Connect Anthropic to StackSpend
Track Anthropic API costs and Claude Code Analytics, including model-level spend and user-level Claude Code usage.
StackSpend tracks Anthropic (Claude) API costs and Claude Code Analytics using your Admin API key. Get model-level breakdown, daily spend visibility, user-level Claude Code attribution, anomaly detection, and forecasting.
Prerequisites
- An Anthropic organization account with API access
- Access to Anthropic Console
- Admin API key (required for cost reporting and Claude Code Analytics)
Generate an Admin API Key
Create an Admin API key in the Anthropic Console. Admin keys are required for organization cost reporting and Claude Code Analytics.
- 1Go to Anthropic Console
- 2Navigate to API Keys (or Settings → API Keys)
- 3Click Create Key or Generate API Key
- 4Select Admin key type (required for cost reporting and Claude Code Analytics)
- 5Optionally name the key (e.g., "StackSpend Cost Tracking")
- 6Click Create Key
- 7Important: Copy the API key immediately. It starts with
sk-ant-admin-. You won't be able to see it again.
Note: Admin API keys provide organization-level access to Anthropic usage data. Store them securely and never share them publicly.
Connect in StackSpend
- 1Go to Settings → Providers in your StackSpend dashboard
- 2Click Add Provider → Select Anthropic
- 3Paste your Admin API key
- 4Click Test Connection to verify
- 5Once the test succeeds, click Connect
After Connecting
Once Anthropic is connected, StackSpend begins syncing API cost data and Claude Code Analytics. Claude Code Analytics is daily aggregated and can lag by up to 1 hour.
- Costs sync automatically every 6 hours
- Model-level usage tracking (Claude Opus, Sonnet, Haiku)
- User-level Claude Code cost attribution when available
- Claude Code token, session, tool acceptance, commit, and pull request metrics
Related reading
- Anthropic Cost Monitoring
- How to Track LLM API Spend Across OpenAI, Anthropic, Bedrock, Vertex, and Azure OpenAI
- OpenAI vs Anthropic Pricing in 2026: Which API Is Actually Cheaper?
- LLM Spend Management - Tracking OpenAI, Anthropic, and Cursor in One Place
- Connect OpenAI to StackSpend
- Connect Cursor to StackSpend
Know where your cloud and AI spend stands — every day.
Connect providers in minutes. Get 90 days of visibility and start receiving daily cost updates before the invoice lands.