Skip to content

Extract

Create Extract Job
client.extract.create(ExtractCreateParams { file_input, organization_id, project_id, 4 more } params, RequestOptionsoptions?): ExtractV2Job { id, created_at, file_input, 10 more }
POST/api/v2/extract
List Extract Jobs
client.extract.list(ExtractListParams { configuration_id, created_at_on_or_after, created_at_on_or_before, 11 more } query?, RequestOptionsoptions?): PaginatedCursor<ExtractV2Job { id, created_at, file_input, 10 more } >
GET/api/v2/extract
Get Extract Job
client.extract.get(stringjobID, ExtractGetParams { expand, organization_id, project_id } query?, RequestOptionsoptions?): ExtractV2Job { id, created_at, file_input, 10 more }
GET/api/v2/extract/{job_id}
Delete Extract Job
client.extract.delete(stringjobID, ExtractDeleteParams { force, organization_id, project_id } params?, RequestOptionsoptions?): ExtractDeleteResponse
DELETE/api/v2/extract/{job_id}
Cancel Extract Job
client.extract.cancel(stringjobID, ExtractCancelParams { organization_id, project_id } params?, RequestOptionsoptions?): ExtractV2Job { id, created_at, file_input, 10 more }
POST/api/v2/extract/{job_id}/cancel
Validate Extraction Schema
client.extract.validateSchema(ExtractValidateSchemaParams { data_schema } body, RequestOptionsoptions?): ExtractV2SchemaValidateResponse { data_schema }
POST/api/v2/extract/schema/validation
Generate Extraction Schema
client.extract.generateSchema(ExtractGenerateSchemaParams { organization_id, project_id, data_schema, 3 more } params, RequestOptionsoptions?): ConfigurationCreate { name, parameters }
POST/api/v2/extract/schema/generate
ModelsExpand Collapse
ExtractConfiguration { data_schema, advanced_citations, cite_sources, 13 more }

Extract configuration combining parse and extract settings.

data_schema: Record<string, Record<string, unknown> | Array<unknown> | string | 2 more | null>

JSON Schema defining the fields to extract. Validate with the /schema/validate endpoint first.

One of the following:
Record<string, unknown>
Array<unknown>
string
number
boolean
advanced_citations?: boolean

More precise citation bounding boxes. Set to false for faster extraction with less precise boxes.

cite_sources?: boolean

Include citations in results. Returned under extract_metadata (auto-included when set). Text-level on turbo (no bounding boxes).

confidence_scores?: boolean

Include confidence scores in results. Returned under extract_metadata (auto-included when set).

disable_cache?: boolean

Disable reuse and storage of Extract results

effort?: "max" | null

Use ‘max’ for additional processing effort on agentic_plus. Priced by the processing each document needs, with the page price as the minimum. Omit or set to null for the tier’s default behavior.

extraction_target?: "per_doc" | "per_page" | "per_table_row"

Deprecated. Applies only to Agentic and Cost Effective versions 2.0 or earlier. Granularity of extraction: per_doc returns one object per document, per_page returns one object per page, per_table_row returns one object per table row. Agentic Plus supports per_doc only.

One of the following:
"per_doc"
"per_page"
"per_table_row"
max_pages?: number | null

Maximum number of pages to process. Omit for no limit.

minimum1
parse_config_id?: string | null

Saved parse configuration ID to control how the document is parsed before extraction. Turbo extract does not support parse configuration or produce a parse output; use another tier if your workflow requires parsed text.

parse_tier?: "agentic" | "agentic_plus" | "cost_effective" | "fast" | null

Parse tier to use before extraction. Defaults to the extract tier if not specified. Turbo extract does not support parse configuration or produce a parse output; use another tier if your workflow requires parsed text.

One of the following:
"agentic"
"agentic_plus"
"cost_effective"
"fast"
sheet_names?: Array<string> | null

Optional worksheet names to extract when spreadsheet_mode is on. Overrides target_pages for spreadsheets; omit to extract every sheet. Names are matched exactly (case-sensitive) — pass them as a list, e.g. [“Sheet 1”, “My Sheet”].

spreadsheet_mode?: boolean

Extract structured data directly from spreadsheet cells (.xlsx/.xls/.csv). Billed at the standard per-page Extract rate, with page count derived from workbook size.

system_prompt?: string | null

