Hi all,
I’m at my wits end…
I have an asterisk setup that I want to provide anonymous calling with. I want *65 to hit my dial-plan, the caller-id to be edited and set as anonymous, and then sent out a trunk. Easy enough.
Here’s my plan:
[LetsAnon]
exten => _*65.,1,NoOp(Anonymous Call from ${CALLERID(num)})
exten => _*65.,n,Goto(AnonCall,${EXTEN},1)
[AnonCall]
exten => _*65.,1,NoOp(Original Caller ID is ${CALLERID(num)})
exten => _*65.,n,Set(${CALLERID(name)}=anonymous)
exten => _*65.,n,Set(${CALLERID(number)}=anonymous)
exten => _*65.,n,NoOp(New Caller ID is ${CALLERID(num)})
exten => _*65.,n,Goto(Done-Anon,${EXTEN:3},1)
exten => _*65.,n,Hangup
[Done-Anon]
exten => _X.,1,Dial(SIP/${EXTEN}@OutboundTrunk)
exten => _X.,2,NoOp(FAILED TO DIAL ANON!)
exten => _X.,3,Hangup
UPDATE
Removing the rest because it’s redundant now, see jcolp’s reply below. I was using it wrong.
Leaving this up for future searches.