Skip to main content
API v2 is in beta. Endpoints return the X-Lago-Endpoint-Status: beta header.

Billable Metric.

lago_id
string<uuid>
required

Unique identifier created by Lago.

Example:

"1a901a90-1a90-1a90-1a90-1a901a901a90"

name
string
required

Name.

Example:

"example"

code
string
required

Code.

Example:

"example"

description
string | null
required

Description.

Example:

"example"

aggregation_type
enum<string>
required

How event values are aggregated.

Available options:
count_agg,
sum_agg,
max_agg,
unique_count_agg,
weighted_sum_agg,
latest_agg
Example:

"count_agg"

weighted_interval
enum<string> | null
required

Weighting interval for weighted_sum_agg.

Available options:
seconds,
null
Example:

"seconds"

recurring
boolean
required

Recurring.

Example:

false

rounding_function
enum<string> | null
required

Rounding applied to the aggregated quantity.

Available options:
round,
ceil,
floor,
null
Example:

"round"

rounding_precision
integer | null
required

Rounding precision.

Example:

1

field_name
string | null
required

Field name.

Example:

"example"

expression
string | null
required

Expression.

Example:

"example"

created_at
string<date-time>
required

UTC creation timestamp, with microsecond precision.

Example:

"2022-04-29T08:59:51.123456Z"

updated_at
string<date-time>
required

UTC timestamp of the last update, with microsecond precision.

Example:

"2022-04-29T08:59:51.123456Z"

deleted_at
string<date-time> | null
required

UTC deletion timestamp, with microsecond precision. Null until deletion.

Example:

null

filters
object[]

Filters defined by this metric. Included only with expands[]=filters.