Custom system prompt to guide extraction behavior

target_pages?: string | null

Comma-separated page numbers or ranges to process (1-based). Omit to process all pages.

tier?: "agentic" | "agentic_plus" | "cost_effective" | "turbo"

Extract tier: cost_effective (5 credits/page), agentic (15 credits/page), agentic_plus (50 credits/page), or turbo (35 credits/page)

One of the following:
"agentic"
"agentic_plus"
"cost_effective"
"turbo"
version?: string

Extract version name, such as ‘2.5’. Use ‘latest’ for the newest compatible release for the selected tier. Dates (YYYY-MM-DD) are also supported, which will use the latest version on or before the specified date.

ExtractJobMetadata { field_metadata, parse_job_id, parse_tier }

Extraction metadata.

field_metadata?: ExtractedFieldMetadata { document_metadata, page_metadata, row_metadata } | null

Metadata for extracted fields including document, page, and row level info.

document_metadata?: Record<string, Record<string, unknown> | Array<unknown> | string | 2 more | null> | null

Per-field metadata keyed by field name from your schema. Scalar fields (e.g. vendor) map to a FieldMetadataEntry with citation and confidence. Array fields (e.g. items) map to a list where each element contains per-sub-field FieldMetadataEntry objects, indexed by array position. Nested objects contain sub-field entries recursively.

One of the following:
Record<string, unknown>
Array<unknown>
string
number
boolean
page_metadata?: Array<Record<string, Record<string, unknown> | Array<unknown> | string | 2 more | null>> | null

Per-page metadata when extraction_target is per_page

One of the following:
Record<string, unknown>
Array<unknown>
string
number
boolean
row_metadata?: Array<Record<string, Record<string, unknown> | Array<unknown> | string | 2 more | null>> | null

Per-row metadata when extraction_target is per_table_row

One of the following:
Record<string, unknown>
Array<unknown>
string
number
boolean
parse_job_id?: string | null

Reference to the ParseJob ID used for parsing

parse_tier?: string | null

Parse tier used for parsing the document

ExtractJobUsage { num_pages_billed, num_pages_extracted }

Extraction usage metrics.

num_pages_billed?: number | null

Number of effective pages billed

num_pages_extracted?: number | null

Number of pages extracted

ExtractV2Job { id, created_at, file_input, 10 more }

An extraction job.

id: string

Unique job identifier (job_id)

created_at: string

Creation timestamp

formatdate-time
file_input: string

File ID or parse job ID that was extracted

project_id: string

Project this job belongs to

status: string

Current job status.

  • PENDING — queued, not yet started
  • RUNNING — actively processing
  • COMPLETED — finished successfully
  • FAILED — terminated with an error
  • CANCELLED — cancelled by user
updated_at: string

Last update timestamp

formatdate-time
configuration?: ExtractConfiguration { data_schema, advanced_citations, cite_sources, 13 more } | null

Extract configuration combining parse and extract settings.

data_schema: Record<string, Record<string, unknown> | Array<unknown> | string | 2 more | null>

JSON Schema defining the fields to extract. Validate with the /schema/validate endpoint first.

One of the following:
Record<string, unknown>
Array<unknown>
string
number
boolean
advanced_citations?: boolean

More precise citation bounding boxes. Set to false for faster extraction with less precise boxes.

cite_sources?: boolean

Include citations in results. Returned under extract_metadata (auto-included when set). Text-level on turbo (no bounding boxes).

confidence_scores?: boolean

Include confidence scores in results. Returned under extract_metadata (auto-included when set).

disable_cache?: boolean

Disable reuse and storage of Extract results

effort?: "max" | null

Use ‘max’ for additional processing effort on agentic_plus. Priced by the processing each document needs, with the page price as the minimum. Omit or set to null for the tier’s default behavior.

extraction_target?: "per_doc" | "per_page" | "per_table_row"

Deprecated. Applies only to Agentic and Cost Effective versions 2.0 or earlier. Granularity of extraction: per_doc returns one object per document, per_page returns one object per page, per_table_row returns one object per table row. Agentic Plus supports per_doc only.

One of the following:
"per_doc"
"per_page"
"per_table_row"
max_pages?: number | null

Maximum number of pages to process. Omit for no limit.

minimum1
parse_config_id?: string | null

