API Reference
Log In
API Reference

Count the matching enforcement events per day or per week

Returns the history strip for the same filter the list accepts: one entry per bucket that has events, ascending, with the bucket start as local wall time in the zone named on the answer. zone is an IANA region id such as America/Denver and defaults to UTC; buckets follow that zone, so an evening block lands on the day the reader saw it rather than on UTC's next day. Z is accepted as a spelling of UTC; any other offset, such as UTC+01:00, is refused with 422, because it is not a zone name. A bucket with no events is absent rather than returned as a zero, and the first and last bucket can be partial, because the window bounds are applied to the time the event was written. level defaults to ALL here, so a reader who has chosen no tier sees every enforcement event in the window rather than only hard-cap breaches. The answer is an EnforcementEventHistoryPageResource: the bars under buckets, beside the zone they were actually cut in and the resolvedSince and resolvedUntil of the window actually searched. It is this endpoint's own object rather than the paged envelope the list returns, so do not reach for the list's unwrapping helper here.

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

Revenium-generated identifier of the team to scope the counts

string

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

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

Which tier of events to count. ALL is the default and counts both; HARD counts cap breaches and would-be breaches, WARN counts warning-line crossings.

Allowed:
string
enum

Whether to count real enforcement actions, a shadow rule's would-have-done rows, or both

Allowed:
string

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

string

Optional exact match on the affected person or object, which is what turns this into one person's history strip. Requires groupBy alongside it, or the request is rejected with 422.

string

Which dimension groupValue belongs to. 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 request that tripped the rule, named as the transactionId field these endpoints return it under

string
enum

How wide each bucket is. DAY is the default; HOUR buckets to the start of the hour, which is what keeps a one-day window from drawing a single bar; WEEK buckets to the Monday that starts the ISO week in the requested zone.

Allowed:
string

IANA region id the buckets are cut in, defaulting to UTC. Z is accepted as a spelling of UTC. Any other offset, such as UTC+01:00, is not a zone name and is rejected with 422. The zone actually used comes back on the answer, because a well-formed region id this service does not recognise falls back to UTC rather than being refused.

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
*/*