Pull specific fields from a document into a typed schema.
Accepts exactly one of: a file upload (multipart/form-data), a document URL (JSON body), or a file_id referencing an already-ingested document (from POST /v3/files), plus a JSON Schema (the schema field) describing what to extract.
Sync mode (default)
Blocks until extraction completes and returns 200 with the full result.
schema is the JSON Schema that drives extraction. It arrives as a dict
on JSON requests and as a JSON-encoded string on multipart requests — both
are coerced to dict.
options is a free-form dict; currently supports {"async": bool}.
schema
Schema · object
required
document
string | null
file_id
integer | null
options
Options · object
Response
Extraction completed (sync mode).
id
string
required
status
string
required
created_at
string<date-time> | null
completed_at
string<date-time> | null
processing_time_ms
integer | null
document
ExtractDocument · object | null
Show child attributes
result
ExtractResult · object | null
Show child attributes
usage
ExtractUsage · object | null
Show child attributes
progress
JobProgress · object | null
Live progress of a long-running async job while it is in flight.
Shared by the parse (GET /api/v3/parse/<id>) and extract
(GET /api/v3/extract/<id>) polling envelopes: pages_processed is the
count of pages done so far and percentage is the completion percentage
[0, 100] derived from it.
Show child attributes
{"docsConfig":{"theme":"mint","$schema":"https://mintlify.com/docs.json","name":"LightOn Developers","colors":{"primary":"#1f99bb","light":"#1f99bb","dark":"#1f99bb"},"logo":{"light":"https://mintcdn.com/lighton-developers/dojq_qF_vSGGGm4-/logo/light.svg?fit=max\u0026auto=format\u0026n=dojq_qF_vSGGGm4-\u0026q=85\u0026s=345d3b10124f99971a7737a9f06f2886","dark":"https://mintcdn.com/lighton-developers/dojq_qF_vSGGGm4-/logo/dark.svg?fit=max\u0026auto=format\u0026n=dojq_qF_vSGGGm4-\u0026q=85\u0026s=d1c2d4800c07667359bb3abf2437e7aa"},"favicon":"https://mintcdn.com/lighton-developers/p54dDELPycbNT9ym/favicon.svg?fit=max\u0026auto=format\u0026n=p54dDELPycbNT9ym\u0026q=85\u0026s=c9a4897b47f6d0e0d035509f82d5c847","navbar":{"primary":{"type":"button","label":"Console","href":"https://console.lighton.ai"}},"footer":{"socials":{"x":"https://x.com/lightonio","linkedin":"https://www.linkedin.com/company/lighton","bluesky":"https://bsky.app/profile/lightonai.bsky.social","youtube":"https://www.youtube.com/@lighton4013","website":"https://lighton.ai/newsletter"}},"contextual":{"options":["copy","view","chatgpt","claude","perplexity","mcp","cursor","vscode"],"display":"header"},"styling":{"latex":false},"navigation":{"global":{"anchors":[{"anchor":"Playground","icon":"circle-play","href":"https://console.lighton.ai"}]},"pages":[]}},"deployment":{"deploymentMetadataValue":{"subdomain":"lighton-developers","hasAudioNarration":false,"actualSubdomain":"lighton-developers","customDomains":["developers.lighton.ai"],"gitSource":{"type":"github","owner":"lightonai","repo":"lighton-developers-documentation","deployBranch":"main","contentDirectory":"","isPrivate":true,"mountPath":"","label":""},"entitlements":{"AI_CHAT":{"status":"DISABLED"},"WEB_MCP":{"status":"DISABLED"},"NARRATION":{"status":"DISABLED"}},"buildId":"6ae0d933663d8e17af01bd02","clientVersion":"0.0.4263","searchFilterCounts":[{"language":"default","tag":"API Reference","count":50},{"language":"default","tag":"Intelligence","count":30},{"language":"default","tag":"Tutorials","count":15},{"language":"default","tag":"Facets","count":14},{"language":"default","tag":"Administration","count":13},{"language":"default","tag":"MCP Server","count":9},{"language":"default","tag":"Integrations","count":8},{"language":"default","tag":"Classify and organise documents","count":8},{"language":"default","tag":"Workspaces","count":8},{"language":"default","tag":"Budget","count":8}]},"assistantConfig":{"enableAskAiButton":false,"enableStarterQuestions":false,"enableContextualStarterQuestions":false,"enableAskAiSearchBar":true,"deflection":{"enabled":true,"email":"support@lighton.ai"}},"basePath":"","hasChatPermissions":false,"hasWebMcpPermissions":false,"toggles":[{"name":"kill-isr","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"custom-rbac-roles","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"agent-mintlify-slack","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"agent-integrations-settings","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"rbac-expansion","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"automations-pr-grouping","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"custom-prefix","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"analytics-v7","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"user-flows-analytics","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"no-publish-flow","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"workos-onboarding","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"snapshot-serving-live","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"stripTemperatureMiddleware","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"support-platform-pylon-zendesk","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"snapshot-serving","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"instant-rollback","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"granular-notifications-server","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"granular-notifications","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"automations-fable","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"fixed-ai-action-pricing","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"site-roles","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"automation-resolve-merge-conflict","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"scoped-publishing","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"mintql","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"page-level-analytics","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"editor-version-history-v2","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"billing-page-v2","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"full-page-search","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"workspace-projects","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"assistant-v5","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"fork-pr-previews","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"revalidation-jwt","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"workos-sso-scim","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"hobby-abuse-scan","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"dashboard-inbox","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"workos-signup","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"turbopuffer-dual-write","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"workos-enabled","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"approve-review-flow","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"editor-metadata","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"sso-setup-deadline-banner","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"turbopuffer-serve","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"live-agents","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"starter-pricing","enabled":true,"variant":{"name":"control","enabled":true,"payload":{"type":"string","value":"control"},"feature_enabled":true},"impressionData":false},{"name":"llms-txt-v2","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"wildcard-email-auth","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false}],"googleFontsInlined":false},"customCss":[]}
{"page":{"pagePath":"api-reference/extract/extract-structured-data-from-a-document","slug":"/api-reference/extract/extract-structured-data-from-a-document","pageMetadata":{"title":"Extract structured data from a document","description":"Pull specific fields from a document into a typed schema.\n\nAccepts exactly one of: a **file upload** (multipart/form-data), a **document URL** (JSON body), or a **`file_id`** referencing an already-ingested document (from `POST /v3/files`), plus a **JSON Schema** (the `schema` field) describing what to extract.\n\n### Sync mode (default)\nBlocks until extraction completes and returns **200** with the full result.\n\n```bash\ncurl -X POST https://api.lighton.ai/api/v3/extract \\\n -H 'Authorization: Bearer $TOKEN' \\\n -F file=@invoice.pdf \\\n -F 'schema={\"type\":\"object\",\"properties\":{\"invoice_number\":{\"type\":\"string\"}}}'\n```\n\n### Async mode (`options.async = true`)\nReturns **202** immediately with an `ext_\u003ctoken>` job id. Poll `GET /api/v3/extract/{id}` with that same id until `status` is `completed` or `failed`.\n\n```bash\ncurl -X POST https://api.lighton.ai/api/v3/extract \\\n -H 'Authorization: Bearer $TOKEN' \\\n -H 'Content-Type: application/json' \\\n -d '{\"document\": \"https://example.com/report.pdf\", \"schema\": {\"type\": \"object\", \"properties\": {\"title\": {\"type\": \"string\"}}}, \"options\": {\"async\": true}}'\n```\n\nFor multipart uploads, pass `options` as a JSON-encoded form field: `-F 'options={\"async\":true}'`.\n\n**Supported file types:** `.pdf`, `.png`, `.jpg`, `.jpeg`, `.pptx`, `.ppt`, `.odp`, `.docx`, `.odt`, `.doc`, `.html`\n\n**Sync limits:** 20 MB file size, 15 pages.\n\n**Async limits:** 100 MB file size, 1000 pages.","deprecated":null,"version":null,"openapi":"/api-reference/api-console.yaml post /api/v3/extract","href":"/api-reference/extract/extract-structured-data-from-a-document","autogeneratedByOpenApi":true},"description":{"compiledSource":"\"use strict\";\nconst {Fragment: _Fragment, jsx: _jsx, jsxs: _jsxs} = arguments[0];\nconst {useMDXComponents: _provideComponents} = arguments[0];\nfunction _createMdxContent(props) {\n const _components = {\n code: \"code\",\n h3: \"h3\",\n p: \"p\",\n pre: \"pre\",\n span: \"span\",\n strong: \"strong\",\n ..._provideComponents(),\n ...props.components\n }, {CodeBlock} = _components;\n if (!CodeBlock) _missingMdxReference(\"CodeBlock\", true);\n return _jsxs(_Fragment, {\n children: [_jsx(_components.p, {\n children: \"Pull specific fields from a document into a typed schema.\"\n }), \"\\n\", _jsxs(_components.p, {\n children: [\"Accepts exactly one of: a \", _jsx(_components.strong, {\n children: \"file upload\"\n }), \" (multipart/form-data), a \", _jsx(_components.strong, {\n children: \"document URL\"\n }), \" (JSON body), or a \", _jsx(_components.strong, {\n children: _jsx(_components.code, {\n children: \"file_id\"\n })\n }), \" referencing an already-ingested document (from \", _jsx(_components.code, {\n children: \"POST /v3/files\"\n }), \"), plus a \", _jsx(_components.strong, {\n children: \"JSON Schema\"\n }), \" (the \", _jsx(_components.code, {\n children: \"schema\"\n }), \" field) describing what to extract.\"]\n }), \"\\n\", _jsx(_components.h3, {\n children: \"Sync mode (default)\"\n }), \"\\n\", _jsxs(_components.p, {\n children: [\"Blocks until extraction completes and returns \", _jsx(_components.strong, {\n children: \"200\"\n }), \" with the full result.\"]\n }), \"\\n\", _jsx(CodeBlock, {\n numberOfLines: \"4\",\n language: \"shellscript\",\n children: _jsx(_components.pre, {\n className: \"shiki shiki-themes github-light-default dark-plus\",\n style: {\n backgroundColor: \"#ffffff\",\n \"--shiki-dark-bg\": \"#0B0C0E\",\n color: \"#1f2328\",\n \"--shiki-dark\": \"#D4D4D4\"\n },\n language: \"shellscript\",\n children: _jsxs(_components.code, {\n language: \"shellscript\",\n numberOfLines: \"4\",\n children: [_jsxs(_components.span, {\n className: \"line\",\n children: [_jsx(_components.span, {\n style: {\n color: \"#953800\",\n \"--shiki-dark\": \"#DCDCAA\"\n },\n children: \"curl\"\n }), _jsx(_components.span, {\n style: {\n color: \"#0550AE\",\n \"--shiki-dark\": \"#569CD6\"\n },\n children: \" -X\"\n }), _jsx(_components.span, {\n style: {\n color: \"#0A3069\",\n \"--shiki-dark\": \"#CE9178\"\n },\n children: \" POST\"\n }), _jsx(_components.span, {\n style: {\n color: \"#0A3069\",\n \"--shiki-dark\": \"#CE9178\"\n },\n children: \" https://api.lighton.ai/api/v3/extract\"\n }), _jsx(_components.span, {\n style: {\n color: \"#CF222E\",\n \"--shiki-dark\": \"#D7BA7D\"\n },\n children: \" \\\\\"\n })]\n }), \"\\n\", _jsxs(_components.span, {\n className: \"line\",\n children: [_jsx(_components.span, {\n style: {\n color: \"#0550AE\",\n \"--shiki-dark\": \"#569CD6\"\n },\n children: \" -H\"\n }), _jsx(_components.span, {\n style: {\n color: \"#0A3069\",\n \"--shiki-dark\": \"#CE9178\"\n },\n children: \" 'Authorization: Bearer $TOKEN'\"\n }), _jsx(_components.span, {\n style: {\n color: \"#CF222E\",\n \"--shiki-dark\": \"#D7BA7D\"\n },\n children: \" \\\\\"\n })]\n }), \"\\n\", _jsxs(_components.span, {\n className: \"line\",\n children: [_jsx(_components.span, {\n style: {\n color: \"#0550AE\",\n \"--shiki-dark\": \"#569CD6\"\n },\n children: \" -F\"\n }), _jsx(_components.span, {\n style: {\n color: \"#0A3069\",\n \"--shiki-dark\": \"#CE9178\"\n },\n children: \" file=@invoice.pdf\"\n }), _jsx(_components.span, {\n style: {\n color: \"#CF222E\",\n \"--shiki-dark\": \"#D7BA7D\"\n },\n children: \" \\\\\"\n })]\n }), \"\\n\", _jsxs(_components.span, {\n className: \"line\",\n children: [_jsx(_components.span, {\n style: {\n color: \"#0550AE\",\n \"--shiki-dark\": \"#569CD6\"\n },\n children: \" -F\"\n }), _jsx(_components.span, {\n style: {\n color: \"#0A3069\",\n \"--shiki-dark\": \"#CE9178\"\n },\n children: \" 'schema={\\\"type\\\":\\\"object\\\",\\\"properties\\\":{\\\"invoice_number\\\":{\\\"type\\\":\\\"string\\\"}}}'\"\n })]\n }), \"\\n\"]\n })\n })\n }), \"\\n\", _jsxs(_components.h3, {\n children: [\"Async mode (\", _jsx(_components.code, {\n children: \"options.async = true\"\n }), \")\"]\n }), \"\\n\", _jsxs(_components.p, {\n children: [\"Returns \", _jsx(_components.strong, {\n children: \"202\"\n }), \" immediately with an \", _jsx(_components.code, {\n children: \"ext_\u003ctoken>\"\n }), \" job id. Poll \", _jsx(_components.code, {\n children: \"GET /api/v3/extract/{id}\"\n }), \" with that same id until \", _jsx(_components.code, {\n children: \"status\"\n }), \" is \", _jsx(_components.code, {\n children: \"completed\"\n }), \" or \", _jsx(_components.code, {\n children: \"failed\"\n }), \".\"]\n }), \"\\n\", _jsx(CodeBlock, {\n numberOfLines: \"4\",\n language: \"shellscript\",\n children: _jsx(_components.pre, {\n className: \"shiki shiki-themes github-light-default dark-plus\",\n style: {\n backgroundColor: \"#ffffff\",\n \"--shiki-dark-bg\": \"#0B0C0E\",\n color: \"#1f2328\",\n \"--shiki-dark\": \"#D4D4D4\"\n },\n language: \"shellscript\",\n children: _jsxs(_components.code, {\n language: \"shellscript\",\n numberOfLines: \"4\",\n children: [_jsxs(_components.span, {\n className: \"line\",\n children: [_jsx(_components.span, {\n style: {\n color: \"#953800\",\n \"--shiki-dark\": \"#DCDCAA\"\n },\n children: \"curl\"\n }), _jsx(_components.span, {\n style: {\n color: \"#0550AE\",\n \"--shiki-dark\": \"#569CD6\"\n },\n children: \" -X\"\n }), _jsx(_components.span, {\n style: {\n color: \"#0A3069\",\n \"--shiki-dark\": \"#CE9178\"\n },\n children: \" POST\"\n }), _jsx(_components.span, {\n style: {\n color: \"#0A3069\",\n \"--shiki-dark\": \"#CE9178\"\n },\n children: \" https://api.lighton.ai/api/v3/extract\"\n }), _jsx(_components.span, {\n style: {\n color: \"#CF222E\",\n \"--shiki-dark\": \"#D7BA7D\"\n },\n children: \" \\\\\"\n })]\n }), \"\\n\", _jsxs(_components.span, {\n className: \"line\",\n children: [_jsx(_components.span, {\n style: {\n color: \"#0550AE\",\n \"--shiki-dark\": \"#569CD6\"\n },\n children: \" -H\"\n }), _jsx(_components.span, {\n style: {\n color: \"#0A3069\",\n \"--shiki-dark\": \"#CE9178\"\n },\n children: \" 'Authorization: Bearer $TOKEN'\"\n }), _jsx(_components.span, {\n style: {\n color: \"#CF222E\",\n \"--shiki-dark\": \"#D7BA7D\"\n },\n children: \" \\\\\"\n })]\n }), \"\\n\", _jsxs(_components.span, {\n className: \"line\",\n children: [_jsx(_components.span, {\n style: {\n color: \"#0550AE\",\n \"--shiki-dark\": \"#569CD6\"\n },\n children: \" -H\"\n }), _jsx(_components.span, {\n style: {\n color: \"#0A3069\",\n \"--shiki-dark\": \"#CE9178\"\n },\n children: \" 'Content-Type: application/json'\"\n }), _jsx(_components.span, {\n style: {\n color: \"#CF222E\",\n \"--shiki-dark\": \"#D7BA7D\"\n },\n children: \" \\\\\"\n })]\n }), \"\\n\", _jsxs(_components.span, {\n className: \"line\",\n children: [_jsx(_components.span, {\n style: {\n color: \"#0550AE\",\n \"--shiki-dark\": \"#569CD6\"\n },\n children: \" -d\"\n }), _jsx(_components.span, {\n style: {\n color: \"#0A3069\",\n \"--shiki-dark\": \"#CE9178\"\n },\n children: \" '{\\\"document\\\": \\\"https://example.com/report.pdf\\\", \\\"schema\\\": {\\\"type\\\": \\\"object\\\", \\\"properties\\\": {\\\"title\\\": {\\\"type\\\": \\\"string\\\"}}}, \\\"options\\\": {\\\"async\\\": true}}'\"\n })]\n }), \"\\n\"]\n })\n })\n }), \"\\n\", _jsxs(_components.p, {\n children: [\"For multipart uploads, pass \", _jsx(_components.code, {\n children: \"options\"\n }), \" as a JSON-encoded form field: \", _jsx(_components.code, {\n children: \"-F 'options={\\\"async\\\":true}'\"\n }), \".\"]\n }), \"\\n\", _jsxs(_components.p, {\n children: [_jsx(_components.strong, {\n children: \"Supported file types:\"\n }), \" \", _jsx(_components.code, {\n children: \".pdf\"\n }), \", \", _jsx(_components.code, {\n children: \".png\"\n }), \", \", _jsx(_components.code, {\n children: \".jpg\"\n }), \", \", _jsx(_components.code, {\n children: \".jpeg\"\n }), \", \", _jsx(_components.code, {\n children: \".pptx\"\n }), \", \", _jsx(_components.code, {\n children: \".ppt\"\n }), \", \", _jsx(_components.code, {\n children: \".odp\"\n }), \", \", _jsx(_components.code, {\n children: \".docx\"\n }), \", \", _jsx(_components.code, {\n children: \".odt\"\n }), \", \", _jsx(_components.code, {\n children: \".doc\"\n }), \", \", _jsx(_components.code, {\n children: \".html\"\n })]\n }), \"\\n\", _jsxs(_components.p, {\n children: [_jsx(_components.strong, {\n children: \"Sync limits:\"\n }), \" 20 MB file size, 15 pages.\"]\n }), \"\\n\", _jsxs(_components.p, {\n children: [_jsx(_components.strong, {\n children: \"Async limits:\"\n }), \" 100 MB file size, 1000 pages.\"]\n })]\n });\n}\nfunction MDXContent(props = {}) {\n const {wrapper: MDXLayout} = {\n ..._provideComponents(),\n ...props.components\n };\n return MDXLayout ? _jsx(MDXLayout, {\n ...props,\n children: _jsx(_createMdxContent, {\n ...props\n })\n }) : _createMdxContent(props);\n}\nreturn {\n default: MDXContent\n};\nfunction _missingMdxReference(id, component) {\n throw new Error(\"Expected \" + (component ? \"component\" : \"object\") + \" `\" + id + \"` to be defined: you likely forgot to import, pass, or provide it.\");\n}\n","frontmatter":{},"scope":{}},"pageType":"default","mdx":{"mdxSource":{"compiledSource":"\"use strict\";const{Fragment:_Fragment,jsx:_jsx}=arguments[0];const{useMDXComponents:_provideComponents}=arguments[0];function _createMdxContent(props){return _jsx(_Fragment,{})}function MDXContent(props={}){const{wrapper:MDXLayout}={..._provideComponents(),...props.components};return MDXLayout?_jsx(MDXLayout,{...props,children:_jsx(_createMdxContent,{...props})}):_createMdxContent(props)}return{default:MDXContent}","frontmatter":{},"scope":{"config":{},"pageMetadata":{"title":"Extract structured data from a document","description":"Pull specific fields from a document into a typed schema.\n\nAccepts exactly one of: a **file upload** (multipart/form-data), a **document URL** (JSON body), or a **`file_id`** referencing an already-ingested document (from `POST /v3/files`), plus a **JSON Schema** (the `schema` field) describing what to extract.\n\n### Sync mode (default)\nBlocks until extraction completes and returns **200** with the full result.\n\n```bash\ncurl -X POST https://api.lighton.ai/api/v3/extract \\\n -H 'Authorization: Bearer $TOKEN' \\\n -F file=@invoice.pdf \\\n -F 'schema={\"type\":\"object\",\"properties\":{\"invoice_number\":{\"type\":\"string\"}}}'\n```\n\n### Async mode (`options.async = true`)\nReturns **202** immediately with an `ext_\u003ctoken>` job id. Poll `GET /api/v3/extract/{id}` with that same id until `status` is `completed` or `failed`.\n\n```bash\ncurl -X POST https://api.lighton.ai/api/v3/extract \\\n -H 'Authorization: Bearer $TOKEN' \\\n -H 'Content-Type: application/json' \\\n -d '{\"document\": \"https://example.com/report.pdf\", \"schema\": {\"type\": \"object\", \"properties\": {\"title\": {\"type\": \"string\"}}}, \"options\": {\"async\": true}}'\n```\n\nFor multipart uploads, pass `options` as a JSON-encoded form field: `-F 'options={\"async\":true}'`.\n\n**Supported file types:** `.pdf`, `.png`, `.jpg`, `.jpeg`, `.pptx`, `.ppt`, `.odp`, `.docx`, `.odt`, `.doc`, `.html`\n\n**Sync limits:** 20 MB file size, 15 pages.\n\n**Async limits:** 100 MB file size, 1000 pages.","deprecated":null,"version":null,"openapi":"/api-reference/api-console.yaml post /api/v3/extract","href":"/api-reference/extract/extract-structured-data-from-a-document","autogeneratedByOpenApi":true}}},"mdxSourceWithNoJs":null},"mdxExtracts":{"tableOfContents":[],"codeExamples":{}},"jsLinks":[],"openApiReferenceData":{"operation":{"operationId":"api_v3_extract_create","description":"Pull specific fields from a document into a typed schema.\n\nAccepts exactly one of: a **file upload** (multipart/form-data), a **document URL** (JSON body), or a **`file_id`** referencing an already-ingested document (from `POST /v3/files`), plus a **JSON Schema** (the `schema` field) describing what to extract.\n\n### Sync mode (default)\nBlocks until extraction completes and returns **200** with the full result.\n\n```bash\ncurl -X POST https://api.lighton.ai/api/v3/extract \\\n -H 'Authorization: Bearer $TOKEN' \\\n -F file=@invoice.pdf \\\n -F 'schema={\"type\":\"object\",\"properties\":{\"invoice_number\":{\"type\":\"string\"}}}'\n```\n\n### Async mode (`options.async = true`)\nReturns **202** immediately with an `ext_\u003ctoken>` job id. Poll `GET /api/v3/extract/{id}` with that same id until `status` is `completed` or `failed`.\n\n```bash\ncurl -X POST https://api.lighton.ai/api/v3/extract \\\n -H 'Authorization: Bearer $TOKEN' \\\n -H 'Content-Type: application/json' \\\n -d '{\"document\": \"https://example.com/report.pdf\", \"schema\": {\"type\": \"object\", \"properties\": {\"title\": {\"type\": \"string\"}}}, \"options\": {\"async\": true}}'\n```\n\nFor multipart uploads, pass `options` as a JSON-encoded form field: `-F 'options={\"async\":true}'`.\n\n**Supported file types:** `.pdf`, `.png`, `.jpg`, `.jpeg`, `.pptx`, `.ppt`, `.odp`, `.docx`, `.odt`, `.doc`, `.html`\n\n**Sync limits:** 20 MB file size, 15 pages.\n\n**Async limits:** 100 MB file size, 1000 pages.","summary":"Extract structured data from a document","tags":["Extract"],"requestBody":"af5f24c0-8f37-4341-adb0-4d623f55a7ae","security":["d9957e6c-cf47-4af4-a315-d308fd95f0ca"],"responses":{"200":"62bd74ad-b920-4d7d-b290-39c6bd220642","202":"1ea99f66-6b2e-4ff1-8807-c0dde22719a4","400":"924b3e08-a9d2-4504-a02e-a8383aee9c89","401":"9f5c46cd-80b2-48f2-9feb-fde0168a6ed2","404":"3fd5b874-ddb9-4f6d-a3f3-7ae757c9b34f","413":"fb0f06c9-e6ed-4062-8ff1-18edee6ab95e","422":"fe9dad6e-52c6-420f-81b9-58311b3f19ec","429":"a8a57833-d701-4d43-89a8-2764ae462d91","503":"7daa16ed-7b7f-4363-b9a9-c38b6e81f0f4"},"method":"post","type":"path","servers":["48c3fa0c-537e-4ab8-b62c-fc02ab11f431"],"path":"/api/v3/extract","baseUrlOptions":["https://api.lighton.ai"],"title":"Extract structured data from a document","codeSamples":[],"requiredOnlyExamples":false,"requestExampleType":"generated","responseExampleType":"generated"},"dependencies":{"parameters":{},"requestBody":{"content":{"multipart/form-data":{"schema":{"description":"Body for POST /api/v3/extract.\n\n``schema`` is the JSON Schema that drives extraction. It arrives as a dict\non JSON requests and as a JSON-encoded string on multipart requests — both\nare coerced to ``dict``.\n\n``options`` is a free-form dict; currently supports ``{\"async\": bool}``.","properties":{"schema":{"additionalProperties":true,"title":"Schema","type":"object","isRequired":true,"uniqueKey":"schema","typeLabel":"Schema · object"},"document":{"oneOf":[{"type":"string","title":"Document","uniqueKey":"document.oneOf.0","typeLabel":"string"},{"type":"null","title":"Document","uniqueKey":"document.oneOf.1","typeLabel":"null"}],"uniqueKey":"document","typeLabel":"string | null"},"file_id":{"oneOf":[{"type":"integer","title":"File Id","uniqueKey":"file_id.oneOf.0","typeLabel":"integer"},{"type":"null","title":"File Id","uniqueKey":"file_id.oneOf.1","typeLabel":"null"}],"uniqueKey":"file_id","typeLabel":"integer | null"},"options":{"additionalProperties":true,"title":"Options","type":"object","uniqueKey":"options","typeLabel":"Options · object"}},"required":["schema"],"title":"ExtractRequest","type":"object","uniqueKey":"","typeLabel":"ExtractRequest · object"},"examples":{"ExtractViaFileUpload(sync)":{"title":"ExtractViaFileUpload(sync)","summary":"Extract via file upload (sync)","description":"Upload a PDF and provide a JSON Schema to extract specific fields.","value":{"file":"(binary)","schema":{"type":"object","properties":{"invoice_number":{"type":"string"}}}}}},"exampleType":"examples"},"application/x-www-form-urlencoded":{"schema":{"description":"Body for POST /api/v3/extract.\n\n``schema`` is the JSON Schema that drives extraction. It arrives as a dict\non JSON requests and as a JSON-encoded string on multipart requests — both\nare coerced to ``dict``.\n\n``options`` is a free-form dict; currently supports ``{\"async\": bool}``.","properties":{"schema":{"additionalProperties":true,"title":"Schema","type":"object","isRequired":true,"uniqueKey":"schema","typeLabel":"Schema · object"},"document":{"oneOf":[{"type":"string","title":"Document","uniqueKey":"document.oneOf.0","typeLabel":"string"},{"type":"null","title":"Document","uniqueKey":"document.oneOf.1","typeLabel":"null"}],"uniqueKey":"document","typeLabel":"string | null"},"file_id":{"oneOf":[{"type":"integer","title":"File Id","uniqueKey":"file_id.oneOf.0","typeLabel":"integer"},{"type":"null","title":"File Id","uniqueKey":"file_id.oneOf.1","typeLabel":"null"}],"uniqueKey":"file_id","typeLabel":"integer | null"},"options":{"additionalProperties":true,"title":"Options","type":"object","uniqueKey":"options","typeLabel":"Options · object"}},"required":["schema"],"title":"ExtractRequest","type":"object","uniqueKey":"","typeLabel":"ExtractRequest · object"},"examples":{"Example":{"title":"Example","value":{"schema":{},"document":"\u003cstring>","file_id":123,"options":{}}}},"exampleType":"generated"},"application/json":{"schema":{"description":"Body for POST /api/v3/extract.\n\n``schema`` is the JSON Schema that drives extraction. It arrives as a dict\non JSON requests and as a JSON-encoded string on multipart requests — both\nare coerced to ``dict``.\n\n``options`` is a free-form dict; currently supports ``{\"async\": bool}``.","properties":{"schema":{"additionalProperties":true,"title":"Schema","type":"object","isRequired":true,"uniqueKey":"schema","typeLabel":"Schema · object"},"document":{"oneOf":[{"type":"string","title":"Document","uniqueKey":"document.oneOf.0","typeLabel":"string"},{"type":"null","title":"Document","uniqueKey":"document.oneOf.1","typeLabel":"null"}],"uniqueKey":"document","typeLabel":"string | null"},"file_id":{"oneOf":[{"type":"integer","title":"File Id","uniqueKey":"file_id.oneOf.0","typeLabel":"integer"},{"type":"null","title":"File Id","uniqueKey":"file_id.oneOf.1","typeLabel":"null"}],"uniqueKey":"file_id","typeLabel":"integer | null"},"options":{"additionalProperties":true,"title":"Options","type":"object","uniqueKey":"options","typeLabel":"Options · object"}},"required":["schema"],"title":"ExtractRequest","type":"object","uniqueKey":"","typeLabel":"ExtractRequest · object"},"examples":{"ExtractViaDocumentURL(sync)":{"title":"ExtractViaDocumentURL(sync)","summary":"Extract via document URL (sync)","description":"Provide a publicly accessible document URL and a JSON Schema.","value":{"document":"https://example.com/invoice.pdf","schema":{"type":"object","properties":{"invoice_number":{"type":"string","description":"The invoice reference number"},"total":{"type":"number","description":"The total amount due"}}}}},"ExtractAsynchronously":{"title":"ExtractAsynchronously","summary":"Extract asynchronously","description":"Same as above with options.async=true. Returns 202 with a job ID.","value":{"document":"https://example.com/large-report.pdf","schema":{"type":"object","properties":{"title":{"type":"string"}}},"options":{"async":true}}},"ExtractViaFileId(sync)":{"title":"ExtractViaFileId(sync)","summary":"Extract via file_id (sync)","description":"Reference an already-ingested document (from POST /v3/files) by id.","value":{"file_id":42,"schema":{"type":"object","properties":{"invoice_number":{"type":"string"},"total":{"type":"number"}}}}}},"exampleType":"examples"}},"required":true,"exampleType":"examples"},"responses":{"62bd74ad-b920-4d7d-b290-39c6bd220642":{"content":{"application/json":{"schema":{"properties":{"id":{"title":"Id","type":"string","isRequired":true,"uniqueKey":"id","typeLabel":"string"},"status":{"title":"Status","type":"string","isRequired":true,"uniqueKey":"status","typeLabel":"string"},"created_at":{"oneOf":[{"type":"string","title":"Created At","format":"date-time","uniqueKey":"created_at.oneOf.0","typeLabel":"string\u003cdate-time>"},{"type":"null","title":"Created At","uniqueKey":"created_at.oneOf.1","typeLabel":"null"}],"uniqueKey":"created_at","typeLabel":"string\u003cdate-time> | null"},"completed_at":{"oneOf":[{"type":"string","title":"Completed At","format":"date-time","uniqueKey":"completed_at.oneOf.0","typeLabel":"string\u003cdate-time>"},{"type":"null","title":"Completed At","uniqueKey":"completed_at.oneOf.1","typeLabel":"null"}],"uniqueKey":"completed_at","typeLabel":"string\u003cdate-time> | null"},"processing_time_ms":{"oneOf":[{"type":"integer","title":"Processing Time Ms","uniqueKey":"processing_time_ms.oneOf.0","typeLabel":"integer"},{"type":"null","title":"Processing Time Ms","uniqueKey":"processing_time_ms.oneOf.1","typeLabel":"null"}],"uniqueKey":"processing_time_ms","typeLabel":"integer | null"},"document":{"oneOf":[{"type":"object","title":"ExtractDocument","properties":{"filename":{"oneOf":[{"type":"string","title":"Filename","uniqueKey":"document.oneOf.0.filename.oneOf.0","typeLabel":"string"},{"type":"null","title":"Filename","uniqueKey":"document.oneOf.0.filename.oneOf.1","typeLabel":"null"}],"uniqueKey":"document.oneOf.0.filename","typeLabel":"string | null"},"page_count":{"oneOf":[{"type":"integer","title":"Page Count","uniqueKey":"document.oneOf.0.page_count.oneOf.0","typeLabel":"integer"},{"type":"null","title":"Page Count","uniqueKey":"document.oneOf.0.page_count.oneOf.1","typeLabel":"null"}],"uniqueKey":"document.oneOf.0.page_count","typeLabel":"integer | null"},"file_size_bytes":{"oneOf":[{"type":"integer","title":"File Size Bytes","uniqueKey":"document.oneOf.0.file_size_bytes.oneOf.0","typeLabel":"integer"},{"type":"null","title":"File Size Bytes","uniqueKey":"document.oneOf.0.file_size_bytes.oneOf.1","typeLabel":"null"}],"uniqueKey":"document.oneOf.0.file_size_bytes","typeLabel":"integer | null"},"mime_type":{"oneOf":[{"type":"string","title":"Mime Type","uniqueKey":"document.oneOf.0.mime_type.oneOf.0","typeLabel":"string"},{"type":"null","title":"Mime Type","uniqueKey":"document.oneOf.0.mime_type.oneOf.1","typeLabel":"null"}],"uniqueKey":"document.oneOf.0.mime_type","typeLabel":"string | null"}},"uniqueKey":"document.oneOf.0","typeLabel":"ExtractDocument · object"},{"type":"null","uniqueKey":"document.oneOf.1","typeLabel":"null"}],"uniqueKey":"document","typeLabel":"ExtractDocument · object | null"},"result":{"oneOf":[{"type":"object","title":"ExtractResult","properties":{"data":{"oneOf":[{"type":"array","items":{"additionalProperties":true,"type":"object","uniqueKey":"result.oneOf.0.data.oneOf.0.items.[INDEX]","typeLabel":"object"},"title":"Data","uniqueKey":"result.oneOf.0.data.oneOf.0","typeLabel":"Data · object[]"},{"type":"null","title":"Data","uniqueKey":"result.oneOf.0.data.oneOf.1","typeLabel":"null"}],"uniqueKey":"result.oneOf.0.data","typeLabel":"Data · object[] | null"},"pagination":{"oneOf":[{"type":"object","title":"ExtractPagination","required":["page","page_size","total_items","total_pages","has_next","has_prev"],"properties":{"page":{"title":"Page","type":"integer","isRequired":true,"uniqueKey":"result.oneOf.0.pagination.oneOf.0.page","typeLabel":"integer"},"page_size":{"title":"Page Size","type":"integer","isRequired":true,"uniqueKey":"result.oneOf.0.pagination.oneOf.0.page_size","typeLabel":"integer"},"total_items":{"title":"Total Items","type":"integer","isRequired":true,"uniqueKey":"result.oneOf.0.pagination.oneOf.0.total_items","typeLabel":"integer"},"total_pages":{"title":"Total Pages","type":"integer","isRequired":true,"uniqueKey":"result.oneOf.0.pagination.oneOf.0.total_pages","typeLabel":"integer"},"has_next":{"title":"Has Next","type":"boolean","isRequired":true,"uniqueKey":"result.oneOf.0.pagination.oneOf.0.has_next","typeLabel":"boolean"},"has_prev":{"title":"Has Prev","type":"boolean","isRequired":true,"uniqueKey":"result.oneOf.0.pagination.oneOf.0.has_prev","typeLabel":"boolean"}},"uniqueKey":"result.oneOf.0.pagination.oneOf.0","typeLabel":"ExtractPagination · object"},{"type":"null","uniqueKey":"result.oneOf.0.pagination.oneOf.1","typeLabel":"null"}],"uniqueKey":"result.oneOf.0.pagination","typeLabel":"ExtractPagination · object | null"}},"uniqueKey":"result.oneOf.0","typeLabel":"ExtractResult · object"},{"type":"null","uniqueKey":"result.oneOf.1","typeLabel":"null"}],"uniqueKey":"result","typeLabel":"ExtractResult · object | null"},"usage":{"oneOf":[{"type":"object","title":"ExtractUsage","properties":{"pages_processed":{"oneOf":[{"type":"integer","title":"Pages Processed","uniqueKey":"usage.oneOf.0.pages_processed.oneOf.0","typeLabel":"integer"},{"type":"null","title":"Pages Processed","uniqueKey":"usage.oneOf.0.pages_processed.oneOf.1","typeLabel":"null"}],"uniqueKey":"usage.oneOf.0.pages_processed","typeLabel":"integer | null"}},"uniqueKey":"usage.oneOf.0","typeLabel":"ExtractUsage · object"},{"type":"null","uniqueKey":"usage.oneOf.1","typeLabel":"null"}],"uniqueKey":"usage","typeLabel":"ExtractUsage · object | null"},"progress":{"oneOf":[{"type":"object","title":"JobProgress","description":"Live progress of a long-running async job while it is in flight.\n\nShared by the parse (``GET /api/v3/parse/\u003cid>``) and extract\n(``GET /api/v3/extract/\u003cid>``) polling envelopes: ``pages_processed`` is the\ncount of pages done so far and ``percentage`` is the completion percentage\n[0, 100] derived from it.","required":["percentage","pages_processed"],"properties":{"percentage":{"title":"Percentage","type":"integer","isRequired":true,"uniqueKey":"progress.oneOf.0.percentage","typeLabel":"integer"},"pages_processed":{"title":"Pages Processed","type":"integer","isRequired":true,"uniqueKey":"progress.oneOf.0.pages_processed","typeLabel":"integer"}},"uniqueKey":"progress.oneOf.0","typeLabel":"JobProgress · object"},{"type":"null","uniqueKey":"progress.oneOf.1","typeLabel":"null"}],"uniqueKey":"progress","typeLabel":"JobProgress · object | null"}},"required":["id","status"],"title":"ExtractJobResponse","type":"object","uniqueKey":"","typeLabel":"ExtractJobResponse · object"},"examples":{"SyncExtractionResponse":{"title":"SyncExtractionResponse","summary":"Sync extraction response","value":{"id":"ext_0196e4b2a3c14d5e8f7a9b2c1d0e3f4a","status":"completed","created_at":"2026-03-31T10:00:00+00:00","completed_at":"2026-03-31T10:00:04+00:00","processing_time_ms":3200,"document":{"filename":"invoice.pdf","page_count":3,"file_size_bytes":245120,"mime_type":"application/pdf"},"result":{"data":[{"invoice_number":"INV-2026-001","total":null,"line_items":null},{"invoice_number":null,"total":1250,"line_items":[{"description":"Widget A","quantity":10,"unit_price":50},{"description":"Widget B","quantity":5,"unit_price":150}]},{"invoice_number":null,"total":null,"line_items":null}],"pagination":{"page":1,"page_size":15,"total_items":3,"total_pages":1,"has_next":false,"has_prev":false}},"usage":{"pages_processed":3},"progress":{"percentage":100,"pages_processed":3}}}},"exampleType":"examples"}},"description":"Extraction completed (sync mode).","exampleType":"examples"},"1ea99f66-6b2e-4ff1-8807-c0dde22719a4":{"content":{"application/json":{"schema":{"properties":{"id":{"title":"Id","type":"string","isRequired":true,"uniqueKey":"id","typeLabel":"string"},"status":{"title":"Status","type":"string","isRequired":true,"uniqueKey":"status","typeLabel":"string"},"created_at":{"oneOf":[{"type":"string","title":"Created At","format":"date-time","uniqueKey":"created_at.oneOf.0","typeLabel":"string\u003cdate-time>"},{"type":"null","title":"Created At","uniqueKey":"created_at.oneOf.1","typeLabel":"null"}],"uniqueKey":"created_at","typeLabel":"string\u003cdate-time> | null"},"completed_at":{"oneOf":[{"type":"string","title":"Completed At","format":"date-time","uniqueKey":"completed_at.oneOf.0","typeLabel":"string\u003cdate-time>"},{"type":"null","title":"Completed At","uniqueKey":"completed_at.oneOf.1","typeLabel":"null"}],"uniqueKey":"completed_at","typeLabel":"string\u003cdate-time> | null"},"processing_time_ms":{"oneOf":[{"type":"integer","title":"Processing Time Ms","uniqueKey":"processing_time_ms.oneOf.0","typeLabel":"integer"},{"type":"null","title":"Processing Time Ms","uniqueKey":"processing_time_ms.oneOf.1","typeLabel":"null"}],"uniqueKey":"processing_time_ms","typeLabel":"integer | null"},"document":{"oneOf":[{"type":"object","title":"ExtractDocument","properties":{"filename":{"oneOf":[{"type":"string","title":"Filename","uniqueKey":"document.oneOf.0.filename.oneOf.0","typeLabel":"string"},{"type":"null","title":"Filename","uniqueKey":"document.oneOf.0.filename.oneOf.1","typeLabel":"null"}],"uniqueKey":"document.oneOf.0.filename","typeLabel":"string | null"},"page_count":{"oneOf":[{"type":"integer","title":"Page Count","uniqueKey":"document.oneOf.0.page_count.oneOf.0","typeLabel":"integer"},{"type":"null","title":"Page Count","uniqueKey":"document.oneOf.0.page_count.oneOf.1","typeLabel":"null"}],"uniqueKey":"document.oneOf.0.page_count","typeLabel":"integer | null"},"file_size_bytes":{"oneOf":[{"type":"integer","title":"File Size Bytes","uniqueKey":"document.oneOf.0.file_size_bytes.oneOf.0","typeLabel":"integer"},{"type":"null","title":"File Size Bytes","uniqueKey":"document.oneOf.0.file_size_bytes.oneOf.1","typeLabel":"null"}],"uniqueKey":"document.oneOf.0.file_size_bytes","typeLabel":"integer | null"},"mime_type":{"oneOf":[{"type":"string","title":"Mime Type","uniqueKey":"document.oneOf.0.mime_type.oneOf.0","typeLabel":"string"},{"type":"null","title":"Mime Type","uniqueKey":"document.oneOf.0.mime_type.oneOf.1","typeLabel":"null"}],"uniqueKey":"document.oneOf.0.mime_type","typeLabel":"string | null"}},"uniqueKey":"document.oneOf.0","typeLabel":"ExtractDocument · object"},{"type":"null","uniqueKey":"document.oneOf.1","typeLabel":"null"}],"uniqueKey":"document","typeLabel":"ExtractDocument · object | null"},"result":{"oneOf":[{"type":"object","title":"ExtractResult","properties":{"data":{"oneOf":[{"type":"array","items":{"additionalProperties":true,"type":"object","uniqueKey":"result.oneOf.0.data.oneOf.0.items.[INDEX]","typeLabel":"object"},"title":"Data","uniqueKey":"result.oneOf.0.data.oneOf.0","typeLabel":"Data · object[]"},{"type":"null","title":"Data","uniqueKey":"result.oneOf.0.data.oneOf.1","typeLabel":"null"}],"uniqueKey":"result.oneOf.0.data","typeLabel":"Data · object[] | null"},"pagination":{"oneOf":[{"type":"object","title":"ExtractPagination","required":["page","page_size","total_items","total_pages","has_next","has_prev"],"properties":{"page":{"title":"Page","type":"integer","isRequired":true,"uniqueKey":"result.oneOf.0.pagination.oneOf.0.page","typeLabel":"integer"},"page_size":{"title":"Page Size","type":"integer","isRequired":true,"uniqueKey":"result.oneOf.0.pagination.oneOf.0.page_size","typeLabel":"integer"},"total_items":{"title":"Total Items","type":"integer","isRequired":true,"uniqueKey":"result.oneOf.0.pagination.oneOf.0.total_items","typeLabel":"integer"},"total_pages":{"title":"Total Pages","type":"integer","isRequired":true,"uniqueKey":"result.oneOf.0.pagination.oneOf.0.total_pages","typeLabel":"integer"},"has_next":{"title":"Has Next","type":"boolean","isRequired":true,"uniqueKey":"result.oneOf.0.pagination.oneOf.0.has_next","typeLabel":"boolean"},"has_prev":{"title":"Has Prev","type":"boolean","isRequired":true,"uniqueKey":"result.oneOf.0.pagination.oneOf.0.has_prev","typeLabel":"boolean"}},"uniqueKey":"result.oneOf.0.pagination.oneOf.0","typeLabel":"ExtractPagination · object"},{"type":"null","uniqueKey":"result.oneOf.0.pagination.oneOf.1","typeLabel":"null"}],"uniqueKey":"result.oneOf.0.pagination","typeLabel":"ExtractPagination · object | null"}},"uniqueKey":"result.oneOf.0","typeLabel":"ExtractResult · object"},{"type":"null","uniqueKey":"result.oneOf.1","typeLabel":"null"}],"uniqueKey":"result","typeLabel":"ExtractResult · object | null"},"usage":{"oneOf":[{"type":"object","title":"ExtractUsage","properties":{"pages_processed":{"oneOf":[{"type":"integer","title":"Pages Processed","uniqueKey":"usage.oneOf.0.pages_processed.oneOf.0","typeLabel":"integer"},{"type":"null","title":"Pages Processed","uniqueKey":"usage.oneOf.0.pages_processed.oneOf.1","typeLabel":"null"}],"uniqueKey":"usage.oneOf.0.pages_processed","typeLabel":"integer | null"}},"uniqueKey":"usage.oneOf.0","typeLabel":"ExtractUsage · object"},{"type":"null","uniqueKey":"usage.oneOf.1","typeLabel":"null"}],"uniqueKey":"usage","typeLabel":"ExtractUsage · object | null"},"progress":{"oneOf":[{"type":"object","title":"JobProgress","description":"Live progress of a long-running async job while it is in flight.\n\nShared by the parse (``GET /api/v3/parse/\u003cid>``) and extract\n(``GET /api/v3/extract/\u003cid>``) polling envelopes: ``pages_processed`` is the\ncount of pages done so far and ``percentage`` is the completion percentage\n[0, 100] derived from it.","required":["percentage","pages_processed"],"properties":{"percentage":{"title":"Percentage","type":"integer","isRequired":true,"uniqueKey":"progress.oneOf.0.percentage","typeLabel":"integer"},"pages_processed":{"title":"Pages Processed","type":"integer","isRequired":true,"uniqueKey":"progress.oneOf.0.pages_processed","typeLabel":"integer"}},"uniqueKey":"progress.oneOf.0","typeLabel":"JobProgress · object"},{"type":"null","uniqueKey":"progress.oneOf.1","typeLabel":"null"}],"uniqueKey":"progress","typeLabel":"JobProgress · object | null"}},"required":["id","status"],"title":"ExtractJobResponse","type":"object","uniqueKey":"","typeLabel":"ExtractJobResponse · object"},"examples":{"AsyncAcceptedResponse":{"title":"AsyncAcceptedResponse","summary":"Async accepted response","value":{"id":"ext_0196e4b2a3c14d5e8f7a9b2c1d0e3f4a","status":"pending","created_at":"2026-03-31T10:00:00+00:00","completed_at":null,"processing_time_ms":null,"document":{"filename":"large-report.pdf","page_count":null,"file_size_bytes":5242880,"mime_type":"application/pdf"},"result":null,"usage":null,"progress":null}}},"exampleType":"examples"}},"description":"Extraction accepted (async mode). Poll GET /v3/extract/{id} for status.","exampleType":"examples"},"924b3e08-a9d2-4504-a02e-a8383aee9c89":{"content":{"application/json":{"schema":{"type":"object","properties":{"id":{"oneOf":[{"type":"string","description":"Job/resource id when one already exists (useful for async error diagnosis); null otherwise.","isRequired":true,"uniqueKey":"id.oneOf.0","typeLabel":"string"},{"type":"null","description":"Job/resource id when one already exists (useful for async error diagnosis); null otherwise.","isRequired":true,"uniqueKey":"id.oneOf.1","typeLabel":"null"}],"isRequired":true,"uniqueKey":"id","typeLabel":"string | null"},"code":{"type":"integer","description":"HTTP status code","isRequired":true,"uniqueKey":"code","typeLabel":"integer"},"error":{"type":"string","description":"Error code used by the UI as a translation key","isRequired":true,"uniqueKey":"error","typeLabel":"string"},"detail":{"type":"string","description":"Human-readable error message for developers","isRequired":true,"uniqueKey":"detail","typeLabel":"string"},"doc_url":{"type":"string","description":"Link to the error-code documentation page","isRequired":true,"uniqueKey":"doc_url","typeLabel":"string"}},"required":["code","detail","doc_url","error","id"],"uniqueKey":"","typeLabel":"object"},"examples":{"MissingSource":{"title":"MissingSource","summary":"Missing source","value":{"id":null,"code":400,"error":"missing_input","detail":"A file upload, document URL, or file_id is required.","doc_url":"https://developers.lighton.ai/errors#missing_input"}},"AmbiguousSource":{"title":"AmbiguousSource","summary":"Ambiguous source","value":{"id":null,"code":400,"error":"ambiguous_input","detail":"Provide exactly one of: file upload, document URL, or file_id.","doc_url":"https://developers.lighton.ai/errors#ambiguous_input"}},"PageLimitExceeded":{"title":"PageLimitExceeded","summary":"Page limit exceeded","value":{"id":null,"code":400,"error":"max_pages_exceeded","detail":"Document has 1200 pages, exceeding the async limit of 1000 pages.","doc_url":"https://developers.lighton.ai/errors#max_pages_exceeded"}}},"exampleType":"examples"}},"description":"Bad request — missing/ambiguous source, unsupported format, or page limit exceeded.","exampleType":"examples"},"9f5c46cd-80b2-48f2-9feb-fde0168a6ed2":{"content":{"application/json":{"schema":{"type":"object","properties":{"id":{"oneOf":[{"type":"string","description":"Job/resource id when one already exists (useful for async error diagnosis); null otherwise.","isRequired":true,"uniqueKey":"id.oneOf.0","typeLabel":"string"},{"type":"null","description":"Job/resource id when one already exists (useful for async error diagnosis); null otherwise.","isRequired":true,"uniqueKey":"id.oneOf.1","typeLabel":"null"}],"isRequired":true,"uniqueKey":"id","typeLabel":"string | null"},"code":{"type":"integer","description":"HTTP status code","isRequired":true,"uniqueKey":"code","typeLabel":"integer"},"error":{"type":"string","description":"Error code used by the UI as a translation key","isRequired":true,"uniqueKey":"error","typeLabel":"string"},"detail":{"type":"string","description":"Human-readable error message for developers","isRequired":true,"uniqueKey":"detail","typeLabel":"string"},"doc_url":{"type":"string","description":"Link to the error-code documentation page","isRequired":true,"uniqueKey":"doc_url","typeLabel":"string"}},"required":["code","detail","doc_url","error","id"],"uniqueKey":"","typeLabel":"object"},"examples":{"Unauthorized":{"title":"Unauthorized","value":{"id":null,"code":401,"error":"unauthorized","detail":"Authentication credentials were not provided or are invalid.","doc_url":"https://developers.lighton.ai/errors#unauthorized"}}},"exampleType":"examples"}},"description":"Authentication credentials were not provided or are invalid","exampleType":"examples"},"3fd5b874-ddb9-4f6d-a3f3-7ae757c9b34f":{"content":{"application/json":{"schema":{"type":"object","properties":{"id":{"oneOf":[{"type":"string","description":"Job/resource id when one already exists (useful for async error diagnosis); null otherwise.","isRequired":true,"uniqueKey":"id.oneOf.0","typeLabel":"string"},{"type":"null","description":"Job/resource id when one already exists (useful for async error diagnosis); null otherwise.","isRequired":true,"uniqueKey":"id.oneOf.1","typeLabel":"null"}],"isRequired":true,"uniqueKey":"id","typeLabel":"string | null"},"code":{"type":"integer","description":"HTTP status code","isRequired":true,"uniqueKey":"code","typeLabel":"integer"},"error":{"type":"string","description":"Error code used by the UI as a translation key","isRequired":true,"uniqueKey":"error","typeLabel":"string"},"detail":{"type":"string","description":"Human-readable error message for developers","isRequired":true,"uniqueKey":"detail","typeLabel":"string"},"doc_url":{"type":"string","description":"Link to the error-code documentation page","isRequired":true,"uniqueKey":"doc_url","typeLabel":"string"}},"required":["code","detail","doc_url","error","id"],"uniqueKey":"","typeLabel":"object"},"examples":{"DocumentNotFoundOrUnauthorized":{"title":"DocumentNotFoundOrUnauthorized","summary":"Document not found or unauthorized","value":{"id":null,"code":404,"error":"not_found","detail":"Document not found or access denied.","doc_url":"https://developers.lighton.ai/errors#not_found"}},"DocumentFileMissing":{"title":"DocumentFileMissing","summary":"Document file missing","value":{"id":null,"code":404,"error":"document_file_not_found","detail":"The document's stored file could not be found.","doc_url":"https://developers.lighton.ai/errors#document_file_not_found"}}},"exampleType":"examples"}},"description":"`file_id` does not exist, is not authorized for the requesting user, or its stored file is missing.","exampleType":"examples"},"fb0f06c9-e6ed-4062-8ff1-18edee6ab95e":{"content":{"application/json":{"schema":{"type":"object","properties":{"id":{"oneOf":[{"type":"string","description":"Job/resource id when one already exists (useful for async error diagnosis); null otherwise.","isRequired":true,"uniqueKey":"id.oneOf.0","typeLabel":"string"},{"type":"null","description":"Job/resource id when one already exists (useful for async error diagnosis); null otherwise.","isRequired":true,"uniqueKey":"id.oneOf.1","typeLabel":"null"}],"isRequired":true,"uniqueKey":"id","typeLabel":"string | null"},"code":{"type":"integer","description":"HTTP status code","isRequired":true,"uniqueKey":"code","typeLabel":"integer"},"error":{"type":"string","description":"Error code used by the UI as a translation key","isRequired":true,"uniqueKey":"error","typeLabel":"string"},"detail":{"type":"string","description":"Human-readable error message for developers","isRequired":true,"uniqueKey":"detail","typeLabel":"string"},"doc_url":{"type":"string","description":"Link to the error-code documentation page","isRequired":true,"uniqueKey":"doc_url","typeLabel":"string"}},"required":["code","detail","doc_url","error","id"],"uniqueKey":"","typeLabel":"object"},"examples":{"PayloadTooLarge":{"title":"PayloadTooLarge","summary":"Payload too large","value":{"id":null,"code":413,"error":"payload_too_large","detail":"File size (157286400 bytes) exceeds the 100MB async limit.","doc_url":"https://developers.lighton.ai/errors/payload_too_large"}}},"exampleType":"examples"}},"description":"File exceeds the size limit (20 MB sync, 100 MB async).","exampleType":"examples"},"fe9dad6e-52c6-420f-81b9-58311b3f19ec":{"content":{"application/json":{"schema":{"type":"object","properties":{"id":{"oneOf":[{"type":"string","description":"Job/resource id when one already exists (useful for async error diagnosis); null otherwise.","isRequired":true,"uniqueKey":"id.oneOf.0","typeLabel":"string"},{"type":"null","description":"Job/resource id when one already exists (useful for async error diagnosis); null otherwise.","isRequired":true,"uniqueKey":"id.oneOf.1","typeLabel":"null"}],"isRequired":true,"uniqueKey":"id","typeLabel":"string | null"},"code":{"type":"integer","description":"HTTP status code","isRequired":true,"uniqueKey":"code","typeLabel":"integer"},"error":{"type":"string","description":"Error code used by the UI as a translation key","isRequired":true,"uniqueKey":"error","typeLabel":"string"},"detail":{"type":"string","description":"Human-readable error message for developers","isRequired":true,"uniqueKey":"detail","typeLabel":"string"},"doc_url":{"type":"string","description":"Link to the error-code documentation page","isRequired":true,"uniqueKey":"doc_url","typeLabel":"string"},"fields":{"type":"object","additionalProperties":{"type":"array","items":{"type":"object","properties":{"error":{"type":"string","description":"Error code / translation key","isRequired":true,"uniqueKey":"fields.additionalProperties.items.[INDEX].error","typeLabel":"string"},"detail":{"type":"string","description":"Human-readable description of the field error","isRequired":true,"uniqueKey":"fields.additionalProperties.items.[INDEX].detail","typeLabel":"string"}},"required":["detail","error"],"uniqueKey":"fields.additionalProperties.items.[INDEX]","typeLabel":"object"},"uniqueKey":"fields.additionalProperties","typeLabel":"object[]"},"description":"Field-level validation errors keyed by field name","uniqueKey":"fields","typeLabel":"object"}},"required":["code","detail","doc_url","error","id"],"uniqueKey":"","typeLabel":"object"},"examples":{"MalformedJSONSchema":{"title":"MalformedJSONSchema","summary":"Malformed JSON Schema","value":{"id":null,"code":422,"error":"validation_error","detail":"The provided JSON Schema is malformed.","doc_url":"https://developers.lighton.ai/errors#validation_error","fields":{"schema":[{"error":"invalid","detail":"JSON Schema is not valid: missing 'type' keyword."}]}}}},"exampleType":"examples"}},"description":"JSON Schema is malformed, uses unsupported features, or exceeds limits.","exampleType":"examples"},"a8a57833-d701-4d43-89a8-2764ae462d91":{"content":{"application/json":{"schema":{"type":"object","properties":{"id":{"oneOf":[{"type":"string","description":"Job/resource id when one already exists (useful for async error diagnosis); null otherwise.","isRequired":true,"uniqueKey":"id.oneOf.0","typeLabel":"string"},{"type":"null","description":"Job/resource id when one already exists (useful for async error diagnosis); null otherwise.","isRequired":true,"uniqueKey":"id.oneOf.1","typeLabel":"null"}],"isRequired":true,"uniqueKey":"id","typeLabel":"string | null"},"code":{"type":"integer","description":"HTTP status code","isRequired":true,"uniqueKey":"code","typeLabel":"integer"},"error":{"type":"string","description":"Error code used by the UI as a translation key","isRequired":true,"uniqueKey":"error","typeLabel":"string"},"detail":{"type":"string","description":"Human-readable error message for developers","isRequired":true,"uniqueKey":"detail","typeLabel":"string"},"doc_url":{"type":"string","description":"Link to the error-code documentation page","isRequired":true,"uniqueKey":"doc_url","typeLabel":"string"}},"required":["code","detail","doc_url","error","id"],"uniqueKey":"","typeLabel":"object"},"examples":{"TooManyRequests":{"title":"TooManyRequests","summary":"Too Many Requests","value":{"id":null,"code":429,"error":"too_many_requests","detail":"Too many requests. Please try again later.","doc_url":"https://developers.lighton.ai/errors#too_many_requests"}}},"exampleType":"examples"}},"description":"Too many requests","exampleType":"examples"},"7daa16ed-7b7f-4363-b9a9-c38b6e81f0f4":{"description":"API is under maintenance. Check `GET /api/v3/system/status` for active periods and retry.","content":{"application/json":{"schema":{"type":"object","description":"Returned by the maintenance middleware when the requested endpoint is blocked.","required":["detail","error","mode"],"properties":{"detail":{"type":"string","example":"System is under maintenance.","isRequired":true,"uniqueKey":"detail","typeLabel":"string"},"error":{"type":"string","example":"service_maintenance","isRequired":true,"uniqueKey":"error","typeLabel":"string"},"mode":{"type":"string","enum":["full_shutdown","warning_banner"],"description":"`full_shutdown` blocks all traffic; `warning_banner` also blocks and shows a dismissible toast.","isRequired":true,"uniqueKey":"mode","typeLabel":"enum\u003cstring>"},"reason":{"type":"string","description":"Operator-supplied maintenance reason, if any.","uniqueKey":"reason","typeLabel":"string"},"started_at":{"type":"string","format":"date-time","uniqueKey":"started_at","typeLabel":"string\u003cdate-time>"},"endpoint_category_names":{"type":"array","items":{"type":"string","uniqueKey":"endpoint_category_names.items.[INDEX]","typeLabel":"string"},"description":"Non-empty only for category-scoped periods. Empty means all endpoints are affected.","uniqueKey":"endpoint_category_names","typeLabel":"string[]"}},"uniqueKey":"","typeLabel":"object"},"examples":{"Example":{"title":"Example","value":{"detail":"System is under maintenance.","error":"service_maintenance","mode":"full_shutdown","reason":"\u003cstring>","started_at":"2023-11-07T05:31:56Z","endpoint_category_names":["\u003cstring>"]}}},"exampleType":"generated"}},"exampleType":"generated"}},"security":{"d9957e6c-cf47-4af4-a315-d308fd95f0ca":{"bearerAuth":{"type":"http","scheme":"bearer","description":"Bearer authentication header of the form `Bearer \u003ctoken>`, where `\u003ctoken>` is your auth token.","scopes":[]}}},"servers":{"48c3fa0c-537e-4ab8-b62c-fc02ab11f431":{"url":"https://api.lighton.ai"}},"processedSecurityOptions":[{"schemes":[{"scheme":{"type":"http","scheme":"bearer","description":"Bearer authentication header of the form `Bearer \u003ctoken>`, where `\u003ctoken>` is your auth token.","scopes":[]},"schema":{"title":"Bearer Auth","type":"string","isRequired":true,"description":"Bearer authentication header of the form `Bearer \u003ctoken>`, where `\u003ctoken>` is your auth token.","format":"bearer","typeLabel":"string\u003cbearer>","deprecated":false},"schemeName":"bearerAuth","name":"Authorization"}],"title":"bearerAuth"}]},"originalFileLocation":"api-reference/api-console.yaml"},"subdomain":"lighton-developers","siteName":"LightOn Developers","title":"Extract structured data from a document - LightOn Developers","navMaps":{"firstHrefInVersion":{},"firstHrefInLanguage":{}},"lastModified":"2026-09-16T07:50:03.042Z","originalFileLocation":"api-reference/extract/extract-structured-data-from-a-document.mdx"},"headHtml":"\u003cscript data-mint-head>(function(){var d=document.documentElement,p=null;if(!p){try{p=localStorage.getItem(\"isDarkMode\")}catch(e){}if(p==='true')p='dark';else if(p==='false')p='light';if(p!=='light'\u0026\u0026p!=='dark'\u0026\u0026p!=='system')p=\"system\"}var r=p==='system'?(matchMedia(\"(prefers-color-scheme: dark)\").matches?'dark':'light'):p;d.classList.remove(r==='dark'?'light':'dark');d.classList.add(r);d.setAttribute(\"data-theme-preference\",p)})();\u003c/script>\u003cmeta data-mint-head name=\"description\" content=\"Pull specific fields from a document into a typed schema. Accepts exactly one of: a file upload (multipart/form-data), a document URL (JSON body), or a file_id referencing an already-ingested document (from POST /v3/files), plus a JSON Schema (the schema field) describing what to extract. ### Sync mode (default) Blocks until extraction completes and returns 200 with the full result. bash curl -X POST https://api.lighton.ai/api/v3/extract \\ -H \u0026#x27;Authorization: Bearer $TOKEN\u0026#x27; \\ -F file=@invoice.pdf \\ -F \u0026#x27;schema={\u0026quot;type\u0026quot;:\u0026quot;object\u0026quot;,\u0026quot;properties\u0026quot;:{\u0026quot;invoice_number\u0026quot;:{\u0026quot;type\u0026quot;:\u0026quot;string\u0026quot;}}}\u0026#x27; ### Async mode (options.async = true) Returns 202 immediately with an ext_ job id. Poll GET /api/v3/extract/{id} with that same id until status is completed or failed. bash curl -X POST https://api.lighton.ai/api/v3/extract \\ -H \u0026#x27;Authorization: Bearer $TOKEN\u0026#x27; \\ -H \u0026#x27;Content-Type: application/json\u0026#x27; \\ -d \u0026#x27;{\u0026quot;document\u0026quot;: \u0026quot;https://example.com/report.pdf\u0026quot;, \u0026quot;schema\u0026quot;: {\u0026quot;type\u0026quot;: \u0026quot;object\u0026quot;, \u0026quot;properties\u0026quot;: {\u0026quot;title\u0026quot;: {\u0026quot;type\u0026quot;: \u0026quot;string\u0026quot;}}}, \u0026quot;options\u0026quot;: {\u0026quot;async\u0026quot;: true}}\u0026#x27; For multipart uploads, pass options as a JSON-encoded form field: -F \u0026#x27;options={\u0026quot;async\u0026quot;:true}\u0026#x27;. Supported file types: .pdf, .png, .jpg, .jpeg, .pptx, .ppt, .odp, .docx, .odt, .doc, .html Sync limits: 20 MB file size, 15 pages. Async limits: 100 MB file size, 1000 pages.\">\u003cmeta data-mint-head name=\"application-name\" content=\"LightOn Developers\">\u003cmeta data-mint-head name=\"generator\" content=\"Mintlify\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"192x192\" href=\"/mintlify-assets/_mintlify/favicons/lighton-developers/2Zh9Mbvo5QQal47m/_generated/favicon/android-chrome-192x192.png\" media=\"(prefers-color-scheme: light)\">\u003clink data-mint-head rel=\"apple-touch-icon\" type=\"image/png\" sizes=\"180x180\" href=\"/mintlify-assets/_mintlify/favicons/lighton-developers/2Zh9Mbvo5QQal47m/_generated/favicon/apple-touch-icon.png\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"16x16\" href=\"/mintlify-assets/_mintlify/favicons/lighton-developers/2Zh9Mbvo5QQal47m/_generated/favicon/favicon-16x16.png\" media=\"(prefers-color-scheme: light)\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"32x32\" href=\"/mintlify-assets/_mintlify/favicons/lighton-developers/2Zh9Mbvo5QQal47m/_generated/favicon/favicon-32x32.png\" media=\"(prefers-color-scheme: light)\">\u003clink data-mint-head rel=\"shortcut icon\" type=\"image/x-icon\" href=\"/mintlify-assets/_mintlify/favicons/lighton-developers/2Zh9Mbvo5QQal47m/_generated/favicon/favicon.ico\" media=\"(prefers-color-scheme: light)\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"192x192\" href=\"/mintlify-assets/_mintlify/favicons/lighton-developers/2Zh9Mbvo5QQal47m/_generated/favicon-dark/android-chrome-192x192.png\" media=\"(prefers-color-scheme: dark)\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"16x16\" href=\"/mintlify-assets/_mintlify/favicons/lighton-developers/2Zh9Mbvo5QQal47m/_generated/favicon-dark/favicon-16x16.png\" media=\"(prefers-color-scheme: dark)\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"32x32\" href=\"/mintlify-assets/_mintlify/favicons/lighton-developers/2Zh9Mbvo5QQal47m/_generated/favicon-dark/favicon-32x32.png\" media=\"(prefers-color-scheme: dark)\">\u003clink data-mint-head rel=\"shortcut icon\" type=\"image/x-icon\" href=\"/mintlify-assets/_mintlify/favicons/lighton-developers/2Zh9Mbvo5QQal47m/_generated/favicon-dark/favicon.ico\" media=\"(prefers-color-scheme: dark)\">\u003cmeta data-mint-head property=\"og:title\" content=\"Extract structured data from a document - LightOn Developers\">\u003cmeta data-mint-head property=\"og:description\" content=\"Pull specific fields from a document into a typed schema. Accepts exactly one of: a file upload (multipart/form-data), a document URL (JSON body), or a file_id referencing an already-ingested document (from POST /v3/files), plus a JSON Schema (the schema field) describing what to extract. ### Sync mode (default) Blocks until extraction completes and returns 200 with the full result. bash curl -X POST https://api.lighton.ai/api/v3/extract \\ -H \u0026#x27;Authorization: Bearer $TOKEN\u0026#x27; \\ -F file=@invoice.pdf \\ -F \u0026#x27;schema={\u0026quot;type\u0026quot;:\u0026quot;object\u0026quot;,\u0026quot;properties\u0026quot;:{\u0026quot;invoice_number\u0026quot;:{\u0026quot;type\u0026quot;:\u0026quot;string\u0026quot;}}}\u0026#x27; ### Async mode (options.async = true) Returns 202 immediately with an ext_ job id. Poll GET /api/v3/extract/{id} with that same id until status is completed or failed. bash curl -X POST https://api.lighton.ai/api/v3/extract \\ -H \u0026#x27;Authorization: Bearer $TOKEN\u0026#x27; \\ -H \u0026#x27;Content-Type: application/json\u0026#x27; \\ -d \u0026#x27;{\u0026quot;document\u0026quot;: \u0026quot;https://example.com/report.pdf\u0026quot;, \u0026quot;schema\u0026quot;: {\u0026quot;type\u0026quot;: \u0026quot;object\u0026quot;, \u0026quot;properties\u0026quot;: {\u0026quot;title\u0026quot;: {\u0026quot;type\u0026quot;: \u0026quot;string\u0026quot;}}}, \u0026quot;options\u0026quot;: {\u0026quot;async\u0026quot;: true}}\u0026#x27; For multipart uploads, pass options as a JSON-encoded form field: -F \u0026#x27;options={\u0026quot;async\u0026quot;:true}\u0026#x27;. Supported file types: .pdf, .png, .jpg, .jpeg, .pptx, .ppt, .odp, .docx, .odt, .doc, .html Sync limits: 20 MB file size, 15 pages. Async limits: 100 MB file size, 1000 pages.\">\u003cmeta data-mint-head property=\"og:site_name\" content=\"LightOn Developers\">\u003cmeta data-mint-head property=\"og:url\" content=\"https://developers.lighton.ai/api-reference/extract/extract-structured-data-from-a-document\">\u003cmeta data-mint-head property=\"og:type\" content=\"website\">\u003cmeta data-mint-head property=\"og:image\" content=\"https://lighton-developers.mintlify.site/_mintlify/api/og/v2?division=Extract\u0026amp;title=Extract+structured+data+from+a+document\u0026amp;description=Pull+specific+fields+from+a+document+into+a+typed+schema.%0A%0AAccepts+exactly+one+of%3A+a+**file+upload**+%28multipart%2Fform-data%29%2C+a+**document+URL**+%28JSON+body%29%2C+or+a\u0026amp;theme=42de0de5beb070a7d2770d17\u0026amp;signature=b59063620b4bf40977331f77d5611e78f7caebf5e04a9b2fbeaeac4216658bfa\">\u003cmeta data-mint-head property=\"og:image:width\" content=\"1200\">\u003cmeta data-mint-head property=\"og:image:height\" content=\"630\">\u003cmeta data-mint-head name=\"twitter:card\" content=\"summary_large_image\">\u003cmeta data-mint-head name=\"twitter:title\" content=\"Extract structured data from a document - LightOn Developers\">\u003cmeta data-mint-head name=\"twitter:description\" content=\"Pull specific fields from a document into a typed schema. Accepts exactly one of: a file upload (multipart/form-data), a document URL (JSON body), or a file_id referencing an already-ingested document (from POST /v3/files), plus a JSON Schema (the schema field) describing what to extract. ### Sync mode (default) Blocks until extraction completes and returns 200 with the full result. bash curl -X POST https://api.lighton.ai/api/v3/extract \\ -H \u0026#x27;Authorization: Bearer $TOKEN\u0026#x27; \\ -F file=@invoice.pdf \\ -F \u0026#x27;schema={\u0026quot;type\u0026quot;:\u0026quot;object\u0026quot;,\u0026quot;properties\u0026quot;:{\u0026quot;invoice_number\u0026quot;:{\u0026quot;type\u0026quot;:\u0026quot;string\u0026quot;}}}\u0026#x27; ### Async mode (options.async = true) Returns 202 immediately with an ext_ job id. Poll GET /api/v3/extract/{id} with that same id until status is completed or failed. bash curl -X POST https://api.lighton.ai/api/v3/extract \\ -H \u0026#x27;Authorization: Bearer $TOKEN\u0026#x27; \\ -H \u0026#x27;Content-Type: application/json\u0026#x27; \\ -d \u0026#x27;{\u0026quot;document\u0026quot;: \u0026quot;https://example.com/report.pdf\u0026quot;, \u0026quot;schema\u0026quot;: {\u0026quot;type\u0026quot;: \u0026quot;object\u0026quot;, \u0026quot;properties\u0026quot;: {\u0026quot;title\u0026quot;: {\u0026quot;type\u0026quot;: \u0026quot;string\u0026quot;}}}, \u0026quot;options\u0026quot;: {\u0026quot;async\u0026quot;: true}}\u0026#x27; For multipart uploads, pass options as a JSON-encoded form field: -F \u0026#x27;options={\u0026quot;async\u0026quot;:true}\u0026#x27;. Supported file types: .pdf, .png, .jpg, .jpeg, .pptx, .ppt, .odp, .docx, .odt, .doc, .html Sync limits: 20 MB file size, 15 pages. Async limits: 100 MB file size, 1000 pages.\">\u003cmeta data-mint-head name=\"twitter:image\" content=\"https://lighton-developers.mintlify.site/_mintlify/api/og/v2?division=Extract\u0026amp;title=Extract+structured+data+from+a+document\u0026amp;description=Pull+specific+fields+from+a+document+into+a+typed+schema.%0A%0AAccepts+exactly+one+of%3A+a+**file+upload**+%28multipart%2Fform-data%29%2C+a+**document+URL**+%28JSON+body%29%2C+or+a\u0026amp;theme=42de0de5beb070a7d2770d17\u0026amp;signature=b59063620b4bf40977331f77d5611e78f7caebf5e04a9b2fbeaeac4216658bfa\">\u003cmeta data-mint-head name=\"twitter:image:width\" content=\"1200\">\u003cmeta data-mint-head name=\"twitter:image:height\" content=\"630\">\u003cmeta data-mint-head name=\"msapplication-config\" content=\"/mintlify-assets/_mintlify/favicons/lighton-developers/2Zh9Mbvo5QQal47m/_generated/favicon/browserconfig.xml\">\u003cmeta data-mint-head name=\"apple-mobile-web-app-title\" content=\"LightOn Developers\">\u003cmeta data-mint-head name=\"msapplication-TileColor\" content=\"#1f99bb\">\u003clink data-mint-head rel=\"canonical\" href=\"https://developers.lighton.ai/api-reference/extract/extract-structured-data-from-a-document\">\u003clink data-mint-head rel=\"alternate\" type=\"application/xml\" href=\"/sitemap.xml\">\u003clink data-mint-head rel=\"alternate\" type=\"text/markdown\" href=\"/api-reference/extract/extract-structured-data-from-a-document.md\">\u003cscript data-mint-head type=\"application/ld+json\">{\"@context\":\"https://schema.org\",\"@graph\":[{\"@type\":\"Organization\",\"@id\":\"https://developers.lighton.ai/#organization\",\"name\":\"LightOn Developers\",\"url\":\"https://developers.lighton.ai\",\"logo\":{\"@type\":\"ImageObject\",\"url\":\"https://mintcdn.com/lighton-developers/dojq_qF_vSGGGm4-/logo/light.svg?fit=max\u0026auto=format\u0026n=dojq_qF_vSGGGm4-\u0026q=85\u0026s=345d3b10124f99971a7737a9f06f2886\"}},{\"@type\":\"WebSite\",\"@id\":\"https://developers.lighton.ai#website\",\"name\":\"LightOn Developers\",\"url\":\"https://developers.lighton.ai\",\"publisher\":{\"@id\":\"https://developers.lighton.ai/#organization\"}},{\"@type\":\"WebPage\",\"@id\":\"https://developers.lighton.ai/api-reference/extract/extract-structured-data-from-a-document#webpage\",\"url\":\"https://developers.lighton.ai/api-reference/extract/extract-structured-data-from-a-document\",\"name\":\"Extract structured data from a document\",\"description\":\"Pull specific fields from a document into a typed schema. Accepts exactly one of: a file upload (multipart/form-data), a document URL (JSON body), or a file_id referencing an already-ingested document (from POST /v3/files), plus a JSON Schema (the schema field) describing what to extract. ### Sync mode (default) Blocks until extraction completes and returns 200 with the full result. bash curl -X POST https://api.lighton.ai/api/v3/extract \\\\ -H 'Authorization: Bearer $TOKEN' \\\\ -F file=@invoice.pdf \\\\ -F 'schema={\\\"type\\\":\\\"object\\\",\\\"properties\\\":{\\\"invoice_number\\\":{\\\"type\\\":\\\"string\\\"}}}' ### Async mode (options.async = true) Returns 202 immediately with an ext_ job id. Poll GET /api/v3/extract/{id} with that same id until status is completed or failed. bash curl -X POST https://api.lighton.ai/api/v3/extract \\\\ -H 'Authorization: Bearer $TOKEN' \\\\ -H 'Content-Type: application/json' \\\\ -d '{\\\"document\\\": \\\"https://example.com/report.pdf\\\", \\\"schema\\\": {\\\"type\\\": \\\"object\\\", \\\"properties\\\": {\\\"title\\\": {\\\"type\\\": \\\"string\\\"}}}, \\\"options\\\": {\\\"async\\\": true}}' For multipart uploads, pass options as a JSON-encoded form field: -F 'options={\\\"async\\\":true}'. Supported file types: .pdf, .png, .jpg, .jpeg, .pptx, .ppt, .odp, .docx, .odt, .doc, .html Sync limits: 20 MB file size, 15 pages. Async limits: 100 MB file size, 1000 pages.\",\"dateModified\":\"2026-09-16T07:50:03.042Z\",\"isPartOf\":{\"@id\":\"https://developers.lighton.ai#website\"},\"breadcrumb\":{\"@id\":\"https://developers.lighton.ai/api-reference/extract/extract-structured-data-from-a-document#breadcrumb\"}},{\"@type\":\"BreadcrumbList\",\"@id\":\"https://developers.lighton.ai/api-reference/extract/extract-structured-data-from-a-document#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Document Processing\",\"item\":\"https://developers.lighton.ai/api-reference/parse/parse-a-document-to-markdown\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"Extract structured data from a document\",\"item\":\"https://developers.lighton.ai/api-reference/extract/extract-structured-data-from-a-document\"}]},{\"@type\":[\"TechArticle\",\"APIReference\"],\"@id\":\"https://developers.lighton.ai/api-reference/extract/extract-structured-data-from-a-document#apireference\",\"headline\":\"Extract structured data from a document\",\"name\":\"Extract structured data from a document\",\"description\":\"Pull specific fields from a document into a typed schema. Accepts exactly one of: a file upload (multipart/form-data), a document URL (JSON body), or a file_id referencing an already-ingested document (from POST /v3/files), plus a JSON Schema (the schema field) describing what to extract. ### Sync mode (default) Blocks until extraction completes and returns 200 with the full result. bash curl -X POST https://api.lighton.ai/api/v3/extract \\\\ -H 'Authorization: Bearer $TOKEN' \\\\ -F file=@invoice.pdf \\\\ -F 'schema={\\\"type\\\":\\\"object\\\",\\\"properties\\\":{\\\"invoice_number\\\":{\\\"type\\\":\\\"string\\\"}}}' ### Async mode (options.async = true) Returns 202 immediately with an ext_ job id. Poll GET /api/v3/extract/{id} with that same id until status is completed or failed. bash curl -X POST https://api.lighton.ai/api/v3/extract \\\\ -H 'Authorization: Bearer $TOKEN' \\\\ -H 'Content-Type: application/json' \\\\ -d '{\\\"document\\\": \\\"https://example.com/report.pdf\\\", \\\"schema\\\": {\\\"type\\\": \\\"object\\\", \\\"properties\\\": {\\\"title\\\": {\\\"type\\\": \\\"string\\\"}}}, \\\"options\\\": {\\\"async\\\": true}}' For multipart uploads, pass options as a JSON-encoded form field: -F 'options={\\\"async\\\":true}'. Supported file types: .pdf, .png, .jpg, .jpeg, .pptx, .ppt, .odp, .docx, .odt, .doc, .html Sync limits: 20 MB file size, 15 pages. Async limits: 100 MB file size, 1000 pages.\",\"url\":\"https://developers.lighton.ai/api-reference/extract/extract-structured-data-from-a-document\",\"mainEntityOfPage\":{\"@id\":\"https://developers.lighton.ai/api-reference/extract/extract-structured-data-from-a-document#webpage\"},\"dateModified\":\"2026-09-16T07:50:03.042Z\",\"publisher\":{\"@id\":\"https://developers.lighton.ai/#organization\"},\"isPartOf\":{\"@id\":\"https://developers.lighton.ai#website\"}}]}\u003c/script>\u003cscript data-mint-head type=\"application/ld+json\">{\"@context\":\"https://schema.org\",\"@type\":\"WebSite\",\"name\":\"LightOn Developers\",\"publisher\":{\"@type\":\"Organization\",\"name\":\"LightOn Developers\"},\"provider\":{\"@type\":\"Organization\",\"name\":\"Mintlify\",\"url\":\"https://mintlify.com\"}}\u003c/script>","agentPointerHref":"/api-reference/extract/extract-structured-data-from-a-document.md","siteName":"LightOn Developers","nav":{"global":{"anchors":[{"anchor":"Playground","icon":"circle-play","href":"https://console.lighton.ai"}]},"tabs":[{"tab":"Documentation","pages":[{"title":"Documentation","href":""}]},{"tab":"API Reference","groups":[{"group":"Overview","pages":[{"title":"API Reference","href":"/api-reference/introduction"},{"title":"API Errors","href":"/api-reference/v3-error-codes"}]},{"group":"Intelligence","pages":[{"title":"Ask a question over your documents","deprecated":null,"version":null,"openapi":"/api-reference/api-console.yaml post /api/v3/ask","href":"/api-reference/ask/ask-a-question-over-your-documents"},{"title":"Search document chunks","deprecated":null,"version":null,"openapi":"/api-reference/api-console.yaml post /api/v3/search","href":"/api-reference/search/search-document-chunks"},{"group":"Files","pages":[{"title":"List files accessible to the authenticated user","deprecated":null,"version":null,"openapi":"/api-reference/api-console.yaml get /api/v3/files","href":"/api-reference/files/list-files-accessible-to-the-authenticated-user"},{"title":"Upload a file","deprecated":null,"version":null,"openapi":"/api-reference/api-console.yaml post /api/v3/files","href":"/api-reference/files/upload-a-file"},{"title":"Delete multiple files in a single request","deprecated":null,"version":null,"openapi":"/api-reference/api-console.yaml post /api/v3/files/bulk-delete","href":"/api-reference/files/delete-multiple-files-in-a-single-request"},{"title":"Retrieve a single file by ID","deprecated":null,"version":null,"openapi":"/api-reference/api-console.yaml get /api/v3/files/{id}","href":"/api-reference/files/retrieve-a-single-file-by-id"},{"title":"Update file metadata or replace its file","deprecated":null,"version":null,"openapi":"/api-reference/api-console.yaml patch /api/v3/files/{id}","href":"/api-reference/files/update-file-metadata-or-replace-its-file"},{"title":"Delete a file","deprecated":null,"version":null,"openapi":"/api-reference/api-console.yaml delete /api/v3/files/{id}","href":"/api-reference/files/delete-a-file"},{"title":"Download a document file","deprecated":null,"version":null,"openapi":"/api-reference/api-console.yaml get /api/v3/files/{id}/download","href":"/api-reference/files/download-a-document-file"},{"title":"Get document thumbnail","deprecated":null,"version":null,"openapi":"/api-reference/api-console.yaml get /api/v3/files/{id}/thumbnail","href":"/api-reference/files/get-document-thumbnail"}]},{"group":"Facets","pages":[{"title":"List content types","deprecated":null,"version":null,"openapi":"/api-reference/api-console.yaml get /api/v3/content-types","href":"/api-reference/facets/list-content-types"},{"title":"Define content types and attributes","deprecated":null,"version":null,"openapi":"/api-reference/api-console.yaml post /api/v3/content-types","href":"/api-reference/facets/define-content-types-and-attributes"},{"title":"Batch define content types and attributes","deprecated":null,"version":null,"openapi":"/api-reference/api-console.yaml post /api/v3/content-types/batch","href":"/api-reference/facets/batch-define-content-types-and-attributes"},{"title":"Resolve search scope","deprecated":null,"version":null,"openapi":"/api-reference/api-console.yaml post /api/v3/content-types/scope","href":"/api-reference/facets/resolve-search-scope"},{"title":"List content type templates","deprecated":null,"version":null,"openapi":"/api-reference/api-console.yaml get /api/v3/content-types/templates","href":"/api-reference/facets/list-content-type-templates"},{"title":"Resolve search scope","deprecated":null,"version":null,"openapi":"/api-reference/api-console.yaml post /api/v3/content-types/scope","href":"/api-reference/facets/resolve-search-scope"},{"title":"List file classifications and attribute values","deprecated":null,"version":null,"openapi":"/api-reference/api-console.yaml get /api/v3/files/{file_id}/facets","href":"/api-reference/facets/list-file-classifications-and-attribute-values"},{"title":"Classify file and set attribute values","deprecated":null,"version":null,"openapi":"/api-reference/api-console.yaml post /api/v3/files/{file_id}/facets","href":"/api-reference/facets/classify-file-and-set-attribute-values"},{"title":"Batch classify and set attribute values","deprecated":null,"version":null,"openapi":"/api-reference/api-console.yaml post /api/v3/files/{file_id}/facets/batch","href":"/api-reference/facets/batch-classify-and-set-attribute-values"}]},{"group":"Tags","pages":[{"title":"List all tags for the authenticated user's company","deprecated":null,"version":null,"openapi":"/api-reference/api-console.yaml get /api/v3/tags","href":"/api-reference/tags/list-all-tags-for-the-authenticated-users-company"},{"title":"Create a new tag for the company","deprecated":null,"version":null,"openapi":"/api-reference/api-console.yaml post /api/v3/tags","href":"/api-reference/tags/create-a-new-tag-for-the-company"},{"title":"Delete a company tag","deprecated":null,"version":null,"openapi":"/api-reference/api-console.yaml delete /api/v3/tags/{id}","href":"/api-reference/tags/delete-a-company-tag"},{"title":"Add tags to a file","deprecated":null,"version":null,"openapi":"/api-reference/api-console.yaml post /api/v3/files/{id}/tags","href":"/api-reference/files/add-tags-to-a-file"},{"title":"Remove a tag from a file","deprecated":null,"version":null,"openapi":"/api-reference/api-console.yaml delete /api/v3/files/{id}/tags/{tag_id}","href":"/api-reference/files/remove-a-tag-from-a-file"}]},{"group":"Workspaces","pages":[{"title":"List workspaces","deprecated":null,"version":null,"openapi":"/api-reference/api-console.yaml get /api/v3/workspaces","href":"/api-reference/workspaces/list-workspaces"},{"title":"Create a workspace","deprecated":null,"version":null,"openapi":"/api-reference/api-console.yaml post /api/v3/workspaces","href":"/api-reference/workspaces/create-a-workspace"},{"title":"Retrieve a workspace","deprecated":null,"version":null,"openapi":"/api-reference/api-console.yaml get /api/v3/workspaces/{id}","href":"/api-reference/workspaces/retrieve-a-workspace"},{"title":"Update a workspace","deprecated":null,"version":null,"openapi":"/api-reference/api-console.yaml patch /api/v3/workspaces/{id}","href":"/api-reference/workspaces/update-a-workspace"},{"title":"Delete a workspace","deprecated":null,"version":null,"openapi":"/api-reference/api-console.yaml delete /api/v3/workspaces/{id}","href":"/api-reference/workspaces/delete-a-workspace"},{"title":"Browse datasource folders","deprecated":null,"version":null,"openapi":"/api-reference/api-console.yaml post /api/v3/workspaces/datasource/browse","href":"/api-reference/workspaces/browse-datasource-folders"},{"title":"Test datasource credentials","deprecated":null,"version":null,"openapi":"/api-reference/api-console.yaml post /api/v3/workspaces/datasource/test","href":"/api-reference/workspaces/test-datasource-credentials"}]}]},{"group":"Document Processing","pages":[{"group":"Parse","pages":[{"title":"Parse a document to Markdown","deprecated":null,"version":null,"openapi":"/api-reference/api-console.yaml post /api/v3/parse","href":"/api-reference/parse/parse-a-document-to-markdown"},{"title":"Get the status and result of an async parse job","deprecated":null,"version":null,"openapi":"/api-reference/api-console.yaml get /api/v3/parse/{id}","href":"/api-reference/parse/get-the-status-and-result-of-an-async-parse-job"},{"title":"Render a document as PDF","description":"Convert a document into a PDF suitable for inline preview.\n\nAccepts a **file upload** (multipart/form-data), a **document URL**, or a **file_id** referencing a document already ingested in the platform (JSON body). The conversion is synchronous — the PDF bytes are returned directly.\n\n**Supported file types:** `.pdf`, `.png`, `.jpg`, `.jpeg`, `.pptx`, `.ppt`, `.odp`, `.docx`, `.odt`, `.doc`, `.html`, `.xhtml`\n\n**Size limit:** 20 MB.","deprecated":null,"version":null,"openapi":"/api-reference/api-console.yaml post /api/v3/preview","href":"/api-reference/parse/render-a-document-as-pdf"}]},{"group":"Extract","pages":[{"title":"Extract structured data from a document","deprecated":null,"version":null,"openapi":"/api-reference/api-console.yaml post /api/v3/extract","href":"/api-reference/extract/extract-structured-data-from-a-document"},{"title":"Get the status and result of an async extract job","description":"Poll for the status and result of an async extract job submitted via `POST /api/v3/extract` with `options.async=true`. Returns the same envelope shape as the synchronous extract endpoint once `status` is `completed`.\n\n```bash\ncurl https://api.lighton.ai/api/v3/extract/ext_0196e4b2a3c14d5e \\\n -H 'Authorization: Bearer $TOKEN'\n```\n\n**Pagination:** when completed, `result.data` is paginated with a fixed page size of 15. Use the `page` query param (1-based) to navigate; `result.pagination` reports `total_items`, `total_pages`, `has_next`, `has_prev`.\n\n**Recommended polling cadence:** 1s for the first 10s, then 5s, capped at 30s. Stop polling once `status` is in `{completed, failed}`.","deprecated":null,"version":null,"openapi":"/api-reference/api-console.yaml get /api/v3/extract/{job_id}","href":"/api-reference/extract/get-the-status-and-result-of-an-async-extract-job"}]}]},{"group":"Administration","pages":[{"group":"API Keys","pages":[{"title":"List API keys","deprecated":null,"version":null,"openapi":"/api-reference/api-console.yaml get /api/v3/keys","href":"/api-reference/api-keys/list-api-keys"},{"title":"Create API key","deprecated":null,"version":null,"openapi":"/api-reference/api-console.yaml post /api/v3/keys","href":"/api-reference/api-keys/create-api-key"},{"title":"Retrieve API key","deprecated":null,"version":null,"openapi":"/api-reference/api-console.yaml get /api/v3/keys/{id}","href":"/api-reference/api-keys/retrieve-api-key"},{"title":"Update API key","deprecated":null,"version":null,"openapi":"/api-reference/api-console.yaml patch /api/v3/keys/{id}","href":"/api-reference/api-keys/update-api-key"},{"title":"Revoke API key","deprecated":null,"version":null,"openapi":"/api-reference/api-console.yaml delete /api/v3/keys/{id}","href":"/api-reference/api-keys/revoke-api-key"}]},{"group":"Budget","pages":[{"title":"Get company budget","deprecated":null,"version":null,"openapi":"/api-reference/api-console.yaml get /api/v3/billing/budget","href":"/api-reference/budget/get-company-budget"},{"title":"Create or update company budget","deprecated":null,"version":null,"openapi":"/api-reference/api-console.yaml put /api/v3/billing/budget","href":"/api-reference/budget/create-or-update-company-budget"},{"title":"Delete company budget","deprecated":null,"version":null,"openapi":"/api-reference/api-console.yaml delete /api/v3/billing/budget","href":"/api-reference/budget/delete-company-budget"},{"title":"List budget alerts","deprecated":null,"version":null,"openapi":"/api-reference/api-console.yaml get /api/v3/billing/budget/alerts","href":"/api-reference/budget/list-budget-alerts"},{"title":"Create budget alert","deprecated":null,"version":null,"openapi":"/api-reference/api-console.yaml post /api/v3/billing/budget/alerts","href":"/api-reference/budget/create-budget-alert"},{"title":"Toggle all budget alerts","deprecated":null,"version":null,"openapi":"/api-reference/api-console.yaml patch /api/v3/billing/budget/alerts","href":"/api-reference/budget/toggle-all-budget-alerts"},{"title":"Update budget alert","deprecated":null,"version":null,"openapi":"/api-reference/api-console.yaml patch /api/v3/billing/budget/alerts/{id}","href":"/api-reference/budget/update-budget-alert"},{"title":"Delete budget alert","deprecated":null,"version":null,"openapi":"/api-reference/api-console.yaml delete /api/v3/billing/budget/alerts/{id}","href":"/api-reference/budget/delete-budget-alert"}]}]}]},{"tab":"Tutorials","pages":[{"title":"Tutorials","href":"/tutorials"}]},{"tab":"Settings","pages":[{"title":"Settings","href":"/untitled-page"}]},{"tab":"Integrations","pages":[{"title":"Integrations","href":"/integrations"}]},{"tab":"MCP Server","pages":[{"title":"MCP Server","href":"/mcp-server/quickstart"}]},{"tab":"SDKs","pages":[{"title":"SDKs","href":"/sdks"}]},{"tab":"Use Cases","pages":[{"title":"Use Cases","href":"/use-cases"}]},{"tab":"Legal","pages":[{"title":"Legal","href":"/legal/terms-of-use"}]},{"tab":"Support","pages":[{"title":"Support","href":"/support"}]}]},"basePath":"","title":"Extract structured data from a document - LightOn Developers","deploymentId":"dpl_7AgmPo2RyRWZ68ZGceW618SWGEAz","buildId":"dpl_7AgmPo2RyRWZ68ZGceW618SWGEAz","dynamics":["c2aa737661","2b790eda92","b0f84f53ff","a9bb46feb3"],"chunks":["OpenApiReferenceProvider-wzXgrCiA.js","snippetPresets-Ctn0LgL5.js","utils-knxdv-fi.js","style-to-object-BY3JEAdk.js","utils-Szn2cJIN.js","v4-DIgz8zy6.js","addUniqueKeysToSchema-CYggQ38U.js","conditional-requirements-CFM0id0Q.js","cloneDeep-a_SFy_bM.js","_Uint8Array-CYON-SEw.js","isObject-FP1Yky1u.js","ApiExamples-Bp2XNIJ2.js","usePlaygroundInputsStore-Bv5ea2yO.js","shallow-BeX-jZPB.js","isEqual-DiyXA5rL.js","CodeSnippets-DXnnQSz3.js","CodeSnippet-Ba_bs1zd.js","getApiPlaygroundDisplay-D0IrdxIN.js","Page-Dn3dap3J.js","DynamicMarkdown-T8UDalrO.js","SectionHeading-DANTRrnD.js","icon-Mqg-z9_o.js","MethodPill-gS6fR7OH.js","getPastedJson-B3wZ4biI.js","Check2Icon-BT0wGl3r.js","axios-CsQoIw0U.js","Markdown-DUz08Fig.js","AssistantPageLink-D3sNlIci.js","dist-BbIWfytJ.js","lib-DMeTj1gb.js","lib-B8HbPgcC.js","katex-Dbtb6Wk7.js","html-void-elements-mCSPHezU.js","marked.esm-CZWythHk.js"]}