[asterisk-users] Forward incoming call to recipients.

asterisk at phreaknet.org asterisk at phreaknet.org
Wed Aug 31 06:06:30 CDT 2022


On 8/29/2022 4:50 PM, Ken D'Ambrosio wrote:
> Hey, all. I'd like to forward an incoming call (e.g., to an on-call 
> rotation number), out to multiple recipients, BUT only hand the call 
> over to whoever answers _and acknowledges_ (e.g., "Press any key..."), 
> 'cause I don't want it just going to their mailbox.  I've thought of a 
> number of ways to try to make this happen, but surely, something like 
> this must be fairly common, and I'm guessing someone's already got The 
> Right Way(tm) to make it happen. 
There's usually not a "The Right Way(tm)" in Asterisk, only ways, some 
of which are better than others. It really depends on your implementation.

The built-in way I believe is to use the screening/privacy options for 
the Dial() application. I've never used them before so I can't say 
anything further than that. It may or may not fit your use case, you'd 
have to play around with them.

If you wanted to "roll your own", at a high level, you could use local 
channels to do this. Dial the individual destinations using Local 
channels and fork the sub-calls on answer. Use FRAME_DROP to drop the 
answer supervision from answering the master Dial prematurely. Then the 
callee side can then prompt for acknowledgement and if answered, it can 
answer the master channel and cut through as well as cancel the other legs.



More information about the asterisk-users mailing list