Saved parse configuration ID to control how the document is parsed before extraction. Turbo extract does not support parse configuration or produce a parse output; use another tier if your workflow requires parsed text.

parse_tier?: "agentic" | "agentic_plus" | "cost_effective" | "fast" | null

Parse tier to use before extraction. Defaults to the extract tier if not specified. Turbo extract does not support parse configuration or produce a parse output; use another tier if your workflow requires parsed text.

One of the following:
"agentic"
"agentic_plus"
"cost_effective"
"fast"
sheet_names?: Array<string> | null

Optional worksheet names to extract when spreadsheet_mode is on. Overrides target_pages for spreadsheets; omit to extract every sheet. Names are matched exactly (case-sensitive) — pass them as a list, e.g. [“Sheet 1”, “My Sheet”].

spreadsheet_mode?: boolean

Extract structured data directly from spreadsheet cells (.xlsx/.xls/.csv). Billed at the standard per-page Extract rate, with page count derived from workbook size.

system_prompt?: string | null

Custom system prompt to guide extraction behavior

target_pages?: string | null

Comma-separated page numbers or ranges to process (1-based). Omit to process all pages.

tier?: "agentic" | "agentic_plus" | "cost_effective" | "turbo"

Extract tier: cost_effective (5 credits/page), agentic (15 credits/page), agentic_plus (50 credits/page), or turbo (35 credits/page)

One of the following:
"agentic"
"agentic_plus"
"cost_effective"
"turbo"
version?: string

Extract version name, such as ‘2.5’. Use ‘latest’ for the newest compatible release for the selected tier. Dates (YYYY-MM-DD) are also supported, which will use the latest version on or before the specified date.

configuration_id?: string | null

Saved extract configuration ID used for this job, if any

error_message?: string | null

Error details when status is FAILED

extract_metadata?: ExtractJobMetadata { field_metadata, parse_job_id, parse_tier } | null

Extraction metadata.

field_metadata?: ExtractedFieldMetadata { document_metadata, page_metadata, row_metadata } | null

Metadata for extracted fields including document, page, and row level info.

document_metadata?: Record<string, Record<string, unknown> | Array<unknown> | string | 2 more | null> | null

Per-field metadata keyed by field name from your schema. Scalar fields (e.g. vendor) map to a FieldMetadataEntry with citation and confidence. Array fields (e.g. items) map to a list where each element contains per-sub-field FieldMetadataEntry objects, indexed by array position. Nested objects contain sub-field entries recursively.

One of the following:
Record<string, unknown>
Array<unknown>
string
number
boolean
page_metadata?: Array<Record<string, Record<string, unknown> | Array<unknown> | string | 2 more | null>> | null

Per-page metadata when extraction_target is per_page

One of the following:
Record<string, unknown>
Array<unknown>
string
number
boolean
row_metadata?: Array<Record<string, Record<string, unknown> | Array<unknown> | string | 2 more | null>> | null

Per-row metadata when extraction_target is per_table_row

One of the following:
Record<string, unknown>
Array<unknown>
string
number
boolean
parse_job_id?: string | null

Reference to the ParseJob ID used for parsing

parse_tier?: string | null

Parse tier used for parsing the document

extract_result?: Record<string, Record<string, unknown> | Array<unknown> | string | 2 more | null> | Array<Record<string, Record<string, unknown> | Array<unknown> | string | 2 more | null>> | null

Extracted data conforming to the data_schema. Returns a single object for per_doc, or an array for per_page / per_table_row.

One of the following:
Record<string, Record<string, unknown> | Array<unknown> | string | 2 more | null>
Record<string, unknown>
Array<unknown>
string
number
boolean
Array<Record<string, Record<string, unknown> | Array<unknown> | string | 2 more | null>>
Record<string, unknown>
Array<unknown>
string
number
boolean
metadata?: Metadata | null

Job-level metadata.

usage?: ExtractJobUsage { num_pages_billed, num_pages_extracted } | null

Extraction usage metrics.

num_pages_billed?: number | null

Number of effective pages billed

num_pages_extracted?: number | null

Number of pages extracted

usage?: Usage | null

Usage recorded against an extract job.

A parse job can back several extract jobs, so each of them reports that same parse cost in its total.

credits?: number | null

Total credits billed against this job. Null until billing has recorded it.

extract_credits?: number | null

Credits billed for the extraction itself

