Codex auf unbegrenztem Claude betreiben

Codex auf unbegrenztem Claude betreiben

Codex führt lange autonome Schleifen aus — genau die Last, bei der Abrechnung pro Token unkalkulierbar wird. Mit einem Pauschaltarif läuft Codex so lange wie nötig zum festen Preis.

Set up the custom provider

Codex reads ~/.codex/config.toml. Add a [model_providers.<name>] table with the gateway base_url, the env_key holding your key, and wire_api = "chat" for the OpenAI-compatible surface, then select it with model_provider.

The CLI, the SDK, and the VS Code extension all read the same file, so one config covers every way you run Codex.

Base URL and model

Use the base URL with /v1 — Codex appends the route itself. Set model to a Claude id the gateway serves (claude-sonnet-4-5 or claude-opus-4-8), no prefix, and export your key into the env_key variable.

Provider ids openai, ollama and lmstudio are reserved; give yours a different name. Keys live in the user-level config, not a project copy.

Why unlimited fits Codex

Each Codex task is a multi-turn loop that resends context every step, so a single deep run can move enormous token volume. On metered pricing that is unpredictable — a loop that retries overnight can quietly run up a large bill.

Flat-rate unlimited removes the meter entirely. You stop rationing turns and let Codex pursue the task to completion, knowing the cost is fixed for the period.

Pick the right model for the loop

Use a Sonnet-class model for most agentic work and an Opus-class one for the hardest reasoning. On an unlimited plan you can leave the stronger model selected without watching token cost.

Verify wire_api against your Codex version — "chat" for OpenAI-compatible; some builds expect "responses".

# ~/.codex/config.toml
model = "claude-sonnet-4-5"
model_provider = "aiprime"

[model_providers.aiprime]
base_url = "https://claudeapikey.dev/v1"
env_key = "AIPRIME_API_KEY"
wire_api = "chat"

FAQ

Can I run Codex on an unlimited Claude plan?
Yes — define a custom provider in config.toml with the gateway base_url and wire_api = "chat", set a Claude model, and the flat-rate plan covers every run.

Why is unlimited good for Codex?
Codex runs long multi-turn loops that resend context, so token use is high and unpredictable. Unlimited keeps cost fixed regardless of run length.

Does the base URL need /v1?
Yes — {SITE}/v1. Codex appends the route itself.

Are there limits on the unlimited plan?
No token limits during the plan, only fair-use rate limits to keep the gateway fast.

Start using Claude in minutes

Get an API key — no Anthropic account or waitlist required.

Get your API key

Weitere Claude API Guides

Was eine Anthropic-kompatible API bedeutetClaude API Credits kaufen: So startest du mit Claude API GuthabenDer günstigste Weg, die Claude API zu nutzenClaude API Fehler — Rate Limits, 400, 500 und 529 behebenClaude API free trial: what's actually free, and what isn'tClaude-Modelle im VergleichClaude API Kosten, verständlich erklärtClaude API Gateway oder direkt bei Anthropic? Ein ehrlicher VergleichClaude API vs. Claude Pro/Max Subscription — welche Option passt besser?Claude API mit Crypto bezahlenClaude API ohne Warteliste — sofortiger ZugangClaude Code API Kosten — Preise und wie du sie senkstClaude Code API Key — So bekommst und konfigurierst du ihnSo bekommst du unbegrenzte Claude-NutzungSo erstellst du einen Claude API KeySo reduzierst du den Token-Verbrauch mit ClaudeClaude über eine OpenAI-kompatible API nutzenEinen Unlimited Hermes Agent mit Claude betreibenUnlimited OpenClaw auf Claude betreibenWas „Unlimited“ Claude API Access bedeutetSo bekommst du einen unbegrenzten Claude API KeyUnbegrenzte Claude Code Nutzung — ohne Token-LimitsUnbegrenzter Claude Opus 4.8 ZugangUnbegrenzte Claude-Nutzung — Pläne und PreiseUnlimited Aider mit der Claude APICherry Studio mit unbegrenztem Claude betreibenUnbegrenzter Claude Code ZugangUnbegrenztes Cline mit der Claude APIUnlimited Cursor mit der Claude APIFactory Droid mit unbegrenztem Claude betreibenGitHub Copilot mit unbegrenztem Claude betreibenUnbegrenztes Claude in JetBrains IDEsKilo Code auf unbegrenztem ClaudeLangChain mit unbegrenztem Claude aufbauenUnbegrenztes Claude hinter LiteLLMn8n-Workflows auf unbegrenztem ClaudeUnbegrenztes OpenCode mit der Claude APIUnbegrenztes Roo Code mit der Claude APIUnbegrenztes Claude in VS Code — drei WegeZed mit unbegrenztem Claude betreiben