Skip to main content
idapt
HomeAI ModelsExploreResourcesPricing
Sign inUse for Free
  • Home
  • Pricing
  • AI Models
  • Skills
  • Image models
  • Voice models
  • Video models
  • Rankings
  • Multi-Model Chat
  • Agents
  • Computers
  • Drive
  • Automations
  • AI Gateway
  • All features →
  • Blog
  • About
  • Comparisons
  • Benchmarks
  • Model Match
  • Demos
  • Help center
  • FAQ
  • Privacy
  • Support
  • Developers
  • Quickstarts
  • API reference
  • API pricing
  • CLI
  • MCP
  • Migrate
  • Downloads
  • Desktop
© idapt[email protected]TermsPrivacy PolicyLegal noticeReport content
X (Twitter)Discord
Help Center
🔗

Codex CLI with idapt

Found this helpful? Share it:

Set up Codex CLI against idapt's compatible APIs with the steps below. This article and the AI Gateway quickstarts lander render the same shared steps, so they never drift.

Codex CLI with idapt

A TOML provider block with command-based auth points Codex at idapt and pulls the live model catalog.

  1. 1

    Install

    bash
    npm i -g @openai/codex
  2. 2

    Point it at idapt

    toml
    # ~/.codex/config.toml
    model_provider = "idapt"
    model = "openai/gpt-5.6-luna"
    model_reasoning_effort = "high"
    
    [model_providers.idapt]
    name = "idapt"
    base_url = "https://idapt.app/api/openai/v1"
    wire_api = "chat"
    
    [model_providers.idapt.auth]
    command = "sh"
    args = ["-c", "echo $IDAPT_API_KEY"]

    Command-based auth also triggers the model-catalog refresh, so non-OpenAI ids get real metadata instead of the Unknown model fallback. Windows: use command = "powershell" with Write-Output $env:IDAPT_API_KEY. model_reasoning_effort takes low, medium, high, xhigh, or max.

GOOD TO KNOW

API keys and scopesOpenAI-compatible API referenceOpenRouter-compatible API referenceRate limits and errors

MORE QUICKSTARTS

Claude Code

OpenCode

Crush

Moving to idapt entirely?

The quickstart keeps codex as your surface. When you are ready to leave it, one command imports its chat history into idapt: run Import chats from coding agents (idapt chat import --from codex), then continue in idapt directly.

Related articles

🔑

API keys and scopes

Create a key, choose its scopes, pin it to an API version, rotate it, and cap what it can spend.

🚦

Rate limits and errors

Every error shape the API returns, what each rate limit is, and how to handle a wall in code.

🛡️

Cap what an API key spends

Give every Gateway API key a lifetime, monthly, or daily USD cap, and what a capped-out key returns.

🔗

OpenAI-compatible API

Use idapt's 200+ models from any app that speaks the OpenAI API format.

🤖

Claude Code with idapt

Point Claude Code at idapt's Anthropic-compatible API with ANTHROPIC_BASE_URL and an idapt key; add MCP for workspace access.

🔗

OpenCode with idapt

Configure OpenCode to route through idapt's OpenAI-compatible API: a provider block in opencode.json with the base URL and your key.

🔗

Aider with idapt

Use Aider with idapt's OpenAI-compatible API: OPENAI_API_BASE plus a prefixed model flag route edits through your idapt key.

🧰

Import chats from coding agents

Bring your Claude Code, Codex, or OpenCode session history into idapt with one CLI command: dates and tool calls included.

Up next

Continue with idapt

Configure Continue.dev to use idapt's OpenAI-compatible API: a models block with apiBase and your key.

Was this helpful?