Notify after forwarded Call is finished
Hi, I’m trying to find out a special solution for our customer. He needs to understand when the forwarded call is finished. The workflow is the following: - User A is calling a external number (User B) and after the Caller has answered the call,he puts the Call on Hold - User A is calling the second external number (User C) (with the BLF keys) and says that on the other line is person X and do an Attended Transfer And the problem is that the User A want to know when the call is finished for calling the next person. Is there a way to understand when the call is finished? It it possible to use the BLF functions for that? I tried to complete that using the dial plan with hangup_after_bridge=false and continue_on_fail=true for calling a command something after the bridge but still without luck and the BLF key for User C is also always Green. Plan B would be to parse the channels table and do send a message to the yealink phones after the call has left the channels table… We are using FS 1.4.14, Yealink Phones and a patton smartnode as ISDN/SIP Gateway. Any hint? Maybe to watch a special Event to understand when the call is finished? Thank you very much! Raphael
On Tue, Feb 10, 2015 at 2:46 AM, Raphael Lechner <raphael.lechner@gmail.com> wrote:
Hi,
I’m trying to find out a special solution for our customer. He needs to understand when the forwarded call is finished.
The workflow is the following: - User A is calling a external number (User B) and after the Caller has answered the call,he puts the Call on Hold - User A is calling the second external number (User C) (with the BLF keys) and says that on the other line is person X and do an Attended Transfer
And the problem is that the User A want to know when the call is finished for calling the next person.
Is there a way to understand when the call is finished? It it possible to use the BLF functions for that? I tried to complete that using the dial plan with hangup_after_bridge=false and continue_on_fail=true for calling a command something after the bridge but still without luck and the BLF key for User C is also always Green.
Plan B would be to parse the channels table and do send a message to the yealink phones after the call has left the channels table…
We are using FS 1.4.14, Yealink Phones and a patton smartnode as ISDN/SIP Gateway.
Any hint? Maybe to watch a special Event to understand when the call is finished?
You could set api_hangup_hook on either of these legs and have the API send out a NOTIFY (or anything you want, I suppose) at hangup. https://freeswitch.org/confluence/display/FREESWITCH/Variables#Variables-api... Please experiment and report back! -MC
Thank you very much!
Raphael _________________________________________________________________________ Professional FreeSWITCH Consulting Services: consulting@freeswitch.org http://www.freeswitchsolutions.com
Official FreeSWITCH Sites http://www.freeswitch.org http://confluence.freeswitch.org http://www.cluecon.com
FreeSWITCH-users mailing list FreeSWITCH-users@lists.freeswitch.org http://lists.freeswitch.org/mailman/listinfo/freeswitch-users UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-users http://www.freeswitch.org
Thank you for the hint. The api_hangup_hook seems to work only for the first call and for the attended transfer call in the background. At the moment I have a working solution using the event CHANNEL_HANGUP_COMPLETE and by parsing the different variables sending the phone a popup via XML. In some situation the script get confused. I’m still experimenting and I will report them back after. Raphael
On 10 Feb 2015, at 16:53, Michael Collins <msc@freeswitch.org> wrote:
You could set api_hangup_hook on either of these legs and have the API send out a NOTIFY (or anything you want, I suppose) at hangup. https://freeswitch.org/confluence/display/FREESWITCH/Variables#Variables-api... <https://freeswitch.org/confluence/display/FREESWITCH/Variables#Variables-api_hangup_hook>
Please experiment and report back!
-MC
Thank you very much!
Raphael _________________________________________________________________________ Professional FreeSWITCH Consulting Services: consulting@freeswitch.org <mailto:consulting@freeswitch.org> http://www.freeswitchsolutions.com <http://www.freeswitchsolutions.com/>
Official FreeSWITCH Sites http://www.freeswitch.org <http://www.freeswitch.org/> http://confluence.freeswitch.org <http://confluence.freeswitch.org/> http://www.cluecon.com <http://www.cluecon.com/>
FreeSWITCH-users mailing list FreeSWITCH-users@lists.freeswitch.org <mailto:FreeSWITCH-users@lists.freeswitch.org> http://lists.freeswitch.org/mailman/listinfo/freeswitch-users <http://lists.freeswitch.org/mailman/listinfo/freeswitch-users> UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-users <http://lists.freeswitch.org/mailman/options/freeswitch-users> http://www.freeswitch.org <http://www.freeswitch.org/> _________________________________________________________________________ Professional FreeSWITCH Consulting Services: consulting@freeswitch.org <mailto:consulting@freeswitch.org> http://www.freeswitchsolutions.com <http://www.freeswitchsolutions.com/>
Official FreeSWITCH Sites http://www.freeswitch.org <http://www.freeswitch.org/> http://confluence.freeswitch.org <http://confluence.freeswitch.org/> http://www.cluecon.com <http://www.cluecon.com/>
FreeSWITCH-users mailing list FreeSWITCH-users@lists.freeswitch.org <mailto:FreeSWITCH-users@lists.freeswitch.org> http://lists.freeswitch.org/mailman/listinfo/freeswitch-users <http://lists.freeswitch.org/mailman/listinfo/freeswitch-users> UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-users <http://lists.freeswitch.org/mailman/options/freeswitch-users> http://www.freeswitch.org <http://www.freeswitch.org/>
Attached the link to my current working solution. Some parts of the python script are only used on that installation and probably need to be changed for another installation. If you dial *5 + external number then you get the notification after the call is finished. The Python script needs to be running. There exists also some limitation: - This works only for ATTENDED_TRANSFER not for BLIND_TRANSFER - If you put *5 + external Number to a Linekey then you always get the notification after hanging up (If you only call them, without transferring another call). Python Script: https://pastebin.freeswitch.org/23906 <https://pastebin.freeswitch.org/23906> Check if call is finished and send notification to the yealink phone. Dialplan: https://pastebin.freeswitch.org/23907 <https://pastebin.freeswitch.org/23907> mark the call for processing them after with the python script and create outgoing call. Raphael
On 10 Feb 2015, at 17:12, Raphael Lechner <raphael.lechner@gmail.com> wrote:
Thank you for the hint. The api_hangup_hook seems to work only for the first call and for the attended transfer call in the background.
At the moment I have a working solution using the event CHANNEL_HANGUP_COMPLETE and by parsing the different variables sending the phone a popup via XML. In some situation the script get confused. I’m still experimenting and I will report them back after.
Raphael
On 10 Feb 2015, at 16:53, Michael Collins <msc@freeswitch.org <mailto:msc@freeswitch.org>> wrote:
You could set api_hangup_hook on either of these legs and have the API send out a NOTIFY (or anything you want, I suppose) at hangup. https://freeswitch.org/confluence/display/FREESWITCH/Variables#Variables-api... <https://freeswitch.org/confluence/display/FREESWITCH/Variables#Variables-api_hangup_hook>
Please experiment and report back!
-MC
Thank you very much!
Raphael _________________________________________________________________________ Professional FreeSWITCH Consulting Services: consulting@freeswitch.org <mailto:consulting@freeswitch.org> http://www.freeswitchsolutions.com <http://www.freeswitchsolutions.com/>
Official FreeSWITCH Sites http://www.freeswitch.org <http://www.freeswitch.org/> http://confluence.freeswitch.org <http://confluence.freeswitch.org/> http://www.cluecon.com <http://www.cluecon.com/>
FreeSWITCH-users mailing list FreeSWITCH-users@lists.freeswitch.org <mailto:FreeSWITCH-users@lists.freeswitch.org> http://lists.freeswitch.org/mailman/listinfo/freeswitch-users <http://lists.freeswitch.org/mailman/listinfo/freeswitch-users> UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-users <http://lists.freeswitch.org/mailman/options/freeswitch-users> http://www.freeswitch.org <http://www.freeswitch.org/> _________________________________________________________________________ Professional FreeSWITCH Consulting Services: consulting@freeswitch.org <mailto:consulting@freeswitch.org> http://www.freeswitchsolutions.com <http://www.freeswitchsolutions.com/>
Official FreeSWITCH Sites http://www.freeswitch.org <http://www.freeswitch.org/> http://confluence.freeswitch.org <http://confluence.freeswitch.org/> http://www.cluecon.com <http://www.cluecon.com/>
FreeSWITCH-users mailing list FreeSWITCH-users@lists.freeswitch.org <mailto:FreeSWITCH-users@lists.freeswitch.org> http://lists.freeswitch.org/mailman/listinfo/freeswitch-users <http://lists.freeswitch.org/mailman/listinfo/freeswitch-users> UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-users <http://lists.freeswitch.org/mailman/options/freeswitch-users> http://www.freeswitch.org <http://www.freeswitch.org/>
participants (2)
-
Michael Collins
-
Raphael Lechner