WhatsApp Agent
Learn how to create and connect an Optimly agent to your WhatsApp Business account to offer real-time support to your customers.
What is a WhatsApp Messaging Agent?
A WhatsApp Agent is a conversational AI powered by LLMs that integrates with your WhatsApp Business Account to:
- Respond to customer questions using your business knowledge base
- Provide 24/7 conversational support
- Communicate in your brand’s tone and personality
- Handle multiple conversations simultaneously
- Operate via a secure connection with your WhatsApp phone number
Connect a WhatsApp Business Account
To begin the integration:
- Go to the Integrations section in your Optimly dashboard.
- Click on the WhatsApp card and then click Connect.
Note: The phone number you connect to your agent must not be used on WhatsApp or WhatsApp Business. If currently in use, you'll need to delete the existing WhatsApp account.
Steps to delete your current WhatsApp account:
- Open WhatsApp or WhatsApp Business.
- Go to Settings → Account → Delete my account.
- Confirm the phone number and select Delete my account.
- After deletion, wait a few minutes for the number to be released.
Connect Through Facebook
- Click Get Started to log in with your Facebook account.
- Choose or create your Business Profile.
- Choose or create a WhatsApp Business Account.
- (Optional) Fill in your WhatsApp Business Profile details.
- (Optional) Add and verify a phone number if none exists.
- Click Continue, then Finish to complete the setup.
Setting Up Your WhatsApp Agent
Once your WhatsApp account is connected:
- Go to the Agents section.
- Click + Add and select WhatsApp Agent.
You will then proceed with the following steps.
1. Basics
- Agent Name & Avatar: Name your agent and upload an avatar.
- Connected Account: Select the linked WhatsApp Business Account.
- Phone Number: Choose the verified number for the agent.
2. Configuration
- Behavior: Define your agent’s role and personality. Use the prompt generator to write clear and on-brand instructions.
- Model: Select the LLM powering your agent (e.g., GPT-4, GPT-4o mini).
- Knowledge Restrictions: Choose whether responses should rely only on your uploaded content.
- Emoji Support: Enable or disable emojis in chat responses.
3. Knowledge Base
Upload and connect business-specific content to power your agent’s responses:
- PDFs, text files, and Google Docs
- Website URLs
- YouTube videos with product demos or tutorials
- Custom knowledge bases or FAQs
4. Tools
Optimly offers tools to enhance the experience in WhatsApp:
- Takeover Request: Allow the agent to trigger a manual handoff to a human when needed (e.g., on user request or failed response).
Tools can be toggled on/off from the dashboard to match your needs.
Manual Conversation Control
Optimly provides complete control over WhatsApp conversations, allowing you to choose when the AI responds automatically and when you want to handle messages personally.
Setting the Default Behavior
In the Configuration tab, set how your agent handles all new WhatsApp conversations:
- Automatic AI Responses Enabled (default): Your agent responds to all WhatsApp messages automatically
- Automatic AI Responses Disabled: All new conversations require manual responses from you
This setting applies to all new conversations but can be overridden for individual chats.
Taking Over Individual Conversations
You can manually control any WhatsApp conversation at any time:
- Go to the Conversations section from the dashboard
- Select the WhatsApp conversation you want to control
- Look for the Manual/AI toggle switch at the top of the conversation
- Toggle to switch between modes:
- AI Active (blue badge): Agent responds automatically to WhatsApp messages
- Manual Mode (orange badge): You send all responses through WhatsApp
Sending Manual Responses
When manual mode is active:
- Customer WhatsApp messages appear in real-time in your conversation view
- A "Manual mode active" indicator shows at the top
- Type your response in the message input box
- Press Enter or click Send
- Your message is delivered to the customer via WhatsApp instantly
- You can send text, images, or other supported media types
When to Use Manual Mode for WhatsApp
Manual mode is particularly useful for:
- Sales Conversations: High-value leads or important customers
- Complex Support: Issues requiring human judgment or empathy
- Escalated Issues: When automated responses aren't sufficient
- VIP Customers: Providing personalized, white-glove service
- Sensitive Topics: Complaints, refunds, or delicate situations
- Business Hours: Handle conversations personally during working hours
WhatsApp Manual Mode Best Practices
Response Time: When in manual mode, respond quickly to maintain customer satisfaction. WhatsApp users expect fast responses.
Switching Strategy:
- Use AI mode during off-hours (nights, weekends)
- Switch to manual during business hours for important conversations
- Return to AI mode when you're not available
Notifications: Enable notifications to know when new WhatsApp messages arrive in manual mode.
Seamless Handoff: Customers won't know when you switch between manual and AI modes - the conversation continues naturally.
Resuming AI Mode
When you're finished with a conversation:
- Toggle the switch back to AI Active
- The agent immediately resumes automatic responses
- The conversation history is preserved
- Future messages are handled by the AI unless you take over again
Pro Tip: You can switch between manual and AI mode multiple times in the same conversation. This flexibility lets you jump in when needed and let the AI handle routine follow-ups.
For help setting up your WhatsApp agent or configuring advanced options, reach out to us at contact@optimly.io.