API Documentation

Reference for the Convex Lake REST API — authentication, endpoints, parameters, and response formats.

#1. Get started

This page walks you from zero to your first downloaded data file in three steps.

Step 1 — Create an API key

Sign in, open Settings → API Keys, and generate a key. Keys look like do_XXXXXXXX_XXXXXXXX and are shown only once — copy and store it safely.

Every request carries the key in a header:

x-api-key: do_YOUR_KEY

Step 2 — Discover what's available

The catalog is browsed one level at a time with /info. Start at the top and drill down: md_type → exchange → ticker → timeframe → date → files.

curl -H "x-api-key: do_YOUR_KEY" "https://api.convexlake.com/info"

→ {"folders": ["orderbook/", "trades/", "candles/", "surface/", "bbo/"], ...}

curl -H "x-api-key: do_YOUR_KEY" "https://api.convexlake.com/info?md_type=orderbook&exchange=kalshi&ticker=btc&timeframe=15&date=2026-05-21"

→ {"objects": [{"key": "...", "slug": "KXBTC15M-26MAY211945", "size": 812430, ...}], ...}

Each object includes a ready-to-use slug — the filename without its format extension.

Step 3 — Download a file

Pass the same parameters plus the slug to the matching download endpoint:

curl -O -J -H "x-api-key: do_YOUR_KEY" "https://api.convexlake.com/orderbook?exchange=kalshi&ticker=btc&timeframe=15&date=2026-05-21&slug=KXBTC15M-26MAY211945"

The response is the raw file; curl -O -J saves it under its real name (format resolved automatically).

Python example:

import requests

KEY = "do_YOUR_KEY"
BASE = "https://api.convexlake.com"
H = {"x-api-key": KEY}

# Find files for a date
info = requests.get(f"{BASE}/info", headers=H, params={
    "md_type": "candles", "exchange": "polymarket",
    "ticker": "btc", "timeframe": "5", "date": "2026-06-10",
}).json()

for obj in info.get("objects", []):
    r = requests.get(f"{BASE}/candles", headers=H, params={
        "exchange": "polymarket", "ticker": "btc", "timeframe": "5",
        "date": "2026-06-10", "slug": obj["slug"],
    })
    r.raise_for_status()
    name = r.headers["Content-Disposition"].split("filename=")[-1].strip('"')
    open(name, "wb").write(r.content)
    print("saved", name)

JavaScript example:

const KEY = "do_YOUR_KEY";
const BASE = "https://api.convexlake.com";

const info = await fetch(
  `${BASE}/info?md_type=trades&exchange=polymarket&ticker=btc&timeframe=5&date=2026-06-10`,
  { headers: { "x-api-key": KEY } },
).then(r => r.json());

const slug = info.objects[0].slug;
const file = await fetch(
  `${BASE}/trades?exchange=polymarket&ticker=btc&timeframe=5&date=2026-06-10&slug=${slug}`,
  { headers: { "x-api-key": KEY } },
);
const blob = await file.blob(); // save or parse as needed

Rate limits: Free 60 req/min · Research 300 req/min · Pro 1,000 req/min. Exceeding the limit returns HTTP 429 with a Retry-After header.

Using an AI assistant instead? The same data is available through our MCP server — see the MCP section on the API Keys page.

#2. Overview

The Convex Lake API provides programmatic access to historical market data files (orderbook snapshots, trades) collected from prediction market venues and stored in object storage.

Base URL:

https://api.convexlake.com

Endpoints:

EndpointDescription
GET /infoBrowse available folders and files (drill down by exchange, ticker, timeframe, date)
GET /orderbookDownload a specific orderbook data file
GET /surfaceDownload a specific volatility surface file
GET /candlesDownload a specific candles (OHLCV) file
GET /tradesDownload a specific trades file
GET /leaderboardList dates and download leaderboard CSVs
GET /leaderboard-tradesList trader addresses and download per-trader trades CSVs

Authentication:

Generate an API key on the API Keys page. Include it in every request:

x-api-key: do_XXXXXXXX_XXXXXXXX_XXXXXXXX_XXXXXXXX

Keys can be revoked at any time from the API Keys page. Revoked keys are immediately rejected.

#3. GET /info

Lists folders and files available under a data path. Use it to discover what exchanges, tickers, timeframes and dates are available, and to list the exact filenames you can pass to /orderbook.

Drill-down parameters:

Provide parameters progressively — each additional parameter drills one level deeper.

