The Daily Billing Process
The Daily Billing Process is an scheduled automatic task which processes and bills customer subscriptions automatically on a daily basis. The Daily Billing Process performs the recurring billing, subscription renewals, updates subscription states, and sends notifications. The Daily Billing Process processes all subscriptions for all accounts. If for an account the processing of at least one subscription fails, CloudBlue Commerce considers all the account's subscriptions unprocessed and no events are generated. The Daily Billing Process will attempt to process the failed account on the next run.
The Daily Billing Process performs the following operations:
-
It creates a list of all active accounts which have not been processed for more than one day.
-
For each account, it checks its credit terms parameters (Due Period, Grace Period, Hold Period). If one of the periods ends, the Daily Billing Process generates the corresponding events. For example, when the Hold Period ends for an account, the Daily Billing Process generates certain events which result in putting the account on hold.
-
For each subscription:
-
It requests current resource usage statistics from an external system.
-
It updates resource usage parameter values in accordance with the returned usage results and checks whether overuse occurs. If overuse occurs, it generates the corresponding events according to the subscription settings.
-
It checks the following parameters:
-
Next Billing Date: When the billing date comes, it generates the corresponding events, whose processing results in creating a billing order.
Important:
• By default, the billing date is aligned with the subscription start date. For example, if the subscription start day is the 16th of the month, it is billed on the 16th.
• A subscription also can be billed on an account statement day. For example: In the Charge Before Billing Period billing model, the Sales Order is placed and completed on 08 Jan 2021, and the statement date is the 24th.
◦ The Sales Order is calculated from 08 Jan 2021 to 08 Feb 2021. This means the Next Billing Date is 08 Feb 2021.
◦ The first Billing Order is calculated from 08 Feb 2021 to 24 Feb 2021. This means the Next Billing Date is 24 Feb 2021. -
Renew Point: If Auto-Renewal is set to Before Expiration, when the date defined by Renew Point comes, the Daily Billing Process generates the corresponding events, whose processing results in creating a subscription renewal order.
-
Expiration Date: When the subscription expiration date comes, the Daily Billing Process generates the corresponding events according to the subscription settings.
-
Grace Period: When the grace period ends, the Daily Billing Process generates the corresponding events according to the subscription settings.
-
Hold Period: When the hold period ends, the Daily Billing Process generates the corresponding events according to the subscription settings.
-
-
It checks the subscription notification schedule. If there are notifications to be sent, the Daily Billing Process generates the corresponding events, whose processing results in sending notifications.
-
Note: To make sure there are no subscriptions that failed Daily Billing Process checks, it is recommend that for every account you monitor the Last Billing Date parameter regularly.
You can customize the Daily Billing Process as provided in Tuning Daily Billing Process.