💬 Smart email auto-responder template using AI

⚡ 15,614 views · 💬 Lead Nurturing & AI Sales Agents

💡 Pro Tip — YouTube’s API quotas can be a bottleneck when you’re pulling data at scale. ScraperNode is a community node with dedicated scrapers for channels, videos, and comments — no quota limits, just structured data.

View All Scrapers

Description

Smart Email Auto-Responder with AI Classification

Automatically Categorize and Reply to Emails using LangChain + Google Gemini + Gmail + SMTP + Brevo

This n8n workflow is designed to intelligently manage incoming emails and automatically send personalized responses based on the content. It classifies emails using LangChain’s Text Classifier, sends HTML responses depending on the category, and updates Gmail and Brevo CRM accordingly.


Key Features

Triggers and Classifies Emails

Responds Automatically

Enhances Workflow with Automation

Optional AI Chat Integration


Tools & Integrations Required

  1. Gmail account (OAuth2)
  2. LangChain (Text Classifier node)
  3. Google Gemini API account
  4. SMTP credentials (e.g., Gmail SMTP, Brevo, etc.)
  5. Brevo/Sendinblue account and API key

Step-by-Step Node Guide

1. Gmail Trigger

Polls Gmail every hour for new emails.
Filters out internal addresses (e.g., @syncbricks.com).
Avoids replying to already-responded emails (Re: subject filter).

2. LangChain Text Classifier

Uses AI to categorize the content of the email based on pre-defined categories:

3. Google Gemini (PaLM) Chat Model (Optional)

Provides additional AI support to enhance classification accuracy.
Can be used to summarize or enrich the context if needed.

4. Email Send Nodes

Each response category has a separate SMTP node with a custom HTML email:

5. Gmail: Mark as Read

Marks the email so it isn’t processed again.

6. Gmail: Apply Label

Adds a label (e.g., Handled by Bot) for organization.

7. Brevo: Create/Update Contact

Saves the sender to your CRM for future communication or marketing.


Email Templates Included

Guest Post Template

Includes pricing, website list, submission guidelines, and payment instructions.

YouTube Review Template

Includes package pricing, review samples, video thumbnails, and inquiry instructions.

Step by Step Tutorial

GET n8n Now

N8N COURSE

n8n Book

More courses:
http://lms.syncbricks.com

YouTube Channel:
https://youtube.com/@syncbricks


How to Use

  1. Import the template into your n8n instance.
  2. Configure your Gmail OAuth2 and SMTP credentials.
  3. Set up your LangChain Text Classifier and Google Gemini API credentials.
  4. Update label ID in the Gmail node and ensure all custom fields like from.value[0].name match your use case.
  5. Run the workflow and watch it respond intelligently to new inquiries.

Best Practices


Attribution & Support

Developed by Amjid Ali
This template took extensive time and effort to build. If you find it useful, please consider supporting my work.

Buy My Book:
Mastering n8n on Amazon

Full Courses & Tutorials:
http://lms.syncbricks.com

Follow Me Online:
LinkedIn: https://linkedin.com/in/amjidali
Website: https://amjidali.com
YouTube: https://youtube.com/@syncbricks

🔗 Nodes Used

Send Email, Gmail, Brevo, Gmail Trigger, Google Gemini Chat Model, Text Classifier

📥 Import

Download workflow.json and import into n8n: Workflow menu → Import from File

📖 Importing guide · 🔑 Credential setup