Learn how to create a basic chatbot using WhatsApp Cloud API and Pabbly Connect. Follow this step-by-step guide for seamless WhatsApp automation. Discover how to seamlessly connect your essential tools through accessible instructions that make powerful automation available to professionals at every skill level.

Watch Step By Step Video Tutorial Below


1. Accessing Pabbly Connect for WhatsApp Automation

To create a basic chatbot using WhatsApp Cloud API, the first step is accessing Pabbly Connect. This platform enables seamless integration between various applications, including Google Sheets and WhatsApp.

Start by visiting the Pabbly Connect website and signing up for a free account. If you’re an existing user, simply log in to your dashboard. Once logged in, click the blue button to create a new workflow and give it a name like ‘Create a Chatbot in WhatsApp’.


2. Setting Up Google Sheets with Pabbly Connect

The next step involves setting up Google Sheets, where your customer data will be stored. In this automation, Pabbly Connect will facilitate the connection between Google Sheets and WhatsApp Cloud API.

To integrate Google Sheets, use the Pabbly Connect Webhooks add-on. Here’s how to set it up:

  • Open your Google Sheets and go to Extensions, then Add-ons, and get the Pabbly Connect Webhooks add-on.
  • Once installed, navigate to the add-on and select Initial Setup.
  • Copy the Webhook URL from Pabbly Connect and paste it into the designated field in Google Sheets.

After setting the trigger column, click on the Send Test button to ensure the connection works. Once test data is sent successfully, Pabbly Connect will be ready to capture data from Google Sheets.


3. Sending Messages via WhatsApp Cloud API

After setting up Google Sheets, the next step is to send messages using the WhatsApp Cloud API. This is where Pabbly Connect plays a crucial role in automating the message delivery process.

To send messages, select the WhatsApp Cloud API application in Pabbly Connect and choose the action event ‘Send Template Message’. Connect your WhatsApp Cloud API account by providing the required credentials, including the phone number ID and access token.

  • Copy the phone number ID from your WhatsApp Cloud API account and paste it into Pabbly Connect.
  • Select the template you created for sending messages.
  • Map the recipient’s mobile number from the data captured in Google Sheets.

Once everything is set up, click the Send Test button to verify that the message is sent successfully to the customer’s WhatsApp number.


4. Creating a Chatbot Workflow with Pabbly Connect

Now, let’s create a chatbot workflow that responds to user messages. This will involve setting up another workflow in Pabbly Connect to handle incoming messages from WhatsApp.

Start by creating a new workflow and selecting the WhatsApp Cloud API as the trigger event for incoming messages. Copy the Webhook URL provided by Pabbly Connect and paste it into your WhatsApp Cloud API configuration.

Set the Webhook URL in the configuration settings of WhatsApp Cloud API. Verify the token to ensure the connection is established. Subscribe to the messages webhook feed to start receiving notifications.

Once you’ve completed these steps, your chatbot will be ready to respond automatically to any incoming messages based on the user’s selection.


5. Defining Responses in the Chatbot Using Pabbly Connect

The final step is to define the specific responses your chatbot will send based on user input. Using Pabbly Connect, you can create a lookup table to manage different responses for different user selections.

In the Pabbly Connect workflow, add a Lookup Table action event to define the scenarios based on the user’s reply (1, 2, or 3). Map the user’s response to the corresponding offer details.

Create entries in the lookup table for each possible user response. Map the lookup key to the user’s input from WhatsApp. Set a fallback value for unrecognized inputs.

Finally, connect the WhatsApp Cloud API again to send the appropriate response based on the lookup table results. This completes the chatbot setup, allowing it to respond dynamically to customer inquiries.


Conclusion

In this tutorial, we’ve demonstrated how to create a basic chatbot using WhatsApp Cloud API and Pabbly Connect. This automation allows you to send personalized messages and engage with customers effectively.

Ensure you check out Pabbly Connect to create business automation workflows and reduce manual tasks. Pabbly Connect currently offer integration with 2,000+ applications.