Skip to main content
PATCH
Update a meter

Authorizations

Authorization
string
header
required

Your account's secret key: Authorization: Bearer sk_test_… or sk_live_…. Server-side only.

Path Parameters

productID
string<uuid>
required

Product ID.

meterID
string<uuid>
required

Meter ID.

Body

application/json

Omitted fields stay as they are. name cannot be changed.

displayName
string
unit
enum<string>
Available options:
token,
request,
unit
aggregation
enum<string>
Available options:
sum,
count,
unique_count,
max,
last

Response

The updated meter.

A meter: defines how usage events add up to a billable quantity.

id
string<uuid>
productId
string<uuid>
name
string

The key you send in track(). Cannot change after creation.

displayName
string

Name shown on invoices and in the dashboard.

unit
enum<string>

token, request or unit.

Available options:
token,
request,
unit
aggregation
enum<string>

How events aggregate: sum, count, unique_count, max or last.

Available options:
sum,
count,
unique_count,
max,
last
valueProperty
string | null

Event field carrying the numeric value. Unused with count.

status
string