Automation library · Scheduling

Multi-platform AI sales agent with RAG and CRM

Started by an incoming WhatsApp message, and works across Airtable, Google Calendar, Google Drive, Telegram and one other. It puts Gemini and OpenAI behind a retrieval step, so answers are drawn from documents you supply rather than from the model alone. 71 steps, 5 branches: large, and worth reading before you trust it with anything live.

LargeCalls a model: Gemini, OpenAIRetrieval

71 stepsLarge: read it before trusting it with anything live
5Branches: places the flow splits
0Loops or waits
5Services it connects to

The flow

Starts it 11Model 17Logic 14Service 18

The steps in the order they run, from what starts it. The first 60 of 71.

  1. 1When chat message receivedChat triggerStarts it
  2. 2Postgres Chat MemoryMemory Postgres ChatModel
  3. 3Consultation AgentTool WorkflowModel
  4. 4CRM AgentTool WorkflowModel
  5. 5Telegram TriggerTelegram triggerStarts it
  6. 6Facebook TriggerWebhookStarts it
  7. 7Instagram TriggerWebhookStarts it
  8. 8WhatsApp TriggerWhats App triggerStarts it
  9. 9When clicking ‘Execute workflow’Manual triggerStarts it
  10. 10Default Data LoaderDocument Default Data LoaderModel
  11. 11GeminiEmbeddings Google GeminiModel
  12. 12When Executed by Another WorkflowExecute Workflow triggerStarts it
  13. 13get_schemaAirtable ToolService
  14. 14list_recordsAirtable ToolService
  15. 15Window Buffer MemoryMemory Buffer WindowModel
  16. 16create_opportunityAirtable ToolService
  17. 17update_opportunityAirtable ToolService
  18. 18create_contactAirtable ToolService
  19. 19update_contactAirtable ToolService
  20. 20Create Event with AttendeeGoogle Calendar ToolService
  21. 21Get EventsGoogle Calendar ToolService
  22. 22Delete EventGoogle Calendar ToolService
  23. 23Update EventGoogle Calendar ToolService
  24. 24OpenAI Chat ModelLm Chat Open AiModel
  25. 25OpenAI Chat Model1Lm Chat Open AiModel
  26. 26OpenAI Chat Model2Lm Chat Open AiModel
  27. 27OpenAI Chat Model3Lm Chat Open AiModel
  28. 28Embeddings OpenAIEmbeddings Open AiModel
  29. 29Set Message6SetLogic
  30. 30Sales AgentAgentModel
  31. 31Route MessageSwitchLogic
  32. 32Respond to Webhook - facebook postRespond To WebhookStarts it
  33. 33Respond to Webhook - facebook getRespond To WebhookStarts it
  34. 34Respond to Webhook - instagram postRespond To WebhookStarts it
  35. 35Respond to Webhook - instagram getRespond To WebhookStarts it
  36. 36Get Lead InfoAirtableService
  37. 37Download fileGoogle DriveService
  38. 38PGVectorVector Store PGVectorModel
  39. 39CRM AssistantAgentModel
  40. 40Calendar AgentAgentModel
  41. 41Company DatabaseTool Vector StoreModel
  42. 42Vector DatabaseVector Store PGVectorModel
  43. 43No Operation, do nothingNo OpLogic
  44. 44Switch1SwitchLogic
  45. 45Set MessageSetLogic
  46. 46Get Audio1TelegramService
  47. 47Reply to userTelegramService
  48. 48If not echoIfLogic
  49. 49If not echo1IfLogic
  50. 50Route MessagesSwitchLogic
  51. 51ResponseSetLogic
  52. 52Try AgainSetLogic
  53. 53SuccessSetLogic
  54. 54Try Again1SetLogic
  55. 55Update Agent DetailsSetLogic
  56. 56Send message (Whatsapp)Whats AppService
  57. 57Send message (facebook)Facebook Graph ApiService
  58. 58Send message (instagram)Http RequestService
  59. 59Send message (embedded)SetLogic
  60. 60Send message (telegram)TelegramService

How it's built

Starts on
An incoming WhatsApp message
Steps
71, with 5 branches
Size
Large: read it before trusting it with anything live
Connects to
Airtable, Google Calendar, Google Drive, Telegram, WhatsApp
Model
Gemini, 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, Google Calendar, Google Drive, Telegram and WhatsApp accounts, and a key for Gemini and 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 Gemini and 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 71 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 71 steps before you point it at anything that matters.