#12062·Roo-Code

Anthropic provider with custom base URL ignores custom model name, sends 'claude-sonnet-4-5' instead

Author: cobra91Created Apr 5, 2026Updated May 14, 2026
Labelsbug

Bug Description

When configuring Anthropic as the API provider with a custom base URL (e.g., http://localhost:3000/api) and entering a custom model name in the model field, the custom model name is ignored. Instead, the request always sends claude-sonnet-4-5 as the model identifier, regardless of what was entered.

Steps to Reproduce

  1. Open Roo Code settings
  2. Select Anthropic as the API Provider
  3. Set a custom Base URL (e.g., http://localhost:3000/api)
  4. Enter a custom model name in the model field (e.g., qwen/qwen3.6-plus or any other value)
  5. Save and start a conversation
  6. Observe the outgoing request body

Expected Behavior

The request body sent to the custom endpoint should contain the custom model name:

json
{
  "model": "qwen/qwen3.6-plus",
  ...
}

Actual Behavior

The request body always contains the hardcoded default:

json
{
  "model": "claude-sonnet-4-5",
  ...
}

Evidence

Captured request body from Roo Code hitting a local Anthropic-compatible proxy:

json
{
  "model": "claude-sonnet-4-5",
  "max_tokens": 16384,
  "temperature": 1,
  "thinking": {
    "type": "enabled",
    "budget_tokens": 8192
  },
  ...
}

The model field is always claude-sonnet-4-5 regardless of the custom model name entered in settings.

Environment

  • OS: Windows 11
  • VS Code version: latest
  • Roo Code version: latest
  • API Provider: Anthropic (custom base URL)