____ _ _ _
/ ___| | ___ | |_| |__ ___ _ __
| | | |/ _ \| __| '_ \ / _ \ '__|
| |___| | (_) | |_| | | | __/ |
\____|_|\___/ \__|_| |_|\___|_|
One CLI to switch between Claude Code providers instantly.
🔒 Secure • 🚀 Fast • 📦 XDG Compliant
Requirements: Claude Code CLI
# 1. Install Claude Code CLI
curl -fsSL https://claude.ai/install.sh | bash
# 2. Install Clother
curl -fsSL https://raw.githubusercontent.com/jolehuit/clother/main/clother.sh | bashGot a Claude Pro/Team subscription?
clother-native # Use your subscription, no setup needed!Want to use alternative models?
clother config # Set up Z.AI, MiniMax, Kimi, etc.
clother-zai # Launch with Z.AI (GLM)
clother-minimax # Launch with MiniMaxWant 100+ models via OpenRouter?
clother config openrouter # Set up OpenRouter
clother-or-devstral # Launch with Devstralclother-native # Claude Sonnet/Opus/Haiku
# Uses your Claude Pro/Team subscription
# No API key needed| Command | Provider | Models | Get API Key |
|---|---|---|---|
clother-zai |
Z.AI | GLM-4.5-air, GLM-4.7 | z.ai |
clother-minimax |
MiniMax | MiniMax-M2 | minimax.io |
clother-kimi |
Kimi | kimi-k2-thinking-turbo | kimi.com |
clother-moonshot |
Moonshot AI | kimi-k2-turbo-preview | moonshot.ai |
clother-deepseek |
DeepSeek | deepseek-chat | deepseek.com |
clother-mimo |
Xiaomi MiMo | mimo-v2-flash | xiaomimimo.com |
| Command | Provider | Endpoint |
|---|---|---|
clother-zai-cn |
Z.AI (China) | open.bigmodel.cn |
clother-minimax-cn |
MiniMax (China) | api.minimaxi.com |
clother-ve |
VolcEngine | ark.cn-beijing.volces.com |
| Command | Provider | Description |
|---|---|---|
clother-or-* |
OpenRouter | 100+ models via native API |
clother-<custom> |
Custom | Any Anthropic-compatible endpoint |
Access Grok, Gemini, Mistral and more through OpenRouter's native Anthropic API.
clother config openrouter # Enter API key from https://openrouter.ai/keys
# Add models interactively:
Model ID: moonshotai/kimi-k2-0905:exacto
Short name: kimi-k2 # Creates: clother-or-kimi-k2
clother-or-kimi-k2 # Use it!Important: For non-Claude models, use the
:exactovariant (e.g.moonshotai/kimi-k2-0905:exacto). Exacto handles Claude Code's message format better and provides reliable tool use support. See OpenRouter Exacto docs for details.
Add any Anthropic-compatible endpoint:
clother config # Choose "custom"
clother-myprovider # Ready to use!| Command | Description |
|---|---|
clother config [provider] |
Configure provider (interactive menu if no args) |
clother list [--json] |
List configured profiles |
clother info <name> |
Show provider details |
clother test [provider] |
Test connectivity |
clother status |
Show installation status |
clother uninstall |
Remove everything |
| Flag | Description |
|---|---|
-v, --verbose |
Verbose output |
-q, --quiet |
Minimal output |
-y, --yes |
Auto-confirm prompts |
--json |
JSON output |
--no-color |
Disable colors |
# Pass any Claude Code options
clother-zai --dangerously-skip-permissions
# Check what's configured
clother list
clother info zai
# Machine-readable output
clother list --json | jq '.profiles[].name'Clother creates lightweight launcher scripts that set environment variables:
# When you run: clother-zai
# It does:
export ANTHROPIC_BASE_URL="https://api.z.ai/api/anthropic"
export ANTHROPIC_AUTH_TOKEN="$ZAI_API_KEY"
exec claude "$@"API keys stored securely in ~/.local/share/clother/secrets.env (chmod 600).
Follows XDG Base Directory Specification:
~/.config/clother/ # Configuration
~/.local/share/clother/ # Data (secrets)
~/bin/clother-* # Launcher scripts
| Problem | Solution |
|---|---|
claude: command not found |
Install Claude CLI first |
clother: command not found |
Add ~/bin to PATH |
API key not set |
Run clother config |
✅ macOS (zsh/bash) • ✅ Linux (zsh/bash) • ✅ Windows (WSL)
Requirements: Bash 4.0+, Claude Code CLI
Thanks to everyone who helped improve Clother:
PRs welcome! 🙏
MIT © jolehuit