Automatic invoicing

From ISPWiki
Jump to: navigation, search

Starting from version 5.57.0 BILLmanager supports automatic invoicing for customers. This feature can be activated in the Global settings module.

This feature enables to facilitate invoicing for clients. A client won't need to generate an invoice manually, BILLmanager will create the invoice automatically for a required amount when his service should be prolonged.

What services can be invoiced automatically?

Automatic invoices can be generated only for services with daily charges, and monthly charges provided that automatic renewal is enabled for such monthly services.

When the billing system generates an invoice?

The billing panel estimates for how many days a client has funds on his account. Information is taken from the LowMoneyNoticePeriod parameter in the BILLmanager configuration file. The default value is 10 5 4 3 2 1 0 days.

10 days before a service expiration date, BILLmanager creates an invoice for service renewal. The invoice will include all services that should be prolonged for the next month starting from their suspension date.

Invoices are generated automatically with the command:

/usr/local/mgr5/sbin/billmaintain --command warnmoney

Running this command will re-send a "Low-balance of account" notification.

What is the invoice amount?

This is a service renewal amount starting from a planned suspension date (date when the client will have insufficient funds on his account) + 1 month.

Payment method

A payment method is selected based on the last 5 payments. If a client made payments by credit card, it will be selected for automatic invoicing. If BILLmanager could not define a payment method or it was not wire transfer, a payment method won't be set, and a client will be able to choose it himself during the payment process.

If BILLmanager could not define a payment method or it was not wire transfer, an invoice will have number - pfx/<number>, despite the number settings selected in the Company configuration form. Once a payment method is selected, the invoice number will change according to company's settings.

The second invoice will be sent in 2 weeks or after the first one is paid. It will be also generated, if you delete the payment (this operation is available only to admin).

Example

Let's say, today is June 1, and client will run out of funds on June 10. The client has 5 active services:

  • Shared-hosting with daily charges. Monthly renewal price - 50 euro.
  • Domain name with automatic renewal activated for 1 year. The service expiration date is June 25. Yearly renewal price is 150 euro.
  • VPS#1 with automatic renewal activated for 1 month. The service expiration date is June 21. Monthly renewal price - 200 euro.
  • VPS#2 with disabled automatic renewal.
  • Dedicated with automatic renewal activated for 3 months. The service expiration date is July 15.

On June 1, BILLmanager will see that client will run out of money on June 10. Then, it will find the services that should be prolonged during that period, June 10 till July 10. The following services will be selected:

Shared-hosting, domain name, and VPS#1.

Automatic renewal is not activated for VPS#2, that's why the invoice for this service won't be generated. Our dedicated server will expire on July 15, which is not included into that month, so the service won't be included into invoice.

Therefore, on June 1 an invoice for 400 euro will be generated for renewal of the following services:

  • Shared-hosting
  • Domain name
  • Virtual server#1

How notifications are sent

the configuration file contains the following parameter:

LowMoneyNoticePeriod - how many days will pass before the "insufficient funds' notification will be sent. The default value is 10 5 4 3 2 1 0.

The notification WON'T BE SENT, if the post-paid services option is activated. If the option is set, the notifications will be sent only on the 1st day of the month, when the billing system generates a new invoice for the previous month.