ai-usage
Check AI usage across Anthropic and other providers. Use when: 1. User asks about AI usage, token usage, or quota 2. User says "what's my AI usage" or "how much have I used" 3. User asks about Anthropic/Claude usage or limits 4. User asks about costs or spending on AI 5. Monitoring usage during heartbeats (daily check)
Install via CLI (Recommended)
clawhub install openclaw/skills/skills/bshandley/ai-usageWhat This Skill Does
The ai-usage skill serves as a comprehensive monitoring dashboard for your AI consumption within the OpenClaw ecosystem. It provides real-time visibility into your interaction patterns, token usage, and associated costs across various AI providers. By bridging the gap between your local OpenClaw session logs and the official Anthropic OAuth quota API, this tool ensures you never hit unexpected rate limits or budget caps. It automatically detects and parses logs from multiple providers like Anthropic, OpenAI, and Ollama, offering both a human-readable CLI summary and a machine-readable JSON output for automated tracking systems.
Installation
To integrate this tool into your OpenClaw environment, execute the following command in your terminal:
clawhub install openclaw/skills/skills/bshandley/ai-usage
This script is lightweight and requires no external pip dependencies, running natively on Python 3.10+ environments. It utilizes existing authentication from your Claude Code installation to query quota data securely.
Use Cases
This skill is designed for power users, developers, and team leads who need granular control over their AI spend. Use it to:
- Monitor weekly utilization percentages for Anthropic models including Sonnet and Opus.
- Track rolling 5-hour usage windows to avoid rate-limit throttling.
- Audit total token consumption across different local and cloud-based AI providers.
- Generate cost reports for project-based accounting using the built-in parsing engine for session logs.
- Set up automated heartbeat checks to receive alerts before your monthly spend or API quota is reached.
Example Prompts
- "What is my current AI usage across all models today?"
- "How much of my Anthropic weekly quota have I burned through so far?"
- "Show me the token breakdown for my recent sessions and tell me if I'm trending over budget."
Tips & Limitations
- Use the
--jsonflag when piping output into monitoring tools or custom dashboards to ensure clean data parsing. - If you are running automated checks, use a smaller, faster model like Haiku to minimize the overhead cost of the check itself.
- The tool requires
claudeCLI access to read quota details; if your credentials are expired, the tool will attempt an automatic refresh, but ensure your~/.claude/.credentials.jsonfile is properly configured. - Note that while local OpenClaw logs are parsed immediately, real-time external API quota information is subject to the responsiveness of the Anthropic authentication server.
Metadata
Not sure this is the right skill?
Describe what you want to build — we'll match you to the best skill from 16,000+ options.
Find the right skillPaste this into your clawhub.json to enable this plugin.
{
"plugins": {
"official-bshandley-ai-usage": {
"enabled": true,
"auto_update": true
}
}
}Tags(AI)
Flags: file-read, external-api
Related Skills
stoic-quotes
Provide Stoic philosophy quotes from Marcus Aurelius, Seneca, Epictetus, Cato, and other Stoic philosophers upon user request. Use when: 1. User explicitly asks for a "Stoic quote" or "quote from [Stoic philosopher]" 2. User requests philosophical wisdom or inspiration from Stoicism 3. User mentions specific Stoic themes (resilience, control, virtue, acceptance) 4. User asks for guidance from Marcus Aurelius, Seneca, Epictetus, or other Stoics Always acknowledge that quotes have been previously provided when delivering a quote. Reference the comprehensive quotes collection for selection.
nextcloud
Access Nextcloud files via WebDAV API. Sync documents for RAG indexing, upload files, manage folders, and automate workflows. Use when browsing cloud files, syncing to local RAG, uploading recordings, or any Nextcloud file operations.