search

How to Create a Loop in a Bot

If you have a bot – for example, an FAQ bot – for more information visit: FAQ bot – which you’d like to run again every time an action is finished – you can create a loop that will restart the bot from the very beginning.

Here is a step-by-step guide on how to implement a loop into your existing bot: 

1 ) Add the ‘Visitor clicks the bots button’ trigger

2 ) Add the ‘Chat with bot ended’ action

3 ) Edit the last message sent by the bot 

1 ) Add the ‘Visitor clicks the bots button’ trigger

To add the ‘Visitor clicks the bots button’ trigger – go to the right side of your bot editor, and open the ‘Triggers’ section. Drag the ‘Visitor clicks the bots button’ node onto the map and connect it with the first action.

Tidio chatbot edit - FAQ bot
How to add the ‘visitor clicks the bots button’ trigger

By adding the ‘Visitor clicks the bots button’ trigger – you connect this specific bot with the Bots Launcher tool. This allows your website visitors to click on the bot and activate it again from the beginning. 

2 ) Add the ‘Chat with bot ended’ action

Now, go to the ‘Actions’ section on the right and drag the ‘Chat with bot ended’ node onto your bot’s map. Place it at the very end and connect all the final messages to that action.

'Chat with bot ended' added to the map
Where to add the ‘Chat with bot ended’ action

The loop is now created! Every time your customer arrives at the end of the bot – it will restart and allow the visitor to see all the possible actions again.

FAQ bot starts again - loop is created
How the loop will look like

3 ) Edit the last message sent by the bot 

If you’d like to edit the message sent when the bot is finished, you can change it in the main ‘Chatbots’ section. Click the ‘Bot chat ended message’ found under the ‘Bots Launcher’ list at the bottom.

Where to edit the message sent by the bot at the end
Where to edit the message sent when the bot is finished

All done, now your looped bot is ready to use!

If you have any other issues with the chatbots, please reach out to us at [email protected] or use the chat in the bottom-right corner of our website.

Can't find what you're looking for?

CONTACT SUPPORT