List metering events
Changed onList ingested events.
Request
- Base URL: https://global.api.konghq.com
- URL: https://global.api.konghq.com/v3/openmeter/events
- Auth: one of:
- HTTP bearer
- HTTP bearer
- HTTP bearer
- HTTP bearer
Query parameters
Filter events returned in the response.
To filter events by subject add the following query param: filter[subject][eq]=customer-1
{
"customer_id": "01G65Z755AFWAKHE12NY0CQ9FH",
"time": {
"eq": "2022-03-30T07:20:50Z"
},
"ingested_at": {
"eq": "2022-03-30T07:20:50Z"
},
"stored_at": {
"eq": "2022-03-30T07:20:50Z"
}
}The asc suffix is optional as the default sort order is ascending. The desc suffix is used to specify a descending order. Multiple sort attributes may be provided via a comma separated list. JSONPath notation may be used to specify a sub-attribute (eg: 'foo.bar desc').
Sort events returned in the response. Supported sort attributes are:
- time (default)
- ingested_at
- stored_at
When omitted, events are sorted by time desc (most recent first). When a sort field is provided without a suffix, it sorts descending. Append the asc suffix to sort ascending, or the desc suffix to sort descending.
Response
Cursor paginated response.
Example response
{
"data": [
{
"event": {
"id": "5c10fade-1c9e-4d6c-8275-c52c36731d3c",
"source": "service-name",
"specversion": "1.0",
"type": "prompt",
"subject": "customer_key",
"time": "2023-01-01T01:01:01.001Z"
},
"customer": {
"id": "01G65Z755AFWAKHE12NY0CQ9FH"
},
"ingested_at": "2023-01-01T01:01:01.001Z",
"stored_at": "2023-01-01T01:01:02.001Z"
}
],
"meta": {
"page": {
"size": 10
}
}
}Changes
- breaking
added to the
/response propertyoneOflist for the response status - warning
added the new
key_invalidenum value to the//////response property for the response status - warning
added the new
uniqueenum value to the//////response property for the response status
- breaking
- warning
added the new
400.00enum value to theresponse property for the response status - warning
added the new
403.00enum value to theresponse property for the response status
- warning