{"uid":"cap_TIXIHIjndBGqpYqLTQQLM","slug":"delx-commerce-pdf-ocr-9bdf08a7","name":"Delx Commerce PDF OCR","description":"Pay-per-result APIs for agents. No signup. Exact price. Verifiable delivery. USDC on Base + Solana via x402.","url":"https://commerce.delx.ai/api/v1/x402/pdf-ocr?utm_source=zero.xyz","method":"POST","headers":{},"bodySchema":{"type":"object","properties":{"psm":{"enum":[3,6,11],"type":"integer","default":6,"description":"Tesseract page segmentation mode for machine-printed text."},"max_chars":{"type":"integer","default":200000,"maximum":200000,"minimum":1,"description":"Maximum UTF-8 characters returned; OCR remains bounded."},"max_pages":{"type":"integer","default":10,"maximum":10,"minimum":1,"description":"Maximum PDF pages to render and OCR."},"pdf_base64":{"type":"string","maxLength":5592406,"minLength":1,"description":"One base64-encoded PDF up to 4 MiB decoded; application/pdf data URIs are accepted."},"file_base64":{"type":"string","maxLength":5592406,"minLength":1,"description":"Alias for pdf_base64."}}},"responseSchema":{"type":"json","example":{"psm":6,"text":"--- Page 1 ---\nPrinted text recognized from a scanned PDF","bytes":48210,"chars":51,"model":"tesseract-5+poppler","scope":"pdf_ocr","schema":"delx/ocr/v1","language":"eng","provider":"first-party","truncated":false,"confidence":94.12,"attribution":"Text recognized locally by Delx with Tesseract and Poppler; no document is stored, fetched, or sent to a third-party provider.","document_id":"pdf_ocr_6fd2b8d1b8ddf0f3e9a9b2c4d5e6f708","total_pages":1,"input_sha256":"6fd2b8d1b8ddf0f3e9a9b2c4d5e6f7081234567890abcdef1234567890abcdef","output_sha256":"c5f7b2d4c1e7a0f9b6d2e8c3a4f5b6071234567890abcdef1234567890abcdef","pages_observed":1,"words_observed":9,"sale_price_usdc":0.01,"upstream_cost_usd":0,"gross_margin_floor_usd":0.0095275}},"example":null,"exampleRequest":null,"tags":["x402"],"displayCostAmount":"0.01","displayCostAsset":"USDC","priceDynamic":false,"priceHint":null,"priceStatus":"priced","priceSource":"probe","requiresHandshake":false,"reviewCount":0,"rating":{"score":"0.00","successRate":"0.00","reviews":0,"stars":null,"state":"unrated"},"availabilityStatus":"unknown","priceObserved":null,"sessionDeposit":null,"pricing":{"kind":"static","summary":"$0.01/call","primary":{"kind":"static","protocol":"x402","network":"base","amountUsd":"0.01","per":"call","confidence":"exact"},"accepted":[{"kind":"static","protocol":"x402","network":"base","amountUsd":"0.01","per":"call","confidence":"exact"}]},"paymentMethods":[{"uid":"pm_ybix6tqHROO0bd0c9WnvS","protocol":"x402","methodType":"crypto","chain":"base","mode":"charge","costAmount":"0.01","costPer":"request","priority":0,"asset":"0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913","unit":"request","depositMicros":null,"planRef":null}],"brandName":null,"brandSlug":null,"brandBaseUrl":null,"brandDocsUrl":null,"whatItDoes":"Extracts text from scanned or machine-printed PDFs using Tesseract 5 + Poppler, returning recognized text with confidence score and cryptographic hashes for verifiable delivery","exampleAgentPrompt":"Can you extract all the text from this scanned PDF I'm sending you as a base64 string? Use page segmentation mode 6 and limit it to 10 pages — it's a machine-printed contract.","exampleUseCases":[{"title":"Invoice data extraction for finance automation","prompt":"I have a scanned invoice PDF encoded in base64 — can you OCR it and pull out all the text? Use PSM mode 6 and give me up to 5 pages worth."},{"title":"Legal contract text digitization","prompt":"I've got a scanned legal contract as a base64 PDF. Extract all the text from it using Tesseract OCR, up to 10 pages, so I can search through the clauses."},{"title":"Research paper text extraction","prompt":"This academic paper was scanned and I only have it as a PDF. Can you run OCR on the base64-encoded file and return the recognized text, capped at 50000 characters?"}],"resultDescription":"A JSON object containing: the full recognized text (paginated with page markers), OCR confidence score (0–100), document ID, SHA-256 hashes of input and output for verifiability, page and word counts, language detected, model used (tesseract-5+poppler), truncation flag, and sale price in USDC. No document is stored or sent to third parties.","failureModes":["PDF exceeds 4 MiB decoded size — request rejected","PDF base64 string malformed or not valid PDF — parse error","More than 10 pages requested — capped at maximum","Character limit exceeded — text truncated with truncated:true flag","Non-machine-printed or handwritten text — low confidence score or empty output"],"whenToPreferThis":"Choose this endpoint when you need fast, pay-per-call PDF OCR with no signup, verifiable cryptographic delivery receipts, and privacy guarantees (no document stored or sent to third parties). Ideal for AI agents operating autonomously with USDC micropayments via x402 protocol on Base or Solana. Prefer over subscription OCR services when you need per-result billing and auditability via SHA-256 hashes.","instructions":null,"reviewSummary":null,"reviewSummaryHighlights":null,"reviewSummaryConcerns":null,"reviewSummaryGeneratedAt":null,"activationCount":0,"lastUsedAt":null,"lastSuccessfullyRanAt":null,"lastHealthCheckAt":"2026-10-02T13:06:44.443Z","isFirstParty":false,"canonicalSlug":"delx-commerce-pdf-ocr-9bdf08a7"}