#How to create an automation with start and end actions with a debouncing timer?

1 messages · Page 1 of 1 (latest)

dull thistle
#

I want to trigger an start action when an entity changes state to ON -- call a webhook and save the contents of the response (contains event_id)
Once start action is done, I want to wait until that entity goes back to OFF, and stays OFF for 10 seconds. If it turns back ON I do no want to do the start action but just restart my 10-second timer. And this may happen many times.
Eventually when it stays OFF for 10 seconds, I want to trigger another webhook action (using the same event_id I had gotten in start action)

How do I do this?

nimble geyser
#

For the latter part, you can use a wait_for_trigger with a for:

terse holly
#

You can set the automation to skip other runs while it is still running and then at the end add a "wait for trigger"

dull thistle
#

@terse holly can you describe how to do " skip other runs" ?