Skip to main content
FileRouter lets you pass native, provider-specific settings alongside the common parse options you already use. The providerOptions object is namespaced by provider ID — when you set providerOptions.llamaparse, only LlamaParse receives those values. Mistral OCR and Datalab never see them, and vice versa. This means you can safely configure multiple providers in a single compare call without any risk of options from one provider interfering with another.

How namespacing works

Each key in providerOptions must match a provider ID (llamaparse, mistral-ocr, or datalab). FileRouter extracts the matching namespace before forwarding the request to each provider. Providers that don’t have a matching key in providerOptions receive no extra options at all. FileRouter also applies the input source and all authentication-owned fields after any native options you supply. This means provider options cannot redirect a job to a different endpoint or override credentials — the routing is always under FileRouter’s control.
If you request a normalized output that a provider doesn’t support (for example, asking for tables from a provider that has no table capability), FileRouter fails the request before sending anything to the provider. You get an immediate error rather than a silent empty result.

Passing options to a single provider

Use providerOptions in a parse call to send typed native settings to one provider:
Parse with LlamaParse agentic options
The tier and agentic_options fields map directly to LlamaParse’s official SDK request type. Page numbers are always one-based in FileRouter and are translated into each provider’s native representation automatically.

Passing different options per provider in a compare call

Because providerOptions is namespaced, you can include options for multiple providers in a single compare call. Each provider only receives its own block:
Compare with per-provider options
LlamaParse receives the tier field. Mistral OCR receives model and includeImageBase64. Neither provider sees the other’s options.
LlamaParse options follow ParsingCreateParams from @llamaindex/llama-cloud. Protected fields (file_id, source_url, organization_id, project_id) are stripped automatically — you cannot override them through providerOptions.
LlamaParse native options reference

The raw escape hatch

Each configured provider exposes its underlying SDK client through provider.raw. You can use this to call provider APIs that FileRouter doesn’t currently expose as part of its normalized contract:
Access the underlying LlamaParse SDK client
Operations performed through provider.raw bypass FileRouter’s normalization, input validation, and output selection. Use the escape hatch only for features that the FileRouter SDK doesn’t yet support natively.

Provider output capabilities

Requesting an output that a provider doesn’t support fails immediately, before any provider I/O occurs.