I’m trying to build a TTS message out of multiple if/then statements. Here it is, broken down into two separate messages - but is there a way to combine these two messages into a single message?
sequence:
- service: media_player.alexa_tts
data_template:
entity_id: media_player.jasons_spot, media_player.kitchen_echo
message: >
{% if is_state('input_boolean.basement_secure', 'on') %}
Skynet security analysis running. Basement is secure.
{% else %}
Skynet security analysis running. Basement is not secure.
{% endif %}
- delay: '00:00:04'
- service: media_player.alexa_tts
data_template:
entity_id: media_player.jasons_spot, media_player.kitchen_echo
message: >
{% if is_state('input_boolean.first_floor_secure', 'on') %}
First floor is secure.
{% else %}
First floor is not secure.
{% endif %}