AI agent that can scrape webpages
⚙️🛠️🚀🤖🦾 This template is a PoC of a ReAct AI Agent capable of fetching random pages (not only Wikipedia or Google search results). On the top part there's a manual chat node connected to a LangChain ReAct Agent. The agent has access to a workflow tool for getting page content. The page content extraction starts with converting query parameters into a JSON object. There are 3 pre-defined parameters: url – an address of the page to fetch method = full / simplified maxlimit - maximum length for the final page. For longer pages an error message is returned back to the agent Page content fetching is a multistep process: An HTTP Request mode tries to get the page content. If the page content was successfuly retrieved, a series of post-processing begin: Extract HTML BODY; content Remove all unnecessary tags to recuce the page size Further eliminate external URLs and IMG scr values (based on the method query parameter) Remaining HTML is converted to Markdown, thus recuding the page lengh even more while preserving the basic page structure The remaining content is sent back to an Agent if it's not too long (maxlimit = 70000 by default, see CONFIG node). NB: You can isolate the HTTP Request part into a separate workflow. Check the Workflow Tool description, it guides the agent to provide a query string with several parameters instead of a JSON object. Please reach out to Eduard is you need further assistance with you n8n workflows and automations! Note that to use this template, you need to be on n8n version 1.19.4 or later.
✨🔪 Advanced AI powered document parsing & text extraction with Llama Parse
Description This workflow automates document processing using LlamaParse to extract and analyze text from various file formats. It intelligently processes documents, extracts structured data, and delivers actionable insights through multiple channels. How It Works Document Ingestion & Processing 📄 Monitors Gmail for incoming attachments or accepts documents via webhook Validates file formats against supported LlamaParse extensions Uploads documents to LlamaParse for advanced text extraction Stores original documents in Google Drive for reference Intelligent Document Analysis 🧠 Automatically classifies document types (invoices, reports, etc.) Extracts structured data using customized AI prompts Generates comprehensive document summaries with key insights Converts unstructured text into organized JSON data Invoice Processing Automation 💼 Extracts critical invoice details (dates, amounts, line items) Organizes financial data into structured formats Calculates tax breakdowns, subtotals, and payment information Maintains detailed records for accounting purposes Multi-Channel Delivery 📱 Saves extracted data to Google Sheets for tracking and analysis Sends concise summaries via Telegram for immediate review Creates searchable document archives in Google Drive Updates spreadsheets with structured financial information Setup Steps Configure API Credentials 🔑 Set up LlamaParse API connection Configure Gmail OAuth for email monitoring Set up Google Drive and Sheets integrations Add Telegram bot credentials for notifications Customize AI Processing ⚙️ Adjust document classification parameters Modify extraction templates for specific document types Fine-tune summary generation prompts Customize invoice data extraction schema Test and Deploy 🚀 Test with sample documents of various formats Verify data extraction accuracy Confirm notification delivery Monitor processing pipeline performance
URL and IP lookups through Greynoise and VirusTotal
This n8n workflow serves as a powerful cybersecurity and threat intelligence tool to look up URLs or IP addresses through industry standard threat intelligence vendors. It starts with either a form submission or a webhook trigger, allowing users to input data, URLs or IPs that require analysis. The workflow then splits into two paths depending on whether the input data is an IP or URL. If an IP was given, it sets the ip variable to the IP; however if a URL was given the workflow will perform a DNS lookup using Google Public DNS and sets the ip variable based on the results from Google. The workflow then checks the obtained IP addresses against GreyNoise services, with one branch utilizing GreyNoise RIOT IP Lookup to assess IP reputation and association with known benign services, and the other using GreyNoise IP Context to evaluate potential threats. The results from both GreyNoise services are merged to create a comprehensive analysis which includes the IP, classification (benign, malicious, or unknown), IP location, tags to identify activity or malware, category, and trust level. In parallel, a VirusTotal scan is initiated for the URL/IP to identify if it is malicious. A 5-second wait ensures proper processing, and the workflow subsequently polls the scan result to determine when the analysis is complete. The workflow then summarizes the analysis including the overall security vendor analysis results, blockList analysis, OpenPhish analysis, the URL, and the IP. Finally, the workflow combines the summarized intelligence from both GreyNoise and VirusTotal to provide a thorough analysis of the URL/IP. This summarized intelligence can then be emailed to the user that filled out the form via Gmail or it can be sent to the user via a Slack message. Setting up this workflow may require proper configuration of the form submission or webhook trigger, and ensuring that the GreyNoise and VirusTotal API credentials are correctly integrated. Users should also consider the potential volume of data and API rate limits, as excessive requests could lead to issues. Proper documentation and validation of input data are crucial to ensure accurate and meaningful results in the final report.
Flux dev image generation (Fal.ai) to Google Drive
This workflow automates AI-based image generation using the Fal.ai Flux API. Define custom prompts, image parameters, and effortlessly generate, monitor, and save the output directly to Google Drive. Streamline your creative automation with ease and precision. Who is this for? This template is for content creators, developers, automation experts, and creative professionals looking to integrate AI-based image generation into their workflows. It’s ideal for generating custom visuals with the Fal.ai Flux API and automating storage in Google Drive. What problem is this workflow solving? Manually generating AI-based images, checking their status, and saving results can be tedious. This workflow automates the entire process — from requesting image generation, monitoring its progress, downloading the result, and saving it directly to a Google Drive folder. What this workflow does Sets Custom Image Parameters: Allows you to define the prompt, resolution, guidance scale, and steps for AI image generation. Sends a Request to Fal.ai: Initiates the image generation process using the Fal.ai Flux API. Monitors Image Status: Checks for completion and waits if needed. Downloads the Generated Image: Fetches the completed image once ready. Saves to Google Drive: Automatically uploads the generated image to a specified Google Drive folder. Setup Prerequisites: • Fal.ai API Key: Obtain it from the Fal.ai platform and set it as the Authorization header in HTTP Header Auth credentials. • Google Drive OAuth Credentials: Connect your Google Drive account in n8n. Configuration: • Update the “Edit Fields” node with your desired image parameters: • Prompt: Describe the image (e.g., “Thai young woman net idol 25 yrs old, walking on the street”). • Width/Height: Define image resolution (default: 1024x768). • Steps: Number of inference steps (e.g., 30). • Guidance Scale: Controls image adherence to the prompt (e.g., 3.5). • Set your Google Drive folder ID in the “Google Drive” node to save the image. Run the Workflow: • Trigger the workflow manually to generate the image. • The workflow waits, checks status, and saves the final output seamlessly. Customization • Modify Image Parameters: Adjust the prompt, resolution, steps, and guidance scale in the “Edit Fields” node. • Change Storage Location: Update the Google Drive node with a different folder ID. • Add Notifications: Integrate an email or messaging node to alert you when the image is ready. • Additional Outputs: Expand the workflow to send the generated image to Slack, Dropbox, or other platforms. This workflow streamlines AI-based image generation and storage, offering flexibility and customization for creative automation.
Split out binary data
This workflows helps with processing binary data. You'll often have binary objects with keys such as attachment0, attachment1, attachment_2, etc. attached to your items, for example when reading an incoming email. This binary data is hard to process because it's not an array you can simply loop through. This workflow solves this problem by providing a Function node that takes all incoming items and all their binary data and then returning a single item for each file with a data key containing your binary file. Incoming binary data: Processed binary data:
Visual regression testing with Apify and AI Vision Model
This n8n workflow is a proof-of-concept template exploring how we might work with multimodal LLMs and their multi-image analysis capabilities. In this demo, we compare 2 screenshots of a webpage taken at different timestamps and pass both to our multimodal LLM for a visual comparison of differences. Handling multiple binary inputs (ie. images) in an AI request is supported by n8n's basic LLM node. How it works This template is intended to run as 2 parts: first to generate the base screenshots and next to run the visual regression test which captures fresh screenshots. Starting with a list of webpages captured in a Google sheet, base screenshots are captured for each using a external web scraping service called Apify.com (I prefer Apify but feel free to use whichever web scraping service available to you) These base screenshots are uploaded to Google Drive and will be referenced later when we run our testing. Phase 2 of the workflow, we'll use a scheduled trigger to fire sometime in the future which will reuse our web scraping service to generate fresh screenshots of our desired webpages. Next, re-download our base screenshots in parallel and with both old and new captures, we'll pass these to our LLM node. In the LLM node's options, we'll define 2 "user message" inputs with the type of binary (data) for our images. Finally, we'll prompt our LLM with our testing criteria and capture the regressions detected. Note, results will vary depending on which LLM you use. A final report can be generated using the LLM's output and is uploaded to Linear. Requirements Apify.com API key for web screenshotting service Google Drive and Sheets access to store list of webpages and captures Customising this workflow Have your own preferred web screenshotting service? Feel free to swap out Apify with your service of choice. If the web screenshot is too large, it may prove difficult for the LLM to spot differences with precision. Try splitting up captures into smaller images instead.
Generate & schedule social posts with Gemini/OpenAI for X and LinkedIn
💼 LinkedIn Content Machine – AI-Powered Post Generator & Scheduler for X and LinkedIn How it works: This end-to-end workflow automates your personal or brand content strategy by: 🧠 Using Google Gemini or OpenAI to generate engaging LinkedIn/X content from a title or trending posts. 🗓️ Posting directly to LinkedIn and X (formerly Twitter). 📊 Pulling high-performing LinkedIn posts to inspire new ideas. ✍️ Saving AI-generated drafts to Google Sheets for review. 🔔 Notifying your team on Slack when drafts are ready. Steps to set up: Add your API keys for Google Gemini or OpenAI. Set up your LinkedIn, X (Twitter), Google Sheets, and Slack credentials. Customize prompt logic or post filters if needed. Schedule the idea generation module or trigger it manually. Start generating and posting consistent, high-quality content with zero manual effort!
Auto workflow backup to Google Drive – automated export of all your workflows
n8n Workflow Backup to Google Drive – Automated Export of All Your Workflows This workflow is designed to automatically create backups of all your workflows in n8n and store them as individual .json files in Google Drive. It's a fully automated system that helps developers, agencies, or automation teams ensure their automation logic is always safe, versioned, and ready to restore or share. What is this for? If you’re building and managing multiple automations inside n8n, losing a workflow due to accidental deletion or misconfiguration can cost you hours of work. This template solves that by exporting all your workflows into separate files and storing them in a dated Google Drive folder. It helps with disaster recovery, version tracking, and team collaboration — without any manual exporting. How this works: -Once triggered (manually or via a schedule), the workflow performs the following steps: -Creates a new folder in your Google Drive, named with today’s date (e.g. “Workflow Backups Monday 16-05-2025”). -Connects to your n8n instance using the internal API and retrieves a list of all existing workflows. -Iterates over each workflow, converts it into a .json file using the built-in file conversion node. -Uploads each individual .json file to the newly created folder in Google Drive. -Optionally, the workflow finds and deletes old backup folders to keep your Google Drive clean and avoid clutter. You get a clean, timestamped folder with all your flows — ready to restore, send, or store securely. You can trigger it manually or schedule it (e.g., to run weekly on Monday mornings). How to set it up: Import the provided workflow JSON into your n8n instance. Set up your credentials: -Replace the placeholder “Google demo” with your actual Google Drive OAuth2 credentials in all Google Drive nodes. -Replace the placeholder “n8n demo” with your n8n API credentials so the workflow can fetch your flows. -Go to the node “Create new folder” and replace the folder ID with your own destination folder in Google Drive where backups should be stored. -(Optional) Enable the “Schedule Trigger” to run the backup automatically once a week or on your preferred interval. You’re ready to go — test it with the Manual Trigger first and check your Google Drive for results.
Fetch dynamic prompts from GitHub and auto-populate n8n expressions in prompt
Who Is This For? This workflow is designed for AI engineers, automation specialists, and content creators who need a scalable system to dynamically manage prompts stored in GitHub. It eliminates manual updates, enforces required variable checks, and ensures that AI interactions always receive fully processed prompts. --- 🚀 What Problem Does This Solve? Manually managing AI prompts can be inefficient and error-prone. This workflow: ✅ Fetches dynamic prompts from GitHub ✅ Auto-populates placeholders with values from the setVars node ✅ Ensures all required variables are present before execution ✅ Processes the formatted prompt through an AI agent --- 🛠 How This Workflow Works This workflow consists of three key branches, ensuring smooth prompt retrieval, variable validation, and AI processing. --- 1️⃣ Retrieve the Prompt from GitHub (HTTP Request → Extract from File → SetPrompt) The workflow starts manually or via an external trigger. It fetches a text-based prompt stored in a GitHub repository. The Extract from File Node retrieves the content from the GitHub file. The SetPrompt Node stores the prompt, making it accessible for processing. 📌 Note: The prompt must contain n8n expression format variables (e.g., {{ $json.company }}) so they can be dynamically replaced. --- 2️⃣ Extract & Auto-Populate Variables (Check All Prompt Vars → Replace Variables) A Code Node scans the prompt for placeholders in the n8n expression format ({{ $json.variableName }}). The workflow compares required variables against the setVars node: ✅ If all variables are present, it proceeds to variable replacement. ❌ If any variables are missing, the workflow stops and returns an error listing them. The Replace Variables Node replaces all placeholders with values from setVars. 📌 Example of a properly formatted GitHub prompt: Hello {{ $json.company }}, your product {{ $json.features }} launches on {{ $json.launch_date }}. This ensures seamless replacement when processed in n8n. --- 3️⃣ AI Processing & Output (AI Agent → Prompt Output) The Set Completed Prompt Node stores the final, processed prompt. The AI Agent Node (Ollama Chat Model) processes the prompt. The Prompt Output Node returns the fully formatted response. 📌 Optional: Modify this to use OpenAI, Claude, or other AI models. --- ⚠️ Error Handling: Missing Variables If a required variable is missing, the workflow stops execution and provides an error message: ⚠️ Missing Required Variables: ["launch_date"] This ensures no incomplete prompts are sent to AI agents. --- ✅ Example Use Case 📜 GitHub Prompt File (Using n8n Expressions) Hello {{ $json.company }}, your product {{ $json.features }} launches on {{ $json.launch_date }}. 🔹 Variables in setVars Node json { "company": "PropTechPro", "features": "AI-powered Property Management", "launch_date": "March 15, 2025" } ✅ Successful Output Hello PropTechPro, your product AI-powered Property Management launches on March 15, 2025. 🚨 Error Output (If Missing launch_date) ⚠️ Missing Required Variables: ["launch_date"] --- 🔧 Setup Instructions 1️⃣ Connect Your GitHub Repository Store your prompt in a public or private GitHub repo. The workflow will fetch the raw file using the GitHub API. 2️⃣ Configure the SetVars Node Define the required variables in the SetVars Node. Make sure the variable names match those used in the prompt. 3️⃣ Test & Run Click Test Workflow to execute. If variables are missing, it will show an error. If everything is correct, it will output the fully formatted prompt. --- ⚡ How to Customize This Workflow 💡 Need CRM or Database Integration? Connect the setVars node to an Airtable, Google Sheets, or HubSpot API to pull variables dynamically. 💡 Want to Modify the AI Model? Replace the Ollama Chat Model with OpenAI, Claude, or a custom LLM endpoint. --- 📌 Why Use This Workflow? ✅ No Manual Updates Required – Fetches prompts dynamically from GitHub. ✅ Prevents Broken Prompts – Ensures required variables exist before execution. ✅ Works for Any Use Case – Handles AI chat prompts, marketing messages, and chatbot scripts. ✅ Compatible with All n8n Deployments – Works on Cloud, Self-Hosted, and Desktop versions.
Clone viral TikTok & Instagram reels with Apify and Gemini 2.5 Pro
Reverse engineer short-form videos from Instagram and TikTok using Gemini AI Who's it for Content creators, AI video enthusiasts, and digital marketers who want to analyze successful short-form videos and understand their production techniques. Perfect for anyone looking to reverse-engineer viral content or create detailed prompts for AI video generation tools like Google Veo or Sora. How it works This automation takes any Instagram Reel or TikTok URL and performs a forensic analysis of the video content. The workflow downloads the video, converts it to base64, and uses Google's Gemini 2.5 Pro vision API to generate an extremely detailed "Generative Manifest" - a comprehensive prompt that could be used to recreate the video with AI tools. The analysis includes: Visual medium identification (film stock, camera sensor, lens characteristics) Color grading and lighting breakdown Shot-by-shot deconstruction with precise timing Camera movement and framing details Subject description and action choreography Environmental and atmospheric details How to set up Configure API credentials: Add your Apify API key for video scraping Set up Google Gemini API authentication Set up Slack integration (optional): Configure Slack OAuth for result sharing Update the channel ID where results should be posted Access the form: The workflow creates a web form where you can input video URLs Form accepts both Instagram Reel and TikTok URLs Requirements Apify account with API access for video scraping Google Cloud account with Gemini API enabled Slack workspace (optional, for sharing results) Videos must be publicly accessible (no private accounts) How to customize the workflow Modify the analysis prompt: Edit the "setbaseprompt" node to adjust the depth and focus of the video analysis Add different platforms: Extend the switch node to handle other video platforms Integrate with other tools: Replace Slack with email, Discord, or other notification systems
Generate 360° virtual try-on videos for clothing with Kling API (unofficial)
What's the workflow used for? Leverage this Kling API (unofficial) provided by PiAPI workflow to streamline virtual try-on video creation. This tool is designed for e-commerce platforms, fashion brands, content creators and content influencers. By uploading model and clothing images and linking PiAPI account, users can swiftly generate a realistic video of the model sporting the outfit with a 360° turn, offering an immersive viewing experience. Step-by-step Instruction For basic settings of virtual try-on, check API doc to get best practice. Fill in your X-API-Key of your PiAPI account in Preset Parameters node. Upload the model photo and provide target clothing image urls. Click Test Workflow to generate virtual try-on image. Get the video output in the final node. Param Settings If you want to change into a dress, input the modelinput URL and the dressinput URL in the parameters. If you want to change into separates, input modelinput URL, upperinput URL and lower_input URL in Preset Parameters. Use Case Input images: Output Video <video src="https://static.piapi.ai/n8n-instruction/virtual-try-on/example1.mp4" controls /> The output demonstrates that the model is wearing the clothing from the specified image and showcases a rotating runway-style view. This workflow enables you to efficiently test garment-on-model presentation effects while reducing business model validation costs to a certain extent.
Generate AI images in bulk with Freepik, Google Sheets & Drive
This n8n workflow automates bulk AI image generation using Freepik's Text-to-Image API. It reads prompts from a Google Sheet, generates multiple variations of each image using Freepik's AI, and automatically uploads the results to Google Drive with organized file names. This is perfect for content creators, marketers, or designers who need to generate multiple AI images in bulk and store them systematically. Key Features: Bulk image generation from Google Sheets prompts Multiple variations per prompt (configurable duplicates) Automatic file naming and organization Direct upload to Google Drive Batch processing for efficient API usage Freepik AI-powered image generation Step-by-Step Implementation Guide Prerequisites Before setting up this workflow, you'll need: n8n instance (cloud or self-hosted) Freepik API account with Text-to-Image access Google account with access to Sheets and Drive Google Sheet with your prompts Step 1: Set Up Freepik API Credentials Go to Freepik API Developer Portal Create an account or sign in Navigate to your API dashboard Generate an API key for Text-to-Image service Copy the API key and save it securely In n8n, go to Credentials → Add Credential → HTTP Header Auth Configure as follows: Name: "Header Auth account" Header Name: x-freepik-api-key Header Value: Your Freepik API key Step 2: Set Up Google Credentials Google Sheets Access: Go to Google Cloud Console Create a new project or select existing one Enable Google Sheets API Create OAuth2 credentials In n8n, go to Credentials → Add Credential → Google Sheets OAuth2 API Enter your OAuth2 credentials and authorize with spreadsheets.readonly scope Google Drive Access: In Google Cloud Console, enable Google Drive API In n8n, go to Credentials → Add Credential → Google Drive OAuth2 API Enter your OAuth2 credentials and authorize Step 3: Create Your Google Sheet Create a new Google Sheet: sheets.google.com Set up your sheet with these columns: Column A: Prompt (your image generation prompts) Column B: Name (identifier for file naming) Example data: | Prompt | Name | |-------------------------------------------|-------------| | A serene mountain landscape at sunrise | mountain-01 | | Modern office space with natural lighting | office-02 | | Cozy coffee shop interior | cafe-03 | Copy the Sheet ID from the URL (the long string between /d/ and /edit) Step 4: Set Up Google Drive Folder Create a folder in Google Drive for your generated images Copy the Folder ID from the URL when viewing the folder Note: The workflow is configured to use a folder called "n8n workflows" Step 5: Import and Configure the Workflow Copy the provided workflow JSON In n8n, click Import from File or Import from Clipboard Paste the workflow JSON Configure each node as detailed below: Node Configuration Details: Start Workflow (Manual Trigger) No configuration needed Used to manually start the workflow Get Prompt from Google Sheet (Google Sheets) Document ID: Your Google Sheet ID (from Step 3) Sheet Name: Sheet1 (or your sheet name) Operation: Read Credentials: Select your "Google Sheets account" Double Output (Code Node) Purpose: Creates multiple variations of each prompt JavaScript Code: javascript const original = items[0].json; return [ { json: { ...original, run: 1 } }, { json: { ...original, run: 2 } }, ]; Customization: Add more runs for additional variations Loop (Split in Batches) Processes items in batches to manage API rate limits Options: Keep default settings Reset: false Create Image (HTTP Request) Method: POST URL: https://api.freepik.com/v1/ai/text-to-image Authentication: Generic → HTTP Header Auth Credentials: Select your "Header Auth account" Send Body: true Body Parameters: Name: prompt Value: ={{ $json.Prompt }} Split Responses (Split Out) Field to Split Out: data Purpose: Separates multiple images from API response Convert to File (Convert to File) Operation: toBinary Source Property: base64 Purpose: Converts base64 image data to file format Upload Image to Google Drive (Google Drive) Operation: Upload Name: =Image - {{ $('Get Prompt from Google Sheet').item.json.Name }} - {{ $('Double Output').item.json.run }} Drive ID: My Drive Folder ID: Your Google Drive folder ID (from Step 4) Credentials: Select your "Google Drive account" Step 6: Customize for Your Use Case Modify Duplicate Count: Edit the "Double Output" code to create more variations Update File Naming: Change the naming pattern in the Google Drive upload node Adjust Batch Size: Modify the Loop node settings for your API limits Add Image Parameters: Enhance the HTTP request with additional Freepik parameters (size, style, etc.) Step 7: Test the Workflow Ensure your Google Sheet has test data Click Execute Workflow on the manual trigger Monitor the execution flow Check that images are generated and uploaded to Google Drive Verify file names match your expected pattern Step 8: Production Deployment Set up error handling for API failures Configure appropriate batch sizes based on your Freepik API limits Add logging for successful uploads Consider webhook triggers for automated execution Set up monitoring for failed executions Freepik API Parameters Basic Parameters: prompt: Your text description (required) negative_prompt: What to avoid in the image guidance_scale: How closely to follow the prompt (1-20) numinferencesteps: Quality vs speed trade-off (20-100) seed: For reproducible results Example Enhanced Body: json { "prompt": "{{ $json.Prompt }}", "negative_prompt": "blurry, low quality", "guidance_scale": 7.5, "numinferencesteps": 50, "num_images": 1 } Workflow Flow Summary Start → Manual trigger initiates the workflow Read Sheet → Gets prompts and names from Google Sheets Duplicate → Creates multiple runs for variations Loop → Processes items in batches Generate → Freepik API creates images from prompts Split → Separates multiple images from response Convert → Transforms base64 to binary file format Upload → Saves images to Google Drive with organized names Complete → Returns to loop for next batch Contact Information Robert A Ynteractive For support, customization, or questions about this workflow: 📧 Email: rbreen@ynteractive.com 🌐 Website: https://ynteractive.com/ 💼 LinkedIn: https://www.linkedin.com/in/robert-breen-29429625/ Need help implementing this workflow or want custom automation solutions? Get in touch for professional n8n consulting and workflow development services.