by Jose Cuartas
Sync Gmail emails to PostgreSQL with S3 attachment storage Automated Gmail Email Processing System Who's it for Businesses and individuals who need to: Archive email communications in a searchable database Backup email attachments to cloud storage Analyze email patterns and communication data Comply with data retention policies Integrate emails with other business systems What it does This workflow automatically captures, processes, and stores Gmail emails in a PostgreSQL database while uploading file attachments to S3/MinIO storage. It handles both individual emails (via Gmail Trigger) and bulk processing (via Schedule Trigger). Key features: Dual processing: real-time individual emails + scheduled bulk retrieval Complete email metadata extraction (sender, recipients, labels, timestamps) HTML to plain text conversion for searchable content Binary attachment processing with metadata extraction Organized S3/MinIO file storage structure UPSERT database operations to prevent duplicates How it works Email Capture: Gmail Trigger detects new emails, Schedule Trigger gets bulk emails from last hour Parallel Processing: Emails with attachments go through binary processing, others go directly to transformation Attachment Handling: Extract metadata, upload to S3/MinIO, create database references Data Transformation: Convert Gmail API format to PostgreSQL structure Storage: UPSERT emails to database with linked attachment information Requirements Credentials needed: Gmail OAuth2 (gmail.readonly scope) PostgreSQL database connection S3/MinIO storage credentials Database setup: Run the provided SQL schema to create the messages table with JSONB fields for flexible data storage. How to set up Gmail OAuth2: Enable Gmail API in Google Cloud Console, create OAuth2 credentials PostgreSQL: Create database and run the SQL schema provided in setup sticky note S3/MinIO: Create bucket "gmail-attachments" with proper upload permissions Configure: Update authenticatedUserEmail in transform scripts to your email Test: Start with single email before enabling bulk processing How to customize Email filters**: Modify Gmail queries (in:sent, in:inbox) to target specific emails Storage structure**: Change S3 file path format in Upload node Processing schedule**: Adjust trigger frequencies based on email volume Database fields**: Extend PostgreSQL schema for additional metadata Attachment types**: Add file type filtering in binary processing logic Note: This workflow processes emails from the last hour to avoid overwhelming the system. Adjust timeframes based on your email volume and processing needs.
by Sankalp Dev
Automated Marketing Analytics Report with AI Agent How it works Transform your marketing data into actionable insights with this intelligent automation workflow. The system combines scheduled triggers with AI-powered analysis to deliver comprehensive marketing reports directly to your inbox. Key Features: Scheduled automated reporting (daily, weekly, or monthly) AI-powered data analysis using advanced language models Multi-platform marketing data integration via GoMarble MCP Intelligent report generation with actionable recommendations Direct email delivery of formatted reports Set up steps Prerequisites: GoMarble MCP account and API access Gmail account for report delivery n8n instance (cloud or self-hosted) Configuration Time: ~15-20 minutes Step-by-step setup: Connect GoMarble MCP to n8n Follow the integration guide: GoMarble n8n Setup Configure your marketing platform credentials (Google Ads, Facebook Ads, Analytics) Configure the Schedule Trigger Set your preferred reporting frequency Choose optimal timing for data availability Customize the Report Prompt Define specific metrics and KPIs to track Set analysis parameters and report format preferences Set up AI Agent Configuration Choose between Anthropic Claude or OpenAI models Configure the GoMarble MCP tools for your marketing platforms Configure Gmail Integration Set recipient email addresses Customize email template and subject line Advanced Configuration: Add conditional logic for performance thresholds Include custom data visualization requests Set up alert triggers for significant metric changes What you'll get Automated Intelligence:** Regular marketing performance analysis without manual effort Cross-Platform Insights:** Unified view of Google Ads, Facebook Ads, and Analytics data AI-Powered Recommendations:** Strategic insights and optimization suggestions Professional Reports:** Well-formatted, executive-ready marketing summaries Scalable Solution:** Easy to extend with additional marketing platforms or custom metrics Perfect for marketing teams, agencies, and business owners who want to stay on top of their marketing performance with minimal manual work.
by Msaid Mohamed el hadi
Overview This workflow automates the discovery, extraction, enrichment, and storage of business information from Google Maps search queries using AI tools, scrapers, and Google Sheets. It is ideal for: Lead generation agencies Local business researchers Digital marketing firms Automation & outreach specialists 🔧 Tools & APIs Used Google Maps Search (via HTTP)** Custom JavaScript Parsing** URL Filtering & De-duplication** Google Sheets (Read/Write)** APIFY Actor** for business scraping LangChain AI Agent** (OpenRouter - Gemini 2.5) n8n Built-in Logic** (Loops, Conditions, Aggregators) 🧠 Workflow Summary Trigger The automation starts via schedule (every hour). Read Queries from Google Sheet Loads unprocessed keywords from a Google Sheet tab named keywords. Loop Through Keywords Each keyword is used to search Google Maps for relevant businesses. Extract URLs JavaScript parses HTML to find all external website URLs from the search results. Clean URLs Filters out irrelevant domains (e.g., Google-owned, example.com, etc.), and removes duplicates. Loop Through URLs For each URL: Checks if it already exists in the Google Sheet (to prevent duplication). Calls the APIFY Actor to extract full business data. Optionally uses AI Agent (Gemini) to provide detailed insight on the business, including: Services, About, Market Position, Weaknesses, AI suggestions, etc. Converts the AI result (text) to a structured JSON object. Save to Google Sheet Adds all extracted and AI-enriched business information to a separate tab (Sheet1). Mark Queries as Processed Updates the original row in keywords to avoid reprocessing. 🗃️ Output Fields Saved The following information is saved per business: Business Name, Website, Email, Phone Address, City, Postal Code, Country, Coordinates Category, Subcategory, Services About Us, Opening Hours, Social Media Links Legal Links (Privacy, Terms) Logo, Languages, Keywords AI-Generated Description** Google Maps URL 📈 Use Cases Build a prospect database for B2B cold outreach. Extract local SEO insights per business. Feed CRMs or analytics systems with enriched business profiles. Automate market research for regional opportunity detection. 📩 Want a Similar Workflow? If you’d like a custom AI-powered automation like this for your business or agency, feel free to contact me: 📧 msaidwolfltd@gmail.com
by Manav Desai
This n8n template demonstrates how to build a weekly Hollywood film industry briefing using Tavily for real-time search and Google Gemini for summarization. It sends a concise, emoji‑styled email with movie releases, box office results, industry news, and must‑watch recommendations every week automatically. Use cases: Great for film journalists, entertainment bloggers, or movie enthusiasts who want automated weekly updates without manually checking multiple sources. Good to know Free to use: Tavily provides **1,000 API credits per month on their free plan (no credit card required), so this workflow can run at zero cost. Real-time data**: Tavily’s search API is optimized for up-to-date information — perfect for weekly movie releases and box office stats. Google Gemini is used for summarization, and you only need basic API access (no paid tier required). How it works Trigger**: Scheduled every Thursday morning (configurable). Search**: Four Tavily API calls gather: Movies releasing this week Last week’s box office results Hollywood industry news Must‑watch movies currently in theatres Summarization**: Google Gemini turns this into Gmail‑friendly HTML with emojis and bullet points. Email**: The formatted newsletter is sent via Gmail node. How to use Configure Tavily API and Gmail OAuth2 credentials in n8n’s credential manager. (Optional) Edit Tavily queries to focus on specific genres or add filters. Adjust the schedule trigger to any day/time you prefer. Requirements Tavily API account (free plan – 1,000 monthly requests) Google Gemini API key for summarization Gmail account (OAuth2 credentials for sending emails) Want insane output quality? You can swap Gemini for OpenAI’s ChatGPT models: GPT‑3.5 Turbo** – \~\$0.002/run (crazy cheap) GPT‑4o** – \~\$0.009/run (latte price) GPT‑4.5** – \~\$0.15/run (god‑mode quality) This upgrade gives you cleaner, richer, “did‑a‑human‑write‑this?” vibes — perfect for journalist‑grade Hollywood briefings. Just note: OpenAI API requires a \$5 minimum credit to activate usage. Example Output (ChatGPT version) Subject: Daily Hollywood Film Industry Briefing – August 3, 2025 Good morning, Here's your daily Hollywood film briefing for August 3, 2025: 🎬 Releases The Bad Guys 2 – Released Friday, August 1, 2025 The Naked Gun – Released Friday, August 1, 2025 These are the confirmed new wide theatrical Hollywood releases this week (Monday through Sunday of current week). No additional new Hollywood theatrical releases found for this week. 📊 Box Office Highest‑grossing Hollywood films of 2025 (worldwide): Ne Zha 2 – approx. \$1.90 billion (non‑Hollywood Chinese animated film leads) Lilo & Stitch – approx. \$1.02 billion A Minecraft Movie – approx. \$955 million Jurassic World Rebirth – approx. \$731 million How to Train Your Dragon – approx. \$610 million Last week’s box office performance (Monday–Sunday): The Fantastic Four: First Steps – domestic debut \\$118 M; global \\$218 M, Marvel’s biggest opening of 2025 Superman – added \~\$94 M worldwide last week, passing \$500 M global total Jurassic World Rebirth – up \\$70 M worldwide last week, despite \40 % drop week‑on‑week F1: The Movie – up \~\$48 M last week internationally/domestically growth visible Lilo & Stitch – added \~\$10 M worldwide last week, slower tail but still billion‑plus gross Highlights & trends: Fantastic Four’s strong debut reboots Marvel success, signaling resumed audience interest; Superman continues to hold strong; Jurassic World Rebirth remains durable after holiday surge; surge in box office recovery noted across key titles. Overall box office up \~12–15 % year‑on‑year. 📰 Industry Buzz Christopher Nolan has signed to direct a massive \$250 million adaptation of Homer’s The Odyssey, starring Matt Damon and Tom Holland, with Imax pre‑sales at 95 % capacity across major locations. Marvel has relaunched the Fantastic Four franchise successfully with First Steps; positive CinemaScore and strong visuals marking a fresh start. DC’s Superman continues strong with over \$500 M global, solidifying DC’s summer comeback. Universal’s Jurassic World Rebirth continues strong overseas, especially in China, contributing to \$318 M global in opening holiday weekend. Warner Bros.–Discovery stock surges (\~30 %) amid box office rebound, with Disney, IMAX and Cinemark also seeing robust growth in 2025. Ne Zha 2 becomes highest‑grossing animated and non‑Hollywood film ever, crossing \$2 billion globally—though not Hollywood, its impact on global trends is notable. Mission: Impossible – The Final Reckoning quietly solidifies strong global numbers (\~\$562 M) and continues reliable franchise performance. 🎥 Must‑Watch in Theatres (Surat, India) The Fantastic Four: First Steps** – Currently showing in English/Hindi/Tamil/Telugu in Surat cinemas; hyped globally, strong visuals, action‑heavy, best experienced in IMAX or premium formats if available in Surat multiplexes. Runs this week. F1: The Movie** – Available in Surat in multiple languages, strong reviews praising adrenaline‑fuelled direction and visuals and growing fan hype; ideal in standard or Dolby formats for immersive sound and speed feel. Jurassic World Rebirth** – Still playing in Surat, popular with family audiences; grand visuals and dinosaur action well‑suited to IMAX or large format screens. That’s all for today’s briefing. Have a great theatrical weekend ahead!
by Cheng Siong Chin
Introduction Upload invoices via Telegram, receive structured data instantly. Perfect for accountants and finance teams. How It Works Telegram bot receives invoices, downloads files, extracts data using OpenAI, then returns analysis. Workflow Template Telegram Trigger → Document Check → Get File → HTTP Download → AI Extract → Format Response → Send to Telegram Workflow Steps Telegram Trigger: Listens for uploads. Document Check: Validates files; routes errors. Get File: Retrieves metadata. HTTP Download: Fetches content. AI Extract: OpenAI parses invoice fields. Format Response: Structures data. Send Analysis: Delivers to chat. Setup Instructions Telegram Bot: Create via BotFather, add credentials. OpenAI Agent: Add API key and extraction prompt. HTTP Node: Set authentication. Parser: Define invoice schema. Error Handling: Configure fallbacks. Prerequisites n8n instance Telegram Bot Token OpenAI API key Customization Database storage Accounting software integration Benefits Eliminates manual entry Reduces errors
by Atta
Turn raw feedback into actionable product insights. This workflow collects feedback from both customers and staff via a single Jotform, uses Gemini AI to analyze and categorize it, then intelligently routes it: Actionable bugs and feature requests* become tasks in specific *Trello** lists, tagged with source and priority. General feedback* is logged in a structured *Airtable** base for later review. Urgent bugs* trigger instant *Slack** alerts for your dev team. An optional confirmation email is sent via Gmail if the submitter provides their address. Stop manually sorting feedback and ensure nothing falls through the cracks. This workflow centralizes input, automates triage, and delivers structured data directly to your product and development teams. Features Unified Feedback Collection:** Uses a single Jotform for customers and staff. AI-Powered Triage:** Gemini AI categorizes feedback (Bug, Feature Request, General), suggests priority, and extracts keyword tags. Intelligent Filtering:** An IF node separates actionable tasks from general comments. Automated Task Creation:** Creates Trello cards in specific lists ("Bugs," "Feature Backlog") with relevant labels (Source, Urgent). Structured Logging:** Saves all general feedback to an Airtable base for review and trend analysis. Conditional Alerts:* Notifies a Slack channel *only for high-priority bugs. Optional Email Confirmation:** Sends a thank-you email if the submitter provides their address. Nodes Used 🟣 Jotform Trigger (Jotform Trigger) ✉️ Gmail (Send Confirmation Email) 🧠 AI Agent (AI Feedback Triage) 🃏 Trello (Create Trello Card) 📣 Slack (Alert Dev Team) 🗂️ Airtable (Log General Feedback to Airtable) 🔧 Set, **❓ IF, 🚫 No Operation, do nothing How to use this template Follow these steps to configure the workflow with your accounts and specific IDs. 1. Set up Jotform, Trello, and Airtable (CRITICAL) Before starting, you must create the Jotform form, Trello board, and Airtable base exactly as described in the "Required Setup" section at the end of this document. 2. Configure the Jotform Trigger Node Credentials:** Connect your Jotform account. Form:** Select your "Help us improve IdeaToBiz" form (replace the title with your company name). Resolve Data:* Ensure the *"Resolve Data"* toggle in the node's parameters is turned *ON**. 3. Configure the Config (Set) Node This node stores your Trello IDs. You must replace the placeholder values. Find Your IDs:** Open your Trello board, add .json to the URL, and press Enter. Search the JSON page for your List names ("Bugs," "Feature Backlog") and Label names ("Customer," "Staff," "Other," "Urgent") to find their corresponding "id" values. Action:** Paste your unique IDs into the value fields in this node. 4. Configure the Email Provided? (IF) and Send Confirmation Email (Gmail) Nodes IF Node:** No configuration needed. Gmail Node:** Credentials: Connect your Gmail (or other email service) account. Customize: Edit the Subject and Body to match your company's voice. 5. Configure the AI Feedback Triage Node Credentials:** Connect your Google AI (Gemini) credentials. Check Prompt:** Ensure the prompt correctly references your feedback field (e.g., {{ $('Jotform Trigger').item.json['Feedback Details'] }}). Check Schema:** Ensure the "Structured Output" JSON schema matches the required fields (task_title, category, suggested_priority, tags). 6. Configure the Is it a Bug or Feature? (IF) Node No configuration needed. This node filters based on the AI output. 7. Configure the Create Trello Card Node Credentials:** Connect your Trello credentials. Board ID:** Select your Product Feedback board. Check Expressions:** Verify that the expressions for List ID and Labels correctly pull the IDs from your Config node and data from the AI Feedback Triage and Jotform Trigger nodes. The template should be pre-filled, but double-check node names if you renamed them. 8. Configure the Is it an Urgent Bug? (IF) Node No configuration needed. This checks the AI output before alerting Slack. 9. Configure the Alert Dev Team (Slack) Node Credentials:** Connect your Slack credentials. Channel:** Select the channel for urgent bug alerts (e.g., #dev-alerts). Customize:** Edit the message text if desired. Ensure the Trello card URL expression ({{ $('Create Trello Card').item.json.shortUrl }}) is correct. 10. Configure the Log General Feedback to Airtable Node Credentials:** Connect your Airtable credentials. Base ID:** Select your Product Feedback Log base. Table ID:** Select your Feedback Submissions table. Enable Typecast:* In the node's *Options, ensure the **Typecast toggle is ON. This is crucial for allowing n8n to create new tag options in Airtable. Check Field Mappings:** Verify that the field mappings correctly reference the AI Feedback Triage and Jotform Trigger nodes. 11. Activate Your Workflow! Once all credentials and IDs are configured, save and activate your workflow. How to Adapt the Template Change Task Destination:* Replace the Trello node with *ClickUp, **Asana, Jira, or another task manager. You'll need to adapt the field mappings. Change Logging Destination:* Replace the Airtable node with *Google Sheets, **Notion, or send logs via Email or Discord. Adjust AI Prompt:** Modify the prompt in the AI Feedback Triage node to change how feedback is categorized, prioritized, or tagged. Modify Filtering Logic:** Change the conditions in the Is it a Bug or Feature? IF node (e.g., maybe you also want "UI/UX Issue" to go to Trello). Refine Alerting:** Change the conditions in the Is it an Urgent Bug? IF node or send alerts for different categories (e.g., alert the design team for UI issues). Required Setup Jotform Form Setup Create Account: If needed, sign up at Jotform. Create Form: Build a form titled "Help us improve IdeaToBiz" (or similar). Add Fields: Radio Button: Label I am a..., Options Customer, Staff, Other (Required: ON). Email: Label Your Email (Optional) (Required: OFF). Long Text: Label Feedback Details (Required: ON). Submit Button: Label Submit Feedback. Trello Board Setup Create Board: Create a new Trello board named Product Feedback. Create Lists (Columns): Add at least these two lists: Feature Backlog Bugs Create Labels: Go to Menu -> More -> Labels and create: Urgent (Red recommended) Customer (Blue recommended) Staff (Green recommended) Other (Grey recommended) Airtable Base Setup Create Base: Create a new Airtable base named Product Feedback Log. Create Table: Name the table Feedback Submissions. Configure Fields: Rename the primary field (Name) to Feedback Summary (Type: Single line text). Rename Notes to Full Feedback (Type: Long text). Delete Assignee. Rename Status to Source (Type: Single select, Options: Customer, Staff, Other). Add Email field (Type: Email). Add AI Tags field (Type: Multiple select). Add Submitted At field (Type: Created time).
by Sulieman Said
How it Works This workflow automates the process of discovering companies in different cities, extracting their contact data, and storing it in Airtable. City Loop (Airtable → Google Maps API) Reads a list of cities from Airtable. Uses each city combined with a search term (e.g., SEO Agency, Berlin) to query Google Maps. Marks processed cities as “checked” to allow safe restarts if interrupted. Business Discovery & Deduplication Searches for businesses via Google Maps Text Search. Checks Airtable to avoid scraping the same company multiple times. Fetches detailed info for each business via Google Maps Place Details API. Impressum Extraction (Website → HTML Parsing) Builds an Impressum page URL for each business. Requests the HTML and cleans out ads, headers, footers, etc. Extracts relevant contact info using an AI extractor (OpenAI node). Contact Information Extraction Pulls out: Decision Maker (Name + Position in one string, if available). Email address (must be valid, containing @). Phone number (international format if possible). Filters out incomplete results (e.g., empty email). Database Storage Writes company data back into Airtable: Company name Address Website Email Phone number Decision Maker (Name + Position) Search term & city used Setup Steps 1. Prerequisites Google Maps API Key with access to: Places API → Text Search + Place Details Airtable base with at least two tables: Cities (with columns: ID, City, Country, Status) Companies (for scraped results) OpenAI API key (for decision maker + contact extraction). 2. Authentication Configure your Airtable API credentials in n8n. Set up HTTP Query Auth with your Google Maps API key. Add your OpenAI API key in the OpenAI Chat node. 3. Configuration In the Airtable “Cities” table, list all cities you want to scrape. Define your search term in the “Execute Workflow” node (e.g., SEO Agency). Adjust the batch sizes and wait intervals if you want faster/slower scraping (Google API has strict rate limits). 4. Execution Start manually or from another workflow. The workflow will scrape all companies in each city step by step. It can be safely stopped and resumed — cities already marked as processed will be skipped. 5. Results Enriched company dataset stored in Airtable, ready for CRM import, lead generation, or further automation. Tips & Notes Always respect GDPR and local laws when handling scraped data. The workflow is modular → you can swap Airtable with Google Sheets, Notion, or a database of your choice. Add custom filters to limit results (e.g., only companies with websites). Use sticky notes inside the workflow to understand each step (mandatory for template publishing). Keep an eye on Google Places API costs** — queries are billed after the free quota. If you are still within the first 2 months of the Google Cloud Developer free trial, you can benefit from free credits. Questions or custom requests? 📩 suliemansaid.business@gmail.com
by Nguyen Thieu Toan
How it works 🧠 AI-Powered News Update Bot for Zalo using Gemini and RSS Feeds This workflow allows you to build a smart Zalo chatbot that automatically summarizes and delivers the latest news using Google Gemini and RSS feeds. It’s perfect for keeping users informed with AI-curated updates directly inside Vietnam’s most popular messaging app. 🚀 What It Does Receives user messages via Zalo Bot webhook Fetches the latest articles from an RSS feed (e.g., AI news) Summarizes the content using Google Gemini Formats the response and sends it back to the user on Zalo 📱 What Is Zalo? Zalo is Vietnam’s leading instant messaging app, with over 78 million monthly active users—more than 85% of the country’s internet-connected population. It handles 2 billion messages per day and is deeply embedded in Vietnamese daily life, making it a powerful channel for communication and automation. 🔧 Setup Instructions 1. Create a Zalo Bot Open the Zalo app and search for "Zalo Bot Creator" Tap "Create Zalo Bot Account" Your bot name must start with "Bot" (e.g., Bot AI News) After creation, Zalo will send you a message containing your Bot Token 2. Configure the Webhook Replace [your-webhook URL] in Zalo Bot Creator with your n8n webhook URL Use the Webhook node in this workflow to receive incoming messages 3. Set Up Gemini Add your Gemini API key to the HTTP Request node labeled Summarize AI News Customize the prompt if you want a different tone or summary style 4. Customize RSS Feed Replace the default RSS URL with your preferred news source You can use any feed that provides timely updates (e.g., tech, finance, health) 🧪 Example Interaction User: "What's new today?" Bot: "🧠 AI Update: Google launches Gemini 2 with multimodal capabilities, revolutionizing how models understand text, image, and code..." ⚠️ Notes Zalo Bots currently do not support images, voice, or file attachments Make sure your Gemini API key has access to the model you're calling RSS feeds should be publicly accessible and well-formatted 🧩 Nodes Used Webhook HTTP Request (Gemini) RSS Feed Read Set & Format Zalo Message Sender (via API) 💡 Tips You can swap Gemini with GPT-4 or Claude by adjusting the API call Add filters to the RSS node to only include articles with specific keywords Use the Function node to personalize responses based on user history Built by Nguyen Thieu Toan (Nguyễn Thiệu Toàn) (https://nguyenthieutoan.com). Read more about this workflow by Vietnamese: https://nguyenthieutoan.com/share-workflow-n8n-zalo-bot-cap-nhat-tin-tuc/
by Rahul Joshi
Description Automate your AI-powered outreach and follow-up pipeline end-to-end with GPT-4o, Gmail, and Google Sheets. 🤖📬 This workflow personalizes emails for each lead, manages follow-ups automatically, tracks client replies, and updates CRM records in real time — all from a single Google Sheet. Ideal for sales and growth teams looking to convert leads faster without manual effort. ⚙️🚀 What This Template Does 1️⃣ Starts manually when you click “Execute workflow.” 🕹️ 2️⃣ Fetches all leads from the Google Sheet (sample_leads_50). 📊 3️⃣ Validates email format and filters only active (unbooked) leads. 🔍 4️⃣ Uses Azure OpenAI GPT-4o to generate short, personalized outreach emails in HTML. ✉️ 5️⃣ Cleans and parses the AI output (subject + HTML body). 🧠 6️⃣ Sends the first outreach email via Gmail and stores its thread ID. 📤 7️⃣ Waits 24 hours, then checks for a client reply in the Gmail thread. ⏱️ 8️⃣ If a positive reply is found → marks lead as BOOKED and updates in Sheets. ✅ 9️⃣ If no reply → triggers a polite follow-up email, waits again 24 hours, and checks the thread a second time. 🔁 🔟 If a second reply is found → marks BOOKED and logs the client message. 1️⃣1️⃣ If still no response → updates status to Declined in Google Sheets. ❌ 1️⃣2️⃣ Logs invalid or incomplete leads to a separate sheet for data cleanup. 🧾 Key Benefits ✅ Eliminates manual outreach and follow-up effort. ✅ Produces personalized, context-aware AI emails for every lead. ✅ Auto-tracks replies and updates CRM status with zero input. ✅ Prevents duplicate or repeated contact with booked clients. ✅ Keeps lead database synchronized and audit-ready. Features Google Sheets integration for dynamic lead retrieval and updates. Regex-based email validation for clean data pipelines. Azure OpenAI GPT-4o for contextual email writing. Two-stage Gmail automation (initial + follow-up). JavaScript parsing for AI output and Gmail thread analysis. Automated 24-hour wait and recheck logic. Conditional branches for Booked / Declined / Invalid outcomes. End-to-end CRM synchronization without manual review. Requirements Google Sheets OAuth2 credentials with read/write access. Azure OpenAI API key for GPT-4o model access. Gmail OAuth2 credentials with send, read, modify permissions. Environment Variables GOOGLE_SHEET_LEADS_ID GOOGLE_SHEET_OUTREACH_TAB_ID AZURE_OPENAI_API_KEY GMAIL_OAUTH_CLIENT_ID GMAIL_OAUTH_SECRET Target Audience 💼 Sales and Business Development teams automating outreach. 📈 Marketing and Growth teams running re-engagement campaigns. 🤖 Automation and RevOps teams integrating AI lead workflows. 💬 Freelancers and agencies managing large prospect lists. 📊 Operations teams maintaining CRM cleanliness and tracking. Step-by-Step Setup Instructions 1️⃣ Connect your Google Sheets, Azure OpenAI, and Gmail credentials. 2️⃣ Set your Google Sheet ID and tab name (outreach automation). 3️⃣ Update the GPT-4o system prompt to match your tone and signature. 4️⃣ Verify column headers (Company Name, Email, Booking Status, etc.). 5️⃣ Test the email validation branch with sample data. 6️⃣ Run once manually to confirm Gmail thread creation and reply detection. 7️⃣ Confirm successful CRM updates in Google Sheets. 8️⃣ Activate for continuous lead outreach and follow-up automation. ✅
by Satoshi
Overview The workflow automatically gathers weekly user and page view metrics. It then uses AI to analyze, compare, and compile a summary report. Finally, it sends the report to the manager's email. How it works Get Data from GA Automatically retrieve data from Google Analytics (GA) for the two most recent weeks. Compare the data and calculate the variances between the two weeks. Generate Report Automatically analyze the data and generate reports using Artificial Intelligence (AI). Generate charts to visualize the data. Export the report to PDF. Send Report Send the report via email to the manager. Set up steps Google cloud account Create the credentials and replace them in the workflow. Please enable the following APIs: Gmail API Google Analytics Admin API Google Analytics Data API HTML to PDF account You need to install node HTML to PDF. Get API key and replace in the workflow.
by franck fambou
⚠️ IMPORTANT: This template requires self-hosted n8n hosting due to the use of community nodes (MCP tools). It will not work on n8n Cloud. Make sure you have access to a self-hosted n8n instance before using this template. Overview This workflow automation allows a Google Gemini-powered AI Agent to orchestrate multi-source web intelligence using MCP (Model Context Protocol) tools such as Firecrawl, Brave Search, and Apify. The system allows users to interact with the agent in natural language, which then leverages various external data collection tools, processes the results, and automatically organizes them into structured spreadsheets. With built-in memory, flexible tool execution, and conversational capabilities, this workflow acts as a multi-agent research assistant, capable of retrieving, synthesizing, and delivering actionable insights in real time. How the system works AI Agent + MCP Pipeline User Interaction A chat message is received and forwarded to the AI Agent. AI Orchestration The agent, powered by Google Gemini, decides which MCP tools to invoke based on the query. Firecrawl-MCP: Recursive web crawling and content extraction. Brave-MCP: Real-time web search with structured results. Apify-MCP: Automation of web scraping tasks with scalable execution. Memory Management A memory module stores context across conversations, ensuring multi-turn reasoning and task continuity. Spreadsheet automation Results are structured in a new, automatically created Google Spreadsheet, enriched with formatting and additional metadata. Data processing The workflow generates the spreadsheet content, updates the sheet, and improves results via HTTP requests and field edits. Delivery of results Users receive a structured and contextualized dataset ready for review, analysis, or integration into other systems. Configuration instructions Estimated setup time: 45 minutes Prerequisites Self-hosted n8n instance (v0.200.0 or higher recommended) Google Gemini API key MCP-compatible nodes (Firecrawl, Brave, Apify) configured Google Sheets credentials for spreadsheet automation Detailed configuration steps Step 1: Configuring the AI Agent AI Agent node**: Select Google Gemini as the LLM model Configure your Google Gemini API key in the n8n credentials Set the system prompt to guide the agent's behavior Connect the Simple Memory node to enable context tracking Step 2: Integrating MCP Tools Firecrawl-MCP Configuration**: Install the @n8n/n8n-nodes-firecrawl-mcp package Configure your Firecrawl API key Set crawling parameters (depth, CSS selectors) Brave-MCP configuration**: Install the @n8n/n8n-nodes-brave-mcp package Add your Brave Search API key Configure search filters (region, language, SafeSearch) Apify-MCP configuration**: Install the @n8n/n8n-nodes-apify-mcp package Configure your Apify credentials Select the appropriate actors for your use cases Step 3: Spreadsheet automation “Create Spreadsheet” node**: Configure Google Sheets authentication (OAuth2 or Service Account) Set the file name with dynamic timestamps Specify the destination folder in Google Drive “Generate Spreadsheet Content” node**: Transform the agent's outputs into tabular format Define the columns: URL, Title, Description, Source, Timestamp Configure data formatting (dates, links, metadata) “Update Spreadsheet” node**: Insert the data into the created sheet Apply automatic formatting (headers, colors, column widths) Add summary formulas if necessary Step 4: Post-processing and delivery “Data Enrichment Request” node** (formerly “HTTP Request1”): Configure optional API calls to enrich the data Add additional metadata (geolocation, sentiment, categorization) Manage errors and timeouts “Edit Fields” node**: Refine the final dataset (metadata, tags, filters) Clean and normalize the data Prepare the final response for the user Structure of generated Google Sheets Default columns | Column | Description | Type | |---------|-------------|------| | URL | Data source URL | Hyperlink | | Title | Page/resource title | Text | | Description | Description or content excerpt | Long text | | Source | MCP tool used (Brave/Firecrawl/Apify) | Text | | Timestamp | Date/time of collection | Date/Time | | Metadata | Additional data (JSON) | Text | Automatic formatting Headings**: Bold font, colored background URLs**: Formatted as clickable links Dates**: Standardized ISO 8601 format Columns**: Width automatically adjusted to content Use cases Business and enterprise Competitive analysis combining search, crawling, and structured scraping Market trend research with multi-source aggregation Automated reporting pipelines for business intelligence Research and academia Literature discovery across multiple sources Data collection for research projects Automated bibliographic extraction from online sources Engineering and development Discovery of APIs and documentation Aggregation of product information from multiple platforms Scalable structured scraping for datasets Personal productivity Automated creation of newsletters or knowledge hubs Personal research assistant compiling spreadsheets from various online data Key features Multi-source intelligence Firecrawl for deep crawling Brave for real-time search Apify for structured web scraping AI-driven orchestration Google Gemini for reasoning and tool selection Memory for multi-turn interactions Context-based adaptive workflows Structured data output Automatic spreadsheet creation Data enrichment and formatting Ready-to-use datasets for reporting Performance and scalability Handles multiple simultaneous tool calls Scalable web data extraction Real-time aggregation from multiple MCPs Security and privacy Secure authentication based on API keys Data managed in Google Sheets / n8n Configurable retention and deletion policies Technical architecture Workflow User query → AI agent (Gemini) → MCP tools (Firecrawl / Brave / Apify) → Aggregated results → Spreadsheet creation → Data processing → Results delivery Supported data types Text and metadata** from crawled web pages Search results** from Brave queries Structured data** from Apify scrapers Tabular reports** via Google Sheets Integration options Chat interfaces Web widget for conversational queries Slack/Teams chatbot integration REST API access points Data sources Websites (via Firecrawl/Apify) Search engines (via Brave) APIs (via HTTP Request enrichment) Performance specifications Query response: < 5 seconds (search tasks) Crawl capacity: Thousands of pages per run Spreadsheet automation: Real-time creation and updates Accuracy: > 90% when using combined sources Advanced configuration options Customization Set custom prompts for the AI Agent Adjust the spreadsheet schema for reporting needs Configure retries for failed tool runs Analytics and monitoring Track tool usage and costs Monitor crawl and search success rates Log queries and outputs for auditing Troubleshooting and support Timeouts:** Manually re-run failed MCP executions Data gaps:** Validate Firecrawl/Apify selectors Spreadsheet errors:** Check Google Sheets API quotas
by Rahul Joshi
Description Automate Jira backlog management with intelligent cleanup, prioritization, and AI-powered reporting. This workflow scans daily to identify stale issues, missing priorities, and overdue tasks — auto-updates Jira with corrective labels, logs everything into Google Sheets for tracking, and notifies teams via Slack. Every Friday, it sends an AI-generated backlog summary email to project leads for visibility and planning. 🚀📅 What This Template Does Step 1: Triggers automatically every weekday at 7:00 AM to fetch backlog issues from Jira. ⏰ Step 2: Filters issues missing estimates, assignees, or priority values for cleanup. 🧹 Step 3: Applies corrective labels (e.g., “Needs Estimation,” “Unassigned,” “Overdue”). 🏷️ Step 4: Logs all flagged issues into Google Sheets with timestamps for audit tracking. 📊 Step 5: Sends real-time Slack alerts summarizing key backlog insights. 💬 Step 6: Every Friday, uses GPT-4 to generate a summarized backlog health report. 🤖 Step 7: Delivers weekly summary emails to leads and project managers via Gmail. 📧 Key Benefits ✅ Eliminates manual backlog reviews and prioritization. ✅ Ensures consistent Jira hygiene and task visibility. ✅ Provides centralized backlog tracking via Google Sheets. ✅ Sends real-time alerts for overdue and unassigned tasks. ✅ Offers AI-driven insights for better sprint planning. Features Automated daily trigger (Mon–Fri, 7 AM) Jira issue fetching and filtering by priority and assignment Smart labeling for hygiene tracking Slack alerts for backlog anomalies Weekly GPT-4 generated summary reporting Google Sheets integration for historical logging Gmail integration for summary email delivery Requirements Jira API credentials with read/write issue permissions Google Sheets OAuth2 credentials for data logging Slack Bot token with chat:write permissions Gmail OAuth2 credentials for email delivery OpenAI or Azure OpenAI API key for GPT-4 summarization Target Audience Agile and Scrum teams maintaining large backlogs 🧩 Product managers ensuring backlog quality and consistency 📋 Engineering leads seeking proactive backlog hygiene 🛠️ Organizations needing visibility across project tasks 🏢 Remote teams using Slack for daily syncs 🌐 Step-by-Step Setup Instructions Connect Jira credentials and specify your project key(s). 🔑 Link your Google Sheet and replace YOUR_SHEET_ID for backlog tracking. 📊 Configure Slack and replace YOUR_CHANNEL_ID for alert delivery. 💬 Add Gmail credentials and define recipient emails for weekly reports. 📧 Add your GPT-4 API key (OpenAI or Azure) for AI summarization. 🤖 Adjust cron expression (0 7 * * 1-5) to match your local timezone. ⏰ Run manually once to validate all connections, then enable automation. ✅