Skip to content
Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
36 changes: 36 additions & 0 deletions docs/cli-agents/claude-code.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,42 @@ Claude Code supports multiple authentication methods. Choose the one that matche
claude
```

## Setup with the VS Code extension

If you prefer using Claude Code inside VS Code, install the [Claude Code extension](https://marketplace.visualstudio.com/items?itemName=anthropic.claude-code) and point it to Bifrost using the same environment variables you use for the CLI.

### 1. Install the extension

1. Open **Extensions** in VS Code (`Cmd+Shift+X` on macOS)

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P2 Missing Windows/Linux keyboard shortcut

Only the macOS shortcut is mentioned. Windows and Linux users use Ctrl+Shift+X.

Suggested change
1. Open **Extensions** in VS Code (`Cmd+Shift+X` on macOS)
1. Open **Extensions** in VS Code (`Cmd+Shift+X` on macOS, `Ctrl+Shift+X` on Windows/Linux)

2. Search for **Claude Code**
3. Install **Claude Code** by Anthropic

### 2. Configure Bifrost endpoint

Add Bifrost variables in your editor settings:

```json
{
"claudeCode.environmentVariables": [
{
"name": "ANTHROPIC_BASE_URL",
"value": "http://localhost:8080/anthropic"
},
{
"name": "ANTHROPIC_DEFAULT_SONNET_MODEL",
"value": "vertex/claude-sonnet-4-6"
},
{
"name": "ANTHROPIC_DEFAULT_HAIKU_MODEL",
"value": "vertex/claude-haiku-4-5"
}
]
}
Comment on lines +50 to +64

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P1 Wrong VS Code settings key

The key claudeCode.environmentVariables does not exist in the Claude Code extension. The correct key is claude-code.environmentVariables (kebab-case), as confirmed by the official VS Code setup docs. Using the wrong key will silently have no effect — the environment variables will never be passed to the Claude process.

Suggested change
"claudeCode.environmentVariables": [
{
"name": "ANTHROPIC_BASE_URL",
"value": "http://localhost:8080/anthropic"
},
{
"name": "ANTHROPIC_DEFAULT_SONNET_MODEL",
"value": "vertex/claude-sonnet-4-6"
},
{
"name": "ANTHROPIC_DEFAULT_HAIKU_MODEL",
"value": "vertex/claude-haiku-4-5"
}
]
}
{
"claude-code.environmentVariables": [
{
"name": "ANTHROPIC_BASE_URL",
"value": "http://localhost:8080/anthropic"
},
{
"name": "ANTHROPIC_DEFAULT_SONNET_MODEL",
"value": "vertex/claude-sonnet-4-6"
},
{
"name": "ANTHROPIC_DEFAULT_HAIKU_MODEL",
"value": "vertex/claude-haiku-4-5"
}
]
}

```
Comment on lines +48 to +65

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

⚠️ Potential issue | 🟡 Minor

Add ANTHROPIC_DEFAULT_OPUS_MODEL to complete the example.

The example configuration is missing the Opus tier variable. Line 165 documents that Claude Code uses three model tiers (Sonnet, Opus, and Haiku), and line 176 shows ANTHROPIC_DEFAULT_OPUS_MODEL is supported. For consistency and completeness, include all three tier variables in the VS Code configuration example.

Based on learnings, the documented environment variables match the implementation in cli/internal/harness/native_config.go.

📝 Proposed fix to add the missing environment variable
     {
       "name": "ANTHROPIC_DEFAULT_HAIKU_MODEL",
       "value": "vertex/claude-haiku-4-5"
+    },
+    {
+      "name": "ANTHROPIC_DEFAULT_OPUS_MODEL",
+      "value": "vertex/claude-opus-4-5-20251101"
     }
   ]
 }
🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@docs/cli-agents/claude-code.mdx` around lines 48 - 65, Add the missing Opus
tier env var to the VS Code example JSON: insert an object with "name":
"ANTHROPIC_DEFAULT_OPUS_MODEL" and an appropriate example value (e.g.,
"vertex/claude-opus-4-6") into the array alongside
ANTHROPIC_DEFAULT_SONNET_MODEL and ANTHROPIC_DEFAULT_HAIKU_MODEL in the
claude-code.mdx code block so all three tiers (Sonnet, Opus, Haiku) are shown;
ensure the new entry follows the same object structure as the others.


If virtual keys are enabled, also add `ANTHROPIC_API_KEY` in the same list (use your Bifrost virtual key value). If not, set it to `dummy`.


## Amazon Bedrock via Bifrost

### Setup
Expand Down
Loading