How to access Polymarket historical orderbook data
Polymarket exposes live market state, but researchers often need the orderbook as it looked yesterday, last week, or during a specific event. Resolved Markets stores point-in-time Polymarket orderbook snapshots with full bid/ask depth and exposes them through REST, OpenAPI, CLI export, and MCP.
Last updated:
- Full depthSnapshot contents
- MillisecondsTimestamp precision
- Up to 500REST page size
- CLI CSV exportBulk workflow
Three-step REST workflow
- Find a market. Use
/v1/markets/livefor active markets or/v1/markets/history/recentfor closed ones (filter bycrypto,timeframe,category,sinceandbefore). - Query snapshots. Use
/v1/markets/:id/snapshotswithfrom,to,sideandlimit; addincludebook=truefor the full bid and ask ladders. - Analyze the book. Use
best_bid,best_ask,mid,spread,bids,asks, andsequence_numberfor replay or backtesting.
# 1. Find a live BTC 1-hour market
curl -s "https://api.resolvedmarkets.com/v1/markets/live?crypto=BTC&timeframe=1h" \
-H "X-API-Key: rm_your_key" | jq '.[0] | {conditionId, slug, question}'
# 2. Or the most recently settled one, with its active time range
curl -s "https://api.resolvedmarkets.com/v1/markets/history/recent?crypto=BTC&timeframe=1h&status=closed&limit=1" \
-H "X-API-Key: rm_your_key" | jq '.markets[0] | {market_id, first_seen, last_seen}'
# 3. Pull its order-book snapshots with full depth
curl -s "https://api.resolvedmarkets.com/v1/markets/<market_id>/snapshots?side=UP&includebook=true&limit=500" \
-H "X-API-Key: rm_your_key" | jq '.data[0] | {timestamp, best_bid, best_ask, mid_price}'
# 4. Export a whole market to CSV with the CLI
npm install -g @elcara-hq/resolvedmarkets-cli
rm-api download -m <market_id> --from 2026-09-01 --to 2026-09-02 --format csv -o ./market.csvSnapshot fields that matter
- Full depth:
bidsandasksarrays, not just top-of-book. - Derived prices:
best_bid,best_ask,mid, andspread. - Replay safety:
sequence_number— a per-token count of applied book events, so you can tell how much activity each stored row skipped. - Timing: event and capture timestamps for latency-sensitive research.
- Context: paired spot crypto fields where applicable.
Frequently asked questions
How do I access Polymarket historical orderbook data?
List markets with GET /v1/markets/live or /v1/markets/history, then call GET /v1/markets/:id/snapshots with from, to, side, and limit query parameters. Each response returns point-in-time bid and ask arrays plus derived fields.
What fields are included in a historical snapshot?
Snapshots include condition_id, token_id, side, event_timestamp, capture_timestamp, sequence_number, best_bid, best_ask, mid, spread, full bids and asks arrays, top-5 depth, and paired crypto spot fields where applicable.
How far back does history go?
Resolved Markets keeps the full archive for captured markets. Exact earliest availability depends on when a market category entered the pipeline; Pro and Enterprise plans do not have a fixed 31-day retention cliff.
Can I export data to parquet?
Not directly — the rm-api CLI exports CSV, JSON and JSONL, and maintains an incremental SQLite cache. Converting to parquet from there is one line in your notebook: pandas.read_csv("export.csv").to_parquet("export.parquet"), or DuckDB’s COPY … TO … (FORMAT PARQUET). Enterprise users can also request direct ClickHouse access for large analytical queries.
Related resources
- Polymarket historical dataPrices, trades, order books and resolutions in one place.
- Crypto dataHigh-frequency BTC, ETH, SOL, XRP snapshots.
- Quant researchClickHouse, columnar storage, and microstructure workflows.
- AI agentsMCP and OpenAPI for autonomous tools.
- llms-full.txtFull inlined API reference for LLM context.

