Setup wizard

Connect your AI tool.

Pick a tool, your operating system and a model. The steps and snippets below update to match.

1Tool
2Operating system
3Instructions

Connect Claude Code CLI

Claude Code reads the base URL, key and model from its settings file, so it works without an Anthropic login.

  1. Install Claude Code, then open a new terminal window.
    Terminal
    curl -fsSL https://claude.ai/install.sh | bash
  2. Create the file ~/.claude/settings.json with this content. If the file already exists, add the env block to it. Note that the base URL has no /v1 at the end.
    settings.json
    {
      "env": {
        "ANTHROPIC_BASE_URL": "https://cheaptokens.pw",
        "ANTHROPIC_AUTH_TOKEN": "YOUR_API_KEY",
        "ANTHROPIC_MODEL": "claude-sonnet-5-5",
        "ANTHROPIC_DEFAULT_HAIKU_MODEL": "claude-haiku-5-5"
      }
    }
  3. Go to your project folder and start Claude Code. It skips the Anthropic login because the key is already set.
    Terminal
    claude
  4. Type /status. It should show https://cheaptokens.pw as the Anthropic base URL. Then send a message.
  5. Using the Claude Code extension for VS Code instead? Install it (code --install-extension anthropic.claude-code), open the Command Palette, run Preferences: Open User Settings (JSON) and add this inside the outer braces:
    VS Code settings.json
    "claudeCode.environmentVariables": [
      { "name": "ANTHROPIC_BASE_URL", "value": "https://cheaptokens.pw" },
      { "name": "ANTHROPIC_AUTH_TOKEN", "value": "YOUR_API_KEY" },
      { "name": "ANTHROPIC_MODEL", "value": "claude-sonnet-5-5" }
    ]
  • Already signed in to Claude Code with an Anthropic account? Type /logout once so the two logins don't clash.
  • Switch model at any time with /model claude-sonnet-5-5, or start with claude --model claude-sonnet-5-5.
  • ANTHROPIC_DEFAULT_HAIKU_MODEL is the small model Claude Code uses for background jobs such as naming sessions.
  • For one terminal session only, you can set ANTHROPIC_BASE_URL and ANTHROPIC_AUTH_TOKEN as environment variables instead of editing the file.
  • Don't put your key in a project's own .claude/settings.json. That file is usually committed to git.

Open the full Claude Code CLI guide →