How the integration works
Claude Code reads Anthropic-compatible environment variables. Point its base URL at DeepSeek-V4.io and use a paid DeepSeek-V4.io API key; the gateway handles the upstream provider and model mapping.
Create and manage it on /developer.
The client talks to its native compatible endpoint.
Provider credentials and routing stay on the server.
Before you start
- Claude Code installed and launched successfully
- A paid DeepSeek-V4.io account with an API key from /developer
- A fresh terminal session after changing environment variables
Configure Claude Code
export DEEPSEEK_V4_API_KEY="your-deepseek-v4-io-key"
export ANTHROPIC_BASE_URL="https://deepseek-v4.io/api"
export ANTHROPIC_AUTH_TOKEN="$DEEPSEEK_V4_API_KEY"
export ANTHROPIC_API_KEY=""
export ANTHROPIC_MODEL="deepseek-v4-flash"cd /path/to/your/project
claudeVerify the setup
Verified against the public DeepSeek-V4.io gateway with Claude Code 2.1.196 on 2026-08-12.
- 1Ask Claude Code to inspect one file without changing it.
- 2Ask it to call a read-only tool and use the result in its final answer.
- 3Confirm streaming completes and the request appears in the Developer usage view.
Troubleshooting
401 authentication error
Create a paid DeepSeek-V4.io key and confirm ANTHROPIC_AUTH_TOKEN contains that key, not a DeepSeek Platform or OpenRouter key.
404 endpoint error
Use ANTHROPIC_BASE_URL=https://deepseek-v4.io/api. Claude Code appends /v1/messages itself.
Old provider is still used
Open a new terminal after exporting the variables, then start a new Claude Code session.
Sources and support boundary
Configuration fields are checked against the tool publisher's documentation. DeepSeek-V4.io owns this gateway guide and support for its endpoint; it does not represent the tool publisher.
Ready to connect Claude Code?
Create a DeepSeek-V4.io API key, copy the configuration above, and verify one read-only tool call before using it on a real project.
Open Developer Dashboard