K-line Stream
Subscribe to K-line pushes for a specified trading pair and interval.
- Channel Format:
kline@{symbol},{interval} - Supported Intervals:
1m5m15m30m1h4h1d1w - Push Frequency: Real-time when data changes
- Access: Public
Subscribe Request
{
"op": "subscribe",
"args": ["kline@BTC_USDT,1m"]
}
Unsubscribe
{
"op": "unsubscribe",
"args": ["kline@BTC_USDT,1m"]
}
Push Example
{
"ch": "kline@BTC_USDT,1m",
"d": {
"s": "BTC_USDT",
"i": "1m",
"ot": 1768205280000,
"ct": 1768205339999,
"o": "49000",
"h": "49100",
"l": "48900",
"c": "49050",
"v": "12.345",
"qv": "605000.50",
"tc": 156,
"bv": "6.123",
"bqv": "300000.25",
"x": false
}
}
Push Fields
| Field | Type | Description |
|---|---|---|
s | string | Trading pair |
i | string | Interval |
ot | number | Open time (milliseconds) |
ct | number | Close time (milliseconds) |
o | string | Open price |
h | string | High price |
l | string | Low price |
c | string | Close price / latest price |
v | string | Volume (base asset) |
qv | string | Turnover (quote asset) |
tc | number | Number of trades |
bv | string | Taker buy volume |
bqv | string | Taker buy turnover |
x | boolean | Whether the K-line is closed |