parse_credits?: number | null

Credits billed against the parse job backing this extract job

ExtractV2JobCreate { file_input, configuration, configuration_id, 2 more }

Request to create an extraction job. Provide configuration_id or inline configuration.

file_input: string

File ID or parse job ID to extract from

maxLength200
configuration?: ExtractConfiguration { data_schema, advanced_citations, cite_sources, 13 more } | null

Extract configuration combining parse and extract settings.

data_schema: Record<string, Record<string, unknown> | Array<unknown> | string | 2 more | null>

JSON Schema defining the fields to extract. Validate with the /schema/validate endpoint first.

One of the following:
Record<string, unknown>
Array<unknown>
string
number
boolean
advanced_citations?: boolean

More precise citation bounding boxes. Set to false for faster extraction with less precise boxes.

cite_sources?: boolean

Include citations in results. Returned under extract_metadata (auto-included when set). Text-level on turbo (no bounding boxes).

confidence_scores?: boolean

Include confidence scores in results. Returned under extract_metadata (auto-included when set).

disable_cache?: boolean

Disable reuse and storage of Extract results

effort?: "max" | null

Use ‘max’ for additional processing effort on agentic_plus. Priced by the processing each document needs, with the page price as the minimum. Omit or set to null for the tier’s default behavior.

extraction_target?: "per_doc" | "per_page" | "per_table_row"

Deprecated. Applies only to Agentic and Cost Effective versions 2.0 or earlier. Granularity of extraction: per_doc returns one object per document, per_page returns one object per page, per_table_row returns one object per table row. Agentic Plus supports per_doc only.

One of the following:
"per_doc"
"per_page"
"per_table_row"
max_pages?: number | null

Maximum number of pages to process. Omit for no limit.

minimum1
parse_config_id?: string | null

Saved parse configuration ID to control how the document is parsed before extraction. Turbo extract does not support parse configuration or produce a parse output; use another tier if your workflow requires parsed text.

parse_tier?: "agentic" | "agentic_plus" | "cost_effective" | "fast" | null

Parse tier to use before extraction. Defaults to the extract tier if not specified. Turbo extract does not support parse configuration or produce a parse output; use another tier if your workflow requires parsed text.

One of the following:
"agentic"
"agentic_plus"
"cost_effective"
"fast"
sheet_names?: Array<string> | null

Optional worksheet names to extract when spreadsheet_mode is on. Overrides target_pages for spreadsheets; omit to extract every sheet. Names are matched exactly (case-sensitive) — pass them as a list, e.g. [“Sheet 1”, “My Sheet”].

spreadsheet_mode?: boolean

Extract structured data directly from spreadsheet cells (.xlsx/.xls/.csv). Billed at the standard per-page Extract rate, with page count derived from workbook size.

system_prompt?: string | null

Custom system prompt to guide extraction behavior

target_pages?: string | null

Comma-separated page numbers or ranges to process (1-based). Omit to process all pages.

tier?: "agentic" | "agentic_plus" | "cost_effective" | "turbo"

Extract tier: cost_effective (5 credits/page), agentic (15 credits/page), agentic_plus (50 credits/page), or turbo (35 credits/page)

One of the following:
"agentic"
"agentic_plus"
"cost_effective"
"turbo"
version?: string

Extract version name, such as ‘2.5’. Use ‘latest’ for the newest compatible release for the selected tier. Dates (YYYY-MM-DD) are also supported, which will use the latest version on or before the specified date.

configuration_id?: string | null

Saved configuration ID

webhook_configuration_ids?: Array<string> | null

IDs of saved webhook configurations to notify for this job.

webhook_configurations?: Array<WebhookConfiguration> | null

Outbound webhook endpoints to notify on job status changes

webhook_events?: Array<"batch.cancelled" | "batch.error" | "batch.pending" | 36 more> | null

Events to subscribe to (e.g. ‘parse.success’, ‘extract.error’). If null, all events are delivered.

