How to create a prepaid flow?

I want to accomplish the following tasks:

  1. Create a customer
  2. Recharge wallet with an arbitrary amount given by the user (Add products specified in the bucket equivalent to the amount recharged)
  3. Generate invoice for this payment
  4. Deduct the amount using API requests

If arbitrary amount is not possible please suggest some other flow like using bucket group and generating invoice for that.

Can you please mention which APIs need to be used to accomplish this, also how to achieve this on UI?

Edit: I also need an find the amount that needs to be charged to the user (amount given by him + the tax applicable on the specific product)

Hi Alphastar,

Firstly I want to confirm what kind of service you are trying to bill - is it a month-to-month plan which includes a quote of calls/sms or a prepaid card that can be recharged?

The general flow is that you need to:

  1. Create a plan.
  2. Create a customer with subscriber and the subscribers will be assigned a plan.
  3. You need to define products to keep track of the usages
  4. Define an input processor (available in general settings) to set how API calls should map to subscribers and products.

The amount given to users can be defined in the plan/service for postpaid and bucket/bucket group for prepaid.

For invoices - postpaid has automatic monthly invoices, for prepaid you can generate a one-time invoice with API you can see the api call example in the invoice section here:

You can read more about the prepaid entities here:

Please feel free to ask more questions if you need anything to be clarified.