my automations.yaml file is like this:
- id: '1580730150400'
alias: Poco Away
description: ''
trigger:
- entity_id: binary_sensor.maindoor
platform: state
to: 'on'
- entity_id: binary_sensor.maingate
platform: state
to: 'on'
- entity_id: binary_sensor.gatestairs
platform: state
to: 'on'
- entity_id: binary_sensor.bathroom_pir
platform: state
to: 'on'
- entity_id: binary_sensor.motion_sensor_158d0002246c35
platform: state
to: 'on'
- entity_id: binary_sensor.sonoff2_pir
platform: state
to: 'on'
condition:
- condition: state
entity_id: binary_sensor.pocophone
state: 'off'
action:
- data:
message: alert {{ trigger.to_state.state }} + {{ trigger.entity_id }}
service: notify.telegram
the automation is triggered, but the message isn’t sent. i think it’s in my syntax. i tried using just the word alert, and it sends. i need to have the entity_id that triggers the automation and it’s state sent also. how do i do this?
Thank you