[asterisk-users] auto dial out multiple destinations
Vieri
rentorbuy at yahoo.com
Tue Apr 24 03:32:33 MST 2007
Hi,
I am searching for the most effective solution for the
following scenario:
Our users can call into our IVR menu and dial a
specific extension and immediately hang up. This event
should simply trigger Asterisk to make multiple
simultaneous calls through a group of zap channels
(5-10 calls). When the called parties answer, Asterisk
should simply play a message and hangup.
So I was thinking that I could simply add this in
extensions.conf:
exten => 844844,1,Playback(multicall-activated)
exten => 844844,2,agi(multicallagi.php)
exten => 844844,3,Hangup
Then the AGI script would simply create a call file
for each destination number and the format would be
something like this:
Channel: Zap/g0/5555555
MaxRetries: 2
RetryTime: 10
WaitTime: 5
Application: Playback
Data: soundfile
However, Asterisk doesn't wait for the destination to
pick the phone up, so the playback ends prematurely
and the channel is closed. It works only if I use
"Channel: SIP/5555 " (ie. it waits until the SIP phone
answers and then plays the soundfile).
I tried using
Context: mycontext
Extension: s
Priority: 1
and the same thing happens: the context lines are
"run" immediately and even if the destination is not
on line. The only difference here is that I can make a
long loop so it plays back several times so that if
the called party picks the phone up, there's a chance
that they will here the looped playback. But this
isn't very effective.
Has someone done a "better" approach?
Does someone know why only ZAP channels seem to
misbehave (they are immediately considered "answered"
when they are not) ?
Also, could the multicallagi.php script "cut free" a
zap channel in case all channels are already in use in
group g0? Basically, these would be emergency calls
and I wouldn't want them to be hanging around a long
time in the outgoing queue. Also if multicallagi.php
frees a busy channel it could get busy again before
the call file is placed in "outgoing". So is there a
way so that Asterisk knows that the call files I'm
putting in outgoing are "emergency calls"? I know I
could dedicate another group of channels or a single
channel for these calls but I don't have any
available.
Thanks
Vieri
__________________________________________________
Do You Yahoo!?
Tired of spam? Yahoo! Mail has the best spam protection around
http://mail.yahoo.com
More information about the asterisk-users
mailing list