Well to start you probably have to add verify_ssl: false to your sensor. Since that’s a local IP address whatever SSL certificate you are presenting is either self-signed or for a different domain entirely since CAs won’t issue SSL certificates for private IP addresses.
Also it looks like you’re providing Content-Type: application/json as a header which is weird since its a GET call and has no request body. Did you mean to put Accept: application/json to specify that you want JSON back? Not sure if that’s necessary or not but it makes more sense then providing Content-Type without a postbody.
Also only you can verify this but make sure your llt_addons secret is of the format Bearer <a valid token>.
I’m guessing it was blowing up on the SSL certificate since it looks correct other then that. Maybe the extraneous Content-Type header but most APIs just ignore that on a GET call.
Huh, that is really confusing. I’ve had issues with not receiving notifications before due to end device state but never with ha not firing an automation when it obviously should. If you go to developer tools you can manually set binary_sensor.updater to on and off to test it. Does it work when you do that at least?
it’s hard coded for that binary_sensor. This thread gives you other ways to be notified almost immediately so if that is a concern for you, use that rather than the binary sensor.
Yea that’s my bad, I need to update that. Early on after I posted it and started using this package one of the first things I noticed was that binary_sensor.updater was wayyyy too slow for me. When I started digging into making update sensors for the other components of supervisor (after @DavidFW1960 pointed it out actually) I realized I should just make my own for core. I mentioned it here:
There’s two packages on the initial post. One is the base package that I posted initially, the second one includes a lot more update sensors for the various supervisor components and includes a much faster sensor for core. Here it is if you want to add it. With this one you can set the scan_interval to whatever you want:
Until now I checked if the updater sensor switched to “True” to fire my notification.
That obviously didn´t work reliably, maybe (wild guess) because that switch to “True” sometimes happens during HA restarting and the automation doesn´t get triggered (due to maybe HA not being fully started yet?).
Now I´m thinking of setting a time pattern as trigger (e. g. “every 3 hours”) and setting the check if sensor state is “True” as a condition.
Problems with this strategy:
Obviously:
notifications/actions will be fired every time according to time pattern. Receiving a notification ONCE is enough… don´t know how to work around that from the automation perspective
Possibly:
ending up in the same situation (automation not getting triggered).
I was wondering how you guys set up your notification automations.
So still a complete miracle to me why it´s not reliably working… (one indication: there is a correlation between automations not being triggered when sensor state changes and at the same time or only few minutes before HA is being restarted)
History should contain an entry like Has been triggered by state of sensor.updater_addons @ roughly 19:02:XX - but it doesn´t
Let´s see what others use or if someone has an idea.
I have had issues with triggers not firing when the state changed during a restart. I can’t think of any specific examples off the top of my head but it is something I’ve struggled with before.
But I actually don’t use automations at all with update notifications. In the package at the top you can see there’s a whole bunch of alerts, that’s what I use. They’re basically automations specifically for the use case of notifying you of a situation.
I have noticed with alerts that occasionally I’ll miss the first one for a similar reason (state changed during a restart). But that’s not a big deal with alerts since they have a built-in reminder feature so I’ll get the second one even if I somehow miss the first.
I’ve never seen that. Really don’t know what to make of that. Might have to report a bug I guess but its not something I’ve ever seen and I use tons of alerts in my system for all sorts of things.