Page tree

Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

View file
nameLCR-sample.csv
height250

Overview 

Least Cost Routing (LCR) allows users to intelligently select the ITSP provider to route the traffic based on the cost for a certain destination number.

...

carriera.csv
 
 
 
carrierb.csv
 
 

SAMPLE CSV → LCR-sample.csv

 

Create LCR Carrier  

 
Go to "Configuration" -> "Routing" -> "LCR Carriers", add a new LCR carrier and then choose from "SIP Trunk/Load Balancing List" the created SIP Trunk "Trunk_To_Carrier_A":
 
 
  
Click the "Save" button:
 
 
 
Click the "Upload" button in "Carrier Rates File" to upload rate list:
 
 
 
Repeat above steps for all the rate lists.
 
 

Using the LCR Database 

Once the LCR internal database is created, you can start using LCR routing now from both the advanced and basic routing plan engines:


Basic Dial Plan

Advanced Dial Plan

<condition field="destination_number" expression="^(.*)$">
    <action application="lcr" data="$1"/>
    <action application="bridge" data="${lcr_auto_route}"/>
</condition>

 

 

e.g. when number "17771234567" is dialed and hit above routing plan, "17771234567" is passed to the lcr look up function. The lookup result is saved to channel variable "lcr_auto_route". Since the rate of "1777" from CarrierA is 0.0069 and 0.0079 for CarrierB, CarrierA will be tried first; if the carrier is not available (e.g the SIP trunk is down), then CarrierB will be tried.
 
When you change the dialed number to "17781234567", since CarrierB for "1778" is cheaper than CarrierA, then CarrierB will be tried first.
 
 

Using Load Balancing List 

If you get 2 or more SIP Trunks from the same ITSP provider, you can setup a load balancing list using the same rate list.
 
 
 
 
In the Load Balancing SIP Trunk List "SIP_Trunk_List_C", there are 2 resources: SIP Trunk C1 and C2 and you can set their "weight" to decide which one will be used more often.
 
 
 
Create an LCR Carrier using the load balancing list as the destination:
 
 

Whenever this carrier is chosen the calls will be load balanced across all SIP trunks members of the load balancing list and according to the specified weight and availability of each one.

Update of rate list for a specific LCR carrier 

Rates are always changing, when an update comes for one ITSP provider, please:
 
  1. Prepare the updated rate list CSV file
  2. Remove the out-of-date "Carrier Rates File", then all the rates related to this LCR carrier will be removed from internal database
  3. Upload the new CSV file