Individual cards

Learn how to create individual cards and how to send the cards to chat users.

Procedure

Creating individual cards

Follow the steps below to create an individual card:

  1. Insert the Create Card command in the script.
  2. Enter the card title in the Title input parameter.
  3. Select either Asset or URL as the card image source in the Source type input parameter.
  4. Enter the imported file or the URL of the image that will appear on the card in the Resource or URL parameter.
  5. Enter the variable name in the Card output parameter. It stores the created card.

Adding button to the card

Follow the steps below to add a button to the individual card:

  1. Insert the Add Button to Card command in the script.
  2. Insert the Card Item variable in the Card input parameter.
  3. Select the button action on the Button action input parameter.
  4. Insert the button text in the Button text input parameter.
  5. Insert the button action value in the Button value input parameter.

Showing the cards in the web chat

To show the created cards by placing them side by side using a card carousel, use the Bot Ask Carousel command.

Follow the steps below to send the carousel with the cards:

  1. Create a List<Card Item> variable.
  2. Insert the Add to Collection command in the script.
    1. Insert the List<Card Item> variable in the Collection input parameter.
    2. Insert the <Card Item> variable returned by Create Card in the Item added input parameter.
  3. Insert the Bot Ask Carousel command in the script.
    1. Insert a message in the Text input parameter. This message is sent together with the carousel to the chat users.
    2. Insert the List<Card Item> variable in the Cards input parameter.
    3. Set a time limit to receive the answer to this question in the Timeout input parameter.
    4. Insert the variable name in the Value output parameter. You receive the card value selected by the user in this variable.

For more details on the definition of other parameters, see the documentation of the commands used.