ParameterDescriptionExample
md_typeMarket data type (top-level namespace)orderbook
exchangeVenue namekalshi
tickerUnderlying or categorybtc
marketKalshi market slug (level between category and date)bnb
timeframeContract timeframe in minutes (e.g. 15 → 15m)15
dateTrading date (YYYY-MM-DD)2026-05-21

Tickers are lowercase for prediction markets (polymarket, kalshi, limitless, predict-fun) and uppercase for deribit and binance.

surface has no ticker level (surface/{exchange}/{date}/), and candles for deribit / hyperliquid are rolling per-instrument files (candles/{exchange}/{timeframe}/).

Examples:

List available market data types:

curl -H "x-api-key: do_YOUR_KEY" "https://api.convexlake.com/info"

List exchanges under an md_type:

curl -H "x-api-key: do_YOUR_KEY" "https://api.convexlake.com/info?md_type=orderbook"

List tickers under an exchange:

curl -H "x-api-key: do_YOUR_KEY" "https://api.convexlake.com/info?md_type=orderbook&exchange=kalshi"

List timeframes for a ticker:

curl -H "x-api-key: do_YOUR_KEY" "https://api.convexlake.com/info?md_type=orderbook&exchange=kalshi&ticker=btc"

List available dates:

curl -H "x-api-key: do_YOUR_KEY" "https://api.convexlake.com/info?md_type=orderbook&exchange=kalshi&ticker=btc&timeframe=15"

List files for a specific date:

curl -H "x-api-key: do_YOUR_KEY" "https://api.convexlake.com/info?md_type=orderbook&exchange=kalshi&ticker=btc&timeframe=15&date=2026-05-21"

Response fields:

FieldDescription
tierYour subscription tier
allowed_exchangesExchanges your plan can access
prefixThe resolved path being listed
foldersSubfolders under the current prefix
objectsFile entries (only present at the leaf level) with key, size, last_modified
is_truncatedTrue if the folder had more than 1000 entries

Response example (/info?md_type=orderbook&exchange=kalshi&ticker=btc&timeframe=15&date=2026-05-21):

{

"tier": "research",

"allowed_exchanges": ["kalshi","polymarket","predict","limitless","deribit","binance"],

"prefix": "orderbook/kalshi/btc/15m/2026-05-21/",

"folders": [],

"objects": [

{"key":"KXBTC15M-26MAY211945.gz","size":812430,"last_modified":"2026-05-21T19:46:02.000Z"},

{"key":"KXBTC15M-26MAY212000.gz","size":798211,"last_modified":"2026-05-21T20:01:04.000Z"}

],

"is_truncated": false

}

Empty result: If nothing exists at the requested path, the endpoint returns HTTP 404 with:

{"message":"no data for parameters provided", ...}

#4. Download endpoints

Each market data type has its own download endpoint, bound to its own top-level storage prefix:

EndpointStorage prefixContent
GET /orderbookorderbook/Orderbook snapshots / BBO
GET /surfacesurface/Volatility surfaces
GET /candlescandles/OHLCV candles
GET /tradestrades/Executed trades

They all share the same parameters as /info plus a slug (the file name from the objects list, without the file extension).

Common parameters:

ParameterRequiredDescription
exchangeyesVenue name (e.g. kalshi)
tickeryesUnderlying or category (e.g. btc) — not used by /surface or rolling candles
marketnoKalshi market slug between category and date (e.g. bnb)
timeframenoTimeframe in minutes (e.g. 15) — required for deribit/hyperliquid candles
dateyesTrading date (YYYY-MM-DD) — not used by rolling candles
slugyesFile slug from /info, without extension

Response:

The response body is the raw file bytes. The Content-Disposition header sets the filename to the slug, so curl -O -J saves it with the correct name.

Workflow:

1. Call /info to discover the folder and get the exact slug filenames.

2. Call the matching download endpoint with the same parameters + slug.

Notes:

- slug is given without a file extension (e.g. KXBTC15M-26MAY211945); the API resolves the stored format automatically.

- slug cannot contain / or ...

- Missing files return HTTP 404 with {"message":"no data for parameters provided", "key": ...}.

#4.1 GET /orderbook

Downloads a single orderbook (or BBO) file from the orderbook/ prefix.

Parameters:

