Skip to main content

Overview

Bifrost supports the Anthropic Files API and Batch API (via the beta namespace) with cross-provider routing. This means you can use the Anthropic SDK to manage files and batch jobs across multiple providers including Anthropic, OpenAI, and Gemini. The provider is specified using the x-model-provider header in default_headers.
Bedrock Limitation: Bedrock batch operations require file-based input with S3 storage, which is not supported via the Anthropic SDK’s inline batch API. For Bedrock batch operations, use the Bedrock SDK directly.

Client Setup

In API Key section, you can either send virtual key or a dummy key to escape client side validation.

Anthropic Provider (Default)

Cross-Provider Client

To route requests to a different provider, set the x-model-provider header:

Files API

The Files API is accessed through the beta.files namespace. Note that file support varies by provider.

Upload a File

Upload a text file for use with Anthropic:

List Files

Delete a File

Download File Content

Note: Anthropic only allows downloading files created by certain tools (like code execution). OpenAI allows downloading batch output files.

Batch API

The Anthropic Batch API is accessed through beta.messages.batches. Anthropic’s batch API uses inline requests rather than file uploads.

Create a Batch with Inline Requests

Bedrock Note: Bedrock requires file-based batch creation with S3 storage. When routing to Bedrock from the Anthropic SDK, you’ll need to use the Bedrock SDK directly for batch operations. See the Bedrock SDK documentation for details.

List Batches

Retrieve Batch Status

Cancel a Batch

Get Batch Results


End-to-End Workflows

Anthropic Batch Workflow

Cross-Provider Batch Workflow (OpenAI via Anthropic SDK)


Provider-Specific Notes


Next Steps