Skip to main content
The Claude Desktop App brings Claude to your desktop with a chat interface and a built-in Code tab powered by Claude Code. By routing the Code tab through Bifrost, you get multi-provider routing, virtual keys, budget controls, and full observability.
If your Allowed Headers are already set to *, you can skip this note. If not and you face issues integrating Bifrost with Claude Desktop, try switching to * or adding the specific headers required by your client. By default, Bifrost whitelists: Content-Type, Authorization, X-Requested-With, X-Stainless-Timeout, and X-Api-Key.

How It Works

The Claude Desktop App has two tabs with different routing behavior:
TabTrafficBifrost Integration
Code tabUses the Anthropic Messages API (Claude Code under the hood)Route inference through Bifrost’s /anthropic endpoint
Chat tabConnects directly to claude.aiConnect to Bifrost’s /mcp endpoint for MCP tools
This guide covers configuring the Code tab for inference routing and the Chat tab for MCP tool access.

Setup

1. Configure settings.json

Open ~/.claude/settings.json and add the Bifrost endpoint and API key under the env key:
{
  "env": {
    "ANTHROPIC_API_KEY": "your-bifrost-virtual-key",
    "ANTHROPIC_BASE_URL": "http://localhost:8080/anthropic"
  }
}
For production deployments:
{
  "env": {
    "ANTHROPIC_API_KEY": "your-bifrost-virtual-key",
    "ANTHROPIC_BASE_URL": "https://bifrost.example.com/anthropic"
  }
}
You can open this file by running /config inside Claude Code, or by editing ~/.claude/settings.json directly. These settings are shared between the Desktop app and the CLI.

2. Start a New Session

Close any active session in the Code tab and start a new one for the settings to take effect.

Amazon Bedrock via Bifrost

Setup

Add the Bifrost endpoint and pin model versions in ~/.claude/settings.json:
{
  "env": {
    "ANTHROPIC_API_KEY": "bifrost-virtual-key",
    "ANTHROPIC_BASE_URL": "http://localhost:8080/anthropic",
    "ANTHROPIC_DEFAULT_SONNET_MODEL": "bedrock/global.anthropic.claude-sonnet-4-6",
    "ANTHROPIC_DEFAULT_HAIKU_MODEL": "bedrock/global.anthropic.claude-haiku-4-5-20251001-v1:0"
  }
}
If you don’t pin using settings.json - you can pin these in UI. Go to Dashboard > Models > Model Providers > AWS Bedrock > Key. And add deployments.
Claude bedrock pinning
Always pin model versions when using Bedrock. Without pinning, Claude Code aliases resolve to the latest version, which may not be enabled in your Bedrock account.

Google Vertex AI via Bifrost

Setup

{
  "env": {
    "ANTHROPIC_API_KEY": "bifrost-virtual-key",
    "ANTHROPIC_BASE_URL": "http://localhost:8080/anthropic",
    "ANTHROPIC_DEFAULT_SONNET_MODEL": "vertex/claude-sonnet-4-6",
    "ANTHROPIC_DEFAULT_HAIKU_MODEL": "vertex/claude-haiku-4-5"
  }
}

Azure via Bifrost

Setup

{
  "env": {
    "ANTHROPIC_API_KEY": "bifrost-virtual-key",
    "ANTHROPIC_BASE_URL": "http://localhost:8080/anthropic",
    "ANTHROPIC_DEFAULT_SONNET_MODEL": "azure/claude-sonnet-4-6",
    "ANTHROPIC_DEFAULT_HAIKU_MODEL": "azure/claude-haiku-4-5"
  }
}
You will also have to map these model names to actual deployment names on Bifrost dashboard.
Claude Azure pinning
Azure-hosted models must support tool use capabilities for Claude Code to function properly. Verify tool calling support before configuring Azure models.

Model Configuration

The Code tab uses three model tiers: Sonnet (default), Opus (complex tasks), and Haiku (fast, lightweight). With Bifrost, you can override these defaults to use any model from any provider. Override Default Models: Add to ~/.claude/settings.json:
{
  "env": {
    "ANTHROPIC_DEFAULT_SONNET_MODEL": "openai/gpt-5",
    "ANTHROPIC_DEFAULT_OPUS_MODEL": "anthropic/claude-opus-4-5-20251101",
    "ANTHROPIC_DEFAULT_HAIKU_MODEL": "azure/claude-haiku-4-5"
  }
}
Alternative models must support tool use capabilities for file operations, terminal commands, and code editing to work properly with Claude Code.

MCP Integration (Chat Tab)

The Chat tab supports MCP servers configured in claude_desktop_config.json. Connect to Bifrost’s MCP endpoint to give the Chat tab access to all your aggregated MCP tools: Config file locations:
  • macOS: ~/Library/Application Support/Claude/claude_desktop_config.json
  • Windows: %APPDATA%\Claude\claude_desktop_config.json
{
  "mcpServers": {
    "bifrost": {
      "url": "http://localhost:8080/mcp",
      "headers": {
        "Authorization": "Bearer your-bifrost-virtual-key"
      }
    }
  }
}
MCP servers in claude_desktop_config.json are for the Chat tab only. For MCP in the Code tab, configure servers in ~/.claude.json or your project’s .mcp.json file. See MCP Gateway URL for full setup details.

Enterprise Deployment

For organization-wide Bifrost routing, deploy a managed-settings.json file via MDM (Jamf, Kandji, Intune):
  • macOS: /Library/Application Support/ClaudeCode/managed-settings.json
  • Windows: C:\Program Files\ClaudeCode\managed-settings.json
{
  "env": {
    "ANTHROPIC_BASE_URL": "https://bifrost.example.com/anthropic",
    "ANTHROPIC_API_KEY": "org-bifrost-virtual-key"
  }
}
Managed settings cannot be overridden by individual users, ensuring all Code tab traffic routes through Bifrost.

Observability

All Claude Desktop Code tab requests through Bifrost are logged. Monitor them at http://localhost:8080/logs — filter by provider, model, or search through conversation content to track usage patterns across your organization.

Next Steps