{
  "openapi": "3.1.0",
  "info": {
    "title": "Cats API",
    "version": "1.0.0",
    "description": "67 cat breeds with origin, temperament, lifespan, weight and 1-to-5 trait scores, with images.\n\nDetailed reference data for 67 cat breeds — origin, temperament, life span, weight ranges (kg and lb), and 1–5 behavioural and care trait scores (affection, energy, grooming, vocalisation, child- and dog-friendliness, and more), plus boolean flags and filters for hypoallergenic, hairless, short-legged, indoor and lap breeds. ",
    "contact": {
      "name": "Data and APIs",
      "url": "https://dataandapis.com/contact"
    },
    "termsOfService": "https://dataandapis.com/terms-of-service",
    "license": {
      "name": "Data and APIs Terms of Service",
      "url": "https://dataandapis.com/terms-of-service"
    },
    "x-logo": {
      "url": "https://dataandapis.com/images/cats.webp"
    }
  },
  "externalDocs": {
    "description": "Documentation, live tester and pricing",
    "url": "https://dataandapis.com/apis/cats"
  },
  "servers": [
    {
      "url": "https://api-cats.dataandapis.com"
    }
  ],
  "tags": [
    {
      "name": "Data",
      "description": "Cats API belongs to the Data category of the Data and APIs catalog."
    }
  ],
  "paths": {
    "/v1/breeds/origins": {
      "get": {
        "operationId": "breedOrigins",
        "summary": "Breed Origins",
        "description": "Breed Origins endpoint of the Cats API. Costs 1 token per call.",
        "externalDocs": {
          "url": "https://dataandapis.com/apis/cats/breed-origins"
        },
        "responses": {
          "200": {
            "description": "Successful response",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object"
                },
                "example": {
                  "count": 24,
                  "origins": [
                    {
                      "origin": "United States",
                      "count": 13
                    },
                    {
                      "origin": "United Kingdom",
                      "count": 5
                    },
                    {
                      "origin": "Egypt",
                      "count": 1
                    }
                  ]
                }
              }
            }
          },
          "401": {
            "description": "Missing or invalid API key"
          },
          "402": {
            "description": "Subscription past due; the response carries a payment_url"
          },
          "429": {
            "description": "Monthly token allowance exhausted"
          }
        },
        "security": [
          {
            "ApiKey": []
          }
        ]
      }
    },
    "/v1/breeds/{slug}": {
      "get": {
        "operationId": "getBreed",
        "summary": "Get Breed",
        "description": "Get Breed endpoint of the Cats API. Costs 1 token per call.",
        "externalDocs": {
          "url": "https://dataandapis.com/apis/cats/get-breed"
        },
        "parameters": [
          {
            "name": "slug",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "example": "balinese"
          }
        ],
        "responses": {
          "200": {
            "description": "Successful response",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object"
                },
                "example": {
                  "slug": "abyssinian",
                  "name": "Abyssinian",
                  "altNames": [],
                  "origin": "Egypt",
                  "countryCode": "EG",
                  "temperament": [
                    "Active",
                    "Energetic",
                    "Independent",
                    "Intelligent",
                    "Gentle"
                  ],
                  "lifeSpanYears": {
                    "min": 14,
                    "max": 15
                  },
                  "weightKg": {
                    "min": 3,
                    "max": 5
                  },
                  "weightLb": {
                    "min": 7,
                    "max": 10
                  },
                  "hypoallergenic": false,
                  "rare": false,
                  "hairless": false,
                  "shortLegs": false,
                  "indoor": false,
                  "lap": true,
                  "traits": {
                    "adaptability": 5,
                    "affection": 5,
                    "energy": 5,
                    "grooming": 1,
                    "intelligence": 5,
                    "sheddingLevel": 2,
                    "socialNeeds": 5,
                    "vocalisation": 1,
                    "healthIssues": 2,
                    "childFriendly": 3,
                    "dogFriendly": 4,
                    "strangerFriendly": 5
                  },
                  "description": "The Abyssinian is a cat breed originating from Egypt. It is known for being active, energetic, independent, intelligent and gentle.",
                  "imageUrl": "https://cdn2.thecatapi.com/images/0XYvRd7oD.jpg",
                  "wikipediaUrl": "https://en.wikipedia.org/wiki/Abyssinian_(cat)"
                }
              }
            }
          },
          "401": {
            "description": "Missing or invalid API key"
          },
          "402": {
            "description": "Subscription past due; the response carries a payment_url"
          },
          "429": {
            "description": "Monthly token allowance exhausted"
          }
        },
        "security": [
          {
            "ApiKey": []
          }
        ]
      }
    },
    "/v1/breeds": {
      "get": {
        "operationId": "listBreeds",
        "summary": "List Breeds",
        "description": "List Breeds endpoint of the Cats API. Costs 1 token per call.",
        "externalDocs": {
          "url": "https://dataandapis.com/apis/cats/list-breeds"
        },
        "parameters": [
          {
            "name": "hairless",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string"
            },
            "example": "false"
          },
          {
            "name": "hypoallergenic",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string"
            },
            "example": "true"
          },
          {
            "name": "lap",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string"
            },
            "example": "true"
          },
          {
            "name": "limit",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string"
            },
            "example": "20"
          },
          {
            "name": "origin",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string"
            },
            "example": "Egypt"
          },
          {
            "name": "page",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string"
            },
            "example": "1"
          },
          {
            "name": "q",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string"
            },
            "example": "siamese"
          },
          {
            "name": "temperament",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string"
            },
            "example": "Active"
          }
        ],
        "responses": {
          "200": {
            "description": "Successful response",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object"
                },
                "example": {
                  "total": 67,
                  "page": 1,
                  "limit": 20,
                  "count": 1,
                  "results": [
                    {
                      "slug": "abyssinian",
                      "name": "Abyssinian",
                      "altNames": [],
                      "origin": "Egypt",
                      "countryCode": "EG",
                      "temperament": [
                        "Active",
                        "Energetic",
                        "Independent",
                        "Intelligent",
                        "Gentle"
                      ],
                      "lifeSpanYears": {
                        "min": 14,
                        "max": 15
                      },
                      "weightKg": {
                        "min": 3,
                        "max": 5
                      },
                      "weightLb": {
                        "min": 7,
                        "max": 10
                      },
                      "hypoallergenic": false,
                      "rare": false,
                      "hairless": false,
                      "shortLegs": false,
                      "indoor": false,
                      "lap": true,
                      "traits": {
                        "adaptability": 5,
                        "affection": 5,
                        "energy": 5,
                        "grooming": 1,
                        "intelligence": 5,
                        "sheddingLevel": 2,
                        "socialNeeds": 5,
                        "vocalisation": 1,
                        "healthIssues": 2,
                        "childFriendly": 3,
                        "dogFriendly": 4,
                        "strangerFriendly": 5
                      },
                      "description": "The Abyssinian is a cat breed originating from Egypt. It is known for being active, energetic, independent, intelligent and gentle.",
                      "imageUrl": "https://cdn2.thecatapi.com/images/0XYvRd7oD.jpg",
                      "wikipediaUrl": "https://en.wikipedia.org/wiki/Abyssinian_(cat)"
                    }
                  ]
                }
              }
            }
          },
          "401": {
            "description": "Missing or invalid API key"
          },
          "402": {
            "description": "Subscription past due; the response carries a payment_url"
          },
          "429": {
            "description": "Monthly token allowance exhausted"
          }
        },
        "security": [
          {
            "ApiKey": []
          }
        ]
      }
    },
    "/v1/breeds/random": {
      "get": {
        "operationId": "randomBreeds",
        "summary": "Random Breeds",
        "description": "Random Breeds endpoint of the Cats API. Costs 1 token per call.",
        "externalDocs": {
          "url": "https://dataandapis.com/apis/cats/random-breeds"
        },
        "parameters": [
          {
            "name": "amount",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string"
            },
            "example": "3"
          }
        ],
        "responses": {
          "200": {
            "description": "Successful response",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object"
                },
                "example": {
                  "count": 1,
                  "results": [
                    {
                      "slug": "bengal",
                      "name": "Bengal",
                      "origin": "United States",
                      "temperament": [
                        "Alert",
                        "Agile",
                        "Energetic"
                      ],
                      "lifeSpanYears": {
                        "min": 12,
                        "max": 15
                      },
                      "lap": false
                    }
                  ]
                }
              }
            }
          },
          "401": {
            "description": "Missing or invalid API key"
          },
          "402": {
            "description": "Subscription past due; the response carries a payment_url"
          },
          "429": {
            "description": "Monthly token allowance exhausted"
          }
        },
        "security": [
          {
            "ApiKey": []
          }
        ]
      }
    }
  },
  "components": {
    "securitySchemes": {
      "ApiKey": {
        "type": "apiKey",
        "in": "header",
        "name": "X-Api-Key",
        "description": "Create a free key at https://dataandapis.com/sign-up. 500 tokens a month on the Free plan; this API costs 1 token per call."
      }
    }
  },
  "security": [
    {
      "ApiKey": []
    }
  ]
}