
How to Use the DeepSeek V4 Pro API on EvoLink: First Call to Claude Code
POST https://direct.evolink.ai/v1/messages with model: "deepseek-v4-pro" in Anthropic Messages format, and read the reply from content. The same endpoint lets you point Claude Code at DeepSeek V4 Pro by changing two environment variables — no code changes.deepseek-v4-pro, and since August 13, 2026 (the official changelog date) that same ID serves the upgraded 0813 build (the agent-focused GA release). You do not change the ID to get the new build. The old aliases deepseek-chat and deepseek-reasoner were retired upstream on July 24, 2026 — if your code still uses them, this guide is your migration path.What you will build
- a first successful V4 Pro request in Anthropic Messages format;
- a Claude Code setup that runs on V4 Pro through EvoLink;
- correct thinking-mode control (and why
budget_tokenssilently does nothing); - handling for the three parameter mappings that break Claude migrations;
- a 429/concurrency strategy and a fallback route for production.
Prerequisites
- An EvoLink account and an API key from the dashboard.
- Any HTTP client. Examples below use cURL and plain Python (
requests) so the request shape is explicit. - The full parameter contract lives in the DeepSeek V4 Messages API documentation; this guide focuses on flow and pitfalls, not on duplicating the reference.
Step 1 — Your first V4 Pro request
curl https://direct.evolink.ai/v1/messages \
-H "Authorization: Bearer $EVOLINK_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"model": "deepseek-v4-pro",
"max_tokens": 1024,
"messages": [
{"role": "user", "content": "Refactor this function to be iterative: def f(n): return n*f(n-1) if n else 1"}
]
}'content array. With thinking enabled (the default), the model's reasoning arrives as a content block of type: "thinking" followed by the answer block — read the final text block, and budget for the thinking tokens in your output cost (more on this in Step 4).The same call in Python, dependency-light:
import requests, os
resp = requests.post(
"https://direct.evolink.ai/v1/messages",
headers={"Authorization": f"Bearer {os.environ['EVOLINK_API_KEY']}"},
json={
"model": "deepseek-v4-pro",
"max_tokens": 1024,
"messages": [{"role": "user", "content": "Summarize the tradeoffs of MoE routing in two sentences."}],
},
timeout=120,
)
resp.raise_for_status()
blocks = resp.json()["content"]
print(next(b["text"] for b in blocks if b["type"] == "text"))max_tokens accepts up to 384,000 — V4 Pro's unusually large output ceiling — and the context window is 1M tokens.Step 2 — Switch Claude Code to DeepSeek V4 Pro
Because EvoLink exposes V4 Pro on an Anthropic-compatible Messages endpoint, Claude Code can run on it by overriding its endpoint variables:
export ANTHROPIC_BASE_URL="https://direct.evolink.ai"
export ANTHROPIC_AUTH_TOKEN="your-evolink-api-key"
export ANTHROPIC_MODEL="deepseek-v4-pro"
claudeThat is the entire switch: your agent workflow, tools, and prompts stay the same. Community reports consistently describe V4 Pro as strongest on long, multi-step coding tasks — the 0813 build roughly doubled its scores on terminal-agent benchmarks — so an agentic harness like Claude Code is exactly where it earns its price difference against closed models.
Two practical notes for this setup:
- Tool calling works through the standard Anthropic
tool_use/tool_resultflow, so Claude Code's file edits and shell tools function normally. - V4 Pro has no vision input. Claude Code features that attach screenshots or images will not work on this route; keep a vision-capable model configured for those tasks.
Step 3 — The three migration pitfalls
These are the mappings that silently differ from Anthropic's native API. All three come from the current EvoLink contract, verified August 13, 2026.

budget_tokens is ignored. Anthropic's native thinking budget field does nothing here. Thinking is controlled by two other fields:{
"thinking": {"type": "enabled"},
"output_config": {"effort": "high"}
}low, high, or max, and the default is high — medium and xhigh are accepted but silently mapped to high per DeepSeek's official mapping table. If you migrated code that sets budget_tokens (or assumed a medium default) and wondered why behavior or billing never changes — this is why.role: "system" is rejected. System prompts must use the top-level system field, not a message with a system role:{
"model": "deepseek-v4-pro",
"system": "You are a terse senior reviewer.",
"messages": [{"role": "user", "content": "Review this diff..."}]
}top_k, container, mcp_servers, and metadata are not supported on this route, and image/document content types are rejected. Strip them during migration rather than letting requests fail in production.Step 4 — Thinking effort and what it does to your bill
DeepSeek bills thinking tokens as output tokens, and V4 Pro is a heavy thinker: community measurements have shown it consuming several times more reasoning tokens than closed-model peers on the same task. Practical guidance:
- The default is
effort: "high"— a heavy setting for routine work. Setlowexplicitly for bulk steps and keephighfor tasks where a failed attempt costs more than the extra tokens;maxis the escalation tier. - Cache-hit input is billed at roughly 1/120 of the cache-miss rate until August 16, 2026 16:00 UTC; DeepSeek's published repricing then moves the Pro ratio to about 1/30 with peak/off-peak dual rates. Check live per-token rates on the DeepSeek model pricing on EvoLink rather than trusting any blog's numbers, including this one's.
- For high-volume, low-difficulty steps (classification, summaries), route to
deepseek-v4-flashinstead and keep Pro for the hard steps.
Step 5 — Concurrency, 429s, and fallback
429 beyond it. Requests that queue longer than 10 minutes before inference are dropped. For production:- Treat
429as backpressure: exponential backoff with jitter, and cap in-flight requests below your measured ceiling. - Set client timeouts generously for
higheffort tasks — thinking time precedes the first token. - Configure a fallback: because the EvoLink route speaks the same Messages format for multiple models, a router-level fallback from
deepseek-v4-proto another available model is a config change, not a rewrite. Community threads are full of exactly this pattern — Flash for bulk steps, Pro for hard steps, a closed model as final fallback.
FAQ
deepseek-v4-pro. Since August 13, 2026 it serves the 0813 GA build — same ID, upgraded model./v1/messages route documented above. Check the API documentation for the current state before wiring an OpenAI-style client.thinking.type (enabled/disabled) plus the effort setting (low/high/max, default high; medium is accepted but maps to high). Anthropic's budget_tokens is ignored on this route.Where to go next
- DeepSeek models on EvoLink — live pricing and model access.
- DeepSeek V4 Pro 0813: what changed — the GA build's agent and Codex changes.
- Pro vs Flash decision guide — which tier fits which workload.


