Handle WhatsApp sales inquiries with OpenAI, Pinecone, Google Calendar, and Slack
Needs changesNeeds changes. This template uses 1 thing(s) that n8n 3.0 removes: AI Agent v1 (old agent modes). 1 breaking item(s) found. Static check, last run 2026-10-19.
What to replace before upgrading
| Removed in 3.0 | Replace with |
|---|---|
| AI Agent v1 (old agent modes) Sales Agent (v1.7) | Latest AI Agent node (Tools Agent). For SQL Agent, use a Postgres or MySQL tool with a recent AI Agent. |
Nodes used (13)
- WhatsApp Trigger
n8n-nodes-base.whatsAppTrigger - If
n8n-nodes-base.if - No Operation, do nothing
n8n-nodes-base.noOp - AI Agent
@n8n/n8n-nodes-langchain.agent - OpenAI Chat Model
@n8n/n8n-nodes-langchain.lmChatOpenAi - Simple Memory
@n8n/n8n-nodes-langchain.memoryBufferWindow - Pinecone Vector Store
@n8n/n8n-nodes-langchain.vectorStorePinecone - Embeddings OpenAI
@n8n/n8n-nodes-langchain.embeddingsOpenAi - Google Calendar Tool
n8n-nodes-base.googleCalendarTool - Code
n8n-nodes-base.code - Slack
n8n-nodes-base.slack - WhatsApp Business Cloud
n8n-nodes-base.whatsApp - Error Trigger
n8n-nodes-base.errorTrigger
What it does
Quick overview This workflow handles inbound WhatsApp Business messages with an OpenAI-powered sales agent that uses Pinecone RAG for product answers and Google Calendar tools for scheduling, then either replies on WhatsApp or hands the conversation to Slack, with Slack-based error alerts. How it works 1. Triggers on every inbound WhatsApp Business message and checks whether the payload contains a text body. 2. Drops non-text messages (such as images or voice notes) and continues only with text conversations. 3. Uses an OpenAI chat model with per-customer session memory to generate a concise sales reply and decide whether a human handoff is needed. 4. Lets the agent query a Pinecone-backed product catalog via OpenAI embeddings to answer pricing, specs, and availability questions. 5. Lets the agent check availability and book appointments in Google Calendar when the customer requests scheduling. 6. Parses the agent’s HANDOFF flag and either posts the customer message plus draft reply to a Slack channel or sends the reply back to the customer on WhatsApp. 7. Sends a Slack alert to an ops channel if any step in the workflow fails. Setup 1. Connect WhatsApp Business Cloud credentials and set the WhatsApp Phone Number ID used to send replies. 2. Add OpenAI API credentials for both the chat model and embeddings. 3. Configure Pinecone credentials and replace the Pinecone index name used by the product catalog tool. 4. Connect Google Calendar credentials and replace the target calendar ID used for availability checks and bookings. 5. Connect Slack credentials and set the channel IDs for both the handoff channel and the ops/alerts channel.