One of the following:
"batch.cancelled"
"batch.error"
"batch.pending"
"batch.running"
"batch.success"
"classify.cancelled"
"classify.error"
"classify.partial_success"
"classify.pending"
"classify.running"
"classify.success"
"extract.cancelled"
"extract.error"
"extract.partial_success"
"extract.pending"
"extract.running"
"extract.success"
"parse.cancelled"
"parse.error"
"parse.partial_success"
"parse.pending"
"parse.running"
"parse.success"
"sheets.cancelled"
"sheets.error"
"sheets.partial_success"
"sheets.pending"
"sheets.success"
"split.cancelled"
"split.error"
"split.pending"
"split.processing"
"split.success"
"unmapped_event"
"verify.cancelled"
"verify.error"
"verify.pending"
"verify.running"
"verify.success"
webhook_headers?: Record<string, string> | null

Custom HTTP headers sent with each webhook request (e.g. auth tokens)

webhook_output_format?: string | null

Response format sent to the webhook: ‘string’ (default) or ‘json’

webhook_signing_secret?: string | null

Shared signing secret used to sign webhook deliveries. When set, each request includes an HMAC-SHA256 signature of the request body in the ‘LC-Signature’ header (value ‘sha256=’). Recompute the HMAC over the raw request body with this secret to verify the delivery is authentic.

webhook_url?: string | null

URL to receive webhook POST notifications

ExtractV2JobQueryResponse { items, next_page_token, total_size }

Paginated list of extraction jobs.

items: Array<ExtractV2Job { id, created_at, file_input, 10 more } >

The list of items.

id: string

Unique job identifier (job_id)

created_at: string

Creation timestamp

formatdate-time
file_input: string

File ID or parse job ID that was extracted

project_id: string

Project this job belongs to

status: string

Current job status.

  • PENDING — queued, not yet started
  • RUNNING — actively processing
  • COMPLETED — finished successfully
  • FAILED — terminated with an error
  • CANCELLED — cancelled by user
updated_at: string

Last update timestamp

formatdate-time
configuration?: ExtractConfiguration { data_schema, advanced_citations, cite_sources, 13 more } | null

Extract configuration combining parse and extract settings.

data_schema: Record<string, Record<string, unknown> | Array<unknown> | string | 2 more | null>

JSON Schema defining the fields to extract. Validate with the /schema/validate endpoint first.

One of the following:
Record<string, unknown>
Array<unknown>
string
number
boolean
advanced_citations?: boolean

More precise citation bounding boxes. Set to false for faster extraction with less precise boxes.

cite_sources?: boolean

Include citations in results. Returned under extract_metadata (auto-included when set). Text-level on turbo (no bounding boxes).

confidence_scores?: boolean

Include confidence scores in results. Returned under extract_metadata (auto-included when set).

disable_cache?: boolean

Disable reuse and storage of Extract results

effort?: "max" | null

Use ‘max’ for additional processing effort on agentic_plus. Priced by the processing each document needs, with the page price as the minimum. Omit or set to null for the tier’s default behavior.

extraction_target?: "per_doc" | "per_page" | "per_table_row"

Deprecated. Applies only to Agentic and Cost Effective versions 2.0 or earlier. Granularity of extraction: per_doc returns one object per document, per_page returns one object per page, per_table_row returns one object per table row. Agentic Plus supports per_doc only.

One of the following:
"per_doc"
"per_page"
"per_table_row"
max_pages?: number | null

Maximum number of pages to process. Omit for no limit.

minimum1
parse_config_id?: string | null

Saved parse configuration ID to control how the document is parsed before extraction. Turbo extract does not support parse configuration or produce a parse output; use another tier if your workflow requires parsed text.

parse_tier?: "agentic" | "agentic_plus" | "cost_effective" | "fast" | null

Parse tier to use before extraction. Defaults to the extract tier if not specified. Turbo extract does not support parse configuration or produce a parse output; use another tier if your workflow requires parsed text.

One of the following:
"agentic"
"agentic_plus"
"cost_effective"
"fast"
sheet_names?: Array<string> | null

Optional worksheet names to extract when spreadsheet_mode is on. Overrides target_pages for spreadsheets; omit to extract every sheet. Names are matched exactly (case-sensitive) — pass them as a list, e.g. [“Sheet 1”, “My Sheet”].

spreadsheet_mode?: boolean

Extract structured data directly from spreadsheet cells (.xlsx/.xls/.csv). Billed at the standard per-page Extract rate, with page count derived from workbook size.

system_prompt?: string | null

Custom system prompt to guide extraction behavior

target_pages?: string | null

Comma-separated page numbers or ranges to process (1-based). Omit to process all pages.

