Channel elements
Channel-elements are elements that are specific to a channel. These elements are present in the Chatbot sends and Chatbot receives sections in the chatbot editor.
Each channel has a different set of elements. Some elements are available only in one channel. Example: Apple Pay (Apple Messages for Business) and Single Product Message (WhatsApp). Some elements, such as Carousel, are available in multiple channels. However, the features and specifications of the element may be different in each channel.
For more information about the specifications of an element, refer to the Message Types sections in the channel documentation.
The following table shows the file formats for some of the chatbot elements, based on the channel.
Elements | Channels | ||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|
Apple Messages for Business |
Google's Business Messages |
Instagram Messaging |
Line | Live Chat |
Messenger | RCS | SMS | Telegram | Viber Bots |
Viber Business Messages |
|||
Audio | X | X | X | X | X | ✓ | ✓ | X | ✓ | X | X | ✓ | |
Button | X | X | X | X | ✓ | ✓ | X | X | X | X | ✓ | X | |
Carousel | X | ✓ | ✓ | ✓ | ✓ | ✓ | X | X | X | ✓ | X | X | |
Document | X | X | X | X | X | X | X | X | ✓ | ✓ | X | X | |
File | ✓ | X | X | X | ✓ | ✓ | X | X | X | X | X | ✓ | |
Image | ✓ | X | ✓ | ✓ | ✓ | ✓ | ✓ | X | ✓ | ✓ | ✓ | ✓ | |
List | X | X | X | X | X | X | X | X | X | X | X | ✓ | |
Location | X | X | X | ✓ | X | ✓ | X | X | X | ✓ | ✓ | ✓ | |
Quick Reply | ✓ | X | X | X | X | X | X | X | X | X | X | X | |
Reply button | X | X | X | X | X | X | X | X | X | X | X | ✓ | |
Rich Card | X | ✓ | ✓ | ✓ | X | ✓ | X | X | X | X | X | X | |
Rich Link | ✓ | X | X | X | X | X | X | X | X | X | X | X | |
Sticker | X | X | ✓ | X | X | X | X | X | X | ✓ | X | ✓ | |
Text | ✓ | ✓ | ✓ | ✓ | ✓ | ✓ | ✓ | ✓ | ✓ | ✓ | ✓ | ✓ | |
URL | X | X | X | X | X | X | X | X | X | ✓ | X | X | |
Video | X | X | X | X | ✓ | ✓ | ✓ | X | ✓ | ✓ | X | ✓ |
To use a channel in Answers, you must enable it first. View the instructions in the documentation for that channel.
For any channel, you can use only senders that are registered with Infobip.
To view elements that are common to all channels, refer to the Core elements section.
To view the elements for a specific channel, select the channel in the following filter.
Apple Messages for Business
Apple Messages for Business is a two-way communication channel that helps businesses communicate with end users. Use Apple Messages for Business in Answers to help end users resolve issues, schedule appointments, buy products and services, make payments with Apple Pay, and more.
Apple Messages for Business enables iOS users to initiate a chat from within an iOS application, such as Apple Maps, without having to navigate to a contact page.
When an end user starts a conversation with a chatbot on Apple Messages for Business, a person profile is automatically created as type Lead in People.
Apple Messages for Business offers a variety of message types, as well as Apple-specific message types such as Apple Pay, Apple authentication, and iMesages app. Refer to the messaging limitations for each message type.
To use Apple Messages for Business in Answers, you must enable this channel in your Infobip account.
Apple authentication
Verify Apple users through 3rd party company client bases, all within the Apple chat. This works by adding your Apple integration via the web interface using some simple parameters. When customers reach the Apple authentication step in the chat, a browser will automatically prompt the user to provide their credentials to authenticate themselves.
To add Apple authentication, drag the Apple Authentication channel element into the dialog editor then set up the initial message to the customer in the Received message tab.
The next step is to set up the authentication logic for this chatbot. Note that you will need to have already configured your connection to your 3rd party system before you can use Apple authentication.
In the Authentication tab, select an attribute your customer's authorization token will be stored against. The Repeat option lets you set how many times a user can fail authentication before the fallback option is triggered. Set the number of times they can repeat attempted authentication.
Fallback is used in cases where the user is unable to authenticate themselves. Set whether to send them to another dialog if this happens, or whether to transfer them to an agent, as well as an optional message if required.
In the Reply Message tab, set up a message to be sent to the end user in case of successful authentication. After this, the next step in the dialog will follow automatically.
Apple Form
Send embedded interactive forms as part of the custom journey for some channels all in a single step. This allows you to collect information from customers using questions and selections providing the chatbot with more information and context.
Forms let your users complete things like surveys, troubleshooting, account creation, etc. without having to leave the chat or even having to open any additional windows onscreen.
You must first create your forms for supported channels in the Content module to be able to use them in Answers. Forms must also be enabled or they will not show up for selection in the chatbot building experience.
Once forms are created in the content module, you cannot modify the contents of them through Answers. If you need to make any edits before using the form, you'll need to edit it back in the Content module in Forms.
Provide a title, message and optional image to be sent just before the form for clarification about the user is about to start. This is added in the Received message tab in form configuration.
In the Form tab, select an available form from the dropdown, then go on to define how responses are handled and to which attributes they can be optionally saved to.
Repeat determines the number of times they can try again if the chatbot does not recognize a repose, before reverting to the fallback option.
Use the message options in the Reply tab to send a message after the user successfully completed the form.
Note that users cannot navigate away from the chat and come back to open forms. Switching apps or windows will close the form and responses will be lost.
For more information about Apple forms, refer to the Infobip Apple Messages for Business documentation.
Apple Pay
Add Apple payment services to your chatbot so that end users can securely pay for products and services without leaving the Apple Messages for Business chat.
When an end user selects the payment request, the payment review and confirmation window opens. After the end user authorizes payment, the payment request chat message updates to reflect that the payment is complete. The chat progress is not lost during the payment process.
You can also include information such as order confirmation and order tracking.
Note
You must have an Apple Pay Merchant ID in the Apple Business Register. This ID identifies your business as a merchant that is able to accept payments. The ID is unique to your Apple Pay service and does not expire.
Configure Apple payment
To configure Apple payment in your chatbot, do the following:
- Configure Apple Pay. Alternatively, you can configure it through the Apple Pay element in later steps.
- In the Attributes tab, create the following attributes:
- In the chatbot editor, follow these steps for each dialog in which you want to use the Apple Pay element.
- Add the Code element from the Chatbot actions section.
- In the Code element, use the generateUUID function to generate a unique identifier for the order.
attributeApi.set('attributeName', UUID.generate());
where attributeName is the name of the attribute in which the unique order identifier is saved.
Example:
attributeApi.set('ID', UUID.generate()); - (Optional) Add the API element from the Chatbot actions section. In the Body section, configure the Key-value pair to send the order identifier to your payment gateway. Responses that are sent to the webhooks in the Apple Pay configuration include this identifier.
Key: The attribute that is used to identify the order in the payment gateway.
Value: The attribute that contains the unique order identifier in Answers.
- Add the Apple Pay element from the Chatbot receives section. You must use only one Apple Pay element in the dialog.
- Configure the following sections:
- Received message: The message that you send to end users before they start the payment process.
- Apple pay settings: The list of items and their prices. End users can select one or more options.
- Reply message: The message that you send to end users after a successful checkout.
For more information about the Apple Pay element, refer to the Apple Messages for Business documentation.
When an end user creates an order, they go to the dialog that contains Apple Pay. The Code element in the dialog generates a unique order identifier.
Each time the end user edits the order, they need to go to the dialog again. So, each time, the Code element in the dialog generates a new order identifier.
Received Message
Configure the message that the end user sees before they start the payment process. This tab contains the following fields:
- Title: Title of the message. This field can contain a maximum of 512 characters including spaces and special characters. There can be only one line of text.
- Message text (optional): Message that you send to the end user. This field can contain a maximum of 512 characters including spaces, new line, emojis, hyperlinks, and attributes.
- Image (optional): Image to be displayed in the message. If you do not add an image, a default icon is used. Either upload the image or add the link to the image. Supported file types are .jpg and .png. To add the link to an image, in the Link tab, enter the public URL that contains the image.
- Image style: The style of the image. Example: icon, small, and large. The default value is icon.
Apple pay settings
In this tab, you can create a list of items and configure the shipping method.
Apple pay configuration: If you have not configured Apple Pay already, select Edit configuration to set up Apple pay. For information about the configuration, refer to the Apple Messages for Business documentation.
After you complete the configuration, go to the chatbot > Apple pay element > Apple pay settings tab, and complete the following fields.
Set order ID from attribute ID: Choose the attribute that contains the unique order identifier.
Items: Create a list of items. Add the items either manually or from a list attribute.
To add an item manually, select Add item. Complete the following fields:
- Item name: Name of the item. Can contain spaces, special characters, and attributes. There can be only one line of text.
- Item price: Price of the item. Can contain positive numbers, including zero, with a maximum of 2 decimal places. For decimals, use a decimal point as the decimal separator and not a comma. You can use an attribute.
- Status: Choose one of the following:
- Final: The price of the item is set and is not affected when the end user checks out. Example: The price does not change if the end user applies a promotional code or a coupon.
- Pending: The price of the item may change when the end user checks out. Example: The price changes if the end user applies a promotional code or a coupon.
To add an item from a list attribute, follow these steps:
- In the Attributes tab > Attributes tab, select Add attribute.
- In the Name field, enter a name. Example: list_items. In the Type field, choose List.
- In the Dialogs tab, go to the dialog that contains the Apple Pay element.
- From the Chatbot actions section, drag the Code element to the editor. Add it before the Apple Pay element.
- In the Code element, create a list of items and set it to the attribute that you created. Add the following information for each list item:
- Item name: Name of the item. Can contain spaces, special characters, and attributes. There can be only one line of text.
- Item price: Price of the item. Can contain positive numbers, including zero, with a maximum of 2 decimal places. For decimals, use a decimal point as the decimal separator and not a comma. You can use an attribute.
The following example is for a list with two list items:
const items = [
{"name":"Charger", "price":"39.99"},
{"name":"Mouse", "price":"11"}
];
attributeApi.set('list_items', items);
where
items is the name of the list
name and price are the field names that you need to use in the Apple Pay element in later steps
list_items is the attribute that you created
- In the Apple Pay element that you created > Apple pay settings tab, select Add item from list attribute.
- Complete the following fields:
- From attribute: Choose the list attribute that you created. Example: list_items.
- Iteration label: Enter a label. Example: it. The label is available as a placeholder in the Item name and Item price fields.
This field can contain a maximum of 100 characters, including underscores. There cannot be spaces or special characters. There can be only one line of text. - Item name: Add the iteration label and the relevant field name that you created in the Code element. Example: {{it.name}}
- Item price: Add the iteration label and the relevant field name that you created in the Code element. Example: {{it.price}}.
- Status: Choose one of the following:
- Final: The price of the item is set and is not affected when the end user checks out. Example: The price does not change if the end user applies a promotional code or a coupon.
- Pending: The price of the item may change when the end user checks out. Example: The price changes if the end user applies a promotional code or a coupon.
After you add all the items, configure the following fields:
Total title: Enter a title. Example: Total price.
Total price: The total price of the items is calculated automatically. This price does not include shipping charges.
Status: Choose one of the following:
- Final: The total price is set and is not affected when the end user checks out. Example: The price does not change if the end user applies a promotional code or a coupon.
- Pending: The total price may change when the end user checks out. Example: The price changes if the end user applies a promotional code or a coupon.
Shipping: Configure the shipping information. Add the shipping method either manually or from a list attribute.
To add a shipping method manually, select Add shipping method. Complete the following fields:
- Shipping method name: Name of the shipping method. Can contain spaces, special characters, and attributes. There can be only one line of text.
- Shipping price: Price of shipping. Can contain positive numbers, including zero. You can also use an attribute.
- Shipping method detail: Add information about the shipping. You can also use an attribute.
- Shipping method identifier: Create a unique identifier for the shipping method. You can also use an attribute.
To add a shipping method from a list attribute, follow these steps:
- In the Attributes tab > Attributes tab, select Add attribute.
- In the Name field, enter a name. Example: shipping_method. In the Type field, choose List.
- In the Dialogs tab, go to the dialog that contains the Apple Pay element.
- From the Chatbot actions section, drag the Code element to the editor. Add it before the Apple Pay element.
- In the Code element, create a set of shipping methods and set it to the attribute that you created. Add the following information for each shipping method:
- Shipping method name: Name of the shipping method. Can contain spaces, special characters, and attributes. There can be only one line of text.
- Shipping price: Price of shipping. Can contain positive numbers, including zero. You can also use an attribute.
- Shipping method detail: Add information about the shipping. You can also use an attribute.
- Shipping method identifier: Create a unique identifier for the shipping method. You can also use an attribute.
The following example is for two shipping methods:
const shipping = [
{"name":"Express", "price":"4.99", "detail":"Next day delivery", "id":"21"},
{"name":"Standard", "price":"0.99", "detail":"Delivery within 4-5 business days", "id":"22"}
];
attributeApi.set('shipping_method', shipping);
where
shipping is the name of the shipping method list
name, price, detail, and id are the field names that you need to use in the Apple Pay element in later steps
shipping_method is the attribute that you created
- In the Apple Pay element that you created > Apple pay settings tab, select Add shipping method from list attribute.
- Complete the following fields:
- From attribute: Choose the list attribute that you created. Example: shipping_method.
- Iteration label: Enter a label. Example: lbl. This value is available as a placeholder in the Shipping method name, Shipping method price, Shipping method detail, and Shipping method identifier fields.
This field can contain a maximum of 100 characters, including underscores. There cannot be spaces or special characters. There can be only one line of text. - Shipping method name: Add the iteration label and the relevant field name that you created in the Code element. Example: {{lbl.name}}
- Shipping method price: Add the iteration label and the relevant field name that you created in the Code element. Example: {{lbl.price}}.
- Shipping method detail: Add the iteration label and the relevant field name that you created in the Code element. Example: {{lbl.detail}}.
- Shipping method identifier: Add the iteration label and the relevant field name that you created in the Code element. Example: {{lbl.id}}.
Save response to (optional): Choose the attribute in which to save the order response. This attribute contains the response from Apple and contains the following information:
- The unique order identifier
- Whether the payment was made (Boolean - true/false)
- Items for which the payment was made
- Amount paid for these items
- Total amount paid
Fallback: The action to take if the end user enters an invalid response or performs an unknown action. This section contains the following fields:
- Fallback action: You can either transfer the chat to an agent (Connect to agent) or send the end user to another dialog (Go to dialog).
- Dialog: If the Fallback action is Go to dialog, choose the relevant dialog. Example: You can go back to the default dialog or to the closing dialog. You can choose an existing dialog or create a new one.
- Fallback message (optional): The message to send to the end user. Can contain a maximum of 1,000 characters including spaces, special characters, new line, emojis, and attributes. You can add a maximum of 5 variations of the message. The end user receives one of these messages. To add a variation, select Add variation.
Reply Message
Configure the message that the end user sees after a successful checkout. This tab contains the following fields:
- Title: Title of the message. This field can contain a maximum of 512 characters including spaces and special characters. There can be only one line of text.
- Message text (optional): Message that you send to the end user. This field can contain a maximum of 512 characters including spaces, new line, emojis, hyperlinks, and attributes.
Test the Chatbot
After you configure the chatbot, use the simulator to test the chatbot flow. In the simulator, follow these steps:
- Start a conversation with the chatbot. When the chatbot enters the dialog that contains the Apple Pay element, the Code element in the dialog generates a unique order ID, which is saved in the ID attribute.
In this example, the chatbot is not configured to connect to a real-life API.
- Select the button.
- Select Pay. In the simulator, you can see only the total price.
- Select Attribute.
- Select View details.
The order response contains the unique order ID that was saved in the ID attribute.
If you go to the dialog again, a new order ID is generated.
How to
Edit or delete a list item
To edit or delete an item or a shipping method, follow one of these ways:
- Select the three dots against the list item and choose an option.
- Select the list item.
Reorder list items
To edit or delete items or shipping methods, use the six dots against a list item to drag the item.
File
Send files and documents directly to end users either by uploading the file in the Answers editor or by providing a link to the file.
Supported file formats depend on the channel that your chatbot uses. Refer to the Message types section for the relevant channel.
For WhatsApp, you can either define the individual file types that the chatbot should handle or you can set to all.
Image
Send images to end users by either uploading the image in the Answers editor or by providing a direct open URL to the image. The link option also supports attributes if you need to customize the URL. Add an optional caption to your image.
Supported image formats depend on the channel that your chatbot uses. Refer to the Message types section for the relevant channel.
iMessage App
iMessages is a framework that enables you to create apps that contain additional functionality. Apps that are created by using the iMessages framework are called iMessage apps.
Each iMessage app must enable a single, specific task. Example: Choose a seat, view a flight’s progress on a map, or view in-store maps.
You can create the following types of iMessage apps:
- Standalone iMessage app: A standalone app redirects the customer to your iOS app, which resides outside the Messages app.
- iMessage app extension: An iMessage app extension is hosted inside your iOS app. The extension enables customers to interact with your app from within a Messages for Business conversation.
After you create the app, you can share it with end users through Answers.
To send the iMessage App to end users, in the chatbot editor, drag and drop the iMessage app element from Chatbot receives.
Received Message tab: The initial message that you send to the end user. The end user sees this message before they open your iMessages app. This tab contains the following elements:
- Title
- Message text: Can contain emojis and placeholders. Maximum of 512 characters
iMessage App tab:
- Click Create Configuration to configure your iMessage App connection. This section contains information that is used to identify the selected app. Refer to the iMessage App configuration section
- Save response to: Choose an attribute in which you want to store responses from the end user
- Repeat: Set the number of times to repeat your message in cases where the end user provides an unrecognized response. You can repeat the message a maximum of three times
- Fallback: Set the action to take if the end user exceeds the number of unrecognized responses that is set in the Repeat section. Available actions are:
- Go to a dialog. Choose the dialog
- Connect to agent: Applicable if you either have the Infobip Conversations solution enabled or integrate with an external contact center solution
(Optional) Provide a Fallback message to send to the end user. You can provide more than one message. Each message can contain a maximum of 1000 characters, including variables.
Reply Message tab: The message that you send to the end user after they send you a valid response. This tab contains the following elements:
- Title
- Message text: Can contain emojis and placeholders. Maximum of 512 characters
The next steps in your chatbot flow then follow.
For more information about iMessage App, refer to iMessage App documentation and the Apple support documentation.
List picker
Provide end users with a list of pre-defined choices from which they can select one or more options. Example: A list of items that they can purchase or a list of questions that directs them to the relevant support option. The chatbot can use the selection to route the end users to the next step.
There is no limit to the number of options that you can add to a list picker. Infobip recommends that you add a maximum of 7 options to avoid poor chatbot performance.
To add a list picker to your chatbot, in the chatbot editor, drag and drop the List Picker element from Chatbot receives.
List pickers contain the following mandatory components:
- Received message: The message that you send to end users
- List: The list of items from which end users can select one or more options
- Reply message: The message that you send to end users after they choose items from the list
Received Message: Configure the message that the end user sees before the list of items. This tab contains the following fields:
- Title: Title of the message. The default title is “Select an option”. This field can contain a maximum of 512 characters including spaces. There can be only one line of text
- Message text (optional): Message that you send to the end user. This field can contain a maximum of 512 characters including spaces, new line, emojis, hyperlinks, and attributes
- Image (optional): Image to be displayed in the message. If you do not add an image, a default icon is used. Either upload the image or add the link to the image. Supported file types are .jpg and .png. To add the link to an image, in the Link tab, enter the public URL that contains the image.
- Image style: The style of the image. Example: icon, small, and large. The default value is icon.
List: Configure the list of items that you send to end users. You can categorize the list items into groups by using multiple sections with items in each section.
This tab contains the following fields:
- Section title: Title of the section. Can contain a maximum of 512 characters including spaces and attributes. There can be only one line of text
- Multiple item selection: Enable this option so that end users can choose more than one item from the list
- List items: Items in the list. You can add items either manually or from a list attribute.
To add an item manually, click Add item. Complete the following fields:- Item Title: Name of the list item. Can contain a maximum of 512 characters including spaces and attributes. There can be only one line of text
- Item identifier (optional): A unique identifier for the item. Can contain spaces
- Image (optional): Image to be displayed for the item. Either upload the image or add the link to the image. Supported file types are .jpg and .png. To add the link to an image, in the Link tab, enter the public URL that contains the image.
- Item Subtitle (optional): Information about the list item. Example: description. Can contain a maximum of 512 characters including spaces, special characters, emojis, and attributes. There can be only one line of text.
To add an item from a list attribute, follow these steps:
- In the Attributes tab > Attributes tab, click Add attribute.
- In the Name field, enter a name. Example: list_items. In the Type field, choose List.
- In the Dialogs tab, go to the dialog that contains the list picker that you created.
- From the Chatbot actions section, drag and drop the Code element. Add it before the List Picker element in the editor.
- In the Code element, create a list of items and set it to the attribute that you created. Add the following information for each list item:
- Item Title: Name of the list item. Can contain a maximum of 512 characters including spaces and attributes. There can be only one line of text
- Item identifier (optional): A unique identifier for the item. Can contain spaces
- Image (optional): Image to be displayed for the item. Specify the public URL that contains the image
- Item Subtitle (optional): Information about the list item. Example: description. Can contain a maximum of 512 characters including spaces, special characters, emojis, and attributes. There can be only one line of text.
The following example is for a list with two list items:
const items = [
{"title":"Answers", "identifier":"answers", "image":"https://cdn-www.infobip.com/wp-content/uploads/2021/03/08230929/answers-benefit-002-2x.png", "subtitle":"Chatbot-building platform"},
{"title":"Things", "identifier":"things", "image":"https://cdn-www.infobip.com/wp-content/uploads/2021/05/25141144/iot-header-2x.png", "subtitle":"Internet of things"}
];
attributeApi.set('list_items', items);
where
items is the name of the list
title, identifier, image, and subtitle are the field names that you need to use in the List picker element in later steps
list_items is the attribute that you created
- In the List Picker element that you created > List tab, click Add from list attribute.
- Complete the following fields:
- From attribute: Choose the list attribute that you created. Example: list_items.
- Iteration label: Enter a label. Example: it_label. This value is available as a placeholder in the Item title, Item identifier, Image, and Item Subtitle fields.
This field can contain a maximum of 100 characters, including underscores. There cannot be spaces or special characters. There can be only one line of text. - Item title: Add the iteration label and the relevant field name that you created in the Code element. Example: {{it_label.title}}
- Item identifier (optional): Add the iteration label and the relevant field name that you created in the Code element. Example: {{it_label.identifier}}. If you have not specified this field in the Code element, leave this field blank
- Image (optional): Add the iteration label and the relevant field name that you created in the Code element. Example: {{it_label.image}}. If you have not specified this field in the Code element, leave this field blank
- Item Subtitle (optional): Add the iteration label and the relevant field name that you created in the Code element. Example: {{it_label.subtitle}}. If you have not specified this field in the Code element, leave this field blank
- Add new list section: Add a list section
- Save selection: Save the end user's selection to an attribute.
- Field to save: Choose the field to save. Example: item title, item identifier
- Save to attribute: The attribute to which you want to save the selection. You can either choose an existing attribute or create a new one
- Repeat count: Choose the number of times to repeat the message in case you do not receive a valid response from the end user. The default value is No repeat. You can repeat the message a maximum of 3 times
- Fallback: The action to take if the end user enters an invalid response or performs an unknown action. This section contains the following fields:
- Fallback action: You can either transfer the chat to an agent (Connect to agent) or send the end user to another dialog (Go to dialog).
- Dialog: If the Fallback action is Go to dialog, choose the relevant dialog. Example: You can go back to the default dialog or to the closing dialog. You can choose an existing dialog or create a new one.
- Fallback message (optional): The message to send to the end user. Can contain a maximum of 1,000 characters including spaces, special characters, new line, emojis, and attributes. You can add a maximum of 5 variations of the message. The end user receives one of these messages. To add a variation, click Add variation.
To edit or delete a list item, click the three dots against the list item and choose an option. You can also edit the list item by clicking on it.
To reorder the list items, use the six dots against a list item to drag and drop the item.
Reply Message: Configure the message that the end user sees after they choose items from the list. This tab contains the following fields:
- Title: Title of the message. Can contain a maximum of 512 characters including spaces. There can be only one line of text
- Message text (optional): Message that you send to the end user. Can contain a maximum of 512 characters including spaces, new line, emojis, hyperlinks, and attributes
- Image (optional): Image to be displayed in the message. Either upload the image or add the link to the image. Supported file types are .jpg and .png. To add the link to an image, in the Link tab, enter the public URL that contains the image.
If you add an image to the Received message, but not to the Reply message, the image from the Received message is used in the Reply message. - Image style: The style of the image. Example: icon, small, and large. The default value is icon.
After you configure the chatbot, use the simulator to test the chatbot flow. In the simulator, follow these steps:
- Click the button.
- Choose one or more items and click Send.
For more information about list pickers, refer to the Apple Messages for Business documentation.
Quick Reply
Quick reply buttons enable end users to choose from multiple options inline without leaving the conversation with your chatbot. Instead of typing a reply to your message, the end user can click one of these buttons to send you a predefined reply. The chatbot receives the postback value of that button. Thus, you can capture a specific response from the end user.
You can add 2–5 options. End users can choose only one of these options.
To add quick replies to your chatbot, in the chatbot editor, drag and drop the Quick Reply element from Chatbot sends.
Quick replies contain the following mandatory components:
- Description text: The message that you send to end users after they choose a quick reply option
-
Quick replies: The set of predefined options from which the end user can select one
Quick replies: You can add quick replies either manually or from a list attribute.
To add a quick reply manually, click Add quick reply. Complete the following fields:
- Item text: Text that is displayed on the quick reply button and is visible to the end user. Can contain a maximum of 512 characters including emojis, special characters, spaces, and attributes. There can be only one line of text.
- Postback: Data that is sent back to you when the end user clicks the button. Can contain special characters, spaces, and attributes. Example: If the quick reply button title is 'Send me more information', you can specify the postback value as 'send_information'
To add a quick reply from a list attribute, follow these steps:
- Add a quick reply manually. You must add at least one item manually for the validation to be successful. Example: To add 5 quick reply buttons, add 1 item manually and the other 4 items from a list attribute.
- In the Attributes tab > Attributes tab, click Add attribute.
- In the Name field, enter a name. Example: list_items. In the Type field, choose List.
- In the Dialogs tab, go to the dialog that contains the quick reply element that you created.
- From the Chatbot actions section, drag and drop the Code element. Add it before the Quick Reply element in the editor.
- In the Code element, create a list of quick reply items and set it to the attribute that you created. Add the following information for each quick reply item:
- Item text: Text that is displayed on the quick reply button and is visible to the end user. Can contain a maximum of 512 characters including emojis, special characters, spaces, and attributes. There can be only one line of text.
- Postback: Data that is sent back to you when the end user clicks the button. Can contain special characters, spaces, and attributes. Example: If the quick reply button title is 'Send me more information', you can specify the postback value as 'send_information'
The following example is for a list with two quick reply buttons:const items = [
{"title":"Moments", "postback":"moments"},
{"title":"Conversations", "postback":"conversations"}
];
attributeApi.set('list_items', items);
where
items is the name of the list
title and postback are the field names that you need to use in the Quick reply element in later steps
list_items is the attribute that you created
- In the Quicky reply element that you created, click Add quick reply and add a list item manually. If you do not do so, the chatbot fails validation.
- Click Add quick replies from list attribute.
- Complete the following fields:
- From attribute: Choose the list attribute that you created. Example: list_items.
- Iteration label: Enter a label. Example: it_label. This value is available as a placeholder in the Item text and Postback fields.
This field can contain a maximum of 100 characters, including underscores. There cannot be spaces or special characters. There can be only one line of text. - Item text: Add the iteration label and the relevant field name that you created in the Code element. Example: {{it_label.title}}
- Postback: Add the iteration label and the relevant field name that you created in the Code element. Example: {{it_label.identifier}}
To edit or delete a quick reply button, click the three dots against the button and choose an option. You can also edit the button by clicking on it.
To reorder the quick reply buttons, use the six dots against a button to drag and drop the button.
To process the quick reply selection made by the end user, add User Input as the next element.
After you configure the chatbot, use the simulator to test the chatbot flow.
For more information about quick replies, refer to the Apple Messages for Business documentation.
Rich link
Use rich links to send URLs that are embedded within either an image or a video. When you use rich links, the end user can see a preview of the web page within the Messages app. Thus, end users can be assured that the link is for your web page and not for a fraudulent page. When the end user clicks the image or video, the link opens within the Messages app. After viewing the webpage, the end user can close the page and return to the chatbot conversation.
To add a rich link to your chatbot, in the chatbot editor, drag and drop the Rich link element from Chatbot sends.
You can embed the URL of the website in either an image or a video. To embed the URL in an image, click Image link. To embed the URL in a video, click Video link.
You can add the image or video to the message in one of the following ways:
- Upload the image or video: Use the Upload tab. Supported file format for images are .png and .jpg. Supported file format for video is .mp4.
- Add a link to the image or video: Use the Link tab. Enter the public URL that contains the image or video in the Image URL or Video URL field.
Enter the following information.
- Link title: A name for the URL
- Link URL: The URL of the website to which you want to direct the end user
After you configure the rich link, use the simulator to test the link. When you click the image, the link opens.
For more information about rich links, refer to the Apple Messages for Business documentation.
Text
Send text-only messages and use personalization options in conjunction with attributes, objects, links, and emojis. If you are using links, use the link preview option to auto-display previews in messages. Note however not all channels support this. This option is enabled by default.
Character limits differ depending on which channel your chatbot is using. Make sure to check out the relevant Message types sections for each channel type.
Time picker
Prompt end users to choose a time slot from a list of options. Example: schedule an appointment. Customers can view time pickers in calendar view, which helps them view any meeting conflicts. After choosing a time, end user can view their choice in the conversation to add the event to their calendar.
If you include information such as address or directions, end users can view this information in calendar applications and get directions in map applications. Time pickers also support push notifications to remind end users about upcoming appointments. You must obtain opt-in from customers to send them push notifications and provide an opt-out option.
To add a time picker to your chatbot, in the chatbot editor, drag and drop the Time Picker element from Chatbot receives.
Time pickers contain the following mandatory components:
- Received message: The message that you send to end users
- Time slots: The list of time slots from which end users can select an option
- Reply message: The message that you send to the end user after they choose a time slot from the list
Received Message: Configure the message that the end user sees before the list of time slots. This tab contains the following fields:
- Title: Title of the message. The default title is “Select an option”. This field can contain a maximum of 512 characters including spaces. There can be only one line of text.
- Message text (optional): Message that you send to the end user. This field can contain a maximum of 512 characters including spaces, new line, emojis, hyperlinks, and attributes
- Image (optional): Image to be displayed in the message. If you do not add an image, a default calendar icon is used. Either upload the image or add the link to the image. Supported file types are .jpg and .png. To add the link to an image, in the Link tab, enter the public URL that contains the image.
- Image style: The style of the image. Example: icon, small, and large. The default value is icon.
Time slots: Configure the set of time slots to send to the end user. In addition to time slots, you can add the location of the event.
This tab contains the following fields:
- Title: Title of the list of time slots. Can contain spaces and attributes. There can be only one line of text
- Time zone: Choose a time zone from the list. Time slots are adjusted based on the selected time zone
- Location details (Optional): Either manually enter the address for the location or choose the attribute in which you have saved the address. The attribute type must be Text.
-
Latitude (Optional): Either manually enter the latitude for the location or choose the attribute in which you have saved the latitude. The format for the latitude is decimal degrees. Example: 13.067439. The attribute type must be Number.
-
Longitude (Optional): Either enter the longitude for the location or choose the attribute in which you have saved the longitude. The format for the longitude is decimal degrees. Example: 80.237617. The attribute type must be Number.
- Time slots: List of time slots. You can add time slots either manually or from a list attribute. Available time slots can change because multiple end users would choose a time slot. So, Infobip recommends that you use a list attribute that contains the currently available time slots.
To add a time slot manually, click Add time slot. Complete the following fields:- Slot type: Choose how you want to add the time slot. If you want to enter the start time manually, choose free form. If you want to pick a time slot, choose Picker.
- Start time: If the slot type is free form, enter the start time in the format yyyy-mm-ddThh:mm:ssZ. If the slot type is picker, choose the start date and start time.
- Duration: Duration of the time slot. Minimum value is 1 hour, and maximum value is 24 hours. The duration is in whole hours.
- Identifier (optional): A unique identifier for the time slot. Can contain spaces
To add a time slot from a list attribute, follow these steps:
- In the Attributes tab > Attributes tab, click Add attribute.
- In the Name field, enter a name. Example: time_slots. In the Type field, choose List.
- In the Dialogs tab, go to the dialog that contains the time picker that you created.
- From the Chatbot actions section, drag and drop the Code element. Add it before the Time Picker element in the editor.
- In the Code element, create a list of time slots and set it to the attribute that you created. Add the following information for each time slot:
- Start time: The start date and time for the time slot in the format yyyy-mm-ddThh:mm:ssZ
- Identifier (optional): A unique identifier for the time slot. Can contain spaces
The following example is for a list with two time slots:const slots = [
{"start":"2023-11-15T15:00:00Z", "identifier":"slot_1"},
{"start":"2023-11-15T16:00:00Z", "identifier":"slot_2"},
];
attributeApi.set('time_slots', slots);
where
slots is the name of the list
start and identifier are the field names that you need to use in the Time Picker element in later steps
time_slots is the attribute that you created
- In the Time Picker element that you created > Time slots tab > Time slots section, click Add time slots from list attribute.
- Complete the following fields:
- From attribute: Choose the list attribute that you created. Example: time_slots.
- Iteration label: Enter a label. Example: it_label. This value is available as a placeholder in the Start time and Identifier fields.
This field can contain a maximum of 100 characters, including underscores. There cannot be spaces or special characters. There can be only one line of text. - Start time: Add the iteration label and the relevant field name that you created in the Code element. Example: {{it_label.identifier}}
- Duration: Choose the duration of the time slot. Minimum value is 1 hour, and maximum value is 24 hours. The duration is in whole hours.
- Identifier (optional): Add the iteration label and the relevant field name that you created in the Code element. Example: {{it_label.identifier}}. If you have not specified this field in the Code element, leave this field blank
- Save selection: Save the end user's selection to an attribute.
- Field to save: Choose the field to save. Example: time slot start time, time slot identifier
- Save to attribute: The attribute to which you want to save the selection. You can either choose an existing attribute or create a new one
- Repeat count: Choose the number of times to repeat the message in case you do not receive a valid response from the end user. The default value is No repeat. You can repeat the message a maximum of 3 times
- Fallback: The action to take if the end user enters an invalid response or performs an unknown action. This section contains the following fields:
- Fallback action: You can either transfer the chat to an agent (Connect to agent) or send the end user to another dialog (Go to dialog).
- Dialog: If the Fallback action is Go to dialog, choose the relevant dialog. Example: You can go back to the default dialog or to the closing dialog. You can choose an existing dialog or create a new one.
- Fallback message (optional): The message to send to the end user. Can contain a maximum of 1,000 characters including spaces, special characters, new line, emojis, and attributes. You can add a maximum of 5 variations of the message. The end user receives one of these messages. To add a variation, click Add variation.
To edit or delete a time slot, click the three dots against the time slot and choose an option. You can also edit the time slot by clicking on it.
To reorder the time slots, use the six dots against a time slot to drag and drop the slot.
Reply Message: Configure the message that the end user sees after they choose a time slot from the list. This tab contains the following fields:
- Title: Title of the message. Can contain a maximum of 512 characters including spaces. There can be only one line of text
- Message text (optional): Message that you send to the end user. Can contain a maximum of 512 characters including spaces, new line, emojis, hyperlinks, and attributes
- Image (optional): Image to be displayed in the message. Either upload the image or add the link to the image. Supported file types are .jpg and .png. To add the link to an image, in the Link tab, enter the public URL that contains the image.
If you add an image to the Received message, but not to the Reply message, the image from the Received message is used in the Reply message. - Image style: The style of the image. Example: icon, small, and large. The default value is icon.
After you configure the chatbot, use the simulator to test the chatbot flow. In the simulator, follow these steps:
- Click the button.
- Choose one of the time slots.
For more information about time pickers, refer to the Apple Messages for Business documentation.