RoyaleAPI / cr-api

Clash Royale Analytics, Profiles and Insights. We no longer publish a public API. Please use the official API from Supercell.
https://RoyaleAPI.com
167 stars 20 forks source link

royal hogs and giant snowball have no `id ` in /player/:tag["cards"] #375

Closed fourjr closed 5 years ago

fourjr commented 6 years ago

GET https://api.royaleapi.com/player/2P0LYQ

Full response: https://hastebin.com/uqefubequt

fourjr commented 6 years ago
{
    "name": "Royal Hogs",
    "level": 1,
    "maxLevel": 11,
    "count": 1,
    "rarity": "rare",
    "requiredForUpgrade": 2,
    "leftToUpgrade": 1,
    "icon": "https://api-assets.clashroyale.com/cards/300/ASSQJG_MoVq9e81HZzo4bynMnyLNpNJMfSLb3hqydOw.png"
}
{
    "name": "Giant Snowball",
    "level": 1,
    "maxLevel": 13,
    "count": 16,
    "rarity": "common",
    "requiredForUpgrade": 2,
    "leftToUpgrade": -14,
    "icon": "https://api-assets.clashroyale.com/cards/300/7MaJLa6hK9WN2_VIshuh5DIDfGwm0wEv98gXtAxLDPs.png"
}

normally the rarity would be Common or Rare, minor inconsistency which could break applications.

im assuming this is because these data aren't in /constants

fourjr commented 6 years ago

This has been resolved (data is in /constants already) but leaving it open as you might want to improve no-constants behaviour

selfish commented 5 years ago

Actually, even though it's closed now, @fourjr - how would you suggest improving it?