Coding agents

Set up your coding agents

Install the Ramp CLI and point Claude Code, Codex, OpenCode, and other coding agents at Router.

Router is compatible with all coding agents that support the OpenAI Responses API. In addition, we provide direct integrations with several popular coding agents through the ramp router command in the Ramp CLI:

Coding agent
CLI name
Claude Code
claude-code
Claude Desktop (macOS)
desktop
Codex (CLI and desktop app)
codex
OpenCode
opencode
Pi
pi
Hermes
hermes
Conductor (macOS)
conductor
Antigravity
antigravity
Cursor
cursor

On a Mac? We recommend Router for Mac instead of the steps on this page. It walks you through signing in and choosing your agents, with no terminal needed, and then shows your spend in the menu bar. This also applies when a coding agent is setting Router up for you: have it install and open the app, then finish setup in the app yourself. The steps on this page are for Linux and Windows, or if you prefer the terminal.

No browser on this machine? Skip to On a machine without a browser, which sets up your agents with an API key.

You can also set up any of these agents by hand without running an installer. The manual setup guides walk through each one. For everything else ramp router can do once it's installed, see Ramp CLI.

Setting up your coding agent using the Ramp CLI

There are two ways to set up, and you can switch later by running setup again:

  • With connectors. Your agents use Router's models and can also reach the apps your company has enabled, such as Slack or GitHub, through connectors. This is available for Claude Code, Claude Desktop, Codex, OpenCode, Pi, and Antigravity, and is described below.
  • Models only. Your agents use Router's models and nothing else changes. Choose this if you don't need connectors, or if you use Hermes or Conductor. See Model-only setup.

To set up with connectors, install the Ramp CLI, then configure Router models and connectors:

curl -fsSL https://agents.ramp.com/install.sh | sh -s -- --no-skills
ramp router configure --connectors

If the installer updates your PATH, open a new terminal before running ramp router configure --connectors.

The CLI lists the coding agents it finds on your machine, with none selected. Use the up and down arrow keys to move, Enter or Space to select or deselect an agent, and a to select or deselect them all. Then move to Submit and press Enter to confirm.

If you chose Claude Code or Codex, setup may then ask which models they should show. Recommended models keeps their model pickers short, and All available models lists everything your key can use.

After that, sign in with Ramp in your browser and approve connector access for the account and company shown. Setup offers to reuse a saved Router API key or creates one for you if you don't have one.

Cursor isn't in this list. To set it up, name it: ramp router configure cursor. See Cursor below.

Claude Desktop is included automatically. On a Mac with Claude Desktop installed, ramp router configure --connectors always sets up Claude Desktop and restarts it during setup. Afterwards, Claude Desktop runs through Router instead of your Claude.ai account, so your Claude.ai chats and projects won't appear in it. They aren't deleted, and running ramp router configure disconnect desktop puts Claude Desktop back the way it was. If you only want Router in your terminal, name the agent instead, for instance ramp router configure claude-code --connectors.

Connect your apps on Connectors, then restart your agent. If the page isn't available, ask your Ramp administrator about Router access. See Connectors for company permissions.

You may also configure a specific agent by passing in its name, for instance ramp router configure opencode --connectors. Connector setup requires browser approval on every run, even when you supply an API key.

Note that the browser sign-in hands its result back to the CLI on the same machine. If you're setting up a remote machine, or one without a browser, use an API key as described in On a machine without a browser.

Check that it works

Run a short prompt in each agent you set up, for instance:

claude -p "Reply with one word: pong"
codex exec --skip-git-repo-check "Reply with one word: pong"

Codex normally runs only inside a Git repository, so --skip-git-repo-check lets this check run from any folder.

A reply means the agent reached a model through Router. You can also run ramp router configure list to see which agents are connected, and open Logs to see the requests. Restart any agent sessions that were already open so that they pick up Router.

Model-only setup

To set up any agent without connectors, including Hermes and Conductor, run the installer in Router mode:

curl -fsSL https://agents.ramp.com/install.sh | sh -s -- --router

It installs the Ramp CLI, opens your browser to sign in to Router, and then configures every agent it can. It doesn't ask you to choose; it sets up:

  • Claude Code, Codex, OpenCode, and Pi.
  • Hermes and Conductor, if they're installed.
  • Claude Desktop, if it's installed on your Mac. Claude Desktop restarts during setup.

It doesn't set up Cursor. To choose your agents yourself, run ramp router configure after the installer finishes, which shows the picker described above.

If the CLI is already installed, run ramp router configure without --connectors for model-only setup. You can also name agents directly, for instance ramp router configure codex hermes.

On a machine without a browser

On a remote machine, a container, or anywhere else the CLI can't open a browser, set up with an API key instead of signing in. This is also the path to use when a coding agent runs setup for you from a shell that has no screen.

  1. Create a key on the API keys page from any computer. Note that the secret is shown only once.

  2. Install the CLI by itself, then make the ramp command available in the shell you're using:

    curl -fsSL https://agents.ramp.com/install.sh | sh -s -- --no-skills
    export PATH="$HOME/.local/bin:$PATH"

    The installer adds ~/.local/bin to your PATH in your shell profile, but that only applies to shells you open afterwards. With the export line, you don't need to open a new shell, which can be awkward in a remote session or a coding agent's shell.

  3. Give setup the key in the RAMP_ROUTER_CONFIGURE_API_KEY environment variable and name the agents you want. The read -rs line waits for you to paste the key and press Enter, without showing it on screen:

    read -rs RAMP_ROUTER_CONFIGURE_API_KEY
    export RAMP_ROUTER_CONFIGURE_API_KEY
    ramp router configure claude-code codex
    unset RAMP_ROUTER_CONFIGURE_API_KEY

We recommend reading the key this way instead of passing --api-key or typing the key into an export line. Your shell saves the commands you type in its history, and with read -rs the key never appears in a command. Naming the agents matters as well: without names and without a terminal to show the picker, setup configures Claude Code, Codex, OpenCode, and Pi whether or not they're installed.

Because there's no terminal to ask in, setup doesn't offer the choice of which models to show. The first time you set up Claude Code and Codex this way, they show the recommended models. When you run setup again, each keeps the choice it already has, so if you chose All available models in an earlier setup, it stays that way. To go back to the recommended models, run setup again for each agent on its own:

ramp router configure claude-code --claude-models compact
ramp router configure codex --codex-models compact

Note that --claude-models and --codex-models work only when you name that one agent.

Setup saves the key in each agent's own configuration files, so treat those files as you would the key.

Note that if the variable is empty, setup falls back to signing in through the browser and waits for it, so check that the key is set if setup appears to hang. This path sets up models only, because connectors always need browser approval on the same machine.

Installer options

The installer puts the ramp command in ~/.local/bin and adds that folder to your PATH in your shell profile. It accepts these options after sh -s --:

Option
What it does
--router
Configures your coding agents with Router right after installing.
--api-key 'your-router-key'
Uses this Router key instead of signing in through the browser. Requires --router. Note that your shell saves a key you type in a command to its history. To keep it out, set the RAMP_ROUTER_CONFIGURE_API_KEY environment variable with read -rs instead, as shown in On a machine without a browser. The installer reads that variable when you pass --router.
--connectors
Sets up connectors along with models. Requires --router.
--no-skills
Skips installing Ramp's agent skills. --router skips them too, but Router setup still adds its own skills.
--no-modify-path
Leaves your shell profile alone, so you add ~/.local/bin to your PATH yourself.

Disconnect your agents

To restore agents to their original model configuration, run:

ramp router configure disconnect

Then select the agents you want to remove Router from, using the same keys as the setup picker. To skip the picker, name them, for instance ramp router configure disconnect codex.

For Claude Desktop, run ramp router configure disconnect desktop, which restores the setup Claude Desktop had before, such as your Claude.ai account. Note that disconnecting Claude Code also disconnects Claude Desktop if it's set up, and restarts it.

Cursor

ramp router configure cursor sets Cursor up for you on a Mac. Cursor must be closed while setup changes its settings, so the CLI offers to quit Cursor and reopens it afterwards. It also creates the ramp- aliases Cursor needs to reach Claude models. On Windows and Linux, the CLI copies your Router key to the clipboard and prints the steps to finish in Cursor's settings. See Set up Cursor with Router for details.

Note that ramp router refresh doesn't update Cursor. Run ramp router configure cursor again to pick up new models.

Installing without running a script from the internet

If you'd rather not pipe a script into your shell, you have a few options:

  • Download the installer, read it, and then run it:

    curl -fsSL https://agents.ramp.com/install.sh -o install.sh
    less install.sh
    sh install.sh --no-skills

    Open a new terminal if the installer updates your PATH, then run:

    ramp router configure --connectors
  • Install the Ramp CLI with Homebrew, then configure models and connectors:

    brew install ramp-public/ramp/ramp-cli
    ramp router configure --connectors
  • Run the Ramp CLI from npm, which needs Node.js:

    npx @ramp/router@latest configure
  • Skip the CLI entirely and set up your agent by hand. Each guide shows exactly which files to edit and what to put in them, so you can see every change before you make it.

What extensions we add to your coding agent

Alongside adding the models that Router supports to your coding agent, Router also adds status information that shows which models served your session, whether Switchyard routing is enabled, and how much you saved by using Router.

This is currently supported for Claude Code, Codex, Pi, and OpenCode. To hide it, run ramp router harness-widget disable, and run ramp router harness-widget enable to bring it back. Pi and OpenCode follow the change on their next turn, and Claude Code and Codex in new sessions.

For Claude Code, we install a Claude Code status line that shows which models served your session, how many requests each handled, the direct cost, and how much you saved by using Router:

Switchyard enabled · Claude Opus 5.5 ×12, Claude Sonnet 5.5 ×30
██████████░░░░░░░░░░░░░░ $4.09 vs $10.02 direct · 59% saved

The full bar reflects the full price of the session, and the filled part reflects how much you paid using Router. When the two prices match, the bar is hidden and the status line shows a single session total.

For Codex, we add a hook that shows the same session summary in the conversation after each turn. Most turns show a compact line such as Session $4.09 (59% saved).

On macOS and Linux, the Claude Code status line and the Codex hook currently need python3 on your PATH.

Setup also adds two agent skills:

  • ramp-add-router, for Claude Code, Codex, OpenCode, Pi, and Antigravity, which lets your agent move one of your apps onto Router.
  • ramp-prefer-ramp-connectors, which tells your agent to use Router connectors when they're available.

Note that both are added even when you install with --no-skills, which skips only Ramp's other skills. To leave out ramp-add-router, run ramp router configure --no-skills.

None of these additions are required. If setup can't add one, it carries on, and your agents still run through Router. Run ramp router refresh to try again.

For Pi and OpenCode, we include a status line that shows what model served your last prompt, along with any savings from Router:

Switchyard enabled
Routed to: gpt-6.1-sol via openai  -50% vs Gpt 6.1 Sol
Ramp        █████████████░░░░░░░░░░░ $0.35
Gpt 6.1 Sol ████████████████████████ $0.71

The full bar is the direct price, and the filled part is the Router price. When Switchyard routing is enabled, the first line says so, and the empty part of the bar is what routing saved against your selected model. When the two prices match, the bar is hidden and the status line shows a single session total.

Model updates

Router's model catalog is regularly updated as new models are released. Most changes will be picked up by your coding agent, but support varies from agent to agent:

Coding agent
Model catalog updates
Claude Code / Desktop
Automatically discovered
OpenCode
Updated dynamically by Router plugin
Pi
Updated dynamically by Router extension, requires support for the model in your Pi version
Hermes
Automatically discovered
Codex / Conductor
Updated in the background as sessions start; run ramp router refresh to update right away
Antigravity
Run ramp router refresh
Cursor
Run ramp router configure cursor

Manual setup

Every agent below can be set up by editing its configuration yourself, with nothing to install. Each guide lists the exact settings, explains what they do, and shows how to undo them.

Note that manual setup does not include all the functionality that the Ramp CLI offers. See the guides for each agent for more details.

Any other agent

For an agent that isn't listed, you can configure Router within it manually using the following details:

  • The base URL for Router is https://api.router.com/v1.
  • You will need to create an API key on the API keys page.
  • Prefer the OpenAI Responses API; it supports Router's fallback lists and Router-only fields. If your agent only speaks the legacy OpenAI Chat Completions API, Router also serves POST /v1/chat/completions on the same models, with the limits described in Responses and Messages.
  • If your agent supports model auto-discovery, Router provides an OpenAI-compatible listing API at https://api.router.com/v1/models.
  • You will need to configure all the models you want to use with Router in your agent manually. Refer to Supported models for a list of supported models.

Limitations

Claude.ai Connectors are not supported with Router because they require an Anthropic subscription. Use Router connectors for supported apps, or configure an equivalent MCP server directly in your coding agent.

When Claude Desktop runs through Router, it doesn't use your Claude.ai account, so that account's chat history, projects, and connectors aren't available there.