You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
ccswap guard runs a local proxy that stops paid extra usage. Point Claude Code at it with ANTHROPIC_BASE_URL=http://127.0.0.1:8318 and it forwards every request to Anthropic. Once an account is on paid overage, or past guard.blockThreshold (default 98%) while overage is allowed, it answers POST /v1/messages with a 429 until that window resets. Blocks are kept per account, so they survive a token refresh and a restart. guard serve runs it in the foreground, guard install / guard uninstall manage a launchd service on macOS, and guard status shows whether it's running and how many accounts are blocked. It only binds to loopback, refuses to start if ANTHROPIC_BASE_URL already points at another gateway, and honours HTTPS_PROXY / NO_PROXY. Settings: guard.port, guard.blockExtraUsage, guard.blockThreshold. Thanks @mvanhorn (#88).
Spend alerts. notify.command gets a spend-active event when an account starts spending extra usage and spend-increase each time its spend rises by notify.spendStepUsd (default 5, in the account's currency). Both are on by default for anyone with notify.command set, and the menu bar shows them as notifications. Baselines are saved, so ccswap auto --once fires them too and two engines never send the same one. Thanks @mvanhorn (#87).
Accounts with no monthly spend cap now show their spend as unlimited in list, the dashboard, the statusline and --json (spend.unlimited, with limit and pct null, see docs/json.md). autoswitch.creditFallback still never parks on an uncapped account unless you set autoswitch.creditFallbackAllowUnlimited (#87).
ccswap list ends each Claude account with a use row (now, after 14:30, blocked until …) for the rule "use the account whose weekly limit resets soonest, with room in both windows". --json adds usePlan. The dashboard and the menu bar show it too (#84, #85).
ccswap list shows why extra usage is off ($$ off (out of credits)), which limit is binding, per-model weekly shares and early resets (#82).
ccswap relogin NUM renews a saved Claude login in a throwaway profile without switching to it (#77).
Banked resets for Claude accounts, behind usage.resetGrants (off by default) (#76).
New auto-switch settings: autoswitch.codexThreshold (a Codex weekly gate apart from Claude's), autoswitch.weeklyCaps (e.g. 3=60 treats slot 3 as full at 60% of its week) and autoswitch.creditFallback (park on one account's extra-usage credits once every account is spent) (#79).
Only one live auto-switch engine runs per provider. A second menu bar, dashboard or ccswap auto stops with a message naming the one already running (#78).
Statusline: the session's account, Claude Code's context %, pace and a width setting (#75).
Fixes
Updating from the macOS menu bar no longer drops the GUI libraries and leaves the menu unable to start. Thanks @samuelclay (#83).
Antigravity usage fetches no longer leave ccswap-agy-* temp dirs behind. Old orphans are cleaned up after two minutes, only when nothing protects them. Thanks @mvanhorn (#86).
Codex usage, banked-reset and warm-up requests only go over HTTPS to chatgpt.com or chat.openai.com and never follow a redirect. Plus fixes for login expiry, the agy fallback file, the exhausted reset time and roster refresh (#74).
The spend row no longer disappears when the API reports utilization: null (#79).