Answer WhatsApp text, voice, image and video messages with OpenAI and Gemini
Ready for 3.0What this workflow does
This AI workflow has 19 nodes and runs on WhatsApp events (messages). Along the way it connects WhatsApp Business Cloud, OpenAI, Google Gemini and OpenAI Chat Model and 1 more.
How it runs
Trigger: On WhatsApp events (messages).
- Configuration (Edit Fields (Set)): sets 7 fields: system_prompt, openai_model, gemini_model…
- Split Out: splits a list into separate items
- Route by Message Type (Switch): routes items into 3 branches
- Get Audio Download URL (WhatsApp Business Cloud): media url get
- Get Video Download URL (WhatsApp Business Cloud): media url get
- Get Image Download URL (WhatsApp Business Cloud): media url get
- Prepare Agent Input (Edit Fields (Set)): sets 4 fields: message_type, message_text, message_caption…
- Download Audio File (HTTP Request): calls an HTTP API
- Download Video File (HTTP Request): calls an HTTP API
- Download Image File (HTTP Request): calls an HTTP API
…plus 5 more steps. See the full node list below.
Services it uses
Before you upgrade to n8n 3.0
Nothing in this workflow is removed in n8n 3.0, so it should import and run after the upgrade.
Nodes used (12)
- WhatsApp Trigger
n8n-nodes-base.whatsAppTrigger - Edit Fields (Set)
n8n-nodes-base.set - Split Out
n8n-nodes-base.splitOut - Switch
n8n-nodes-base.switch - WhatsApp Business Cloud
n8n-nodes-base.whatsApp - HTTP Request
n8n-nodes-base.httpRequest - OpenAI
@n8n/n8n-nodes-langchain.openAi - Google Gemini
@n8n/n8n-nodes-langchain.googleGemini - AI Agent
@n8n/n8n-nodes-langchain.agent - OpenAI Chat Model
@n8n/n8n-nodes-langchain.lmChatOpenAi - Simple Memory
@n8n/n8n-nodes-langchain.memoryBufferWindow - Wikipedia
@n8n/n8n-nodes-langchain.toolWikipedia
From the author
Quick overview This workflow replies to incoming WhatsApp Business messages (text, voice notes, images, and videos) by transcribing or describing media with OpenAI and Google Gemini, then generating a conversational response with an OpenAI-powered agent that…