Trading

My trades

Trades executed on the user's orders.

WSSwss://ws.bit2me.com/v1/tradingmy-trades

Streams every trade executed on one of the user's orders, on every market or only on symbol. Needs an authenticated connection.

Subscribe

Subscribes the connection to my-trades. Send symbol to receive only that market, or leave it out to receive every market. Authenticate the connection first: an unauthenticated connection gets Forbidden.

event*string
Valuesubscribe
symbol?string

Only this market. Every market when not sent.

Match^[A-Z0-9]+/[A-Z0-9]+$
ExampleB2M/EUR
subscription*object
Show properties
name*string
Valuemy-trades

Update

Trades executed on the user's orders.

A trade executed on one of the user's orders.

event*string
Valuemy-trades
symbol*string

Market symbol as BASE/QUOTE, uppercase. The list of valid symbols is GET /v2/trading/market-config.

Match^[A-Z0-9]+/[A-Z0-9]+$
ExampleB2M/EUR
data*object
Show properties
id?string

Trade identifier.

Formatuuid
userId?string
Formatuuid
timestamp?integer

Execution time, in milliseconds since the Unix epoch.

datetime?string

Execution time.

Formatdate-time
symbol?string

Market symbol as BASE/QUOTE, uppercase. The list of valid symbols is GET /v2/trading/market-config.

Match^[A-Z0-9]+/[A-Z0-9]+$
ExampleB2M/EUR
order?string

The user's order this trade belongs to.

Formatuuid
side?string

buy spends the quote currency to get the base currency; sell does the opposite.

Value inbuy | sell
price?number
amount?number

Amount in the base currency.

cost?number

Value in the quote currency.

fee?object
Show properties
cost?number

Fee charged, in currency.

currency?string
Match^[A-Z0-9]+$
ExampleEUR
rate?number

Fee rate, as a percentage.

clientOrderId?string | null

Unsubscribe

Removes the my-trades subscription. Send the same symbol used to subscribe, if any.

Removes the my-trades subscription of the connection.

event*string
Valueunsubscribe
symbol?string

The same symbol sent to subscribe, if any.

Match^[A-Z0-9]+/[A-Z0-9]+$
ExampleB2M/EUR
subscription*object
Show properties
name*string
Valuemy-trades
{  "event": "subscribe",  "subscription": {    "name": "my-trades"  }}
{  "event": "my-trades",  "symbol": "B2M/EUR",  "data": {    "id": "9adb20ae-f673-49a4-b232-75442e3af617",    "userId": "7bd4cc22-7682-4e45-85b3-29386b979d75",    "timestamp": 1665997927993,    "datetime": "2022-10-17T09:12:07.993Z",    "symbol": "B2M/EUR",    "order": "69d3df53-9248-430c-9850-d72ff1f0befa",    "side": "sell",    "price": 0.014,    "amount": 100,    "cost": 1.4,    "fee": {      "cost": 0.00224,      "currency": "EUR",      "rate": 0.16    },    "clientOrderId": "MY-CLIENT-ORDER-ID"  }}
{  "event": "unsubscribe",  "subscription": {    "name": "my-trades"  }}