Skip to content

[Feature] Implement Get Pokemon by ID #1

@sbmsr

Description

@sbmsr

What you need to do

Our API needs to support the ability to get a Pokemon by ID.

Expected behavior

  1. a request to http://localhost:3000/pokemon/482 should return HTTP status 200 and the following JSON body
{
    id: 482,
    name: { english: "Azelf", japanese: "アグノム", chinese: "亚克诺姆", french: "Créfadet" },
    type: ["Psychic"],
    base: { HP: 75, Attack: 125, Defense: 70, "Sp. Attack": 125, "Sp. Defense": 70, Speed: 115 },
}
  1. a request to http://localhost:3000/pokemon/badId should return HTTP status 400 and the following JSON body
{
    error: "Invalid ID"
}
  1. a request to http://localhost:3000/pokemon/999999999 should return HTTP status 404 and the following JSON body
{
    error: "Not found"
}

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions