Skip to content

darkokoa/clother

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

35 Commits
 
 
 
 
 
 
 
 

Repository files navigation

  ____ _       _   _
 / ___| | ___ | |_| |__   ___ _ __
| |   | |/ _ \| __| '_ \ / _ \ '__|
| |___| | (_) | |_| | | |  __/ |
 \____|_|\___/ \__|_| |_|\___|_|

English | 中文

One CLI to switch between Claude Code providers instantly.

License: MIT Shell Platform

🔒 Secure • 🚀 Fast • 📦 Lightweight


Installation

# 1. Install Claude Code CLI
npm install -g @anthropic-ai/claude-code

# 2. Install Clother
curl -fsSL https://raw.githubusercontent.com/darkokoa/clother/main/clother.sh | bash

# 3. Add to PATH (if prompted)
echo 'export PATH="$HOME/bin:$PATH"' >> ~/.zshrc && source ~/.zshrc

Quick Start

Got 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-zai-cn              # Launch with Z.AI China (Zhipu/GLM)
clother-minimax             # Launch with MiniMax
clother-minimax-cn          # Launch with MiniMax China

Providers

Native Anthropic (Your Subscription)

clother-native              # Claude Sonnet/Opus/Haiku
                           # Uses your Claude Pro/Team subscription
                           # No API key needed

Alternative Models

Command Provider Models Get API Key
clother-zai Z.AI GLM-4.5-air, GLM-4.6 z.ai
clother-zai-cn Z.AI (China) GLM-4.5-air, GLM-4.6 bigmodel.cn
clother-minimax MiniMax MiniMax-M2 minimax.io
clother-minimax-cn MiniMax (China) MiniMax-M2 minimaxi.com
clother-kimi Moonshot AI Kimi-K2 variants moonshot.ai
clother-katcoder KAT-Coder KAT-Coder streamlake.ai
clother-ve VolcEngine (China) Doubao Seed Code console.volcengine.com

Custom Providers

Add your own Anthropic-compatible endpoint:

clother config              # Choose "custom"
clother-myprovider          # Ready to use!

Commands

clother config              # Set up a provider
clother list                # Show configured providers
clother info <name>         # Show provider details
clother uninstall           # Remove everything

Examples

# Pass any Claude Code options
clother-zai --dangerously-skip-permissions

# Check what's configured
clother list
clother info zai

How It Works

Clother creates tiny 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 "$@"

No proxy, no overhead, just environment variables. API keys stored securely in ~/.clother/secrets.env (chmod 600).


FAQ

Can I use multiple providers at once?
Open multiple terminals — each can use a different provider.

Where are my API keys stored?
In ~/.clother/secrets.env with chmod 600 (only you can read it).

What providers work with Clother?
Any provider with an Anthropic-compatible API. For non-compatible providers (OpenRouter, LiteLLM), use claude-code-router instead.

Does this modify my Claude installation?
No. It only sets environment variables before launching claude.


Troubleshooting

Problem Solution
claude: command not found npm install -g @anthropic-ai/claude-code
clother: command not found Add ~/bin to PATH (see installation)
API key not set Run clother config

Platform Support

✅ macOS (zsh/bash) • ✅ Linux (zsh/bash) • ✅ Windows (WSL)


License

MIT © jolehuit

About

Configure and launch multiple Claude Code–compatible LLM providers from one CLI, switching profiles instantly with simple clother-* commands.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Languages

  • Shell 100.0%