Latest Trade Subscription
This WebSocket provides real-time trade detail push notifications.
Overview
This page provides detailed documentation on how to subscribe to real-time trade detail data (Trade) using the WebSocket API. Through this interface, users can receive continuous trade updates in real time, including transaction prices, volumes, directions, and timestamps for various products such as stocks, cryptocurrencies, forex, and futures. It explains how to establish a connection, manage request frequency, handle responses, and interpret the push data format for efficient integration into trading systems or analytics platforms.
Request Frequency
For a single WebSocket connection, all requests (subscribe, unsubscribe, heartbeat) are limited to 60 times per minute. If the request frequency limit is exceeded, the connection will be automatically closed. If disconnections occur too frequently, and the system deems them to be malicious requests, the API key will be banned. Please be mindful of the calling logic during usage.
Error Code Explanation
Please refer to the WebSocket error code documentation for further details.
Subscription Address
Please refer to the WebSocket subscription addresses.
Request Quantity
Different subscription plans allow varying numbers of products per WebSocket subscription. Please refer to the WebSocket restrictions documentation for specific details.
Request (Protocol Number: 10000)
{
"code": 10001,
"trace": "423afec425004bd8a5e02e1ba5f9b2b0",
"msg": "ok"
}code
Integer
Yes
Protocol number for the request
10000
trace
String
Yes
Trace ID (random string)
423afec425004bd8a5e02e1ba5f9b2b0
data
JSON
Yes
Subscription data
codes
String
Yes
Subscribed symbol (separate multiple with commas)
BTCUSDT
Response (Protocol Number: 10001)
{
"code": 10001,
"trace": "423afec425004bd8a5e02e1ba5f9b2b0",
"msg": "ok"
}code
Integer
Yes
Response protocol number
10001
trace
String
Yes
Trace ID from the request
423afec425004bd8a5e02e1ba5f9b2b0
msg
String
Yes
Response message
ok
Push (Protocol Number: 10002)
{
"code": 10002,
"data": {
"p": "103482.94",
"s": "BTCUSDT",
"t": 1747552358393,
"td": 2,
"v": "0.00096",
"vw": "99.3436224"
}
}code
Integer
Yes
Push protocol number
10002
data
JSON
Yes
Push data entity
s
String
Yes
Symbol name
BTCUSDT
p
String
Yes
Current price
103482.94
t
Long
Yes
Trade timestamp
1747552358393
td
Integer
Yes
Trade direction (0: default, 1: Buy, 2: Sell)
2
v
String
Yes
Trade volume
0.00096
vw
String
Yes
Trade value
99.3436224
Last updated
