claude-usage

Check Claude Code / Claude Max usage limits. Run when user asks about usage, limits, quota, or how much Claude capacity is left.

Safety Notice

This listing is from the official public ClawHub registry. Review SKILL.md and referenced scripts before running.

Copy this and send it to your AI assistant to learn

Install skill "claude-usage" with this command: npx skills add aligurelli/claude-usage-checker

Claude Usage Checker

Launches the Claude CLI interactively (PTY) and reads the /usage output to report your Claude Code / Claude Max quota.

Prerequisites

  • Claude CLI must be installed (npm i -g @anthropic-ai/claude-code) and logged in
  • If running claude shows "Missing API key", the user must log in manually first: open a terminal, run claude, and complete the browser login flow
  • Requires an interactive PTY — the agent will launch a local process and read its output (quota info only)

Steps

  1. Launch claude with PTY
  2. Wait for the welcome screen (poll until it appears)
  3. Send /usage + Enter
  4. Read the output (poll until usage data appears)
  5. Close with Escape then /exit
  6. Report the results

Commands

# Launch claude with PTY
exec pty=true command="claude"

# Wait and check log
process action=poll sessionId=XXX timeout=5000

# Send /usage
process action=send-keys sessionId=XXX literal="/usage"
process action=send-keys sessionId=XXX keys=["Enter"]

# Read output
process action=poll sessionId=XXX timeout=5000

# Exit
process action=send-keys sessionId=XXX keys=["Escape"]
process action=send-keys sessionId=XXX literal="/exit"
process action=send-keys sessionId=XXX keys=["Enter"]

Notes

  • If you see "Missing API key" → tell the user to log in; browser-based login won't work headlessly
  • Allow a few seconds between polls — Claude CLI starts slowly
  • "Current week" = weekly reset, not daily

Output Format

Report in a table:

UsageResets
Current sessionX% usedtoday at HH:MM (timezone)
Weekly (all models)X% usedHH:MM (timezone)
Weekly (Sonnet only)X% usedHH:MM (timezone)
Extra usageX% used / $X of $Y spentdate (timezone)

Always show reset times. The CLI displays them as "Resets Xpm" — convert to HH:MM format.

Source Transparency

This detail page is rendered from real SKILL.md content. Trust labels are metadata-based hints, not a safety guarantee.

Related Skills

Related by shared tags or category signals.

Coding

client-onboard

Generate a complete client onboarding package from a project description. Creates project brief, tech stack, milestones, folder structure, CLAUDE.md, and a r...

Registry SourceRecently Updated
Coding

workflow-migrate

Migrate N8N/Zapier/Make workflows to production-grade Python or Node.js scripts. Given a workflow description or paste, rewrites automation logic with retry,...

Registry SourceRecently Updated
Coding

Freelance Proposal Writer

Write high-converting freelance proposals from job postings (Upwork, Toptal, Freelancer, etc). Given a job URL or pasted description, analyzes the client's r...

Registry SourceRecently Updated
Coding

Spec-First Development

Spec-driven development workflow. Before writing any code, generates a comprehensive SPEC.md covering data models, user flows, API contracts, file structure,...

Registry SourceRecently Updated