Skip to main content
Subscribe to the balances channel to receive account balance snapshots in a balance_response object. Periodic snapshots are published every 60 seconds, with additional event-driven updates after trades, deposits, withdrawals, funding, rewards, and order-margin changes.

Update timing and initial snapshot

After a new subscription, the gateway sends {"subscribed":"balances"} and immediately queues a balance_response from its latest cached account state. You do not wait for the next periodic refresh. This is a cached snapshot, not a fresh balance query; if the gateway has no cached balance yet, it sends a default zero-valued balance until an update arrives. Placing or cancelling an order triggers an update when it changes reserved order margin, including changes to order_margin and available_balance. Reservation updates are coalesced per account on an approximately one-second cadence. Other account events can trigger an earlier snapshot. There is no one-message-per-order guarantee, and delivery is asynchronous. The 60-second interval is the periodic refresh cadence, not a maximum delivery latency guarantee. Every message contains a balance snapshot, not a delta.

1) Authenticate

Send this immediately after connecting to wss://trade.qfex.com?api_key=YOUR_API_KEY:

2) Subscribe

Sample Code

Example Responses

Initial, periodic, and event-driven snapshots all use balance_response. The legacy balance_update / v4_balances envelope does not apply to wss://trade.qfex.com.