pokeapi icon indicating copy to clipboard operation
pokeapi copied to clipboard

[Request] Colors of Pokemon variants which changes the Pokemon color

Open jonbarrow opened this issue 3 months ago • 4 comments

Currently the API only provides colors for a Pokemon's base species, but does not provide colors for any individual forms/variants. In a lot of cases this is probably fine, but in cases where a form/variant has drastically different colors this doesn't really make a lot of sense

Some examples would be:

  • Alcremie. Listed under the "white" color, but whose shiny variant is black. Additionally the different "flavors" of Alcremie are all different colors
  • Minior. Listed under "brown", but whose different cores are all different colors
  • Charizard. Listed under "red", but whose mega evolution is black/blue

Some real world use cases for this information would be things like an application which changes an elements color to match the color of the currently displayed Pokemon (which is also my usecase)

jonbarrow avatar Sep 10 '25 21:09 jonbarrow

We might need to move the color property in the pokemon from the pokemon-species, right?

Naramsim avatar Sep 11 '25 03:09 Naramsim

Keeping a reference to pokemon_species seems fine imo, since "species" (at least in my interpretation) refers to the baseline default variation of a Pokemon, and in most cases this is enough. So "moving" it seems a little unnecessary, the https://pokeapi.co/api/v2/pokemon-color/ID API can probably stay the same, for backwards compatibility and such

However adding a color property to https://pokeapi.co/api/v2/pokemon-form/ID API would be the ideal solution to this issue I feel. Adding it just to the https://pokeapi.co/api/v2/pokemon/ID API wouldn't be enough since not every form is represented by this API (https://github.com/PokeAPI/pokeapi/issues/1281) and the main issue is that some forms are different colors

How were these color values determined originally? Moving them to the forms API would be most ideal, but there's also significantly more entires to account for there so I'm wondering if this can be automated

jonbarrow avatar Sep 12 '25 18:09 jonbarrow

A few follow up questions actually:

  1. I just saw https://github.com/PokeAPI/pokeapi/issues/326, which seems to imply this data came from Veekun? Is this true? The data does seem to line up, just making sure
  2. Would you be open to changing this if so? There's a handful of entries which don't seem to make a TON of sense imo, though they do make sense by the current documentation. Notably Butterfree is listed as "white", despite it's main body being purple. This lines up with the current documentation of The color listed in the Pokédex is usually the color most apparent or covering each Pokémon's body, but in cases like these it seems odd to classify a Pokemon as a color that isn't part of the "main" body?
  3. If you're willing to change some of these, would you also be willing to expand the color categories? Currently the documentation stats No orange category exists; Pokémon that are primarily orange are listed as red or brown, but I also don't think this makes a ton of sense seeing as there are Pokemon that are justs traight up orange (like Charmander), I feel like this is a remnant of Veekun and there's room for expanding into more categories
  4. https://pokeapi.co/api/v2/pokemon-form?limit=100000 returns all the forms/variations correct? Just making sure since ~1,500 seems rather low

I'm willing to manually go through and reclassify all 1,500+ forms and their shiny/gender variants if need be. I'm going to have to do so regardless anyway since even if this request isn't accepted I still wanted to add this as a feature in my own app. I did experiment with some automated versions of this to varying degrees of success, but nothing I was fully satisfied with

jonbarrow avatar Sep 13 '25 02:09 jonbarrow

I started looking into this again, it turns out one of the issues is that the color data from Veekun is just out of date? I checked the Veekun repo and it looks like it's stale and likely won't get updated (master branch hasn't been touched in 4 years)

So it looks like this will need to be a change made here

In later generations Pokemon forms got their own dex entries and thus their own color categorizations, and some Pokemon were re-classified entirely

Bulbapedia has information on these changes here https://m.bulbapedia.bulbagarden.net/wiki/List_of_Pokémon_by_color (which also correctly categorizes Pokemon like Minior into different colors based on form). For basically all cases the "new color" is what PokeAPI should use, with the exception of "Switch vs Mobile" table for Pokemon HOME, in which case the "Switch" color should be used (I only point this out because Bulbapedia swapped the positions of the columns for that table for some reason, which is a little confusing at a glance)

That being said, this doesn't entirely solve this issue since the data still needs to be exposed per-form in the API, even once the color data is corrected

jonbarrow avatar Nov 22 '25 07:11 jonbarrow