{"slug": "open-source-claude-codex-cursor-limits-tracker-for-mac", "title": "Open-source Claude/Codex/Cursor limits tracker for Mac", "summary": "CreditWatcher, an open-source macOS menu bar app and CLI, now monitors Codex, Claude Code, and Cursor subscription usage limits locally with no telemetry. The tool reads credentials from official tools, caches data locally, and provides a rich terminal dashboard or native menu bar popover. It is designed for privacy-conscious developers who want to track their AI API usage without third-party servers.", "body_md": "A **macOS menu bar app** and **CLI** to monitor **Codex**, **Claude Code**, and **Cursor** subscription usage limits — locally, read-only, with no telemetry.\n\nInspired by the design spirit of [Stats](https://github.com/exelban/stats) (lightweight macOS menu bar utility).\n\n**Download CreditWatcher for macOS**\n\nPrebuilt installers are published through [GitHub Releases](https://github.com/aalksii/creditwatcher/releases).\n\n**Three providers**— Codex (OpenAI), Claude Code (Anthropic), Cursor in one place** macOS menu bar app**— native Swift, no Node.js required at runtime** CLI dashboard**— rich terminal view with color-coded progress bars** Read-only usage checks**— never proxies inference or scrapes web UIs** Local credentials**— reads existing logins from official tools; tokens stay on your machine** Shared cache**— CLI and menu bar app share`~/.creditwatcher/`\n\nquota cache**60-second cooldown**— on-demand refresh, avoids hammering provider APIs** Optional local web UI**—`creditwatcher serve`\n\non`127.0.0.1`\n\nonly\n\nCreditWatcher is designed to be local-first:\n\n| Data | Where it lives |\n|---|---|\n| OAuth / session tokens | Read from local files only (menu bar app never reads Keychain) |\n| Usage responses | Cached under `~/.creditwatcher/` |\n| Network calls | Direct to official provider APIs only |\n\n**No telemetry**— no analytics, crash reporters, or third-party servers** No token logging**— access/refresh tokens are not printed in normal operation** No Keychain in the menu bar app**— Claude auth uses JSON files and env vars only; no macOS Keychain prompts from the app** Optional CLI import**—`creditwatcher login claude`\n\nmay read Keychain once in Terminal to copy credentials into`~/.creditwatcher/claude-auth.json`\n\n**Sandbox-free macOS app**— required to read local credential stores and call provider APIs; see[SECURITY.md](/aalksii/creditwatcher/blob/main/SECURITY.md)\n\n**CLI:** Node.js 18+**macOS app:** macOS 14+ (Sonoma), Xcode 15+**Provider logins:** sign in with official tools first (`codex login`\n\n,`claude`\n\n, Cursor.app)\n\n```\ngit clone https://github.com/aalksii/creditwatcher.git\ncd creditwatcher\nnpm install\nnpm run build\nnpm link   # optional — install `creditwatcher` on your PATH\n```\n\nWithout linking:\n\n```\nnpm run dashboard       # rich terminal dashboard (all providers)\nnpm run status          # detailed text output per provider\nnpm run quota           # JSON output (used by menu bar integration)\nopen macos/CreditWatcher.xcodeproj\n# Product → Run (⌘R)\n```\n\nOr from the command line:\n\n```\nxcodebuild -project macos/CreditWatcher.xcodeproj -scheme CreditWatcher -configuration Debug build\n```\n\nThe built app is under Xcode DerivedData or `build/`\n\nwhen using `xcodebuild`\n\n.\n\nFor a local drag-to-Applications installer:\n\n```\nnpm run macos:dmg\n```\n\nThe DMG is written to `dist/macos/CreditWatcher-<version>.dmg`\n\n.\n\nFor public distribution, sign and notarize it with an Apple Developer ID:\n\n```\nSIGN_IDENTITY=\"Developer ID Application: Your Name (TEAMID)\" \\\nNOTARY_PROFILE=\"notarytool-profile\" \\\nnpm run macos:dmg\n```\n\nCreate the `notarytool`\n\nprofile once with `xcrun notarytool store-credentials`\n\n.\n\n| Command | Description |\n|---|---|\n`creditwatcher dashboard` |\nRich terminal dashboard — all providers |\n`creditwatcher dashboard --force` |\nSkip the 60-second usage cooldown |\n`creditwatcher status [codex|claude|cursor]` |\nDetailed usage per provider |\n`creditwatcher quota --json` |\nMachine-readable quota JSON |\n`creditwatcher login [codex|claude|cursor]` |\nImport or OAuth login helpers |\n`creditwatcher serve` |\nOptional local web UI at\n|\n\nExample:\n\n```\ncreditwatcher dashboard\ncreditwatcher status claude\ncreditwatcher quota --json\n```\n\n- Launch\n**CreditWatcher** from Xcode (⌘R) or open the built`.app`\n\n- A gauge icon appears in the menu bar (no Dock icon)\n- Click the icon for a popover with Codex, Claude, and Cursor usage cards\n- Use the gear button to show/hide providers, reorder cards, and sign in or out per tool\n- Icon tint reflects worst-case usage: system default <70%, yellow 70–90%, red >90%\n\n**Refresh:** auto-refresh on open; **Refresh** button bypasses the 60s cooldown. Background refresh every 60 seconds.\n\n**Quit:** click **Quit** in the popover or right-click the menu bar icon and choose **Quit CreditWatcher**.\n\n**Launch at login:** System Settings → General → Login Items → add CreditWatcher.\n\n**CLI button:** opens Terminal with `creditwatcher dashboard --verbose`\n\n(optional — requires the Node CLI).\n\nSign in with the official tools first. CreditWatcher reads existing credentials — it does not replace them.\n\n**Recommended:**\n\n```\ncodex login\ncreditwatcher status codex\n```\n\nAuth order:\n\n`~/.codex/auth.json`\n\n(official Codex CLI)`~/.creditwatcher/auth.json`\n\n(via`creditwatcher login codex`\n\n)\n\n**Recommended (menu bar app):**\n\n```\nclaude                              # sign in with Claude Code if needed\ncreditwatcher login claude          # import into ~/.creditwatcher/claude-auth.json\n```\n\nThen click **Refresh** in the menu bar app.\n\nAuth order for automatic usage checks (freshest token wins on auth failure):\n\n`CLAUDE_CODE_OAUTH_TOKEN`\n\nenvironment variable`~/.claude/.credentials.json`\n\n`~/.creditwatcher/claude-auth.json`\n\n(import copy via`creditwatcher login claude`\n\n)\n\nThe menu bar app reads only the sources above. For Claude Code installs that store credentials in Keychain (no credentials file), run `creditwatcher login claude`\n\nin Terminal — the CLI may read Keychain once there and save a file copy the app can use.\n\n**Recommended:** sign in via Cursor.app, then:\n\n```\ncreditwatcher status cursor\n```\n\nAuth order:\n\n`CURSOR_SESSION_TOKEN`\n\nenvironment variable- Cursor IDE SQLite state DB —\n`state.vscdb`\n\nkey`cursorAuth/accessToken`\n\n`~/.creditwatcher/cursor-auth.json`\n\n(import copy via`creditwatcher login cursor`\n\n)\n\n```\nCreditWatcher.app (Swift)          creditwatcher CLI (Node.js)\n├── CodexProvider                  ├── src/codex/\n├── ClaudeProvider                 ├── src/claude/\n└── CursorProvider                 └── src/cursor/\n         │                                    │\n         └──────── shared cache ──────────────┘\n                  ~/.creditwatcher/\n```\n\nNative app calls provider APIs directly via `URLSession`\n\n. No Node.js required at runtime.\n\n| Variable | Default | Description |\n|---|---|---|\n`CODEX_HOME` |\n`~/.codex` |\nCodex CLI auth directory |\n`CLAUDE_CONFIG_DIR` |\n`~/.claude` |\nClaude credentials directory |\n`CURSOR_SESSION_TOKEN` |\n— | Cursor session cookie value |\n`CURSOR_STATE_DB` |\nplatform default | Override path to Cursor `state.vscdb` |\n`CREDITWATCHER_OAUTH_PORT` |\n`1455` |\nOAuth callback port (Codex login) |\n\n**CreditWatcher is unofficial and not endorsed by OpenAI, Anthropic, or Cursor.**\n\n- Usage APIs may change without notice (especially Cursor's unofficial endpoints)\n- Third-party tools using consumer OAuth may violate provider Terms of Service\n- Anthropic has restricted consumer OAuth in third-party tools —\n**use Claude integration at your own risk** - This tool performs\n**read-only** usage checks — do not use it to proxy inference or share tokens **Use at your own risk**— the authors are not responsible for account actions by providers\n\nSee the [Safety & Terms of Service](#safety--terms-of-service) section in this README for details on safe usage patterns.\n\n- Pre-built macOS release (signed\n`.app`\n\n/ Homebrew cask) - Demo GIF for README\n- npm publish for global CLI install\n\n**Read-only** usage endpoints only (`GET /wham/usage`\n\n,`/api/oauth/usage`\n\n,`/api/usage-summary`\n\n)- Refreshes expired OAuth tokens via official token endpoints when needed\n- Stores tokens\n**locally only** - On-demand checks with a\n**60-second cooldown** per provider - Direct calls to provider APIs — no third-party relay\n\n- Proxy inference requests\n- Scrape ChatGPT or Claude web UIs\n- Send tokens to any server except the official provider APIs\n- Background polling beyond the 60s refresh interval\n- Log or print access/refresh tokens\n\n| Pattern | Why it's risky |\n|---|---|\n| Spoofing official client harness | Routing subscription quota through third-party agents |\n| Credential exfiltration | Sending OAuth tokens to third-party servers |\n| Inference proxying | Using subscription tokens for other users/tools |\n| Aggressive polling | Hammering usage endpoints |\n| Token sharing | Distributing refresh tokens across machines |\n\nSee [CONTRIBUTING.md](/aalksii/creditwatcher/blob/main/CONTRIBUTING.md). Please report security issues via [SECURITY.md](/aalksii/creditwatcher/blob/main/SECURITY.md).\n\n[MIT](/aalksii/creditwatcher/blob/main/LICENSE) — Copyright (c) 2026 Aleksei Artemiev", "url": "https://wpnews.pro/news/open-source-claude-codex-cursor-limits-tracker-for-mac", "canonical_source": "https://github.com/aalksii/creditwatcher", "published_at": "2026-07-01 08:55:15+00:00", "updated_at": "2026-07-01 09:20:56.686955+00:00", "lang": "en", "topics": ["developer-tools", "ai-tools", "ai-products"], "entities": ["CreditWatcher", "Codex", "Claude Code", "Cursor", "OpenAI", "Anthropic", "Stats", "GitHub"], "alternates": {"html": "https://wpnews.pro/news/open-source-claude-codex-cursor-limits-tracker-for-mac", "markdown": "https://wpnews.pro/news/open-source-claude-codex-cursor-limits-tracker-for-mac.md", "text": "https://wpnews.pro/news/open-source-claude-codex-cursor-limits-tracker-for-mac.txt", "jsonld": "https://wpnews.pro/news/open-source-claude-codex-cursor-limits-tracker-for-mac.jsonld"}}