ParameterRequiredDescription
exchangeyeskalshi, polymarket, predict-fun, limitless, deribit, binance (Research / Pro) or free
tickeryesUnderlying, e.g. btc (lowercase for prediction markets, uppercase for deribit/binance)
timeframeconditionalContract timeframe in minutes (15 → 15m). Omit for deribit
file_typenoLimitless only: book (default), oracle or trades — the three sibling files per epoch
dateyesTrading date, YYYY-MM-DD
slugyesFile slug from /info, without extension
md_typenoOverrides the prefix; use bbo for best-bid/offer files

Request:

curl -O -J -H "x-api-key: do_YOUR_KEY" "https://api.convexlake.com/orderbook?exchange=kalshi&ticker=btc&timeframe=15&date=2026-05-21&slug=KXBTC15M-26MAY211945"

Response example:

HTTP/1.1 200 OK

content-type: application/gzip

content-disposition: attachment; filename="KXBTC15M-26MAY211945.gz"

content-length: 812430

Decompressed body (CSV):

ts,side,price,size,level

1779737100123,bid,0.54,1200,1

1779737100123,ask,0.56,800,1

1779737100456,bid,0.55,950,1

#4.2 GET /surface

Downloads a volatility surface file from the surface/ prefix.

Path layout: surface/{exchange}/{date}/{slug} — there is no ticker level.

Parameters:

ParameterRequiredDescription
exchangeyesderibit
dateyesCollection date, YYYY-MM-DD
slugyesFile slug from /info?md_type=surface, without extension

Request:

curl -O -J -H "x-api-key: do_YOUR_KEY" "https://api.convexlake.com/surface?exchange=deribit&date=2026-09-14&slug=BTC-2026-09-14"

Response example:

HTTP/1.1 200 OK

content-type: application/gzip

content-disposition: attachment; filename="BTC-surface.csv.gz"

Decompressed body (CSV):

ts,expiry,strike,moneyness,iv,delta,gamma,vega,theta

1786464000000,2026-08-29,60000,0.92,0.5123,0.71,0.000021,86.4,-42.1

1786464000000,2026-08-29,65000,1.00,0.4871,0.52,0.000029,94.7,-48.6

Requires a Research or Pro key.

#4.3 GET /candles

Downloads an OHLCV candles file from the candles/ prefix.

Two path layouts:

- Prediction markets: candles/{exchange}/{category}/[market/]{date}/{slug}

- deribit and hyperliquid: rolling per-instrument files at candles/{exchange}/{timeframe}/{instrument} — no ticker or date

Parameters:

ParameterRequiredDescription
exchangeyeskalshi, polymarket, predict-fun, limitless, deribit, hyperliquid
tickerconditionalUnderlying or category, e.g. btc, crypto. Not used for deribit/hyperliquid
marketnoKalshi market slug between category and date, e.g. bnb
timeframeconditionalCandle interval (15 → 15m). Required for deribit/hyperliquid
dateconditionalTrading date, YYYY-MM-DD. Not used for deribit/hyperliquid
slugyesFile slug from /info?md_type=candles, without extension

Requests:

curl -O -J -H "x-api-key: do_YOUR_KEY" "https://api.convexlake.com/candles?exchange=kalshi&ticker=crypto&market=bnb&date=2026-03-24&slug=KXBNB-26MAR2417-B537-prices"

curl -O -J -H "x-api-key: do_YOUR_KEY" "https://api.convexlake.com/candles?exchange=hyperliquid&timeframe=1h&slug=BTC"

Response example:

HTTP/1.1 200 OK

content-type: application/gzip

content-disposition: attachment; filename="KXBTC15M-26MAY211945.gz"

Decompressed body (CSV):

ts,open,high,low,close,volume,trades

1779736200000,0.52,0.57,0.51,0.55,18420,214

1779737100000,0.55,0.59,0.54,0.58,20115,236

#4.4 GET /trades

Downloads an executed-trades file from the trades/ prefix.

Parameters:

ParameterRequiredDescription
exchangeyesVenue name, e.g. polymarket
tickeryesUnderlying or category, e.g. btc, crypto (lowercase for prediction markets)
marketnoKalshi market slug between category and date, e.g. bnb
timeframeconditionalContract timeframe in minutes (5 → 5m)
dateyesTrading date, YYYY-MM-DD
slugyesFile slug from /info?md_type=trades, without extension

Request:

curl -O -J -H "x-api-key: do_YOUR_KEY" "https://api.convexlake.com/trades?exchange=polymarket&ticker=btc&timeframe=5&date=2026-06-10&slug=btc-updown-5m-1781049600-trades"

Response example:

