Returns
Arguments
Example Query
Usage Guidelines
Bar data provides time-series OHLC (Open, High, Low, Close) aggregates for individual prediction markets. Each bar represents a time period and includes comprehensive metrics for both outcomes, including price movements, volume, liquidity, bid/ask spreads, and order book depth. Key characteristics:- Market ID formats vary by protocol:
- Polymarket:
<marketAddress>:Polymarket:<exchangeAddress>:<networkId>(e.g.,0x25aa90b3cd98305e849189b4e8b770fc77fe89bccb7cf9656468414e01145d38:Polymarket:0xc5d563a36ae78145c45a50134d48a1215220f80a:137) - Kalshi:
<marketSlug>:Kalshi(e.g.,KXMVECROSSCATEGORY-S2026A4A05B370DF-F1FBA451AA9:Kalshi)
- Polymarket:
- Outcome-level OHLC data: Separate price and liquidity metrics for
outcome0andoutcome1 - Detailed market microstructure: Includes bid/ask prices, spreads, and 2% depth metrics
- Volume breakdown: Track buys, sells, and total volume in USD, collateral tokens, and shares
- Time-series format: Each bar has a timestamp (
t) representing the period start - Multiple resolutions: From 1-minute to 1-week intervals for granular or aggregate analysis
Troubleshooting Tips
Why don't outcome prices sum to 1.00?
Why don't outcome prices sum to 1.00?
What's the difference between volumeUsd, volumeShares, and volumeCollateralToken?
What's the difference between volumeUsd, volumeShares, and volumeCollateralToken?
How do I calculate the bid/ask spread?
How do I calculate the bid/ask spread?
askUsd.c - bidUsd.c for the close of each bar. A wider spread indicates lower liquidity or higher market uncertainty. Monitor spreads to assess market health and trading conditions.What does twoPercentBidDepthUsd measure?
What does twoPercentBidDepthUsd measure?
Why might some outcome fields be null?
Why might some outcome fields be null?
liquidityUsd, bidUsd, and depth metrics may be null for older data or during periods when orderbook snapshots weren’t available. Always check for null values before processing these fields.How should I interpret high/low vs open/close in OHLC?
How should I interpret high/low vs open/close in OHLC?
o(open): Value at the start of the bar periodh(high): Maximum value during the periodl(low): Minimum value during the periodc(close): Value at the end of the period
What does allTimeVolumeUsd represent?
What does allTimeVolumeUsd represent?
volumeUsd in the bar to understand what percentage of total volume occurred in that period.Related Recipes
- Prediction Event Dashboard: Use market bars for the single-market drill-down chart
- Prediction Charts: Render outcome probability candlesticks, bid/ask spreads, and volume overlays