Candles & Funding
Historical OHLCV and funding rates from immutable dataset releases.
Both endpoints read from validated, checksummed dataset releases — the same bytes the backtest engine uses. Coverage per venue/pair is in /context/datasets.
GET/context/candles
Query parameters
| Param | Type | Notes |
|---|---|---|
venue | string | Required |
symbol | string | Required — the canonical symbol exactly as returned by /context/markets (never a framework alias) |
timeframe | string | 1m, 5m, 15m, 1h, 4h, 1d (aggregated server-side from 1m) |
from / to | ISO 8601 | Required window; max 10,000 candles per request |
cursor | string | Continue a windowed read |
Response — 200
{
"venue": "lighter",
"symbol": "SOL-PERP.LIGHTER",
"timeframe": "1h",
"release": "rel_2026-07-27T02",
"candles": [
{ "t": "2026-07-01T00:00:00Z", "o": 141.22, "h": 143.05, "l": 140.9, "c": 142.71, "v": 183422.5 }
],
"gaps": [],
"next_cursor": null
}
releasepins the immutable dataset release the rows came from — quote it and any re-read returns identical bytes. On venues whose release pipeline is still pending (Hyperliquid, Binance — see datasets),releaseisnulland reproducibility is not claimed.gapslists intervals the venue itself never served (venue-side holes are recorded, never interpolated). An empty array is a completeness statement, not a default.- Bulk export: send
Accept: text/csvfor the same window as CSV — one row per candle, same fields.
GET/context/funding
Hourly funding rates for perp venues.
Query parameters: venue, symbol, from, to (same semantics as candles).
Response — 200
{
"venue": "lighter",
"symbol": "SOL-PERP.LIGHTER",
"release": "rel_2026-07-27T02",
"fundings": [
{
"t": "2026-07-01T00:00:00Z",
"rate": 0.0000125,
"rate_annualized": 0.1095
}
],
"gaps": [
{ "from": "2025-01-21T14:00:00Z", "to": "2025-01-21T15:00:00Z", "reason": "venue_history_hole" }
]
}
rate is the decimal fraction per funding interval; rate_annualized is derived for convenience. Funding history is the input for carry analysis and cost-of-hold modeling — the things a directional backtest silently ignores.
Freshness
Releases publish on backfill cadence (hourly for active venues), so the most recent ~1–2 hours may not be in a release yet. to values beyond the latest release are clamped, and the response's release timestamp tells you the effective horizon. Context is a research surface; execution-time data belongs to your deployed framework's live venue connection.