Hello,
I would like to switch my light to different colors via a webhook, depending on the value “event”.
Basically my script seems to work, but it stops after the first condition. So if “event=Feuer” the script works, but if “event=Gefahrgut” the script stops and does not come to the second condition at all.
Where is my error so that I can use multiple queries?
alias: Test Alarm Webhook 220103
description: ''
trigger:
- platform: webhook
webhook_id: Test_1
condition: []
action:
- condition: template
value_template: '{{ trigger.json.event == ''Feuer'' }}'
- scene: scene.einsatz_beleuchtung_rot
- condition: template
value_template: '{{ trigger.json.event == ''Gefahrgut'' }}'
- scene: scene.ha_einsatz_beleuchtung_lila
mode: single
And on top of that, another question:
How can I link multiple conditions with “Or”.
So for example
value_template: '{{ trigger.json.event == ''Feuer1'' }}' OR '{{ trigger.json.event == ''Feuer2'' }}' OR '{{ trigger.json.event == ''Feuer3'' }}'
Thanks a lot