Skip to content

santifer/claude-pulse

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

5 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Claude Pulse

Leer en español

SwiftBar plugin for macOS that monitors Claude API usage in real-time. Tracks rate limits, predicts when you'll hit caps, and helps you pace your usage intelligently.

Claude Pulse

The Problem

Claude Code users hit rate limits unexpectedly. The API has two time windows (5-hour and 7-day) with separate limits, making it hard to know when you're burning through your quota too fast.

The Solution

Claude Pulse sits in your menu bar and shows:

  • Real-time usage across both time windows (5h + 7d)
  • Smart color coding — green/yellow/orange/red based on consumption rate vs time remaining
  • Reset predictions — exactly when your limits refresh
  • Recent sessions — one-click resume from menu bar
  • macOS alerts — notifications at 70% and 90% thresholds

Tech Stack

Bash macOS SwiftBar jq Claude

Installation

# 1. Install dependencies
brew install --cask swiftbar
brew install jq

# 2. Copy to SwiftBar plugins folder
cp claude-pulse.1m.sh ~/Library/Application\ Support/SwiftBar/Plugins/

# 3. Make executable
chmod +x ~/Library/Application\ Support/SwiftBar/Plugins/claude-pulse.1m.sh

Requirements:

  • macOS (uses Keychain for OAuth token)
  • SwiftBar
  • jq
  • Active Claude Code OAuth session

How It Works

The plugin queries Anthropic's OAuth API every minute and calculates a "burn rate" — comparing your usage percentage against time elapsed. If you're using 50% of your quota but only 25% of the time window has passed, you're on track to hit the limit before reset.

Color Logic

Color Meaning
🟢 Green On pace — will have quota remaining at reset
🟡 Yellow 30% faster than sustainable
🟠 Orange 60% faster — slow down
🔴 Red Will exhaust before reset

Configuration (Optional)

Create ~/.claude-usage-config.json:

{
  "alerts": {
    "threshold_warning": 70,
    "threshold_critical": 90,
    "cooldown_minutes": 30,
    "enabled": true
  },
  "display": {
    "max_sessions": 5,
    "show_velocity": true,
    "show_streak": true,
    "show_predictions": true
  }
}

License

MIT

Let's Connect

Website LinkedIn Email

About

SwiftBar plugin for macOS. Real-time Claude API usage monitoring with rate limit predictions and smart alerts.

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Languages