AI automation
WhatsApp AI agent with n8n in South Africa
Build a WhatsApp AI agent with n8n in South Africa, retain context and hand conversations to a person when needed.
Direct answer
A useful WhatsApp AI agent needs four pieces: a webhook, memory per contact, response guardrails and human handoff. Wafly transports messages while n8n coordinates the model, knowledge source and business systems.
A webhook sends each message to n8n, where your workflow retrieves context and asks a model for a response. Wafly delivers it to WhatsApp while your team keeps control of the conversation.
What you can automate
- Answer common questions with context
- Look up catalogues, bookings or order status
- Hand off to a person based on intent or confidence
Before you start
- An inbound message webhook
- A model provider configured in n8n
- A stable identifier per contact
- A clear rule for stopping automation
A production-ready approach
Group short messages
Wait briefly and combine consecutive messages from the same contact. This prevents the agent from sending three replies when someone writes one thought in several parts.
Constrain the source of truth
Give the model only approved information: catalogue, policies, bookings or status retrieved through an API. If evidence is missing, the flow should say so or hand the chat to a person.
Design handoff before the prompt
Terms such as person, agent or complaint should pause the AI. Store a summary, notify the team and do not automate again until an explicit resume signal.
Minimum event state to keep
{
"contact": "27821234567",
"message": "I need to change my booking",
"receivedAt": "2026-08-26T12:00:00Z",
"conversationMode": "ai"
}Production checklist
- Memory isolated per contact
- Message length and retry limits
- Human response for low confidence
- A log of the source used for each answer
- Tests with audio, images and fragmented messages
How to build the workflow
- Receive Wafly message events in an n8n Webhook node.
- Add memory, guardrails and the agent knowledge source.
- Send the response through Wafly and log the interaction in your system.
QR connection, not the official Meta API. Use opt-in contacts and increase volume gradually.
Frequently asked questions
Does Wafly include the AI model?
No. You choose the provider and model inside n8n; Wafly connects the workflow to WhatsApp.
Can a human stay in the loop?
Yes. Add conditions that pause the agent, notify the team and enable human support.
Should every message be automated?
No. Start with narrow intents, track errors and hand off sensitive or uncertain requests.