[asterisk-users] dial and bridge

Lenz Emilitri lenz.loway at gmail.com
Thu May 16 09:45:36 CDT 2013


Thanks all for your help, in the end I was able to do something like:

Action: Originate
Channel: Local/300 at from-internal/n
Application: MusicOnHold
Async: 1


As soon as this connects, the callee hears MOH. I get the channel out via
AMI events and start another call:

Action: Originate
Channel: Local/301 at from-internal/n
Application: Bridge
Data: Local/300 at from-internal-aa8c;1
Async: 1

when this connects, it is immediately bridged to the first callee. I just
have to keep track of errors and hang up the first call if the seconds does
not go through.

Thanks a lot!
l.




2013/5/15 Dan Cropp <dan at amtelco.com>

> You could use AsyncAGI to achieve this.****
>
> ** **
>
> Originate the first call (passing in some unique identifier as a
> variable), then using AMI you will see the channel data.  When you see an
> Event: AysncAGI for that channel (with that id, you have control of the
> call).  Send a Dial Action telling it to dial the call and bridge them
> together if the person answers.  If they don’t answer, you will be notified
> and can do something with the original call (play a message, hangup, etc).
> If they are bridged, you can see how long, etc.****
>
> ** **
>
> Setup an extension, naming it something like patching****
>
> ** **
>
> exten => patching,1,AGI(agi:async)****
>
> ** **
>
> Action: Originate
> Channel: Local/300 at from-internal****
>
> Async: 1
> Exten: 1****
>
> Context: patching
> Data: 1973****
>
> Variable: YourUniquePatchID=1234****
>
> ** **
>
> ** **
>
> Using AsyncAGI and AMI, you can have full control of the call.  You do
> have to setup a very simple dial plan so Asterisk knows you are using
> AsyncAGI to control the call.****
>
> ** **
>
> Have a great day!****
>
> Dan****
>
> ** **
>
> ** **
>
> ** **
>
> *From:* asterisk-users-bounces at lists.digium.com [mailto:
> asterisk-users-bounces at lists.digium.com] *On Behalf Of *Lenz Emilitri
> *Sent:* Tuesday, May 14, 2013 11:16 AM
> *To:* Asterisk Users Mailing List - Non-Commercial Discussion
> *Subject:* [asterisk-users] dial and bridge****
>
> ** **
>
>
> ****
>
> Hi all,****
>
> I need some advice - I have been working on originating multiple calls
> using AMI and then joining them. ****
>
> What I want to do is:****
>
> - dial call 1 (where the caller is in a "channel" format, like SIp/1234 or
> Local/1234 at ext) and "park" it somehow****
>
> - dial call 2 (where again the caller is in channel format) and join it to
> the previous call.****
>
> ** **
>
> As a requirement, I cannot use the dialplan as an end-point (as I cannot
> change it) but need to use the AMI only.****
>
> ** **
>
> I tried doing something like:****
>
> ** **
>
> Action: Originate
> Channel: Local/300 at from-internal****
>
> Async: 1
> Application: Wait
> Data: 1973****
>
> ** **
>
> So that the call goes to 300 and then basically stays there forever, and
> then I dial again:****
>
> ** **
>
> Action: Originate
> Channel: Local/500 at from-internal****
>
> Async: 1
> Application: Wait
> Data: 1973****
>
>   ****
>
> And then try to bridge the results, but it does not seem to work.****
>
> What I would like to do would be more on the lines of:****
>
> ** **
>
> Originate call 1 and park it (using a park or waiting)****
>
> Originate call 2 and bridge it immediately to call1 (using the Application
> part)****
>
> ** **
>
> But maybe I am missing something? is there anybody who has better
> suggestions?****
>
> ** **
>
> Thanks****
>
> l.****
>
> ** **
>
> ** **
>
> ** **
>
> ** **
>
> ** **
>
> ** **
>
> -- ****
>
> Loway - home of QueueMetrics - http://queuemetrics.com****
>
> Test-drive WombatDialer beta @ http://wombatdialer.com ****
>
> --
> _____________________________________________________________________
> -- Bandwidth and Colocation Provided by http://www.api-digital.com --
> New to Asterisk? Join us for a live introductory webinar every Thurs:
>                http://www.asterisk.org/hello
>
> asterisk-users mailing list
> To UNSUBSCRIBE or update options visit:
>    http://lists.digium.com/mailman/listinfo/asterisk-users
>



-- 
Loway - home of QueueMetrics - http://queuemetrics.com
Test-drive WombatDialer beta @ http://wombatdialer.com
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.digium.com/pipermail/asterisk-users/attachments/20130516/e37150d4/attachment.htm>


More information about the asterisk-users mailing list