I’m querying the Get Streams endpoint with a list of game_id
s to get a list of streams playing one of those games.
I’m currently seeing an issue where the streams endpoint is occasionally returning streams with an incorrect game_id
. For instance, when I query game_id=6523
, which should be Boktai: The Sun Is in Your Hand, I instead get a stream with game_id=15257
Hamtaro: Ham-Ham Heartbreak.
curl -H "Authorization: Bearer <snip>" -H "Client-Id: <snip>" -X GET "https://api.twitch.tv/helix/streams?first=100&game_id=6523"
{"data":[{"id":"39452524197","user_id":"<snip>","user_login":"<snip>","user_name":"<snip>","game_id":"15257","game_name":"Hamtaro: Ham-Ham Heartbreak","type":"live","title":"Last Part? - Hamtaro: Ham-Ham Heartbreak Pt. 3 | GBA Madness","viewer_count":1,"started_at":"2023-03-29T15:14:42Z","language":"en","thumbnail_url":"https://static-cdn.jtvnw.net/previews-ttv/live_user_<snip>-{width}x{height}.jpg","tag_ids":[],"tags":["Chilled","VTuber","Eldritch","English"],"is_mature":true}],"pagination":{"cursor":"eyJiIjp7IkN1cnNvciI6ImV5SnpJam94TGpjd05qWXhORGN5TmpNNE56VTNNeXdpWkNJNlptRnNjMlVzSW5RaU9uUnlkV1Y5In0sImEiOnsiQ3Vyc29yIjoiIn19"}}
When it appears, this is 100% reproducible, i.e. if I repeatedly send this query I get the Hamtaro stream every time, as long as that stream is live. Alternatively, if I send a query with the game_id
for Hamtaro instead, I receive the same response (i.e. I don’t receive a Boktai stream instead).
The wrong game which appears seems to vary, though I’ve seen it occur with Hamtaro more than once now.
It even appears wrong on the Twitch website itself, as can be seen here: https://i.imgur.com/mTAOANy.png
The Get Games endpoint seems to behave correctly:
curl -H "Authorization: Bearer <snip>" -H "Client-Id: <snip>" -X GET "https://api.twitch.tv/helix/games?id=6523"
{"data":[{"id":"6523","name":"Boktai: The Sun Is in Your Hand","box_art_url":"https://static-cdn.jtvnw.net/ttv-boxart/6523_IGDB-{width}x{height}.jpg","igdb_id":"6326"}]}
curl -H "Authorization: Bearer <snip>" -H "Client-Id: <snip>" -X GET "https://api.twitch.tv/helix/games?id=15257"
{"data":[{"id":"15257","name":"Hamtaro: Ham-Ham Heartbreak","box_art_url":"https://static-cdn.jtvnw.net/ttv-boxart/15257_IGDB-{width}x{height}.jpg","igdb_id":"6428"}]}
Could this be fixed server-side?