I am trying to get a phone notification automation working to run my vacuum if it hasn’t been ran for a few days.
I have an automatic automation working so when everyone leaves the house, the vacuum runs and stores the date it ran.
Now I am having trouble with getting the phone notification running.
Here is what I have after researching for quite a while.
- id: '1677698617602'
alias: Vacuum Run Notification
description: ''
trigger:
- platform: time
at: 09:00:00
condition:
- condition: template
value_template: '{{ now() - state_attr(''input_datetime.vacuum_last_ran'', ''last_triggered'')
> timedelta( days=3 ) }}'
action:
- service: notify.mobile_app_jason_pixel_6_pro
data:
title: Run The Vacuum?
message: It has been 3 days since the vacuum has ran, do you want to run it
now?
data:
actions:
- action: URI
title: Run Vacuum
uri: /lovelace-mobile/vacuum
mode: single