Crypto Order-Book Snapshots: Null vs Zero - Handle Missing Fields Correctly
A depth snapshot is a list of price levels with quantities at one moment. What's absent from it is as important as what's present.
Short answer
Binance's depth endpoint returns lastUpdateId, event and transaction times, and bids and asks as [price, quantity] pairs up to the requested limit. A price not listed is not 'zero liquidity' — it may simply be beyond the depth limit. An empty side within the limit is rare and worth flagging. Each snapshot is a single moment; comparing two snapshots without the updates between them hides adds and cancels. Record lastUpdateId so snapshots can be ordered and joined with diff streams.
Fields and what missing values mean
| Field | Null / absent means | Zero / empty means |
|---|---|---|
| Level not listed | Beyond depth limit or empty | — |
| bids / asks array | Empty side: flag | — |
| Quantity | — | Not 0 in snapshots |
| lastUpdateId | Needed for ordering | — |
| Depth limit | Defines the visible range | — |
Put Crypto Order-Book Snapshots next to price, flow and positioning in one workspace.
Open a ChartsPod workspaceHandling policy
Illustrative: with limit 20, a snapshot shows bids down to 59,850. A 'wall' at 59,500 isn't visible — not because it's absent, but because it sits beyond the requested depth.
Conclusion
Related: Crypto Order-Book Deltas: Null vs Zero - Handle Missing Fields Correctly, Order-Book Liquidity Pulls in Crypto: What Price Response Adds to the Reading.
Record lastUpdateId so snapshots can be ordered and joined with diff streams.
Review Crypto Order-Book Snapshots with bar replay before using it live.
Open ChartsPod replayQuestions readers ask
Does an unlisted price mean no liquidity?
Not necessarily; it may be beyond the depth limit.
What is lastUpdateId for?
Ordering and syncing with diff streams.
Can snapshots show cancels?
Not directly; compare with diffs.
Sources and methodology
Field definitions come from DEX Screener's API reference, CoinGecko's onchain API documentation and Binance's Spot API documentation, read 17 October 2026. Where a schema was not visible in the documentation, this guide says so and describes defensive handling rather than asserting field behaviour.
- Binance: USD-M Futures market data API — trades, depth, funding and open interest.
- Binance USD-M: How to manage a local order book correctly — snapshot plus diff synchronisation.
This article explains research tools and workflows. It is not financial advice, does not recommend buying or selling any asset and does not predict prices. Crypto derivatives carry a risk of rapid and total loss of margin.
CHARTSPOD EDITORIAL EDITION · RESEARCH AND EDUCATION ONLY · NOT FINANCIAL ADVICE.