How does invoicing work in PortaBilling?

Link copied to clipboard

PortaBilling provides a ready-to-use invoice function. You can design how your invoices will look. Internal invoices are created automatically based on calls the customer has made. To generate and store invoices as .pdf files, the administrator must enable this functionality. The invoices can be automatically emailed to the customer (if this option is enabled and the customer has an email address set up in his properties). The invoices can be viewed online or printed via the administrator and customer self-care web interfaces.

Who is invoiced?

Link copied to clipboard

Only customers (both resellers and retail customers) are invoiced, since only they have all the information required for invoicing, such as address, taxpayer ID, and so forth. Individual accounts are not invoiced.

How often?

Link copied to clipboard

Each customer has his own billing period, which could be:

  • Daily
  • Weekly
  • Semimonthly
  • Monthly (anniversary or on the first day of every month)
  • 30 calendar days.

When the current billing period is over (for example, on the first day of the month) a summary of all the calls made by the customer is calculated. Customer call statistics are generated and stored on the server (optionally, they can also be mailed to the customer automatically) and an invoice is created.

Note that the billing period is based on the customer’s time zone. For example, if the customer has a weekly billing period and his time zone is Australia/Melbourne, his statistics would cover the period from 24-Mar-2009 00:00 Melbourne time (23-Mar-2009 14:00 GMT) until 31-Mar-2009 00:00 Melbourne time (30-Mar-2009 14:00 GMT). For another customer, who also has a weekly billing period but is in the New York time zone, this billing period will cover calls made from 24-Mar-2009 00:00 New York time (24-Mar-2009 05:00 GMT) to 31-Mar-2009 00:00 New York time (30-Mar-2009 14:00 GMT).

When are PortaBilling invoices generated?

Link copied to clipboard

Statistics are generated with a sufficient delay to make sure that the billing period for a particular customer (according to that customer’s time zone) has ended. Also, statistics calculation takes place only at a certain time of day (usually during night hours, when there is the least amount of activity in the system). Weekly invoices cover Monday through Sunday. Assuming that your system does statistical calculation from 2am until 8am Central European Time every day, then statistics for those customers whose time zone is in Asia or Europe should be available each Monday morning. For customers with a time zone in the US, the billing period will not have ended yet when statistics are calculated on Monday morning; thus they are created on Monday night and made available Tuesday morning.

It might occur that in the middle of a billing period, a customer wants to pay for services consumed and does not want to wait until the end to receive an invoice. For such customers, administrators may generate a midterm invoice. For example, a customer with a monthly billing period wishes to pay for services consumed up to the 13th of May. On the 14th of May, the administrator generates a midterm invoice for this customer, which covers the period from the 1st of May until the 13th of May. The midterm invoice is generated within the hour.

Sometimes invoices for extra services such as a technician visit or an equipment purchase need to be provided at the time when such service is rendered so the customer can immediately proceed with payment. The administrator can generate an out-of-turn invoice (to cover only a few specific items) on demand. The out-of-turn invoice is generated immediately.

More detailed information about midterm and out-of-term invoices can be found in the PortaBilling Administrator Guide.

Invoice total

There are two methods available for calculating the invoice total:

All charges during the period

This is the simpler method – the invoice contains all of the call charges for the specified period, with the invoice total equaling the sum of these charges. Balance adjustments, refunds, and payments made by a customer via the online payment system are not included, since these refer to transactions that have already been made and will not occur again. So, for example, if during August a customer makes calls for $120 and pays $100 for his services in July on August 10, his invoice will show $120. Of course, the customer’s payment will be recorded in the system and will affect his balance.

Including the previous balance

The invoice total will be calculated as:

  • Previous invoice total
  • + Sum of all charges during the period (call-related or manual charges)
  • - Sum of all payments or refunds made during the period.

So, taking our previous example: if the customer’s invoice for July was $110, and he paid $100 and made calls for $120 during August, his total on the August invoice will be $110 + $120 - $100 = $130

