Wetel
Go back

Waiting for a reply without holding anything up: how an AI employee asks and carries on

A good clerk who needs something from a customer does not stand at the desk until the customer phones back. They write a note on the file, “waiting for the customer: which order do they mean?”, put the file in the tray and serve the next person. When the customer calls, the clerk picks up that file, reads the note, and carries on from that exact line. Nothing was redone, and nobody queued behind an idle clerk.

An AI employee on Wetel works the same way with the await_reply step. It asks the question, puts a note on the file, and lets go. This post is for the developer building the workflow and the operations lead looking after it, and a person on your team stays in charge of both: they publish the workflow and can see every paused conversation.

What does the await_reply step do?

It sends the customer a question, ends the current turn, and continues the same workflow from the step after it when the next message arrives on that conversation. Nothing is held open while it waits: no job, no worker and no open connection. The steps before the question do not run again.

That last point is the reason the step exists. By default, every message a customer sends starts a brand-new run at the top of the workflow, and nothing your steps worked out carries over except the transcript. A workflow that needs several turns usually gets by with an llm step re-reading the conversation and inferring where things stand. await_reply is the one structural exception: it writes a real “waiting for an answer to this” record, so the next message is treated as the answer to that specific question rather than left to inference.

sequenceDiagram
participant C as Customer
participant W as Workflow
C->>W: "Where is my order?"
Note over W: Look up open orders, then await_reply asks which one
W->>C: "I found a few open orders: 1. ... 2. ... Which one?"
Note over W: Run saved as AWAITING_INPUT. Nothing is held open.
C->>W: "2"
Note over W: A new run resumes after the question.<br/>The order lookup does not run again.
W->>C: "Order 2 is on its way."

What does it look like in a workflow?

This is the question step from the docs’ worked example, a shipping assistant that found several orders and asks which one the customer means (all data fictional):

{
"id": "ask_which_order",
"type": "await_reply",
"label": "Which Order?",
"config": {
"promptTemplate": "I found a few open orders on your account:\n\n{{#each awaitReplyOptions}}{{slot}}. {{label}}\n{{/each}}\nWhich one would you like an update on? Reply with the number.",
"saveAs": "chosenOrder",
"matchMode": "options",
"optionsFrom": "orderLookup.data",
"optionIdField": "order_id",
"optionLabelField": "description",
"expiresAfterSeconds": 86400,
"mood": "helpful"
},
"position": { "x": 0, "y": 200 }
}

The routing lives on two labelled edges. answered is required on every await_reply step. unanswered is required in options mode, for a reply that matched nothing. Both rules are checked when you save or publish, not discovered in the middle of a conversation.

One honest caveat: the docs say the dashboard’s workflow builder does not yet show a form for this step. You write it in the workflow JSON through the API and publish as usual; check the changelog for when that changes.

What does the customer see?

They see the question as an ordinary message, and then nothing until they reply. The question always marks the turn as complete (turnComplete: true), because the turn genuinely is over until a person answers. If your chat window decides “the AI employee has finished” with a silence timer instead of turnComplete, it can cut the turn off early or hang; watch turnComplete.

When they reply, the workflow carries on with the answer in place: in the example, chosenOrder.id feeds the status lookup and the first order lookup is not called again.

How is the reply matched to the question?

In free_text mode, the whole reply is the answer, saved as text.

In options mode, the list is fixed at the moment the question is asked and stored with the wait. When the reply comes in, matching reads only that stored list, never anything the new message claims, so a later message cannot widen the set of acceptable answers. Matching tries, in order:

  1. the slot number shown (“2”),
  2. the exact id, ignoring case,
  3. the label with case, accents, punctuation and plurals folded,
  4. a unique whole-word match, so “the solution architect role” or just “architect” can pick a “Solution Architect” option.

Every tier needs exactly one winner. No match, or two or more, sends the reply down unanswered with the raw text saved, never a guess. A clean “sorry, which one?” beats a confident update to a record nobody chose.

The documented limits: at most 20 options per question (extras are dropped), and labels are cut to 80 characters. If the list to offer is missing or empty, the step fails rather than quietly becoming a free-text question, so put a condition step in front if “offer a list when there is one, otherwise ask openly” is what you want.

How long does it wait?

24 hours by default. You can set expiresAfterSeconds per step, up to a ceiling of 7 days. The deadline is checked when the next message arrives.

What happens if the customer never answers?

Nothing, on purpose. Once the wait has expired, the next message simply starts a fresh run from the top of the workflow, exactly as if the question had never been asked. An expired wait does not take the unanswered edge, and Wetel will not send an unprompted message hours later into an abandoned conversation.

So there is no “expired path” to wire up. Instead, make sure the top of your workflow copes with a customer who comes back days later and says “2” out of context.

If the business needs a real deadline (“chase after 10 minutes”, “release the held order if they don’t confirm”), build it on your side: a scheduled job of your own that checks pendingAwaitReplies and then acts, for example by starting a task with runWorkflowTask. Do not size a business promise off the expiry window.

What else closes a waiting question?

What carries across the pause?

The workflow’s own variables, as they were when the question was asked, capped at 256 KB. A workflow carrying more than that fails at the question step with a named error rather than silently cutting data, so drop large documents you no longer need before the pause.

What does not carry, because the reply brings its own: the new message, the conversation history, the ids, and that turn’s attachment facts. If the workflow needs a file the customer sent before the question, copy what you need into your own variable first.

How do I see who is waiting?

A paused run has its own status, so “waiting on the customer” is something you can query rather than guess.

The saved context a paused run will resume with is deliberately not exposed by any query.

How is this different from an approval step?

Both park the run with nothing held open, and both continue down a labelled edge. The difference is who answers: in await_reply the customer answers in the chat; in an approval step a workspace owner decides in the approvals inbox, and the customer hears nothing from that step.

await_replyapproval
Who answersThe customer, in the conversationA workspace owner, in the approvals inbox
Default wait24 hours72 hours
Longest wait7 days14 days
Edgesanswered, unansweredapproved, rejected, expired
When time runs outNo edge; next message starts overFollows the expired edge

Use await_reply when only the customer can supply what is missing. Use an approval step when a person on your team should sign off before the AI employee acts; designing approval steps people actually read covers that side.

Design tips

  1. One question at a time. A conversation can hold exactly one open question; a second is refused. Ask for one thing, get it, then ask the next.
  2. Prefer a list when the answer is a record. options mode with an unanswered edge beats free text when the customer is choosing between orders, roles or bookings.
  3. Bound your own re-ask loop. An unanswered branch that routes back to the question re-asks once per message, indefinitely, because each reply is a new run. For “after three tries, hand to a person”, count the attempts in a variable and gate the loop with a condition step.
  4. Design for the customer who comes back late, since an expired question has no path of its own.
  5. Keep questions in the main workflow. A sub-agent runs on a session nobody is watching, so an await_reply there is refused. Ask before or after the hand-off.

What is live today, and what is not built yet

Live today: asking and resuming, free-text and option matching, the 24-hour default and 7-day ceiling, the 256 KB carry-over, and the paused-run status and queries above.

Not built yet:

To add your first question step, start with the Await Reply node reference.


Share this post:

Next Post
What an evaluation score can tell you, and what it cannot
Previous Post
What is a sub-agent, and when would I use one?