Query Ticker Orderbook
Endpoint Information
Endpoint: GET /api/v1/tickers/{symbol}/orderbooks?exchange={exchange}
Description: Query platform orderbook
Authentication: Institution API Key + Signature (non-Maker API endpoint — X-Maker-Addr is not required). See Authorization
Query Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
| symbol | string | Yes | Route parameter, stock symbol |
| exchange | int | Yes | URL parameter, exchange code. See Exchange enum type description |
| chain_id | int | No | URL parameter, blockchain network ID. If not provided, queries orders on all chains |
Response Parameters
| Field | Type | Description |
|---|---|---|
| symbol | string | Stock symbol |
| market | string | Market code enum. See Market enum type description |
| ask | object array | Ask orders |
| ask[].price | decimal | Price in corresponding market |
| ask[].volume | decimal | Volume |
| bid | object array | Bid orders |
| bid[].price | decimal | Price in corresponding market |
| bid[].volume | decimal | Volume |
| time | string | Time |
Request Example
Query Using Default Chain ID
bash
curl -X GET "{API_BASE_URL}/api/v1/tickers/AAPLs/orderbooks?exchange=0" \
-H "X-API-Key: YOUR_API_KEY" \
-H "X-API-Timestamp: 1715100000000" \
-H "X-API-Signature: GENERATED_SIGNATURE" \
-H "Content-Type: application/json"Query Specifying Chain ID
bash
curl -X GET "{API_BASE_URL}/api/v1/tickers/AAPLs/orderbooks?exchange=0&chain_id=56" \
-H "X-API-Key: YOUR_API_KEY" \
-H "X-API-Timestamp: 1715100000000" \
-H "X-API-Signature: GENERATED_SIGNATURE" \
-H "Content-Type: application/json"Response Example
json
{
"code": 0,
"data": {
"symbol": "AAPLs",
"market": "usex",
"ask": [
{"price": 150.25, "volume": 100.0},
{"price": 150.30, "volume": 200.0}
],
"bid": [
{"price": 150.20, "volume": 150.0},
{"price": 150.15, "volume": 250.0}
],
"time": "2025-01-17T03:00:24Z"
}
}Implementation Notes
- Supports querying orderbook on specific blockchain networks via the
chain_idparameter - If
chain_idis not provided, the system queries orders on all chains and aggregates them - Orderbook only displays orders with
pendingstatus - Prices are automatically converted based on the exchange's base currency (USD/HKD/USDT)
- Bid orders are sorted by price in descending order, ask orders in ascending order
- Maximum of 5 price levels displayed per side
- Order quantities at the same price are automatically aggregated