Update the to the latest. I've added more channel vars:<br><br>eg:<br><br>after doing:<br><br> <action application="lcr" data="12148267722 default2"/><br>(not a real number)<br><br>I get the following:<br>
<br>variable_lcr_query_digits: [12148267722]<br>variable_lcr_query_profile: [0]<br>variable_lcr_query_expanded_digits: [12148267722, 1214826772, 121482677, 12148267, 1214826, 121482, 12148, 1214, 121, 12, 1]<br>variable_lcr_route_1: [[lcr_carrier=teliax,lcr_rate=0.01000,absolute_codec_string=PCMU]sofia/gateway/teliax/12148267722]<br>
variable_lcr_rate_1: [0.01000]<br>variable_lcr_carrier_1: [teliax]<br>variable_lcr_codec_1: [PCMU]<br>variable_lcr_route_2: [[lcr_carrier=vitelity,lcr_rate=0.01440,absolute_codec_string=PCMU]sofia/gateway/vitelity/12148267722]<br>
variable_lcr_rate_2: [0.01440]<br>variable_lcr_carrier_2: [vitelity]<br>variable_lcr_codec_2: [PCMU]<br>variable_lcr_route_count: [2]<br>variable_lcr_auto_route: [[lcr_carrier=teliax,lcr_rate=0.01000,absolute_codec_string=PCMU]sofia/gateway/teliax/12148267722|[lcr_carrier=vitelity,lcr_rate=0.01440,absolute_codec_string=PCMU]sofia/gateway/vitelity/12148267722]<br>
variable_import: [lcr_carrier,lcr_rate]<br><br>which, I think is what you are asking for. If you know which route you are going to use (eg: 1) then you can get it's rate by using lcr_rate_1.<br><br>Alternatively, you can use the lcr_auto_route and then once the b-leg connects, query the b-leg variable for lcr_carrier and lcr_rate to see which one was actually used. <br>
<br>You really can't use lcr_auto_route and set a single rate since each leg can be rated differently (look at example above). <br><br>Normally lcr is used for your own rates between you and your carrier. That is independant of the rate table used for your customers. You can use lcr to query both. First use lcr to query your own rates using a different profile. This would return a *single* route if you setup your route table right. Save the rate in a var to be used with nibble bill. Then use lcr with your external rates so you can route according to your own cost with your carrier(s).<br>
<br><div class="gmail_quote">On Thu, Apr 2, 2009 at 5:22 AM, Yuriy Ivzhenko (WP) <span dir="ltr"><<a href="mailto:yivzhenko@mksat.net">yivzhenko@mksat.net</a>></span> wrote:<br><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">
Hi,<br>
<br>
I want to use module lcr to find a best route and his rate , then make a call<br>
and bill on that rate with nibblebill module.<br>
<br>
lcr return variable "lcr_auto_route" that contains "[lcr_rate=xxx]" variable<br>
for new channel.<br>
To use nibblebill i need to set "nibble_rate" = "lcr_rate".<br>
<br>
What is best method to do that?<br>
Is there a way to do that with standard tools, without use external scripts?<br>
<br>
<br>
Thanks,<br>
Yuriy<br>
<br>
_______________________________________________<br>
Freeswitch-users mailing list<br>
<a href="mailto:Freeswitch-users@lists.freeswitch.org">Freeswitch-users@lists.freeswitch.org</a><br>
<a href="http://lists.freeswitch.org/mailman/listinfo/freeswitch-users" target="_blank">http://lists.freeswitch.org/mailman/listinfo/freeswitch-users</a><br>
UNSUBSCRIBE:<a href="http://lists.freeswitch.org/mailman/options/freeswitch-users" target="_blank">http://lists.freeswitch.org/mailman/options/freeswitch-users</a><br>
<a href="http://www.freeswitch.org" target="_blank">http://www.freeswitch.org</a><br>
</blockquote></div><br><br clear="all"><br>-- <br>-Rupa<br>