メインコンテンツまでスキップ

Categories

Explore categorised image collections.

List Categories​

Retrieve a list of available categories (e.g., Hats, Space, Sunglasses).

curl -H "x-api-key: YOUR-API-KEY" https://api.thedogapi.com/v1/categories

Example Response​

[
{
"id": 5,
"name": "boxes",
"species_id": "2"
},
{
"id": 15,
"name": "clothes",
"species_id": "2"
}
]

Get Category Details​

curl -H "x-api-key: YOUR-API-KEY" https://api.thedogapi.com/v1/categories/5

Filter images by category​

Pass one or more category IDs to the image search to get images from those collections:

curl -H "x-api-key: YOUR-API-KEY" "https://api.thedogapi.com/v1/images/search?category_ids=5&limit=5"