# Crypto OHLC Candles `GET` `https://api.unusualwhales.com/api/crypto/{pair}/ohlc/{candle_size}` Returns OHLC candle data for a crypto pair. Available candle sizes: 1m, 5m, 10m, 15m, 30m, 1h, 4h, 1d, 1w ## Authentication ``` Authorization: Bearer YOUR_API_KEY ``` ## Path Parameters | Name | Type | Required | Description | |------|------|----------|-------------| | `pair` | string | Yes | | | `candle_size` | string | Yes | | ## Query Parameters | Name | Type | Required | Description | |------|------|----------|-------------| | `limit` | Default 500 Max 500 Min 1 | No | How many items to return. Default: 500. Max: 500. Min: 1. | | `date` | Optional Market Date | No | A trading date in the format of YYYY-MM-DD. This is optional and by default the last trading date. | ## Response (200) | Field | Type | Description | |-------|------|-------------| | `close` | string | | | `high` | string | | | `low` | string | | | `open` | string | | | `pair` | string | | | `start_time` | string | | | `timestamp` | string | | | `volume` | string | | ## Example ### curl ```bash curl -X GET "https://api.unusualwhales.com/api/crypto/{pair}/ohlc/{candle_size}" \ -H "Authorization: Bearer YOUR_API_KEY" \ -H "Accept: application/json" ``` ### Python ```python import http.client conn = http.client.HTTPSConnection("api.unusualwhales.com") headers = {"Authorization": "Bearer YOUR_API_KEY", "Accept": "application/json"} conn.request("GET", "/api/crypto/{pair}/ohlc/{candle_size}", headers=headers) response = conn.getresponse() print(response.read().decode("utf-8")) ``` ## Response Example ```json { "data": [ { "close": "93210.00", "high": "94321.00", "low": "89000.00", "open": "90000.00", "pair": "BTC-USD" } ] } ```