The Pokemon API allows access to a collection of Pokemon data, including retrieval of Pokemon details, listing of Pokemon, and toggling their 'favourite' status.
http://localhost:3001
- URL:
/pokemon
- Method:
GET
- Description: Retrieves a paginated list of Pokemon. Optional
page
query for pagination (3 per page).
- URL:
/pokemon/:id
- Method:
GET
- Description: Fetches details of a specific Pokemon by ID.
- URL Parameters:
id
- ID of the Pokemon.
- URL:
/pokemon/:id/favourite
- Method:
POST
- Description: Toggles the 'favourite' status of a specified Pokemon.
- URL Parameters:
id
- ID of the Pokemon to toggle.
id
: number - Unique identifier.favourite
: boolean - Favourite status.name
: string - Name.image
: string - Image URL.type
: string - Type.abilities
: string[] - Abilities.stats
: Object - Containshp
,attack
,defense
.