HTTP/1.1 200 OK

content-type: application/gzip

content-disposition: attachment; filename="btc-updown-5m-1781049600-trades.gz"

Decompressed body (CSV):

ts,side,price,size,trade_id

1781049603117,buy,0.61,250,0x9f21...a4

1781049607884,sell,0.60,180,0x71bc...d0

Trade files are typically much smaller than orderbook snapshots.

#4.5 GET /leaderboard

Lists and downloads trader leaderboard CSV files stored under leaderboard/{exchange}/{date}/leaderboard.csv.

Each date folder contains a single leaderboard.csv, so a date returns the file directly — no filename or extra parameters needed.

Parameters:

ParameterRequiredDescription
exchangenoVenue, defaults to polymarket
datenoTrading date, YYYY-MM-DD. Omit to list available dates

List available dates:

curl -H "x-api-key: do_YOUR_KEY" "https://api.convexlake.com/leaderboard?exchange=polymarket"

{"tier":"research","exchange":"polymarket","prefix":"leaderboard/polymarket/","dates":["2026-09-08","2026-09-09"]}

Download a day's leaderboard:

curl -O -J -H "x-api-key: do_YOUR_KEY" "https://api.convexlake.com/leaderboard?exchange=polymarket&date=2026-09-09"

Requires a Research, Pro or Institutional key.

#4.6 GET /leaderboard-trades

Lists and downloads per-trader leaderboard trades CSV files stored under leaderboard-trades/{exchange}/{address}.csv.

Each trader has a single {address}.csv file, so an address returns the file directly — no filename, date or extra parameters needed. Available venues: polymarket, limitless, predict-fun.

Parameters:

ParameterRequiredDescription
exchangenoVenue: polymarket, limitless, predict-fun. Defaults to polymarket
addressnoTrader address. Omit to list available addresses

List available trader addresses:

curl -H "x-api-key: do_YOUR_KEY" "https://api.convexlake.com/leaderboard-trades?exchange=polymarket"

{"tier":"research","exchange":"polymarket","prefix":"leaderboard-trades/polymarket/","addresses":["0xabc...","0xdef..."]}

Download one trader's trades:

curl -O -J -H "x-api-key: do_YOUR_KEY" "https://api.convexlake.com/leaderboard-trades?exchange=limitless&address=0xabc..."

Requires a Research, Pro or Institutional key.

#5. Error Handling

All errors return a JSON object.

Status codes:

CodeMeaning
200Success
400Bad request (missing required parameter, invalid slug)
401Unauthorized (missing, invalid, or revoked API key)
403Forbidden — your plan does not include this exchange
404No data for the given parameters
405Method not allowed (only GET is supported)
502Upstream storage error

Example responses:

{"error":"Missing x-api-key header"}

{"error":"Invalid API key"}

{"error":"Forbidden: your plan does not include this data","allowed_exchanges":["free"]}

{"message":"no data for parameters provided","key":"orderbook/kalshi/btc/15m/2026-05-21/foo"}

Common issues:

- Extension: slug may be sent with or without a file extension — the API strips it and resolves the stored format automatically.

- Ticker case: prediction-market tickers are lowercase (btc, crypto); only deribit and binance use uppercase.

- Wrong tier: Free-tier keys can only access the free exchange. Upgrade to Research or Pro for kalshi, polymarket, predict-fun, limitless, deribit, binance and hyperliquid.

- Wrong header: Use x-api-key, not Authorization.

- Revoked key: Generate a new key from the API Keys page.

#6. Best Practices

Discovery pattern:

Always call /info first to learn the exact filenames — filenames encode contract identifiers and vary by date. Do not hard-code slugs.

Pagination:

/info returns up to 1000 entries per call. If is_truncated is true, narrow the query with more drill-down parameters instead of paginating.

Downloads:

- Files can be large (often 500 KB – 5 MB per snapshot, gzip-compressed). Stream them to disk rather than holding them in memory.

- Use curl -O -J to keep the original filename.

Key hygiene:

- Store API keys as environment variables — never commit them to source control.

- Rotate keys periodically: generate a new key first, migrate your clients, then revoke the old one.

Rate limits:

Free tier is capped at 60 requests per minute; Pro tier at 300 requests per minute. Requests over the limit receive HTTP 429 with a Retry-After header.

#7. Data Reference

Overview of every dataset available through the API — storage prefix, coverage and file format.

For the full coverage matrix across all venues with update cadence and storage paths, see the Data Coverage page.

