Querying
Usage by event property
get/v2/events/aggregate
Query parameters
propertystring required
valuestring required
aggregation'sum' | 'min' | 'max' | 'avg' | 'latest' | 'count'
Aggregation applied to corrected usage events. latest returns the quantity from the event with the latest occurred_at; ties use accepted_at then event ID. count returns the number of events.
Example:sum
start_atinteger
Unix timestamp in seconds.
Example:1767225600
Inclusive lower bound for event occurrence time. Defaults to five years before the request.
end_atinteger
Unix timestamp in seconds.
Example:1767225600
Exclusive upper bound for event occurrence time. Defaults to the request time.
currencystring
Example:usd
Aggregate only matching events for this currency. Normalized to lowercase.
Response
Metric totals for matching usage events.
Example response
{
"property": "ari_job_id",
"value": "018f5f0c-1111-7abc-8def-123456789abc",
"aggregation": "sum",
"data": [
{
"metric_id": "metric_0194f4e3a2b77c6aa91c4f6b4db2a980",
"currency": "usd",
"quantity": "1250.5"
}
]
}Changes
No recorded changes to this endpoint across all 1 revision of this API.