Sport Events Life Cycle

Documentation on websocket messages for sport event changes, including listing, unlisting, and re-listing events.

Here is a document on what websocket messages get pushed out through websocket for different changes related to sport events.

To summarize, different events will be pushed under the topic “tournament_xxx” when a sport event is listed, unlisted, or re-listed through the broadcast channel.

When an event is initially created and listed on site, an event of “op” = “c” gets sent out.

For all other cases where an event is listed or re-listed, the “op” = “u”.

When an event is unlisted, the “op” = “d”.

More details

  • Event created — not listed: No message

  • Event created — listed: change_type sport_event, topic tournament_xxx
    Sample message: { "change_type": "sport_event", "op": "c", "payload": "eyJpZCI6IjE1MDAwOTAxNTAiLCJ0b3VybmFtZW50X2lkIjoiMTYwMDAwMDA3MyIsImluZm8iOnsibmFtZSI6InRlcyBYYW5kZXIgU2NoYXVmZmVsZSB0byBXaW4iLCJkaXNwbGF5X25hbWUiOiIiLCJ0eXBlIjoiY3VzdG9tIiwiZXZlbnRfaWQiOjE1MDAwOTAxNTAsInNwb3J0X25hbWUiOiJHb2xmIiwidG91cm5hbWVudF9uYW1lIjoiVHJhdmVsZXJzIENoYW1waW9uc2hpcCIsInRvdXJuYW1lbnRfaWQiOjE2MDAwMDAwNzMsImNvbXBldGl0b3JzIjpbXSwic3RhdHVzIjoibm90X3N0YXJ0ZWQiLCJzY2hlZHVsZWQiOiIyMDIzLTA2LTI1VDIyOjAwOjAwWiIsInVwZGF0ZWRfYXQiOjE2ODcyNzgwMTkxOTkwNjczNjB9fQ==", "timestamp": 1687278019324319700 }

    Sample payload decoded: { "id": "1500090150", "tournament_id": "1600000073", "info": { "name": "tes Xander Schauffele to Win", "display_name": "", "type": "custom", "event_id": 1500090150, "sport_name": "Golf", "tournament_name": "Travelers Championship", "tournament_id": 1600000073, "competitors": [], "status": "not_started", "scheduled": "2023-06-25T22:00:00Z", "updated_at": 1687278019199067400 } }

  • Event listed/re-listed (after created): change_type sport_event, topic tournament_xxx
    Sample message: { "change_type": "sport_event", "op": "u", "payload": "eyJpZCI6IjE1MDAwMDAxNDQiLCJ0b3VybmFtZW50X2lkIjoiMTUwMDAwMDA2MCIsImluZm8iOnsibmFtZSI6Ik5vdmEgdGVzdDIiLCJkaXNwbGF5X25hbWUiOiIiLCJ0eXBlIjoiY3VzdG9tIiwiZXZlbnRfaWQiOjE1MDAwMDAxNDQsInNwb3J0X25hbWUiOiJCYXNrZXRiYWxsIiwidG91cm5hbWVudF9uYW1lIjoiVG91cm5hbWVudCBUZXN0IE5vdmExIiwidG91cm5hbWVudF9pZCI6MTUwMDAwMDA2MCwiY29tcGV0aXRvcnMiOlt7ImlkIjoxNjAwMDAwMDUwLCJuYW1lIjoiWWVzIiwiZGlzcGxheV9uYW1lIjoiWWVzIiwiYWJicmV2aWF0aW9uIjoiWWVzIiwic2lkZSI6ImhvbWUifSx7ImlkIjoxNjAwMDAwMDUxLCJuYW1lIjoiTm8iLCJkaXNwbGF5X25hbWUiOiJObyIsImFiYnJldmlhdGlvbiI6Ik5vIiwic2lkZSI6ImF3YXkifV0sInN0YXR1cyI6Im5vdF9zdGFydGVkIiwic2NoZWR1bGVkIjoiMjAyMy0wNC0yNVQxNzo0NjoyNFoiLCJ1cGRhdGVkX2F0IjoxNjg2NzYzMzAxNjY0OTQyNjY5fX0=", "timestamp": 1686763301998473000 }

    Sample payload decoded: { "id": "1500000144", "tournament_id": "1500000060", "info": { "name": "Nova test2", "display_name": "", "type": "custom", "event_id": 1500000144, "sport_name": "Basketball", "tournament_name": "Tournament Test Nova1", "tournament_id": 1500000060, "competitors": [ { "id": 1600000050, "name": "Yes", "display_name": "Yes", "abbreviation": "Yes", "side": "home" }, { "id": 1600000051, "name": "No", "display_name": "No", "abbreviation": "No", "side": "away" } ], "status": "not_started", "scheduled": "2023-04-25T17:46:24Z", "updated_at": 1686582406275919600 } }

  • Event unlisted: change_type sport_event, topic tournament_xxx
    Sample message: { "change_type": "sport_event", "op": "d", "payload": "eyJpZCI6IjE1MDAwOTAxNTAiLCJ0b3VybmFtZW50X2lkIjoiMTYwMDAwMDA3MyJ9", "timestamp": 1687278241642408700 }

    Sample payload decoded: { "id": "1500090150", "tournament_id": "1600000073" }