Invoicing modes are controlled by the New_Style_Invoice_Calculation configuration option.

Basis of invoices

Link copied to clipboard

For a reseller, the call charges on the invoice are based on the sum total of all his xDRs in a given period.

For a retail customer, the call charges on the invoice are the sum total of all xDRs (call charges and maintenance fees) for this customer’s credit accounts. Debit accounts are prepaid, and so since they have been already paid in full there is no need to invoice these calls.

Void invoices

Link copied to clipboard

It sometimes happens that an error is detected after an invoice has been generated and delivered to the customer. A new invoice must be produced, but the old one must be kept for audit purposes. The void invoice operation marks the invoice as canceled (this will also be visible in the .pdf file), and then a new invoice is automatically produced.

Invoice recalculation

Link copied to clipboard

This process voids an existing invoice and generates a new one in its place.

Invoices review

Link copied to clipboard

In order to provide your customers with correct invoices, PortaBilling allows you to review invoices before sending them to your customers. The administrator reviews the invoices and then approves them, or if necessary, performs balance adjustments (for example, to correct an invoice total) or sends them to be regenerated (if, for example, the administrator has additional reasons to update the invoice). Only after that step, the invoices are delivered via email to your customers. You can enable this feature for a specific customer class. At the end of the billing period, the invoices will be created but not yet sent to the customers, pending approval.

Enable invoice review

Filter invoices with Under review status

The review status of an invoice is displayed as part of the invoice record in the database. The following statuses are possible:

  • Under review – a created invoice requires an administrator’s approval. The administrator can filter invoices by Under review status on the web interface.
  • Approved – the administrator has approved the invoice and it is automatically sent to a customer via email. The invoice keeps the Approved status on the web interface until one of the payment statuses is applied. For instance, the Approved status changes to Unpaid or Paid.
  • Rejected – if the administrator chooses to re-issue the invoice and postpones its processing to the nearest off-peak hours, the invoice status is Rejected until the processing is done. Once the invoice is re-issued, the status is Under review again, and the invoice is available for re-approval.

The invoices review functionality can be used for the following situations:

  • Billing of premium customers – with your premium customers, you naturally want to provide them with high-quality services. Invoices are no exception. You want to be sure that all charges are included and that the invoice total is calculated accurately.
  • Billing of a new service – an administrator creates a new service with new ratings, tariffs, products and invoice templates. If they are not sure whether all the new charges are correctly calculated they can activate the Send invoice after review and approval by administrator option for the specific customer class. Only after the administrator checks and approves the invoices are they delivered to customers via email.
  • Changes in templates – if during invoice review an administrator discovers that a template must be adjusted, they change the template. Then on the Invoices page the administrator selects all of the “under review” invoices that were created using this template and regenerates new ones. They are then sent for a second review.

If the “auto-charge credit card” functionality is enabled together with the “review invoices” functionality, then the credit card will be charged after the administrator’s approval of the invoice. To prevent situations where invoice review has not been performed there is an additional field that defines how many days the invoices remain under review before they are auto-approved by PortaBilling. Each day administrators, who belong to the corresponding mailing list, receive an email with a list of all the invoices to be reviewed. If an invoice is not reviewed by the end of the specified period, it is automatically approved and sent to the customer. An email with a list of all auto-approved invoices is sent to the administrators who belong to the corresponding mailing list.

Adjusting invoices under review

Link copied to clipboard

When an administrator reviews invoices they can apply balance adjustments to be included on the current invoice. They specify the amount and the date of the balance adjustment that is covered by the most recent billing period. ‎

Example

The administrator reviews a March invoice with an invoice total of $150, notices a human error (a $100 subscription is charged, but it should have been free this month according to the agreement). They click Adjust, select the type of transaction Manual credit, and apply a $100 credit to the customer. The invoice is then automatically scheduled for recalculation/regeneration. After that, the invoice shows a credit of $100, and the invoice total is $150-$100=$50.

On this page

Release
What's new
Admin manuals
Handbooks
Developers documentation
UI help