POST /species/identify
Identifies the species in the uploaded photo.
Note that the AI model for species recognition is still in training! For now, name the file after the the species you want to discover, for example “pikachu.jpg”. Lookup the list of species on Wikipedia.
Only generation I species are recognizable.
URL
https://api.pokedexercice.ch/species/identify
Parameters
Name | Validation | Description |
---|---|---|
file | required, file, mimes: jpg ,png ,jpeg ,gif ,svg | An image with the name of the species to discover. |
Return
201 if the species was not yet discovered, 200 if the species was already known
{ id: number; name: string; image: string; types: string[];}
Example
Request
fetch('https://api.pokedexercice.ch/species/identify', { method: 'POST', headers: {'Authorization': `Bearer MY_PERSONAL_TOKEN`}, body: formData // FormData object containing your file});
Response
{ "data": { "id": 25, "name": "Pikachu", "image": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/other/official-artwork/25.png", "types": [ "electric" ] }}