> ## Documentation Index
> Fetch the complete documentation index at: https://developer.wooxpro.com/llms.txt
> Use this file to discover all available pages before exploring further.

# 【公共】最新成交频道

获取最新成交数据

### 推送规则

1. 无需用户登录
2. 实时推送，每次推送通常只包含一笔成交

### 请求

> 请求

```json theme={null}
{
  "id": "1",
  "cmd": "SUBSCRIBE",
  "params": ["trade@PERP_BTC_USDT"]
}
```

Topic 格式:

`trade@<symbol>`

* symbol: 交易对，如 `PERP_BTC_USDT`

### 返回

> 返回

```json theme={null}
{
  "topic": "trade@PERP_BTC_USDT",
  "ts": 1618820361552,
  "data": {
    "s": "PERP_BTC_USDT",
    "px": "42598.27",
    "sx": "300",
    "sd": "BUY",
    "src": 0,
    "rpi": false,
    "ts": 1618820361540
  }
}
```

返回数据说明:

| 字段 | 类型 | 描述 |
| :- | :- | :- |
| s | String | 交易对 |
| px | String | 成交价格 |
| sx | String | 成交数量 |
| sd | String | 成交方向，`BUY` 或 `SELL` |
| src | Int | 成交来源 -`1`=内部（WOO X 上的成交） -`0`=外部（聚合来源的成交） |
| rpi | Boolean | 是否与 RPI 订单撮合 |
| ts | Long | 成交在引擎中的生成时间（毫秒） |


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.