I’m not sure if this is the right place to ask, but I almost have a Python program in place to do a pop up on a user’s computer if 911 is called from one of the buildings.
The part I’m unsure of though: I’m using the AMI and using “Getvar” to get the CALLERID(dnid) to see if it’s 911 (or in my testing case, just my cell phone number). It works if I hard code in a Channel name to do. What I am trying to figure out, and I may be overlooking something or asking for the impossible, is for it to detect from any and all channels if one of them is connected with the PSAP. I don’t want to have to specify one channel, especially since the channel name changes (like right now it’s “PJSIP/3717-0000001d” but earlier it was “PJSIP/3717-00000009” for example).
Is there someone that can point me in the right direction, or has an example of what I’m trying to accomplish already in place? Looking at the Asterisk Wiki at the “Getvar” action if I don’t specify a channel, it would look globally at that variable. Wouldn’t that mean that without giving it the channel that it would be able to see the value of that variable is the emergency number?
Thanks for the post! I’ve gone through the post and it’s helped me familiarize myself with some of the dialplan and hooking.
The Python script I have planned on residing on certain users’ computers, it doesn’t sit on the FreePBX box itself. Can I still utilize the Python program by calling it from the dialplan?
I did find these two threads in the Asterisk community forums. I’m a little unsure how the CURL works, even reading through the documentation for it. Can you point me in the right direction with that a little, or am I going down the wrong path with CURL?