Skip to content

Codex CLI: CC-Switch Quick Configuration

Codex CLI is best configured through CC-Switch. CC-Switch writes the required Codex configuration and authentication data automatically, so Codex can use HCAI after the configuration is enabled.

Access Information

ItemValue
Website URLhttps://ai.hctopup.com
API request URLhttps://ai.hctopup.com/v1
API KeyUse the Key created in HCAI
Provider nameHCAI is recommended

Configuration Steps

  1. Open the Codex configuration page.

    • Open CC-Switch.
    • Click the Codex icon tab at the top.
    • Click the "+" button in the upper-right corner to add a provider.

    CC-Switch Codex main page

  2. Choose custom configuration.

    On the add-provider page, select "Custom Configuration".

    CC-Switch Codex custom configuration

  3. Fill in the provider basics.

    • Provider name: choose a custom name, such as HCAI.
    • Website URL: enter https://ai.hctopup.com.
    • API Key: enter the Key created in the HCAI console.
    • API request URL: enter https://ai.hctopup.com/v1.

    CC-Switch Codex provider details

    You can copy the API request URL and Key after creating the API in the HCAI console.

    Copy API endpoint and Key from HCAI

  4. Save the configuration.

    CC-Switch Codex save configuration

  5. Return to the main page and enable the configuration.

    Back in the Codex provider list, confirm that the HCAI configuration is marked as active. After it is enabled, CC-Switch writes the Codex configuration and login data automatically.

    CC-Switch Codex enable HCAI configuration

Then reopen Codex CLI:

sh
codex

Next Steps