[Asterisk-Users] Allowing Called user to accept call before
transfer
John Biundo
johnbiundo at sbcglobal.net
Sat Nov 19 20:58:53 MST 2005
I'm still fairly wet behind the ears, so I hope one of the experts will
chime in, but I think I'm doing what you want, so let me try to describe it.
When a call comes in without caller id, I "screen it" (record the
caller's name), then dial one of the internal extensions and play back
the recording. I provide the callee the options to accept the call,
send it to voicemail, or do other nastier things.
The way I do it is to call a macro in the Dial command. For example:
exten => s,n,Dial(${ALLHOUSE},20,TtmM(play-screen^${ANNOUNCE}))
In the play-screen macro, I play the screen, and accept DTMF tones to
accept the callee's desired outcome. Based on the tone, I then set
the MACRO_RESULT variable appropriately. See the dial command on the
wiki for more on this. I use something like:
exten => s,n,SetVar(MACRO_RESULT=GOTO:sendfamilyvmail^s^1)
When the macro ends, if the value of MACRO_RESULT is undefined, the call
is bridged. This is the key point: if you want the call to be bridged,
do not define MACRO_RESULT to anything. If the value is set to GOTO...,
the call is NOT bridged at the end of the macro, and execution continues
at the target of the GoTo.
Hope that helps.
DEEZED wrote:
> I was wondering if its possible to have a asterisk dial a number, and then
> when it is answered, asterisk will playback a message asking the called
> person to press a button if they would like to accept the call, and then if
> asterisk hears a DTFM tone, it will then bridge the 2 calls together.
>
>
>
> If this is possible, how could this be done. Does asterisk have a command to
> merge channel A with channel B?
>
>
>
>
>
>
> ------------------------------------------------------------------------
>
> _______________________________________________
> --Bandwidth and Colocation sponsored by Easynews.com --
>
> Asterisk-Users mailing list
> Asterisk-Users at lists.digium.com
> http://lists.digium.com/mailman/listinfo/asterisk-users
> To UNSUBSCRIBE or update options visit:
> http://lists.digium.com/mailman/listinfo/asterisk-users
More information about the asterisk-users
mailing list