Usage meters
Create a meter
Creates a meter that counts events of one name with one aggregation.
Authorization
bearer usage:writeAuthorizationBearer <token>
A v1 API key; the scope named is the one the route needs.
In: header
Scope: usage:write
Header Parameters
Idempotency-Key*string
Names the act so a retry under it lands on the stored answer (idempotency-key).
Length
1 <= length <= 255Request Body
application/json
TypeScript Definitions
Use the request body type in TypeScript.
Response Body
application/json
application/problem+json
curl -X POST "https://example.com/v1/meters" \ -H "Idempotency-Key: string" \ -H "Content-Type: application/json" \ -d '{ "name": "string", "eventName": "string", "aggregation": { "type": "count" }, "unit": "string" }'{ "id": "string", "name": "string", "description": "string", "eventName": "string", "aggregation": { "type": "count" }, "unit": "string", "filter": { "conjunction": "and", "clauses": [ { "key": "string", "operator": "equals", "value": "string" } ] }, "status": "active", "archivedAt": "2019-08-24T14:15:22Z", "hasEvents": true, "createdAt": "2019-08-24T14:15:22Z", "updatedAt": "2019-08-24T14:15:22Z", "liveMode": true}