In asterisk/elastix/freepbx, how do you....
1- detect an incoming call
2- read the caller id
3- do something...(perform function)
?
In asterisk/elastix/freepbx, how do you....
1- detect an incoming call
2- read the caller id
3- do something...(perform function)
?
Does this help http://www.freepbx.org/support/documentation/howtos/how-to-set-up-notification-caller-id-popup-on-mac-os-x-linux-and-other-
My general advice: read Asterisk book. It will give you most answers.
Calls to your asterisk will land in some context, probably incoming
, but you can define different contexts for different callers.
There is function callerid, you can use it in your dialplan or AGI scripts
I use AGI scripts written in Python (there are libraries for Python, Perl and other popular languages), which connect to CRM WebService, check caller group by callerid and can prompt differently if call is from me or other employee and differently if one our customers is calling. Different prompts are in different contexts and AGI only set some variables.
In Your Incoming context you can check the callerId of the incoming call, if the callerId matches then you can perform the actions required in dailplan or from using AGI