I have an Elk alarm system and I’m using the plugin. Right now, I have a notification on Partiion/Area 1 that sends me an email if it goes into alarm mode. But, that notification doesn’t tell me what was tripped.
What I want to do is to use the SMTP plugin to craft a custom email/SMS, and some Luup code that will run when the system alarms. I want it to either tell me what sensor tripped it, or give me a list of tripped sensors.
There is no direct access to Notifications from Luup.
However a notification is triggered by changes in the uPnP variables for a device.
These are available from Luup, you need the devices, variable names, and of course the uPnP serviceid for each variable. If you had a list of these … you could iterate the loop.
Even the LastTrip time will be available. (You can find the serviceid for a uPnPvariable by going to the Advanced page for a device. Hover you mouse over the variable name.
I have a mod to Vera Alerts that should be available soon that will use Vera Alerts as a notification agent. (Device Notifications, Scene Trigger Notifications). No luup code needed. Has better information content then MCV email notification and you can customize the message.
Yep, this is why I was going to use the smtp plugin and call it directly with luup. So, there is no way to iterate through all security sensors without defining a list of them first?