Claude Code CLI
Point the Claude Code CLI at our gateway and it runs on your Apigator credits — streaming, same workflow, billed as API Usage Billing (not your personal subscription).
403, ask MixerBox to allowlist you.A script writes ~/.claude/settings.json for you (backs up + merges your existing settings). Paste your key when prompted:
curl -fsSL https://apigator.ai/setup-claude-cli.sh | bash Then claude /logout (once, if you have a personal login) → claude. Done. Prefer to read it first? View the script.
Want to switch back to your personal Claude subscription later? curl -fsSL https://apigator.ai/setup-claude-cli.sh | bash -s revert then claude /login.
settings.jsonexport only lasts one terminal session. For a permanent default, put it in Claude Code's settings — applied on every launch.
If you have a personal Claude login, log out once so it never falls back to your subscription:
claude /logout Create ~/.claude/settings.json:
{
"env": {
"ANTHROPIC_BASE_URL": "https://claude.apigator.ai",
"ANTHROPIC_API_KEY": "sk-your-apigator-key",
"ANTHROPIC_MODEL": "claude-opus-4-8",
"ANTHROPIC_SMALL_FAST_MODEL": "claude-haiku-4-5"
}
} Then just run claude. No export, no --bare, nothing to re-set. (Don't commit a settings file with your key.)
--bare?No — it's optional. It only forces strict ANTHROPIC_API_KEY auth and skips the confirm prompt.
| Situation | What to do | --bare |
|---|---|---|
| Apigator as default, no prompts | claude /logout once + settings.json | not needed |
| Keep personal login, use Apigator now | set env, run claude, answer Yes | not needed |
| Force Apigator every run, skip prompt | add --bare | required |
claude-opus-4-8 | Claude Opus 4.8 (pinned) |
claude-sonnet-4-6 | Claude Sonnet 4.6 (pinned) |
claude-haiku-4-5 | Claude Haiku 4.5 (pinned) |
opus / sonnet / haiku | latest in that family |
claude -p "Reply with exactly: apigator ok" Using an AI agent? Hand it the raw setup file to self-configure: /claude-cli.md — plain markdown, meant for an agent to read (not a styled page).