Skip to content

Commit fcfb35b

Browse files
committed
metering: Update doc to clarify use of metering APIs
1 parent 20bea14 commit fcfb35b

File tree

1 file changed

+6
-4
lines changed

1 file changed

+6
-4
lines changed

userguide/aviate/aviate-metering.adoc

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -4,9 +4,9 @@ include::{sourcedir}/aviate/includes/aviate-card.adoc[]
44

55
== Introduction
66

7-
The Aviate plugin offers metering capabilities. The https://apidocs.killbill.io/usage[Kill Bill core usage APIs] support recording rolled-up usage data. However, any required aggregation must be performed outside Kill Bill. With the introduction of the metering feature, aggregation can now occur directly within Kill Bill. Thus, this feature allows users to be charged based on aggregated units seamlessly.
7+
The Aviate plugin offers metering capabilities. The https://apidocs.killbill.io/usage[Kill Bill core usage APIs] support recording rolled-up usage data, but aggregation must be performed outside Kill Bill. With the introduction of the metering feature, aggregation can now occur directly within Kill Bill by using the metering APIs. Thus, this feature allows users to be charged based on aggregated units seamlessly.
88

9-
The Aviate Metering feature introduces the concept of a https://killbill.github.io/slate/aviate-metering-apis.html#billingmeter[BillingMeter] and a https://killbill.github.io/slate/aviate-metering-apis.html#usageevent[UsageEvent]. A `BillingMeter` encapsulates information about how usages should be aggregated. A `UsageEvent` represents a single usage. Each `UsageEvent` has an associated `BillingMeter`. The `UsageEvents` are then aggregated based on the aggregation type specified in the associated `BillingMeter`.
9+
The Aviate Metering feature introduces the concept of a https://killbill.github.io/slate/aviate-metering-apis.html#billingmeter[BillingMeter] and a https://killbill.github.io/slate/aviate-metering-apis.html#usageevent[UsageEvent]. A `BillingMeter` encapsulates information about how usage points should be aggregated - e.g. sum all points within a specific period. A `UsageEvent` represents a single usage point. Each `UsageEvent` has an associated `BillingMeter`. The `UsageEvents` are then aggregated based on the aggregation type specified in the associated `BillingMeter`.
1010

1111
== Getting Started with Aviate Metering
1212

@@ -29,11 +29,13 @@ Refer to the https://docs.killbill.io/latest/userguide_configuration.html[__Kill
2929

3030
=== Using Metering APIs
3131

32-
Once the aviate plugin is installed and the metering feature is enabled, you can start using the Aviate Metering APIs. These APIs enable creation of billing meters and usage recording. They are documented in our https://apidocs.killbill.io/aviate-metering[api docs].
32+
Once the aviate plugin has been installed and the metering feature is enabled, you can start using the Aviate Metering APIs. These APIs enable creation of billing meters and allow to record raw (non aggregated) usage points. These APIs replace the https://killbill.github.io/slate/usage.html#record-usage-for-a-subscription[Kill Bill usage APIs]: Users should either use existing Kill Bill usage APIs (to record aggregated usage points) or use the Aviate metering APIs discussed in this section. For more details about these APIs, please refer to our https://apidocs.killbill.io/aviate-metering[api docs].
33+
34+
Note that in the current implementation, the caller should ensure that all usage points for a specific subscription should be serialized.
3335

3436
== A Metering Example
3537

36-
This section explains how metering works with an example.
38+
This section explains how metering works with an example. We also provide a https://docs.killbill.io/latest/aviate-usage-ai-tutorial[tutorial] with step by step examples.
3739

3840
Assume that we would like to track the cellphone minutes consumed by a user. We can create a `BillingMeter` as follows:
3941

0 commit comments

Comments
 (0)