Possible to use templates in a service call in Mushroom Template (Custom) card for double tap action

From researching on the forums here, I know natively lovelace doesn’t support that but I was wondering if the custom Mushroom Template card could pull it off and I just cannot figure out the syntax. Thanks!

      action: call-service
      service: |-
        {% if is_state('climate.living_room_ac', 'off')  %}
        {% else %}
        {% endif %}

AFAIK, the answer is “no”… you will need to move your templated logic to a a script, then call the script as a service from the desired card action. If you check the Mushroom docs the phrase “May contain templates” is notably absent from the actions compared to other available configuration variables.

1 Like

You are 100% correct, I should have dug deeper in that mushroom doc section. Thank you very much.