Home › Per-customer API analytics
API usage analytics per customer
Once your API has paying users, the questions change. It's no longer "how many requests?" but "who is sending them, to which endpoints, and are they about to outgrow their plan?"
Why per-endpoint metrics aren't enough
Free tools like Cloudflare's Endpoint Management show request count, latency and error rate per endpoint (last 24 hours or 7 days). Below Enterprise, they don't break that down by customer or plan (checked Oct 11, 2026). Per-customer analytics usually means Moesif (from US$165/mo at 1M events), Treblle (US$233/mo billed yearly) or building your own pipeline.
Three ways to attribute a request to a customer
- Response headers (most accurate). Your origin already knows who the caller is. Return
X-MSA-Customer-Id: cus_42andX-MSA-Plan: pro. API Meter reads them and strips them before the client sees them. - Request headers. If your SDK sends
x-customer-idandx-customer-plan, those work too. - Hashed API key (zero code). No tagging? We hash the
x-api-keyor Bearer token with a per-API salt, so each key becomes a stable pseudonymous customer ID likek:b43cba44de7d4e92.
What you see
- Requests, 5xx error rate and p95 latency
- Top endpoints, normalized (
/orders/123becomes/orders/:id) - Per-customer request counts and share of traffic, with plan
- A monthly usage meter and per-customer CSV export
The live demo dashboard shows real traffic sent through the public demo API.