Add PolycomPush
dialplan application, to streamline delivering push notifications to IP phones, e.g. with syntax as such:
same => n,Set(spipmsg=<title><u>Title</u></title><p>Hello world!</p>)
same => n,Set(vvxmsg=<title>Title</title><p>Hello world!</p>)
same => n,PolycomPush(PJSIP/Polycom1&PJSIP/Polycom2,pushuser,pushpass,spipmsg,vvxmsg) ; <- names of variables, not variables directly (like several other Asterisk functions, e.g. CUT)
same => n,Hangup()
This application will make a curl
request to the IP of each endpoint and deliver the appropriate payload based on its user agent. (If a phone has multiple AORs, it should process all of them)
Currently, the "older" message is intended for SoundPoints and the "newer" for VVX and newer.
There should be a verbose message for each phone, with the HTTP response of whether or not the push was successful.
This will make it easier to see if anything went wrong. Right now, with ~10 phones, this process requires many lines of dialplan, and results in around 200 lines of Asterisk console output - so much clutter it's hard to see what happened and if anything went wrong.
You must be