Allow your AI to call an API to fetch data
Use n8n to bring data from any API to your AI. This workflow uses the Chat Trigger to provide the chat interface, and the Custom n8n Workflow Tool to call a second workflow that calls the API. The second workflow uses AI functionality to refine the API request based on the user's query. It then makes an API call, and returns the response to the main workflow. This workflow is used in Advanced AI examples | Call an API to fetch data in the documentation. To use this workflow: Load it into your n8n instance. Add your credentials as prompted by the notes. Requires n8n 1.28.0 or above
Receipt scanning & analysis workflow
How it works: Automatically detects when a new receipt is uploaded to Google Drive. Extracts text from the receipt using OCR. Uses an AI Agent to analyze the extracted data and structure it (e.g., vendor, date, total, tax). Saves the organized receipt data into a Google Sheet for easy tracking. Set up steps: Setup takes around 15–20 minutes. You'll need a Google Drive folder for receipts and a Google Sheet to store results. Configure your Google Drive Trigger, OCR extraction, AI Agent, and Google Sheets connection. Detailed instructions and explanations are included in this n8n Starter Session tutorial series.
Get an mp4 attachment from Gmail to Google Drive
This simple workflow allows you to get an mp4 attachment from gmail email and then upload it to Google Drive to get attachment webview link.
Automatically document n8n workflows directly in Notion database
Use case n8n workflows can go out of hand when you're automating as much as we do at n8n. We needed a place to document them and keep track of who owns and maintains them. To facilitate this we use this n8n workflow to automatically sync workflows directly to a Notion database if it has the tag sync-to-notion. How to setup Add your n8n api creds Add your Notion creds Create notion database with fields env id as text, isActive (dev) as boolean, URL (dev) as url, Workflow created at as date, Workflow updated at as date, Error workflow setup as boolean (Make sure page is connected) Add tag sync-to-notion to some workflows
Webhook returning XML
Receives data from an incoming HTTP Request (set up to use respond to webhook node) Create dummy data Convert JSON to XML which gets returned Respond to Webhook which returns the data and the content type of the data
Automatically archive Gmail emails from Inbox
Use Case Automatically archive emails in your Gmail inbox from the last day, unless they have been starred. Been using this with my personal and work emails to stick to an Inbox Zero strategy, without having to click or swipe a lot. Setup Add your Gmail creds How to adjust this template Set your own schedule for when to run this. Otherwise, should be good to go. 🤞🏽
Job applying agent
Who this is for This workflow is for freelancers, job seekers, or service providers who want to automatically apply to businesses by scraping their website information, extracting contact details, and sending personalized job application emails with AI-powered content — all from one form submission. What this workflow does This workflow starts every time someone submits the Job Applier Form. It then: Scrapes the target business website to gather company information and contact details. Converts HTML content to readable markdown format for better AI processing. Extracts email addresses and creates a company summary using GPT-5 AI. Validates email addresses to ensure they contain proper formatting (@ symbol check). Accesses your experience data from a connected Google Sheet with your skills and portfolio. Generates personalized application emails (subject + body) using GPT-5 based on the job position and company info. Sends the application email automatically via Gmail with your name as sender. Provides confirmation through a completion form showing the AI's response. Setup To set this workflow up: Form Trigger – Customize the job application form fields (Target Business Website, Applying As dropdown with positions like Video Editor, SEO Expert, etc.). OpenAI GPT-5 – Add your OpenAI API credentials for both AI models used in the workflow. Google Sheets – Connect your sheet containing your working experience data, skills, and portfolio information. Gmail Account – Link your Gmail account for sending application emails automatically. Experience Data – Update the Google Sheet with your relevant skills, experience, and achievements for each job type. Sender Name – Modify the sender name in Gmail settings (currently set to "Jamal Mia"). How to customize this workflow to your needs Add more job positions to the dropdown menu (currently includes Video Editor, SEO Expert, Full-Stack Developer, Social Media Manager). Modify the AI prompt to reflect your unique value proposition and application style. Enhance email validation with additional checks like domain verification or email format patterns. Add follow-up scheduling to automatically send reminder emails after a certain period. Include attachment functionality to automatically attach your resume or portfolio to applications. Switch to different email providers or add multiple sender accounts for variety.
Daily swing trade ideas with GPT-4, Yahoo Finance, Google Sheets & Telegram
Automated daily swing‑trade ideas from end‑of‑day (EOD) data, scored by an LLM, logged to Google Sheets, and pushed to Telegram. --- What this workflow does Fetches EOD quotes for a chosen stock universe (example: NSE‑100 via RapidAPI). Cleans & filters the universe using simple technical/quality gates (e.g., price/volume sanity, avoid illiquid names). Packages market context and feeds it to OpenAI with a strict JSON schema to produce top swing‑trade recommendations (entry, target, stop, rationale). Splits structured output into rows and logs them to a Google Sheet for tracking. Sends an alert with the day’s trade ideas to Telegram (channel or DM). --- Ideal for Retail traders who want a daily, hands‑off idea generator. PMs/engineers prototyping LLM‑assisted quant sidekicks. Creators who publish daily trade notes to their audience. --- Tech stack n8n (orchestration) RapidAPI (EOD quotes; pluggable data source) OpenAI (LLM for idea generation) Google Sheets (logging & performance tracker) Telegram (alerts) --- Prerequisites RapidAPI key with access to an EOD quotes endpoint for your exchange. OpenAI API key. Google account with a Sheet named TradeRecommendationsTracker (or update the node). Telegram bot token (via @BotFather) and destination chat ID. > You can replace any of the above vendors with equivalents (e.g., Alpha Vantage, Twelve Data, Polygon, etc.). Only the HTTP Request + Format nodes need tweaks. --- Environment variables | Key | Example | Used in | | -------------------- | -------------------------- | --------------------- | | RAPIDAPI_KEY | xxxxxxxxxxxxxxxxxxxxxxxx | HTTP Request (quotes) | | OPENAIAPIKEY | sk-… | OpenAI node | | TELEGRAMBOTTOKEN | 123456:ABC-DEF… | Telegram node | | TELEGRAMCHATID | 5357385827 | Telegram node | --- Google Sheet schema Create a Sheet (tab: EOD_Ideas) with the headers: Date, Symbol, Direction, Entry, Target, StopLoss, Confidence, Reason, SourceModel, UniverseTag Node map (name → purpose) Trigger – Daily Market Close → Fires daily after market close (e.g., 4:15 PM IST). Prepare Stock List (NSE 100) → Provides stock symbols to analyze (static list or from a Sheet/API). Fetch EOD Data (RapidAPI) → Gets EOD data for all symbols in one or batched calls. Format EOD Data → Normalizes API response to a clean array (symbol, close, high, low, volume, etc.). Filter Valid Stock Data → Drops illiquid/invalid rows (e.g., volume > 200k, close > 50). Build LLM Prompt Input → Creates compact market context & JSON instructions for the model. Generate Swing Trade Ideas (OpenAI) → Returns strict JSON with top ideas. Split JSON Output (Trade‑wise) → Explodes the JSON array into individual items. Log Trade to Google Sheet → Appends each idea as a row. Send Trade Alert to Telegram → Publishes a concise summary to Telegram.
Restore your workflows from GitHub
This workflow restores all n8n instance workflows from GitHub backups using the n8n API node. It complements the Backup Your Workflows to GitHub template by allowing users to seamlessly restore previously saved workflows. How It Works The workflow fetches workflows stored in a GitHub repository and imports them into your n8n instance. Setup Instructions To configure the workflow, update the Globals node with the following values: repo.owner – Your GitHub username repo.name – The name of your GitHub repository storing the workflows repo.path – The folder path within the repository where workflows are stored For example, if your GitHub username is john-doe, your repository is named n8n-backups, and workflows are stored in a workflows/ folder, you would set: repo.owner → john-doe repo.name → n8n-backups repo.path → workflows/ Required Credentials GitHub API – Access to your repository n8n API – To import workflows into your n8n instance Who Is This For? This template is ideal for users who want to restore their workflows from GitHub backups, ensuring easy migration and recovery in case of data loss. --- Check out my other templates: 👉 My n8n Templates
LinkedIn job hunting & outreach automation with Apify, Gemini AI, and Gmail
This n8n workflow automates the process of collecting job and decision-maker data, crafting AI-generated referral messages, and drafting them in Gmail—all using a combination of Apify, Google Sheets, LLMs, and email APIs. Use cases Auto-sourcing job postings from LinkedIn via Apify Identifying decision-makers at relevant companies Auto-drafting custom referral request messages using AI Exporting structured data to Google Sheets and drafting Gmail messages for outreach Good to know You can customize the filtering logic to target specific cities or companies. Message creation uses the Gemini 2.0 Flash model and LangChain’s output parser for structured messages. Email data is fetched using Anymailfinder, but can be replaced with other providers like Hunter.io. Gmail API drafts the message, but you need to enable Gmail API access from your Google Cloud console. How it works Trigger A Schedule Trigger runs the automation daily. Job Data Extraction Apify pulls job listings using a predefined actor. The HTTP response is split and structured using the Split Out node. Store Job Data Job listings are saved to a Google Sheet. The node maps key fields like title, company, location, and poster info. Decision-Maker Discovery Another Apify actor pulls decision-maker data from LinkedIn. This is split and filtered (e.g., by city or company name). Store Contacts Contact details (name, title, location, etc.) are appended to another Google Sheet (n8n-sheet). Message Generation A LLM Chain uses Gemini 2.0 Flash to generate short, custom LinkedIn messages. The message respects rules like tone, length (<100 words), and personalization. Parse & Merge AI Output The output is structured using Structured Output Parser and merged with contact data. Save Final Messages The final headline and body are stored back into Google Sheets (n8n-sheet). Email Discovery Get Email IDs node hits Anymailfinder API using the LinkedIn profile link. Draft in Gmail Using Gmail API, the message is drafted in your inbox with subject and body auto-filled. How to use Update Apify actor inputs to specify roles, companies, or locations. Replace the manual Schedule Trigger with a webhook or form input if desired. Update the Google Sheets document and sheet name in the relevant nodes. Add your Gmail and Anymailfinder credentials in n8n settings. Requirements Google Sheets API access Gmail API access Apify account Gemini API key (via Google AI Studio) Anymailfinder (or alternate email discovery API) Customizing this workflow This framework is highly modular. You can: Add more filters for company size, role, or hiring urgency Use alternate LLMs (OpenAI, Claude, etc.) Switch output channels (Slack, WhatsApp, etc.) Plug in different CRM tools for follow-ups
Build your own SQLite MCP server
This template is for Self-Hosted N8N Instances only. This n8n demonstrates how to build a simple SQLite MCP server to perform local database operations as well as use it for Business Intelligence. This MCP example is based off an official MCP reference implementation which can be found here -https://github.com/modelcontextprotocol/servers/tree/main/src/sqlite How it works A MCP server trigger is used and connected to 5 tools: 2 Code Node and 3 Custom Workflow. The 2 Code Node tools use the SQLLite3 library and are simple read-only queries and as such, the Code Node tool can be simply used. The 3 custom workflow tools are used for select, insert and update queries as these are operations which require a bit more discretion. Whilst it may be easier to allow the agent to use raw SQL queries, we may find it a little safer to just allow for the parameters instead. The custom workflow tool allows us to define this restricted schema for tool input which we'll use to construct the SQL statement ourselves. All 3 custom workflow tools trigger the same "Execute workflow" trigger in this very template which has a switch to route the operation to the correct handler. Finally, we use our Code nodes to handle select, insert and update operations. The responses are then sent back to the the MCP client. How to use This SQLite MCP server allows any compatible MCP client to manage a SQLite database by supporting select, create and update operations. You will need to have a SQLite database available before you can use this server. Connect your MCP client by following the n8n guidelines here - https://docs.n8n.io/integrations/builtin/core-nodes/n8n-nodes-langchain.mcptrigger/integrating-with-claude-desktop Try the following queries in your MCP client: "Please create a table to store business insights and add the following..." "what business insights do we have on current retail trends?" "Who has contributed the most business insights in the past week?" Requirements SQLite for database. MCP Client or Agent for usage such as Claude Desktop - https://claude.ai/download Customising this workflow If the scope of schemas or tables is too open, try restrict it so the MCP serves a specific purpose for business operations. eg. Confine the querying and editing to HR only tables before providing access to people in that department. Remember to set the MCP server to require credentials before going to production and sharing this MCP server with others!
Generate video ads with Gemini 2.5 flash images & FAL WAN animation
This automated workflow template transforms a single product image into a complete professional advertisement video with dynamic motion and custom soundtrack. Perfect for e-commerce businesses, marketing agencies, and content creators who need to quickly produce high-quality video ads for social media platforms like TikTok, Instagram Reels, and YouTube Shorts. Note: This workflow uses FAL.ai API for AI image generation with Gemini Bano Banana and video creation with Wan, Google Gemini for intelligent storyboarding, ImgBB for image hosting, and Upload-Post.com for automated social media publishing. Who Is This For? E-commerce Businesses: Transform product photos into engaging video advertisements that drive sales and increase conversion rates across social media platforms. Marketing Agencies: Scale video ad production for multiple clients without expensive video equipment or extensive editing time. Social Media Managers: Create consistent, professional video content for brands that stands out in crowded social feeds. Content Creators & Influencers: Generate eye-catching product showcase videos for sponsored content and affiliate marketing campaigns. Small Business Owners: Compete with larger brands by creating professional-quality video ads on a budget. What Problem Does This Workflow Solve? Creating professional video advertisements traditionally requires expensive equipment, design skills, and hours of editing time. This workflow addresses these challenges by: AI-Powered Visual Enhancement: Automatically generates 4 unique variations of your product image with different lighting, backgrounds, and visual effects. Intelligent Motion Generation: Converts static images into dynamic 5-second video clips with smooth camera movements, rotations, and visual effects. Automated Storyboarding: Uses AI to create a cohesive visual narrative that showcases your product from multiple appealing angles. Professional Audio Integration: Automatically generates and adds suitable background music that matches your product and brand aesthetic. Seamless Video Composition: Combines all video clips into a single 20-second advertisement with smooth transitions. Multi-Platform Publishing: Automatically uploads finished videos to TikTok, Instagram, and YouTube with optimized formatting. How It Works Product Upload: Submit a single product image and brief description through the web form interface. AI Storyboard Creation: Google Gemini AI analyzes your product and creates a 4-frame visual story with lighting enhancements, background changes, and cinematic effects. Image Generation: FAL.ai Gemini 2.5 Flash creates 4 unique variations of your product image based on the AI-generated prompts. Video Animation: Each enhanced image is converted into a 5-second video clip with specific motion patterns (rotation, zoom, lighting sweeps, camera orbits). Quality Control: The system monitors video generation progress and ensures all clips are successfully created before proceeding. Video Sequencing: FFmpeg API combines all 4 video clips into a seamless 20-second advertisement with smooth transitions. Audio Enhancement: AI generates appropriate background music that matches your product category and brand style. Final Composition: Audio and video are merged to create the complete advertisement. Automated Publishing: The finished video is automatically uploaded to TikTok, Instagram Reels, and YouTube with your product description. Setup FAL.ai API Setup: Create account at fal.ai and obtain API credentials Add your API token to the HTTP request authentication nodes Google Gemini API: Set up Google AI Studio account and get API key Configure the Google Gemini Chat Model node with your credentials ImgBB Configuration: Register at imgbb.com for image hosting Update the imgbbapikey in the "Set APIs Vars" node Upload-Post Integration: Create account at upload-post.com Connect your social media accounts (TikTok, Instagram, YouTube) Add your Upload-Post credentials to the final upload node Workflow Configuration: Adjust video parameters (resolution, frame rate, duration) in the image-to-video nodes Customize audio prompts in the "Create Sounds" node Modify social media posting settings in the "Upload Post" node Requirements Accounts: n8n, FAL.ai, Google AI Studio, ImgBB, Upload-Post.com API Keys: FAL.ai API token, Google Gemini API key, ImgBB API key, Upload-Post credentials Social Media: Connected TikTok, Instagram, and YouTube accounts for automated publishing Features AI-Powered Image Enhancement: Creates 4 professional variations with lighting, background, and effect improvements Dynamic Video Generation: Converts static images to engaging videos with camera movements and visual effects Intelligent Audio Matching: Generates background music that complements your product and target audience Multi-Platform Optimization: Automatically formats videos for TikTok, Instagram Reels, and YouTube Shorts (9:16 aspect ratio) Progress Monitoring: Built-in status checking ensures reliable video generation before proceeding to next steps Automated Publishing: Direct upload to social media platforms with optimized descriptions and formatting Scalable Processing: Handles multiple video generations simultaneously for efficient batch processing Professional Quality: Produces broadcast-ready videos suitable for paid advertising campaigns Use this template to revolutionize your product marketing strategy, automatically converting any product photo into multiple high-quality video advertisements ready for immediate social media deployment.