completed (HTTP 200, result included); everything else is queued (HTTP 202) and finishes asynchronously.
Fast-path eligibility: inline text of at most 50 KB (UTF-8) with no webhookUrl. Everything else is queued.
Request
Bearer sk_live_...Optional, 1–255 characters. Returns the existing job if a job with this key was already created. Applies to queued jobs only; fast-path jobs complete inline and are not deduplicated.
Inline text to process, up to 5,000,000 characters. Provide exactly one of
text or fileId.One of
chill, medium, aggressive. Either preset or operations is required.1–10 custom operations, applied in order. See below.
URL to receive
job.completed / job.failed events for this job. Forces the queued path. Requires a plan with webhooks.Presets
Operations
GET /v1/text/presets and GET /v1/text/operations return these definitions as JSON.
Examples
Fast path (inline text)
Queued (uploaded PDF)
Results
One code path handles both: checkstatus. If it’s completed, the result is already in the response. Otherwise poll GET /v1/jobs/:id (ideally with ?wait=25 to long-poll) or wait for the webhook.
Jobs created from inline text return result.outputText; jobs created from a fileId return result.outputUrl pointing to a .txt file. PDFs have their text extracted before processing.