Skip to content
Coder Docs

JetBrains

Use Claude Agent and Codex in JetBrains IDEs with AI Gateway.

On this page

Note

AI Gateway is part of AI Governance, which is included with a Premium license.

JetBrains IDEs 2026.3 and later include JetBrains Air, an agent workspace provided by the bundled Air plugin. When you connect a JetBrains IDE to a Coder workspace, Air runs coding agents inside the workspace and reuses their existing configuration. If the workspace is configured for AI Gateway, Claude Agent and Codex sessions route requests through AI Gateway without any configuration in the IDE.

Prerequisites

You don't need a JetBrains AI subscription.

How Air uses the workspace configuration

AgentHow Air runs itSettings read from the workspace
Claude AgentInstalls its own copy from the ACP agent registryANTHROPIC_BASE_URL and ANTHROPIC_AUTH_TOKEN
CodexRuns the Codex CLI installed in the workspaceThe AI Gateway model provider in ~/.codex/config.toml

Configure the template

To configure both agents for every workspace, set enable_ai_gateway = true on the Claude Code module and the Codex module. For Claude Agent, you can instead set the environment variables on the workspace agent, as shown in Configure in-workspace tools.

Use a local IDE

If you run the IDE locally instead of in a Coder workspace, Air uses the local configuration of each agent. Configure Claude Code and Codex for AI Gateway with a long-lived Coder API token.

Start a session

  1. Open the Agent Sessions tool window.
  2. Next to New Session, select a Claude Agent or Codex preset.
  3. Send a prompt.

References: Agents in IntelliJ IDEA, Configure agent authorization