I build a (actionable) notification that telle me that a light is on when I’m not home. Now the notification says something like: “There is still a light on”. Would it be possible to make this a variable message that tells me which lamp is on?
This is my config now:
- id: '0000000000010'
alias: Action Push Message
initial_state: 'on'
trigger:
- platform: state
entity_id: group.verlichting
to: 'on'
condition:
condition: and
conditions:
- condition: state
entity_id: device_tracker.iphone_van_r
state: not_home
action:
service: notify.ios_iphone_van_r
data:
message: Er staat nog verlichting aan!
data:
push:
badge: 0
category: lights
action_data:
entity_id: group.verlichting
Thanks. I get some errors, must be something simple with comma or quote or something, but I can’t find it.
Error loading /home/homeassistant/.homeassistant/configuration.yaml: while parsing a flow mapping in "/home/homeassistant/.homeassistant/automations.yaml", line 188, column 17 expected ',' or '}', but got '<scalar>' in "/home/homeassistant/.homeassistant/automations.yaml", line 189, column 75
What is at line 189, column 75 of automations.yaml? Not sure how that error message has anything to do with the template I suggested since there are no less than or greater than symbols, or numbers, in it.
since I use almost the same notification but without the action_data: group.verlichting, I wonder why you use that?
I get correct notifications without …