> ## 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.

# 【Public】Trade Channel

Get trade data

### Pushing Rules

1. No user login required
2. Pushed in real-time. Each push usually contains one trade

### Request

> Request

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

Topic Format:

`trade@<symbol>`

* symbol: Trading pair, such as `PERP_BTC_USDT`

### Response

> Response

```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
  }
}
```

Return data description:

| Field | Type | Description |
| :- | :- | :- |
| s | String | Symbol |
| px | String | Trade price |
| sx | String | Trade quantity |
| sd | String | Trade side, `BUY` or `SELL` |
| src | Int | Trade source -`1`=internal (trades on WOO X) -`0`=external (trades from aggregated sources) |
| rpi | Boolean | Whether the trade is matched as an RPI order |
| ts | Long | Trade generation time in engine (in millisecond) |


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