Desktop Code tab: Opus 5 capped at 200K on a Team Premium seat; app always injects ANTHROPIC_BASE_URL and no claude-opus-5[1m] row exists

Status Open
Reported on v2.1.209
Maintainer reply None cached
Activity 0 comments · opened Jul 28, 2026

Environment

  • macOS 25.5.0 (arm64)
  • Claude Desktop, Code tab
  • Claude Code 2.1.209 and 2.1.219 (both affected)
  • Team plan, Premium seat
  • Model: claude-opus-5

Expected

Per model configuration docs:

On Max, Team, and Enterprise plans, including both Team Standard and Team Premium seats, Opus is automatically upgraded to 1M context with no additional configuration.

Actual

The context indicator reads 52.8k / 200.0k (26%). In ~/.claude.json, tengu_hawthorn_window is 200000.

Unaffected by all of the following:

  • signing out and back in, on both claude.ai and Claude Code
  • fully quitting and relaunching the app
  • adding usage credits (the org had a negative credit balance; topping it up cleared cachedExtraUsageDisabledReason from "out_of_credits" to null, but hasExtraUsageEnabled stayed false and the window stayed 200000)
  • upgrading Claude Code 2.1.209 -> 2.1.219

Observation: the desktop app always sets ANTHROPIC_BASE_URL

From the shipped Claude.app/Contents/Resources/app.asar:

return {
  CLAUDE_CODE_ENTRYPOINT: n.type === "3p" ? "claude-desktop-3p" : "claude-desktop",
  ANTHROPIC_BASE_URL: e.apiHost,
  // ...
}

Confirmed in the session environment: ANTHROPIC_BASE_URL=https://api.anthropic.com. It is not set in any shell profile or settings file. The app injects it.

Hypothesis (not documented for Opus, please confirm or correct)

The docs describe a gateway path that budgets the window at 200K, but state it under the Sonnet 5 context window heading:

LLM gateway: when ANTHROPIC_BASE_URL points at a gateway, Claude Code can't verify 1M support. To use the full window, select Sonnet 5 (1M context) in the model picker, which maps to sonnet[1m].

If that gateway detection keys on ANTHROPIC_BASE_URL merely being set, rather than on it differing from the default endpoint, then the desktop app injecting https://api.anthropic.com would trip it and suppress the subscription auto-upgrade for Opus as well. That would explain a 200K window on a plan the docs say includes 1M, and it would affect every Claude Desktop Code-tab user on such a plan.

I have not been able to verify the detection logic itself, so this is offered as a lead rather than a conclusion. If gateway detection is not what is capping this, the underlying question stands on its own: on a Team Premium seat with claude-opus-5, what makes tengu_hawthorn_window resolve to 200000, and what is a user supposed to change?

Suggested fix, if the hypothesis holds

Either skip injecting ANTHROPIC_BASE_URL when it equals the default Anthropic endpoint, or exempt the default endpoint from gateway detection so entitlement-based 1M resolution still applies.

Secondary issue: the documented [1m] escape hatch does not exist for Opus 5

The docs give [1m] as the way to force a 1M window when not on an auto-upgrade tier. That escape hatch is unavailable for Opus 5. The model catalog contains claude-opus-4-8[1m], claude-sonnet-5[1m], and claude-fable-5[1m], but no claude-opus-5[1m]. Running /model claude-opus-5[1m] reports Set model to claude-opus-5[1m] while requests continue to go out as plain claude-opus-5.

So on the desktop app there is currently no route to a 1M window on Opus 5: the auto-upgrade does not apply, and the manual override has no model row to select.

Possibly related

#70609, #63447, #36351

View original on GitHub ↗