API Reference
Log In
API Reference

Count the enforcement events matching a filter

Returns counts of blocked, would-have-blocked, warned and would-have-warned events for the same filters as the events list, plus how many people or objects were affected. The response is a single object, not a paged list. level and mode are accepted so one query string works on every endpoint on this resource, and are deliberately not applied to these counts: level defaults to HARD, so applying it would report zero warnings to every caller that never sent a level at all, and filtering to one tier would zero the counts beside it. Every other filter is applied, over the window resolved exactly as the list resolves it. distinctAffected is zero on a cost control with one limit for everyone, which groups on nothing, and counts events whose dimension was never recorded, so it can be larger than the total on /affected, which needs both the value and the dimension. resolvedSince and resolvedUntil carry the window these counts were actually taken over, which is not always the one that was asked for: an over-old since is moved forward rather than refused.

Recent Requests
Log in to see full request history
TimeStatusUser Agent
Retrieving recent requests…
LoadingLoading…
Query Params
string
required

ID of the team that owns this data.

string

Optional ISO-8601 timestamp starting the date range, inclusive, resolved exactly as the list resolves it, so the counts and the rows cover one window

string

Optional ISO-8601 timestamp ending the date range, inclusive, resolved exactly as the list resolves it

string

Optional Revenium-generated identifier of a cost control. When supplied, only events produced by that rule are counted.

string
enum

Ignored here: the counts always cover every tier and every mode. Accepted so the list's query string works unchanged, and an invalid value is rejected with 422.

Allowed:
string
enum

Ignored here: the counts always cover every tier and every mode. Accepted so the list's query string works unchanged, and an invalid value is rejected with 422.

Allowed:
string

Optional free-text search, matched case-insensitively against the event text, exactly as on the list

string

Optional exact match on the affected person or object. Send back the value this resource returned in groupValue. Requires groupBy alongside it, or the request is rejected with 422.

string

Which dimension groupValue belongs to, for example SUBSCRIBER or DEPARTMENT. Required whenever groupValue is sent, and groupValue is required whenever this is sent; either one alone is rejected with 422 naming the missing one. Matched case-insensitively against the known dimensions; a value that matches none of them is rejected with 422 naming the accepted values, rather than being answered as though nothing matched.

string

Optional exact match on the transaction ID of the request that tripped the rule

Headers
string
enum
Defaults to application/json

Generated from available response content types

Allowed:
Responses

Language
Credentials
Header
LoadingLoading…
Response
Click Try It! to start a request and see the response here! Or choose an example:
application/json
application/hal+json
*/*