Limited Order Book Depth
Subscribe URL
wss://stream.bittap.com/endpoint?format=JSON
Subscribe Parameters
Stream name: f_depth<level>@<symbol>_scale.
| Parameter | Description |
|---|---|
| level | level indicates the number of bid/ask levels, The default value for level is 30 |
| symbol | trading pair |
| scale | scale indicates aggregation precision, The value for scale can be found in the depth and precision settings of the trading pair |
Data Update
| Name | Type | Description |
|---|---|---|
| e | STRING | Topic |
| s | STRING | trading pair |
| i | STRING | aggregation precision |
| lastUpdateId | LONG | last update id |
| bids | ARRAY | buy orders |
| asks | ARRAY | sell orders |
Subscribe Example
{
"method": "SUBSCRIBE",
"params": [
"f_depth1@BTC-USDT-M_0.01"
],
"id": "eru1bat"
}Subscribe Success Example
{
"code": 0, // 0 means success, non-0 means failure
"msg":"", // failure reason, null when success
"topic": ["", ""], // topics that failed to subscribe
"id": 1
}Data Update Example
{
"e": "f_depth1", // topic
"s": "BTC-USDT-M", // trading pair
"i": "0.01", // aggregation precision
"lastUpdateId": 1777735424, // last update id
"bids": [ // buy orders
[
"106610.65", // price
"2.028125" // quantity
]
],
"asks": [ // sell orders
[
"106610.66",
"2.90337"
]
]
}Unsubscribe Example
{
"method": "UNSUBSCRIBE",
"params": [
"f_depth1@BTC-USDT-M_0.01"
],
"id": "eru1bat"
}Error Codes
No information available
Code Example
Last updated on: