Create Recurring Billing Config
Create a recycling plan configuration
Header Parameters
random 16 bytes alphanumerics
Please follow the OpenAPI authentication section
Please follow the OpenAPI authentication section
Request Body
-
The number of intervals between recurring billings. For example, billing_interval=monthly and billing_interval_counts=3 , then system bills every 3 months.
-
If billing_interval=monthly and billing_interval_counts=1 , then system bills every 1 month.
-
If billing_interval=yearly and billing_interval_counts=1 , then system bills every 1 year.
- Single option choice: [daily], [weekly], [monthly], [annually]
-
This is to determine if the system will apply automated billing date/time based on the current date/time of when the user subscribes to the recurring plan.
-
Single option choice: [automated], [customized]
-
[automated]: the system will select the current calendar date/time to be the start date of the recurring billing cycle. For example, if user is subscribing on 1st March 2024, and billing_interval= yearly and billing_interval_counts =1 ; then, user will be issued with a billing invoice of 1st March 2024 - 1st March 2025.
-
If if user is subscribing on 1st March 2024, and billing_interval= monthly and billing_interval_counts =2 ; then, user will be issued with a billing invoice of 1st March 2024 - 1st May 2024.
-
If if user is subscribing on 1st March 2024, and billing_interval= weekly and billing_interval_counts = 2 ; then, user will be issued with a billing invoice of 1st March 2024 - 15th March 2024.
- [customized]: if user chooses this option, depending on which data is set in billing_interval , they will need to configure billing_month ; billing_day_of_month . This option is only applicable for when billing_interval = monthly/yearly .
- The data is as below:
- 1 = January
- 2 = February
- 3 = March
- 4 = April
- 5 = May
- 6 = June
- 7 = July
- 8 = August
- 9 = September
- 10 = October
- 11 = November
- 12 = December
- The data is as below:
- 1 = 1st of that month
- 2 = 2nd of that month
- 3 = 3rd of that month
- 4 = 4th of that month
- 5 = 5th of that month
- 6 = 6th of that month
- 7 = 7th of that month
- 8 = 8th of that month
- 9 = 9th of that month
- 10 = 10th of that month
- 11 = 11th of that month
- 12 = 12th of that month
- 13 = 13th of that month
- 14 = 14th of that month
- 15 = 15th of that month
- 16 = 16th of that month
- 17 = 17th of that month
- 18 = 18th of that month
- 19 = 19th of that month
- 20 = 20th of that month
- 21 = 21st of that month
- 22 = 22nd of that month
- 23 = 23rd of that month
- 24 = 24th of that month
- 25 = 25th of that month
- 26 = 26th of that month
- 27 = 27th of that month
- 28 = 28th of that month
- 29 = 29th of that month +30 = 30th of that month
- 31 = 31st of that month (if there is no 31st in a month, then automatically default to 30th/29th/28th respecitvely)
-
This data field is let the system knows if needs to calculate prorated amount, if the customer is entering a recurring cycle that is not a full cycle period.
-
For example, user starts the subscription on 1st April 2024, but the billing cycle is billing_interval= monthly and billing_interval_counts = 1 , and also billing_day_of_month= 31 . If billing_proration_enabled= False, then the system will calculate the payment to be paid from 31st March 2024 - 30th April 2024 (since there is no 31st April). The billing amount will be full amount expected to be paid in that cycle. The system will issue a billing invoice for customer to pay for recurring period of 1st April 2024 - 30th April 2024. The invoice’s billing start date will be 1st April 2024 00:00:00, and this should consider as one count for recurring_cycles.interval_counts
-
If billing_proration_enabled= TRUE, then check the above examples described in billing_day_of_month , billing_month
config object required
‒ The frequency at which a recurring invoice is billed to the customer.
‒ [daily] - The invoice will be billed on daily basis
‒ [weekly] - The invoice will be billed on weekly basis
‒ [monthly] - The invoice will be billed on monthly basis
‒ [annually] - The invoice will be billed on annually basis
Possible values: [automated
, customized
]
- 200
Response Headers
Schema
data object required
config object required
{
"code": 0,
"message": "string",
"data": {
"config": {
"id": "string",
"p_business_id": "string",
"interval_count": 0,
"billing_interval": "string",
"billing_config_settings": "string",
"billing_month": 0,
"billing_day_of_month": 0,
"billing_proration_enabled": true,
"description": "string",
"created_at": "string",
"updated_at": "string",
"deleted_at": "string"
}
}
}