[Freeswitch-users] Polycom auto answer on active call

Spencer Thomason spencer at 5ninesolutions.com
Fri May 18 00:04:02 MSD 2012


Hello,
You can use the following to track all calls placed to a registered user:

I use the following dial-string:
                <params>
                        <param name="dial-string" value="{limit=${uuid_limit(${uuid} hash ${dialed_domain} ${dialed_user})},sip_invite_domain=${domain_name},presence_id=${dialed_user}@${dialed_domain}}${sofia_contact(${dialed_user}@${dialed_domain})}"/>
                </params>


I will update the wiki.

Thanks,
Spencer


On May 17, 2012, at 12:03 PM, Spencer Thomason wrote:

> Yes,
> The main problem I'm have trouble with is tracking calls from a hunt group.  I use a lua script to call multiple users at once.  For example:
> session:execute("bridge", "[leg_timeout=30]user/1001@"..domain_name..",".."[leg_timeout=30]user/1002@"..domain_name..",".."[leg_timeout=30]user/1003@"..domain_name);
> 
> It is impossible to know which user will be on the phone before the lua script is called.  I can execute an api application from the directory dial-string but I am unaware of a way to execute another dialplan application from there.  Since there is no transfer, I cannot do something like:
> <action application="limit" data="hash ${domain_name} ${dialed_extension} 100"/>
> before 
> <action application="bridge" data="user/${dialed_extension}@${domain_name}"/>
> 
> I hope that helps explain my problem :-)
> 
> Thanks,
> Spencer
> 
> 
> On May 17, 2012, at 11:49 AM, Yehavi Bourvine wrote:
> 
>> Sorry, I did not understand what you exactly mean. Can you give some example?
>>  
>> About the bridge application - you have to check it in each bridge call, or do one centralized check before you enter the logic of the dialplan: If the user is above limit - make it busy; if not, continue with the dialplan as usuall.
>>  
>>                                 __Yehavi:
>> 
>> 2012/5/17 Spencer Thomason <spencer at 5ninesolutions.com>
>> The problem is that I have now way of incrementing the number of calls that limit is keeping track of from an API command.  I believe that I need to increment the call count from the directory dial-string because there are several places an extension could be called with a bridge directly to the user (i.e. bridge/user@${domain_name}) as apposed to a transfer.  If a call is transferred then I can call the dialplan application limit before the bridge to the user and everything works great.  Is there a way I can call a dialplan application from the directory dial-string?  or is there any other way to make sure that limit is called on every bridge to a registered user?
>> 
>> Thanks again,
>> Spencer
>> 
>> 
>> On May 17, 2012, at 9:52 AM, Yehavi Bourvine wrote:
>> 
>>> You can call mod_limit by yourself or at the dialstring. Mod_limit counts all calls to/from an extension, so it is quite accurate.
>>>  
>>> For example, we use:
>>>  
>>>       <action application="bridge" data="${cond(${limit_usage(max_calls ${destination_number})} > ${MaxLimit} ?  error/user_busy : ${RingAt})}" />
>>> Which either returns "user busy" or calls the extension.
>>>  
>>>                              __Yehavi:
>>> 
>>> 2012/5/17 Spencer Thomason <spencer at 5ninesolutions.com>
>>> Thanks that should work.  How did you keep track of the calls?  Calls from an extension are easy enough but an extension can be called many ways, i.e. hunts groups, transfers, etc that would need to be accounted using limit.  Could you do this by modifying the dial-string?
>>> 
>>> Spencer
>>> 
>>> On May 17, 2012, at 9:09 AM, Yehavi Bourvine wrote:
>>> 
>>>> Use the mod_limit to check whether there is already a call on his extension, and if so - do not try to bridge with auto answer.
>>>>  
>>>>                          __Yehavi:
>>>> 
>>>> 2012/5/17 Spencer Thomason <spencer at 5ninesolutions.com>
>>>> Hello, I'm having a problem with Polycom endpoints where the phone auto answers a page even if another call is in progress.  My dialplan looks like this:
>>>> 
>>>>    <extension name="extension-intercom">
>>>>      <condition field="destination_number" expression="^\*80(\d{3,7})$">
>>>>        <action application="set" data="dialed_extension=$1"/>
>>>>        <action application="export" data="sip_auto_answer=true"/>
>>>>        <action application="bridge" data="user/${dialed_extension}@${domain_name}"/>
>>>>      </condition>
>>>>    </extension>
>>>> 
>>>> Does anyone have any suggestions for an elegant way to solve this?
>>>> 
>>>> Thanks,
>>>> Spencer
>>>> 
>>>> 
>>>> 
>>>> _________________________________________________________________________
>>>> Professional FreeSWITCH Consulting Services:
>>>> consulting at freeswitch.org
>>>> http://www.freeswitchsolutions.com
>>>> 
>>>> 
>>>> 
>>>> 
>>>> Official FreeSWITCH Sites
>>>> http://www.freeswitch.org
>>>> http://wiki.freeswitch.org
>>>> http://www.cluecon.com
>>>> 
>>>> Join Us At ClueCon - Aug 7-9, 2012
>>>> 
>>>> FreeSWITCH-users mailing list
>>>> FreeSWITCH-users at lists.freeswitch.org
>>>> http://lists.freeswitch.org/mailman/listinfo/freeswitch-users
>>>> UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-users
>>>> http://www.freeswitch.org
>>>> _________________________________________________________________________
>>>> Professional FreeSWITCH Consulting Services:
>>>> consulting at freeswitch.org
>>>> http://www.freeswitchsolutions.com
>>>> 
>>>> 
>>>> 
>>>> 
>>>> Official FreeSWITCH Sites
>>>> http://www.freeswitch.org
>>>> http://wiki.freeswitch.org
>>>> http://www.cluecon.com
>>>> 
>>>> Join Us At ClueCon - Aug 7-9, 2012
>>>> 
>>>> FreeSWITCH-users mailing list
>>>> FreeSWITCH-users at lists.freeswitch.org
>>>> http://lists.freeswitch.org/mailman/listinfo/freeswitch-users
>>>> UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-users
>>>> http://www.freeswitch.org
>>> 
>>> 
>>> _________________________________________________________________________
>>> Professional FreeSWITCH Consulting Services:
>>> consulting at freeswitch.org
>>> http://www.freeswitchsolutions.com
>>> 
>>> 
>>> 
>>> 
>>> Official FreeSWITCH Sites
>>> http://www.freeswitch.org
>>> http://wiki.freeswitch.org
>>> http://www.cluecon.com
>>> 
>>> Join Us At ClueCon - Aug 7-9, 2012
>>> 
>>> FreeSWITCH-users mailing list
>>> FreeSWITCH-users at lists.freeswitch.org
>>> http://lists.freeswitch.org/mailman/listinfo/freeswitch-users
>>> UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-users
>>> http://www.freeswitch.org
>>> 
>>> 
>>> _________________________________________________________________________
>>> Professional FreeSWITCH Consulting Services:
>>> consulting at freeswitch.org
>>> http://www.freeswitchsolutions.com
>>> 
>>> 
>>> 
>>> 
>>> Official FreeSWITCH Sites
>>> http://www.freeswitch.org
>>> http://wiki.freeswitch.org
>>> http://www.cluecon.com
>>> 
>>> Join Us At ClueCon - Aug 7-9, 2012
>>> 
>>> FreeSWITCH-users mailing list
>>> FreeSWITCH-users at lists.freeswitch.org
>>> http://lists.freeswitch.org/mailman/listinfo/freeswitch-users
>>> UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-users
>>> http://www.freeswitch.org
>> 
>> 
>> _________________________________________________________________________
>> Professional FreeSWITCH Consulting Services:
>> consulting at freeswitch.org
>> http://www.freeswitchsolutions.com
>> 
>> 
>> 
>> 
>> Official FreeSWITCH Sites
>> http://www.freeswitch.org
>> http://wiki.freeswitch.org
>> http://www.cluecon.com
>> 
>> Join Us At ClueCon - Aug 7-9, 2012
>> 
>> FreeSWITCH-users mailing list
>> FreeSWITCH-users at lists.freeswitch.org
>> http://lists.freeswitch.org/mailman/listinfo/freeswitch-users
>> UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-users
>> http://www.freeswitch.org
>> 
>> 
>> _________________________________________________________________________
>> Professional FreeSWITCH Consulting Services:
>> consulting at freeswitch.org
>> http://www.freeswitchsolutions.com
>> 
>> 
>> 
>> 
>> Official FreeSWITCH Sites
>> http://www.freeswitch.org
>> http://wiki.freeswitch.org
>> http://www.cluecon.com
>> 
>> Join Us At ClueCon - Aug 7-9, 2012
>> 
>> FreeSWITCH-users mailing list
>> FreeSWITCH-users at lists.freeswitch.org
>> http://lists.freeswitch.org/mailman/listinfo/freeswitch-users
>> UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-users
>> http://www.freeswitch.org
> 
> _________________________________________________________________________
> Professional FreeSWITCH Consulting Services:
> consulting at freeswitch.org
> http://www.freeswitchsolutions.com
> 
> 
> 
> 
> Official FreeSWITCH Sites
> http://www.freeswitch.org
> http://wiki.freeswitch.org
> http://www.cluecon.com
> 
> Join Us At ClueCon - Aug 7-9, 2012
> 
> FreeSWITCH-users mailing list
> FreeSWITCH-users at lists.freeswitch.org
> http://lists.freeswitch.org/mailman/listinfo/freeswitch-users
> UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-users
> http://www.freeswitch.org

-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.freeswitch.org/pipermail/freeswitch-users/attachments/20120517/4e931798/attachment-0001.html 


Join us at ClueCon 2011 Aug 9-11, 2011
More information about the FreeSWITCH-users mailing list