Overview
This guide explains how to set up credits auto-recharge for prepaid, usage-based billing in Stigg. In a prepaid credits model, customers purchase credits upfront and consume them as they use your product. Auto-recharge extends this model by automatically replenishing credits when a customer’s balance drops below a defined threshold, ensuring uninterrupted usage while enforcing strict spending limits. Auto-recharge is one of several ways to manage credit replenishment and is best suited for customers who want continuous access without manual top-ups. By the end of this guide, you’ll have:- A credit-based pricing model
- An initial prepaid credit balance
- Auto-recharge configured to maintain a rolling balance over time
When to use auto-recharge
Auto-recharge is ideal for:- Usage-based products with continuous consumption
- API-driven or automation-heavy workloads
- AI or compute-based services
- Customers who want predictable spend without service interruptions
Credit lifecycle overview
Before diving into setup, it’s helpful to understand how credits and auto-recharge behave over time:- Customers are granted an initial prepaid credit balance.
- Credits are consumed as usage is reported.
- When the balance drops below a threshold, Stigg triggers an automatic recharge.
- Credits are granted up to a target balance and billed using the selected payment method.
- Auto-recharge pauses automatically when the monthly spend limit is reached or if a payment fails.
Example credit model
This guide uses the following example:- Credits are consumed per API call
- Customers start with an initial prepaid credit balance
- When the balance drops below 20 credits, it is automatically recharged back up to 50 credits
- Auto-recharge spending is capped at $500 per month
Prerequisites
Before enabling auto-recharge, ensure that:- A credit type is configured
- Usage is metered through meter-based features
- Customers have an active payment method on file
- An initial credit balance has been granted
Step 1: Create a product
The product represents the commercial offering that will contain your credit-based usage.- Go to Product catalog → Products.
- Click + New product.
- Select Single active subscription.
- Give the product a name.
- Click Create.
Step 2: Create meter-based features
Credits are consumed by meter-based features.- Go to Product catalog → Features.
- Click + New feature.
- Configure the feature:
- Name – Display name shown in the UI
- Description (optional) – What the feature enables
- Feature type – Select Meter
- Meter type – Select Calculated usage
- Unit names – For example, request / requests
- (Optional) Enable Feature is sold in different units if required.
Step 3: Create a prepaid credit plan
This plan is used to grant customers an initial credit balance.- Go to Product catalog → Plans.
- Click + New plan.
- Select the product you created.
- Give the plan a name (for example, Prepaid credits).
- Click Create.
Step 4: Configure pricing
- Go to Product catalog → Plans.
- Select the plan.
- In the Price section, click + Set.
- Select Paid.
- Choose One-time as the billing model.
- Click Continue.
Step 5: Configure credits
This step defines how many credits are granted to the customer upfront. Under Charges:- Select Credits.
- In Credit type, select Credits (Credits).
- Choose a pricing model (for example, Flat or Stairstep).
- Define the number of credits granted (for example, 50 credits).
- Set the price for the credit grant.
- Click Add to save the charge.
Step 6: Grant credits to a customer
- Go to Customers → Customer accounts.
- Select a customer.
- In the Subscriptions section, click + Add.
- Select the product.
- Select the prepaid credit plan.
- Add a billing method.
- Click Create.
Step 7: Enable auto-recharge
Once a customer has a credit balance, you can configure auto-recharge.Credit usage per customer
- Go to Customers.
- Select a customer.
- Go to the Credits tab.
Auto-recharge settings
- Click Manage in the Auto-recharge widget.
- In When credit balance goes below, enter the credit balance that triggers auto-recharge, such as 30.
- In Then bring credit balance back up to, enter the target balance after recharge.
- In Limit total monthly spend to, enter the maximum amount that can be charged per month.
- Select a reset interval in Spend limit resets every.
- Select a duration in Grant expiration.
- Select a payment method under Payment method.
- Click Save settings.
Step 8: Monitor credit usage
You can monitor how customers consume and recharge credits over time.- Go to Customers → Customer accounts.
- Select a customer.
- Open the Credits tab.
- Current credit balance
- Credit consumption
- Auto-recharge spend for the current month
If the monthly spend limit is set lower than the customer’s current spend for the month, auto-recharge will be disabled and no additional credits will be recharged until the limit is increased or the spend limit resets.
