LlamaParse Batch Processing API
The Batch Processing API from LlamaParse — 5 operation(s) for batch processing.
The Batch Processing API from LlamaParse — 5 operation(s) for batch processing.
openapi: 3.0.3
info:
title: Llama Platform Agent Data Batch Processing API
version: 0.1.0
tags:
- name: Batch Processing
paths:
/api/v1/beta/batch-processing:
post:
tags:
- Batch Processing
summary: Create Batch Job
description: 'Create a batch processing job.
Processes files from a directory or a specific list of item IDs.
Supports batch parsing and classification operations.
Provide either `directory_id` to process all files in a directory,
or `item_ids` for specific items. The job runs asynchronously —
poll `GET /batch/{job_id}` for progress.'
operationId: create_batch_job_api_v1_beta_batch_processing_post
security:
- HTTPBearer: []
parameters:
- name: project_id
in: query
required: false
schema:
anyOf:
- type: string
format: uuid
- type: 'null'
title: Project Id
- name: organization_id
in: query
required: false
schema:
anyOf:
- type: string
format: uuid
- type: 'null'
title: Organization Id
- name: temporal-namespace
in: header
required: false
schema:
anyOf:
- type: string
- type: 'null'
title: Temporal-Namespace
- name: session
in: cookie
required: false
schema:
anyOf:
- type: string
- type: 'null'
title: Session
requestBody:
required: true
content:
application/json:
schema:
$ref: '#/components/schemas/BatchJobCreateRequest'
responses:
'201':
description: Successful Response
content:
application/json:
schema:
$ref: '#/components/schemas/BatchJobResponse'
'422':
description: Validation Error
content:
application/json:
schema:
$ref: '#/components/schemas/HTTPValidationError'
get:
tags:
- Batch Processing
summary: List Batch Jobs
description: 'List batch processing jobs with optional filtering.
Filter by `directory_id`, `job_type`, or `status`. Results
are paginated with configurable `limit` and `offset`.'
operationId: list_batch_jobs_api_v1_beta_batch_processing_get
security:
- HTTPBearer: []
parameters:
- name: directory_id
in: query
required: false
schema:
anyOf:
- type: string
- type: 'null'
description: Filter by directory ID
title: Directory Id
description: Filter by directory ID
- name: job_type
in: query
required: false
schema:
anyOf:
- $ref: '#/components/schemas/BatchJobType'
- type: 'null'
description: Filter by job type (PARSE, EXTRACT, CLASSIFY)
title: Job Type
description: Filter by job type (PARSE, EXTRACT, CLASSIFY)
- name: status
in: query
required: false
schema:
anyOf:
- $ref: '#/components/schemas/BatchJobStatus'
- type: 'null'
description: Filter by job status (PENDING, RUNNING, COMPLETED, FAILED, CANCELLED)
title: Status
description: Filter by job status (PENDING, RUNNING, COMPLETED, FAILED, CANCELLED)
- name: limit
in: query
required: false
schema:
type: integer
maximum: 1000
minimum: 1
description: Maximum number of jobs to return
default: 50
title: Limit
description: Maximum number of jobs to return
- name: offset
in: query
required: false
schema:
type: integer
minimum: 0
description: Number of jobs to skip for pagination
default: 0
title: Offset
description: Number of jobs to skip for pagination
- name: project_id
in: query
required: false
schema:
anyOf:
- type: string
format: uuid
- type: 'null'
title: Project Id
- name: organization_id
in: query
required: false
schema:
anyOf:
- type: string
format: uuid
- type: 'null'
title: Organization Id
- name: session
in: cookie
required: false
schema:
anyOf:
- type: string
- type: 'null'
title: Session
responses:
'200':
description: Successful Response
content:
application/json:
schema:
$ref: '#/components/schemas/BatchJobQueryResponse'
'422':
description: Validation Error
content:
application/json:
schema:
$ref: '#/components/schemas/HTTPValidationError'
/api/v1/beta/batch-processing/{job_id}:
get:
tags:
- Batch Processing
summary: Get Batch Job Status
description: 'Get detailed status of a batch processing job.
Returns current progress percentage, file counts (total,
processed, failed, skipped), and timestamps.'
operationId: get_batch_job_status_api_v1_beta_batch_processing__job_id__get
security:
- HTTPBearer: []
parameters:
- name: job_id
in: path
required: true
schema:
type: string
title: Job Id
- name: project_id
in: query
required: false
schema:
anyOf:
- type: string
format: uuid
- type: 'null'
title: Project Id
- name: organization_id
in: query
required: false
schema:
anyOf:
- type: string
format: uuid
- type: 'null'
title: Organization Id
- name: session
in: cookie
required: false
schema:
anyOf:
- type: string
- type: 'null'
title: Session
responses:
'200':
description: Successful Response
content:
application/json:
schema:
$ref: '#/components/schemas/BatchJobStatusResponse'
'422':
description: Validation Error
content:
application/json:
schema:
$ref: '#/components/schemas/HTTPValidationError'
/api/v1/beta/batch-processing/{job_id}/items:
get:
tags:
- Batch Processing
summary: List Batch Job Items
description: 'List items in a batch job with optional status filtering.
Useful for finding failed items, viewing completed items,
or debugging processing issues.'
operationId: list_batch_job_items_api_v1_beta_batch_processing__job_id__items_get
security:
- HTTPBearer: []
parameters:
- name: job_id
in: path
required: true
schema:
type: string
title: Job Id
- name: status
in: query
required: false
schema:
anyOf:
- $ref: '#/components/schemas/BatchFileStatus'
- type: 'null'
description: Filter items by status
title: Status
description: Filter items by status
- name: limit
in: query
required: false
schema:
type: integer
maximum: 1000
minimum: 1
description: Maximum number of items to return
default: 100
title: Limit
description: Maximum number of items to return
- name: offset
in: query
required: false
schema:
type: integer
minimum: 0
description: Number of items to skip
default: 0
title: Offset
description: Number of items to skip
- name: project_id
in: query
required: false
schema:
anyOf:
- type: string
format: uuid
- type: 'null'
title: Project Id
- name: organization_id
in: query
required: false
schema:
anyOf:
- type: string
format: uuid
- type: 'null'
title: Organization Id
- name: session
in: cookie
required: false
schema:
anyOf:
- type: string
- type: 'null'
title: Session
responses:
'200':
description: Successful Response
content:
application/json:
schema:
$ref: '#/components/schemas/BatchItemListResponse'
'422':
description: Validation Error
content:
application/json:
schema:
$ref: '#/components/schemas/HTTPValidationError'
/api/v1/beta/batch-processing/{job_id}/cancel:
post:
tags:
- Batch Processing
summary: Cancel Batch Job
description: 'Cancel a running batch processing job.
Stops processing and marks pending items as cancelled.
Items currently being processed may still complete.'
operationId: cancel_batch_job_api_v1_beta_batch_processing__job_id__cancel_post
security:
- HTTPBearer: []
parameters:
- name: job_id
in: path
required: true
schema:
type: string
title: Job Id
- name: project_id
in: query
required: false
schema:
anyOf:
- type: string
format: uuid
- type: 'null'
title: Project Id
- name: organization_id
in: query
required: false
schema:
anyOf:
- type: string
format: uuid
- type: 'null'
title: Organization Id
- name: temporal-namespace
in: header
required: false
schema:
anyOf:
- type: string
- type: 'null'
title: Temporal-Namespace
- name: session
in: cookie
required: false
schema:
anyOf:
- type: string
- type: 'null'
title: Session
requestBody:
required: true
content:
application/json:
schema:
$ref: '#/components/schemas/BatchJobCancelRequest'
responses:
'200':
description: Successful Response
content:
application/json:
schema:
$ref: '#/components/schemas/BatchJobCancelResponse'
'422':
description: Validation Error
content:
application/json:
schema:
$ref: '#/components/schemas/HTTPValidationError'
/api/v1/beta/batch-processing/items/{item_id}/processing-results:
get:
tags:
- Batch Processing
summary: Get Item Processing Results
description: 'Get all processing results for a specific item.
Returns the complete processing history for an item including
what operations were performed, parameters used, and where
outputs are stored. Optionally filter by `job_type`.'
operationId: get_item_processing_results_api_v1_beta_batch_processing_items__item_id__processing_results_get
security:
- HTTPBearer: []
parameters:
- name: item_id
in: path
required: true
schema:
type: string
title: Item Id
- name: job_type
in: query
required: false
schema:
anyOf:
- $ref: '#/components/schemas/BatchJobType'
- type: 'null'
description: Filter results by job type
title: Job Type
description: Filter results by job type
- name: project_id
in: query
required: false
schema:
anyOf:
- type: string
format: uuid
- type: 'null'
title: Project Id
- name: organization_id
in: query
required: false
schema:
anyOf:
- type: string
format: uuid
- type: 'null'
title: Organization Id
- name: session
in: cookie
required: false
schema:
anyOf:
- type: string
- type: 'null'
title: Session
responses:
'200':
description: Successful Response
content:
application/json:
schema:
$ref: '#/components/schemas/ItemProcessingResultsResponse'
'422':
description: Validation Error
content:
application/json:
schema:
$ref: '#/components/schemas/HTTPValidationError'
components:
schemas:
StatusEnum:
type: string
enum:
- PENDING
- SUCCESS
- ERROR
- PARTIAL_SUCCESS
- CANCELLED
title: StatusEnum
description: Enum for representing the status of a job
BatchParseJobRecordCreate:
properties:
job_name:
type: string
const: parse_raw_file_job
title: Job Name
default: parse_raw_file_job
partitions:
additionalProperties:
anyOf:
- type: string
format: uuid
- type: string
propertyNames:
$ref: '#/components/schemas/PartitionNames'
type: object
title: Partitions
description: The partitions for this execution. Used for determining where to save job output.
parameters:
anyOf:
- $ref: '#/components/schemas/BatchParseJobConfig'
- type: 'null'
description: The generic parse configuration for all files in the batch.
session_id:
anyOf:
- type: string
format: uuid
- type: 'null'
title: Session Id
description: The upstream request ID that created this job. Used for tracking the job across services.
correlation_id:
anyOf:
- type: string
format: uuid
- type: 'null'
title: Correlation Id
description: The correlation ID for this job. Used for tracking the job across services.
parent_job_execution_id:
anyOf:
- type: string
format: uuid
- type: 'null'
title: Parent Job Execution Id
description: The ID of the parent job execution.
user_id:
anyOf:
- type: string
- type: 'null'
title: User Id
description: The ID of the user that created this job
project_id:
anyOf:
- type: string
format: uuid
- type: 'null'
title: Project Id
description: The ID of the project this job belongs to.
webhook_url:
anyOf:
- type: string
- type: 'null'
title: Webhook Url
description: The URL that needs to be called at the end of the parsing job.
type: object
title: BatchParseJobRecordCreate
description: "Batch-specific parse job record for batch processing.\n\nThis model contains the metadata and configuration for a batch parse job,\nbut excludes file-specific information. It's used as input to the batch\nparent workflow and combined with DirectoryFile data to create full\nParseJobRecordCreate instances for each file.\n\nAttributes:\n job_name: Must be PARSE_RAW_FILE\n partitions: Partitions for job output location\n parameters: Generic parse configuration (BatchParseJobConfig)\n session_id: Upstream request ID for tracking\n correlation_id: Correlation ID for cross-service tracking\n parent_job_execution_id: Parent job execution ID if nested\n user_id: User who created the job\n project_id: Project this job belongs to\n webhook_url: Optional webhook URL for job completion notifications"
ItemProcessingResultsResponse:
properties:
item_id:
type: string
title: Item Id
description: ID of the source item
item_name:
type: string
title: Item Name
description: Name of the source item
processing_results:
items:
$ref: '#/components/schemas/ProcessingResult'
type: array
title: Processing Results
description: List of all processing operations performed on this item
type: object
required:
- item_id
- item_name
title: ItemProcessingResultsResponse
description: Response containing all processing results for an item.
BatchFileStatus:
type: string
enum:
- pending
- processing
- completed
- failed
- skipped
- cancelled
title: BatchFileStatus
description: Status of an individual file in a batch job.
BatchParseJobConfig:
properties:
webhook_configurations:
anyOf:
- items:
$ref: '#/components/schemas/WebhookConfiguration'
type: array
- type: 'null'
title: Webhook Configurations
description: Outbound webhook endpoints to notify on job status changes
priority:
anyOf:
- type: string
enum:
- low
- medium
- high
- critical
- type: 'null'
title: Priority
description: The priority for the request. This field may be ignored or overwritten depending on the organization tier.
custom_metadata:
anyOf:
- additionalProperties: true
type: object
- type: 'null'
title: Custom Metadata
description: The custom metadata to attach to the documents.
resource_info:
anyOf:
- additionalProperties: true
type: object
- type: 'null'
title: Resource Info
description: The resource info about the file
languages:
items:
$ref: '#/components/schemas/ParserLanguages'
type: array
minItems: 1
title: Languages
parsing_instruction:
anyOf:
- type: string
- type: 'null'
title: Parsing Instruction
default: ''
disable_ocr:
anyOf:
- type: boolean
- type: 'null'
title: Disable Ocr
default: false
annotate_links:
anyOf:
- type: boolean
- type: 'null'
title: Annotate Links
default: false
adaptive_long_table:
anyOf:
- type: boolean
- type: 'null'
title: Adaptive Long Table
default: false
compact_markdown_table:
anyOf:
- type: boolean
- type: 'null'
title: Compact Markdown Table
default: false
disable_reconstruction:
anyOf:
- type: boolean
- type: 'null'
title: Disable Reconstruction
default: false
disable_image_extraction:
anyOf:
- type: boolean
- type: 'null'
title: Disable Image Extraction
default: false
invalidate_cache:
anyOf:
- type: boolean
- type: 'null'
title: Invalidate Cache
default: false
outlined_table_extraction:
anyOf:
- type: boolean
- type: 'null'
title: Outlined Table Extraction
default: false
aggressive_table_extraction:
anyOf:
- type: boolean
- type: 'null'
title: Aggressive Table Extraction
default: false
merge_tables_across_pages_in_markdown:
anyOf:
- type: boolean
- type: 'null'
title: Merge Tables Across Pages In Markdown
default: false
output_pdf_of_document:
anyOf:
- type: boolean
- type: 'null'
title: Output Pdf Of Document
default: false
do_not_cache:
anyOf:
- type: boolean
- type: 'null'
title: Do Not Cache
default: false
fast_mode:
anyOf:
- type: boolean
- type: 'null'
title: Fast Mode
default: false
skip_diagonal_text:
anyOf:
- type: boolean
- type: 'null'
title: Skip Diagonal Text
default: false
preserve_layout_alignment_across_pages:
anyOf:
- type: boolean
- type: 'null'
title: Preserve Layout Alignment Across Pages
default: false
preserve_very_small_text:
anyOf:
- type: boolean
- type: 'null'
title: Preserve Very Small Text
default: false
gpt4o_mode:
anyOf:
- type: boolean
- type: 'null'
title: Gpt4O Mode
default: false
gpt4o_api_key:
anyOf:
- type: string
- type: 'null'
title: Gpt4O Api Key
do_not_unroll_columns:
anyOf:
- type: boolean
- type: 'null'
title: Do Not Unroll Columns
default: false
extract_layout:
anyOf:
- type: boolean
- type: 'null'
title: Extract Layout
default: false
high_res_ocr:
anyOf:
- type: boolean
- type: 'null'
title: High Res Ocr
default: false
html_make_all_elements_visible:
anyOf:
- type: boolean
- type: 'null'
title: Html Make All Elements Visible
default: false
layout_aware:
anyOf:
- type: boolean
- type: 'null'
title: Layout Aware
default: false
specialized_chart_parsing_agentic:
anyOf:
- type: boolean
- type: 'null'
title: Specialized Chart Parsing Agentic
default: false
specialized_chart_parsing_plus:
anyOf:
- type: boolean
- type: 'null'
title: Specialized Chart Parsing Plus
default: false
specialized_chart_parsing_efficient:
anyOf:
- type: boolean
- type: 'null'
title: Specialized Chart Parsing Efficient
default: false
specialized_image_parsing:
anyOf:
- type: boolean
- type: 'null'
title: Specialized Image Parsing
default: false
precise_bounding_box:
anyOf:
- type: boolean
- type: 'null'
title: Precise Bounding Box
default: false
line_level_bounding_box:
anyOf:
- type: boolean
- type: 'null'
title: Line Level Bounding Box
default: false
html_remove_navigation_elements:
anyOf:
- type: boolean
- type: 'null'
title: Html Remove Navigation Elements
default: false
html_remove_fixed_elements:
anyOf:
- type: boolean
- type: 'null'
title: Html Remove Fixed Elements
default: false
guess_xlsx_sheet_name:
anyOf:
- type: boolean
- type: 'null'
title: Guess Xlsx Sheet Name
default: false
page_separator:
anyOf:
- type: string
- type: 'null'
title: Page Separator
bounding_box:
anyOf:
- type: string
- type: 'null'
title: Bounding Box
bbox_top:
anyOf:
- type: number
- type: 'null'
title: Bbox Top
bbox_right:
anyOf:
- type: number
- type: 'null'
title: Bbox Right
bbox_bottom:
anyOf:
- type: number
- type: 'null'
title: Bbox Bottom
bbox_left:
anyOf:
- type: number
- type: 'null'
title: Bbox Left
target_pages:
anyOf:
- type: string
- type: 'null'
title: Target Pages
use_vendor_multimodal_model:
anyOf:
- type: boolean
- type: 'null'
title: Use Vendor Multimodal Model
default: false
vendor_multimodal_model_name:
anyOf:
- type: string
- type: 'null'
title: Vendor Multimodal Model Name
model:
anyOf:
- type: string
- type: 'null'
title: Model
vendor_multimodal_api_key:
anyOf:
- type: string
- type: 'null'
title: Vendor Multimodal Api Key
page_prefix:
anyOf:
- type: string
- type: 'null'
title: Page Prefix
page_suffix:
anyOf:
- type: string
- type: 'null'
title: Page Suffix
webhook_url:
anyOf:
- type: string
- type: 'null'
title: Webhook Url
preset:
anyOf:
- type: string
- type: 'null'
title: Preset
take_screenshot:
anyOf:
- type: boolean
- type: 'null'
title: Take Screenshot
default: false
is_formatting_instruction:
anyOf:
- type: boolean
- type: 'null'
title: Is Formatting Instruction
default: true
premium_mode:
anyOf:
- type: boolean
- type: 'null'
title: Premium Mode
default: false
continuous_mode:
anyOf:
- type: boolean
- type: 'null'
title: Continuous Mode
default: false
input_s3_path:
anyOf:
- type: string
- type: 'null'
title: Input S3 Path
input_s3_region:
anyOf:
- type: string
- type: 'null'
title: Input S3 Region
description: The region for the input S3 bucket.
output_s3_path_prefix:
anyOf:
- type: string
- type: 'null'
title: Output S3 Path Prefix
description: If specified, llamaParse will save the output to the specified path. All output file will use this 'prefix' should be a valid s3:// url
output_s3_region:
anyOf:
- type: string
- type: 'null'
title: Output S3 Region
description: The region for the output S3 bucket.
project_id:
anyOf:
- type: string
- type: 'null'
title: Project Id
azure_openai_deployment_name:
anyOf:
- type: string
- type: 'null'
title: Azure Openai Deployment Name
azure_openai_endpoint:
anyOf:
- type: string
- type: 'null'
title: Azure Openai Endpoint
azure_openai_api_version:
anyOf:
- type: string
- type: 'null'
title: Azure Openai Api Version
azure_openai_key:
anyOf:
- type: string
- type: 'null'
title: Azure Openai Key
input_url:
anyOf:
- type: string
- type: 'null'
title: Input Url
http_proxy:
anyOf:
- type: string
- type: 'null'
title: Http Proxy
auto_mode:
anyOf:
- type: boolean
- type: 'null'
title: Auto Mode
default: false
auto_mode_trigger_on_regexp_in_page:
anyOf:
- type: string
- type: 'null'
title: Auto Mode Trigger On Regexp In Page
auto_mode_trigger_on_text_in_page:
anyOf:
- type: string
- type: 'null'
title: Auto Mode Trigger On Text In Page
auto_mode_trigger_on_table_in_page:
anyOf:
- type: boolean
- type: 'null'
title: Auto Mode Trigger On Table In Page
default: false
auto_mode_trigger_on_image_in_page:
anyOf:
- type: boolean
- type: 'null'
title: Auto Mode Trigger On Image In Page
default: false
auto_mode_configuration_json:
anyOf:
- type: string
- type: 'null'
title: Auto Mode Configuration Json
structured_output:
anyOf:
- type: boolean
- type: 'null'
title: Structured Output
default: false
structured_output_json_schema:
anyOf:
- type: string
- type: 'null'
title: Structured Output Json Schema
structured_output_json_schema_name:
anyOf:
- type: string
- type: 'null'
title: Structured Output Json Schema Name
max_pages:
anyOf:
- type: integer
- type: 'null'
title: Max Pages
max_pages_enforced:
anyOf:
- type: integer
- type: 'null'
title: Max Pages Enforced
extract_charts:
anyOf:
- type: boolean
- type: 'null'
title: Extract Charts
default: false
formatting_instruction:
anyOf:
- type: string
- type: 'null'
title: Formatting Instruction
complemental_formatting_instruction:
anyOf:
- type: string
- type: 'null'
title: Complemental Formatting Instruction
content_guideline_instruction:
anyOf:
- type: string
- type: 'null'
title: Content Guideline Instruction
spreadsheet_extract_sub_tables:
anyOf:
- type: boolean
- type: 'null'
title: Spreadsheet Extract Sub Tables
default: false
spreadsheet_force_formula_computation:
anyOf:
- type: boolean
- type: 'null'
title: Spreadsheet Force Formula Computation
default: false
spreadsheet_include_hidden_sheets:
anyOf:
- type: boolean
- type: 'null'
title: Spreadsheet Include Hidden Sheets
default: false
inline_images_in_markdown:
anyOf:
- type: boolean
- type: 'null'
title: Inline Images In Markdown
default: false
job_timeout_in_seconds:
anyOf:
- type: number
- type: 'null'
title: Job Timeout In Seconds
job_timeout_extra_time_per_page_in_seconds:
anyOf:
- type: number
- type: 'null'
title: Job Timeout Extra Time Per Page In Seconds
strict_mode_image_extraction:
anyOf:
- type: boolean
- type: 'null'
title: Strict Mode Image Extraction
default: false
strict_mode_image_ocr:
anyOf:
- type: boolean
- type: 'null'
title: Strict Mode Image Ocr
default: false
strict_mode_reconstruction:
anyOf:
- type: boolean
- type: 'null'
title: Strict Mode Reconstruction
default: false
strict_mode_buggy_font:
anyOf:
- type: boolean
- type: 'null'
title: Strict Mode Buggy Font
default: false
save_images:
anyOf:
- type: boolean
- type: 'null'
title: Save Images
default: true
images_to_save:
anyOf:
- items:
type: string
enum:
- screenshot
- embedded
- layout
type: array
- type: 'null'
title: Images To Save
hide_headers:
anyOf:
- type: boolean
- type: 'null'
title: Hide Headers
default: false
hide_footers:
anyOf:
# --- truncated at 32 KB (58 KB total) ---
# Full source: https://raw.githubusercontent.com/api-evangelist/llamaparse/refs/heads/main/openapi/llamaparse-batch-processing-api-openapi.yml