Automation library · Scheduling

Handle healthcare appointments on WhatsApp with Gemini

Started by an incoming WhatsApp message, and works across Google Calendar, Google Sheets, Redis and WhatsApp. It puts Gemini behind a retrieval step, so answers are drawn from documents you supply rather than from the model alone. 24 steps, 3 branches: large, and worth reading before you trust it with anything live.

LargeCalls a model: GeminiRetrieval

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

The flow

Starts it 2Model 6Logic 5Service 11

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

  1. 1Postgres Chat MemoryMemory Postgres ChatModel
  2. 2Secondary LLMLm Chat Google GeminiModel
  3. 3Primary LLMLm Chat Google GeminiModel
  4. 4WhatsApp TriggerWhats App triggerStarts it
  5. 5Get availability in a calendar in Google CalendarGoogle Calendar ToolService
  6. 6Create an event in Google CalendarGoogle Calendar ToolService
  7. 7Delete an event in Google CalendarGoogle Calendar ToolService
  8. 8Update an event in Google CalendarGoogle Calendar ToolService
  9. 9Get row(s) in sheet in Google SheetsGoogle Sheets ToolService
  10. 10Get Day From DateTool CodeModel
  11. 11Escalate to HumanTool WorkflowModel
  12. 12When Executed by Another WorkflowExecute Workflow triggerStarts it
  13. 13AI AgentAgentModel
  14. 14Handle Message UpdatesIfLogic
  15. 15Crypto1CryptoService
  16. 16Send messageWhats AppService
  17. 17Verify the nameCodeLogic
  18. 18Create A LinkCodeLogic
  19. 19CryptoCryptoService
  20. 20RedisRedisService
  21. 21Get if the escalation ExistsRedisService
  22. 22Send templateWhats AppService
  23. 23Route according to escalation statusIfLogic
  24. 24SwitchSwitchLogic

How it's built

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