Polymarket OHLCV Candlesticks

GET/gateway/v1/prediction-market/polymarket/price-ohlcv/{condition_id}

OHLCV candlestick data for charting a Polymarket market — open, high, low, close, volume per candle. Use this for rendering price charts with candlestick or bar visualizations. For simple price time series (one price per interval), use `prices` instead.

Data refresh: ~30 minutes

Query Parameters

condition_idstringrequired

Polymarket condition ID

Example: 0x6fefc0438c7598b23531457c8c60541990d0786bd4bd9dfc3eabc8d95c291092
start_timeinteger

Start time (Unix seconds). 0 means no lower bound. Cache aligns to 5-minute buckets, so two requests within the same bucket return the same cached result.

end_timeinteger

End time (Unix seconds). 0 means current time. Cache aligns to 5-minute buckets, so two requests within the same bucket return the same cached result.

intervalinteger

Candle interval in minutes: 1=1min, 60=1hour, 1440=1day

Polymarket OHLCV Candlesticks
const options = {method: 'GET'};

fetch('https://api.asksurf.ai/gateway/v1/prediction-market/polymarket/price-ohlcv/{condition_id}', options)
  .then(res => res.json())
  .then(res => console.log(res))
  .catch(err => console.error(err));
OK
{
  "$schema": "https://example.com/schemas/V2CandlestickResponse.json",
  "candles": [
    {
      "close": 123,
      "end_period_ts": 123,
      "high": 123,
      "low": 123,
      "open": 123,
      "timestamp": 123,
      "trades_count": 123,
      "volume": 123
    }
  ],
  "condition_id": "<string>",
  "interval": 123
}