by Rahul Joshi
π Description Ensure your GitHub repositories stay configuration-accurate and documentation-compliant with this intelligent AI-powered validation workflow. π€ This automation monitors repository updates, compares configuration files against documentation references, detects inconsistencies, and alerts your team instantlyβstreamlining DevOps and compliance reviews. β‘ What This Template Does Step 1: Triggers automatically on GitHub push or pull_request events. π Step 2: Fetches both configuration files (config/app-config.json and faq-config.json) from the repository. π Step 3: Uses GPT-4o-mini to compare configurations and detect mismatches, missing keys, or deprecated fields. π§ Step 4: Categorizes issues by severityβcritical, high, medium, or lowβand generates actionable recommendations. π¨ Step 5: Logs all discrepancies to Google Sheets for tracking and audit purposes. π Step 6: Sends Slack alerts summarizing key issues and linking to the full report. π¬ Key Benefits β Prevents production incidents due to config drift β Ensures documentation stays in sync with code changes β Reduces manual review effort with AI-driven validation β Improves team response with Slack-based alerts β Maintains audit logs for compliance and traceability Features Real-time GitHub webhook integration AI-powered config comparison using GPT-4o-mini Severity-based issue classification Automated Google Sheets logging Slack alerts with detailed issue context Error handling for malformed JSON or parsing issues Requirements GitHub OAuth2 credentials with repo and webhook permissions OpenAI API key (GPT-4o-mini or compatible model) Google Sheets OAuth2 credentials Slack API token with chat:write permissions Target Audience DevOps teams ensuring consistent configuration across environments Engineering leads maintaining documentation accuracy QA and Compliance teams tracking configuration changes and risks Setup Instructions Create GitHub OAuth2 credentials and enable webhook access. Connect your OpenAI API key under credentials. Add your Google Sheets and Slack integrations. Update file paths (config/app-config.json and faq-config.json) if your repo uses different names. Activate the workflow β it will start validating on every push or PR. π
by WeblineIndia
Quick Overview This workflow runs daily to fetch invoice data from an HTTP endpoint, calculate early-payment savings and annualized ROI, and use Groq (Llama 3.3) to prioritize eligible discounts. It logs eligible and expired invoices to Google Sheets and emails a digest of HIGH-priority recommendations via Gmail. How it works Runs every day at 9:00 to start an invoice scan. Fetches invoice records from an external HTTP API endpoint. Calculates potential savings, days saved by paying early, annualized ROI, and whether each invoice is still eligible before the discount deadline. Routes eligible invoices to Groq (Llama 3.3) to return a JSON decision with a YES/NO recommendation, HIGH/MEDIUM/LOW priority, and a short reason, then normalizes the AI response. Appends eligible invoice evaluations (including ROI, savings, priority, recommendation, and reason) to a Google Sheets log. Filters for invoices marked YES and HIGH priority, aggregates them into a daily batch, and emails a plain-text digest to the finance team via Gmail. Marks ineligible invoices as expired with a skip reason and appends them to a separate Google Sheets audit log. Setup Add a Groq API credential and ensure the selected Groq model is available in your account. Add Google Sheets OAuth2 credentials and update the spreadsheet ID, sheet tabs, and column headers to match your logging sheets. Add Gmail OAuth2 credentials and set the target recipient(s) for the finance summary email. Update the invoice API URL to your real invoice source and ensure each record includes amount, discount_percent, discount_deadline, payment_due, vendor, and vendor_email fields. Adjust the available cash amount and the ROI/cash threshold rules in the prompt and/or data preparation step to match your finance policy.
by Muhammad Ali
Description How it works This powerful workflow helps businesses and freelancers automatically manage invoices received on WhatsApp. It detects new messages, downloads attached invoices, extracts key data using OCR (Optical Character Recognition), summarizes the details with AI, updates Google Sheets for record-keeping, saves files to Google Drive, and instantly replies with a clean summary message all without manual effort. Perfect for small businesses, agencies, accountants, and freelancers who regularly receive invoices via WhatsApp. Say goodbye to manual data entry and hello to effortless automation. Set up steps Setup takes around 10β15 minutes: Connect your WhatsApp Cloud API to trigger incoming messages. Add your OCR.Space API key to extract invoice text. Link your Google Sheets and Google Drive accounts for data logging and storage. Enter your OpenAI API key for AI-based summarization. Import the template, test once, and youβre ready to automate your invoice workflow. Why use this workflow Save hours of manual data entry Keep all invoices safely stored and organized in Drive Get instant summaries directly in WhatsApp Improve efficiency for client billing, and expense tracking.
by Jay Emp0
Automatically turns trending Reddit posts into punchy, first-person tweets powered by Google Gemini AI, Reddit, and Twitter API, with Google Sheets logging. π§© Overview This workflow repurposes Reddit content into original tweets every few hours. Itβs perfect for creators, marketers, or founders who want to automate content inspiration while keeping tweets sounding human, edgy, and fresh. Core automation loop: Fetch trending Reddit posts from selected subreddits. Use Gemini AI to write a short, first-person tweet. Check your Google Sheet to avoid reusing the same Reddit post. Publish to Twitter automatically. Log tweet + Reddit reference in Google Sheets. π§ Workflow Diagram πͺ How It Works 1οΈβ£ Every 2 hours β the workflow triggers automatically. 2οΈβ£ It picks a subreddit (like r/automation, r/n8n, r/SaaS). 3οΈβ£ Gemini AI analyzes a rising Reddit post and writes a fresh, short tweet. 4οΈβ£ The system checks your Google Sheet to ensure it hasnβt used that Reddit post before. 5οΈβ£ Once validated, the tweet is published via Twitter API and logged. π§ Example Tweet Output π Logged Data (Google Sheets) Each tweet is automatically logged for version control and duplication checks. | Date | Subreddit | Post ID | Tweet Text | |------|------------|----------|-------------| | 08/10/2025 | n8n_ai_agents | 1o16ome | Just saw a wild n8n workflow on Reddit... | βοΈ Key Components | Node | Function | |------|-----------| | Schedule Trigger | Runs every 2 hours to generate a new tweet. | | Code (Randomly Decide Subreddit) | Picks one subreddit randomly from your preset list. | | Gemini Chat Model | Generates tweet text in first person tone using custom prompt rules. | | Reddit Tool | Fetches top or rising posts from the chosen subreddit. | | Google Sheets (read database) | Keeps a record of already-used Reddit posts. | | Structured Output Parser | Ensures consistent tweet formatting (tweet text, subreddit, post ID). | | Twitter Node | Publishes the AI-generated tweet. | | Append Row in Sheet | Logs the tweet with date, subreddit, and post ID. | π§© Setup Tutorial 1οΈβ£ Prerequisites | Tool | Purpose | |------|----------| | n8n Cloud or Self-Host | Workflow execution | | Google Gemini API Key | For tweet generation | | Reddit OAuth2 API | To fetch posts | | Twitter (X) API OAuth2 | To publish tweets | | Google Sheets API | For logging and duplication tracking | 2οΈβ£ Import the Workflow Download Reddit Twitter Automation.json. In n8n, click Import Workflow β From File. Connect your credentials: Gemini β Gemini Reddit β Reddit account Twitter β X Google Sheets β Gsheet 3οΈβ£ Configure Google Sheet Your sheet must include these columns: | Column | Description | |--------|--------------| | PAST TWEETS | The tweet text | | Date | Auto-generated date | | subreddit | Reddit source | | post_id | Reddit post reference | 4οΈβ£ Customize Subreddits In the Code Node, update this array to choose which subreddits to monitor: const subreddits = [ "n8n", "microsaas", "SaaS", "automation", "n8n_ai_agents" ];
by Roshan Ramani
π Smart Telegram Shopping Assistant with AI Product Recommendations Workflow Overview Target User Role: E-commerce Business Owners, Affiliate Marketers, Customer Support Teams Problem Solved: Businesses need an automated way to help customers find products on Telegram without manual intervention, while providing intelligent recommendations that increase conversion rates. Opportunity Created: Transform any Telegram channel into a smart shopping assistant that can handle both product queries and customer conversations automatically. What This Workflow Does This workflow creates an intelligent Telegram bot that: π€ Automatically detects** whether users are asking about products or just chatting π Scrapes Amazon** in real-time to find the best matching products π― Uses AI to analyze and rank** products based on price, ratings, and user needs π± Delivers perfectly formatted** recommendations optimized for Telegram π¬ Handles casual conversations** professionally when users aren't shopping Real-World Use Cases E-commerce Support**: Reduce customer service workload by 70% Affiliate Marketing**: Automatically recommend products with tracking links Telegram Communities**: Add shopping capabilities to existing channels Product Discovery**: Help customers find products they didn't know existed Key Features & Benefits π§ Intelligent Intent Detection Uses Google Gemini AI to understand user messages Automatically routes to product search or conversation mode Handles multiple languages and casual typing styles π Real-Time Product Data Integrates with Apify's Amazon scraper for live data Fetches prices, ratings, reviews, and product details Processes up to 10 products per search instantly π― AI-Powered Recommendations Analyzes multiple products simultaneously Ranks by relevance, value, and user satisfaction Provides top 5 personalized recommendations with reasoning π± Telegram-Optimized Output Perfect formatting with emojis and markdown Respects character limits for mobile viewing Includes direct purchase links for easy buying Setup Requirements Required Credentials Telegram Bot Token - Free from @BotFather Google Gemini API Key - Free tier available at AI Studio Apify API Token - Free tier includes 100 requests/month Required n8n Nodes @n8n/n8n-nodes-langchain (for AI functionality) Built-in Telegram, HTTP Request, and Code nodes Quick Setup Guide Step 1: Telegram Bot Creation Message @BotFather on Telegram Create new bot with /newbot command Copy the bot token to your credentials Step 2: AI Configuration Sign up for Google AI Studio Generate API key for Gemini Add credentials to all three AI model nodes Step 3: Product Scraping Setup Register for free Apify account Get API token from dashboard Add token to "Amazon Product Scraper" node Step 4: Activation Import workflow JSON Add your credentials Activate the Telegram Trigger Test with a product query! Workflow Architecture π± Message Entry Point Telegram Trigger receives all messages π§Ή Query Preprocessing Cleans and normalizes user input for better search results π€ AI Intent Classification Determines if message is product-related or conversational π Smart Routing Directs to appropriate workflow path based on intent π¬ Conversation Path Handles greetings, questions, and general support π Product Search Path Scrapes Amazon β Processes data β AI analysis β Recommendations π€ Optimized Delivery Formats and sends responses back to Telegram Customization Opportunities Easy Modifications Multiple Marketplaces**: Add eBay, Flipkart, or local stores Product Categories**: Specialize for electronics, fashion, etc. Language Support**: Translate for different markets Branding**: Customize responses with your brand voice Advanced Extensions Price Monitoring**: Set up alerts for price drops User Preferences**: Remember customer preferences Analytics Dashboard**: Track popular products and queries Affiliate Integration**: Add commission tracking links Success Metrics & ROI Performance Benchmarks Response Time**: 3-5 seconds for product queries Accuracy**: 90%+ relevant product matches User Satisfaction**: 85%+ positive feedback in testing Business Impact Reduced Support Costs**: Automate 70% of product inquiries Increased Conversions**: Personalized recommendations boost sales 24/7 Availability**: Never miss a customer inquiry Scalability**: Handle unlimited concurrent users Workflow Complexity Intermediate Level - Requires API setup but includes detailed instructions. Perfect for users with basic n8n experience who want to create something powerful.
by Rahul Joshi
Automatically detect, classify, and document GitHub API errors using AI. This workflow connects GitHub, OpenAI (GPT-4o), Airtable, Notion, and Slack to build a real-time, searchable API error knowledge base β helping engineering and support teams respond faster, stay aligned, and maintain clean documentation. βοΈππ¬ π What This Template Does 1οΈβ£ Triggers on new or updated GitHub issues (API-related). πͺ 2οΈβ£ Extracts key fields (title, body, repo, and link). π 3οΈβ£ Classifies issues using OpenAI GPT-4o, identifying error type, category, root cause, and severity. π€ 4οΈβ£ Validates & parses AI output into structured JSON format. β 5οΈβ£ Creates or updates organized FAQ-style entries in Airtable for quick lookup. ποΈ 6οΈβ£ Logs detailed entries into Notion, maintaining an ongoing issue knowledge base. π 7οΈβ£ Notifies the right Slack team channel (DevOps, Backend, API, Support) with concise summaries. π¬ 8οΈβ£ Tracks & prevents duplicates, keeping your error catalog clean and auditable. π π‘ Key Benefits β Converts unstructured GitHub issues into AI-analyzed documentation β Centralizes API error intelligence across teams β Reduces time-to-resolution for recurring issues β Maintains synchronized records in Airtable & Notion β Keeps DevOps and Support instantly informed through Slack alerts β Fully automated, scalable, and low-cost using GPT-4o βοΈ Features Real-time GitHub trigger for API or backend issues GPT-4o-based AI classification (error type, cause, severity, confidence) Smart duplicate prevention logic Bi-directional sync to Airtable + Notion Slack alerts with contextual AI insights Modular design β easy to extend with Jira, Teams, or email integrations π§° Requirements GitHub OAuth2 credentials OpenAI API key (GPT-4o recommended) Airtable Base & Table IDs (with fields like Error Code, Category, Severity, Root Cause) Notion integration with database access Slack Bot token with chat:write scope π₯ Target Audience Engineering & DevOps teams managing APIs Customer support & SRE teams maintaining FAQs Product managers tracking recurring API issues SaaS orgs automating documentation & error visibility πͺ Step-by-Step Setup Instructions 1οΈβ£ Connect your GitHub account and enable the βissuesβ webhook event. 2οΈβ£ Add OpenAI credentials (GPT-4o model for classification). 3οΈβ£ Create an Airtable base with fields: Error Code, Category, Root Cause, Severity, Confidence. 4οΈβ£ Configure your Notion database with matching schema and access. 5οΈβ£ Set up Slack credentials and choose your alert channels. 6οΈβ£ Test with a sample GitHub issue to validate AI classification. 7οΈβ£ Enable the workflow β enjoy continuous AI-powered issue documentation!
by Avkash Kakdiya
How it works This workflow runs daily to review all active deals and evaluate their likelihood of closing successfully. It enriches deal data with recent engagement activity and applies AI-based behavioral scoring to predict conversion probability. High-risk or stalled deals are flagged automatically. Actionable alerts are sent to the sales team, and all analysis is logged for forecasting and tracking. Step-by-step Trigger and fetch deals** Schedule Trigger β Runs the workflow automatically at a fixed time each day. Get Active Deals from HubSpot β Retrieves all open, non-closed deals with key properties. Formatting Data β Normalizes deal fields such as value, stage, age, contacts, and activity dates. Enrich deals with engagement data** If β Filters only active deals for further processing. Loop Over Items β Processes each deal individually. HTTP Request β Fetches engagement associations for the current deal. Get an engagement β Retrieves detailed engagement records from HubSpot. Extracts Data β Structures engagement content, timestamps, and metadata for analysis. Analyze risk, alert, and store results** OpenAI Chat Model β Provides the language model used for analysis. AI Agent β Evaluates behavioral signals, predicts conversion probability, and recommends actions. Format Data β Parses AI output into structured, machine-readable fields. Filter Alerts Needed β Identifies deals that need immediate attention. Send Slack Alert β Sends detailed alerts for high-risk or stalled deals. Append or update row in sheet β Logs analysis results into Google Sheets for reporting. Why use this? Automatically identify high-risk deals before they stall or fail Give sales teams clear, data-driven next actions instead of raw CRM data Improve forecasting accuracy with AI-powered probability scoring Maintain a historical deal health log for audits and performance reviews Reduce manual pipeline reviews while increasing response speed
by Oneclick AI Squad
Quick Overview This workflow receives monitoring alerts via a webhook, logs an incident in ClickUp, uses Anthropic Claude to perform root-cause analysis, and either triggers a Cursor background agent to implement and deploy a fix or escalates to on-call, then updates ClickUp and notifies via WhatsApp. How it works Receives a POST webhook alert from your monitoring system and extracts service, severity, and an error signature for tracking. Deduplicates recurring alerts using stored execution state, scores severity, and determines whether the service is eligible for unsupervised remediation. Creates an incident task in ClickUp with the normalized alert details and waits briefly to debounce flapping alerts. Sends the incident context to Anthropic Claude to generate a structured root-cause analysis including confidence, risk level, and fix instructions. Approves auto-remediation only when the service is allowlisted and the analysis meets confidence and risk thresholds, otherwise prepares an escalation report. If approved, waits for a short safety window, triggers a Cursor background agent to open a PR and run tests (and auto-merge/deploy when configured), then evaluates the outcome after a grace period. Updates the ClickUp incident with the resolution status and sends the final result (auto-resolved or escalated) to the on-call recipient via WhatsApp. Setup Create credentials for ClickUp, Anthropic (HTTP header auth), Cursor (HTTP header auth), and WhatsApp Business Cloud, then connect them to the respective nodes. Set your ClickUp List ID in the incident creation node and ensure the update step can reference the created task ID. Replace placeholders for WhatsApp Phone Number ID and the on-call recipient number in the WhatsApp node. Update the Cursor repository mapping (the workflow uses org/) and tune the auto-remediation allowlist and gating thresholds in the code steps. Copy the webhook URL for the monitoring alert trigger and configure it in your monitoring toolβs alert notification settings.
by WeblineIndia
Data Quality Checker This workflow automatically monitors pricing data in Google Sheets, detects anomalies such as missing values or sudden spikes/drops, generates AI-based short explanations for flagged rows, updates the sheet with status and reason and sends Slack alerts for critical issues. Quick Implementation Steps: Prepare your Google Sheet with columns: price, previous_price, status, reason, row_number. Connect n8n with your Google Sheets, Slack and Groq AI credentials. Trigger the workflow manually or via webhook. Each row is processed to detect anomalies and generate a reason using AI. Flagged rows are updated in Google Sheets and a Slack alert is sent automatically. What It Does The Data Quality Checker workflow is designed to help you maintain accurate pricing data effortlessly. It fetches data from Google Sheets, evaluates each row for anomalies and ensures that unusual changes in prices do not go unnoticed. It automatically flags rows with missing values, sudden spikes or sudden drops in price. The workflow uses a Groq AI model to generate concise explanations for any anomalies found, providing actionable insights directly in your sheet. For rows without issues, it marks the status as OK with a standard reason. A Slack alert is sent for flagged data to keep teams informed in real-time, preventing unnoticed errors and enabling faster corrective actions. Who It's For Data analysts monitoring pricing or inventory data. E-commerce managers tracking product price fluctuations. Finance teams validating large datasets for inconsistencies. Operations teams needing automated anomaly detection with alerts. This workflow suits anyone who relies on timely, accurate data and wants automated anomaly detection and reporting. Requirements to Use This Workflow n8n account (cloud or self-hosted). Google Sheets account** with read/write access to the target sheet. Slack workspace** with a channel for alerts. Groq AI account** for anomaly explanation generation. Sheet structure: columns price, previous_price, status, reason, row_number. How It Works & Setup Guide Prepare Google Sheet Ensure your sheet has price, previous_price, status, reason, row_number. Populate initial pricing data. Connect Credentials in n8n Add Google Sheets OAuth2 for reading and updating the sheet. Add Slack API credentials to send alerts. Add Groq AI credentials for AI reasoning. Trigger the Workflow Use a manual trigger or configure a webhook to run automatically. Process Data The workflow fetches data from Google Sheets. SplitInBatches node ensures each row is processed individually. Check Price Issues node checks for missing values or sudden changes. Anomaly Handling If node determines whether an anomaly exists. For flagged rows, AI generates a short reason (Generate Issue Reason). Prepare Flag Data formats data for updating the sheet. Update & Alert Update Flagged Row writes flagged status and reason back to Google Sheets. Update Normal Row writes OK status for rows with no issues. Send Slack Alert sends real-time notifications for flagged anomalies. How To Customize Nodes Google Sheets nodes:** update documentId and sheetName to match your own sheets. Slack node:** change channelId and alert text to match your workspace and notification style. AI node:** adjust the prompt in Generate Issue Reason to change explanation style or length. Code node:** modify the logic in Check Price Issues to define what constitutes a spike or drop. Add-ons Connect to email notifications instead of Slack. Extend AI logic to suggest corrective actions. Include historical trend analysis in Google Sheets for better insights. Integrate with other data sources like CSV or databases. Use Case Examples E-commerce pricing validation: Automatically detect and explain unusual price changes for hundreds of products. Inventory data verification: Ensure stock values and price adjustments are accurate daily. Finance anomaly detection: Detect sudden cost or rate fluctuations in financial datasets. Market monitoring: Track competitor pricing changes with automated alerts. General data quality assurance: Any dataset requiring automated checks for missing or inconsistent values. This workflow is flexible and can be adapted to other types of tabular data beyond pricing. Troubleshooting Guide | Issue | Possible Cause | Solution | | ------------------------ | --------------------------------------- | --------------------------------------------------------- | | Workflow not triggering | Trigger node not active | Enable the manual or webhook trigger | | Data not fetched | Wrong documentId or sheetName | Verify Google Sheets node settings and credentials | | Slack alert not sent | Invalid channel ID or credentials | Update Slack credentials and ensure channel ID is correct | | AI reasoning fails | Groq API issues or prompt misconfigured | Check Groq AI credentials and review the prompt text | | Wrong anomaly detection | Code logic in Check Price Issues | Adjust thresholds or conditions in the code node | | Sheet updates not saving | Google Sheets permission issue | Ensure OAuth2 account has write access to the sheet | Need Help? If you face issues setting up this workflow, customizing nodes or integrating add-ons, our n8n automation team can help. We specialize in building and optimizing n8n workflows for automation, data quality and alerting. Contact us to implement this workflow, enhance it or create custom automation solutions tailored to your business needs.
by Trung Tran
Automated AWS IAM Compliance Workflow for MFA Enforcement and Access Key Deactivation > This workflow leverages AWS IAM APIs and n8n automation to ensure strict security compliance by continuously monitoring IAM users for MFA (Multi-Factor Authentication) enforcement. .jpg) Whoβs it for This workflow is designed for DevOps, Security, or Cloud Engineers responsible for maintaining IAM security compliance in AWS accounts. It's ideal for teams who want to enforce MFA usage and automatically disable access for non-compliant IAM users. How it works / What it does This automated workflow performs a daily check to detect IAM users without an MFA device and deactivate their access keys. Step-by-step: Daily scheduler: Triggers the workflow once a day. Get many users: Retrieves a list of all IAM users in the account. Get IAM User MFA Devices: Calls AWS API to get MFA device info for each user. Filter out IAM users with MFA: Keeps only users without any MFA device. Send warning message(s): Sends Slack alerts for users who do not have MFA enabled. Get User Access Key(s): Fetches access keys for each non-MFA user. Parse the list of user access key(s): Extracts and flattens key information like AccessKeyId, Status, and UserName. Filter out inactive keys: Keeps only active access keys for further action. Deactivate Access Key(s): Calls AWS API to deactivate each active key for non-MFA users. How to set up Configure AWS credentials in your environment (IAM role or AWS access key with required permissions). Connect Slack via the Slack node for alerting (set channel and credentials). Set the scheduler to your preferred frequency (e.g., daily at 9AM). Adjust any Slack message template or filtering conditions as needed. Requirements IAM user or role credentials with the following AWS IAM permissions: iam:ListUsers iam:ListMFADevices iam:ListAccessKeys iam:UpdateAccessKey Slack credentials (Bot token with chat:write permission). n8n environment with: Slack integration AWS credentials (set via environment or credentials manager) How to customize the workflow Alert threshold**: Instead of immediate deactivation, you can delay action (e.g., alert first, wait 24h, then disable). Change notification channel**: Modify the Slack node to send alerts to a different channel or add email integration. Whitelist exceptions**: Add a Set or IF node to exclude specific usernames (e.g., service accounts). Add audit logging**: Use Google Sheets, Airtable, or a database to log which users were flagged or had access disabled. Extend access checks**: Include console password check (GetLoginProfile) if needed.
by TakatoYamada
Analyze error logs with AI and auto-create GitHub issues with fix suggestions Who is this for DevOps engineers, SREs, and development teams who want to automate error monitoring and reduce mean time to resolution (MTTR). Ideal for teams using GitHub for issue tracking and Slack for incident response. What this workflow does This workflow automates the entire error management lifecycle - from log ingestion to GitHub issue creation and Slack notification - using GPT-4o-powered root cause analysis. When an application error log is received, it parses the payload, checks for duplicates against existing GitHub issues, generates a structured root cause analysis with fix suggestions, creates a formatted GitHub Issue, and routes Slack notifications by severity. A 30-minute Wait node prevents notification flooding. How to set up Add your GitHub Personal Access Token (repo scope) credential Add your OpenAI API credential to the AI analysis node Add your Slack OAuth2 credential (chat:write scope) to all Slack nodes Configure n8n Variables: GITHUB_OWNER and GITHUB_REPO Update Slack channel names (#incident / #dev-alerts) to match your workspace Activate the workflow and copy the webhook URL for your application logger Requirements GitHub repository with Personal Access Token (repo scope) OpenAI API account with GPT-4o access Slack workspace with OAuth2 app installed Two Slack channels: one for critical incidents, one for general dev alerts How to customize Adjust the duplicate detection score threshold (default 60) in the Code node. Modify the GPT-4o prompt to focus on specific error categories. The Wait node duration (30 minutes) can be tuned to match your alerting policy. Key features Scoring-based duplicate detection (no extra API calls required) GPT-4o structured JSON output with graceful fallback parser Severity-based Slack routing (#incident vs #dev-alerts) Dynamic GitHub labels: bug, auto-generated, environment, and critical n8n Variables used for GitHub owner and repo - no hardcoded values Node List | # | Node Name | Type | Purpose | |---|-----------|------|---------| | 1 | Webhook for Error Logs | Webhook | Accepts error log payload via HTTP POST | | 2 | Parse and Enrich Log | Code | Normalizes level, extracts error type, builds duplicate search keyword | | 3 | Search GitHub Issues | GitHub | Fetches open issues labeled bug,auto-generated from the target repo | | 4 | Score GitHub Issue Duplicates | Code | Scores each issue for similarity; flags duplicates at threshold β₯ 60 | | 5 | Check for Duplicates | If | Routes to skip path (true) or analysis path (false) | | 6 | Notify Duplicate to Slack | Slack | Posts link to existing issue when duplicate detected | | 7 | Respond with Duplicate Status | Respond to Webhook | Returns 200 OK JSON acknowledgment for duplicate path | | 8 | OpenAI Error Analysis | OpenAI | GPT-4o analyzes root cause and returns structured JSON fix suggestions | | 9 | Build GitHub Issue Body | Code | Parses AI JSON and builds Markdown issue body with tables and code blocks | | 10 | Create GitHub Issue | GitHub | Creates GitHub issue with title, body, and dynamic labels | | 11 | If Critical Error | If | Checks isCritical flag to route Slack notification channel | | 12 | Post Critical Alert to Slack | Slack | Posts @here alert to #incident with full error details | | 13 | Post Error Summary to Slack | Slack | Posts summary to #dev-alerts with GitHub issue link | | 14 | Wait 30 Minutes | Wait | Enforces 30-minute cooldown to prevent notification flooding | Total: 14 nodes (+ 6 Sticky Notes) Sticky Note Compliance | # | Sticky Note Title | Color | Role | |---|-------------------|-------|------| | 1 | Main Sticky Note (Overview) | Yellow | Workflow overview, How it works, Setup steps, Customization | | 2 | Receive and parse log | White | Covers webhook reception and log parsing | | 3 | Check for duplicate GitHub issues | White | Covers GitHub search and duplicate scoring | | 4 | Handle duplicates and notify | White | Covers duplicate branch (notification + webhook response) | | 5 | Analyze error and suggest fixes | White | Covers AI analysis and issue creation | | 6 | Send alerts and summarize | White | Covers severity check, Slack notifications, and wait | All sticky notes use H2 headings (## ) and follow n8n public guidelines. Webhook payload schema { "service": "payment-api", "level": "CRITICAL", "message": "NullPointerException at PaymentProcessor.java:142", "stack_trace": "java.lang.NullPointerException...", "environment": "production", "timestamp": "2025-01-15T09:23:45Z", "trace_id": "abc-123-xyz", "endpoint": "/api/v2/payments", "http_method": "POST", "status_code": 500, "user_id": "user_98765" } Required fields: service, level, message Optional fields: All others - missing values are handled gracefully with fallbacks. How duplicate detection works | Match condition | Points | |-----------------|--------| | Service name found in issue title | +40 | | Error type found in issue title | +40 | | Keyword overlap (words > 4 chars) | +5 per word (max +20) | Threshold: Score β₯ 60 β duplicate detected β skip issue creation, notify Slack. Tags ai gpt-4 openai github slack error-monitoring devops automation
by Avkash Kakdiya
How it works This workflow automatically detects at-risk customers by listening for inactivity signals from Mixpanel, scoring their churn risk, syncing everything to HubSpot, creating a prioritized ClickUp follow-up task, and alerting the customer success team on Slack β all without any manual effort. Step-by-step Trigger & parse** Mixpanel Webhook β Receives POST events from Mixpanel when a customer inactivity event is fired (e.g. user_inactive_30_days). Supports both single events and batch arrays. Parse Mixpanel Payload β Normalizes the raw Mixpanel payload, extracting email, name, user ID, company, plan, MRR, inactive days, last active date, last feature used, total sessions, location, and CSM assignment. Skips records with no identifying information. Event validation** Is Churn Event β Confirms the event name matches user_inactive_30_days, has no parse errors, and includes a valid email before proceeding. Risk scoring** Enrich User Data β Calculates churn score (Medium / High / Critical) and task priority based on inactive days, sets a due date of 24 hours and a follow-up date of 3 days, and builds the alert subject line with risk level. CRM lookup** HubSpot Find Contact β Searches HubSpot for an existing contact by email, retrieving name, company, lifecycle stage, owner, lead status, and phone. Contact Found β Routes to the full retention flow if a contact exists, or to a Slack fallback alert if no contact is found. Slack Contact Not Found β Posts a Slack warning to the team for manual action when no HubSpot contact matches the churn event email. Deal management** HubSpot Get Deals β Fetches all deals associated with the found HubSpot contact via the CRM Associations API. Deal Exists β Routes to update the existing deal or create a new one based on whether an associated deal is found. HubSpot Update Deal β Updates the existing deal stage to appointmentscheduled and sets the close date to the follow-up date. HubSpot Create Deal β Creates a new churn risk deal linked to the contact, with annual value (MRR Γ 12), deal name, and follow-up close date. Set Deal ID β Normalizes the deal ID from either the update or create branch for consistent downstream use. CRM logging & task creation** HubSpot Log Note β Posts a detailed churn risk note on the HubSpot contact record linked to both the contact and the deal, including all churn signals and MRR data. ClickUp Create Task β Creates a prioritized CS follow-up task with a full action checklist covering outreach, Mixpanel review, discovery call scheduling, and escalation criteria. Due within 24 hours. Slack CS Alert β Posts a comprehensive churn risk alert to the CS Slack channel with customer details, revenue impact, churn signals, risk score, HubSpot links, and a full action checklist. Why use this? Automatically catches every at-risk customer the moment Mixpanel detects inactivity β no manual monitoring needed Three-tier risk scoring (Medium / High / Critical) ensures the CS team prioritizes the highest-value accounts first Keeps HubSpot fully in sync by creating or updating deals and logging churn risk notes directly on the contact record Auto-creates ClickUp tasks with a structured action checklist so every churn risk has an owner and a deadline Alerts the team instantly on Slack with full context β revenue, signals, CRM links, and next steps β so they can act within hours