tier?: "agentic" | "agentic_plus" | "cost_effective" | "turbo"

Extract tier: cost_effective (5 credits/page), agentic (15 credits/page), agentic_plus (50 credits/page), or turbo (35 credits/page)

One of the following:
"agentic"
"agentic_plus"
"cost_effective"
"turbo"
version?: string

Extract version name, such as ‘2.5’. Use ‘latest’ for the newest compatible release for the selected tier. Dates (YYYY-MM-DD) are also supported, which will use the latest version on or before the specified date.

configuration_id?: string | null

Saved extract configuration ID used for this job, if any

error_message?: string | null

Error details when status is FAILED

extract_metadata?: ExtractJobMetadata { field_metadata, parse_job_id, parse_tier } | null

Extraction metadata.

field_metadata?: ExtractedFieldMetadata { document_metadata, page_metadata, row_metadata } | null

Metadata for extracted fields including document, page, and row level info.

document_metadata?: Record<string, Record<string, unknown> | Array<unknown> | string | 2 more | null> | null

Per-field metadata keyed by field name from your schema. Scalar fields (e.g. vendor) map to a FieldMetadataEntry with citation and confidence. Array fields (e.g. items) map to a list where each element contains per-sub-field FieldMetadataEntry objects, indexed by array position. Nested objects contain sub-field entries recursively.

One of the following:
Record<string, unknown>
Array<unknown>
string
number
boolean
page_metadata?: Array<Record<string, Record<string, unknown> | Array<unknown> | string | 2 more | null>> | null

Per-page metadata when extraction_target is per_page

One of the following:
Record<string, unknown>
Array<unknown>
string
number
boolean
row_metadata?: Array<Record<string, Record<string, unknown> | Array<unknown> | string | 2 more | null>> | null

Per-row metadata when extraction_target is per_table_row

One of the following:
Record<string, unknown>
Array<unknown>
string
number
boolean
parse_job_id?: string | null

Reference to the ParseJob ID used for parsing

parse_tier?: string | null

Parse tier used for parsing the document

extract_result?: Record<string, Record<string, unknown> | Array<unknown> | string | 2 more | null> | Array<Record<string, Record<string, unknown> | Array<unknown> | string | 2 more | null>> | null

Extracted data conforming to the data_schema. Returns a single object for per_doc, or an array for per_page / per_table_row.

One of the following:
Record<string, Record<string, unknown> | Array<unknown> | string | 2 more | null>
Record<string, unknown>
Array<unknown>
string
number
boolean
Array<Record<string, Record<string, unknown> | Array<unknown> | string | 2 more | null>>
Record<string, unknown>
Array<unknown>
string
number
boolean
metadata?: Metadata | null

Job-level metadata.

usage?: ExtractJobUsage { num_pages_billed, num_pages_extracted } | null

Extraction usage metrics.

num_pages_billed?: number | null

Number of effective pages billed

num_pages_extracted?: number | null

Number of pages extracted

usage?: Usage | null

Usage recorded against an extract job.

A parse job can back several extract jobs, so each of them reports that same parse cost in its total.

credits?: number | null

Total credits billed against this job. Null until billing has recorded it.

extract_credits?: number | null

Credits billed for the extraction itself

parse_credits?: number | null

Credits billed against the parse job backing this extract job

next_page_token?: string | null

A token, which can be sent as page_token to retrieve the next page. If this field is omitted, there are no subsequent pages.

total_size?: number | null

The total number of items available. This is only populated when specifically requested. The value may be an estimate and can be used for display purposes only.

ExtractV2SchemaGenerateRequest { data_schema, file_id, name, prompt }

Request schema for generating an extraction schema.

data_schema?: Record<string, Record<string, unknown> | Array<unknown> | string | 2 more | null> | null

Optional schema to validate, refine, or extend

One of the following:
Record<string, unknown>
Array<unknown>
string
number
boolean
file_id?: string | null

Optional file ID to analyze for schema generation

name?: string | null

Name for the generated configuration (auto-generated if omitted)

maxLength255
prompt?: string | null

Natural language description of the data structure to extract

ExtractV2SchemaValidateRequest { data_schema }

Request schema for validating an extraction schema.

data_schema: Record<string, Record<string, unknown> | Array<unknown> | string | 2 more | null>

JSON Schema to validate for use with extract jobs

