From d907821f1276b5e9e93e39e5f42498e429fad6c8 Mon Sep 17 00:00:00 2001 From: stephane brossier Date: Fri, 11 Apr 2025 16:50:31 -0700 Subject: [PATCH 1/2] aviate index: Improve index MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit • Remove redundant 'Aviate' so titles better fit • Reorder sections --- html5/_main_toc.html.slim | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-) diff --git a/html5/_main_toc.html.slim b/html5/_main_toc.html.slim index f2aa60850..dbeda2a9d 100644 --- a/html5/_main_toc.html.slim +++ b/html5/_main_toc.html.slim @@ -347,21 +347,21 @@ nav.sidebar-nav li a.nav-link href="/latest/what_is_aviate.html" | What is Aviate? - li.bd-sidenav-active - a.nav-link href="/latest/aviate-custom-invoice-sequencing.html" - | Aviate Custom Invoice Sequencing li.bd-sidenav-active a.nav-link href="/latest/how-to-install-the-aviate-plugin.html" - | Aviate Plugin Installation - li.bd-sidenav-active - a.nav-link href="/latest/aviate-catalog-plugin.html" - | Aviate Catalog + | Plugin Installation li.bd-sidenav-active a.nav-link href="/latest/aviate-health.html" - | Aviate Health + | Health + li.bd-sidenav-active + a.nav-link href="/latest/aviate-custom-invoice-sequencing.html" + | Custom Invoice Sequencing + li.bd-sidenav-active + a.nav-link href="/latest/aviate-catalog-plugin.html" + | Catalog li.bd-sidenav-active a.nav-link href="/latest/aviate-metering.html" - | Aviate Metering + | Metering li .icon-title a.bd-toc-link.main-link role="button" From 4343e33fabaed7a6c1a9fffb6c12898d98d227b1 Mon Sep 17 00:00:00 2001 From: stephane brossier Date: Mon, 14 Apr 2025 15:58:37 -0700 Subject: [PATCH 2/2] aviate wallet: Add documentation for aviate wallet --- html5/_main_toc.html.slim | 3 ++ userguide/aviate/aviate-wallet.adoc | 44 +++++++++++++++++++++++++++++ 2 files changed, 47 insertions(+) create mode 100644 userguide/aviate/aviate-wallet.adoc diff --git a/html5/_main_toc.html.slim b/html5/_main_toc.html.slim index dbeda2a9d..d1445019d 100644 --- a/html5/_main_toc.html.slim +++ b/html5/_main_toc.html.slim @@ -362,6 +362,9 @@ nav.sidebar-nav li.bd-sidenav-active a.nav-link href="/latest/aviate-metering.html" | Metering + li.bd-sidenav-active + a.nav-link href="/latest/aviate-wallet.html" + | Wallet li .icon-title a.bd-toc-link.main-link role="button" diff --git a/userguide/aviate/aviate-wallet.adoc b/userguide/aviate/aviate-wallet.adoc new file mode 100644 index 000000000..1e94cea5b --- /dev/null +++ b/userguide/aviate/aviate-wallet.adoc @@ -0,0 +1,44 @@ += Aviate Wallet + +include::{sourcedir}/aviate/includes/aviate-card.adoc[] + +== Introduction + +The Aviate plugin enables the management of Account wallets — credit pools that can be replenished manually or automatically based on configurable criteria. These credits are consumed by the system to pay for usage, and the wallet mechanism is primarily intended for prepaid scenarios. This helps mitigate financial risk typically associated with billing for usage in arrears. + +Credits can be granted either for free or as part of a payment. In the latter case, a Kill Bill invoice is generated and a payment is processed using the Account’s default payment method. An optional expiration date can be assigned to credits. If the payment fails, the credit is recorded but remains inactive; it is only activated once the payment against the invoice is successfully completed. + +Wallets can be configured with automatic replenishment rules (top-off), which support two modes: restoring the balance to a target level or adding a fixed amount when the balance falls below a threshold. These automatically granted credits can also include an expiration date. Additionally, wallets can be initialized with a predefined amount of free or paid credits. + +The wallet is implemented as a ledger that tracks all transactions, including credit additions and consumptions. It exposes two values: the `balance`, representing currently available credits, and the `live balance`, which includes credits reserved for pending invoice generation. + +Currently, each customer Account supports a single wallet, and the wallet must use the Account’s default currency. + +== Getting Started with Aviate Wallet + +This section provides a step-by-step guide to start using the Aviate Wallet functionality. + +=== Installing the Plugin + +Install the Aviate plugin as described in the https://docs.killbill.io/latest/how-to-install-the-aviate-plugin.html[How to Install the Aviate Plugin] guide. + +=== Enabling Aviate Wallet + +To enable wallet functionality in the Aviate plugin, start Kill Bill with the following system property: + +[source,bash] +---- +com.killbill.billing.plugin.aviate.enableWalletApis=true +---- + +For details on setting configuration properties, refer to the https://docs.killbill.io/latest/userguide_configuration.html[Kill Bill Configuration Guide]. + +=== Using Wallet APIs + +Once the plugin is installed and wallet support is enabled, you can interact with the Aviate Wallet using its API. The API allows you to create wallets, add credits, and configure top-off rules. Full API documentation is available at https://apidocs.killbill.io/aviate-wallet[our API documentation]. + +== Using the Wallet Functionality + +1. Create a wallet for a customer Account, optionally specifying initial credits (free or paid) and top-off rules. +2. Record usage events. The system automatically adjusts the balance and enforces top-off rules as configured. +3. Optionally, manually add credits or update the top-off configuration to better suit your use case.