User Wallet History
Query wallet history. Requires the Read permission.
Query parameter rules:
- It's RECOMMENDED to include
walletTypein the query. If it's not provided, the default will be to query spot wallet history only. walletNameis required ifwalletTypeisISOLATED.- Only upgraded wallet allow query wallet history by using
walletType=UNIFIED. historyTypesshould be encoded to a json array.- It will default to fetch data from the past 7 days if the
startTimeand theendTimeare not set. - The
startTimeandendTimemust be within the range of the past 120 days. - If your futures wallet has already been upgraded, querying future wallet history with
walletType=UNIFIEDfor retrieving the post-upgrade history. - Querying wallet history by setting
walletType=CROSSorwalletType=ISOLATEDwill only return wallet history from before the futures wallet upgrade.
For example,
// query spot wallet history since 7 days ago.
.../public-api/wallet/v1/user/walletHistory?walletType=SPOT
// query spot deposit and withdraw history since 7 days ago.
.../public-api/wallet/v1/user/walletHistory?walletType=SPOT&historyTypes=["DEPOSIT","WITHDRAW"]
// query spot deposit and withdraw history from 2023-01-01 to 2023-03-31.
.../public-api/wallet/v1/user/walletHistory?walletType=SPOT&historyTypes=["DEPOSIT","WITHDRAW"]&startTime=1672531200000&endTime=1680307200000
// query BTC-PERP isolated wallet history since 7 days ago.
.../public-api/wallet/v1/user/walletHistory?walletType=ISOLATED&walletName=ISOLATED@BTC-PERP-USDT
The detail which is a transaction on the blockchain will show cryptoNetwork, and once the transaction is completed, the txId will be displayed.
Request Parametersβ
| Name | Type | Required | Description |
|---|---|---|---|
| walletType | Object | No | |
| walletName | String | No | The name of isolated wallet. Required when walletType is ISOLATED |
| asset | String | No | Asset. Required when walletType=SPOT. |
| historyTypes | Object[] | No | Specified query history types |
| startTime | Double | No | Starting time (included). |
| endTime | Double | No | Ending time (excluded). |
| pageSize | Double | No | Page size for pagination |
| currentPage | Double | No | Current page number for pagination |
Response Contentβ
| Name | Type | Description |
|---|---|---|
| data | Object[] |
example
GET
https://api.btse.com/public-api/wallet/v1/user/walletHistoryResponse (Deposit (crypto))
{
"success": true,
"code": 1,
"msg": "Success",
"time": 1624989977940,
"data": [
{
"transactionTime": 1678445104907,
"type": "DEPOSIT",
"walletName": "SPOT@",
"asset": "ETH",
"netAmount": "0.05",
"amount": "0.05",
"transactionRef": "2023031000000321",
"status": "COMPLETED",
"description": null,
"fee": "0",
"cryptoNetwork": "ETHEREUM",
"toAddress": "0xF14BAc881e719934CEFccD1AC5dC5f814dfbCbF8",
"confirmTimes": "(10/10)",
"txId": "0x94ead563799ee341cb136c18dc9a71a231abaec820caa18c096febbe92da8709"
}
]
}
Response (Withdraw (crypto))
{
"success": true,
"code": 1,
"msg": "Success",
"time": 1624989977940,
"data": [
{
"transactionTime": 1678957494276,
"type": "WITHDRAW",
"walletName": "SPOT@",
"asset": "USDT",
"netAmount": "-30",
"amount": "-30",
"transactionRef": "2023031600000374",
"status": "COMPLETED",
"description": null,
"fee": "6.429",
"cryptoNetwork": "ERC20",
"toAddress": "0xF14BAc881e719934CEFccD1AC5dC5f814dfbCbF8",
"confirmTimes": "(15/15)",
"txId": "0x0a8487a85f37d4995716419d7d7d7048c9625fab8cae69c235103a39ea789377"
}
]
}
Response (Send To)
{
"success": true,
"code": 1,
"msg": "Success",
"time": 1624989977940,
"data": [
{
"transactionTime": 1679619604907,
"type": "SEND",
"walletName": "SPOT@",
"asset": "USDT",
"netAmount": "-1",
"amount": "-1",
"transactionRef": "2023024000000034",
"status": "COMPLETED",
"description": null,
"fee": "0",
"cryptoNetwork": null,
"confirmTimes": null,
"txId": null
}
]
}
Response (Others)
{
"success": true,
"code": 1,
"msg": "Success",
"time": 1767580139575,
"data": [
{
"transactionTime": 1767580126422,
"type": "TRANSFER_OUT",
"walletName": "VIRTUAL|4@BTCPFC-USDT#1",
"asset": "USDT",
"netAmount": "-1.00950715",
"amount": "-1.00950715",
"transactionRef": "e6d252e8-eb64-48cd-81f0-e35ab453059d",
"status": "COMPLETED",
"description": "VIRTUAL|4@BTC-PERP-USD#1->CROSS@;CLOSE",
"fee": "0",
"cryptoNetwork": null,
"toAddress": null,
"confirmTimes": null,
"txId": null
},
{
"transactionTime": 1767580126418,
"type": "REALIZED_PNL",
"walletName": "VIRTUAL|4@BTCPFC-USDT#1",
"asset": "USDT",
"netAmount": "-0.00019329",
"amount": "-0.00019329",
"transactionRef": "69491374-0a01-4341-92ed-5212eb36b0ff",
"status": "COMPLETED",
"description": "VIRTUAL|4@BTC-PERP-USD#1;TRADE",
"fee": "0",
"cryptoNetwork": null,
"toAddress": null,
"confirmTimes": null,
"txId": null
},
{
"transactionTime": 1767578949884,
"type": "TRANSFER_IN",
"walletName": "VIRTUAL|4@BTCPFC-USDT#1",
"asset": "USDT",
"netAmount": "1",
"amount": "1",
"transactionRef": "1732d021-75dc-43cc-86b6-ebc767dd0969",
"status": "COMPLETED",
"description": "CROSS@->VIRTUAL|4@BTC-PERP-USD#1;TRANSFER",
"fee": "0",
"cryptoNetwork": null,
"toAddress": null,
"confirmTimes": null,
"txId": null
}
]
}