# OCR API
> Extract text from images with optical character recognition in eight languages (English, German, French, Spanish, Italian, Portuguese, Dutch and Turkish). Get the full recognised text with an average confidence score and word and line counts, or word-level results where every word carries its own confidence and bounding box for layout-aware processing. Supply an image by public URL, base64 or a raw binary request body; large images are downscaled automatically before recognition to keep responses fast, and a warm engine keeps latency low after start-up. Pure server-side computation (Tesseract, no third-party upstream, no per-call cloud cost). Ideal for digitising documents and receipts, reading text from photos and screenshots, accessibility, and data-entry automation.

## 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/ocr-api/..."
```

## Pricing
- **Free** (Free) — 2,000 calls/Mo, 1 req/s
- **Basic** ($13/Mo) — 40,000 calls/Mo, 3 req/s
- **Pro** ($34/Mo) — 250,000 calls/Mo, 8 req/s
- **Mega** ($89/Mo) — 1,200,000 calls/Mo, 20 req/s

## Endpoints

### OCR

#### `GET /v1/languages` — Supported OCR languages

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

**Response:**
```json
{
    "data": {
        "count": 8,
        "languages": [
            {
                "code": "eng",
                "name": "English"
            },
            {
                "code": "deu",
                "name": "German"
            },
            {
                "code": "fra",
                "name": "French"
            },
            {
                "code": "spa",
                "name": "Spanish"
            },
            {
                "code": "ita",
                "name": "Italian"
            },
            {
                "code": "por",
                "name": "Portuguese"
            },
            {
                "code": "nld",
                "name": "Dutch"
            },
            {
                "code": "tur",
                "name": "Turkish"
            }
        ]
    },
    "meta": {
        "timestamp": "2026-05-30T22:48:29.088Z",
        "request_id": "582efda3-2377-4cb1-b35e-810db5332469"
    },
    "status": "ok",
    "message": "Languages retrieved",
    "success": true
}
```

#### `GET /v1/ocr` — Recognize text from an image

**Parameters:**
- `url` (query, optional, string) — Image URL (or base64/raw body) Example: `https://example.com/scan.png`
- `base64` (query, optional, string) — Base64 image data
- `lang` (query, optional, string) — eng|deu|fra|spa|ita|por|nld|tur Example: `eng`

**Example:**
```bash
curl -H "x-oanor-key: $KEY" \
  "https://api.oanor.com/ocr-api/v1/ocr?url=https%3A%2F%2Fexample.com%2Fscan.png&lang=eng"
```

#### `GET /v1/words` — Word-level boxes & confidence

**Parameters:**
- `url` (query, optional, string) — Image URL (or base64/raw body)
- `base64` (query, optional, string) — Base64 image data
- `lang` (query, optional, string) — Language code Example: `eng`

**Example:**
```bash
curl -H "x-oanor-key: $KEY" \
  "https://api.oanor.com/ocr-api/v1/words?lang=eng"
```


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