查詢錢包余額
HTTP 請求
GET /spot/v3/private/account
請求參數
無
返回參數
參數 | 類型 | 說明 |
---|---|---|
balances | array | Object |
> coin | string | 幣種 |
> coinId | string | 幣種ID |
> total | string | 總額 |
> free | string | 可用余額 |
> locked | string | 凍結余額 |
請求示例
curl --location --request GET 'https://api-testnet.bybit.com/spot/v3/private/account' \
--header 'X-BAPI-SIGN: XXXXX' \
--header 'X-BAPI-API-KEY: {api key}' \
--header 'X-BAPI-TIMESTAMP: 1659346886605' \
--header 'X-BAPI-RECV-WINDOW: 5000'
響應示例
{
"retCode": 0,
"retMsg": "OK",
"result": {
"balances": [
{
"coin": "BTC",
"coinId": "BTC",
"total": "0.20378018343",
"free": "0.20378018343",
"locked": "0"
},
{
"coin": "BTC3L",
"coinId": "BTC3L",
"total": "743.03560386",
"free": "743.03560386",
"locked": "0"
},
{
"coin": "BTC3S",
"coinId": "BTC3S",
"total": "0.999",
"free": "0.999",
"locked": "0"
}
]
},
"retExtMap": {},
"retExtInfo": {},
"time": 1659346887407
}