Asterisk; Call Screening - Press 1 to accept, Press 2 to reject

I wanted a telephone number a certain person could call and I would have the option to accept or reject their call. If I rejected the call they would hear a recording like I had traveled outside of my cellular service area (like that happens anymore!). I googled how to do this and found all sorts of outdated rubbish....

As usual, I figured it out on my own. Today, in 2011. My findings are below.

Global variables -CAN- be set in a macro and read back in the original context.

We'll pretend my number, and extention is 8005551212



You should have most of the sound files.
You'll have to get the not in service one from Napster (http://bit.ly/ki1pse) -- I did.
You'll want to change the SIP/18779009000@sipprovider to the number you're calling (i.e.: 8779009000) @ your sip provider.

Back to Code Help | Moo! Networks

For the search engines: Asterisk, extensions.conf, follow me, call screening, screen call, 1 to accept, privacy protection, pass variable from macro, get variable from macro