(Putting this at the top to make it easier to find...explanation of the app is below.)
This app is available on GitHub and is also available from Hubitat Package Manager:
To install, just add the app from the above (raw link: https://raw.githubusercontent.com/RMoRobert/Hubitat/master/apps/DeviceActivityCheck/DeviceActivityCheck1.groovy) to "Apps Code." Or, find it in Hubitat Package Manager.
While there are at least a couple apps with similar purposes (Device Watchdog and Device Monitor come to mind--both great options that you should also check out), none did exactly what I was looking for, so I decided to write one to meet my own simple need: get notified daily at a specific time (or on an arbitrary schedule you could set up with a rule) if specific devices haven't "checked in" in a while. Additionally, I wanted to be able to configure different "thresholds" (inactivity timeouts) for different devices while keeping them all part of the same report/notification.
Enter: Device Activity Check. Here's a screenshot with a most of the options exposed:
While there is a way to "manually" view the report or trigger the notification (which will only get sent if anything is, indeed, "inactive") from the app, sending an automated notification is the primary purpose of this app. There is no Dashboard integration (it would be easy enough for me to add an HTML endpoint you could feed to an attribute tile or an entire HTML page you could link to and display if this is a need anyone has, but I might suggest Device Watchdog instead). There is no battery monitoring (I do not find this to be helpful for most of my devices). Just thought I'd share what I wrote for myself in case anyone else was interested!
Let me know if you have any questions, but the general idea is:
- Choose the devices you want to "monitor" (Device Activity Check doesn't actually "monitor" or subscribe to any of their events; instead, it evaluates the current time based on their "Last Activity At" data at the time the notification is scheduled to be sent or the report or notification are manually invoked, or, if configured for this instead, checks their "presence" attribute value).
- Optionally, you can create multiple "groups" of devices with the "Add new group" button, which will enable you to configure different intervals (or inactivity detection methods: "Last Activity At" or "presence") for different sets of devices. If you only want one interval/type for all selected devices, you do not need to do this.
- Choose your notification device (for example, your phone/tablet with the Hubitat app or another service) for the "Send notification with list of inactive devices to this device:" field.
- Optionally (but you probably want this), configure a daily time at which to send the notifications. The notification will be sent only if there are inactive devices according to your criteria.
- Optionally, choose a switch, where the notification will also be sent when the switch is turned on, again only if there are devices to report. This is how you could automate sending reports with Rule Machine or Simple Automation Rules instead of relying on the app's built-in daily schedule.
- "Include last activity time in notifications": if configured, inactive devices will also display their last activity date/time in the notifications. Un-select this option to show only the list of devices.
- "View current report": will show list of "inactive" devices (manual alternative to using notifications; may be useful to consult when configuring app for first time to see what devices are listed)
- "Test Notification Now": will send notification (using the same criteria for the daily schedule or switch--only if there are inactive devices to report). May be useful for testing.
- Advanced options: configure logging or restrict sending of notifications to only specific modes (may be useful if using the "switch" option but you want to restrict notifications at certain times).