Skip to main content
The Totalis WebSocket pushes post-trade events in real time — quote acceptances and confirmations, and position settlements. Connect, authenticate, subscribe to the channels you need, and handle events as they arrive. For pre-trade live pricing, use the SSE streams instead: the maker stream for incoming quote requests, and the quote-request stream for the best current quote. The WebSocket covers everything from quote acceptance onward.
WebSocket events reach you only while you’re connected — missed events are not redelivered. For durable, at-least-once delivery to a server (signed, retried, replayable), use webhooks; they carry most of the same lifecycle moments. An early cash-out that closes a position is on both channels (position:bought_back here, position.bought_back by webhook); the one exit outcome neither channel pushes to the buyer is a bid that acquires a position — see the event catalog. See Real time & data channels for the full channel map.

Connecting

Authentication

Send an auth message with your API key immediately after connecting:
Success:
Error:

Subscribing to channels

After authenticating, subscribe to channels to receive events:

Events

Quote events

mm_quote:accepted payload:
draft_quote_id is undocumented. It appears nowhere else in the API contract, and its relationship to the accepted quote_id above isn’t specified — treat it as informational only, and use quote_id (the value valid for confirmation) rather than draft_quote_id for any action. If your integration needs to know what this field represents, raise it with Totalis support rather than assuming a meaning.

Position events

position_pda is the on-chain account address for the position, not a lookup key. To fetch or reference a position through the API, use rfq_id (or position_id, once it’s set on the RFQ) instead.

Keep-alive

Send periodic pings to keep the connection open:
Response:

Example