Skip to Content
🚀 Spot APISpot WebSocketLimited Depth of Market Information

Limited Depth of Market Information

Subscribe URL

wss://stream.bittap.com/endpoint?format=JSON

Subscribe Parameters

Stream Name: s_depth<level>@<symbol>_scale

ParameterDescription
levelindicates the number of bid and ask orders, The default value for level is 30.
symbolTrading Pair
scaleindicates the aggregation precision, The value for scale can be found in the depth and precision settings of the trading pair.

Data Update

NameTypeDescription
eSTRINGTopic
sSTRINGsymbol
iSTRINGaggregation precision
lastUpdateIdLONGlast update id
bidsARRAYbids
asksARRAYasks

Subscribe Example

{ "method": "SUBSCRIBE", "params": [ "s_depth1@BTC-USDT_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": "s_depth30", //topic "s": "BTC-USDT", //symbol "i": "0.01", //aggregation precision "lastUpdateId": 1777735424, //last update id "bids": [ //bids [ "106610.65", //price "2.028125" //quantity ] ], "asks": [ //asks [ "106610.66", "2.90337" ] ] }

Unsubscribe Example

{ "method": "UNSUBSCRIBE", "params": [ "s_depth1@BTC-USDT_0.01" ], "id": "eru1bat" }

Error Codes

No information available

Code Example

Last updated on: