Skip to main content
One websocket carries every live update. Public channels need no key.

Quick example

Node.js

Commands

Every command carries an id you choose; the reply echoes it. Subscribe to a series, not a window, to follow it automatically. With series_tickers: ["sol-15m"], each new window’s window_lifecycle event and first orderbook_snapshot arrive on the same subscription — no resubscribing every 15 minutes. You can pass up to 100 tickers per command.

Channels

Private channels (fill, user_orders, market_positions, balance) arrive with order entry; today they answer error 8 (AUTH_REQUIRED).

Prices

Symbols are a stock (AAPL) or crypto (X:BTCUSD), upper case, up to 64 per command. t_ms is when the price printed at its source; ts_ms is when the server sent it. These are the same prices windows open and settle on.

Sequence numbers and recovery

Every data message has the envelope { type, sid, seq, ts_ms, msg }. seq starts at 1 and goes up by exactly 1 per message on that subscription.
  • If seq jumps, you missed messages. Send update_subscription with action: "get_snapshot" (or resubscribe) and drop your local books until fresh snapshots arrive.
  • Snapshots carry the whole book; deltas carry one level. A delta means: the contracts at price on outcome’s bid side change by delta. A level that reaches 0 is removed.

Checksums

Every orderbook_snapshot and orderbook_delta carries the checksum of the book after it is applied. Compute it on your side after each message; if it doesn’t match, your copy is wrong — request a snapshot.
  1. Take each side’s levels best first (highest price first) and keep the top 10.
  2. Write each level as price:count, exactly as sent on the wire: 0.55:10.
  3. Join a side’s levels with ,, prefix them with up: and down:, and join the two sides with |: up:0.55:10,0.54:3|down:0.44:7 (an empty side is just up: or down:).
  4. The checksum is the CRC-32 (the zlib / PNG one) of that string’s UTF-8 bytes, as an unsigned 32-bit integer.
The REST orderbook returns the same checksum for the same book, so you can seed a book from REST and continue on the websocket.

Limits

The server pings every 10 seconds; standard websocket clients answer automatically. A connection that stops answering is closed. Flooding commands closes the connection with code 1008, and a message over 64 KB with 1009. See Errors for the numbered error replies.