How to Enable AskHandle AI on Infobip?
In this tutorial, we’ll guide you through the process of integrating AskHandle AI using the Infobip Chatbot builder. Infobip's Chatbot tool allows you to create chatbots for WhatsApp and SMS through an intuitive drag-and-drop interface. You can easily create rule-based chatbots or integrate generative AI capabilities directly into the builder.
(This is what the panel will look like after completing all the steps in this tutorial.)
To enable AskHandle AI, we'll be using the API feature within the Chatbot. Before you start, ensure that:
- You have activated the Answers feature in your pricing plan.
- You are on either the Grow or Scale plan.
Let’s get started!
Step 1: Create a New Chatbot
- On the left-hand side menu, locate and click on Chatbots.
- Click on the New Chatbot button to create a new bot.
- Fill out the required details to set up the chatbot. For this demo, we’ll choose WhatsApp as the channel. You can choose a sender later or use Infobip’s test sender for now.
Step 2: Add a Dialog
We need to create two dialogs to make AskHandle AI functional. By default, you’ll see a dialog called Default on the left-hand panel.
- Click on ADD DIALOG to create a new dialog. Name it QA.
Step 3: Set Up the Conversation Flow
Now let’s configure the conversation to trigger the AskHandle AI.
3.1: Add API Call to Start a New Chat Room
-
Go to the Default dialog and drag the API element from the right sidebar under Chatbot receives.
-
To start the conversation with AskHandle AI, we need to create a new chat room for each user.
-
In the API element settings:
Select POST for the method.
- Paste the following URL:
https://dashboard.askhandle.com/api/v1/rooms/
. - Choose JSON for the content type.
Add a key-value pair for Authorization:
- Key:
Authorization
- Value:
Token your_AskHandle_token
(replaceyour_AskHandle_token
with your actual token).
- Key:
If you don’t have your AskHandle token yet, follow these steps to retrieve it:
ShThe response will return a token like this:
Json
-
Next, click on Response and specify the values you want to extract from the API response:
- Attribute:
room
— Path:uuid
- Attribute:
greeting_message
— Path:greeting_message
- Attribute:
-
Click Go Back to continue.
3.2: Save the Greeting Message
- Drag and drop a Save user response element into the flow.
- Click the
{}
button and select thegreeting_message
attribute. (If you don't see it, go back to the API element and ensure the attribute is added correctly). - For Save answer as, create a new attribute called
body
. - In the Fallback section, select Go to dialog and choose Default.
3.3: Transition to the QA Dialog
- Drag and drop the To Dialog element.
- Select QA as the target dialog.
- In the Share attribute value(s) to next intent section, click ADD ATTRIBUTE and select the following:
room
body
greeting_message
Step 4: Configure the QA Dialog
Now let’s configure the QA dialog, where AskHandle AI will provide responses.
Go to the QA dialog and add the following elements:
- API
- Save user response
- To Dialog
4.1: Set Up API Request
- Drag the API element into the QA dialog.
- In the API element settings:
- Select POST for the method.
Paste the following URL:
https://dashboard.askhandle.com/api/v1/messages/
.
- In the Body section, use the following JSON format:
Json
4.2: Set Up the Response Body
Click on Response and set up the response body attributes:
- Attribute:
support_answer
— Path:support_answer
4.3: Save the Response
- Click on the Save user response element.
- Click the
{}
button and select thesupport_answer
attribute. - For Save answer as, select
body
. - In the Fallback section, select Go to Dialog and choose Default.
4.4: Transition Back to Default Dialog
- Go back to the To Dialog element.
- Select QA as the target dialog.
- In the Share attribute value(s) to next intent section, click ADD ATTRIBUTE and select:
room
body
support_answer
greeting_message
Now your AskHandle AI is configured and ready to respond.
Step 5: Test the AI
To test your AI setup:
- Go to the Test section.
- Click START SIMULATION to initiate a conversation with AskHandle AI.
Step 6: Launch the AI
To launch your AI on a real WhatsApp number:
- Go to Settings and select your WhatsApp number from the Phone number list.
- If you haven't registered a WhatsApp number yet, navigate to Channels and Numbers -> Numbers and purchase a new number. Complete the WhatsApp registration process.
Important Notice
If you intend to use AskHandle AI with a real WhatsApp number, ensure that Conversations is enabled in the Default inbound configuration.
If you don't see a Subscription ID, you should create a new one in the Developer Tools -> Subscriptions Management.