How to make flow wait for response of actionable notification / no retrigger

Hi everyone. I have a flow that sends out an actionable notification (iOS) to ask whether I want to start the washing machine when solar production is up and consumption is down.

Currently, the flow retriggers and keeps sending notifications whenever the solar-production-state (first node) changes.

How can I prevent this from happening? Thanks for your help!

How will you determine the next time to send out the message?
Does the washing machine send a msg when it is,done?
You could use a gate node after the node where the notification comes in. Once a msg gets passed thru, close the gate.

The issue is determining when to reopen the gate. Maybe when you indicate the washer should run, set a timer for the length of the wash, then send a msg to the gate to re open.

But what happens if the electric rate goes up before you tell the washer to run, or if the rate goes up while it is running.

What if you miss the first notification, you will need a timer to reset the gate after a length of time if you haven’t replied.

BTW, what nodes are you using to get the rate and send the msg to iOS?

Thanks for the reply @zenofmud

I can make the washer send a message when completed, yes. This would take care of "when to send it next time".

How does a gate node work?

What about using a critical notification to ensure not to miss it (and make is persistent):
Ref: Critical notifications | Home Assistant Companion Docs

To answer your questions: What if: i would not worry about those for now.

Currently I am using CALL_SERVICE nodes (Home Assistant)

best place to look is in the node's documentation see node-red-contrib-simple-gate

Here is a simple flow showing how it works:

[{"id":"b8777bb45a883fe0","type":"inject","z":"a28015d0574dbca4","name":"","props":[{"p":"payload"},{"p":"topic","vt":"str"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","payload":"","payloadType":"date","x":140,"y":60,"wires":[["2409e9e194bacc83"]]},{"id":"544c85eb742490a1","type":"gate","z":"a28015d0574dbca4","name":"","controlTopic":"control","defaultState":"open","openCmd":"open","closeCmd":"close","toggleCmd":"toggle","defaultCmd":"default","statusCmd":"status","persist":false,"storeName":"memory","x":570,"y":140,"wires":[["cb97c09d16c64da0"]]},{"id":"8b15f49302c08e75","type":"change","z":"a28015d0574dbca4","name":"open gate","rules":[{"t":"set","p":"topic","pt":"msg","to":"control","tot":"str"},{"t":"set","p":"payload","pt":"msg","to":"open","tot":"str"}],"action":"","property":"","from":"","to":"","reg":false,"x":340,"y":120,"wires":[["544c85eb742490a1"]]},{"id":"cb97c09d16c64da0","type":"debug","z":"a28015d0574dbca4","name":"debug 26","active":true,"tosidebar":true,"console":false,"tostatus":false,"complete":"false","statusVal":"","statusType":"auto","x":780,"y":140,"wires":[]},{"id":"2409e9e194bacc83","type":"trigger","z":"a28015d0574dbca4","name":"","op1":"1","op2":"0","op1type":"str","op2type":"str","duration":"250","extend":false,"overrideDelay":false,"units":"ms","reset":"","bytopic":"all","topic":"topic","outputs":1,"x":360,"y":60,"wires":[["550d654d2b728d34"]]},{"id":"550d654d2b728d34","type":"change","z":"a28015d0574dbca4","name":"close gate","rules":[{"t":"set","p":"topic","pt":"msg","to":"control","tot":"str"},{"t":"set","p":"payload","pt":"msg","to":"close","tot":"str"}],"action":"","property":"","from":"","to":"","reg":false,"x":550,"y":60,"wires":[["544c85eb742490a1"]]},{"id":"f87b82817d7ac388","type":"inject","z":"a28015d0574dbca4","name":"","props":[{"p":"payload"},{"p":"topic","vt":"str"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","payload":"","payloadType":"date","x":140,"y":120,"wires":[["8b15f49302c08e75"]]},{"id":"15d988adf9dbe9a5","type":"inject","z":"a28015d0574dbca4","name":"","props":[{"p":"payload"},{"p":"topic","vt":"str"}],"repeat":"1","crontab":"","once":false,"onceDelay":0.1,"topic":"","payload":"","payloadType":"date","x":150,"y":180,"wires":[["544c85eb742490a1"]]}]

as for the 'critical notivication' I'm not a Home Assistant user (nor are many here) so I can't help you with that part.

Thanks a lot! That solved my problem. Using it for other notifications too now.

Appreciate your help!

This topic was automatically closed 60 days after the last reply. New replies are no longer allowed.