Claude Desktop

Route Claude Desktop App traffic through FinOps for multi-provider routing, virtual keys, and observability.

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 FinOps, 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 FinOps with Claude Desktop, try switching to * or adding the specific headers required by your client. By default, FinOps 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:

TabTrafficFinOps Integration
Code tabUses the Anthropic Messages API (Claude Code under the hood)Route inference through FinOps's /anthropic endpoint
Chat tabConnects directly to claude.aiConnect to FinOps'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 FinOps endpoint and API key under the env key:

{
 "env": {
 "ANTHROPIC_API_KEY": "your-finops-virtual-key",
 "ANTHROPIC_BASE_URL": "{AI_GATEWAY_URL}/anthropic"
 }
}

For production deployments:

{
 "env": {
 "ANTHROPIC_API_KEY": "your-finops-virtual-key",
 "ANTHROPIC_BASE_URL": "https://finops.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 FinOps

Setup

Add the FinOps endpoint and pin model versions in ~/.claude/settings.json:

{
 "env": {
 "ANTHROPIC_API_KEY": "finops-virtual-key",
 "ANTHROPIC_BASE_URL": "{AI_GATEWAY_URL}/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.

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 FinOps

Setup

{
 "env": {
 "ANTHROPIC_API_KEY": "finops-virtual-key",
 "ANTHROPIC_BASE_URL": "{AI_GATEWAY_URL}/anthropic",
 "ANTHROPIC_DEFAULT_SONNET_MODEL": "vertex/claude-sonnet-4-6",
 "ANTHROPIC_DEFAULT_HAIKU_MODEL": "vertex/claude-haiku-4-5"
 }
}

Azure via FinOps

Setup

{
 "env": {
 "ANTHROPIC_API_KEY": "finops-virtual-key",
 "ANTHROPIC_BASE_URL": "{AI_GATEWAY_URL}/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 FinOps dashboard.

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 FinOps, 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 FinOps'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": {
 "finops": {
 "url": "{AI_GATEWAY_URL}/mcp",
 "headers": {
 "Authorization": "Bearer your-finops-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 FinOps 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://finops.example.com/anthropic",
 "ANTHROPIC_API_KEY": "org-finops-virtual-key"
 }
}

Managed settings cannot be overridden by individual users, ensuring all Code tab traffic routes through FinOps.

Observability

All Claude Desktop Code tab requests through FinOps are logged. Monitor them at {AI_GATEWAY_URL}/logs - filter by provider, model, or search through conversation content to track usage patterns across your organization.

Next Steps