Create Batch Job
BatchCreateResponse Beta.Batch.Create(BatchCreateParamsparameters, CancellationTokencancellationToken = default)
POST/api/v1/beta/batch-processing
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.
Create Batch Job
BatchCreateParams parameters = new()
{
JobConfig = new BatchParseJobRecordCreate()
{
CorrelationID = "182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e",
JobName = JobName.ParseRawFileJob,
Parameters = new()
{
AdaptiveLongTable = true,
AggressiveTableExtraction = true,
AnnotateLinks = true,
AutoMode = true,
AutoModeConfigurationJson = "auto_mode_configuration_json",
AutoModeTriggerOnImageInPage = true,
AutoModeTriggerOnRegexpInPage = "auto_mode_trigger_on_regexp_in_page",
AutoModeTriggerOnTableInPage = true,
AutoModeTriggerOnTextInPage = "auto_mode_trigger_on_text_in_page",
AzureOpenAIApiVersion = "azure_openai_api_version",
AzureOpenAIDeploymentName = "azure_openai_deployment_name",
AzureOpenAIEndpoint = "azure_openai_endpoint",
AzureOpenAIKey = "azure_openai_key",
BboxBottom = 0,
BboxLeft = 0,
BboxRight = 0,
BboxTop = 0,
BoundingBox = "bounding_box",
CompactMarkdownTable = true,
ComplementalFormattingInstruction = "complemental_formatting_instruction",
ConfidenceScoreEffort = "confidence_score_effort",
ContentGuidelineInstruction = "content_guideline_instruction",
ContinuousMode = true,
CustomMetadata = new Dictionary<string, JsonElement>()
{
{ "foo", JsonSerializer.SerializeToElement("bar") }
},
DisableImageExtraction = true,
DisableOcr = true,
DisableReconstruction = true,
DoNotCache = true,
DoNotUnrollColumns = true,
EnableCostOptimizer = true,
ExtractCharts = true,
ExtractLayout = true,
ExtractPrintedPageNumber = true,
FastMode = true,
FormattingInstruction = "formatting_instruction",
Gpt4oApiKey = "gpt4o_api_key",
Gpt4oMode = true,
GuessXlsxSheetName = true,
HideFooters = true,
HideHeaders = true,
HighResOcr = true,
HtmlMakeAllElementsVisible = true,
HtmlRemoveFixedElements = true,
HtmlRemoveNavigationElements = true,
HttpProxy = "http_proxy",
IgnoreDocumentElementsForLayoutDetection = true,
ImagesToSave =
[
ImagesToSave.Embedded
],
InlineImagesInMarkdown = true,
InputS3Path = "input_s3_path",
InputS3Region = "input_s3_region",
InputUrl = "input_url",
InternalIsScreenshotJob = true,
InvalidateCache = true,
IsFormattingInstruction = true,
JobTimeoutExtraTimePerPageInSeconds = 0,
JobTimeoutInSeconds = 0,
KeepPageSeparatorWhenMergingTables = true,
Lang = "lang",
Languages =
[
ParsingLanguages.Abq
],
LayoutAware = true,
LineLevelBoundingBox = true,
MarkdownTableMultilineHeaderSeparator = "markdown_table_multiline_header_separator",
MaxPages = 0,
MaxPagesEnforced = 0,
MergeTablesAcrossPagesInMarkdown = true,
Model = "model",
OutlinedTableExtraction = true,
OutputPdfOfDocument = true,
OutputS3PathPrefix = "output_s3_path_prefix",
OutputS3Region = "output_s3_region",
OutputTablesAsHtml = true,
OutputBucket = "outputBucket",
PageErrorTolerance = 0,
PageFooterPrefix = "page_footer_prefix",
PageFooterSuffix = "page_footer_suffix",
PageHeaderPrefix = "page_header_prefix",
PageHeaderSuffix = "page_header_suffix",
PagePrefix = "page_prefix",
PageSeparator = "page_separator",
PageSuffix = "page_suffix",
ParseMode = ParsingMode.ParseDocumentWithAgent,
ParsingInstruction = "parsing_instruction",
PipelineID = "pipeline_id",
PreciseBoundingBox = true,
PremiumMode = true,
PresentationOutOfBoundsContent = true,
PresentationSkipEmbeddedData = true,
PreserveLayoutAlignmentAcrossPages = true,
PreserveVerySmallText = true,
Preset = "preset",
Priority = Priority.Critical,
ProjectID = "project_id",
RemoveHiddenText = true,
ReplaceFailedPageMode = FailPageMode.BlankPage,
ReplaceFailedPageWithErrorMessagePrefix = "replace_failed_page_with_error_message_prefix",
ReplaceFailedPageWithErrorMessageSuffix = "replace_failed_page_with_error_message_suffix",
ResourceInfo = new Dictionary<string, JsonElement>()
{
{ "foo", JsonSerializer.SerializeToElement("bar") }
},
SaveImages = true,
SkipDiagonalText = true,
SpecializedChartParsingAgentic = true,
SpecializedChartParsingEfficient = true,
SpecializedChartParsingPlus = true,
SpecializedImageParsing = true,
SpreadsheetExtractSubTables = true,
SpreadsheetForceFormulaComputation = true,
SpreadsheetIncludeHiddenSheets = true,
StrictModeBuggyFont = true,
StrictModeImageExtraction = true,
StrictModeImageOcr = true,
StrictModeReconstruction = true,
StructuredOutput = true,
StructuredOutputJsonSchema = "structured_output_json_schema",
StructuredOutputJsonSchemaName = "structured_output_json_schema_name",
SystemPrompt = "system_prompt",
SystemPromptAppend = "system_prompt_append",
TakeScreenshot = true,
TargetPages = "target_pages",
Tier = "tier",
Type = Type.Parse,
UseVendorMultimodalModel = true,
UserPrompt = "user_prompt",
VendorMultimodalApiKey = "vendor_multimodal_api_key",
VendorMultimodalModelName = "vendor_multimodal_model_name",
Version = "version",
WebhookConfigurations =
[
new()
{
WebhookEvents =
[
WebhookEvent.ParseSuccess, WebhookEvent.ParseError
],
WebhookHeaders = new Dictionary<string, string>()
{
{ "Authorization", "Bearer sk-..." }
},
WebhookOutputFormat = "json",
WebhookSigningSecret = "whsec_...",
WebhookUrl = "https://example.com/webhooks/llamacloud",
},
],
WebhookUrl = "webhook_url",
},
ParentJobExecutionID = "182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e",
Partitions = new Dictionary<string, string>()
{
{ "foo", "182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e" }
},
ProjectID = "182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e",
SessionID = "182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e",
UserID = "user_id",
WebhookUrl = "webhook_url",
},
};
var batch = await client.Beta.Batch.Create(parameters);
Console.WriteLine(batch);{
"id": "bjb-aaaaaaaa-bbbb-cccc-dddd-eeeeeeeeeeee",
"job_type": "classify",
"project_id": "proj-aaaaaaaa-bbbb-cccc-dddd-eeeeeeeeeeee",
"status": "cancelled",
"total_items": 0,
"completed_at": "2019-12-27T18:11:19.117Z",
"created_at": "2019-12-27T18:11:19.117Z",
"directory_id": "dir-aaaaaaaa-bbbb-cccc-dddd-eeeeeeeeeeee",
"effective_at": "2019-12-27T18:11:19.117Z",
"error_message": "error_message",
"failed_items": 0,
"job_record_id": "job_record_id",
"processed_items": 0,
"skipped_items": 0,
"started_at": "2019-12-27T18:11:19.117Z",
"updated_at": "2019-12-27T18:11:19.117Z",
"workflow_id": "workflow_id"
}Returns Examples
{
"id": "bjb-aaaaaaaa-bbbb-cccc-dddd-eeeeeeeeeeee",
"job_type": "classify",
"project_id": "proj-aaaaaaaa-bbbb-cccc-dddd-eeeeeeeeeeee",
"status": "cancelled",
"total_items": 0,
"completed_at": "2019-12-27T18:11:19.117Z",
"created_at": "2019-12-27T18:11:19.117Z",
"directory_id": "dir-aaaaaaaa-bbbb-cccc-dddd-eeeeeeeeeeee",
"effective_at": "2019-12-27T18:11:19.117Z",
"error_message": "error_message",
"failed_items": 0,
"job_record_id": "job_record_id",
"processed_items": 0,
"skipped_items": 0,
"started_at": "2019-12-27T18:11:19.117Z",
"updated_at": "2019-12-27T18:11:19.117Z",
"workflow_id": "workflow_id"
}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/