HomeDocumentationAPI Reference
Log In

Trades (Instrument Type) (Currency) (Tx Status)

Channel Name Schema

trades.{instrument_type}.{currency}.{tx_status}

Subscribe to the status on on-chain trade settlement events for a given instrument type and currency.

Channel Parameters

currency string required
Currency
instrument_type string required
Instrument type
enum erc20 option perp
tx_status string required
Transaction status
enum settled reverted

Notification Data

channel string required
Subscribed channel name
data array of objects required
data[].direction string required
Order direction
enum buy sell
data[].index_price string required
Index price of the underlying at the time of the trade
data[].instrument_name string required
Instrument name
data[].liquidity_role string required
Role of the user in the trade
enum maker taker
data[].mark_price string required
Mark price of the instrument at the time of the trade
data[].quote_id string or null required
Quote ID if the trade was executed via RFQ
data[].realized_pnl string required
Realized PnL for this trade
data[].realized_pnl_excl_fees string required
Realized PnL for this trade using cost accounting that excludes fees
data[].subaccount_id integer required
Subaccount ID
data[].timestamp integer required
Trade timestamp (in ms since Unix epoch)
data[].trade_amount string required
Amount filled in this trade
data[].trade_fee string required
Fee for this trade
data[].trade_id string required
Trade ID
data[].trade_price string required
Price at which the trade was filled
data[].tx_hash string required
Blockchain transaction hash
data[].tx_status string required
Blockchain transaction status
enum settled reverted
data[].wallet string required
Wallet address (owner) of the subaccount

Example

Subscriptions are only available via websockets.

{request_example_javascript}
{request_example_python}

Notification messages on this channel will look like this:

{response_example_json}