Hello
I have Samsung SmartTag and get a notification in my phone when pressing the button.
I want to use this message as a trigger to change a switch.
This code I have placed in Automation.yaml
I dont see that the switch is changed.
Last_,notification is enabled in companion App
- alias: EnableChargeMoped
description: ‘’
trigger:- platform: template
value_template: ‘{{ ‘‘Tryckte’’ in states(’‘sensor.SM_g973f_last_notification’’)}}’
condition: []
action: - type: turn_off
device_id: 5b9f65cc5162ba630321866c8db113ca
entity_id: switch.lampatakplatrum2
domain: switch
mode: single
- platform: template