WebSocket API

WebSocket API — one connection, everything streamed live

Orbistats' WebSocket API opens a single persistent connection and streams live scores, match events and odds moves the instant they happen — sub-50ms, no polling loop, no wasted requests. Built for trading desks and live products where a request-response cycle is too slow.

stream.orbistats.com — zsh
Connected — wss://stream.orbistats.com/v1/live
Latency: 38ms
Subscribed: footballcricket
Not a screenshot. This connection is actually running, right now, in your browser.
What's Included

Everything in the WebSocket stream

Included

Persistent Connection

One socket, continuous live updates.

Included

Sub-50ms Delivery

Built for time-sensitive pricing and trading use cases.

Included

Channel Subscriptions

Subscribe to specific leagues, matches or odds markets.

Reliability

Auto-Reconnect

Client libraries handle reconnects and resubscribes for you.

Included

Heartbeats

Ping/pong frames keep the connection alive and detectable.

Coverage

10 Sports, One Protocol

Same message format across every sport we cover.

Authentication

Authenticate on connect

Pass your API key as a query parameter when opening the socket — the connection is rejected if it's missing or invalid.

CONNECT wss://stream.orbistats.com/v1?api_key=YOUR_API_KEY
Subscribing
WS wss://stream.orbistats.com/v1

Subscribe to a channel

Once connected, send a subscribe message to start receiving events for that channel.

Message Fields
FieldTypeRequiredDescription
actionstringRequiredsubscribe or unsubscribe.
channelstringRequiredChannel name, e.g. football.live.
leaguestringOptionalLimit the channel to a single league.
match_idstringOptionalLimit the channel to a single match.
Example Subscribe Message
SUBSCRIBE wss://stream.orbistats.com/v1
{
  "action": "subscribe",
  "channel": "football.live",
  "league": "premier-league"
}
Example Message Received
{
  "channel": "football.live",
  "event": "match.goal",
  "match_id": 48213,
  "minute": 72,
  "team": "Manchester City",
  "timestamp": "2026-09-14T16:12:03.184Z"
}
Connection Handling

Close codes & reconnecting

1000Normal closure — reconnect whenever you're ready.
4001Invalid or missing API key.
4008Rate limit exceeded for your plan.
1006Abnormal closure — reconnect with exponential backoff.
Rate Limits

Concurrent connections by plan

Free

2 connections

Enough to build and test against real data.

Starter

10 connections

For live products in production.

Growth & Enterprise

Custom limits

Talk to us for volume pricing and dedicated capacity.

Channels

Unlimited per connection

Subscribe to as many channels as you need on one socket.

Code Examples

Connect from any language

Official SDKs cover Python, JavaScript and PHP — every other language works over standard WebSocket.

cURL
Python
JavaScript
wscat -c "wss://stream.orbistats.com/v1?api_key=YOUR_API_KEY"
See Also

Related products & sports

Prefer push-on-event instead of holding a connection open? Or jump straight to a sport-specific page.

Get Started

Start free. Upgrade when you need enterprise SLAs.

Self-serve API keys for developers today — dedicated infrastructure, custom feeds and SLAs when you're ready.