Skip to content

CC-Switch

CC-Switch is a graphical tool for managing AI interface configuration. It can manage provider settings and API keys for multiple Agent clients in one place, including mainstream AI coding assistants such as Claude Code, Codex, and OpenCode, reducing the risk of configuration mistakes.

Common use cases include:

  • Managing provider settings and API keys for multiple Agent clients, such as Claude Code, Codex, and OpenCode.
  • Quickly switching between AI model interfaces without manually editing environment variables or local config files.
  • Reducing repeated setup work and improving maintainability across multiple clients.

This guide focuses on installation. For detailed client configuration, see the related client pages.

Installation

Follow the steps for your operating system.

  1. Open the latest release page. Find the Windows installer on the page. The .msi package is recommended, as shown below:

    How to choose the Windows installer on the Releases page
  2. After the download finishes, double-click the installer.

  3. Follow the installer wizard to complete installation.

  4. After installation, find and launch CC-Switch from the Start menu.

How to Start After Installation

  1. Follow Create API Key to get a new API key.

  2. Open CC-Switch, click the Add button in the upper-right corner, and choose to add a unified provider.

  3. Fill in the following fields accurately in the configuration window:

    text
    Provider name: tokenflux
    API URL: https://tokenflux.dev
    API Key: your TokenFlux API key

    Example interface:

    CC-Switch unified provider fields
  4. Save the configuration. CC-Switch will enable this provider for all related Agent clients.

DOYO Claude Channel Environment Variables

WARNING

The DOYO Claude channel temporarily cannot be used in the Claude app. It only works with the Claude Code CLI.

If you manage Claude Code through CC-Switch, you can add ENABLE_PROMPT_CACHING_1H to the Claude provider's JSON configuration. When you enable the provider, CC-Switch writes this configuration into Claude Code's settings.json.

This variable enables a 1-hour prompt cache, which is useful for Claude Code sessions that repeatedly carry long context. It only applies to DOYO's Claude channel; other Claude channels do not need it.

App-Specific Provider

  1. Switch to Claude Code at the top of CC-Switch.
  2. Find the Claude provider card for TokenFlux and click "Edit".
  3. Add the following to env in the "Config JSON":
json
{
  "env": {
    "ENABLE_PROMPT_CACHING_1H": "1"
  }
}

Unified Provider

The unified provider's basic form only contains Name, API Key, API URL, and model configuration, without a separate DOYO environment variable field. When using a unified provider:

  1. First create and sync the unified provider with the flow above.
  2. Return to the Claude Code app and edit the synced Claude provider.
  3. Add "ENABLE_PROMPT_CACHING_1H": "1" to the provider's JSON env.
  4. Save and enable the Claude provider.

Next Steps

After installing and configuring CC-Switch, restart your client and start using it.

More guides: