OpenAPI doesn’t describe WebSocket endpoints — this page is the contract.Documentation Index
Fetch the complete documentation index at: https://docs.ticktock.bet/llms.txt
Use this file to discover all available pages before exploring further.
Endpoints
Auth and scope filtering
The handshake validatesapi_key. After upgrade, the server pushes only the message types your key’s scopes allow:
| Frame type | Required scope |
|---|---|
match.created, match.updated, match.finished | cs2:stream:matches |
round.started, round.finished | cs2:stream:matches |
event.kill, event.bomb_planted, event.bomb_defused, event.bomb_exploded | cs2:stream:matches |
market.created, market.updated, market.suspended, market.unsuspended | cs2:stream:markets |
bet_settlement | cs2:stream:markets |
scoreboard.frame | cs2:stream:scoreboard |
403 per-frame, no errors. Use /v1/whoami to confirm your stream scopes before debugging missing frames.
Frame envelope
data is the same shape (and same scope-filtered field set) as the matching REST endpoint — match.updated mirrors GET /cs2/v1/matches/{id}, bet_settlement mirrors a settlement entry, etc.
Snapshot semantics
On connect the server sends a snapshot of currently-relevant state (live matches, active markets) before switching to incremental frames. After that it polls and emits a frame only when the underlying state actually changes — no constant chatter.| Channel | Default poll cadence |
|---|---|
/cs2/v1/stream (list) | 5s |
/cs2/v1/stream/{match_id} (detail) | 2s |
Frame format
WebSocket frames are JSON only. The REST surface offers XML for the seven feed endpoints (see Content negotiation); the WS channel does not — frames are always JSON regardless of theAccept header on the upgrade.
Clients that need XML for their archival pipeline can hit the matching REST endpoint with Accept: application/xml after each interesting frame.
Keep-alive
The server sends analive envelope every 10s — same shape as REST /v1/alive. If you don’t see one for ~30s, reconnect.
Reconnect strategy
- Reconnect with exponential backoff (start 1s, cap at 30s).
- After reconnect, kick off a stateful recovery replay — the AMQP path republishes the current market state plus settlements/voids since your last processed timestamp and terminates with
<snapshot_complete>. - Unique-ish frame ids live in
meta.seq— use it to dedupe across reconnects.