Simple Mobile Notification when device becomes unavailable

Simply sends a message to your phone telling you which tracked device is disconnected or otherwise unavailable in state for more than 30 seconds.

blueprint:
  name: Entity Unavailable Notification
  description: Sends notification of which entity has lost connection

  domain: automation
  input:
    entity_name:
      name: Entity
      description: Device to check
      selector:
        entity:
    notify_device:
      name: Device to notify
      description: Device needs to run the official Home Assistant app to receive notifications
      selector:
        device:
          integration: mobile_app

mode: queued
max: 10

trigger:
  - entity_id: !input entity_name
    for: '30'
    platform: state
    to: unavailable
action:
  - device_id: !input notify_device
    domain: mobile_app
    type: notify
    message: '{{ trigger.to_state.name }} disconnected'
3 Likes

Nice job, but this one is somehow wrong for me, I am limitted to home assistant companion, despite the fact that we have plenty of notification integrations ( i use telegram mostly). Can we select a notifier from notify.* service ?

yeah I’m not entirely sure on how to do that based on the documentation, since every device and integration for notifications is its own service (e.g notify.mobile_app_sm_g000). Currently selector let’s you choose entities as the broadest option, not service types. I could be wrong though, I’m half-asleep :sleeping:

Nice work!

Is there any way to take a list of entities as input?

I’m thinking about a connectivity check. I’m using a WiFi repeater, and I’d like to receive an alert if all entities in a list of entities are unavailable, because that would mean a WiFi repeater problem.

1 Like

And I would like to use a list of ZigBee or Z-Wave devices to monitor for when they go offline.

1 Like

I have been meaning to create an automation like this for my Wyze sensors, randomly they go down and I have to restart the VM to correct it. This should handle it perfectly.

Its a nice blueprints. Only limited to 1 device… maybe you can eddited it for more devices?

2 Likes

Thank you for this blueprint. Really helpful!

A give a +1 on increasing the number of unavailable devices you can select.

Is there any way of implementing this?

1 Like

you can add them in a list by separating with a comma.
example: cover.garage_door,binary_sensor.front_door,binary_sensor.back_door

1 Like