WebSocket API (data type = 'book')
To maintain full order book visibility you need to first process snapshot (message with is_snapshot = true), after that when you have the full order book state, then you need to apply updates to that order book (message with is_snapshot = false).
We can at our discretion provide a snapshot in the middle of the connection. If you receive a snapshot in the middle of the connection, then you must invalidate the previous order book state and apply the snapshot as the current state of the book.
You could process updates to the book only if you received a snapshot for that book.
Snapshot will be delivered instead of the first order book change after establishing a WebSocket API subscription.
More information: https://docs.coinapi.io/market-data/websocket/messages#orderbook-l2-full--in
Comments
0 comments
Article is closed for comments.