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
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
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
cachedExtraUsageDisabledReasonfrom"out_of_credits"tonull, buthasExtraUsageEnabledstayedfalseand the window stayed200000) - 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: whenANTHROPIC_BASE_URLpoints 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 tosonnet[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