Copyable requests
curl
curl -F "file=@scan.png" https://agentmediatools.com/api/ocrPython
import requests
r = requests.post("https://agentmediatools.com/api/ocr", files={"file": open("scan.png","rb")})
print(r.json()["text"])Document OCR API
Free-tier OCR and document text extraction for AI agents. Upload images or PDFs; get plain text, engine, word count via REST and MCP. For embedded PDF text use PDF-to-text.
Working examples
Upload a scan, image, or PDF—or pass a public URL. Local OCR/text extraction returns plain text, engine name, and word/char counts as JSON for LLM and RAG pipelines.
curl -F "file=@scan.png" https://agentmediatools.com/api/ocrimport requests
r = requests.post("https://agentmediatools.com/api/ocr", files={"file": open("scan.png","rb")})
print(r.json()["text"]){"success":true,"text":"Invoice 1042","engine":"tesseract","word_count":2,"char_count":12}Download URLs are temporary. Save results to your own storage when the workflow needs durable retention.
Yes. Upload images or scanned PDFs for OCR. For PDFs that already contain selectable text, prefer PDF-to-text for cleaner extraction.
PDFs use pdftotext or pdf-parse; images use the server Tesseract installation.
The JSON response includes extracted text, engine, word count, and character count.
Image OCR requires Tesseract on the server; the response reports clearly when OCR is unavailable.
One tool now, one integration later
The same Agent Media Tools account connects this operation to the wider Tool API and MCP catalog.