Skip to content

Get pokemon encounter

GET
/api/v2/pokemon/{pokemon_id}/encounters
const url = 'https://pokeapi.co/api/v2/pokemon/1/encounters';
const options = {method: 'GET'};
try {
const response = await fetch(url, options);
const data = await response.json();
console.log(data);
} catch (error) {
console.error(error);
}

Handles Pokemon Encounters as a sub-resource.

pokemon_id
required
integer

A unique integer value identifying the Pokémon.

Examples

Example1
Terminal window
1
Media typeapplication/json
Array<object>
object
location_area
required

The location area the referenced Pokémon can be encountered in.

object
name
required

The name of the referenced resource.

string
<= 200 characters
url
required

The URL of the referenced resource.

string format: uri
version_details
required

A list of versions and encounters with the referenced Pokémon that might happen.

Array<object>
object
version
required

The game version this encounter happens in.

object
name
required

The name of the referenced resource.

string
<= 200 characters
url
required

The URL of the referenced resource.

string format: uri
max_chance
required

The total percentage of all encounter potential.

integer
encounter_details
required

A list of encounters and their specifics.

Array<object>
object
chance
required

Percent chance that this encounter will occur.

integer
condition_values
required

A list of condition values that must be in effect for this encounter to occur.

Array<object>
object
name
required

The name of the referenced resource.

string
<= 200 characters
url
required

The URL of the referenced resource.

string format: uri
max_level
required

The highest level the Pokémon could be encountered at.

integer
method
required

The method by which this encounter happens.

object
name
required

The name of the referenced resource.

string
<= 200 characters
url
required

The URL of the referenced resource.

string format: uri
min_level
required

The lowest level the Pokémon could be encountered at.

integer

Example

Terminal window
[
{
"location_area": {
"name": "cerulean-city-area",
"url": "https://pokeapi.co/api/v2/location-area/281/"
},
"version_details": [
{
"version": {
"name": "yellow",
"url": "https://pokeapi.co/api/v2/version/3/"
},
"max_chance": 100,
"encounter_details": [
{
"min_level": 10,
"max_level": 10,
"chance": 100,
"method": {
"name": "gift",
"url": "https://pokeapi.co/api/v2/encounter-method/18/"
},
"condition_values": [],
"pokemon_details": null
}
]
},
{
"version": {
"name": "lets-go-pikachu",
"url": "https://pokeapi.co/api/v2/version/31/"
},
"max_chance": 100,
"encounter_details": [
{
"min_level": 12,
"max_level": 12,
"chance": 100,
"method": {
"name": "gift",
"url": "https://pokeapi.co/api/v2/encounter-method/18/"
},
"condition_values": [],
"pokemon_details": null
}
]
}
]
},
{
"location_area": {
"name": "pallet-town-area",
"url": "https://pokeapi.co/api/v2/location-area/285/"
},
"version_details": [
{
"version": {
"name": "red",
"url": "https://pokeapi.co/api/v2/version/1/"
},
"max_chance": 100,
"encounter_details": [
{
"min_level": 5,
"max_level": 5,
"chance": 100,
"method": {
"name": "gift",
"url": "https://pokeapi.co/api/v2/encounter-method/18/"
},
"condition_values": [],
"pokemon_details": null
}
]
},
{
"version": {
"name": "blue",
"url": "https://pokeapi.co/api/v2/version/2/"
},
"max_chance": 100,
"encounter_details": [
{
"min_level": 5,
"max_level": 5,
"chance": 100,
"method": {
"name": "gift",
"url": "https://pokeapi.co/api/v2/encounter-method/18/"
},
"condition_values": [],
"pokemon_details": null
}
]
}
]
}
]