Skip to main content

Candles

Real-time candlestick/kline data.

warning

The candle array uses the order [start, open, close, high, low, baseVolume]. This differs from the standard OHLCV convention where High and Low come before Close.

Subscribe Request:

{
"id": "12345",
"method": "subscribe",
"params": {
"channel": "candles",
"symbol": "BTC-USDT",
"type": "1hour",
"snapshot": {
"startAt": "2024-12-23T00:00:00.000Z",
"endAt": "2024-12-23T23:59:59.999Z"
}
}
}

Request parameters

ParameterDescription
symbol (required)Trading pair symbol. Specify trading pair to get updates. See Get /api/v1/symbols for all currently available trading pairs.
type (required)Candle interval. Specify time interval to get updates. Available values: 1min, 5min, 15min, 30min, 1hour, 2hour, 4hour, 8hour, 12hour, 1day, 1week, 1month.
snapshot (optional)Historical data range set with the following startAt and endAt values. Set this range to get the candles data of the specified period in the initial response. If this range is not set in the request, then the candles are not returned in the initial response, however candles will still be delivered via subscription updates.
startAt (required)Start date and time.
endAt (required)End date and time.

Response

Subscribe Response:

{
"id": "12345",
"result": {
"success": true,
"candles": [
[
"2024-12-23T10:00:00.000Z",
"50800.00",
"51000.00",
"51100.00",
"50700.00",
"98.45678"
],
[
"2024-12-23T11:00:00.000Z",
"51000.00",
"51200.00",
"51250.00",
"50950.00",
"125.67890"
]
]
}
}

Subscription Push Example:

{
"method": "subscription",
"params": {
"channel": "candles",
"symbol": "BTC-USDT",
"type": "1hour",
"data": {
"candle": [
"2024-12-23T12:00:00.000Z",
"51000.00",
"51200.00",
"51250.00",
"50950.00",
"125.67890"
]
}
}
}

Response Parameters

The candle field is a positional array: [start, open, close, high, low, baseVolume]. Note: This order differs from the standard OHLCV convention where High and Low come before Close.

ParameterDescription
start (required)The start time of the candle. Type: string.
open (required)The price of the asset at the beginning of the specified period. Type: string.
close (required)The price of the asset at the end of the specified period. Type: string.
high (required)The highest price the asset reached during the specified period. Type: string.
low (required)The lowest price the asset dropped to during the specified period. Type: string.
baseVolume (required)The total amount of the base currency traded within the specified period. Type: string.