Bridge call channels

1,978 views
Skip to first unread message

case...@gmail.com

unread,
Jun 16, 2014, 7:17:19 PM6/16/14
to 2600h...@googlegroups.com
Hi All,

On my custom whistle-esk app, I'm trying to bridge two or more existing call legs (channels) together from calls that my app has "won". For example, if call A had a Call-ID of "abc" and call B had a Call-ID of "bcd", then I'd like to have a function that could be as simple as bridgeChannels("abc", "bcd",...). To do this, I need to figure out how to send a call command through AMQP to ecallmgr to bridge the channels.

FreeSWITCH has this function:
uuid_bridge
Bridge two call legs together.
Usage: uuid_bridge <uuid> <other_uuid>
uuid_bridge needs atleast any one leg to be answered.


I've found a definition for "Bridge Endpoints" in ecallmgr here: https://github.com/2600hz/kazoo/blob/master/core/whistle-1.0.0/src/api/wapi_dialplan.hrl but I'm not sure how to use this (e.g. what application name do I use to call it, where do I specify the Call-ID, etc.) At the moment I can make a softphone ring and bridge that to a channel by Call-ID using the "Bridge" command specified in the above URL, but I don't want to bridge to a new channel - just bridge two or more existing channels.

Is there any way to do this with ecallmgr through AMQP?

Thanks!

Casey

James Aimonetti

unread,
Jun 16, 2014, 8:06:16 PM6/16/14
to 2600h...@googlegroups.com
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA256

Look at the pickup dialplan command in wapi_dialplan. Only works for
two legs though; you'll need to create and transfer into a conference
for more legs.

On 06/16/2014 04:17 PM, case...@gmail.com wrote:
> Hi All,
>
> On my custom whistle-esk app, I'm trying to bridge two or more
> existing call legs (channels) together from calls that my app has
> "won". For example, if call A had a Call-ID of "abc" and call B had
> a Call-ID of "bcd", then I'd like to have a function that could be
> as simple as *bridgeChannels("abc", "bcd",...)*. To do this, I need
> to figure out how to send a call command through AMQP to ecallmgr
> to bridge the channels.
>
> FreeSWITCH has this function:
> (https://wiki.freeswitch.org/wiki/Mod_commands#uuid_bridge)
> *uuid_bridge* Bridge two call legs together. Usage: uuid_bridge
> <uuid> <other_uuid> uuid_bridge needs atleast any one leg to be
> answered.
>
>
> I've found a definition for "Bridge Endpoints" in ecallmgr here:
> https://github.com/2600hz/kazoo/blob/master/core/whistle-1.0.0/src/api/wapi_dialplan.hrl
> but I'm not sure how to use this (e.g. what application name do I
> use to call it, where do I specify the Call-ID, etc.) At the moment
> I can make a softphone ring and bridge that to a channel by Call-ID
> using the "Bridge" command specified in the above URL, but I don't
> want to bridge to a new channel - just bridge two or more existing
> channels.
>
> Is there any way to do this with ecallmgr through AMQP?
>
> Thanks!
>
> Casey
>


- --
James Aimonetti
Lead Systems Architect / Impressionable Scallywag
"I thought I fixed that"

2600Hz | http://2600hz.com
sip:ja...@2600hz.com
tel:415.886.7905
irc:mc_ @ freenode
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1
Comment: Using GnuPG with Thunderbird - http://www.enigmail.net/

iF4EAREIAAYFAlOfhnUACgkQ54NxaUq7OmBX1gD+IewDJNfFKwG12vla6/y4MNn8
wk+ulEAvVsSC30eqdZgA/AtL1yWQDA6zqLp220kTBr3PXoRwI3iByk5+V3Iwue7y
=Oufv
-----END PGP SIGNATURE-----

case...@gmail.com

unread,
Jun 17, 2014, 4:42:16 PM6/17/14
to 2600h...@googlegroups.com, case...@gmail.com
Exactly what I needed - it worked beautifully. Thanks for the quick reply!  One more question - any thoughts on how to cancel a bridge (or media / echo / conference, etc.)? I've tried sending a park command, but it doesn't seem to do anything.

Here's my park command JSON:
{
  "Event-Name": "command",
  "Event-Category": "call",
  "Call-ID": "OTNhMjRlNTUwZTYxMmEzNjYwNmQ2N2I2NWJiMjk5Y2U",
  "App-Name": "CallMeMaybe",
  "App-Version": "0.0.1",
  "Msg-ID": "84d7877c-096a-4041-9c61-7c181086e827",
  "Insert-At": "now",
  "Server-ID": "CallMeMaybe_ReceiveQueue",
  "Application-Name": "park"
}



Thanks again,
Casey
Reply all
Reply to author
Forward
0 new messages