Skip to content

Sports Channel (WebSocket)

Provide one or more game_id values to start receiving score events for those games. Events include current score, match period, elapsed time, and end-of-game indicators.

Server: wss://ws.openfish.fun/ws/sports


Direction: Client -> Server

FieldTypeRequiredDescription
game_idsarray of stringsYesGame IDs to subscribe to
typestringYesMust be "sports"
{
"game_ids": ["mci-liv-2025-02-03"],
"type": "sports"
}
{
"operation": "subscribe",
"game_ids": ["nyk-bos-2026-04-10"]
}

Server sends ping every 5 seconds. Client must respond with pong within 10 seconds.


Each event describes the current state of a match that the client is tracking.

FieldTypeRequiredDescription
slugstringYesGame identifier (e.g. "mci-liv-2025-02-03")
livebooleanNoWhether the match is in progress
endedbooleanNoWhether the match has ended
scorestringNoCurrent score (e.g. "2-1")
periodstringNoCurrent period (see below)
elapsedstringNoElapsed time ("MM:SS")
last_updatestringNoISO 8601 timestamp
finished_timestampstringNoISO 8601 end time (only for ended matches)
turnstringNoTeam with possession (NFL only)
SportValues
Soccer1H, 2H, HT, FT, PEN
NFLQ1-Q4, HT, OT, FT
NBA/CBBQ1-Q4, HT, OT, FT
MLBTop 1st, Bot 1st, …
Ice HockeyP1, P2, P3, OT, PEN, FT

Sample Message:

{
"slug": "mci-liv-2025-02-03",
"live": true,
"ended": false,
"score": "1-0",
"period": "1H",
"elapsed": "32:15",
"last_update": "2025-02-03T19:50:16.939Z"
}