Skip to main content
GET /api/v1/account/balance/history

Query Parameters

FieldTypeNeedDescriptionExample
”account”stringrequiredUser’s wallet address42trU9A5…
“limit”integeroptionalMaximum number of records to return, defaults to system defined limit100
”cursor”stringoptionalCursor pagination to access records. Default to none1115hVka
”include_trades”booleanoptionalIf true, includes trade events. By default only shows deposit, withdraw, subaccount transfer, and payout eventsfalse
/api/v1/account/balance/history?account=42trU9A5...

Response

  • Status 200: Successfully retrieved balance history
{
  "success": true,
  "data": [
    {
      "amount": "100.000000",
      "balance": "1200.000000",
      "pending_balance": "0.000000",
      "event_type": "deposit",
      "created_at": 1716200000000
    }
    ...
  ],
  "next_cursor": "11114Lz77",
  "has_more": true
}
FieldTypeDescription
'amount'decimal stringAmount change to balance after event
'balance'decimal stringAccount balance after event
'pending_balance'decimal stringPending balance after event
'event_type'stringType of balance event (see below)
'created_at'integerTimestamp in milliseconds of when the balance event occurred
'next_cursor'stringNext cursor for pagination
'has_more'booleanTrue if there exists a 'next_cursor'
Event Type (String)Description
'deposit'Deposit funds to account
'deposit_release'Release of previously pending deposit
'withdraw'Withdrawal of funds from account
'trade'Trading activity (fees, realized PnL)
'market_liquidation'Liquidation by market orders
'backstop_liquidation'Liquidation by backstop liquidator
'adl_liquidation'Liquidation by auto-deleveraging
'subaccount_transfer'Transfer between subaccounts
'funding'Funding payment
'payout'Payout event (from e.g. affiliate program)
  • Status 400: Invalid request parameters
  • Status 401: Unauthorized access
  • Status 500: Internal server error

Code Example (Python)

import requests

response = requests.get(
    "/api/v1/portfolio?account/balance/history?account=42trU9A5..."
    headers={"Accept": "*/*"},
)

data = response.json()