LCR routing problem


I am testing the outbound calls and find a huge problem in LCR routing. I doubt whether my set up is wrong or it is a general problem that is not yet fixed.

So, the LCR chooses the longest prefix among all providers, but it does not compare the price of EACH PROVIDER’S longest prefix. We all know that i.e. 4177 at “Provider_1” can be cheaper than 41772 at “Provider_2”.

I, of course, tried the COST type instead, but it shows you the numbers out of reality. It shows in your billing that all calls pass by cheapest available prefix (which is usually simply the country prefix), while your provider bills you pretty much higher (if you call to mobiles for example).

Could you please check and let me know if my setup is wrong and system is supposed to function differently? I attach an image with real example of rates and dialing number for better understainding of the issue I face.

Thanks in advance for your help! Best regards

Hello @Genia ,

Mr @devangn has given answer same:

Please go through with below video once

Hello @hemdip.badani ! Thanks for clarification! It is now clear that correct (for us) way of LCR is a subject of Enterprise solution. Thanks for the info!

To achieve this in ASTPP 4.0.1 Community edition, replace the get carrier rates function in /opt/ASTPP/freeswitch/scripts/astpp/lib/astpp.functions.lua with the contents of the following pastebin entry then ensure your routing type is set to LCR.