keydata.shop: Polymarket and exchange order flow
v0.1.0Free SQL over Polymarket 5/15-min crypto up/down markets with Binance, Bybit, OKX, Coinbase data
These tools were reported by the server itself during our smoke test (tools/list), not copied from the README.
list_tables List tables
List the tables, the period covered and the limits per query. Call it first.
describe_table Describe a table
Columns of a table: type, how the 10-second bar was rolled up, and what the column means. Numbered book levels (bid_price_00 .. bid_price_09) are listed once.
| Parameter | Type | Description |
|---|---|---|
table * | string |
exchange_bars Exchange OHLC bars
OHLC bars of one exchange instrument: mid open/high/low/close, time-weighted spread (bps), trade OHLC, base and quote volume, taker-buy share of the quote volume, trades and messages. Times are UTC; the default window is the last day. Coinbase has spot only.
| Parameter | Type | Description |
|---|---|---|
coin * | string | |
end | ||
exchange | string | |
instrument_class | string | |
interval | string | |
start |
compare_venues Compare exchange venues
Side-by-side market quality of every exchange instrument of a coin: mean and median spread (bps), quote volume, trades, mean depth within 5 bps (both sides), book reach, share of silent bars and of bars with a provably valid book. Default window: every day served.
| Parameter | Type | Description |
|---|---|---|
coin * | string | |
end | ||
start |
polymarket_markets Polymarket markets
Markets of one up/down series in a window (default: the last day): start and end, the settled outcome, the Up token's mid at the start, 60 s before the end (the last bar that closed by then) and at the end, its mean spread (probability points), and volume and trades of both tokens.
| Parameter | Type | Description |
|---|---|---|
coin * | string | |
end | ||
interval_min | integer | |
limit | integer | |
start |
expiry_calibration Expiry calibration
How well the Polymarket price predicts the outcome: the Up token's mid N seconds before each market's end (from the last 10-second bar that had closed by then, so no look-ahead), grouped into probability buckets, against the share of markets that settled Up. Also the Brier score. coin and interval_min narrow the set; default: every market served.
| Parameter | Type | Description |
|---|---|---|
buckets | integer | |
coin | ||
end | ||
interval_min | ||
seconds_before_end | integer | |
start |
sample_rows Sample rows
First rows of a table from `start` (UTC; default: the first bar). limit 1-50. `columns` picks columns by name; default all (the exchange tables are 83 columns wide).
| Parameter | Type | Description |
|---|---|---|
table * | string | |
columns | ||
limit | integer | |
start |
run_sql Run read-only SQL
Run one read-only DuckDB SELECT over the tables of list_tables (cex, polymarket, chainlink and the per-source views such as binance_btc or polymarket_btc_5m). Filter on ts and aggregate in SQL: at most max_rows rows come back (up to the server's cap), and the query is stopped at the timeout. DuckDB functions such as time_bucket, arg_max, quantile_cont, corr, regr_slope and window functions are available; file and network access are not.
| Parameter | Type | Description |
|---|---|---|
sql * | string | |
max_rows | integer |