Create Meter

View as Markdown

Create a new meter for usage-based billing.

Meters define how to track and aggregate usage events for billing. Each meter must have a unique event_name within an account.

Authentication

AuthorizationBearer

Bearer authentication of the form Bearer <token>, where token is your auth token.

Path parameters

account_idstringRequired

Request

This endpoint expects an object.
display_namestringRequired
event_namestringRequired
aggregation_formulaenumRequired
event_payload_customer_mapping_keystringOptionalDefaults to customer_id
event_payload_value_keystringOptionalDefaults to value

Response

Successful Response
idstring
account_idstring
display_namestring
event_namestring
aggregation_formulastring
event_payload_customer_mapping_keystring
event_payload_value_keystring
is_activeboolean
created_atdatetime
updated_atdatetime

Errors

422
Unprocessable Entity Error