Table of Contents

How to use Questions for Chatbot builder?

Helpdesk Updated by Helpdesk

Using Question Box in Wati Chatbot Builder

The question dialogue box is very simple in Chatbot Builder and it is the most used one.

Parts in Question Box

  1. Question text: In this question box, you can add a question text that would be highlighted on the screen. In the text, you can add variables, emojis. Change the text to Bold, Italic, Strikethrough.

As you can see in the above image there are variables added, variables are anything that are saved answers of the users and which I will talk about later. Anything that follows @{Variable Name} is a variable.

There are also emojis added to make the question look user-friendly.

  1. Add answer variant: it's under the Question Text, which you would provide the user to choose from for the question text that you typed in above.

In the above image, you can see that there are two answer options and we can delete and create more.

When you give a user answer options they have to type in the number according to the answer.

So in this case:

Yes = 1

No = 2

So, if a user types in 1 the answer selected will be "Yes"!

If you want the user to enter a custom answer, you may leave the answer options empty, and then the user can freely answer it.

What if the user does not answer 1 or 2 but answers "hi", so there is always a fallback option that you could link to the chatbot if the answer is not matched to any answer variant.

It looks something like this:

The last option being "General" is used for a fallback if any answer not matched by the user is there then this would be the ideal option to guide the chatbot forward.

  1. Save Answers in a variable: This field is to store the user's reply value into the variable. This variable then can be used to put into another condition or to display again what value that user chose. The below sample showing one case that can use this part.
Step 1: Store answer into variable
Step 2: Check value of variable and set condition
  1. Advanced options:

This option can be used only when the user doesn't specify the "Add answer variant" part. In another word, if the user inputs options in the "Add answer variant" part, "Advanced options" is disabled and vice versa.

This part is used to put validation against the customer's reply. Depend on which data we want the customer to fill in.

***Number:

When choosing validation "Number", the user needs to fill in Min value and Max value.

There is a default validation message, user can also change it to their message eg "Sorry, number of items need to be more than 0 and not greater than 1000. Please try again".

The last item of this part is "Exit chatbot if validation failed more than ... times". That is to trigger exit chatbot if a user still replies wrong after .... times. Users should set up this option, otherwise, customers cannot quit the chatbot if they don't want to ask more related to the current chatbot. If a user still wants the system to keeps asking until the customer input the correct value, which means ignore the fallback, the user can fill the ...times = 0 times.

***Date:

When choose validation Date, user can only input below format: M/d/yyyy, MM/dd/yyyy, M/dd/yyyy, MM/d/yyyy.

For example 1/1/2021, 01/11/2021, 1/11/2021, 01/9/2021

***Date + Time:

When choose validation Date + Time, user can only input below format (validating against the 12-hour clock):

  • M/d/yyyy h:mm:ss tt (1/9/2021 8:00:00 AM)
  • M/d/yyyy h:mm tt (1/9/2021 8:00 PM)
  • MM/dd/yyyy hh:mm:ss (12/25/2020 03:59:05)
  • M/d/yyyy h:mm:ss (1/9/2021 8:00:00)
  • M/d/yyyy hh:mm tt (1/9/2021 11:50 PM)
  • M/d/yyyy hh tt (1/9/2021 11 PM)
  • M/d/yyyy h:mm (1/9/2021 8:00)
  • MM/dd/yyyy hh:mm (12/29/2019 03:30)
  • M/dd/yyyy hh:mm (1/19/2020 09:20)

***Time:

When choose validation Time, user can only input below format:

  • hh:mm tt (02:35 PM)
  • h:mm tt (2:37 PM)
  • HH:mm:ss (14:37:21)
  • H:mm (8:25)
  • HH:mm (08:57)
  • H:mm:ss (8:57:00)
  • hh:mm:ss (02:37:00 )
  • h:mm:ss (2:37:00)
  • h:mm (2:37)
  • hh:mm (03:36)
  • h:mm:ss tt (2:37:00 PM)
  • hh:mm:ss tt (02:37:00 PM)

***Pattern (regex):

When choose validation Pattern (regex), user need to fill in Regex pattern format, some example patterns below:

To filter for a name (alphabets and no numbers or emojis): ^([a-zA-Z\s]+)$

To filter for an email address: ^([a-zA-Z0-9_\-\.]+)@([a-zA-Z0-9_\-\.]+)\.([a-zA-Z]{2,5})$

To not allow emojis: ^(?!.[^\u0020-\u007e\u00a0-\u00ff\u0152\u0153\u0178])$

To filter for something like an Instagram handle (e.g instagram.com/example123): ^instagram\.com/([a-zA-Z0-9_\-\.]+)$

Chatbot example:

How did we do?

How to use Conditions for Chatbot Builder

How to build a chatbot?

Contact