How to trigger a flow in node-red from HA lovelace ui?

image

type: button
tap_action:
  action: call-service
  service: nodered.trigger
  service_data:
    entity_id: switch.lovelace_button
name: Lovelace Button
entity: switch.lovelace_button
type: button
tap_action:
  action: call-service
  service: nodered.trigger
  service_data:
    entity_id: switch.lovelace_button
    payload: hello
name: Lovelace Button
entity: switch.lovelace_button
type: button
tap_action:
  action: call-service
  service: nodered.trigger
  service_data:
    entity_id: switch.lovelace_button
    payload:
      test: 123
      abc: xyz
name: Lovelace Button
entity: switch.lovelace_button

image

[{"id":"123ae7c0.58ab28","type":"ha-entity","z":"70481014.55bbc","name":"","server":"9c202bd8.b64db8","version":1,"debugenabled":false,"outputs":2,"entityType":"switch","config":[{"property":"name","value":"Lovelace Button"},{"property":"device_class","value":""},{"property":"icon","value":""},{"property":"unit_of_measurement","value":""}],"state":"payload","stateType":"msg","attributes":[],"resend":true,"outputLocation":"","outputLocationType":"none","inputOverride":"allow","x":212,"y":672,"wires":[["e69a1437.7ee568"],[]]},{"id":"e69a1437.7ee568","type":"debug","z":"70481014.55bbc","name":"","active":true,"tosidebar":true,"console":false,"tostatus":true,"complete":"payload","targetType":"msg","statusVal":"payload","statusType":"auto","x":390,"y":672,"wires":[]}]

image

11 Likes