# AI sales agent: WhatsApp, FB, IG, OpenAI, Airtable, Supabase: n8n workflow

> Started by an incoming WhatsApp message, and works across Airtable, Supabase vectors and WhatsApp.

Source: https://millionrounds.com/workflow/ai-sales-agent-whatsapp-fb-ig-openai-airtable-supabase (Millionrounds; every figure on the page links to its filing or article)

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

# AI sales agent: WhatsApp, FB, IG, OpenAI, Airtable, Supabase

Started by an incoming WhatsApp message, and works across Airtable, Supabase vectors and WhatsApp. It puts OpenAI behind a retrieval step, so answers are drawn from documents you supply rather than from the model alone. 50 steps, 4 branches: large, and worth reading before you trust it with anything live.

Large Calls a model: OpenAI Retrieval

[Download free](https://millionrounds.com/login?next=%2Fapp%2Fworkflow%2Fai-sales-agent-whatsapp-fb-ig-openai-airtable-supabase)

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

**4** Branches: places the flow splits

**0** Loops or waits

**3** Services it connects to

## The flow

Starts it 9 Model 18 Logic 12 Service 11

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

- 1 **Facebook Trigger** Webhook *Starts it*
- 2 **Instagram Trigger** Webhook *Starts it*
- 3 **Embeddings OpenAI** Embeddings Open Ai *Model*
- 4 **OpenAI Chat Model1** Lm Chat Open Ai *Model*
- 5 **Calendar Agent** Tool Workflow *Model*
- 6 **CRM Agent** Tool Workflow *Model*
- 7 **Postgres Chat Memory** Memory Postgres Chat *Model*
- 8 **WhatsApp** Whats App trigger *Starts it*
- 9 **OpenAI Chat Model** Lm Chat Open Ai *Model*
- 10 **Airtable Form Submitted** Webhook *Starts it*
- 11 **Embeddings OpenAI1** Embeddings Open Ai *Model*
- 12 **OpenAI Chat Model2** Lm Chat Open Ai *Model*
- 13 **Postgres Chat Memory1** Memory Postgres Chat *Model*
- 14 **OpenAI Chat Model3** Lm Chat Open Ai *Model*
- 15 **Calendar Agent1** Tool Workflow *Model*
- 16 **When chat message received** Chat trigger *Starts it*
- 17 **Respond to Webhook - facebook post** Respond To Webhook *Starts it*
- 18 **Respond to Webhook - facebook get** Respond To Webhook *Starts it*
- 19 **Respond to Webhook - instagram post** Respond To Webhook *Starts it*
- 20 **Respond to Webhook - instagram get** Respond To Webhook *Starts it*
- 21 **Demo Supabase** Vector Store Supabase *Model*
- 22 **sales_technique_knowledge** Tool Vector Store *Model*
- 23 **AI Agent** Agent *Model*
- 24 **Get Lead** Airtable *Service*
- 25 **Airtable** Airtable *Service*
- 26 **Demo Supabase1** Vector Store Supabase *Model*
- 27 **sales_technique_knowledge1** Tool Vector Store *Model*
- 28 **AI Agent1** Agent *Model*
- 29 **Edit Fields - chat** Set *Logic*
- 30 **If is not echo - facebook** If *Logic*
- 31 **If is not echo - instagram** If *Logic*
- 32 **Switch** Switch *Logic*
- 33 **Handle Message Types** Switch *Logic*
- 34 **Create Contact** Airtable *Service*
- 35 **No Operation, do nothing** No Op *Logic*
- 36 **Edit Fields - facebook** Set *Logic*
- 37 **Sales Agent Demo - typing_on** Facebook Graph Api *Service*
- 38 **Edit Fields - instagram** Set *Logic*
- 39 **Reply To User** Whats App *Service*
- 40 **Facebook Graph API - Sales Agent Demo** Facebook Graph Api *Service*
- 41 **Instagram Graph API - smb.sales.agent.demo** Http Request *Service*
- 42 **Output - chat** Set *Logic*
- 43 **Edit Fields - chat1** Set *Logic*
- 44 **WhatsApp Business Cloud** Whats App *Service*
- 45 **Reply To User1** Whats App *Service*
- 46 **Edit Fields - form** Set *Logic*
- 47 **HTTP Request** Http Request *Service*
- 48 **WhatsApp Business Cloud2** Whats App *Service*
- 49 **OpenAI** Open Ai *Model*
- 50 **Edit Fields - chat2** Set *Logic*

## How it's built

- **Starts on:** An incoming WhatsApp message
- **Steps:** 50, with 4 branches
- **Size:** Large: read it before trusting it with anything live
- **Connects to:** Airtable, Supabase vectors, WhatsApp
- **Model:** OpenAI
- **Retrieval:** Answers are drawn from documents you supply, not from the model alone

## Questions

What does it need to run?

An n8n account, plus your own Airtable, Supabase vectors and WhatsApp accounts, and a key for OpenAI. You connect your own accounts after importing it; none are included.

What starts it?

It starts on an incoming WhatsApp message.

Does it use AI?

Yes. It calls OpenAI. Its answers draw on documents you give it, not on the model alone. Model calls are billed by the provider, not by n8n.

How long does it take to set up?

Take your time. At 50 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 50 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%2Fai-sales-agent-whatsapp-fb-ig-openai-airtable-supabase)
- **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.

[Airtable](https://millionrounds.com/workflows?service=Airtable#library)[Supabase vectors](https://millionrounds.com/workflows?service=Supabase+vectors#library)[WhatsApp](https://millionrounds.com/workflows?service=WhatsApp#library)

## Workflows like it

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

- [**Automate sales meeting prep with Apify** 47 steps · calls a model · Gmail, Google Calendar](https://millionrounds.com/workflow/automate-sales-meeting-prep-with-apify)
- [**Automate salon appointment management with WhatsApp and OpenAI** 56 steps · calls a model · Gmail, Google Calendar](https://millionrounds.com/workflow/automate-salon-appointment-management-with-whatsapp-and-open)
- [**Automated HR Service System with WhatsApp and OpenAI** 57 steps · calls a model · Gmail, Google Calendar](https://millionrounds.com/workflow/automated-hr-service-system-with-whatsapp-and-openai)
- [**Automated customer reservations with Postgres and WhatsApp** 39 steps · Postgres, WhatsApp](https://millionrounds.com/workflow/automated-customer-reservations-with-postgres-and-whatsapp)
- [**AI-Powered WhatsApp Chatbot: Complete Booking Assistant** 37 steps · calls a model · Gmail, Google Calendar](https://millionrounds.com/workflow/ai-powered-whatsapp-chatbot-complete-booking-assistant)
- [**Build a WhatsApp assistant with Google Suite** 63 steps · calls a model · Gmail, Google Calendar](https://millionrounds.com/workflow/build-a-whatsapp-assistant-with-google-suite)
