Build A Chat Bot
This guide walks you through setting up a basic WhatsApp chatbot using Lipachat APIs. It assumes you’ve already joined the sandbox or connected your own WhatsApp Business number.
🪝 Step 1: Set Up Your Webhook
Navigate to the Lipachat Dashboard → Settings → Webhook
Set the Webhook URL to point to your server endpoint that will handle incoming messages.
Example:
When a customer sends a message on WhatsApp, Lipachat will send a POST request to your webhook with the message payload.
📩 Step 2: Handle Incoming Message
Example payload:
Your backend logic should parse this payload and determine the appropriate response (e.g., predefined replies or bot logic).
📤 Step 3: Respond with a Message
Once your bot determines a reply, call the Send Message API to respond.
Text reply example:
🖼 Optional: Respond with Media
Use the Send Media API to reply with images, PDFs, audio, or video.
Media reply example:
Summary: End-to-End Flow
The customer sends a message via WhatsApp
Lipachat delivers the message to your Webhook
Your chatbot processes the message
Your system calls
Send Message
orSend Media
APIThe customer receives the bot reply on WhatsApp
Last updated