Venues & coverage:

PrefixVenueFirst dateCategories / Symbols
candles/kalshi/Kalshi2026-04-17crypto, economics, esports, other, politics, sports, weather
candles/polymarket/Polymarket2025-01-01crypto, economics, entertainment, esports, news, other, people, politics, science, sports, tech, weather
candles/predict-fun/Predict.fun2026-07-28crypto, esports, finance, sports, weather
trades/kalshi/Kalshi2026-04-11crypto, economics, esports, other, politics, sports, weather
trades/polymarket/Polymarket2024-07-04politics, esports, science, entertainment, crypto, economics, news, tech, weather, people, sports, other
trades/deribit/Deribit options2026-08-07BTC, ETH
trades/binance/Binance options2026-08-11BTC, ETH
orderbook/kalshi/Kalshi live book2026-05-18btc, eth, sol, xrp — 15m, 1h, 1d
orderbook/limitless/Limitless2026-07-10bnb, btc, doge, eth, sol, xrp — 1h
orderbook/polymarket/Polymarket BBO2026-04-23btc, eth, sol, xrp — 5m, 15m, 1h, 4h, 1d
orderbook/predict/Predict.fun live book2026-07-08bnb, btc, eth — 5m, 15m, 1h, 1d
orderbook/deribit/Deribit options book2026-08-07BTC, ETH
orderbook/binance/Binance options book2026-08-11BTC, ETH
surface/deribit/Deribit vol surface2026-08-07BTC, ETH

File formats:

