How LONG DOES the WAIT node actually wait? And how can i use it for longer waits

I am running a few workflows and would like to use the wait node to execute a few functions.
1, Wait for a specific amount of time eg, 5 hours, before it can trigger
2, Wait for a specific webhook to happen before it can start.

The documentation has some explanation on this but does not quite explain it. My main question is,
How can I make my workflow wait for more than 70 seconds ie hours or days, and also e able to wait until a webhook is called.

This is a useful one, especially if you are looking into doing some sequences that rely on specific workflow events that cannot be handled by the triggers or schedule node.

It looks like your topic is missing some important information. Could you provide the following if applicable.

  • n8n version:
  • Database (default: SQLite):
  • n8n EXECUTIONS_PROCESS setting (default: own, main):
  • Running n8n via (Docker, npm, n8n cloud, desktop app):
  • Operating system:

The wait can wait as long as you want.
Above a certain amount of time it saves the execution time to the database and then runs when it hits that time, so you could theoretically have a workflow wait for a year or more, though there would definitely be more practical ways to handle that.

See this workflow below on how to delay until a webhook is called.
I show it being emailed but you would likely send it over an http call or an execute workflow node. Once that url is called the workflow will resume.

If you click in the wait node you’ll also see there is a limit time. I set it to run in 24 hours whether or not the url was called.

3 Likes

Thank you @liam You are a time saver. I was lost on how to use the webhook. If I have several webhooks, how do I append the suffix for each

I’m not really sure what you mean here.

Do you mean several webhooks that could resume the workflow?

If I have several workflows on one canvas that get triggered via webhooks ie if I have two webhook triggers, how do we identify which {{ $execution.resumeUrl }} to use?

There is not a way to identify which to use as the resume webhook works by execution for every resume on webhook node in the workflow.

The resume webhook is simply follows the syntax below:

https://{{ yourN8nUrl.com }}/webhook-waiting/{{ execution ID }}

So even if you have two wait nodes in a row like this:

The same link will resume both, but not both at once. the “Wait 1” node and “Wait 2” node will each need their own webhook call to resume, but using the same link.

Simply put, it doesn’t matter because it will always have the same resume link regardless of where in the workflow and all wait nodes share the same resume link

1 Like

Perfect. Thank you @liam

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