{
"channel": "candle",
"data": {
"t": 123,
"T": 123,
"s": "<string>",
"i": "<string>",
"o": "<string>",
"c": "<string>",
"h": "<string>",
"l": "<string>",
"v": "<string>",
"n": 123,
"closed": true,
"reconciled": true
}
}Live Data WebSocket API
candle
Live OHLCV candles for one coin: built from live trades
Subscribe with Finality: the
Intermediate updates are pushed on every trade and carry the plain HL fields. About 2 seconds after
Rules worth building on:
{"method":"subscribe","subscription":{"type":"candle","coin":"BTC","interval":"1m"}} (coin required; interval one of 5s, 30s, 1m, 5m, 15m, 30m, 1h, 4h, 1d, default 1m). Acknowledgement uses subscriptionResponse and the current bucket is sent immediately; updates use CandleUpdate (HL candle shape {t,T,s,i,o,c,h,l,v,n}).
Finality: the closed frame
Intermediate updates are pushed on every trade and carry the plain HL fields. About 2 seconds after T, once the last block of the bucket has been applied, one more frame is sent for that bucket with two extra fields:
closed: true: this is the final state of the bucket. Treat it as final; do not wait for further updates.reconciled:truewhenh,l,vandnwere recomputed from the stored trades (deduplicated by trade id, the same source ascandleSnapshot),falsewhen storage was temporarily unavailable and the frame reflects the live state only.oandcfollow the execution order of trades inside each block, as on Hyperliquid; they are taken from storage only when the live stream missed the first or last trade of the bucket.5sand30sbuckets are always closed withreconciled: false: they are final at theirclosedframe, without the storage recount.
{"channel":"candle","data":{"t":1789385640000,"T":1789385700000,"s":"BTC","i":"1m",
"o":"77709.0","c":"77697.0","h":"77717.0","l":"77686.0","v":"7.92148","n":195,
"closed":true,"reconciled":true}}
- A bucket is final when you receive its
closedframe. If your listener stops considering a bucket atT, you will miss the last block: the final update can legitimately arrive up to ~1 s afterTeven before reconciliation, because blocks are timestamped when proposed and applied slightly later. - A second
closedframe for the sametsupersedes the first (a trade that arrived very late on a non-reconciled bucket). Keep the last one. - Updates for a bucket can still arrive after a newer bucket has opened. They are applied to their own bucket; a newer
tno longer resets the previous one. - With
allCandles, a coin whose trades were entirely missed by the live path still gets aclosedframe built from stored trades.
Live OHLCV update, built from live trades. Sent for candle (one coin) and allCandles (every coin of the interval) subscriptions.