Get pet profiles using filters

This operation retrieves pets profiles that match the specified filter criteria.

Endpoint structure

GET /pets?{query_parameters}

Path parameters

This operation doesn’t require path parameters.

Query parameters

This operation accepts the following optional query parameters to filter results:

Parameter Type Description
species string Filter pets by species, cat
status string Filter pets by adoption status, available
breed string Filter pets by breed
size string Filter pets by size category, small
gender string Filter pets by gender
shelter_id integer Filter pets by shelter ID

Request headers

Header Value Required
Content-Type application/json No

Request body

This operation doesn’t require a request body.

cURL request

curl -X GET {base_url}/pets?species=cat&status=available

Example responses

Response: 200 OK - with a match

[
  {
    "name": "Luna",
    "species": "cat",
    "breed": "Domestic Shorthair",
    "age_months": 18,
    "gender": "female",
    "size": "small",
    "temperament": "playful, affectionate",
    "medical": {
      "spayed_neutered": true,
      "vaccinations": ["fvrcp", "rabies"]
    },
    "description": "Luna is a playful tabby who loves interactive
                   toys and sunny windows.",
    "shelter_id": 1,
    "status": "available",
    "intake_date": "2025-09-01",
    "id": 1
  }
]

Response : 200 OK - without any matches

{
  []
}

Response : 400 Bad Request - malformed query parameters

{
  "error": "Bad Request",
  "message": "Invalid query parameter format",
  "status": 400
}

Successful responses includes a list of pets with the following: