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 - Listens

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 - Listens for new Gmail messages every hour - Uses AI-based classification to identify the type of inquiry For Example: - Guest Post - YouTube Review - Udemy Course Inquiry Responds Automatically - Sends professional HTML replies customized for each type - Uses SMTP to deliver emails from your domain Enhances Workflow with Automation - Marks processed emails as read - Applies Gmail labels - Adds sender to Brevo contact list Optional AI Chat Integration - Uses Google Gemini (PaLM 2) to enhance classification or summarization --- 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: - Guest Post - Youtube - Udemy Courses 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: - Guest Post Inquiry - YouTube Video Inquiry - Udemy Course Inquiry 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: YouTube Channel: --- 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 - Always test with mock emails first. - Keep the Google Gemini node optional if you want to reduce cost/API calls. - Use Gmail filters to auto-label certain types of emails. - Monitor your Brevo contacts to track new leads. --- 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: Follow Me Online: LinkedIn: Website: YouTube:
Download the workflow JSON file after purchase.
Open n8n → click the menu → Import from File.
Select the downloaded JSON and import.
Set up credentials for each node that requires them.
Click Execute Workflow to test, then activate.
Setup guide included
Purchase to unlock the full step-by-step guide
No reviews yet
Be the first to buy and share your experience.
Leave a review
Sign in to share your experience with this workflow.
Create a free account to purchase workflows.
Need help setting this up?
Book a 3-hour live setup session with an Agility consultant.