I have an automation that monitors 24 input and controls 2 outputs. This automation fires off an email when it runs to alert me the outputs have been controlled. This all works flawlessly. But as I actually have a lot of these automations and each have 24 inputs or so having the Automation99 and automation98 has run makes finding to source manaul process.
How can I include the input reason for the automation in the same email that states what automation ran.
alias: automation99
description: ''
trigger:
- type: door
platform: device
device_id: 4a8ee50f96b03e3ad02d94101db66c0d
entity_id: binary_sensor.10_1_4
domain: binary_sensor
- type: door
platform: device
device_id: 4a8ee50f96b03e3ad02d94101db66c0d
entity_id: binary_sensor.10_2_4
domain: binary_sensor
- type: door
platform: device
device_id: 4a8ee50f96b03e3ad02d94101db66c0d
entity_id: binary_sensor.10_3_4
domain: binary_sensor
- type: door
platform: device
device_id: 4a8ee50f96b03e3ad02d94101db66c0d
entity_id: binary_sensor.10_4_4
domain: binary_sensor
- type: door
platform: device
device_id: 4a8ee50f96b03e3ad02d94101db66c0d
entity_id: binary_sensor.10_5_4
domain: binary_sensor
- type: door
platform: device
device_id: 4a8ee50f96b03e3ad02d94101db66c0d
entity_id: binary_sensor.10_6_4
domain: binary_sensor
- type: door
platform: device
device_id: 4a8ee50f96b03e3ad02d94101db66c0d
entity_id: binary_sensor.10_7_4
domain: binary_sensor
- type: door
platform: device
device_id: 4a8ee50f96b03e3ad02d94101db66c0d
entity_id: binary_sensor.10_8_4
domain: binary_sensor
- type: door
platform: device
device_id: 4a8ee50f96b03e3ad02d94101db66c0d
entity_id: binary_sensor.10_9_4
domain: binary_sensor
- type: door
platform: device
device_id: 4a8ee50f96b03e3ad02d94101db66c0d
entity_id: binary_sensor.10_10_4
domain: binary_sensor
- type: door
platform: device
device_id: 4a8ee50f96b03e3ad02d94101db66c0d
entity_id: binary_sensor.10_11_4
domain: binary_sensor
- type: door
platform: device
device_id: 4a8ee50f96b03e3ad02d94101db66c0d
entity_id: binary_sensor.10_12_4
domain: binary_sensor
- type: door
platform: device
device_id: 582f6c652cb0c6a4247280cb4580403e
entity_id: binary_sensor.05_1
domain: binary_sensor
- type: door
platform: device
device_id: 582f6c652cb0c6a4247280cb4580403e
entity_id: binary_sensor.05_2
domain: binary_sensor
- type: door
platform: device
device_id: 582f6c652cb0c6a4247280cb4580403e
entity_id: binary_sensor.05_3
domain: binary_sensor
- type: door
platform: device
device_id: 582f6c652cb0c6a4247280cb4580403e
entity_id: binary_sensor.05_4
domain: binary_sensor
- type: door
platform: device
device_id: 582f6c652cb0c6a4247280cb4580403e
entity_id: binary_sensor.05_5
domain: binary_sensor
- type: door
platform: device
device_id: 582f6c652cb0c6a4247280cb4580403e
entity_id: binary_sensor.05_6
domain: binary_sensor
- type: door
platform: device
device_id: 582f6c652cb0c6a4247280cb4580403e
entity_id: binary_sensor.05_7
domain: binary_sensor
- type: door
platform: device
device_id: 582f6c652cb0c6a4247280cb4580403e
entity_id: binary_sensor.05_8
domain: binary_sensor
- type: door
platform: device
device_id: 582f6c652cb0c6a4247280cb4580403e
entity_id: binary_sensor.05_9
domain: binary_sensor
- type: door
platform: device
device_id: 582f6c652cb0c6a4247280cb4580403e
entity_id: binary_sensor.05_10
domain: binary_sensor
- type: door
platform: device
device_id: 582f6c652cb0c6a4247280cb4580403e
entity_id: binary_sensor.05_11
domain: binary_sensor
- type: door
platform: device
device_id: 582f6c652cb0c6a4247280cb4580403e
entity_id: binary_sensor.05_12
domain: binary_sensor
condition: []
action:
- type: turn_on
device_id: 582f6c652cb0c6a4247280cb4580403e
entity_id: switch.out2
domain: switch
- type: turn_on
device_id: 4a8ee50f96b03e3ad02d94101db66c0d
entity_id: switch.1
domain: switch
- service: notify.email
data:
message: automation99 is on
data:
level: error
priority: highest
mode: single