# Route WhatsApp customer support with OpenAI: n8n workflow

> Started by another system calling it, and works across Gmail, Google Drive and Google Sheets. It hands the judgement calls to OpenAI.

Source: https://millionrounds.com/workflow/route-whatsapp-customer-support-with-openai (Millionrounds; every figure on the page links to its filing or article)

[Automation library](https://millionrounds.com/workflows) · [Customer support](https://millionrounds.com/workflows?category=Customer+support#library)

# Route WhatsApp customer support with OpenAI

Started by another system calling it, and works across Gmail, Google Drive and Google Sheets. It hands the judgement calls to OpenAI. 48 steps, 7 branches: large, and worth reading before you trust it with anything live.

Large Calls a model: OpenAI

[Download free](https://millionrounds.com/login?next=%2Fapp%2Fworkflow%2Froute-whatsapp-customer-support-with-openai)

**48 steps** Large: read it before trusting it with anything live

**7** Branches: places the flow splits

**0** Loops or waits

**3** Services it connects to

## The flow

Starts it 4 Model 5 Logic 20 Service 19

The steps in the order they run, from what starts it.

- 1 **📥 WhatsApp Webhook** Webhook *Starts it*
- 2 **📊 Read Support Control Panel** Google Sheets Tool *Service*
- 3 **🧠 OpenAI Chat Model (Reply)** Lm Chat Open Ai *Model*
- 4 **📄 FAQ Knowledge Base** Google Docs Tool *Service*
- 5 **🕙 Daily Summary Trigger** Schedule trigger *Starts it*
- 6 **🧠 OpenAI Chat Model (Summary)** Lm Chat Open Ai *Model*
- 7 **🔍 Parse Evolution Payload** Code *Logic*
- 8 **🧠 Evaluate Intent & Support State** Open Ai *Model*
- 9 **🤖 Generate Customer Reply** Agent *Model*
- 10 **📊 Read All Conversations** Google Sheets *Service*
- 11 **🤖 Generate Daily Summary** Agent *Model*
- 12 **🚦 Skip Check** If *Logic*
- 13 **📤 Parse AI Response** Code *Logic*
- 14 **🕙 Daily Summary Window?** Code *Logic*
- 15 **⏳ Find Inactive Conversations** Code *Logic*
- 16 **📧 Format Daily Summary Email** Code *Logic*
- 17 **✅ Respond 200 (Skip)** Respond To Webhook *Starts it*
- 18 **⌨️ Send Typing Presence** Evolution Api *Service*
- 19 **💾 Save Bot Reply** Google Sheets *Service*
- 20 **🔀 Session Complete?** If *Logic*
- 21 **Send WhatsApp Reply** Evolution Api *Service*
- 22 **📎 Has File?** If *Logic*
- 23 **📈 Aggregate Daily Data** Code *Logic*
- 24 **📧 Send Daily Summary** Gmail *Service*
- 25 **💾 Save User Message** Google Sheets *Service*
- 26 **📎 Email Wait For Upload?** If *Logic*
- 27 **✅ Respond 200** Respond To Webhook *Starts it*
- 28 **📂 Ensure Phone Folder** Google Drive *Service*
- 29 **⚙️ Read Control Panel (Daily)** Google Sheets *Service*
- 30 **🧹 Clear Pending Timer On User Reply** Code *Logic*
- 31 **📂 Search Chat Folder** Google Drive *Service*
- 32 **📧 Route to Department** Gmail *Service*
- 33 **📁 Folder Exists?** If *Logic*
- 34 **🧩 Aggregate Daily Context** Aggregate *Logic*
- 35 **📋 Read Chat Memory** Google Sheets *Service*
- 36 **📁 Chat Folder Exists?** If *Logic*
- 37 **🔗 Get Folder ID** Code *Logic*
- 38 **📂 Create Phone Folder** Google Drive *Service*
- 39 **🧾 Format Conversation History** Code *Logic*
- 40 **🔗 Get Chat Folder ID** Code *Logic*
- 41 **📂 Create Chat Folder** Google Drive *Service*
- 42 **📥 Download WhatsApp Media** Evolution Api *Service*
- 43 **✍️ Make Chat Binary** Code *Logic*
- 44 **📦 Prepare Uploaded File Binary** Code *Logic*
- 45 **📄 Upload Chat Text** Google Drive *Service*
- 46 **☁️ Upload Customer Attachment** Google Drive *Service*
- 47 **💾 Save Attachment Link** Google Sheets *Service*
- 48 **📨 Complete After Upload?** If *Logic*

## How it's built

- **Starts on:** Another system calling it
- **Steps:** 48, with 7 branches
- **Size:** Large: read it before trusting it with anything live
- **Connects to:** Gmail, Google Drive, Google Sheets
- **Model:** OpenAI

## Questions

What does it need to run?

An n8n account, plus your own Gmail, Google Drive and Google Sheets accounts, and a key for OpenAI. You connect your own accounts after importing it; none are included.

What starts it?

It starts on another system calling it.

Does it use AI?

Yes. It calls OpenAI. Model calls are billed by the provider, not by n8n.

How long does it take to set up?

Take your time. At 48 steps it is large: read it before trusting it with anything live.

How do I import it?

Copy the workflow, open a new workflow in n8n and paste. The steps appear on the canvas, ready for your own accounts.

**Before you run it**

Nothing here has been tested by us. It is somebody's working automation, read and described from its own steps. Treat the connections it wants as a list of accounts it will touch, and read the 48 steps before you point it at anything that matters.

## Run it in n8n

- **Create your n8n account** Free to start. n8n is where the workflow runs. [Create an n8n account ↗](https://millionrounds.com/n8n)
- **Download the workflow** Free with a Millionrounds account. [Download free](https://millionrounds.com/login?next=%2Fapp%2Fworkflow%2Froute-whatsapp-customer-support-with-openai)
- **Paste it into n8n** Open a new workflow in n8n and paste. Then connect your own accounts.

Stored with the author's traces removed: canvas notes, instance identifiers, saved credential names and any live document they had left behind.

## Connects to

Each opens the other workflows that use it.

[Gmail](https://millionrounds.com/workflows?service=Gmail#library)[Google Drive](https://millionrounds.com/workflows?service=Google+Drive#library)[Google Sheets](https://millionrounds.com/workflows?service=Google+Sheets#library)

## Workflows like it

Also customer support, with the same services where possible, closest in size first.

- [**Create a multi-modal Telegram support bot with OpenAI** 48 steps · calls a model · Google Drive, Supabase vectors](https://millionrounds.com/workflow/create-a-multi-modal-telegram-support-bot-with-openai)
- [**Multi-department support bot with Pinecone and Telegram** 46 steps · calls a model · Google Drive, Pinecone](https://millionrounds.com/workflow/multi-department-support-bot-with-pinecone-and-telegram)
- [**Route RAG customer support across WhatsApp and Outlook** 41 steps · calls a model · Google Sheets, Outlook](https://millionrounds.com/workflow/route-rag-customer-support-across-whatsapp-and-outlook)
- [**Build an AI-powered SMS support system with Twilio and OpenAI** 40 steps · calls a model · Gmail, Postgres](https://millionrounds.com/workflow/build-an-ai-powered-sms-support-system-with-twilio-and-opena)
- [**AI-powered WhatsApp customer service with OpenAI and Gmail** 37 steps · calls a model · Gmail, Google Sheets](https://millionrounds.com/workflow/ai-powered-whatsapp-customer-service-with-openai-and-gmail)
- [**Route WhatsApp support requests with Claude and Supabase** 37 steps · calls a model · Gmail, Google Calendar](https://millionrounds.com/workflow/route-whatsapp-support-requests-with-claude-and-supabase)
