Five-step billing workflow
1. Usage ingestion
Events provide information about your customers’ consumption, with the highest level of granularity. Any product feature for which you want to charge your customers should correspond to a specific event. An event can be triggered by an action or can be sent periodically. Lago is able to ingest events at scale while preventing duplicates.2. Metrics aggregation
The aggregation process consists in converting events into billable metrics. There are 4 aggregation types:Aggregation | Description | Type |
---|---|---|
COUNT | Counts the number of times an incoming event occurs | Metered |
COUNT_UNIQUE | Returns the number of unique values of a predefined property for incoming events | Metered or Recurring |
LATEST | Returns the lastest value of a predefined property for incoming events | Metered |
MAX | Returns the maximum value of a predefined property for incoming events | Metered |
SUM | Calculates the sum of a predefined property for incoming events | Metered or Recurring |
WEIGHTED SUM | Calculates the sum of a predefined property for incoming events prorated based on time used per period | Metered or Recurring |