跳转到主要内容
POST
/
v2
/
wallet
/
{chain}
/
{walletAddress}
/
calculate-pnl
Wallet - Calculate PNL
curl --request POST \
  --url https://api.chainstream.io/v2/wallet/{chain}/{walletAddress}/calculate-pnl \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '
{
  "tokenAddresses": [
    "6p6xgHyF7AeE6TZkSmFsko444wqoP15icUSqi2jfGiPN",
    "So11111111111111111111111111111111111111112"
  ]
}
'
{
  "success": true
}

Documentation Index

Fetch the complete documentation index at: https://docs.chainstream.io/llms.txt

Use this file to discover all available pages before exploring further.

授权

Authorization
string
header
必填

Bearer authentication header of the form Bearer <token>, where <token> is your auth token.

路径参数

chain
enum<string>
必填

A chain name listed in supported networks Supported blockchain chains

可用选项:
sol,
eth,
bsc
walletAddress
string
必填

An address of a wallet

请求体

application/json
tokenAddresses
string[] | null

List of token addresses to calculate PnL for

示例:
[
"6p6xgHyF7AeE6TZkSmFsko444wqoP15icUSqi2jfGiPN",
"So11111111111111111111111111111111111111112"
]

响应

200 - application/json

Successful response

success
boolean
必填

Operation success status

示例:

true