Usage stats
Description
Usage APIs are the same Dashboard REST handlers. Authenticate with a Management API Key. Do not send these to *-rpc.blockreq.com.
| Operation | Path |
|---|---|
| Per-endpoint counts | GET /api/dashboard/endpoints/stats |
| Hourly analytics | GET /api/dashboard/analytics |
| Aggregated overview | GET /api/dashboard/overview |
stats accepts period=24h or period=30d. analytics / overview accept windowMinutes and limit.
Code
curl -H "Authorization: Bearer akv1_YOUR_MANAGEMENT_API_KEY" \
"https://blockreq.com/api/dashboard/endpoints/stats?period=24h"
curl -H "Authorization: Bearer akv1_YOUR_MANAGEMENT_API_KEY" \
"https://blockreq.com/api/dashboard/analytics?windowMinutes=1440"
curl -H "Authorization: Bearer akv1_YOUR_MANAGEMENT_API_KEY" \
https://blockreq.com/api/dashboard/overviewSchemas: Interactive API Docs.
Try It
GET /dashboard/endpoints/stats
https://blockreq.com/api/dashboard/endpoints/stats?period=24h
GET /dashboard/analytics
https://blockreq.com/api/dashboard/analytics?windowMinutes=1440
GET /dashboard/overview
https://blockreq.com/api/dashboard/overview?windowMinutes=1440