Process Document (Beta)

Beta — endpoint shape and validation rules may evolve before general availability.

Classify and validate an uploaded document. Two modes are supported and exactly one of the two must be present per request:

  • Stateless — inline the document type definition on every call via documentType. Nothing is fetched server-side; the caller owns the config.
  • Stateful — reference a stored DocumentType by id via documentTypeId. The server resolves the record and projects its validation / classification rules onto the classifier request; 404 when the id is unknown, 403 when the record belongs to a different organisation.

Response shape is identical across the two modes.

Recent Requests
Log in to see full request history
TimeStatusUser Agent
Retrieving recent requests…
LoadingLoading…
Body Params

Process Document Request

Request to classify and validate a document. Beta endpoint. Two modes: supply the definition inline via documentType (stateless), or reference a stored DocumentType via documentTypeId (stateful) — exactly one of the two is required. Supply the document itself via documentBase64 (inline) or documentUrl (server downloads); again, exactly one of the two is required. Supported formats: PDF, JPEG, PNG, GIF, WebP, DOC, DOCX. The format is detected server-side from the file's magic bytes, and non-image inputs are converted to an image before classification.

string
length ≥ 1

Base64-encoded document. API Gateway caps the request body at ~6 MB. Required when documentUrl is not supplied; do not send both.

uri

Publicly accessible URL the server can GET the document from. Required when documentBase64 is not supplied; do not send both.

string
length ≥ 1

Candidate name. Required when the validation list contains CHECK_NAME_MATCH; safe to omit otherwise.

uuid

Id of a stored DocumentType to resolve server-side. Mutually exclusive with documentType — exactly one of the two is required. Returns 404 if the id is unknown, 403 if the record belongs to a different organisation.

documentType
object

Inline document type definition. Mirrors the DocumentType resource shape. Supply at least one of validation or classificationRules so the classifier has something to evaluate against. Mutually exclusive with documentTypeId — exactly one of the two is required.

Responses

Language
Credentials
LoadingLoading…
Response
Click Try It! to start a request and see the response here! Or choose an example:
application/json