AnyInt Docs
Agent Setup

Configure With CC-Switch

Use CC-Switch to manage AnyInt provider settings for Claude Code, Codex, and Gemini CLI.

CC-Switch is useful when you want a UI for switching providers, checking the local environment, or moving between several agent configurations. If you only need one tool, start with its direct setup guide to reduce the number of moving parts.

Third-party tool

CC-Switch is not operated by AnyInt. Its UI fields and commands can change between releases. AnyInt documents only the public endpoint, authentication, model, and protocol values; follow the UI of your installed CC-Switch version for the exact workflow.

Before you start

Prepare the following:

  1. Install Claude Code, Codex, or Gemini CLI.
  2. Run the target CLI or its help command once so it creates a local config directory.
  3. Create an AnyInt API key.
  4. Confirm that key can access the model you intend to use.
claude --help
codex --help
gemini --help

Use the same key to fetch available model IDs:

export ANYINT_API_KEY="your-anyint-api-key"

curl https://api.anyint.ai/openai/v1/models \
  -H "Authorization: Bearer $ANYINT_API_KEY"

For Claude Code, you can also fetch the Anthropic-compatible model list:

curl https://api.anyint.ai/anthropic/v1/models \
  -H "x-api-key: $ANYINT_API_KEY" \
  -H "anthropic-version: 2023-06-01"

Copy a model ID visible to the current key. Never put a real API key in a repository, screenshot, public document, or shared configuration.

AnyInt provider values

Target toolProvider typeBase URLKey fieldModel IDProtocol status
Claude CodeAnthropic-compatiblehttps://api.anyint.ai/anthropicANTHROPIC_AUTH_TOKEN<ANTHROPIC_MODEL_ID>Stable
CodexOpenAI Responseshttps://api.anyint.ai/openai/v1ANYINT_API_KEY<MODEL_ID>Beta
Gemini CLIGemini-compatiblehttps://api.anyint.ai/gemini/v1betaGEMINI_API_KEY<GEMINI_MODEL_ID>Stable

When the UI provides a Wire API field, Codex must use responses. Model IDs must come from the model list visible to the current AnyInt key.

Use CC-Switch Desktop

  1. Open CC-Switch.
  2. Select Claude, Codex, or Gemini from the tool groups.
  3. Open provider management and add a custom provider.
  4. Set the provider name to AnyInt.
  5. Enter the Base URL, API key, model ID, and Wire API from the table above.
  6. Save and enable the provider.
  7. Open a new terminal, run the target CLI, and send a minimal prompt.

Use the CC-Switch CLI or TUI

On a server, over SSH, or in a terminal-only environment, open the TUI:

cc-switch

You can also open a specific tool directly:

cc-switch --app claude
cc-switch --app codex
cc-switch --app gemini

In the TUI, add a provider named AnyInt and enter the corresponding values from this page. After switching, inspect the available tools, providers, and environment:

cc-switch env tools
cc-switch env check
cc-switch provider list
cc-switch provider current

cc-switch --app codex provider list
cc-switch --app gemini provider current

Configure Claude Code

Select the Claude group in CC-Switch and enter:

FieldValue
Provider nameAnyInt
Base URLhttps://api.anyint.ai/anthropic
API keyYour AnyInt API key
Model<ANTHROPIC_MODEL_ID>

Save and enable the provider, then run:

claude

If Claude Code is still in its first-install or login confirmation flow, finish the CLI's own initialization before returning to CC-Switch and enabling the AnyInt provider.

Configure Codex

Select the Codex group in CC-Switch and enter:

FieldValue
Provider nameAnyInt
Base URLhttps://api.anyint.ai/openai/v1
Wire APIresponses
API keyYour AnyInt API key
Auth environment variableANYINT_API_KEY
Model<MODEL_ID>

Save and enable the provider, then run:

codex

The Base URL must stop at /openai/v1; do not append /responses or /chat/completions. AnyInt's OpenAI Responses API is currently Beta, so validate the model, streaming, and tool calls before adopting it in a stable workflow.

Configure Gemini CLI

Select the Gemini group in CC-Switch and enter:

FieldValue
Provider nameAnyInt
Base URLhttps://api.anyint.ai/gemini/v1beta
API keyYour AnyInt API key
Model<GEMINI_MODEL_ID>

Save and enable the provider, then run:

gemini

Gemini CLI usually reads the Base URL, API key, and model from .gemini/.env or an equivalent config written by CC-Switch. Do not use a local path as fileData.fileUri; use a public HTTPS URL or inline data for file input.

Verify the connection

Start the target agent and ask it to reply exactly AnyInt connected. Basic setup is complete when the selected AnyInt model returns a response without another provider login prompt and the configuration still works after reopening the terminal. For streaming and tool-calling checks, continue with Verify Your Integration.

Troubleshooting

The enabled provider still uses an old configuration

Environment variables in the current shell may override the files written by CC-Switch. Run cc-switch env check, then remove conflicting variables or reopen the terminal.

The model is unavailable

Call the Models API with the same API key and confirm the model ID is visible to that key. Personal keys, team keys, plans, and projects can expose different model lists.

Codex reports a Base URL or Responses error

Confirm the Base URL is https://api.anyint.ai/openai/v1, the Wire API is responses, and the Base URL does not contain a full endpoint path.

Claude Code asks you to log in to Anthropic

Confirm the AnyInt provider is enabled and that Claude Code's effective configuration contains ANTHROPIC_BASE_URL and ANTHROPIC_AUTH_TOKEN. On first use, finish Claude Code's own initialization first.

On this page