[Freeswitch-users] Call intercept.

Michael Jerris mike at jerris.com
Mon Mar 23 07:28:02 MSK 2015


We would be happy to accept a pull request adding some logging there.

> On Mar 22, 2015, at 3:36 PM, Sean Devoy <sdevoy at bizfocused.com> wrote:
> 
> *** RESOLVED ***
>  
> I have some testing to do, but I think I found the problem.  All of my tests have been dialing a did that routes directly to a test extension, then intercepting that call from that extension.  The user’s calls however take a slightly different route.  They come in and got directly to an IVR, then to an extension which seems to not allow intercept!
>  
> The problem lies in my intercept call dialplan:
>     <extension name="directed-call-pickup">
> <!-- picks up the call with db key saved like this:             <action application="db"
>      data="insert/ESTA_call_pickup_uuid/22/${uuid}"/>  -->
>       <condition field="destination_number" expression="^\*\*(\d\d)$">
>         <action application="answer"/>
>         <action application="set" data="intercept_unanswered_only=true"/>
>         <action application="intercept" data="${db(select/esta_call_pickup_uuid/$1)}"/>
>         <action application="sleep" data="2000"/>
>       </condition>
>     </extension>
>  
> A DID bridged directly to an extension that has not been “answered” can be picked up just as expected.  However, a DID that comes in and goes to an IVR (which requires the call  to be “answer()”ed), and then is bridged to one or more extensions CANNOT be intercepted if you include: intercept_unanswered_only=true.
>  
> It appears the correct variable is: intercept_unbridged_only=true
>  
> Hope this helps someone else in the future.
>  
> Maybe it is just me, but perhaps if an “intercept()” fails it could give a hint in the log what happened and why!
>  
> Thanks to those that tried to help.
>  
> Sean
>  
>  
> From: freeswitch-users-bounces at lists.freeswitch.org [mailto:freeswitch-users-bounces at lists.freeswitch.org] On Behalf Of Sean Devoy
> Sent: Sunday, March 22, 2015 12:37 PM
> To: FreeSWITCH Users Help
> Subject: Re: [Freeswitch-users] Call intercept.
>  
> I would think so too.  Since I did provide the full logs, and I can’t figure out what happened, could someone PLEASe take a look:
>  
> In this pastebin:  https://pastebin.freeswitch.org/24023 <https://pastebin.freeswitch.org/24023>
> ·         Line 1 through about 170 show the call coming in from the IVR to an extension “MAINLINE”.
> it is bridged to one extension immediately (ext 10) and a couple of others with [leg delay]
> It has UUID: 574583db-22d2-4b7f-a9a4-3cadd419b93d
> ·         In Line 284,  you can see extension 20 dialed **10 to intercept extension 10.
> ·         In line 298, It matches the dial plan **dd.
> ·         In line 299-to 302 you can see the dialplan for the intercept.
> ·         In line 334, you can see: “intercept(574583db-22d2-4b7f-a9a4-3cadd419b93d)”
> ·         In line 340, you see sofia/external/20 at fs_esta.bizfocused.com entering state [ready][200] <mailto:sofia/external/20 at fs_esta.bizfocused.com%20entering%20state%20%5bready%5d%5b200%5d>
> Does that mean the intercept was successful?
> ·         Then after EXCTLY the “sleep(2000)” the channel for ext 20 says “has executed the last dialplan instruction, hanging up.”
>  
> Does “intercept()” not bridge the two legs together? 
> Am I missing a step? 
> I find no further entries in the log for the intercepted UUID.
> Thanks for looking.
> Sean
>  
>  
> From: freeswitch-users-bounces at lists.freeswitch.org <mailto:freeswitch-users-bounces at lists.freeswitch.org> [mailto:freeswitch-users-bounces at lists.freeswitch.org <mailto:freeswitch-users-bounces at lists.freeswitch.org>] On Behalf Of Brian West
> Sent: Thursday, March 19, 2015 11:48 AM
> To: FreeSWITCH Users Help
> Subject: Re: [Freeswitch-users] Call intercept.
>  
> Sounds like the UUID isn't there that you expected,  so it couldn't pick it up. I'm guessing the full logs would show that. 
>  
> On Thu, Mar 19, 2015 at 10:28 AM, Sean Devoy <sdevoy at bizfocused.com <mailto:sdevoy at bizfocused.com>> wrote:
> Anyone help with this, PLEASE?  The customer is quite upset.
>  
> Thank you,
> Sean
>  
> From: freeswitch-users-bounces at lists.freeswitch.org <mailto:freeswitch-users-bounces at lists.freeswitch.org> [mailto:freeswitch-users-bounces at lists.freeswitch.org <mailto:freeswitch-users-bounces at lists.freeswitch.org>] On Behalf Of Sean Devoy
> Sent: Wednesday, March 18, 2015 3:46 PM
> 
> To: FreeSWITCH Users Help
> Subject: Re: [Freeswitch-users] Call intercept.
>  
> Yes, that is what I pass to the intercept call vie the dialplan/database.  Check the log:
>  
> 62cc7ef5-f121-4fa2-97be-e45ff28d9c95 Dialplan: sofia/external/20 at fs_esta.bizfocused.com <mailto:sofia/external/20 at fs_esta.bizfocused.com> Actionintercept(${db(select/esta_call_pickup_uuid/10)})
> . . . . 
> 62cc7ef5-f121-4fa2-97be-e45ff28d9c95 EXECUTE sofia/external/20 at fs_esta.bizfocused.com <mailto:sofia/external/20 at fs_esta.bizfocused.com>intercept(574583db-22d2-4b7f-a9a4-3cadd419b93d)
>  
>  
> Sean
>  
> From: freeswitch-users-bounces at lists.freeswitch.org <mailto:freeswitch-users-bounces at lists.freeswitch.org> [mailto:freeswitch-users-bounces at lists.freeswitch.org <mailto:freeswitch-users-bounces at lists.freeswitch.org>] On Behalf Of Brian West
> Sent: Wednesday, March 18, 2015 3:39 PM
> To: FreeSWITCH Users Help
> Subject: Re: [Freeswitch-users] Call intercept.
>  
> intercept takes a UUID, not an extension number.
>  
> On Wed, Mar 18, 2015 at 2:12 PM, Sean Devoy <sdevoy at bizfocused.com <mailto:sdevoy at bizfocused.com>> wrote:
> Hi All,
>  
> I have directed call intercept running via dialplan **\d\d  (two digit extensions).
>  
> In this pastebin:  https://pastebin.freeswitch.org/24023 <https://pastebin.freeswitch.org/24023>
>  
> You should see a call come from the IVR into “MAINLINE” which dials ext 10, then after delay adds other extensions.  In this case, the person from extension 10 was at extension 20 and dialed **10.  They report it did not work.  I must say I am not clear if it worked or not.  It appears to work, but ended with sofia/external/20 at fs_esta.bizfocused.com has executed the last dialplan instruction, hanging up. <mailto:sofia/external/20 at fs_esta.bizfocused.com%20has%20executed%20the%20last%20dialplan%20instruction,%20hanging%20up.>
>  
> Can someone who is more log savvy than I review that log and tell me what happened?
>  
> Perhaps my dialplan is missing something:
>  
>     <extension name="directed-call-pickup">
>       <!-- picks up the call with db key saved like this:             <action application="db" data="insert/ESTA_call_pickup_uuid/223/${uuid}"/>  -->
>       <condition field="destination_number" expression="^\*\*(\d\d)$">
>         <action application="answer"/>
>         <action application="set" data="intercept_unanswered_only=true"/>
>         <action application="intercept" data="${db(select/esta_call_pickup_uuid/$1)}"/>
>         <action application="sleep" data="2000"/>
>       </condition>
>     </extension>
>  
> I see in the log the uuid for the appropriate call is in the intercept statement.  After intercept, I am missing something to bridge the 2 legs together?
>  
> Thanks,
> Sean Devoy
>  

-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.freeswitch.org/pipermail/freeswitch-users/attachments/20150323/8de22681/attachment-0001.html 


Join us at ClueCon 2016 Aug 8-12, 2016
More information about the FreeSWITCH-users mailing list