Help
Claude Code errors
Find the cause by error message. Each section says what it means, then what to do. First confirm where requests go: run /status in Claude Code; the Base URL should be https://corecode.live. If it is not, fix the setup with Claude Code first.
Unable to connect to Anthropic services
On first launch, onboarding contacts Anthropic's services, which are often unreachable from mainland China, so Claude Code says Unable to connect to Anthropic services or Failed to connect to api.anthropic.com. This has nothing to do with the relay; skip onboarding:
- Open
~/.claude.json(on Windows,%USERPROFILE%\.claude.json) in an editor. - Add
"hasCompletedOnboarding": trueat the top level and save. - Run
claudeagain.
If the remaining official requests (auto-update, telemetry, error reporting) still fail, add "CLAUDE_CODE_DISABLE_NONESSENTIAL_TRAFFIC": "1" to env in ~/.claude/settings.json to turn them off; see Recommended settings.
Invalid API key · Please run /login
Claude Code did not find the relay key and fell back to the official login. Common causes:
- The variables were set in another terminal only. Putting them in
envin~/.claude/settings.jsonis the reliable way; every terminal and the VS Code extension read it. - A misspelled variable. The relay key goes in
ANTHROPIC_AUTH_TOKENand the address inANTHROPIC_BASE_URL. - Claude Code was not restarted. It reads the configuration only at startup.
Do not follow the hint to run /login with a claude.ai account; that switches Claude Code to the official account.
Auth conflict: Both a token and an API key are set
Both ANTHROPIC_AUTH_TOKEN and ANTHROPIC_API_KEY are set, and Claude Code cannot tell which to use. Remove ANTHROPIC_API_KEY and keep only ANTHROPIC_AUTH_TOKEN. Check with echo $ANTHROPIC_API_KEY (in PowerShell, $env:ANTHROPIC_API_KEY) that it is empty in the current terminal too; if you signed in to claude.ai before, run /logout as well.
401 authentication_error
The relay received the request but does not accept the key: characters were lost when copying, the key was deleted, or it is another provider's key. Copy it again from the API keys page and check that it starts with sk- and has no surrounding spaces.
403
| Message | Cause | What to do |
|---|---|---|
| Insufficient quota | The balance is used up. | Top up in Wallet; it works again at once, with no setup change. |
| Only requests from Claude Code are accepted | Keys in the 仅限CC (Claude Code only) group admit the Claude Code CLI only; SDKs, curl and other clients are refused. | Use it in Claude Code; for other clients, use a key in the 可外接 (external clients) group. |
| Request not allowed | The request went straight to Anthropic and was refused by its region restriction, so it did not go through the relay. | Check the Base URL with /status; see above. |
| This conversation contains a message the upstream model refused under its usage policy | Anthropic's safety classifier refused a message in this conversation. Sending the same conversation again would be refused again, so CoreCode stops it instead of forwarding it. The classifier sometimes refuses ordinary requests too, including the separate checks Claude Code's auto mode sends. | Start a new conversation, or edit the refused message and send it again. If it keeps happening, check whether CLAUDE_CODE_DISABLE_EXPERIMENTAL_BETAS is set; see The cost of auto mode. |
429 rate_limit_error
The key went over its request rate or concurrency limit. Claude Code backs off and retries by itself, so an occasional one needs no action. If it keeps happening, run fewer Claude Code sessions and subagents at once; contact us for higher concurrency.
529 overloaded_error
Anthropic is temporarily overloaded; your setup is not the cause, and Claude Code retries by itself. If it lasts more than a few minutes, check service status, or switch models for a while with /model.
500, 502, 503, 504
503withService deployment in progress; retry shortly.: CoreCode is releasing. The response carriesRetry-After: 5; retry after a few seconds. Requests already in progress are not affected.- Any other
5xx: the upstream or the gateway failed. Check service status first; if it looks normal and the error repeats, send us the time of the failed request from your usage logs.
400 invalid_request_error
| Message | What to do |
|---|---|
prompt is too long | The context is over the model's limit. Run /compact to compress the history, or start a new session with /clear. |
| Model does not exist | Use a model name listed on the Pricing page, without a vendor prefix. |
No output for a long time, or a timeout
With extended thinking, the model can go minutes without text; that is normal. CoreCode's gateway read timeout is 10 minutes. Claude Code's own timeout is API_TIMEOUT_MS, in milliseconds; set it below 10 minutes and the client cuts long thinking short.
With a proxy or VPN on
corecode.live is reachable directly from mainland China. A global proxy sends requests the long way round: slower, and now and then a dropped stream. Add a DIRECT rule for corecode.live in your proxy client. If the payment page does not load, turn the proxy off and try again too.
Still stuck
Check service status first. If it looks normal, send us three things: the output of claude --version, the exact error, and the time of the failed request from your usage logs. You can also ask in the WeChat group. Other questions are in the FAQ.