Problem
After selecting Claude Official in cc-switch, launching Claude Code can still show API Usage Billing instead of using first-party Claude subscription / Remote Control auth.
A representative claude doctor output points to stale API auth still being active:
Remote Control requires claude.ai subscription auth. ANTHROPIC_AUTH_TOKEN is set, so this session is using API-key auth — unset it (or run in a shell without it) to use Remote Control.
This can happen even after /login succeeds because cc-switch can still leave API-specific Claude configuration in the active launch/config path.
Root Cause
There are two paths that should treat Claude Official differently from third-party Claude API providers:
- The provider terminal launcher always uses provider-specific
claude --settings <temp-config> settings, which can keep API auth active for the official provider.
- Claude live settings writes do not remove stale API override values from an official provider record, so
ANTHROPIC_*, apiBaseUrl, primaryModel, and smallFastModel can be written back into Claude's settings.
Expected Behavior
When the selected provider is Claude Official:
- cc-switch should not inject provider-specific API settings into Claude Code.
- stale API auth env vars should not keep Remote Control disabled.
- official Claude settings such as permissions should still be preserved.
- non-official Claude providers should continue to launch with provider-specific settings.
Problem
After selecting
Claude Officialin cc-switch, launching Claude Code can still showAPI Usage Billinginstead of using first-party Claude subscription / Remote Control auth.A representative
claude doctoroutput points to stale API auth still being active:This can happen even after
/loginsucceeds because cc-switch can still leave API-specific Claude configuration in the active launch/config path.Root Cause
There are two paths that should treat
Claude Officialdifferently from third-party Claude API providers:claude --settings <temp-config>settings, which can keep API auth active for the official provider.ANTHROPIC_*,apiBaseUrl,primaryModel, andsmallFastModelcan be written back into Claude's settings.Expected Behavior
When the selected provider is
Claude Official: