Using entities in interactions

Image of an author
Luiza Jurczyk
2 min read
updated: Apr 4, 2022

Create entities relevant to your business and reuse them in your stories to verify any user input you need.

Before you startLink icon

  • User entities can be used in the user says section.

  • Use attributes to call values captured by your entities.

  • You must create an entity in the Entities section, before using it in interactions.

  • To call an entity, type two curly brackets {{ $1 }}.

Using Entities in InteractionsLink icon

In this example, we’re using the entities “Countries” that we’ve created together here. In this interaction, we’re expecting clients to type the countries or continents they live in. We can use this information to determine their approximate location or time zone.

  1. Go to your stories and create a new interaction.

  2. Add a few phrases that your clients or visitors might enter when telling their location. Remember to add the entity. To do so, type double curly brackets, now you should see all valailable entities. Select countries and name your new attribute.

  3. Now, we can create the reply. Go to the bot responses and type your message.

  4. To check if our entity works, we can use an attribute. Add again {{ countries }} to call the value given by the user.

  5. Click on the save button to keep your changes.

To pass information within an interaction or to your webhooks, use attributes.
To pass information within an interaction or to your webhooks, use attributes.

See Also:Link icon

Was this article helpful?

Got it!

Thanks for your feedback.

Thank you!

We’re happy to help.

Start a free ChatBot trial
and build your first chatbot today!

Free 14-day trial No credit card required

Discover our text| products