Templates / Draft and approve Gmail replies and follow-ups with OpenAI

Draft and approve Gmail replies and follow-ups with OpenAI

Ready for 3.0

by Thiago Cavalcanti ✓ · 8 views · created 2026-10-01 · Lead Nurturing, AI Summarization

Ready for 3.0. This template uses no nodes that n8n 3.0 removes. No removed nodes, versions or helpers found. Static check, last run 2026-10-19.

What this workflow does

This AI workflow has 31 nodes and runs on Gmail events (message received) (plus 1 other trigger). Along the way it connects Gmail and OpenAI Chat Model.

How it runs

Trigger: On Gmail events (message received) (plus 1 other trigger).

  1. Your settings (Edit Fields (Set)): sets 11 fields: ownerEmail, senderName, companyName…
  2. New email or weekly run? (If): checks a condition and branches into true / false
  3. Get all leads (Data table): get (row)
  4. Get your leads (Data table): get (row)
  5. Match each email to a lead (Code): runs custom JavaScript code
  6. Keep only quiet leads (Code): runs custom JavaScript code
  7. Sender is a lead? (If): checks a condition and branches into true / false
  8. Classify and draft a reply (Basic LLM Chain): sends a prompt to an LLM, with model: OpenAI model (replies)
  9. Search Gmail for replies (Gmail): get many (message)
  10. Mark the lead as replied (Data table): update (row)

…plus 16 more steps. See the full node list below.

Services it uses

GmailOpenAI Chat Model

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 (10)

From the author

Quick overview This workflow monitors your Gmail inbox for new unread messages, uses OpenAI to classify them and draft fact-based replies, and then emails the draft to an owner for approval before replying in the original Gmail thread. How it works 1.…

Excerpt from Thiago Cavalcanti's description on n8n.io.

View the original on n8n.io → Check your own copy

Get the weekly “what broke” email

New templates, newly broken ones, and n8n release changes. One short email a week.

Form not loading? Subscribe here.