Skip to content

WebSocket / Trade Channel

Endpoint: /ws/v1/spot/market

Channel Name

trade

Description

This channel provides real-time market trade data for a specific spot trading pair.

Subscription Parameters

Parameter Required Type Example Description
op Yes string sub Operation: sub to subscribe, unsub to unsubscribe
channel Yes string trade Channel name
symbol Yes string BTC-USDT Trading pair

Subscription Example

JSON
{
  "op": "sub",
  "channel": "trade",
  "symbol": "BTC-USDT"
}

Push Data Fields

Parameter Required Type Example Description
channel Yes string trade Channel name
symbol Yes string BTC-USDT Trading pair
id Yes long 17592256642623 Trade ID
amount Yes string 0.04 Trade quantity
price Yes number 1997 Trade price
direction Yes string buy Aggressive side: buy or sell
time Yes number 1502448920106 Trade execution time (timestamp in milliseconds)
ts Yes long 1597026383085 Event timestamp (milliseconds)

Push Example

JSON
{
  "channel": "trade",
  "symbol": "BTC-USDT",
  "id": 17592256642623,
  "amount": "0.04",
  "price": 1997,
  "direction": "buy",
  "time": 1502448920106,
  "ts": 1502448920106
}