One of the following:
Record<string, unknown>
Array<unknown>
string
number
boolean
ExtractV2SchemaValidateResponse { data_schema }

Response schema for schema validation.

data_schema: Record<string, Record<string, unknown> | Array<unknown> | string | 2 more | null>

Validated JSON Schema, ready for use in extract jobs

One of the following:
Record<string, unknown>
Array<unknown>
string
number
boolean
ExtractedFieldMetadata { document_metadata, page_metadata, row_metadata }

Metadata for extracted fields including document, page, and row level info.

document_metadata?: Record<string, Record<string, unknown> | Array<unknown> | string | 2 more | null> | null

Per-field metadata keyed by field name from your schema. Scalar fields (e.g. vendor) map to a FieldMetadataEntry with citation and confidence. Array fields (e.g. items) map to a list where each element contains per-sub-field FieldMetadataEntry objects, indexed by array position. Nested objects contain sub-field entries recursively.

One of the following:
Record<string, unknown>
Array<unknown>
string
number
boolean
page_metadata?: Array<Record<string, Record<string, unknown> | Array<unknown> | string | 2 more | null>> | null

Per-page metadata when extraction_target is per_page

One of the following:
Record<string, unknown>
Array<unknown>
string
number
boolean
row_metadata?: Array<Record<string, Record<string, unknown> | Array<unknown> | string | 2 more | null>> | null

Per-row metadata when extraction_target is per_table_row

One of the following:
Record<string, unknown>
Array<unknown>
string
number
boolean
ExtractDeleteResponse = unknown

ExtractReview

Create Extract Review
client.extract.review.create(stringjobID, ReviewCreateParams { organization_id, project_id, confidence_threshold, 2 more } params?, RequestOptionsoptions?): ExtractReview { id, confidence_threshold, created_at, 16 more }
POST/api/v2/extract/{job_id}/review
Get Extract Review
client.extract.review.get(stringjobID, ReviewGetParams { organization_id, project_id } query?, RequestOptionsoptions?): ExtractReview { id, confidence_threshold, created_at, 16 more }
GET/api/v2/extract/{job_id}/review
Change Extract Review Fields
client.extract.review.changeFields(stringjobID, ReviewChangeFieldsParams { changes, revision, organization_id, project_id } params, RequestOptionsoptions?): ExtractReview { id, confidence_threshold, created_at, 16 more }
POST/api/v2/extract/{job_id}/review/fields
Approve Extract Review
client.extract.review.approve(stringjobID, ReviewApproveParams { revision, organization_id, project_id, sign_off } params, RequestOptionsoptions?): ExtractReview { id, confidence_threshold, created_at, 16 more }
POST/api/v2/extract/{job_id}/review/approve
Reject Extract Review
client.extract.review.reject(stringjobID, ReviewRejectParams { reason, revision, organization_id, project_id } params, RequestOptionsoptions?): ExtractReview { id, confidence_threshold, created_at, 16 more }
POST/api/v2/extract/{job_id}/review/reject
Reopen Extract Review
client.extract.review.reopen(stringjobID, ReviewReopenParams { revision, organization_id, project_id } params, RequestOptionsoptions?): ExtractReview { id, confidence_threshold, created_at, 16 more }
POST/api/v2/extract/{job_id}/review/reopen
List Extract Review Events
client.extract.review.listEvents(stringjobID, ReviewListEventsParams { organization_id, page_size, page_token, project_id } query?, RequestOptionsoptions?): PaginatedCursor<ExtractReviewEvent { id, actor_id, created_at, 5 more } >
GET/api/v2/extract/{job_id}/review/events
ModelsExpand Collapse
ExtractReview { id, confidence_threshold, created_at, 16 more }

An extract job’s review: its settings, flags, field actions and decision, with the result as read and as reviewed.

id: string

Unique identifier of the review.

confidence_threshold: number

Fields read below this confidence are flagged.

created_at: string

When review was turned on.

formatdate-time
decided_at: string | null

When it was approved or rejected.

formatdate-time
decided_by: string | null

ID of the user who approved or rejected it.

decided_reason: string | null

Why it was rejected.

field_actions: Record<string, FieldActions>

The latest action per field, keyed by JSON Pointer.

action: "clear" | "confirm" | "correct"

confirm, correct or clear.

One of the following:
"clear"
"confirm"
"correct"
actor_id: string