DatasetFormat
candles/*CSV
trades/*CSV
orderbook/kalshi, polymarket, predictgzip, newline-delimited Python dicts (ast.literal_eval)
orderbook/limitlessgzip, newline-delimited JSON
orderbook/deribit, surface/deribitCSV
orderbook/binance, trades/binanceCSV

#7.1 Candles — Kalshi

Price history for settled Kalshi prediction markets.

Categories:

CategoryFirst dateSub-categories
crypto2026-04-17btc, eth, sol, bnb, xrp
economics2026-06-04feddissent, fedtweets, cpi, gdp, fomc
esports2026-04-18cs2, dota2, lol, valorant
other2026-04-24misc.
politics2026-05-17election, senate, congress
sports2026-07-13tennis, mlb, nba, nfl, nhl, soccer, golf, ufc, f1
weather2026-04-17city/region temperature markets

Columns:

ColumnTypeDescription
timestampintUnix seconds (UTC)
yes_bidfloatBest bid for YES, USD (0–1)
yes_askfloatBest ask for YES, USD (0–1)
pricefloatMid price of YES
volumefloatContracts traded in the interval

Example rows:

timestamp,yes_bid,yes_ask,price,volume

1747432800,0.49,0.51,0.5,1250.0

1747436400,0.50,0.52,0.51,880.0

Notes:

- yes_bid + no_bid ≈ 1.0 — Kalshi markets are binary.

- Each file covers the full life of one market from open to settlement.

- The date folder is the market's expiry date parsed from the ticker.

- volume is in contracts; each contract pays $1 at resolution.

#7.2 Candles — Polymarket

Price history for Polymarket markets.

Categories: crypto, economics, entertainment, esports (2025-01-28), news, other (2025-04-07), people, politics, science, sports, tech, weather (2025-01-09) — most from 2025-01-01.

Columns:

ColumnTypeDescription
timestampintUnix seconds (UTC)
YesfloatProbability of YES (0–1)
NofloatProbability of NO (0–1)

Example rows:

timestamp,Yes,No

1699920000,0.52,0.48

1699923600,0.55,0.45

Notes:

- Yes + No ≈ 1.0 — mirror prices.

- Rows are written on price change, not on a fixed interval.

- Multi-outcome markets produce one file per outcome.

- Prices are USDC cost per share; the winning outcome pays $1.

#7.3 Candles — Predict.fun

Summary records for resolved Predict.fun markets. One row per file (one market).

Tags: crypto, esports, finance, sports (2026-07-28), weather (2026-07-29), economy, tech, tweets (2026-07-30).

Columns:

ColumnTypeDescription
slugstringMarket identifier / URL slug
starts_atstringMarket open (ISO 8601 UTC)
ends_atstringResolution time (ISO 8601 UTC)
market_variantstringe.g. CRYPTO_UP_DOWN, ESPORTS_LOL
titlestringMarket title
winning_outcomestringResolved winner
openfloatUnderlying price at open (crypto only)
closefloatUnderlying price at close (crypto only)
feed_symbolstringPrice feed symbol, e.g. BTCUSDT
outcomesstringSemicolon-separated sub-market titles

Example row:

btc-updown-5m-1785385800,2026-07-30T04:30:00.000Z,2026-07-30T04:35:00.000Z,CRYPTO_UP_DOWN,"Bitcoin Up or Down",Up,64089.995,64142.035,BTCUSDT,"Bitcoin Up or Down"

Notes:

- open/close are raw underlying prices, not probabilities.

- winning_outcome is Up/Down for crypto, a team abbreviation otherwise.

- Lookback is ~2 days — predict.fun only exposes recently resolved markets.

#7.4 Trades — Kalshi

Full trade history for settled Kalshi markets.

Category structure mirrors candles/kalshi/. First date 2026-04-11.

Columns:

ColumnTypeDescription
created_timestringTrade timestamp (ISO 8601 UTC)
yes_pricefloatFill price for YES (0–1)
no_pricefloatFill price for NO (0–1)
countfloatContracts filled
taker_sidestringyes or no
taker_outcome_sidestringOutcome the taker bought
is_block_tradeboolTrue if ≥ 1000 contracts

Example rows:

created_time,yes_price,no_price,count,taker_side,taker_outcome_side,is_block_trade

2025-01-15T14:32:05Z,0.52,0.48,100,yes,yes,False

2025-01-15T15:00:00Z,0.55,0.45,5000,yes,yes,True

Notes:

- yes_price + no_price = 1.0 for standard binary markets.

- Block trades are negotiated off-book and may not reflect the prevailing spread.

- In-game live sports markets (KXMVE*) are excluded by default.

#7.5 Trades — Polymarket

On-chain trade history for Polymarket markets.

First date 2024-07-04 (politics); other categories start between 2024-08 and 2025-12.

Columns:

ColumnTypeDescription
timestampintUnix seconds (UTC)
pricefloatFill price in USDC (0–1)
sizefloatUSDC notional of the trade
sidestringBUY or SELL (taker perspective)
outcomestringYes or No
transaction_hashstringPolygon transaction hash

Example rows:

timestamp,price,size,side,outcome,transaction_hash

1699920000,0.52,100.0,BUY,Yes,0xabc123...

1699920005,0.51,50.0,SELL,Yes,0xdef456...

Notes:

- size is USDC, not contracts — divide by price for share count.

- Trades settle on Polygon via Polymarket's CTF Exchange; hashes are verifiable on Polygonscan.

- One file per outcome (Yes or No) of one market.

#7.6 Trades — Deribit

Historical options trades from Deribit.

Currencies BTC, ETH. Instrument format {CURRENCY}-{DDMMMYY}-{STRIKE}-{C|P}. First date 2026-08-07.

Columns:

ColumnTypeDescription
timestamp_msintTrade timestamp (Unix ms)
trade_idstringDeribit trade identifier
trade_seqintSequential trade number
instrument_namestringFull instrument name
directionstringbuy or sell (taker)
amountfloatContract amount (USD notional for BTC)
pricefloatFill price in BTC
mark_pricefloatMark price at fill, in BTC
index_pricefloatSpot index in USD
ivfloatImplied volatility (%, annualized)
liquidationboolTrue if forced close

Example rows:

timestamp_ms,trade_id,trade_seq,instrument_name,direction,amount,price,mark_price,index_price,iv,liquidation

1748304000000,T123456,8891,BTC-10AUG26-60000-P,buy,0.1,0.0520,0.0518,68400.0,72.5,False

Notes:

- Inverse pricing: prices are in BTC/ETH. USD value = price * index_price.

- Each file covers one instrument for one UTC calendar date.

#7.7 Orderbook — Kalshi

Live snapshots and deltas captured via WebSocket.

Symbols btc, eth, sol, xrp; timeframes 15m, 1h, 1d. First date 2026-05-18.

Format: gzip text, one message per line, serialized as a Python dict string (not JSON) — parse with ast.literal_eval(). Snapshots and deltas are interleaved.

Snapshot example:

{'type': 'orderbook_snapshot', 'sid': 12345, 'seq': 1001, 'msg': {'market_ticker': 'KXBTC-2506-T60000', 'yes_dollars_fp': [['50','200'],['49','500']], 'no_dollars_fp': [['51','150']]}}

Delta example:

{'type': 'orderbook_delta', 'sid': 12345, 'seq': 1002, 'msg': {'market_ticker': 'KXBTC-2506-T60000', 'price_dollars': '50', 'delta_fp': '-200', 'side': 'yes', 'ts_ms': 1718459525123}, 'local_timestamp': 1718459525200}

Fields:

FieldDescription
seqSequence number — apply deltas in order
yes_dollars_fp / no_dollars_fpBook side: [price_cents, quantity] pairs
price_dollarsPrice level in cents ('50' = $0.50)
delta_fpQuantity change (negative = removed)
ts_msExchange timestamp (Unix ms)
local_timestampCollector timestamp (Unix ms)

Reconstructing the book:

1. Initialize from the most recent snapshot.

2. Apply deltas with seq > snapshot_seq in order.

3. book[side][price] += delta_fp; drop the level at zero.

#7.8 Orderbook — Limitless

Full orderbook snapshots for Limitless markets, captured periodically.

Symbols bnb, btc, doge, eth, sol, xrp; timeframe 1h. First date 2026-07-10. Slug format: {asset}-up-or-down-hourly-{start_unix}.

Format: gzip text, one JSON object per line (json.loads()), each a full book snapshot.

Example line:

{"marketSlug":"btc-up-or-down-hourly-1751385600","orderbook":{"bids":[{"price":0.52,"size":1000,"side":"BUY"}],"asks":[{"price":0.54,"size":800,"side":"SELL"}]},"localTimestamp":1751389200123}

Fields:

FieldDescription
marketSlugMarket identifier
orderbook.bidsBuy side, best (highest) first
orderbook.asksSell side, best (lowest) first
priceProbability (0–1)
sizeShares at that level; each share pays $1
localTimestampCollector timestamp (Unix ms)

Notes:

- Each line is a full book, not a delta.

- One file per market epoch.

#7.9 Orderbook — Polymarket (BBO)

Top-of-book stream captured via WebSocket — best bid and best ask only.

Symbols btc, eth, sol, xrp; timeframes 5m, 15m, 1h, 4h, 1d. First date 2026-04-23.

Format: gzip text, one Python dict string per line — parse with ast.literal_eval(). One line per BBO change.

Example line:

{'market': '0x7d6c...abcd', 'asset_id': '12345678...', 'best_bid': '0.52', 'best_ask': '0.54', 'spread': '0.02', 'timestamp': 1751389200123, 'event_type': 'best_bid_ask', 'local_timestamp': 1751389200150}

Fields:

FieldDescription
marketCLOBv2 condition ID (0x hex)
asset_idERC-1155 token ID for the YES outcome
best_bid / best_askString-encoded prices in USDC (0–1)
spreadbest_ask − best_bid
timestampExchange timestamp (Unix ms)
local_timestampCollector timestamp (Unix ms)

Notes:

- BBO only — full depth is not captured.

- Events are emitted on change, not at fixed intervals.

#7.10 Orderbook — Predict.fun

Full orderbook snapshots for Predict.fun crypto up/down markets.

Symbols bnb, btc, eth; timeframes 5m, 15m, 1h, 1d. First date 2026-07-08. Slug format: {symbol}-updown-{timeframe}-{epoch_start_unix}.

Format: gzip text, one Python dict string per line — parse with ast.literal_eval().

Example line:

{'asks': [[0.54, 200], [0.56, 100]], 'bids': [[0.52, 300]], 'lastOrderSettled': {'id': '901846955', 'kind': 'LIMIT', 'outcome': 'No', 'price': '0.54', 'side': 'Bid'}, 'marketId': 708395, 'orderCount': 7, 'settlementsPending': {'asks': [[0.54, 50]], 'bids': [[0.52, 100]]}, 'local_timestamp': 1751994060000}

Fields:

FieldDescription
asks / bids[[price, size], ...], best first; price is a probability (0–1)
lastOrderSettledMost recently matched order; may be an empty dict
marketIdPredict.fun internal market ID
orderCountResting orders in the book
settlementsPendingMatched but unsettled orders, same shape as asks/bids
local_timestampCollector timestamp (Unix ms)

Notes:

- Each line is a full book, not a delta.

- No exchange timestamp is provided — use local_timestamp as event time.

#7.11 Orderbook — Deribit Options

Ten-level book snapshots per instrument, including Greeks and IV.

Currencies BTC, ETH. First date 2026-08-07.

Columns:

ColumnDescription
snapshot_tsSnapshot timestamp (Unix ms)
instrument_nameFull Deribit instrument name
mark_priceMark price in BTC
mark_ivMark implied volatility (%, annualized)
bid_iv / ask_ivIV implied by best bid / ask
underlying_priceSpot index in USD
open_interestOpen interest in USD
delta, gamma, vega, theta, rhoGreeks (theta per day, in BTC)
bid_1_price … bid_10_priceBid prices, levels 1–10, in BTC
bid_1_size … bid_10_sizeBid sizes, levels 1–10, in USD
ask_1_price … ask_10_priceAsk prices, levels 1–10, in BTC
ask_1_size … ask_10_sizeAsk sizes, levels 1–10, in USD

Total: 13 header columns + 40 book-level columns = 53 columns.

Notes:

- Inverse pricing: USD value = price_btc * underlying_price.

- Sizes are USD notional (bid_1_size = 5000 → $5,000).

- bid_iv/ask_iv may be empty when the spread is very wide; unavailable levels are blank.

#7.12 Volatility Surface — Deribit

Implied volatility surface snapshots — all listed options for a currency at periodic intervals through one day.

Currencies BTC, ETH. First date 2026-08-07.

Columns:

ColumnDescription
snapshot_tsSnapshot timestamp (Unix ms)
instrument_nameDeribit instrument name
expiryExpiry date (e.g. 27JUN25)
strikeStrike price in USD
option_typeC (call) or P (put)
underlying_priceSpot index in USD at snapshot
mark_priceMark price in BTC
mark_ivMark implied volatility (%, annualized)
bid_price / ask_price / mid_pricePrices in BTC
volumeContracts traded on the date (cumulative)
volume_usdVolume in USD
open_interestOpen interest in contracts
estimated_delivery_priceEstimated forward price in USD

Notes:

- Inverse pricing: USD value = price * underlying_price.

- One snapshot spans all active strikes × expirations × option types; a file holds all of the day's snapshots.

- Deep OTM options with no market may have bid_price = 0 or blank.

- The surface files are a flattened, single-level view of orderbook/deribit/, better suited to surface fitting and vol calibration.

#7.13 Orderbook — Binance Options

Ten-level book snapshots for Binance European-style options (EAPI), one file per instrument per UTC date.

Currencies BTC, ETH. First date 2026-08-11. Path: orderbook/binance/{BTC|ETH}/{YYYY-MM-DD}/{instrument}-orderbook.csv.

Instrument naming follows Binance options convention: BTC-260819-61500-C → underlying, expiry (YYMMDD), strike in USDT, C call / P put.

Columns:

ColumnDescription
timestamp_msSnapshot timestamp (Unix ms)
bid_p1 … bid_p10Bid prices, levels 1–10, in USDT
bid_s1 … bid_s10Bid sizes, levels 1–10, in contracts
ask_p1 … ask_p10Ask prices, levels 1–10, in USDT
ask_s1 … ask_s10Ask sizes, levels 1–10, in contracts

Total: 1 timestamp column + 40 book-level columns = 41 columns.

Example rows:

timestamp_ms,bid_p1,bid_s1,...,ask_p10,ask_s10

1787071230110,860.000,0.17,,,,,...

Notes:

- Unlike Deribit, Binance options are USDT-quoted — prices are already in USD terms, no inverse conversion needed.

- Empty cells mean the level does not exist at that snapshot; illiquid strikes often have only one or two levels.

- Snapshots are captured at a fixed polling interval, so consecutive rows may be identical when the book does not change.

#7.14 Trades — Binance Options

Executed option trades from Binance options, one file per instrument per UTC date.

Currencies BTC, ETH. First date 2026-08-11. Path: trades/binance/{BTC|ETH}/{YYYY-MM-DD}/{instrument}-trades.csv.

Columns:

ColumnDescription
idBinance trade ID
timestamp_msTrade timestamp (Unix ms)
priceOption premium in USDT
qtyTrade size in contracts
sideAggressor side: buy or sell

Example rows:

id,timestamp_ms,price,qty,side

2476979972738481008,1787112972784,10,0.81,sell

Notes:

- Rows are ordered by timestamp_ms; multiple prints can share the same millisecond.

- Notional in USD = price * qty.

- Files exist only for instruments that traded on the date, so quiet strikes may be absent.

Convex Lake

A comprehensive financial technology platform for prediction market data and quantitative analytics

Resources

Company

© 2026 Convex Lake. All rights reserved.