Extract data from a document
mindee_extract_documentSubmit a document (PDF or image) to a Mindee extraction model and return the structured fields. Provide EITHER document_url (a public URL) OR file_base64 (+ filename). This enqueues an inference and polls until it completes (up to ~30s); if it is still processing it returns a job_id you can poll with mindee_get_job then read with mindee_get_inference. NOTE: consumes Mindee API credits (paid, billed per page). V2 API: POST /v2/inferences/enqueue.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| rag | No | Enable Retrieval-Augmented Generation for the model, if configured. | |
| alias | No | Your own reference tag echoed back in the job/result. | |
| polygon | No | Return bounding-box polygons for fields. | |
| filename | No | Filename for file_base64 uploads, e.g. 'invoice.pdf'. | |
| model_id | Yes | Extraction model id (from mindee_list_models). | |
| raw_text | No | Also return the full OCR raw text of the document. | |
| confidence | No | Return per-field confidence levels (Certain/High/Medium/Low). | |
| file_base64 | No | Base64-encoded document bytes. Use this OR document_url; set `filename` too. | |
| webhook_ids | No | Webhook ids to notify on completion (async flows). | |
| document_url | No | Public URL of the document to process. Use this OR file_base64. |