Templates / Draft and approve Gmail replies with OpenAI and CustomJS

Draft and approve Gmail replies with OpenAI and CustomJS

Unknown

by CustomJS ✓ · 0 views · created 2026-05-30 · Ticket Management, AI Chatbot

Unknown. This template uses community nodes we can't verify statically. Uses community nodes that can't be verified statically (unverified community packages are off by default in 3.0). Static check, last run 2026-10-19.

What this workflow does

This AI workflow has 11 nodes and runs manually, when you click “Execute workflow” (plus 1 other trigger). Along the way it connects Gmail, OpenAI and Pdf Toolkit V2 (community).

How it runs

Trigger: Manually, when you click “Execute workflow” (plus 1 other trigger).

  1. Get many messages (Gmail): get many
  2. Extract Reply Data (Code): runs custom JavaScript code
  3. Filter No Reply Emails (Code): runs custom JavaScript code
  4. Reply to a message (Gmail): reply
  5. Generate AI Draft Reply (OpenAI): uses OpenAI
  6. Mark a message as read (Gmail): mark as read
  7. Format Email Drafts (Code): runs custom JavaScript code
  8. Build Approval Page (Code): runs custom JavaScript code
  9. Upsert Approval Page (Pdf Toolkit): create or update (page)

Services it uses

GmailOpenAIPdf Toolkit V2 (community)

Before you upgrade to n8n 3.0

We can't fully verify this one: it relies on 1 community package, and n8n 3.0 turns unverified community packages off by default (N8N_UNVERIFIED_PACKAGES_ENABLED=false).

  • Check that @custom-js/n8n-nodes-pdf-toolkit-v2 is verified or supports 3.0 (used in Upsert Approval Page).

Nodes used (6)

From the author

Quick Overview This workflow drafts replies for unread Gmail messages using OpenAI, publishes a Tailwind/Alpine approval dashboard to CustomJS, and sends approved replies back through Gmail via a webhook submission. How it works 1. Starts manually and pulls…

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