Skip to main content
GET
Markets WebSocket: stream real-time market price updates

Endpoint details

Establishes a WebSocket connection for streaming V2 market price changes in real-time. Connection: wss://therundown.io/api/v2/ws/markets Authenticate the WebSocket upgrade with X-TheRundown-Key: $THERUNDOWN_API_KEY from a server-side client. Native browser WebSocket clients cannot set custom headers; use an authenticated backend relay for browser consumers. WebSocket access requires an Ultra plan or higher. Filter parameters (query string):
  • affiliate_ids — comma-separated affiliate IDs
  • sport_ids — comma-separated sport IDs
  • event_ids — comma-separated event IDs
  • market_ids — comma-separated market IDs
All filters are optional. If none are specified, all messages are received. Heartbeat: Server sends {"meta":{"type":"heartbeat"},"data":{"now":"<RFC3339>"}} every 15 seconds. Message format:
Queue: 1024-message buffer per client. If the client falls behind, messages are dropped.

Authorizations

X-TheRundown-Key
string
header
required

Recommended API key request header for new integrations

Query Parameters

affiliate_ids
string

Comma-separated sportsbook/affiliate IDs to filter. Common values include DraftKings (19), FanDuel (23), BetMGM (22), BookMaker (7), BetCRIS (9), Pinnacle (3), Polymarket US (31), Circa Sports (32), Bet105 (33), and Heritage Sports (34). Availability varies by sport and market. On V2 event endpoints (/api/v2/sports/{sportID}/events/{date}, /api/v2/events/{eventID}, and their openers/closing siblings), affiliate_ids=0 is a scores-only sentinel: the response keeps events, scores, and status and omits markets and price objects. Other endpoints that share this parameter treat affiliate_ids as a sportsbook filter only.

sport_ids
string

Comma-separated sport IDs to filter

event_ids
string

Comma-separated event IDs to filter

market_ids
string

Comma-separated market IDs to filter

Response

101

WebSocket upgrade successful