Skip to main content
Enso’s metering system is designed to help you track and bill for usage-based metrics. Understanding the core concepts—events, meters, usage, and invoices—is essential for modeling your billing accurately.

Key Concepts

Events

Events are individual records of activity that represent something happening in your product (e.g., a user logs in, an email is sent, data is stored).
Events are typically sent to Enso via API or uploaded as CSV files.
Example event log (CSV):

Meter / Metric

A meter (or metric) defines what you want to measure and bill for.
A meter aggregates events over a given period (such as daily, monthly, or quarterly) to produce a usage value that can be invoiced.

Meter Properties

  • Aggregation Method:
    Determines how events are combined to calculate usage.
    Common methods:
    • sum (total usage)
    • count (number of events)
    • max (peak usage)
    • min (lowest usage)
    • cumulative_start (running total from a start date)
    • cumulative_end (running total until a reset date)
    If you choose a cumulative aggregation method (cumulative_start or cumulative_end), you can configure when the meter resets using these fields:
    • resetType:
      • none (never reset)
      • annual (reset every year)
      • monthly (reset every month)
      • custom (reset on a custom date)
    • monthOfReset:
      Required if resetType is annual. Select the month when the reset should happen.
    • dayOfReset:
      Required if resetType is annual or monthly. Select the day of the month for the reset.
    • customDate:
      Required if resetType is custom. Specify the exact date for the reset.
    These options allow you to create meters that automatically reset their aggregation on an anniversary, monthly, or custom schedule.
  • Window Options:
    Defines the time period over which events are aggregated.
    Common windows:
    • Daily
    • Monthly
    • Quarterly
  • Filters:
    Allow you to include only specific events in your metric calculation.
    You can filter on event fields (e.g., browser, region) using logical conditions.
    Example filter (JSON):
Examples of meters:
  • Monthly active users (aggregates login events per month)
  • GB of storage used (aggregates storage events per month)
  • Emails sent (aggregates email events per month)
  • Quarterly API calls (aggregates API call events per quarter)
Meter structure diagram:

Usage

Usage is the result of aggregating events for a meter over a specific time window.
Usage is what appears on the invoice for each customer.

How It All Connects

Below is a diagram showing the relationship between events, meters, usage, and invoices:
  • Events are raw activity logs.
  • Meters aggregate events using defined methods, windows, and filters.
  • Usage is the aggregated value for a customer and period.
  • Invoices are generated based on usage.

Summary Table


Tip:
Events, meters, and usage are the foundation of usage-based billing in Enso.
Understanding their relationship is key to accurate and flexible billing.