Building your first WhatsApp chatbot
This n8n template builds a simple WhatsApp chabot acting as a Sales Agent. The Agent is backed by a product catalog vector store to better answer user's questions. This template is intended to help introduce n8n users interested in building with WhatsApp. How it works This template is in 2 parts: creating the product catalog vector store and building the WhatsApp AI chatbot. A product brochure is imported via HTTP request node and its text contents extracted. The text contents are then uploaded to the in-memory vector store to build a knowledgebase for the chatbot. A WhatsApp trigger is used to capture messages from customers where non-text messages are filtered out. The customer's message is sent to the AI Agent which queries the product catalogue using the vector store tool. The Agent's response is sent back to the user via the WhatsApp node. How to use Once you've setup and configured your WhatsApp account and credentials First, populate the vector store by clicking the "Test Workflow" button. Next, activate the workflow to enable the WhatsApp chatbot. Message your designated WhatsApp number and you should receive a message from the AI sales agent. Tweak datasource and behaviour as required. Requirements WhatsApp Business Account OpenAI for LLM Customising this workflow Upgrade the vector store to Qdrant for persistance and production use-cases. Handle different WhatsApp message types for a more rich and engaging experience for customers.
Generate AI viral videos with NanoBanana & VEO3, shared on socials via Blotato
Generate AI viral videos with NanoBanana & VEO3, shared on socials via Blotato Who is this for? This workflow is designed for content creators, marketers, and entrepreneurs who want to automate their video production and social media publishing process. If you regularly post promotional or viral-style content on platforms like TikTok, YouTube Shorts, Instagram Reels, LinkedIn, and more, this template will save you hours of manual work. --- What problem is this workflow solving? / Use case Creating viral short-form videos is often time-consuming: You need to generate visuals, write scripts, edit videos, and then manually upload them to multiple platforms. Staying consistent across TikTok, YouTube Shorts, Instagram Reels, LinkedIn, Twitter/X, and others requires constant effort. This workflow solves the problem by automating the entire pipeline from idea → video creation → multi-platform publishing. --- What this workflow does Collects an idea and image from Telegram. Enhances visuals with NanoBanana for user-generated content style. Generates a complete video script with AI (OpenAI + structured prompts). Creates the final video with VEO3 using your custom prompt and visuals. Rewrites captions with GPT to be short, catchy, and optimized for social platforms. Saves metadata in Google Sheets for tracking and management. Auto-uploads the video to all major platforms via Blotato (TikTok, YouTube, Instagram, LinkedIn, Threads, Pinterest, X/Twitter, Bluesky, Facebook). Notifies you on Telegram with a preview link once publishing is complete. --- Setup Connect your accounts: Google Sheets (for video tracking) Telegram (to receive and send media) Blotato (for multi-platform publishing) OpenAI API (for captions, prompts, and image analysis) VEO3 API (for video rendering) Fal.ai (for NanoBanana image editing) Google Drive (to store processed images) Set your credentials in the respective nodes. Adjust the Google Sheet IDs to match your own sheet structure. Insert your Telegram bot token in the Set: Bot Token (Placeholder) node. --- How to customize this workflow to your needs Platforms: Disable or enable only the Blotato social accounts you want to post to. Video style: Adjust the master prompt schema in the Set Master Prompt node to fine-tune tone, camera style, or video format. Captions: Modify the GPT prompt in the Rewrite Caption with GPT-4o node to control length and tone. Notifications: Customize the Telegram nodes to notify team members, not just yourself. Scheduling: Add a Cron trigger if you want automatic posting at specific times. --- ✨ With this workflow, you go from idea → AI-enhanced video → instant multi-platform publishing in just minutes, with almost no manual work. 📄 Documentation: Notion Guide --- Need help customizing? Contact me for consulting and support : Linkedin / Youtube
Suggest meeting slots using AI
The purpose of this n8n workflow is to automate the process of identifying incoming Gmail emails that are requesting an appointment, evaluating their content, checking calendar availability, and then composing and sending a response email. Note that to use this template, you need to be on n8n version 1.19.4 or later.
Gmail AI Email Manager
Want to check out all my flows, follow me on: https://maxmitcham.substack.com/ https://www.linkedin.com/in/max-mitcham/ Email Manager - Intelligent Gmail Classification This automation flow is designed to automatically monitor incoming Gmail messages, analyze their content and context using AI, and intelligently classify them with appropriate labels for better email organization and prioritization. ⚙️ How It Works (Step-by-Step): 📧 Gmail Monitoring (Trigger) Continuously monitors your Gmail inbox: Polls for new emails every minute Captures all incoming messages automatically Triggers workflow for each new email received 📖 Email Content Extraction Retrieves complete email details: Full email body and headers Sender information and recipient lists Subject line and metadata Existing Gmail labels and categories Email threading information (replies/forwards) 🔍 Email History Analysis AI agent checks relationship context: Searches for previous emails from the same sender Checks sent folder for prior outbound correspondence Determines if this is a first-time contact (cold email) Analyzes conversation thread history 🤖 Intelligent Classification Agent Advanced AI categorization using: Claude Sonnet 4 for sophisticated email analysis Context-aware classification based on email history Content analysis for intent and urgency detection Header analysis for automated vs. human-sent emails 🏷️ Smart Label Assignment Automatically applies appropriate Gmail labels: To Respond: Requires direct action/reply FYI: For awareness, no action needed Notification: Service updates, policy changes Marketing: Promotional content and sales pitches Meeting Update: Calendar-related communications Comment: Document/task feedback 📋 Structured Processing Ensures consistent labeling: Uses structured output parsing for reliability Returns specific Label ID for Gmail integration Applies label automatically to the email Maintains classification accuracy 🛠️ Tools Used: n8n: Workflow automation platform Gmail API: Email monitoring and label management Anthropic Claude: Advanced email content analysis Gmail Tools: Email history checking and search Structured Output Parser: Consistent AI responses 📦 Key Features: Real-time email monitoring and classification Context-aware analysis using email history Intelligent cold vs. warm email detection Multiple classification categories for organization Automatic Gmail label application Header analysis for automated email detection Thread-aware conversation tracking 🚀 Ideal Use Cases: Busy executives managing high email volumes Sales professionals prioritizing prospect communications Support teams organizing customer inquiries Marketing teams filtering promotional content Anyone wanting automated email organization Teams needing consistent email prioritization
Scrape any web page into structured JSON data with ScrapeNinja and AI
Disclaimer: This template only works on self-hosted for now, as it uses a community node. Use Case Web scrapers often break due to web page layout changes. This workflow attempts to mitigate this problem by auto-generating web scraping data extractor code via LLM. How It Works This workflow leverages ScrapeNinja n8n community node to: scrape webpage HTML, feed it into LLM (Google Gemini) and ask to write a JS extractor function code, then it executes the written JS extractor against scraped HTML to extract useful data from webpage (the code is safely executed in a sandbox) Installation To install ScrapeNinja n8n node, in your self-hosted instance, go to Settings -> Community nodes, enter "n8n-nodes-scrapeninja", and install. Make sure you are using at least v0.3.0. See this in action: https://www.linkedin.com/feed/update/urn:li:activity:7289659870935490560/
🎓 Learn n8n expressions with an interactive step-by-step tutorial for beginners
How it works This template is an interactive, step-by-step tutorial designed to teach you the most important skill in n8n: using expressions to access and manipulate data. If you know what JSON is but aren't sure how to pull a specific piece of information from one node and use it in another, this workflow is for you. It starts with a single "Source Data" node that acts as our filing cabinet, and then walks you through a series of lessons, each demonstrating a new technique for retrieving and transforming that data. You will learn how to: Access a simple value from a previous node. Use n8n's built-in selectors like .last() and .first(). Get a specific item from a list (Array). Drill down into nested data (Objects). Combine these techniques to access data in an array of objects. Go beyond simple retrieval by using JavaScript functions to do math or change text. Inspect data with utility functions like Object.keys() and JSON.stringify(). Summarize data from multiple items using .all() and arrow functions. Set up steps Setup time: 0 minutes! This workflow is a self-contained tutorial and requires no setup or external credentials. Click "Execute Workflow" to run the entire tutorial. Follow the flow from the "Source Data" node to the "Final Exam" node. For each lesson, click on the node to see how its expressions are configured in the parameters panel. Read the detailed sticky note next to each lesson—it breaks down exactly how the expression works and why. By the end, you'll have the foundational knowledge to connect data and build powerful, dynamic workflows in n8n.
Ai prompt generator workflow
🧠 AI Prompt Generator Workflow – n8n Documentation Who is this for? This workflow is for AI builders, prompt engineers, developers, marketers, and no-code creators who want to convert rough user input into structured, high-quality prompts for LLMs. It’s especially useful for tools that rely on precision prompting and want to automate the discovery of intent and constraints. --- What problem is this workflow solving? / Use case Many users struggle to write effective prompts due to vague ideas or unclear formatting needs. This workflow: Collects structured user input. Dynamically generates clarifying questions. Returns a well-formatted AI prompt based on the user's intent and context. This ensures the generated prompt is useful for downstream AI agents without requiring technical understanding from the end user. --- What this workflow does Start with a branded form UI The user is shown a styled form with questions like: What do you want to build? What tools can you access? What input can be expected? What output do you expect? Analyze and generate relevant follow-up questions The workflow sends the user's answers to Google Gemini (via LangChain) which outputs 1–3 clarifying questions. These questions are parsed into a dynamic form. Loop through and collect follow-up answers Each follow-up question is shown in a form one at a time to capture additional context. Merge all inputs The base intent and follow-up responses are merged into a single context block. Generate a final AI-ready prompt The prompt generator node formats everything into a clean, six-section structure: <constraints> <role> <inputs> <tools> <instructions> <conclusions> Display the final result The finished prompt is shown in a clean UI where users can easily copy and reuse it. --- Setup Credentials Required Google Gemini (PaLM) API credentials (already integrated as Google Gemini(PaLM) Api account 2). Form Trigger Ensure the On form submission trigger is exposed via a webhook or public endpoint (e.g. using ngrok or deployed server). Styling Custom CSS is included in all form nodes for a beautiful UI. You can modify this to match your branding. Environment This workflow is compatible with self-hosted n8n or n8n.cloud. Webhooks must be accessible to users who will fill out the form. --- How to customize this workflow to your needs Change the base questions Update the BaseQuestions form node to add or remove fields depending on your use case. Modify Gemini prompts You can edit the system prompt inside PromptGenerator to change tone, output structure, or AI instructions. Change prompt formatting If you use a different AI agent (like GPT, Claude, or Mistral), adjust the section labels and formatting to suit that agent’s expected input. Send results elsewhere Add integration nodes after PromptGenerator, such as: Google Docs / Notion (to log prompts) Gmail / Slack (to notify your team) Zapier / Make (to push to other automation flows) Skip follow-up questions (optional) If your base form collects all needed info, you can bypass the RelevantQuestions form section by modifying conditional logic. --- Example Output Prompt (Structure) <role> You are an AI assistant that converts videos into LinkedIn posts with a witty tone. </role> <inputs> - A short video (max 5 minutes) - Desired tone: witty - Style: both summary and quotes - Audience: general network </inputs> <tools> You do not have access to APIs or web search. </tools> <instructions> 1. Parse transcript. 2. Extract insights and quotes. 3. Write an engaging, witty LinkedIn post under 3000 characters. </instructions> <constraints> Avoid technical jargon. No generic intros. Make it platform-native. </constraints> <conclusions> Return a LinkedIn-ready post that starts with a hook and ends with hashtags.
Use an open-source LLM (via HuggingFace)
This workflow demonstrates how to connect an open-source model to a Basic LLM node. The workflow is triggered when a new manual chat message appears. The message is then run through a Language Model Chain that is set up to process text with a specific prompt to guide the model's responses. Note that open-source LLMs with a small number of parameters require slightly different prompting with more guidance to the model. You can change the default Mistral-7B-Instruct-v0.1 model to any other LLM supported by HuggingFace. You can also connect other nodes, such as Ollama. Note that to use this template, you need to be on n8n version 1.19.4 or later.
Analyze Reddit posts with AI to identify business opportunities
Use case Manually monitoring Reddit for viable business ideas is time-consuming and inconsistent. This workflow automatically analyzes trending Reddit discussions using AI to surface high-potential opportunities, filter irrelevant content, and generate actionable insights - saving entrepreneurs 10+ hours weekly in market research. What this workflow does This AI-powered workflow automatically collects trending Reddit discussions, analyzes posts for viable business opportunities using GPT-4, applies smart filters to exclude low-value content, and generates scored opportunity reports with market insights. It identifies unmet customer needs through sentiment analysis, prioritizes high-potential ideas using custom criteria, and outputs structured data to Google Sheets for actionable decision-making. Setup Add Reddit,Google and OpenAI credentials Configure target subreddits in Subreddit node Test workflow by testing workflow Review generated opportunity report in Google Sheets How to adjust this template Change data sources: Replace Reddit trigger with Twitter/X or Hacker News API Modify criteria: Adjust scoring thresholds in Opportunity Calculator node Add integrations: Create automatic Slack alerts for urgent opportunities Generate draft business plans using AI Document Writer
Publish image & video to multiple social media (X, Instagram, Facebook and more)
This Workflow streamlines the process of publishing posts (image or video) to multiple social media platforms using a unified form and a third-party API service called Upload-Post. The automation starts with a form trigger, allowing users to submit content (text and media) through a simple frontend interface. Users select the platform (Instagram, LinkedIn, Facebook, X, TikTok, Threads), choose the profile name, write a caption, and upload a photo or video. --- How It Works Automates cross-platform social media posting via Upload-Post, handling both images (JPEG) and videos (MP4). Here’s the process: Trigger: A form submission captures user inputs: Platform (Instagram, LinkedIn, Facebook, X, TikTok, Threads). Account (pre-configured profile name). Caption and file (image/video). Optional Facebook Page ID for targeted posting. Routing: The "Video or Photo?" Switch node checks the file’s MIME type: Image: Routes to the "Post photo" HTTP node (uploads via upload_photos API). Video: Routes to the "Post video" HTTP node (uploads via upload API). API Integration: Both nodes send data to Upload-Post.com’s API, including: Caption, account name, platform, and file binary. Facebook ID (if provided). Success/Failure Handling: The "Result Photo/Video" nodes parse the API response. --- Setup Steps Prerequisites: Upload-Post.com API Key: Get it from the API Keys dashboard. Free tier allows 10 uploads/month. Configuration: API Authentication: In the HTTP Request nodes (Post photo/Post video), set the Authorization header: Name: Authorization Value: Apikey YOURAPIKEY_HERE. Form Customization: Adjust the "On form submission" node to: Add/remove platforms (e.g., YouTube when approved). Modify file type restrictions (default: .jpg, .mp4). Account Mapping: Ensure the "Account" field matches profiles configured in Upload-Post.com (e.g., test1, test2). Facebook Page Integration: Optional: Add a Facebook Page ID field for page-specific posts. Testing: Submit test forms with images/videos. Verify API responses and success/failure messages. Optional Enhancements: Add error logging (e.g., save failed attempts to a database). Extend to YouTube once API support is confirmed. --- Key Features: Multi-Platform: Post to 6+ social networks simultaneously. User-Friendly: Simple form interface for non-technical users. Error Handling: Clear feedback for success/failure cases. --- Need help customizing? Contact me for consulting and support or add me on Linkedin.
Automate competitor research with Exa.ai, Notion and AI agents
This n8n workflow demonstrates a simple multi-agent setup to perform the task of competitor research. It showcases how using the HTTP request tool could reduce the number of nodes needed to achieve a workflow like this. How it works For this template, a source company is defined by the user which is sent to Exa.ai to find competitors. Each competitor is then funnelled through 3 AI agents that will go out onto the internet and retrieve specific datapoints about the competitor; company overview, product offering and customer reviews. Once the agents are finished, the results are compiled into a report which is then inserted in a notion database. Check out an example output here: https://jimleuk.notion.site/2d1c3c726e8e42f3aecec6338fd24333?v=de020fa196f34cdeb676daaeae44e110&pvs=4 Requirements An OpenAI account for the LLM. Exa.ai account for access to their AI search engine. SerpAPI account for Google search. Firecrawl.dev account for webscraping. Notion.com account for database to save final reports. Customising the workflow Add additional agents to gather more datapoints such as SEO keywords and metrics. Not using notion? Feel free to swap this out for your own database.
Deep Research - Sales Lead Magnet Agent
Want to check out all my flows, follow me on: https://maxmitcham.substack.com/ https://www.linkedin.com/in/max-mitcham/ This automation flow is designed to generate comprehensive, research-backed lead magnet articles based on a user-submitted topic, conduct deep research across multiple sources, and automatically create a professional Google Doc ready for LinkedIn sharing. ⚙️ How It Works (Step-by-Step): 📝 Chat Input (Entry Point) A user submits a topic through the chat interface: Topic for lead magnet content Target audience (automatically detected) Company context (when relevant) 🔍 Query Builder Agent An AI agent refines the input by: Converting the topic into 5 targeted research queries Determining if topic relates to *company for specialized research Using structured output parsing for consistent results 📚 Research Leader Agent Conducts comprehensive research that: Uses Perplexity API for real-time web research Integrates *company knowledge base when relevant Creates detailed table of contents with research insights Identifies key trends, expert opinions, and case studies 📋 Project Planner Agent Structures the content by: Generating professional title and subtitle Creating 8-10 logical chapter outlines Developing detailed writing prompts for each section Ensuring step-by-step actionable guidance ✍️ Research Assistant Team Multiple AI agents write simultaneously: Each agent writes one chapter with proper citations Maintains consistent voice across all sections Includes real-world examples and implementation steps Uses both web research and *company knowledge 📝 Editor Agent Professional content polishing: Refines tone for authenticity and engagement Adds image placeholders where appropriate Ensures proper flow between chapters Optimizes for LinkedIn lead magnet format 📄 Google Docs Creation Automated document generation: Creates new Google Doc with formatted content Sets proper sharing permissions (public link) Organizes in designated company folder Returns shareable URL for immediate use 🛠️ Tools Used: n8n: Workflow orchestration platform Anthropic Claude: Primary AI model for content generation OpenRouter: Backup AI model options Perplexity API: Real-time research capabilities *Company Knowledge Hub: Internal documentation access Google Docs API: Document creation and formatting Google Drive API: File management and sharing 📦 Key Features: End-to-end automation from topic to published document Multi-agent approach ensures comprehensive coverage Real-time research with proper citations Company-specific knowledge integration Professional editing and formatting Automatic Google Docs creation with sharing Scalable content generation (3-5 minutes per article) 🚀 Ideal Use Cases: B2B companies building thought leadership content Sales teams creating industry-specific lead magnets Marketing departments scaling content production Consultants developing expertise-demonstrating resources SaaS companies creating feature-focused educational content Startups establishing market presence without content teams