Check incoming call for CALLERID without answering

plin
Joined: Sun 31 of Aug, 2008

Check incoming call for CALLERID without answering

Posted:Sun 31 of Aug, 2008 (15:30 UTC)
I’m running Asterisk 1.4.21.2 and want to catch telemarketer calls on my machine. Asterisk is beyond my telephone system on the internal S0 bus and has no outside connection.
My telephone computer is already answering when I dial 19 for the internal extension which was given to my Asterisk system. Actually I want the system to ONLY respond when a call without callerid is coming in. To accomplish this I tried the following dial plan

exten => "${CALLERID(num)}"19,1,Answer()
exten => 19,n,Wait(1)
exten => 19,n,Playback(phonetic/o_p)
exten => 19,n,Playback(phonetic/k_p)
exten => 19,n,Macro(noCID)
exten => 19,10,Playback(phonetic/n_p)
exten => 19,n,Playback(phonetic/o_p)
exten => 19,n,Playback(phonetic/p_p)
exten => 19,n,Playback(phonetic/e_p)
exten => 19,n,Hangup ; hangup
exten => 19,n,NoOp(End of macro)

Will that work or is there another official way to check an incoming call without answering?