Deal
Subscribe
{
"method": "sub.deal",
"param": {
"symbol": "BTC_USDT"
}
}
Unsubscribe
{
"method": "unsub.deal",
"param": {
"symbol": "BTC_USDT"
}
}
Receive recent trades. No login required. Pushed whenever trades occur. Trade stream enables aggregation by default; to disable, set compress=false in the subscription.
Response Parameters
| Field | Type | Description |
|---|---|---|
| p | decimal | Price |
| v | decimal | Quantity |
| T | int | Trade side: 1 buy, 2 sell |
| O | int | Open/close flag: 1 new position, 2 reduce position, 3 position unchanged. If O=1, v is the added position size |
| M | int | Self-trade: 1 yes, 2 no |
| i | int | Transaction ID |
| t | long | Trade time |
| cts | number | The timestamp from The matching engine when this orderbook data is produced |
Sample data
{
"channel": "push.deal",
"symbol": "BTC_USDT",
"data": [
{
"p": 64410.3,
"v": 5,
"T": 2,
"O": 3,
"M": 1,
"t": 1781768636372,
"i": "15007546827",
"cts": "1781768636372"
}
],
"ts": 1781768636372
}