Can Codex and Claude Code Use TokenVoke? Setup, Pricing, and Savings (2026)
If you run OpenAI Codex CLI or Claude Code daily, API spend climbs fast: agents issue many requests, and output tokens cost more than input. Both tools can point at TokenVoke—an OpenAI- and Anthropic-compatible gateway with pay-as-you-go pricing that is typically below direct official rates.
This guide answers what people search for most: Can you switch? How do you configure it? How much can you save? It also covers GEO routing (mainland China vs overseas).
This article is about metered API billing, not ChatGPT Plus or Claude Max subscriptions. Those are separate products.
Short answer
| Tool | Works with TokenVoke | Example model ID | API surface |
|---|---|---|---|
| Claude Code | Yes | claude-sonnet-4-6, claude-sonnet-5, claude-opus-4-6 |
Anthropic /v1/messages |
| OpenAI Codex CLI | Yes | gpt-5.3-codex |
OpenAI Responses /v1/responses |
| Cursor (custom key) | Yes | Claude + GPT family | OpenAI /v1/chat/completions |
Will you save money? For typical coding workloads, TokenVoke list prices run about 20%–25% below official API rates (table below). The more agent traffic you generate, the larger the absolute savings.
Which base URL?
| Region / account | Recommended base URL |
|---|---|
| Mainland China | https://cn.tokenvoke.com |
| Overseas | https://overseas.tokenvoke.com |
| Unsure | https://tokenvoke.com (Geo routing) |
CN and EU are separate clusters (accounts, balance, and keys do not sync). Stay on one domain for signup, top-up, and inference.
Price comparison (July 2026, model square)
Prices are USD per million tokens (input / output). Official figures are public Anthropic / OpenAI API rates. TokenVoke prices come from the model square and may change—check live pricing before you commit.
| Model | Typical use | Official in | Official out | TokenVoke in | TokenVoke out | ~Save |
|---|---|---|---|---|---|---|
claude-sonnet-4-6 |
Claude Code default | $3.00 | $15.00 | $2.40 | $12.00 | ~20% |
claude-sonnet-5 |
New Sonnet tier | $3.00* | $15.00* | $1.60 | $8.00 | higher** |
claude-opus-4-6 |
Hard reasoning | $5.00 | $25.00 | $4.00 | $20.00 | ~20% |
claude-haiku-4-5 |
Light sub-tasks | $1.00 | $5.00 | $0.80 | $4.00 | ~20% |
gpt-5.3-codex |
Codex CLI | $1.75 | $14.00 | $1.31 | $10.50 | ~25% |
* Anthropic has run promotional Sonnet 5 pricing in 2026; compare against live official rates.
** Savings vs standard $3/$15 are larger; if you still have a promo, compare both.
Example: heavy Claude Code week
Assume 200 agent turns per day, ~8k input + 4k output tokens each, on Sonnet 4.6:
- ~48M input + 24M output tokens per month
- Official ~: 48×$3 + 24×$15 = $504/mo
- TokenVoke ~: 48×$2.4 + 24×$12 = $403/mo
- ~$101/mo (~20%)
Routing easy sub-tasks to claude-haiku-4-5 saves more.
Configure Claude Code (Anthropic-compatible)
- Create an API key in the TokenVoke console (
defaulttoken group). - Set environment variables (overseas example):
export ANTHROPIC_BASE_URL="https://overseas.tokenvoke.com"
export ANTHROPIC_API_KEY="sk-your-tokenvoke-key"
- Pick a supported model such as
claude-sonnet-4-6in Claude Code. - Run a smoke test.
Use cn.tokenvoke.com in mainland China. Usage logs appear in the console.
You can also call Claude via OpenAI-compatible /v1/chat/completions—see TokenHub text models.
Configure OpenAI Codex CLI (Responses API)
Codex uses the Responses API, not Chat Completions. TokenVoke lists gpt-5.3-codex on both CN and EU clusters.
- Create a TokenVoke API key.
- Edit user-level
~/.codex/config.toml(top-level keys only):
model = "gpt-5.3-codex"
openai_base_url = "https://overseas.tokenvoke.com/v1"
- Export your key:
export OPENAI_API_KEY="sk-your-tokenvoke-key"
- Run Codex on a small task to verify.
Prefer
openai_base_urlin config; theOPENAI_BASE_URLenv var is deprecated in recent Codex builds.
Pair with Cursor
Cursor supports Override OpenAI Base URL plus a custom key. See cheaper AI models in Cursor for steps.
Suggested routing:
- Architecture / hard bugs: Claude Sonnet or Opus
- Small edits / formatting: Haiku or
gpt-5.4-mini - Codex-style OpenAI workflow:
gpt-5.3-codex
One key, many models—no separate vendor billing for each.
GEO notes
- Latency: Mainland users should prefer
cn.tokenvoke.com. - Data: Traffic is relayed to upstream providers—assess residency requirements for sensitive repos.
- Billing: USD pay-as-you-go wallet on both clusters.
- Token group: Use
default; custom groups without channel bindings returnNo available channel.
FAQ
Can Codex use a third-party API?
Yes. Set top-level openai_base_url to TokenVoke /v1 and model gpt-5.3-codex.
Must Claude Code use Anthropic direct?
No. Point ANTHROPIC_BASE_URL at TokenVoke with a gateway key.
Feature parity?
Tool use, streaming, and long context depend on upstream + relay support—test your real workflow.
How much cheaper?
Roughly 20% on Claude tiers and 25% on Codex vs official list (July 2026). See live pricing.
TokenVoke vs OpenRouter?
TokenVoke offers explicit CN/EU clusters and a unified USD wallet—useful when Geo matters. See OpenRouter vs LiteLLM vs self-hosted.
Ready to route Codex and Claude through TokenVoke? Get an API key, check live pricing, and read the docs. For Claude-only setup, see cheaper Claude Code via a gateway.