bro-claude
v0.4.1
Published
Run Claude Code against any model provider — Claude native, or any OpenAI/Anthropic-compatible API via an auto-installed proxy. Pick a provider, pick a model, go.
Maintainers
Readme
bro
Run Claude Code against any model — Claude natively, or any OpenAI/Anthropic-compatible API through a proxy that installs itself.
Pick a provider, pick a model, go.
Install
npm install -g bro-claude
# or: bun install -g bro-claudeYou also need the claude CLI installed (that's the thing bro launches).
Use
bro- Scroll to a provider and press enter.
- Scroll to a model and press enter. Press Tab to flip the Skip permissions toggle (
--dangerously-skip-permissions) on/off right there. - First time on a paid provider it asks for an API key and saves it.
Your last provider + model are remembered and pre-selected next time (per provider).
Multiple Claude Account Proxy
The top option in the menu (bro -p pool) pools any number of Claude Max / Team logins behind one local endpoint and launches Claude Code across all of them — so a single session draws from several plans and fails over automatically the moment one runs out of usage.
Pick it and bro handles everything:
- Setup — if you have no pooled accounts yet, it offers to log in a new one (opens Claude to sign in) or import the login already on this machine. Add as many as you like; each is stored in its own isolated config dir under
~/.claude-max-pool/. - Start the proxy — launches the pool server (in
pool/, runs on Bun) in the background and waits for it to go healthy. A live dashboard shows each account's auth state, plan, rate tier, and rolling usage athttp://127.0.0.1:3456/. - Launch Claude — starts Claude Code pointed at the pool (
ANTHROPIC_BASE_URL). The pool forwards Claude's Anthropic/v1/messagescalls directly to Anthropic with the least-loaded account's OAuth token by default, without nesting anotherclaude --printsubprocess. When Claude exits, the proxy is stopped.
Manage pool accounts directly through bro:
bro accounts login work # add/log in a new pooled Claude account
bro accounts import primary # copy this machine's current Claude login
bro accounts list # show account status and usage
bro accounts remove work # delete a pooled accountFailover: when the serving account's usage/rate limit runs out before any output has streamed, the pool transparently sidelines it and retries the turn on the next account — you just keep going. Set CLAUDE_POOL_BACKEND=cli to use the older subprocess backend. Requires Bun (bro finds it automatically; install from bun.sh). See pool/README.md for the pool's own docs, endpoints, and configuration.
🎨 Image Gen
bro image (also the second option in the menu) doesn't launch Claude at all — it asks which image API to use (Yunwu with gpt-image-2 first, plus OpenAI), then serves a local web UI and opens it in your browser.
- Prompt fast — type, press Enter, keep typing. Every generation is a card that shimmers while it works and fades the image in when it lands.
- Concurrent by design — the batch stepper fires N generations at once, and you can keep firing more while others are still running.
- Switch models in the UI — pick from the API's list (including chat-routed models like
gemini-3.1-flash-image) or type any custom model id. Size and quality knobs included where the API supports them. - Reference images — paste, drag-drop, or attach images to the prompt as context. They're saved to
./.bro/context/named by content hash (the same image is never stored twice) and appear in a library strip for one-click reuse. Image-API models route through/images/edits; chat-routed models get them as vision input. - Files land in
./.bro/image-gen/of the directory you launched from, with ahistory.jsonlso the gallery survives reloads.
bro image # pick an image API, then the web UI opens
bro image -p yunwu # skip the API menuKeys are shared with the chat provider of the same id, so a saved Yunwu key just works. Add your own APIs via imageApis in ~/.bro/config.json (merged by id, same as providers).
Providers
Claude is next in the list and runs natively (your normal Claude login — no proxy). Other Anthropic-compatible providers (OpenRouter, Z.ai) just point Claude at their endpoint. OpenAI-format providers (Sakana, OpenAI, DeepSeek, Groq, …) are routed through claude-code-router, which bro installs for you the first time you need it.
Flags
bro -p pool # Multiple Claude Account Proxy (pool many plans)
bro -p sakana -m fugu # skip the menus
bro --list # list every provider + model
bro update # refresh the model list from GitHub, cache it locally
bro --dry-run # show what would run, launch nothing
bro --safe # don't pass --dangerously-skip-permissions
bro --resume <session-id> # pick provider/model, then resume Claude there
bro -p pool --resume <id> # resume through the Multiple Claude Account Proxy
bro -- --help # force a bro flag name through to claudePut bro's own flags first. The first unrecognized argument, and everything
after it, is passed verbatim to the Claude session after provider/model
selection.
Config
Keys and your own providers/models live in ~/.bro/config.json:
{
"keys": {
"sakana": "fish_...",
"#openai": "sk-... ← any key starting with # is ignored (notes / test data)"
},
"providers": [
{
"id": "mylocal",
"name": "My Local LLM",
"mode": "openai",
"baseUrl": "http://localhost:1234/v1/chat/completions",
"noKey": true,
"models": [{ "id": "my-model", "name": "My Model" }]
}
]
}Custom providers merge with the built-in list (same id adds models; new id adds a provider). The built-in model list is pulled from models.json on GitHub and cached at ~/.bro/models.cache.json — run bro update to refresh it (override the source with BRO_MODELS_URL).
Made by JustGains · MIT
