# Cat Facts & Breeds API
> Cat trivia and breed data via the open Cat Fact API (catfact.ninja) — no key. The fact endpoint returns a single random cat fact, optionally bounded to a maximum length; the facts endpoint pages through the full fact collection; and the breeds endpoint lists and searches cat breeds with their country, origin, coat and pattern. Real data, with the breed list cached for speed — no key. 4 endpoints. Ideal for pet apps, fun facts widgets, daily-fact bots, quizzes and onboarding delight.

## Authentication
All requests require your oanor API key in the `x-oanor-key` header. Get one at https://www.oanor.com/developer/keys.

```bash
curl -H "x-oanor-key: oanor_live_…" "https://api.oanor.com/catfact-api/..."
```

## Pricing
- **Free** (Free) — 6,800 calls/Mo, 2 req/s
- **Basic** ($6/Mo) — 91,500 calls/Mo, 8 req/s
- **Pro** ($23/Mo) — 554,500 calls/Mo, 20 req/s
- **Mega** ($69/Mo) — 2,710,000 calls/Mo, 50 req/s

## Endpoints

### Cats

#### `GET /v1/breeds` — Cat breeds

**Parameters:**
- `q` (query, optional, string) — Search breed, country, origin or coat Example: `siamese`
- `limit` (query, optional, string) — Max results (1-100, default 25) Example: `25`

**Example:**
```bash
curl -H "x-oanor-key: $KEY" \
  "https://api.oanor.com/catfact-api/v1/breeds?q=siamese&limit=25"
```

**Response:**
```json
{
    "data": {
        "count": 1,
        "total": 1,
        "breeds": [
            {
                "coat": "Short",
                "breed": "Siamese",
                "origin": "Natural",
                "country": "Thailand",
                "pattern": "Colorpoint"
            }
        ]
    },
    "meta": {
        "timestamp": "2026-06-08T09:48:46.859Z",
        "request_id": "f1b85c41-9bef-48a0-927d-8f121b91c23f"
    },
    "status": "ok",
    "message": "Breeds retrieved successfully",
    "success": true
}
```

#### `GET /v1/fact` — A random cat fact

**Parameters:**
- `max_length` (query, optional, string) — Max length of the fact Example: `60`

**Example:**
```bash
curl -H "x-oanor-key: $KEY" \
  "https://api.oanor.com/catfact-api/v1/fact?max_length=60"
```

**Response:**
```json
{
    "data": {
        "fact": "Neutering a cat extends its life span by two or three years.",
        "length": 60
    },
    "meta": {
        "timestamp": "2026-06-08T09:48:47.153Z",
        "request_id": "f53bdea4-d7f3-49ef-904e-375e7bdbae55"
    },
    "status": "ok",
    "message": "Fact retrieved successfully",
    "success": true
}
```

#### `GET /v1/facts` — Page through facts

**Parameters:**
- `limit` (query, optional, string) — Per page (1-100, default 10) Example: `10`
- `page` (query, optional, string) — Page number Example: `1`
- `max_length` (query, optional, string) — Max length

**Example:**
```bash
curl -H "x-oanor-key: $KEY" \
  "https://api.oanor.com/catfact-api/v1/facts?limit=10&page=1"
```

**Response:**
```json
{
    "data": {
        "page": 1,
        "count": 10,
        "facts": [
            {
                "fact": "Unlike dogs, cats do not have a sweet tooth. Scientists believe this is due to a mutation in a key taste receptor.",
                "length": 114
            },
            {
                "fact": "When a cat chases its prey, it keeps its head level. Dogs and humans bob their heads up and down.",
                "length": 97
            },
            {
                "fact": "The technical term for a cat’s hairball is a “bezoar.”",
                "length": 54
            },
            {
                "fact": "A group of cats is called a “clowder.”",
                "length": 38
            },
            {
                "fact": "A cat can’t climb head first down a tree because every claw on a cat’s paw points the same way. To get down from a tree, a cat must back down.",
                "length": 142
            },
            {
                "fact": "Cats make about 100 different sounds. Dogs make only about 10.",
                "length": 62
            },
            {
                "fact": "Every year, nearly four million cats are eaten in Asia.",
                "length": 55
            },
            {
                "fact": "There are more than 500 million domestic cats in the world, with approximately 40 recognized breeds.",
                "length": 100
            },
            {
                "fact": "Approximately 24 ca
…(truncated, see openapi.json for full schema)
```

### Meta

#### `GET /v1/meta` — Spec

**Example:**
```bash
curl -H "x-oanor-key: $KEY" \
  "https://api.oanor.com/catfact-api/v1/meta"
```

**Response:**
```json
{
    "data": {
        "service": "catfact-api",
        "endpoints": {
            "GET /v1/fact": "A single random cat fact (max_length=optional).",
            "GET /v1/meta": "This document.",
            "GET /v1/facts": "Page through the fact collection (limit=, page=, max_length=).",
            "GET /v1/breeds": "Cat breeds with country, origin, coat & pattern (q=search, limit=)."
        },
        "description": "Cat trivia and breed data via the open Cat Fact API (catfact.ninja): pull a single random cat fact (optionally length-bounded), page through the full fact collection, or list and search cat breeds with their country, origin, coat and pattern. Real data, no key."
    },
    "meta": {
        "timestamp": "2026-06-08T09:48:47.503Z",
        "request_id": "eb18e02c-5ce4-43c1-aa6c-6de5854f6f13"
    },
    "status": "ok",
    "message": "Meta",
    "success": true
}
```


---
Marketplace page: https://www.oanor.com/api/catfact-api
OpenAPI spec: https://www.oanor.com/api/catfact-api/openapi.json
