Docs/API Reference

API Key Analytics

Track real-time usage metrics per API key.

Every API key has its own live analytics, so you can see how each integration behaves: how much it's used, how often it fails, and which models it calls.

GET/api/v1/keys/:keyId/analytics?range=30d
Analytics for one key over a time range.

What you get

UsageModels
Total requestsWhich models were called
Success rateRequest count per model
Failed requestsShare of usage per model
Average response timeHow usage moves between models over time
curl "https://api.tarqaai.com/api/v1/keys/KEY_ID/analytics?range=30d" \
  -H "Authorization: Bearer YOUR_API_KEY"
Prefer a dashboard?

The same numbers, with charts, are in Monitor → Analytics and Monitor → Activity in your dashboard.

FAQ

Where do I find a key's ID?
In Developer → API Keys in the dashboard, or from GET /v1/keys.
Is it real-time?
Yes. Requests show up as they happen.
Can I use it to check a key rotation?
Yes. After deploying a new key, confirm traffic is flowing on it here before revoking the old one. See Authentication.