A flow is a series of steps the bot runs when a customer’s message contains one of its trigger words. For where flows come in the bot’s order, see How AI answers are built.
Before you start
Section titled “Before you start”- Owner, admin or manager role in Soosh
- A computer. On a phone you can look through a flow, but it’s best edited on a computer.
Create the flow
Section titled “Create the flow”- Go to Automation > Bot flows (opens Soosh in a new tab) and click Create flow.
- With no step selected, the panel on the right shows Flow settings. In Name, enter what the flow does, like Order status.
- In Trigger keywords, enter the words that start it, separated by commas,
like
order, track, where is my. - Under Add a step, click a kind of step. The first one is joined to Start for you.
- Click the step on the canvas to set it up in the panel on the right.
- To add the step that comes next, keep a step selected and click another kind under Add a step. It goes below the selected step and follows it. You can also join steps by dragging from the dot under one step to the next, or by choosing a step under Next step.
- Click an empty part of the canvas to show Flow settings again. Fix anything listed under To fix.
- Turn on Flow is on.
- Click Save.
A new flow starts off, so it doesn’t run until you turn on Flow is on. If steps aren’t joined up yet, turning it on asks first and lists them; click Turn on flow to go ahead. To stop the flow starting without deleting it, turn off Flow is on.
To change a flow that’s running without touching it, click Make a copy next to it in the Bot flows list. The copy starts off.
Set up the steps
Section titled “Set up the steps”Each step has its own settings in the panel on the right. In any message,
{{contact_name}} and the names you saved, like {{order_number}}, are filled
in. {{phone_number}} is the customer’s number without +.
- Message: sends a text. To wait for the customer’s answer, choose what you expect in Wait for a reply, then save the answer, like an order number, in Save the reply as. To check the answer, enter a Pattern the reply must match (optional) and the Message when the reply doesn’t match. Times to ask again sets how often it asks.
- Buttons: sends a message with buttons. Click Reply button to add up to 10, and join each one to its own next step. Or click Link button or Phone button to add up to 2, which can’t be mixed with reply buttons.
- WhatsApp form: sends a form. Under WhatsApp form, choose one of your published forms from the list. Set the message’s Heading and the Button label the customer taps.
- Products: sends products from a catalog. Click Choose products, tick one or up to 30, and for several add a Heading and a Message; both can use the flow’s variables. Products go from numbers connected to the catalog’s WhatsApp Business Account; other numbers send the message alone.
- AI reply: the AI answers using your workspace’s AI settings and knowledge. In What to ask the AI, write what it should do, or leave it empty to answer the customer’s last message. If AI is off or has no answer, the flow carries on.
- API call: asks your system, like your order system. Enter the Web
address, Method, Headers and What to send. Under Save details
from the reply, click Add detail to save parts of the answer under
names, like
namefromdata.user.name, for later steps. - Set variable: saves a value for later steps. Click Add variable, then
enter a name and a value. A value can use other saved names in double
braces, like
{{order_number}}. - Condition: goes one way or another, depending on what was saved. Write a
rule in Condition, like
tier == "premium" and amount > 100. Join True and False to the steps that follow. - Business hours: goes one way when you’re open and another when you’re closed. Under Open hours, set each day’s opening and closing time, and join Open and Closed. A closing time earlier than the opening time runs into the next day, like 18:00 to 02:00. The times use your workspace’s time zone.
- Hand over: hands the chat to a team or the General queue. Write the Message before the hand-over and the Note for the agent.
- Go to flow: carries on in another flow. Choose it in Bot flow to go to.
- Create or update lead: makes the customer’s lead, or fills in the one they have, from what they answered. See Create or update a lead in a bot flow.
- End: ends the flow. To send something first, write it in Last message (optional).
Add messages for the start and the end
Section titled “Add messages for the start and the end”These are in Flow settings, with nothing selected on the canvas.
- Optional: in Initial message, write what the customer gets when the flow starts, before its first step.
- Optional: in Completion message, write what they get when the flow finishes.
- Optional: to tell your own system when a flow finishes, open On completion, choose Send to API/Webhook as the Action, and enter the URL. Leave Request body (JSON) empty to send the flow, the contact and everything the flow saved, as JSON.
A flow finishes when it reaches an End step, or a step with nothing joined after it. It doesn’t finish when a Hand over step or an AI handover passes the chat to your team. Then no completion message goes out and the webhook doesn’t run.
To show saved values to agents in the chat’s Contact info panel, use Contact panel display in Flow settings.
Try it
Section titled “Try it”Click Preview. Try this flow opens and starts by itself. The chat looks like one in the inbox: you answer as the customer, by typing or by choosing a button, and the bot’s answers come back with the step they came from under them, like Step: Message. The message box tells you what to do next. Nothing is sent to WhatsApp.
- Undo takes back your last answer and asks that question again.
- Start over begins again.
- What happened shows the details the flow saved under Saved details, and the steps so far under Steps so far, in words. Under Start from a step, choose a step to try one branch without answering the questions before it. On a phone, What happened is a tab next to Chat.
- For API call steps you enter what your system would answer. A Hand over step shows a line saying the chat would go to a person. An AI reply step and the webhook after a flow don’t run in a try.
History
Section titled “History”Every save is kept, up to the latest 50. Click History to see them.
- Click a version to see it on the canvas. It’s read-only, and your own version is kept.
- To go back to it, click Restore this version, then Restore version. The current version stays in the history, and the flow stays on or off as it is.
- To stop looking, click Back to the current version.
Result
Section titled “Result”With Flow is on turned on, the flow runs for every new message that
contains a trigger word. A trigger word has to match a whole word, whatever the
capitals: order matches “Where is my order?” but not “reorder”. If two flows
match, the one with the longest trigger word starts. The badge at the top
shows On or Off. You can also turn a flow on or off from the Bot
flows list.
If you leave the builder with unsaved changes, Soosh asks first. Choose Stay to keep editing or Leave to drop the changes.