[asterisk-users] Callback / Camp / Extention Free notify?

Paul Hales pdhales at optusnet.com.au
Thu Jan 29 17:14:44 CST 2009


> Quick solution that comes into mind:
>
> Set(exten_copy = ${EXTEN});
> Dial(SIP/${EXTEN})
> if ("${DIALSTATUS}"="BUSY") {
>   // prompt for camp
>   Set(DB(camp/${EXTEN}/call_to)=${CALLERID(num));
> }
>
> h => {
>   Set(call_to=${DB(camp/${exten_copy}/call_to)});
>   if ("${call_to}"!="") {
>     Set(DB(camp/${exten_copy}/call_to)=);
>     System(call_to ${exten_copy} ${call_to});
>   }
> }
>
> So, in case if phone2 is busy, store callerid of phone1 in database,
> so when phone2 will hangup it will triger a script "call_to" which
> however can originate call trough manager or call-file.
>
> Of course you will need some additional handling in case if multiple
> callers decide to camp, or diferent protocols are used, etc.
>
>   

You could call a batch script from the dialplan that parses the output
of 'show hints'  with a simple grep to find the status of the individual
in question.

PaulH



More information about the asterisk-users mailing list