Automation triggers when HA reboots / smart plug does a reconnect via WiFI

Hi all,

i have several automations runnning which does notify me when the shelly smart plugs do measure certain power consumptions, e.g. when the washing machine is finished.
This is working quite fine after some tweaking.
But i do get also notification when the shelly does a wifi reconnect (e.g. shelly plug does an update or the access points do an update) or HA does a restart.

My automation does look like this:

alias: Waschmaschine
description: ""
  - type: power
    platform: device
    device_id: e0ed35e064714065217fd82672938142
    entity_id: sensor.steckdose_waschmaschine_shell_power
    domain: sensor
    below: 2.5
      hours: 0
      minutes: 2
      seconds: 0
  - condition: template
    value_template: >-
      {{ as_timestamp(now()) -
      as_timestamp(states.automation.waschmaschine.attributes.last_triggered) |
      int > 1880 }}
  - condition: time
    after: "05:00:00"
    before: "23:59:59"
      - mon
      - tue
      - wed
      - thu
      - fri
      - sun
      - sat
  - service: notify.mobile_app_iphone_14pro
      message: Waschmaschine ist fertig
  - service: notify.mobile_app_janas_iphone
      message: Waschmaschine ist fertig
mode: single

As i have not found a solution how to except those notification, do you guys have an idea?

Add a condition that prevents execution of the action if Home Assistant was recently started (i.e. within the last 5 seconds). The Uptime integration provides a sensor that reports the elapsed time since startup.

1 Like