Api reference
Retrieve a customer-meter aggregate
Returns a single customer-meter aggregate for the specified customer + meter pair. Returns 404 only if the meter itself does not exist on the merchant — if the meter exists but the customer has zero events, the response returns an aggregate with total_quantity: 0, event_count: 0, last_event_at: null.
Related endpoints
GET /customer-meters— List a customer's meter usage
Common errors
401 unauthenticated— missing, malformed, or revoked API key.404 resource_missing— the referenced resource does not exist or is not visible to your key.
x-api-key<token>
Your RevKeen API key (powered by Unkey). Get it from Dashboard > Settings > API Keys. Use rk_sandbox_* for test mode and rk_live_* for production.
In: header
Path Parameters
customer_id*string
Customer UUID
Format
uuidmeter_id*string
Meter UUID
Format
uuidResponse Body
application/json
application/json
application/json
curl "https://api.revkeen.com/v2/customer-meters/00000000-0000-0000-0000-000000000000/00000000-0000-0000-0000-000000000000" \ -H "x-api-key: $REVKEEN_API_KEY"{
"data": {
"object": "customer_meter",
"customer_id": "160c0c4b-9966-4dc1-a916-8407eb10d74e",
"meter_id": "1e13adc1-9ac9-453b-b100-17d2f2da2eb8",
"meter_name": "string",
"meter_event_name": "api_request",
"aggregation": "sum",
"unit_name": "requests",
"total_quantity": 4820,
"event_count": 412,
"last_event_at": "2019-08-24T14:15:22Z"
}
}{
"error": {
"type": "string",
"code": "string",
"message": "string"
}
}{
"error": {
"type": "string",
"code": "string",
"message": "string"
}
}