ts (microseconds since epoch). Reconstruction is exact — every order is replayed from the indexed event stream, not sampled from polled snapshots. Same response shape as the live /book endpoint, plus a history_starts anchor and an as_of timestamp.
Endpoint
:ts is a microsecond UNIX timestamp. ISO-string conversion: epoch_us = unix_seconds * 1_000_000.
Query parameters
Response
How it works
Every snapshot is a deterministic replay of the indexed event stream up to:ts. There is no sampling, no polling, no smoothing — if a fill happened one microsecond before your timestamp, the size is reflected; one microsecond after and it isn’t.
Use cases
- Pre-trade replay — feed
:ts = trade_time - 1µsto see exactly what book the trader saw before placing. - Slippage backtests — for any historical fill, compute realized vs theoretical at-time-of-decision.
- Liquidity migration analysis — chart top-of-book depth over time without polling.
- Forensics — investigate manipulation by reconstructing books around suspicious fills.
Examples
Notes
- Cost: ~50–200ms per request depending on
:tsand outcome activity. Costs grow with order activity in the window, not with how far back:tsis. :tsin the future returns 400.:tsbeforehistory_startsreturns an empty book with awarning. Both are intentional — no silent zeros.resting_orders_countis the truth check — when reconstructing AT NOW, it matches the live book exactly (verified byte-for-byte against/v1/markets/:id/book).- For high-frequency replay across many timestamps, prefer one large query window via
/v1/markets/:id/depth-history(coming soon) over many calls here. - This endpoint is rate-limited on your tier’s per-minute quota like all
/v1/*routes — heavy backtests should respect the limit.