Game duplication in API and website search

Hey there

Noticed around last Thursday or Friday (August 29/30) that the name for the game Z1 Battle Royale was changed back to H1Z1. This is all well and good except that there are a few inconsistencies when trying to fetch information from the API that are also mirrored on Twitch.tv.

Details:
Endpoint: https://api.twitch.tv/helix/games?id=417892&id=511815
Response:

{
    "data": [
        {
            "id": "511815",
            "name": "H1Z1",
            "box_art_url": "https://static-cdn.jtvnw.net/ttv-boxart/H1Z1-{width}x{height}.jpg"
        },
        {
            "id": "417892",
            "name": "H1Z1",
            "box_art_url": "https://static-cdn.jtvnw.net/ttv-boxart/H1Z1-{width}x{height}.jpg"
        }
    ]
}

Endpoint: https://api.twitch.tv/helix/games?name=H1Z1
Response:

{
    "data": [
        {
            "id": "511815",
            "name": "H1Z1",
            "box_art_url": "https://static-cdn.jtvnw.net/ttv-boxart/H1Z1-{width}x{height}.jpg"
        }
    ]
}

So the ID 511815 is clearly the winner, except that the v5 endpoint for top_games is returning results from both IDs.
This can be confirmed by going to https://www.twitch.tv/search?term=h1z1. Clicking on either of the results will bring you to the 511815 version, but the 417892 version is still accessible through https://www.twitch.tv/directory/game/z1%20battle%20royale. I’m surprised the ES query is giving me the right one when I click on them :slight_smile:


Another similar issue I ran into was involving another game: MudRunner
Endpoint: https://api.twitch.tv/helix/games?name=MudRunner
Reponse:

{
    "data": [
        {
            "id": "498821",
            "name": "MudRunner",
            "box_art_url": "https://static-cdn.jtvnw.net/ttv-boxart/MudRunner-{width}x{height}.jpg"
        }
    ]
}

Endpoint: https://api.twitch.tv/helix/games?id=498821
Response:

{
    "data": [
        {
            "id": "498821",
            "name": "Spintires: MudRunner",
            "box_art_url": "https://static-cdn.jtvnw.net/ttv-boxart/./Spintires:%20MudRunner-{width}x{height}.jpg"
        }
    ]
}

Hmm, this seems a little strange as well. Let me double check by calling…
Endpoint: https://api.twitch.tv/helix/games?name=Spintires: MudRunner
Response:

{
    "data": []
}

https://www.twitch.tv/directory/game/mudrunner is the URL that exists on twitch, as Spintires: Mudrunner gives me a 404. I’m just confused why the API would return a game name that it clearly doesn’t have any data for, as evidenced by the api call for the name rather than ID.

Any help or transparency regarding these issues would be greatly appreciated.

Thanks

I can additionally confirm the same behavior as the group "MudRunner" -> 498821 -> "Spintires: MudRunner" -> {} with the following:

"Eden Rising" -> 505640 -> "Eden Rising: Supremacy" -> {}
"Police Simulator: Patrol Duty" -> 498161 -> "Police Simulator 18" -> {}
4211 -> "Solitare" -> {}

/kraken/games/top

{ "game" =>
      { "name" => "MayhemCars",
        "popularity" => 0,
        "_id" => 511641,
        "giantbomb_id" => 72885,
        "box" => { "large" => "https://static-cdn.jtvnw.net/ttv-boxart/MayhemCars-272x380.jpg",
                   "medium" => "https://static-cdn.jtvnw.net/ttv-boxart/MayhemCars-136x190.jpg",
                   "small" => "https://static-cdn.jtvnw.net/ttv-boxart/MayhemCars-52x72.jpg",
                   "template" => "https://static-cdn.jtvnw.net/ttv-boxart/MayhemCars-{width}x{height}.jpg" },
        "logo" => { "large" => "https://static-cdn.jtvnw.net/ttv-logoart/MayhemCars-240x144.jpg",
                    "medium" => "https://static-cdn.jtvnw.net/ttv-logoart/MayhemCars-120x72.jpg",
                    "small" => "https://static-cdn.jtvnw.net/ttv-logoart/MayhemCars-60x36.jpg",
                    "template" => "https://static-cdn.jtvnw.net/ttv-logoart/MayhemCars-{width}x{height}.jpg" },
        "localized_name" => "MayhemCars",
        "locale" => "en-us" },
    "viewers" => 2,
    "channels" => 1
  }

https://api.twitch.tv/helix/games?id=511641

{"data":[{"id":"511641","name":"MayhemCars","box_art_url":"https://static-cdn.jtvnw.net/ttv-boxart/MayhemCars-{width}x{height}.jpg"}]}

https://api.twitch.tv/helix/games?id=512105 or https://api.twitch.tv/helix/games?name=MayhemCars

{"data":[{"id":"512105","name":"MayhemCars","box_art_url":"https://static-cdn.jtvnw.net/ttv-boxart/MayhemCars-{width}x{height}.jpg"}]}
  {
    "game" => {
      "name" => "Forest of Evil",
      "popularity" => 0,
      "_id" => 512760,
      "giantbomb_id" => 73959,
      "box" => { "large" => "https://static-cdn.jtvnw.net/ttv-boxart/Forest%20of%20Evil-272x380.jpg",
                 "medium" => "https://static-cdn.jtvnw.net/ttv-boxart/Forest%20of%20Evil-136x190.jpg",
                 "small" => "https://static-cdn.jtvnw.net/ttv-boxart/Forest%20of%20Evil-52x72.jpg",
                 "template" => "https://static-cdn.jtvnw.net/ttv-boxart/Forest%20of%20Evil-{width}x{height}.jpg" },
      "logo" => { "large" => "https://static-cdn.jtvnw.net/ttv-logoart/Forest%20of%20Evil-240x144.jpg",
                  "medium" => "https://static-cdn.jtvnw.net/ttv-logoart/Forest%20of%20Evil-120x72.jpg",
                  "small" => "https://static-cdn.jtvnw.net/ttv-logoart/Forest%20of%20Evil-60x36.jpg",
                  "template" => "https://static-cdn.jtvnw.net/ttv-logoart/Forest%20of%20Evil-{width}x{height}.jpg" },
      "localized_name" => "Forest of Evil",
      "locale" => "en-us" },
    "viewers" => 1,
    "channels" => 1
  }

https://api.twitch.tv/helix/games?id=512760

{"data":[{"id":"512760","name":"Forest of Evil","box_art_url":"https://static-cdn.jtvnw.net/ttv-boxart/Forest%20of%20Evil-{width}x{height}.jpg"}]}

https://api.twitch.tv/helix/games?id=513163 or https://api.twitch.tv/helix/games?name=Forest of Evil

{"data":[{"id":"513163","name":"Forest of Evil","box_art_url":"https://static-cdn.jtvnw.net/ttv-boxart/Forest%20of%20Evil-{width}x{height}.jpg"}]}

I believe the point is well taken, there is no need to bump your post with new game name/ID mismatches

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.