Asterisk auto dial-out script


is it possible to make asterisk automatically call some user at defined intervals using some script. e.g i want that at 2:00 PM each day my server makes a call to user alice , plays a greeting and hangs up the call ?
thanx in advance


Yes. Although you will need a small amount of shell scripting to create the call file.

you can create script like


echo "Channel: IAX2/provider/9$1" > /var/tmp/call_$1_$7_${DATETIME}
echo "MaxRetries: $2" >> /var/tmp/call_$1_$7_${DATETIME}
echo "WaitTime: $3" >> /var/tmp/call_$1_$7_${DATETIME}
echo "Context: $4" >> /var/tmp/call_$1_$7_${DATETIME}
echo "CallerID: $5 <$6>" >> /var/tmp/call_$1_$7_${DATETIME}
echo "Extension: $7" >> /var/tmp/call_$1_$7_${DATETIME}
echo "Priority: $8" >> /var/tmp/call_$1_$7_${DATETIME}
echo "Archive: Yes" >> /var/tmp/call_$1_$7_${DATETIME}

mv /var/tmp/call_$1_$7_${DATETIME} /var/spool/asterisk/outgoing

and call it via /etc/crontab at 02:01 :

1 2    * * *   root    /path_to/

I hope, user Alice is waiting for a call :smile:

thanks wowks ! let me try it . one more question , can asterisk make more than one such outgoing calls using SIP Channel ? idea is have a close friend group whom i want to send a greeting message at same time .
[ by the way alice would waiting anxiously for such call:-) ]

Thanks and Regards