Templates / Design and apply Gmail label systems with OpenAI and human approval

Design and apply Gmail label systems with OpenAI and human approval

Ready for 3.0

by Mustapha · 34 views · created 2026-08-11 · Document Extraction, 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-12-01.

📬 Weekly n8n 3.0 breakage alerts, free

What this workflow does

This AI workflow has 21 nodes and runs when someone submits an n8n form (“Gmail Inbox Label Setup”). Along the way it connects Gmail and OpenAI.

How it runs

Trigger: When someone submits an n8n form (“Gmail Inbox Label Setup”).

  1. Fetch Gmail Inbox Sample (Gmail): get many
  2. Normalize Emails Data (Code): runs custom JavaScript code
  3. Compile Emails Overview (Code): runs custom JavaScript code
  4. AI Suggest Labels (OpenAI): uses OpenAI
  5. Prepare Labels Proposal (Code): runs custom JavaScript code
  6. Seek Label Approval (n8n Form): shows the next form page
  7. Check Label Approval (If): checks a condition and branches into true / false
  8. Format Approved Labels (Code): runs custom JavaScript code
  9. Display Rejection Message (n8n Form): shows the next form page
  10. Generate Approved Labels in Gmail (Gmail): create (label)

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

Services it uses

GmailOpenAI

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.

Check at runtime on n8n 3.0
  • Code node: the task timeout drops from 300s to 60s. Test with a realistic data volume.
Informational: a static scan can't see the data, so test these on your own instance. Status above is unchanged.

Nodes used (6)

From the author

Quick overview This workflow samples recent Gmail inbox emails, uses OpenAI to propose a tailored Gmail label system, and requires human approval before creating labels and classifying messages, then applies the chosen label to each email and marks it with an…

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