Skip to main content
GET
/
v1
/
kalshi
/
orderbooks
# Get orderbook history for past hour
curl -H "x-api-key: YOUR_API_KEY" \
  "https://api.predexon.com/v1/kalshi/orderbooks?ticker=KXBTC-25JAN31-B100000&start_time=1706745600000&end_time=1706749200000&limit=50"
{
  "snapshots": [
    {
      "ticker": "KXBTC-25JAN31-B100000",
      "timestamp": 1706745600000,
      "yes_bids": [
        {"price": 52, "size": 1500},
        {"price": 51, "size": 2300},
        {"price": 50, "size": 1800}
      ],
      "yes_asks": [
        {"price": 54, "size": 1200},
        {"price": 55, "size": 2100},
        {"price": 56, "size": 900}
      ],
      "best_bid": 52,
      "best_ask": 54,
      "bid_depth": 5600,
      "ask_depth": 4200,
      "sequence": 12345678
    },
    {
      "ticker": "KXBTC-25JAN31-B100000",
      "timestamp": 1706745660000,
      "yes_bids": [
        {"price": 53, "size": 1800},
        {"price": 52, "size": 2000},
        {"price": 51, "size": 1500}
      ],
      "yes_asks": [
        {"price": 55, "size": 1100},
        {"price": 56, "size": 1900},
        {"price": 57, "size": 800}
      ],
      "best_bid": 53,
      "best_ask": 55,
      "bid_depth": 5300,
      "ask_depth": 3800,
      "sequence": 12345890
    }
  ],
  "pagination": {
    "limit": 50,
    "count": 50,
    "pagination_key": "eyJ0aW1lc3RhbXAiOjE3MDY3NDU2NjAwMDAsInNlcXVlbmNlIjoxMjM0NTg5MH0=",
    "has_more": true
  }
}

Overview

Fetch historical orderbook snapshots for a Kalshi market over a specified time range. Returns snapshots including yes bids, yes asks, and market metadata.
All timestamps are in milliseconds. Prices are in cents (1-99 representing 0.01to0.01 to 0.99).
ticker
string
required
The Kalshi market ticker
start_time
integer
required
Start time in Unix timestamp (milliseconds)
end_time
integer
required
End time in Unix timestamp (milliseconds)
limit
integer
default:"100"
Maximum number of snapshots to return (1-200)
pagination_key
string
Pagination key for cursor-based pagination (from previous response)
snapshots
array
pagination
object
# Get orderbook history for past hour
curl -H "x-api-key: YOUR_API_KEY" \
  "https://api.predexon.com/v1/kalshi/orderbooks?ticker=KXBTC-25JAN31-B100000&start_time=1706745600000&end_time=1706749200000&limit=50"
{
  "snapshots": [
    {
      "ticker": "KXBTC-25JAN31-B100000",
      "timestamp": 1706745600000,
      "yes_bids": [
        {"price": 52, "size": 1500},
        {"price": 51, "size": 2300},
        {"price": 50, "size": 1800}
      ],
      "yes_asks": [
        {"price": 54, "size": 1200},
        {"price": 55, "size": 2100},
        {"price": 56, "size": 900}
      ],
      "best_bid": 52,
      "best_ask": 54,
      "bid_depth": 5600,
      "ask_depth": 4200,
      "sequence": 12345678
    },
    {
      "ticker": "KXBTC-25JAN31-B100000",
      "timestamp": 1706745660000,
      "yes_bids": [
        {"price": 53, "size": 1800},
        {"price": 52, "size": 2000},
        {"price": 51, "size": 1500}
      ],
      "yes_asks": [
        {"price": 55, "size": 1100},
        {"price": 56, "size": 1900},
        {"price": 57, "size": 800}
      ],
      "best_bid": 53,
      "best_ask": 55,
      "bid_depth": 5300,
      "ask_depth": 3800,
      "sequence": 12345890
    }
  ],
  "pagination": {
    "limit": 50,
    "count": 50,
    "pagination_key": "eyJ0aW1lc3RhbXAiOjE3MDY3NDU2NjAwMDAsInNlcXVlbmNlIjoxMjM0NTg5MH0=",
    "has_more": true
  }
}

Use Cases

Liquidity Analysis

Analyze historical bid/ask depth and spread patterns

Market Microstructure

Study orderbook dynamics and price formation

Backtesting

Test trading strategies against historical orderbook data

Arbitrage Research

Compare orderbook states across platforms

Price Format

Kalshi uses cents for prices (1-99), where:
  • 52 = $0.52 (52% implied probability)
  • 99 = $0.99 (99% implied probability)
To convert to decimal: price / 100

Authorizations

x-api-key
string
header
required

API key for authentication. Get your free key at dashboard.predexon.com

Query Parameters

ticker
string
required

The Kalshi market ticker

start_time
integer
required

Start time in Unix timestamp (milliseconds)

end_time
integer
required

End time in Unix timestamp (milliseconds)

limit
integer
default:100

Maximum number of snapshots to return

Required range: 1 <= x <= 200
pagination_key
string | null

Pagination key to get the next chunk of data

Response

Successful Response

Kalshi orderbooks endpoint response.

snapshots
KalshiOrderbookSnapshot · object[]
required
pagination
CursorPagination · object
required

Cursor-based pagination for endpoints that don't support offset.