Usage Tracking
Daily usage check
Daily usage check
Prompt: “What’s my AI API usage today?”What it does: Returns total costs, API calls, and token usage for today, broken down by provider and model.
Weekly comparison
Weekly comparison
Prompt: “Compare my usage this week vs last week”What it does: Shows usage summaries for both periods so you can spot trends.
Provider breakdown
Provider breakdown
Prompt: “Which provider am I spending the most on?”What it does: Returns costs grouped by provider (OpenAI, Anthropic, etc.)
Project costs
Project costs
Prompt: “Show me costs broken down by project tag”What it does: Groups usage by the
project metadata tag to see per-project spending.Savings Analysis
Subscription ROI
Subscription ROI
Prompt: “Am I saving money with Claude Max?”What it does: Compares your usage against retail pricing to show if your flat-rate subscription is worth it.
Monthly savings report
Monthly savings report
Prompt: “Show my savings vs retail this month”What it does: Shows total retail cost, subscription cost, and net savings for the current month.
Model-level breakdown
Model-level breakdown
Prompt: “Which models am I using the most under my subscription?”What it does: Shows per-model usage and what that would cost at retail rates.
Monitoring & Alerts
Anomaly detection
Anomaly detection
Prompt: “Are there any cost anomalies I should know about?”What it does: Analyzes recent usage patterns and flags any unusual spikes or changes.
Check alerts
Check alerts
Prompt: “Do I have any unread alerts?”What it does: Lists recent alerts including budget warnings and cost spike notifications.
Set up Slack notifications
Set up Slack notifications
Prompt: “Create a Slack webhook for budget alerts at https://hooks.slack.com/services/…”What it does: Creates a new webhook that sends notifications to your Slack channel.
Pricing Lookups
Model pricing
Model pricing
Prompt: “What’s the current pricing for GPT-4o?”What it does: Returns input/output pricing per million tokens and context window size.
Compare providers
Compare providers
Prompt: “Compare Anthropic and OpenAI pricing”What it does: Shows pricing for all models from both providers for comparison.
Claude Code & Codex Sync
Sync Claude Code usage
Sync Claude Code usage
Prompt: “Sync my Claude Code usage”What it does: Parses local
~/.claude/projects files and uploads usage metadata (tokens, models, timestamps) to your CostHawk dashboard.Preview before syncing
Preview before syncing
Prompt: “Preview my Claude Code sync with dryRun enabled”What it does: Shows exactly what data would be sent without making any network requests. Great for transparency.
Sync Codex CLI usage
Sync Codex CLI usage
Prompt: “List my Codex sessions first, then sync Codex usage for the last 30 days”What it does: Verifies local discovery with
costhawk_list_codex_sessions, then uploads metadata with costhawk_sync_codex_usage maxAgeHours=720.Combined sync
Combined sync
Prompt: “Sync all my local AI usage data”What it does: Syncs both Claude Code and Codex CLI usage in one operation.
Privacy & Transparency
See what files are accessed
See what files are accessed
Run in terminal:What it does: Lists all file paths the MCP server would access, without making network requests.
Verify MCP env and auto-sync flags
Verify MCP env and auto-sync flags
Run in terminal:What it does: Confirms
hasApiKey, autoSyncEnabled, codexAutoSyncEnabled, and local directory detection (local.codexDir, local.claudeCodeDir).Preview any sync payload
Preview any sync payload
Prompt: “Show me what would be sent if I sync my usage, but don’t actually send it”What it does: Uses
dryRun: true to return the full payload that would be uploaded, so you can verify nothing sensitive is included.Combining Tools
You can ask complex questions that use multiple tools:“I’m spending more than usual this week. Can you check for anomalies and show me which project is driving the increase?”Claude will:
- Run anomaly detection
- Get usage by project tag
- Analyze and explain the results
“Sync my Claude Code usage, then show me my total spending this month including the new data”Claude will:
- Sync local Claude Code data
- Fetch updated usage summary
- Present a comprehensive monthly report
Privacy note: All sync operations only send usage metadata (tokens, models, timestamps). Your code, prompts, and file paths are never transmitted.
