Billing for US Inter / Intra State Calls
PortaBilling® offers a simple solution for identifying and billing for US inter / intra state VoIP traffic. In order to properly apply LCR and calculate call costs in accordance to rates applied by vendors, PortaBilling® determines whether the caller resides in the same state as the called party and then applies the correct rate.
1. Clone the existing configuration.
2. From the Configuration Tree choose BillingEngine.
3. In the Groups section select the ZoneRating group.
4. Select Yes under the US_Enabled option.
5. Click the Save button and then the Verify button.
6. Verify the new configuration and click the Check / Apply button.
When a user from the United States dials a US phone number, PortaBilling® first checks if both the number calling and the called number start with a “1.” If so, then PortaBilling® searches for both destinations in the database. If these destinations are in the same state, PortaBilling® applies charges according to the intra-state rate; if the destinations are in the different states, the inter-state rates are applied.
Note, the following taxation plugins are supported in PortaBilling® to calculate customers’ taxes for the inter/intra-state calls:
· EZtax (former BillSoft);
To specify inter / intra state rates, do the following:
1. On the navigation menu on the left, select Service catalog and click Tariffs.
2. Open the tariff and click Rates.
3. On the Add rate panel, fill in the rate details:
· Destination – A destination prefix may be entered directly or you can access the destinations directory by clicking the Destination link (in the column header). Here you will find the desired prefix by country name.
· Rating mode – Select the Separate inter/intra-state rate option to enter different rates for the intra- and inter-state calls.
· First interval / Next interval – Specify the billing unit in seconds.
· Intra-state rate / Inter-state rate – Specify separate prices for intra-state and inter-state calls in the corresponding fields.
4. Click the Save.
5. Repeat these steps if you need to enter more rates.
Please consult thefor information about uploading US Inter / Intra state rates via the Rate upload wizard.
Note that for correct functionality of this feature you need to manage the NPA NXX Area Code data in the PortaBilling® database. To keep this data full and up-to-date you can purchase the NPA NXX database from one of NPA NXX database providers, convert it to an appropriate format and import it into the PortaBilling® database. The data should be imported in the following format: i_env, destination, domain in the Voice_Phone_Number_Domains table, where i_env can be zero to become available for all billing environments.
You can find an example of a NPA NXX Area Code data format in /home/porta-db/billing/schema/npanxx.sql.xz
We provide the default set of NPA NXX Area Codes that can be manually imported into the PortaBilling® mysql and Oracle databases for testing purposes. To do this, perform the following operations:
1. Login into your PortaBilling® web server using ssh.
2. Execute the following commands:
· For mysql database:
unxz --stdout npanxx.sql.xz | mysql -u root porta-billing
· For Oracle database:
unxz --stdout $NPANXX_XZ| sqlplus <login>/<password>@PMASTER
Wait until the database is being imported. It may take up to several minutes.