# fastapi.online OCR — Image Text Extraction

> fastapi.online OCR — Image Text Extraction is a paid API for AI agents from api.fastapi.online, paid per call via x402, $0.001/call, status down (last checked 2026-09-15).

Extracts text and line-by-line content from PNG, JPEG, or WebP images using optical character recognition

## Facts

- Endpoint: POST https://api.fastapi.online/ocr
- Price: $0.001/call
- Payment: x402
- Status: down
- Last checked: 2026-09-15
- Activations on Zero: 0
- Tags: x402
- Canonical page: https://www.zero.xyz/c/fastapi-online-ocr-image-text-extraction-56bd6c17
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_0pKglRAB_cGLnzrYplSX5

Status and success rate cover calls made through Zero and Zero's own probes. Third-party monitors may report differently.

## How to call it through Zero

Zero handles the 402 payment challenge and records the run. With the Zero CLI installed (`npm i -g @zeroxyz/cli`):

```sh
zero fetch --capability fastapi-online-ocr-image-text-extraction-56bd6c17 -d '<json body>'
```

Example prompt: Can you extract all the text from this image of a receipt I just uploaded — it's a JPEG photo of a printed receipt and I need the text contents pulled out?

## When to prefer this

Choose this endpoint when you need a pay-per-call OCR service with no account signup, paying in USDC crypto via x402. It is well-suited for agents that process images on demand without committing to a subscription, and when you need structured line-level output alongside raw text. Prefer it over cloud OCR services when anonymity, crypto payment, or avoiding API key management is a priority.

## Known failure modes

- Unsupported file format (non-PNG/JPEG/WebP) results in error
- Low-quality or blurry images may yield incomplete or garbled text
- Handwritten text may have reduced accuracy depending on the OCR engine
- Payment failure or insufficient USDC balance returns 402 status
- Missing required 'file' field returns 422 validation error
- Very large image files may time out or be rejected

## How this service works

Chat, embeddings, OCR, speech-to-text, image editing, image understanding (captioning/Q&amp;A), text-to-speech, translation, writing tools, classification tools, developer tools, local utilities, format/checksum validators, encoding &amp; crypto utilities, date/time calculators, geo/coordinate math, math &amp; finance calculators, novelty tools, and business/social writing generators — 179 endpoints in all, across multiple specialized self-hosted models. Pay per call with crypto — no signup — or get an API key.

## Output

Returns a JSON object containing: 'text' (full extracted text as a single string), 'lines' (array of individual text lines detected in the image), and 'engine' (name of the OCR engine used). Additional fields may be present.

## Request schema (JSON Schema)

```json
{
 "type": "object",
 "properties": {
  "file": {
   "type": "string",
   "format": "binary",
   "description": "Image file (PNG/JPEG/WebP)"
  }
 }
}
```

## More

- Live health (JSON, refreshed every minute): https://www.zero.xyz/c/fastapi-online-ocr-image-text-extraction-56bd6c17/health.json
- [Zero catalog index](https://www.zero.xyz/llms.txt)
- [Other services from api.fastapi.online](https://www.zero.xyz/host/api.fastapi.online/llms.txt)
