Query Parameters
| Field | Type | Need | Description | Example |
|---|---|---|---|---|
”account” | string | optional | User’s wallet address | 42trU9A5… |
“symbol” | string | optional | Market symbol to filter by | BTC |
”builder_code” | string | optional | Only return trades with this builder code | BUILDER1 |
”start_time” | integer | optional | Start time in milliseconds | 1625097600000 |
”end_time” | integer | optional | End time in milliseconds | 1759215599188 |
”limit” | integer | optional | Maximum number of records to return, defaults to 100 | 100 |
”cursor” | string | optional | Cursor pagination to access records. Default to none | 1115hVka |
Response
- Status 200: Successfully retrieved portfolio position history
| Field | Type | Description |
|---|---|---|
”history_id” | integer | History id of trade |
”order_id” | integer | Order id of order that resulted in the trade |
”client_order_id” | UUID | CLOID of order that resulted in the trade |
”symbol” | string | Trading pair symbol |
”amount” | decimal string | Amount (in token denomination) of the trade event |
”price” | decimal string | Current price of the specified symbol |
”entry_price” | decimal string | Price at which the trade event was executed |
”fee” | decimal string | Fee paid by the trade event |
”spot_fee” | decimal string or null | Native spot fee paid for this trade; only set for spot-buy fills |
”pnl” | decimal string | PnL generated by the trade event |
”event_type” | string | ”fulfill_taker” if taker”fulfill_maker” if maker |
”side” | string | ”open_long""open_short""close_long""close_short" |
"created_at” | integer | Timestamp in milliseconds when the trade event occurred |
”cause” | string | ”normal”regular user-initiated trading ”market_liquidation” position was liquidated due to insufficient margin”backstop_liquidation” position was liquidated by backstop mechanism”settlement”position was closed due to Auto-Deleveraging (ADL) or other settlement |
’next_cursor’ | string | Next cursor for pagination |
’has_more’ | boolean | True if there exists a ‘next_cursor’ |
| Field | Type | Description |
|---|---|---|
'event_type' | string |
|
'side' | string |
|
'cause' | string |
|
- Status 400: Invalid request parameters
- Status 401: Unauthorized access
- Status 500: Internal server error