Anthropic
Connect your Anthropic account to track API costs, model-level usage, and Claude Code analytics in StackSpend.
Anthropic
Direct API billing — Admin API key required
The Anthropic provider connects StackSpend to your Anthropic organization account via the Admin API. Once connected, StackSpend pulls your full billing history on first sync, then keeps it current in real time as new usage accrues.
What StackSpend tracks
- Real-time API costs across all models in your organization
- Model-level usage breakdown — input tokens, output tokens, and cost per model
- Claude Code user-level cost attribution — see spend per engineer
- Claude Code token and productivity metrics
- Full historical data synced on first connection
Prerequisites
- An Anthropic organization account (not a personal account)
- An Admin API key — this must be created from the Admin API section, not the regular API keys section
Setup
Get your Admin API key
Go to console.anthropic.com and navigate to Settings → Admin API Keys. Click Create key and give it a name such as “StackSpend”.
Add to StackSpend
In StackSpend, go to Providers → Add provider and select Anthropic. Paste your Admin API key into the key field and click Save.
Verify sync
Cost data appears within minutes of saving. Your full billing history is backfilled on the first sync. Claude Code analytics (user attribution, token and productivity metrics) may lag by up to 1 hour.
Data summary
| Attribute | Value |
|---|---|
| Data latency | Real-time |
| Historical data | Full history |
| Setup time | 2 min |
sk-ant-admin...) and not a regular API key (sk-ant-api...). These are different keys created in different sections of the Anthropic console. Only Admin API keys have permission to read billing data.