[asterisk-users] PhpAgi call generation
Rob Schall
rschall at callone.net
Tue Jun 19 09:07:11 CDT 2007
Channel: Zap/g2/5052
MaxRetries: 2
RetryTime: 60
WaitTime: 30
Context: internal
Extension: 8855
Priority: 1
Application: Festival
Data: This, is, a, message, from, UCS, Call, One, Server Status. The,
server, %s, is, currently, not, responding, on, ports, 80.
Once you have this in a file with a .call extension, you have to change
the ownership to asterisk or give it full read and execute so asterisk
can read it then delete it when done. Then just move it in the
/var/spool/asterisk/outgoing folder. And the call should initiate in the
next second or so.
nik600 wrote:
> sorry, can you post me an example of a call file?
> thanks
>
> On 6/19/07, Rob Schall <rschall at callone.net> wrote:
>
>> An alternative to this method might be to create a call file and place
>> it in the spool. Have it either dial and connect the caller to an
>> extension that plays that sound, or just execute that sound itself.
>> Right now, we use this functionality for a server scanner. When it
>> detects a particular port down on one of our machines, it will call us
>> and use festival to tell us what the problem is.
>>
>> Rob
>>
>>
>> nik600 wrote:
>>
>>> hi
>>>
>>> i'd like to write a simply application in php with phpAgi that:
>>>
>>> - connect to Asterisk
>>> - call an external number using a Zap channel
>>> - play a message
>>>
>>> here is some code:
>>>
>>> <?php
>>>
>>> $asm = new AGI_AsteriskManager();
>>>
>>> if ($asm->connect()) {
>>>
>>> $asm->Originate("Zap/g1/1","number","default","1");
>>>
>>> /*
>>> play message...
>>> */
>>> } else {
>>> die("error\n");
>>> }
>>>
>>> ?>
>>>
>>> But it doesn't work.
>>> Is it possible to create a program like this?
>>> thanks
>>>
>>>
>>>
>> _______________________________________________
>> --Bandwidth and Colocation provided by Easynews.com --
>>
>> asterisk-users mailing list
>> To UNSUBSCRIBE or update options visit:
>> http://lists.digium.com/mailman/listinfo/asterisk-users
>>
>>
>
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.digium.com/pipermail/asterisk-users/attachments/20070619/1bc9efed/attachment.htm
More information about the asterisk-users
mailing list