Wait
Category: Logic & Control
Overview
The Wait node parks the session for a configured duration. The customer’s session stays alive but the recipe makes no progress until the wake fires. Use it to pace a multi-message sequence, schedule a delayed re-prompt, or give an external system time to finish before the recipe continues.
When to use
- Pace a sequence of messages so the bot feels less robotic.
- Delay a follow-up reminder (“haven’t heard back in 30 minutes → re-prompt”).
- Wait for an asynchronous external job to finish before continuing.
Ports
| Port | Direction | Description |
|---|---|---|
in | input | Receives the flow from the previous node. The session parks immediately on entry. |
next | output | Implicit. Fires after the configured duration elapses and the wake-sweeper resumes the session. |
Configuration
Duration
A positive integer paired with a unit picker. The duration is stored as a duration + unit pair; the runtime computes total seconds from those two fields.
Unit
One of seconds, minutes, hours, or days.
Warnings
- Pauses above 24 hours show an inline warning chip — the next outbound message may fall outside WhatsApp’s 24-hour customer-service window and require a template.
- Pauses above 7 days show a blocker chip (“Duration exceeds the 7-day wall-clock cap”). Split the wait into shorter steps or rethink the flow.
Common patterns
Typing-effect message stagger
Message → Wait (2 seconds) → Message → Wait (2 seconds) → Question. Feels less robotic without significantly slowing throughput.
Delayed re-prompt
Question’s invalid port → Wait (10 minutes) → Message (“Still there?”) → Question (retry).
Limits & validation
- The drawer warns above 24 hours and flags above 7 days as a blocker. The runtime itself does not enforce a hard cap; it parks the session at the requested wake time.
- A Wait inside a recipe that finishes (or whose conversation is closed) before the wake fires is effectively cancelled — the session ends and no further nodes run.
Troubleshooting
Wait works in the Simulator but the wake never fires in production.
The wake-sweeper is responsible for resuming parked sessions. Confirm the API workers are running and that the session’s wake_at is set in the bot-engine inspector. If the conversation was closed before the wake fired, the session was reaped — restart from the trigger.
The next message after a long Wait never reaches the user.
If the Wait exceeded 24 hours, the next outbound message may have fallen outside WhatsApp’s customer-service window and required a pre-approved template. Route through a template-aware outbound step or warn the customer up front.