Recognize and validate user input.
The system entities can help your chatbot validate information such as email addresses or phone numbers. You can save collected data as attributes and pass them to your external systems.
ChatBot offers different system entities:
-
email address
-
number
-
integer number
-
phone number
-
URL
-
temperature
-
Yes and no entities
-
Yes-no entities
How to use system entities
Let’s create a taxi booking bot and use system entities to collect information.
-
Create a new Story or use the existing one.
-
Add User input block to the Bot response block called Welcome message.
-
Open the block you’ve added.
-
In the User says section, use the system entity to get an integer number. To do that, type two curly brackets
{{
to open the entity window. Choose the Parameter validation: Number and set the attribute’s name tonumber
. -
Add a new Bot response block after the User input.
-
Open the added block and complete your bot response.
-
Test our ChatBot Story and see whether it works as intended.