I see a lot of people who use Node-RED as their automation engine looking for a way to trigger a flow from the Home Assistant UI. Here’s how I do it.

First I created an empty script.


script:
  good_morning:
    sequence:


And a button in Lovelace.


- type: entity-button
  entity: script.good_morning
  name: "Good Morning"
  icon: mdi:coffee
  tap_action:
    action: call-service
    service: script.turn_on
    service_data:
      entity_id: script.good_morning


Then in Node-RED.


flow


The events: all node checks only events of type call_service.


events


The switch node checks which script was called.


switch


The call-service node turns on my bedroom ceiling lights in a 30 seconds transition.


call-service


When I press the button (below) in the UI or say “Hey Google, good morning” 1 the flow is triggered and the lights turn on.


button


I prefer this approach because I do not like the idea of using input_boolean for this. It would be like using a light switch to activate a doorbell.

  1. The script was exposed to Google Assistant using Home Assistant Cloud