Skip to content
This repository has been archived by the owner on Dec 12, 2024. It is now read-only.

Latest commit

 

History

History
46 lines (30 loc) · 2.55 KB

BillableMetricObject.md

File metadata and controls

46 lines (30 loc) · 2.55 KB

BillableMetricObject

Properties

Name Type Description Notes
lagoId UUID Unique identifier of the billable metric created by Lago.
name String Name of the billable metric.
code String Unique code used to identify the billable metric associated with the API request. This code associates each event with the correct metric.
description String Internal description of the billable metric. [optional]
recurring Boolean Defines if the billable metric is persisted billing period over billing period. - If set to `true`: the accumulated number of units calculated from the previous billing period is persisted to the next billing period. - If set to `false`: the accumulated number of units is reset to 0 at the end of the billing period. - If not defined in the request, default value is `false`.
createdAt OffsetDateTime Creation date of the billable metric.
fieldName String Property of the billable metric used for aggregating usage data. This field is not required for `count_agg`. [optional]
aggregationType AggregationTypeEnum Aggregation method used to compute usage for this billable metric.
weightedInterval WeightedIntervalEnum Parameter exclusively utilized in conjunction with the `weighted_sum` aggregation type. It serves to adjust the aggregation result by assigning weights and proration to the result based on time intervals. When this field is not provided, the default time interval is assumed to be in `seconds`. [optional]
group BillableMetricGroup [optional]
activeSubscriptionsCount Integer Number of active subscriptions using this billable metric.
draftInvoicesCount Integer Number of draft invoices for which this billable metric is listed as an invoice item.
plansCount Integer Number of plans using this billable metric.

Enum: AggregationTypeEnum

Name Value
COUNT_AGG "count_agg"
SUM_AGG "sum_agg"
MAX_AGG "max_agg"
UNIQUE_COUNT_AGG "unique_count_agg"
WEIGHTED_SUM_AGG "weighted_sum_agg"
LATEST_AGG "latest_agg"

Enum: WeightedIntervalEnum

Name Value
SECONDS "seconds"