Docs

GET /v1/usage

Check your CC API credit consumption and plan status.

API

GET /v1/usage

Check your current credit balance, plan status, and usage breakdown.

Request

GET https://api.coolcoding.co.uk/v1/usage

Example Request

curl https://api.coolcoding.co.uk/v1/usage \
  -H "Authorization: Bearer cc-YOUR_API_KEY"

Python:

import requests

response = requests.get(
    "https://api.coolcoding.co.uk/v1/usage",
    headers={"Authorization": "Bearer cc-YOUR_API_KEY"}
)
print(response.json())

Response

{
  "plan": "Builder",
  "credits_used": 1240,
  "credits_remaining": 760,
  "credits_total": 2000,
  "resets_at": "2026-06-01T00:00:00Z",
  "breakdown": {
    "ingest": 640,
    "signals": 310,
    "alerts": 140,
    "score": 90,
    "report": 60
  },
  "request_id": "req_1c3e9a"
}

Rate limit: 10 requests per 10 minutes on all plans.

Error Responses

Code Meaning
400 Bad Request — missing or invalid parameters
401 Unauthorized — API key missing or invalid
429 Too Many Requests — rate limit exceeded
432 Plan limit exceeded — upgrade your plan
500 Internal Server Error

429 example:

{
  "error": "Rate limit exceeded. Please reduce request frequency.",
  "retry_after": 60
}

Implement retry logic that respects the retry-after header value.

Expert help

Need help tracking this in your app?

Our team sets up analytics pipelines for mobile and web teams every day. Talk to us and get your first events flowing in under an hour.

Talk to an expert