Bulk emails with personalized attachment
A workflow to send personalized emails with respective attachment. The workflow needs a pre-formatted CSV with file names and email IDs.
Xml to SQL database import
This is an example workflow that imports an XML file into an SQL database. The ReadBinaryFiles node loads the XML file from the server. Then the Code node extracts the file content from the binary buffer. Afterwards, an XML node converts the XML string into a JSON structure. Finally, in the MySQL node inserts the data records into the SQL table. In the upper part of the workflow there is another MySQL node that is disabled. This node creates a new table with all the required variables based on the sample SQL database: https://www.mysqltutorial.org/mysql-sample-database.aspx
Query MySQL database with natural language using GPT AI
This workflow contains community nodes that are only compatible with the self-hosted version of n8n. How it works Using chat node, ask a question pertaining to information stored in your MySQL database AI Agent converts your question to a SQL query AI Agent executes the SQL query and returns a result AI Agent can remember the previous 5 questions How to set up: Add your OpenAI API Key in "OpenAI Chat Model" node Add your MySQL credentials in the "SQL DB - List Tables and Schema" and "Execute a SQL Query in MySQL nodes" Update the database name in "SQL DB - List Tables and Schema" node. Replace "yourqueryname" under the Query field with your actual database name After the above steps are completed, use the "When chat message received" node to ask a question about your data using plain English
Automate sales order prioritization with ERP-WMS-TMS integration based on SLA tiers
This n8n workflow automates the prioritization and scheduling of sales orders based on customer SLAs, urgency, and profitability. It ensures that high-priority and SLA-critical orders are picked, packed, and dispatched first—improving fulfillment speed, customer satisfaction, and operational efficiency across warehouses and logistics. --- Key Features Automated Order Fetching: Periodically retrieves all pending or confirmed sales orders from ERP systems. Dynamic SLA-Based Prioritization: Calculates order priority scores using urgency, customer tier, order value, and profit margin. Intelligent SLA Monitoring: Identifies SLA breaches and automatically flags them for immediate handling. Automated Task Creation: Generates urgent picking tasks and alerts warehouse managers in real-time. Smart Scheduling: Optimizes picking and dispatch timelines based on urgency and capacity. Seamless ERP & TMS Integration: Updates order statuses and schedules dispatches automatically. Operational Transparency: Sends end-of-cycle summary reports via email to operations teams. --- Workflow Process Schedule Trigger Runs every 15 minutes to ensure orders are frequently evaluated. Maintains real-time responsiveness without overloading systems. Fetch Pending Orders Retrieves all orders in pending or confirmed state from ERP API. Configurable limit (e.g., 100 orders per run) for controlled processing. Fetch Customer SLA Data Collects SLA tiers, delivery timeframes, and customer-specific priorities from ERP or CRM API. Supports dynamic customer segmentation (Gold, Silver, Bronze tiers). Calculate Priority Scores Assigns weighted priority scores based on multiple criteria: Urgency: 40% Tier: 30% Order Value: 20% Profit Margin: 10% Produces a composite score used for sorting and scheduling. Check if SLA Critical Detects if any order is close to or past SLA deadlines. Routes SLA-breached orders for immediate escalation. Create Urgent Picking Task Generates warehouse picking tasks for critical orders. Assigns to senior pickers or rapid response teams. Alert Warehouse Manager Sends instant SMS and email alerts for SLA-critical or high-priority orders. Ensures immediate managerial attention. Batch Normal Orders Groups non-critical orders into batches of 10 for optimized processing. Reduces load on WMS while maintaining steady throughput. Generate Picking Schedule Creates smart picking schedules based on urgency: High Priority: Same-day Normal: Within 1 day Low: Within 2–3 days Create Bulk Picking Tasks Pushes picking tasks into WMS (Warehouse Management System). Uses auto-assignment and route optimization logic. Generate Dispatch Schedule Builds dispatch timelines according to delivery method: Express, Priority, or Standard. Syncs with transport capacity data. Schedule Dispatches in TMS Sends dispatch requests to TMS (Transport Management System). Books carriers and reserves capacity for each batch. Update Order Statuses Updates ERP with new order statuses, schedules, and expected delivery dates. Maintains a unified view across systems. Generate Summary Report Creates a summary JSON report including: Total orders processed SLA-critical cases Dispatch breakdowns Next deadlines Send Summary Notification Emails the operations team with execution summary and performance metrics. Ensures team alignment and SLA visibility. --- Industries That Benefit This automation is especially valuable for: E-commerce & Retail: To prioritize same-day or express deliveries for VIP customers. Logistics & 3PL Providers: For meeting tight SLAs across multiple clients and delivery tiers. Manufacturing & B2B Distribution: Ensures high-value or contractual orders are prioritized. Pharma & Healthcare: Critical for time-sensitive and compliance-driven deliveries. Consumer Goods & FMCG: Helps manage high-volume dispatch with smart scheduling. --- Prerequisites ERP system with API access (e.g., SAP, Odoo, NetSuite). WMS and TMS integrations with order/task APIs. SMTP and SMS gateway credentials for notifications. n8n instance with HTTP, Function, Email, and Scheduler nodes installed. --- Modification Options Customize priority scoring weights per business type. Integrate AI for predictive SLA breach forecasting. Add Slack/Teams channels for real-time operational alerts. Implement escalation routing for unassigned urgent tasks. Extend reports to include OTIF (On-Time-In-Full) metrics. --- Explore More AI-Powered Workflows: Contact us for customized supply chain and order management automation.
Cross-platform content publisher: Telegram to WordPress, Facebook, X & LinkedIn
==Reason Of The Workflow== This n8n workflow automatically shares content from a Telegram Channel to multiple platforms like WordPress, Facebook, X/Twitter, and LinkedIn. It uses a Switch node to detect the type of content—text, image, video, audio, or document—and sends it to the right processing and publishing nodes for each platform. Who Is This For? This workflow is ideal for content creators, marketers, and organizations who use a Telegram Channel as their main content hub. It eliminates the need for manual, repetitive posting across different social media and blogging platforms by instantly detecting new posts in Telegram and distributing them according to their content type. What This Workflow Does The SocialVibe workflow is a sophisticated automation designed to handle diverse media types and publishing requirements: Real-Time Triggering: It instantly activates upon the detection of a new message (channel_post event) in your configured Telegram Channel. Intelligent Content Detection: It uses a Switch node and a Code node to analyze the Telegram payload and correctly identify the type of content posted (e.g., plain text, image, video, audio, or document). Platform-Specific Publishing: It tailors the publishing action for each platform, ensuring images go to the WordPress media library, text becomes a Tweet, etc. Caption-as-Text: The Telegram post's caption is automatically used as the post body, Tweet text, or blog post content/excerpt. Key Features Versatile Media Support: Handles over 9 different content types (Text, Photo, Video, Audio, Document, etc.). Dedicated WordPress Integration: Creates a new post/article. Uses an Edit Imageautomatically resize images to optimize for web upload. Uploads the image to the WordPress Media Library via HTTP Request. Sets the uploaded image as the post's Featured Image. Broad Social Media Reach: Supports cross-posting to X/Twitter, Facebook Page, LinkedIn Profile, and LinkedIn Page. Customizable Settings: Easily adjust WordPress categories, post status, and platform-specific settings like LinkedIn target IDs. Required Credentials & Accounts Telegram Bot Token: The bot must be an administrator in the source channel. WordPress API Credentials: For REST API access (username/password or application password). Facebook Graph API Credentials: With permissions to post to the target Page. LinkedIn OAuth2 Credentials: To post on a Profile and/or Company Page. Twitter/X OAuth2 Credentials: For publishing tweets. How to Use — Step-by-Step Setup Set Up All Credentials: Configure all necessary API credentials (Telegram, WordPress, Facebook, LinkedIn, Twitter) within your n8n instance. Configure Telegram Trigger: Ensure the Telegram Trigger node is set to listen for the channel_post update type. Customize WordPress Nodes: Update the Create WordPress Post node with your desired Category ID (currently set to 1) and ensure the Status is set to publish (or draft for safety testing). In the HTTP Request nodes (used for WordPress media upload), replace the placeholder URL (e.g., https://yourdomain.myshopify.com/) with your actual WordPress site domain. Update Social Media Target IDs: LinkedIn: Update the Person ID (e.g., PghXXXXnRg) and Organization ID (e.g., 109XXX908) in the respective LinkedIn nodes to match your profile and company page. Telegram Send/Repost: Update the chatId (e.g., -10025XXXX5258) in the sending Telegram nodes to match the channel or group you want to cross-post to. Support & Help WhatsApp: Chat on WhatsApp Discord: SpaGreen Community Facebook Group: SpaGreen Support Website: https://spagreen.net Developer Portfolio: Codecanyon SpaGreen
Post-surgery patient triage & follow-up system with Gemini AI, Telegram & Google Suite
Who’s it for This template is for clinics, hospitals, care teams, and telemedicine providers who need a structured, automated system for post-surgery follow-up. It helps reduce manual workload while ensuring every patient gets timely check-ins and appropriate triage. What it does / How it works This workflow automates daily recovery monitoring using Google Sheets and Telegram. It sends scheduled check-in messages to all patients within their follow-up window. When a patient replies, the message is: Captured by Telegram Trigger Cleaned and structured Summarized by an AI agent Classified into low, moderate, or high intensity Based on the intensity level: Low: Sends a supportive, non-urgent response Moderate: Sends guidance + schedules a follow-up event in Google Calendar High: Sends an alert email to the doctor via Gmail All logic runs automatically. Requirements Google Sheets OAuth2 credentials Gmail OAuth2 credentials Google Calendar OAuth2 credentials Telegram Bot credentials Gemini API credentials A Google Sheet with patient name, surgery type, follow-up duration, and doctor email How to set up Connect all required credentials inside n8n. Replace the Google Sheet ID with your own patient sheet. Adjust column mappings if your sheet structure differs. Test by sending a Telegram message to your bot. Enable the Schedule Trigger to begin automated daily follow-ups. How to customize the workflow Modify AI prompts inside the AI Agent nodes Adjust triage logic for intensity levels Change follow-up intervals in the Schedule Trigger Add additional notification channels (SMS, Slack, CRM logging)