A SwiftBar plugin that displays Codex and Antigravity quota usage from your CLIProxyAPI instance in the macOS menu bar.
brew install swiftbarSymlink or copy the script to your SwiftBar plugins directory:
git clone https://github.com/LoveEatCandy/CLIProxyAPI-quota-bar.git
cp CLIProxyAPI-quota-bar/quota.5m.py path/to/SwiftBar/quota.5m.pyThe 5m in the filename means SwiftBar refreshes every 5 minutes.
Write .env file in the same directory(path/to/SwiftBar/.env):
CPA_BASE_URL="https://xxx" # Your CLIProxyAPI server
CPA_MANAGEMENT_KEY="your-management-key" # Management API key
Status Bar:
🤖C:100% 🌀A:100%
🤖C:100%— 100% Codex quota available🌀A:100%— 100% Antigravity quota available
Dropdown Menu:
- Per-provider account list with quota details
- Status indicators: 🟢 ready / 🔴 rate-limited / 🟡 warning / ⚫ disabled
- Quick links to refresh and open Management Center
- Change refresh interval by renaming the file (e.g.,
quota.1m.pyfor 1 minute) - Modify
TARGET_PROVIDERSin the script to track other providers