Templates / Automate email categorization & response generation with Gmail & GPT-4

Automate email categorization & response generation with Gmail & GPT-4

Needs changes

by Paul ✓ · 1,404 views · created 2025-08-11 · Ticket Management, Multimodal AI

Needs changes. This template uses 1 thing(s) that n8n 3.0 removes: OpenAI (legacy). 1 breaking item(s) found. Static check, last run 2026-10-19.

What this workflow does

This workflow has 12 nodes and runs when an HTTP POST request hits its webhook URL. Along the way it connects Gmail and Google Sheets.

How it runs

Trigger: When an HTTP POST request hits its webhook URL.

  1. 📩 Get Email Details (Gmail): get
  2. 🤖 AI Email Analyzer (OpenAI): uses OpenAI
  3. 🚦 Priority Router (If): checks a condition and branches into true / false
  4. 🚨 High Priority Alert (Gmail): uses Gmail
  5. 🛡️ Spam Detector (If): checks a condition and branches into true / false
  6. 🏷️ Categorize Email (Gmail): modify
  7. 🗑️ Move to Spam (Gmail): modify
  8. 💬 Auto-Reply Detector (If): checks a condition and branches into true / false
  9. 📊 Log to Spreadsheet (Google Sheets): append or update (spreadsheet)
  10. 📝 Create Reply Draft (Gmail): work with draft

…plus 1 more step. See the full node list below.

Services it uses

GmailGoogle Sheets

Before you upgrade to n8n 3.0

1 thing in this workflow is removed in n8n 3.0. Fix it before you upgrade:

  • OpenAI (legacy) in 🤖 AI Email Analyzer: replace with OpenAI node (AI section).

Rather not rewrite it? Many of these flows can be rebuilt in Make (free plan).

Removed in 3.0Replace with
OpenAI (legacy)
🤖 AI Email Analyzer
OpenAI node (AI section)

Nodes used (6)

From the author

Gmail AI Email Manager - Setup Guide 🎯 Workflow Overview This workflow will create an intelligent Gmail email manager that can: - Monitor incoming emails via webhook - Analyze email content using AI - Categorize emails automatically - Generate smart…

Excerpt from Paul'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.