Crypto bars
crypto_barsFetch historical OHLCV bars for crypto pairs to analyze price and volume over time, with configurable timeframe and window. Large results return a result_id for later SQL queries.
Instructions
Historical OHLCV bars for crypto pairs (prices in the quote currency, volume in base units), one row per pair and bar start (UTC). timeframe default 1h; window by start/end or lookback (default P1D). Large results are stored, not shown: you get a result_id to query with results_query.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| end | No | Window end (same format). Default: now (Alpaca's latest available). | |
| sort | No | Time order of the rows: asc (oldest first, default) or desc (newest first). | asc |
| start | No | Window start: ISO date (00:00 UTC) or datetime with a zone, e.g. 2026-01-02T14:30:00Z. | |
| tickers | Yes | Crypto pairs as BASE/QUOTE, e.g. ["BTC/USD"] (1-200). | |
| lookback | No | Window length back from end as an ISO-8601 duration (P5D, P1Y, PT20M); only when start is omitted. Default P1D. | |
| timeframe | No | Bar size: Nmin (1-59), Nh (1-23), 1d, 1w or Nmo (1,2,3,4,6,12). | 1h |
| page_token | No | Continue a truncated fetch: the page_token from the previous response's pagination. |