Query Historical Orders
Endpoint: /v1/futures/orders/history
Request Parameters
Required
Method: GET
Example
Bash
curl -X GET "https://oapi.websea.com/v1/futures/orders/history?symbol=EOS-USDT&limit=20" \
-H "Token: YOUR_TOKEN" \
-H "Nonce: 1700000000_abcd1" \
-H "Signature: GENERATED_SIGNATURE"
Query Parameters
| Parameter | Required | Type | Example | Description |
|---|---|---|---|---|
| symbol | No | string | EOS-USDT | Trading pair. Required when querying a specific symbol; omit to query all symbols |
| from | No | int | 122 | Starting order_id for pagination |
| direct | No | string | prev | Query direction. prev (default): backward in time/ID order; next: forward in time/ID order |
| limit | No | int | 20 | Number of records to return. Default: 20, Maximum: 100 |
| is_full | No | int | 1 | Margin mode: 1 isolated margin, 2 cross margin |
Response Parameters
| Parameter | Required | Type | Example | Description |
|---|---|---|---|---|
| errno | Yes | int | 0 | Status code |
| errmsg | Yes | string | success | Status message |
| result | Yes | array | See example | Result data |
Result Fields
| Parameter | Required | Type | Example | Description |
|---|---|---|---|---|
| order_id | Yes | string | 11535 | Order ID |
| ctime | Yes | int | 1576746253 | Order creation time (Unix timestamp) |
| symbol | Yes | string | EOS-USDT | Trading pair |
| price | Yes | string | 14 | Order price |
| price_avg | Yes | string | 15 | Average execution price |
| lever_rate | Yes | int | 10 | Leverage multiplier |
| amount | Yes | string | 150 | Order quantity |
| deal_amount | Yes | string | 100 | Executed quantity |
| type | Yes | string | buy-limit | Order type |
| status | Yes | int | 3 | Order status (1=Pending, 2=Partially Filled, 3=Filled, 4=Canceling, 5=Partially Canceled, 6=Canceled) |
| contract_type | Yes | string | open | Position action: open to open a position, close to close a position |
| profit | Yes | string | 10 | Total PnL |