Connecting
Authentication
After connecting, send an auth message with your API key:WebSocket connections require API key authentication. Generate your key from the Totalis Dashboard.
Subscribing to Channels
After authenticating, subscribe to channels to receive events:Available Channels
| Channel | Audience | Description |
|---|---|---|
rfqs:open | Market makers | All new and open RFQs |
rfq:{rfq_id} | RFQ owner | Updates for a specific RFQ |
mm:quotes:{mm_id} | Market maker | Updates on your own quotes |
Events
RFQ Events
| Event | Description | Data |
|---|---|---|
rfq:created | New RFQ created | Full RFQ object |
rfq:cancelled | RFQ cancelled | { rfq_id, reason } |
rfq:status | RFQ status changed | { rfq_id, status, updated_at, accepted_quote_id } |
rfq:expired | RFQ expired | { rfq_id } |
Quote Events
| Event | Description | Data |
|---|---|---|
quote:submitted | New quote submitted | Full quote object |
quote:accepted | Quote accepted by user | { quote_id, rfq_id, confirmation_deadline } |
quote:confirmed | Quote confirmed by MM | { quote_id, rfq_id, execution_id } |
quote:executed | On-chain vault position created | { quote_id, rfq_id } |
quote:expired | Quote expired | { quote_id, rfq_id } |
quote:rejected | Quote rejected (another was accepted) | { quote_id, rfq_id, reason } |
quote:withdrawn | Quote withdrawn by MM | { quote_id, rfq_id } |
Position Events
Position events are delivered on therfq:{rfq_id} channel. Subscribe to a specific RFQ’s channel to receive its position lifecycle updates. Status and error events are also sent to the MM’s mm:quotes:{mm_id} channel.
| Event | Description | Data |
|---|---|---|
position:created | Position PDA created, collateral locked in vaults | { rfq_id, position_pda, timestamp } |
position:settled | Position settled with outcome | { rfq_id, position_pda, outcome, tx_signature, timestamp } |
position:cancelled | Position cancelled, collateral unlocked | { rfq_id, position_pda, reason, timestamp } |
position:error | Position execution error | { rfq_id, error, timestamp } |