ID of the user who acted.

at: string

When they acted.

formatdate-time
value?: unknown

The corrected value, for correct.

fields_in_scope: Array<string>

JSON Pointers of the fields the threshold applies to; empty means all.

flags: Array<Flag>

Fields the review asks a person to check.

handled: boolean

Whether someone confirmed, corrected or cleared it.

path: string

JSON Pointer of the field.

reason: "below_threshold" | "required_empty"

below_threshold, or required_empty for a required field left empty.

One of the following:
"below_threshold"
"required_empty"
cell?: Cell | null

Where in a list the least confident value is.

row: number

Index of the row, from 0.

column?: string | null

Property of the row, when rows are objects.

confidence?: number | null

The field’s confidence; for a list, its least confident value.

job_id: string

The extract job reviewed.

open_flags: Array<string>

JSON Pointers of flagged fields nobody checked.

original_result: Record<string, unknown> | null

The result as the model read it.

required_fields: Array<string>

JSON Pointers of fields flagged when empty.

retain_until: string

When the job and its document may be deleted.

formatdate-time
reviewed_result: Record<string, unknown>

The result with the field actions.

revision: number

Bumped by every change; actions name the one they saw.

source_file_id: string | null

The file the job read, or the file behind the parse job it read; null for a URL.

status: "approved" | "pending" | "rejected"

pending until approved or rejected.

One of the following:
"approved"
"pending"
"rejected"
updated_at: string

When the review last changed.

formatdate-time
ExtractReviewEvent { id, actor_id, created_at, 5 more }

One entry in a review’s history.

id: string

Unique identifier of the entry.

actor_id: string | null

ID of the user who acted; null when a review policy turned review on.

created_at: string

When it happened.

formatdate-time
kind: "approved" | "created" | "field_cleared" | 7 more

What happened.

One of the following:
"approved"
"created"
"field_cleared"
"field_confirmed"
"field_corrected"
"field_restored"
"field_undone"
"flags_signed_off"
"rejected"
"reopened"
detail?: ExtractReviewCreatedDetail { confidence_threshold, fields_in_scope, origin, required_fields } | ExtractReviewRejectedDetail { reason } | ExtractReviewSignedOffDetail { paths } | null

The settings for created, the reason for rejected, and the fields for flags_signed_off; null for the rest.

One of the following:
ExtractReviewCreatedDetail { confidence_threshold, fields_in_scope, origin, required_fields }

What a created entry records: where review was turned on, and its settings.

confidence_threshold: number

Fields read below this confidence are flagged.

fields_in_scope: Array<string>

JSON Pointers of the fields the threshold applies to; empty means all.

origin: "api" | "edit" | "history" | 2 more

Turned on as the job ran, from History, by a first edit, by the API, or by the configuration’s review policy as the job completed.

One of the following:
"api"
"edit"
"history"
"policy"
"run"
required_fields: Array<string>

JSON Pointers of fields flagged when empty.

ExtractReviewRejectedDetail { reason }

What a rejected entry records.

reason: string

Why the result was rejected.

ExtractReviewSignedOffDetail { paths }

What a flags_signed_off entry records.

paths: Array<string>

JSON Pointers of the flagged fields confirmed as part of approving.

path?: string | null

JSON Pointer of the field it changed.

value_after?: unknown

The field’s value after the change.

value_before?: unknown

The field’s value before the change.

Note for AI agents: this documentation is built for programmatic access. - Overview of all docs: https://developers.llamaindex.ai/llms.txt - Any page is available as raw Markdown by appending index.md to its URL — e.g. https://developers.llamaindex.ai/llamaparse/parse/getting_started/index.md - Agent-friendly REST search APIs live under https://developers.llamaindex.ai/api/ — search (BM25 full-text), grep (regex), read (fetch a page), and list (browse the doc tree). See https://developers.llamaindex.ai/llms.txt for parameters. - A hosted documentation MCP server is available at https://developers.llamaindex.ai/mcp. If you support MCP, you can ask the user to install it for browsing these docs directly (an alternative to the REST API). Setup: https://developers.llamaindex.ai/for-agents/mcp/ - Other LlamaIndex tooling for agents — the LlamaParse Platform MCP server, agent skills and plugins, and the n8n node — is mapped at https://developers.llamaindex.ai/for-agents/