Receive persistent notification when new entity created

Is there a way to get a notification on the frontend when new entity_id’s are created? Would like to have this as a nice solution with default_view enabled. This way when a new device is autodiscovered by network or rflink or zwave or whatever platform, i will be notified :slightly_smiling_face:

Now i have seen solutions with push notifications but these are for network devices. see example:

#### Notification when a new devices connects to wifi
- alias: Notify for new devices
  trigger:
    platform: event
    event_type: device_tracker_new_device
  action:
    - service: notify.html5
      data_template:
        message: >
          New device:
          {{trigger.event.data.host_name}}
          ({{trigger.event.data.entity_id}})
        title: New device

How can i tranform this to persistent notification for all devices?

see if this helps you:

- alias: New Device Tracked
  id: '1511384756482'
  initial_state: 'on'
  trigger:
    platform: event
    event_type: device_tracker_new_device
  condition: []
  action:
    service: persistent_notification.create
    data_template:
      message: 
        "New Device Tracked: {{trigger.event.data.host_name}}
          ({{trigger.event.data.entity_id}})"
      title: 'New device tracked'

Ah, but that’s only for network devices. I would like to have it for all platforms. Like when I add a new rf temp sensor or when I add a new zwave switch or when autdiscover found a new entity. Then looking for newly created entity’s by scrolling through the list would be the past.

Maybe event_type: platform_discovered might work…

Would like to know this also!

1 Like

I see, though if you create/add them yourself you wouldn’t need a persistent notification wouldn’t you :wink:
Still, let’s see where your suggestion goes . Might be cool.

Yes indeed, but i was suprised when i added a zwave door window sensor for the first time. I first didn’t know there were multiple entities created.

I haven’t tried event_type: platform_discovered yet… hope someone would give it a shot

Years later, but any luck? :grin:

Necrophile, you are… :laughing:

Take a look at this post to get you started:

It’s practically the solution to your question.