Skip to content

install's dummy ANTHROPIC_AUTH_TOKEN disables MCP and claude.ai-tied tools in Claude Code #15

Description

@DexterStorey

Symptom

After tokenmaxx install, Claude Code loses everything tied to the claude.ai login: connectors/MCP servers from claude.ai are not fetched, MCP tool search is off, and server-side tools go away — even though the user is still natively logged in.

Root cause

installClaudeConfig writes both keys into ~/.claude/settings.json:

"env": {
  "ANTHROPIC_AUTH_TOKEN": "managed-by-tokenmaxx",
  "ANTHROPIC_BASE_URL": "http://127.0.0.1:8459/anthropic"
}

A set ANTHROPIC_AUTH_TOKEN takes precedence over the native claude.ai OAuth login and switches Claude Code into gateway auth. Per the Claude Code docs, claude.ai connectors are fetched only when the active auth method is a claude.ai subscription login, and MCP tool search is disabled for non-first-party gateways. The native login stays saved but unused, so every login-tied feature disappears.

Why the token is unnecessary

The proxy never authenticates callers by that value — forwardHeaders unconditionally overwrites Authorization with the active account's credential. With only ANTHROPIC_BASE_URL set, Claude Code keeps its native login (identity, connectors, tools) and sends its own bearer token to the proxy, which replaces it per request. Routing and auto-rotation are unaffected.

Verified locally by pointing ANTHROPIC_BASE_URL at a header-logging listener: with the dummy token set, Claude Code sends Bearer managed-by-tokenmaxx and runs in gateway mode; the upstream request tokenmaxx produces is identical either way.

Behavior change to note

Without the dummy token, Claude Code requires a native login to run when routed through tokenmaxx. That matches the "official apps only" stance in the README, but existing users who never logged in natively will be prompted to /login once.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions