CC Switch
Installing CC Switch, and the steps for importing your CodaAPI key from the console, adding it by hand and switching providers (based on CC Switch's official docs, not yet tested).
CC Switch is an open-source desktop app that manages the model providers of coding tools such as Claude Code, Codex, Gemini CLI, OpenCode and OpenClaw. It saves an address, key and model as a "provider" that you can switch to with one click, so you don't have to edit each tool's configuration files by hand.
The API Keys page in the CodaAPI console can import a key straight into CC Switch. It's the easiest way to connect Claude Code or Codex to CodaAPI.
Not tested: this page follows the official CC Switch repository (v4.0.35, November 2026) and the console's source code, and hasn't been tested item by item on CodaAPI. CC Switch changes quickly, so the labels in your installed version are authoritative.
Install
Download it from the Releases page of the official repository; the official website is ccswitch.io. Only use these two sources.
| System | How to install |
|---|---|
| Windows 10 or later | Download the .msi installer or the portable .zip |
| macOS 12 or later | brew install --cask cc-switch, or download the .dmg |
| Linux | Download the .deb, .rpm or .AppImage |
Install the latest version. Importing a provider from a web page needs a fairly recent release; the official docs are written for 4.0.10 and later.
Import from the console in one click
-
In the console, open General → API Keys (open it directly), open the menu on the row of the key you want to use, and choose CC Switch. No key yet? Create one first.
-
Fill in the Import to CC Switch dialog:
Field What to enter Application Claude (for Claude Code), Codex, or Gemini (for Gemini CLI). Each import covers one application; import again for each one you use Name The name shown in CC Switch. Defaults to My Claude, My Codex or My Gemini; you can change it to CodaAPI Primary Model Required. The list combines the models of every group your account can use and isn't filtered by this key's group or Model Limits, so choose a model from the key's own group. You can also type a model name Haiku Model, Sonnet Model, Opus Model Only shown for Claude, and optional. They set which model Claude Code's haiku,sonnetandopusaliases use -
Click Open CC Switch. When the browser asks whether to open CC Switch, allow it.
-
CC Switch shows an import confirmation with the address, the masked key and the models. Check them and confirm. The dialog also has a toggle for switching to this provider right after the import; it's on by default for imports from the console. If you turn it off, select the provider in CC Switch later and click Enable.
What gets imported into CC Switch:
| Application | Address | Models |
|---|---|---|
| Claude | https://codaapi.com (no /v1) |
The primary model, plus any Haiku, Sonnet and Opus models you set |
| Codex | https://codaapi.com/v1 (with /v1) |
The primary model |
| Gemini | https://codaapi.com |
The primary model |
The key and model names are imported exactly as you chose them in the dialog. When you pick models, keep in mind that Claude Code supports only Claude models, and Codex needs a model that can be called through the Responses API; see the Claude Code and Codex pages.
Add a provider by hand in CC Switch
If importing from the console isn't convenient (for example, CC Switch runs on another computer), add the provider in CC Switch yourself:
- In CC Switch, select the tool to configure in the left sidebar, for example Claude Code or Codex.
- Click + (add provider) at the top right and choose to create a custom configuration.
- Fill in the address from the table above, the
sk-…key you get from Copy Key in the console, and the model names. - Save, then click Enable.
Tools such as OpenCode and OpenClaw use a "coexist" mode in CC Switch: a new provider is added alongside the others instead of replacing them, so you click Add rather than Enable. They use the OpenAI-compatible format, so set the address to https://codaapi.com/v1. The console's one-click import currently supports only Claude, Codex and Gemini, so add these tools by hand, or edit their own configuration files as described in More tools.
Switching and when it takes effect
- Switching changes only the connection details: when CC Switch switches providers it replaces only the address, key and model. The tool's own plugins, MCP servers and other settings stay as they are. Before it first rewrites a tool's configuration file, it backs up the original under
~/.cc-switch/backups/. - When it takes effect: Claude Code doesn't need a restart after a switch. For Codex and Gemini CLI, open a new terminal or restart the CLI.
- Check that it worked: in Claude Code or Codex, type
/statusand confirm that the current address or provider is CodaAPI, then send a message. The request shows up in the console's Usage Logs.
Balance display
CC Switch can show a balance on a provider card, but that needs a usage-query script. Providers imported from the console don't include one, so the card shows no balance. Check your balance and usage in the console's Wallet and Usage Logs.
Security
- During an import, the key is handed to CC Switch through a local
ccswitch://link; no third-party website is involved. CC Switch stores providers locally in the~/.cc-switch/folder. - An import link that contains a key is as good as the key itself. Don't share it, and don't import links from unknown sources.
- On a shared computer, delete the provider in CC Switch when you're done, and disable or delete keys you no longer use in the console.
Common problems
Nothing happens when I click Open CC Switch
If CC Switch isn't installed, is too old, or the browser blocked the external app, there's usually no message at all. Make sure CC Switch is installed and up to date, then try again, and allow the browser's prompt to open CC Switch.
The model I want isn't in the list
The list combines the models of every group your account can use and isn't filtered by this key's group or Model Limits, so a model in the list isn't necessarily usable with this key. Choose a model from the key's own group (see Groups for each group's models); if the key has Model Limits, the model must also be on that list. You can also type the model name; see Model Square for exact names.
The tool still uses the old settings after switching
Codex and Gemini CLI need a new terminal. For Claude Code, check whether ANTHROPIC_BASE_URL or related variables are also set in the project's .claude/settings.json; it can override what CC Switch wrote.
What if I replace my key?
Import the new key from the console again, or edit the provider in CC Switch and replace the key.