Trades Perps
trades_perp
Taker executions on perpetual instruments. One message per trade — the taker's side only (no duplicate for the maker).
Channel: trades_perp:{instrument}
Example: trades_perp:BTC_USDC-PERPETUAL
Payload
["2251.50", "1.5", 1704067200000]| Index | Type | Description |
|---|---|---|
| 0 | string | Price (always positive) |
| 1 | string | Signed size — positive = taker bought (lifted ask), negative = taker sold (hit bid) |
| 2 | integer | Trade execution timestamp (ms) |
sub.on("publication", (ctx) => {
const [price, signedSize, timestamp] = ctx.data;
const side = Number(signedSize) >= 0 ? "buy" : "sell";
});History
Last 100 trades available via the history API on bidirectional transports. See Transports & Connection for subscribe examples with history fetch.
On reconnect, the SDK automatically recovers missed trades using the last known stream position.
Updated 1 day ago
