Step 2: Create a passage to request the user's name

Now that we've created our variable, we need to create the passage where we assign a value to it.

It's important to consider the flow of conversation when planning out when you will assign and use your variables: make sure you're setting variables early in the conversation flow if you want to use their values.

In this guide, we're using our variable to store our user's name during the chatbot's welcome conversation. First, let's create the passage where we ask them their name:

  1. Open the Create section of the left-hand navigation.
  2. Click Conversations.
  3. Click the Welcome conversation.
  4. Click the Passage icon to create a new passage in the conversation.
  5. Rename the passage to Request user name.
  6. Add some text messages to greet the user and ask their name.
  7. In the Expected Response section, click Send Info.
    Leave the default configuration of creating a new passage. We'll use that new passage in a moment.
  8. Click Save.

We have our variable, and the passage where we're asking the user their name. In the next step, we'll assign their response to our Username variable.

Was this article helpful?
0 out of 0 found this helpful



Article is closed for comments.