Last updated: 02 June 2021 

Logical integrations allow you to move the chatbot user through conversations based on one or multiple integration calls. Logical integrations are often used to:

  • Verify a purchase before sending a 'thank you' message to the user.

  • Verify calendar dates are available before allowing the user to book a meeting.

  • Verify a user's location before changing a chatbot's default language.

And more.

Step 1: Ensure you have an active integration

Head to Integrations and make sure your integration is properly set up.

Your integration should have:

  • A base URL

  • An authorization method

  • Relevant headers

  • At least one endpoint

  • Variables inside its endpoint's keys and values

Step 2: Tie your logical integration

Logical integrations happen in transit between two conversation steps.

You can use them to send to users down branch A or B of the conversation, depending on what the integration returns.

Head to Builder.

Click View on the conversation you want to use.

At the step of your logical integration, click Options.

Go to Transitions.

In the events dropdown, select Making an API request.

Select your integration and endpoint.

There are two types of validation you can use.

  1. Status code: progress the conversations based on your integration failing, succeeding, or returning server errors.

  2. Response body: progress the conversation based on your integration returning a specific data point (e.g. an email address, phone number, true/false, etc.).

Hit Save.