by Paul
AI Database Assistant with Smart Query's & PostgreSQL Integration Description: ๐ Transform Your Database into an Intelligent AI Assistant This workflow creates a smart database assistant that safely handles natural language queries without crashing your system. Features dual-agent architecture with built-in query limits and PostgreSQL optimization โ perfect for commercial applications! โ Ideal for: SaaS developers building database search features ๐ Database administrators providing safe AI access ๐ก๏ธ Business teams needing user-friendly data queries ๐ Anyone wanting ChatGPT-like database interaction ๐ค ๐ง How It Works 1๏ธโฃ User asks a question โ "Show me top 10 popular products" 2๏ธโฃ Main AI Agent โ Interprets the request and ensures safety limits 3๏ธโฃ SQL Sub-Agent โ Generates precise PostgreSQL queries 4๏ธโฃ Database executes โ Returns formatted, limited results safely โก Setup Instructions 1๏ธโฃ Prepare Your Database Ensure PostgreSQL is accessible from n8n Note your table structure and column names Set up database connection credentials 2๏ธโฃ Customize the Templates Replace [YOUR_TABLE_NAME] with your actual table name Update [YOUR_FIELDS] with your column names Modify examples to match your use case Important**: Keep all LIMIT clauses intact! 3๏ธโฃ Configure the Agents Copy Main Agent system message to your primary AI node Copy Sub-Agent system message to your SQL generator node Connect the sub-workflow between both agents 4๏ธโฃ Test & Deploy Test with sample queries like "Show me 5 recent items" Verify query limits work (max 50 results) Deploy and monitor performance ๐ฏ Why Use This Workflow? โ๏ธ System Protection โ Built-in limits prevent crashes from large queries โ๏ธ Natural Language โ Users ask questions in plain English โ๏ธ Commercial Ready โ Generic templates work with any database โ๏ธ Dual-Agent Safety โ Smart interpretation + precise SQL generation โ๏ธ PostgreSQL Optimized โ Handles complex schemas and data types ๐จ Critical Features Query Limits**: Default 10, maximum 50 results (can be modified) Error Prevention**: No unlimited data retrieval Smart Routing**: Natural language โ Safe SQL โ Formatted results Customizable**: Works with any PostgreSQL database schema ๐ Start building your AI database assistant today โ safe, smart, and scalable!
by Max Tkacz
Who is this for This workflow is perfect for teams and individuals who manage extensive data in Notion and need a quick, AI-powered way to interact with their databases. If you're looking to streamline your knowledge management, automate searches, and get faster insights from your Notion databases, this workflow is for you. Itโs ideal for support teams, project managers, or anyone who needs to query specific data across multiple records or within individual pages of their Notion setup. Check out the Notion template this Assistant is set up to use: https://www.notion.so/templates/knowledge-base-ai-assistant-with-n8n How it works The Notion Database Assistant uses an AI Agent built with Retrieval-Augmented Generation (RAG) to query this Knowledge Base style Notion database. The assistant can search across multiple properties like tags or question and retrieves content from inside individual Notion pages for additional context. Key features include: Querying the database with flexible filters. Searching within individual Notion pages and extracting relevant blocks. Providing a reference link to the exact Notion pages used to inform its responses, ensuring transparency and easy verification. This assistant uses two HTTP request toolsโone for querying the Notion database and another for pulling data from within specific pages. It streamlines knowledge retrieval, offering a conversational, AI-driven way to interact with large datasets. Set up Find basic set up instructions inside the workflow itself or watch a quickstart video ๐
by Automate With Marc
This workflow contains community nodes that are only compatible with the self-hosted version of n8n. ๐ง Perplexity-Powered Daily AI News Digest (via Telegram) This ready-to-deploy n8n workflow automates the entire process of collecting, filtering, formatting, and distributing daily AI industry news summaries directly to your Telegram group or channel. Powered by Perplexity and OpenAI, it fetches only high-signal AI updates from trusted sources (e.g. OpenAI, DeepMind, HuggingFace, MIT Tech Review), filters out duplicates based on a Google Sheet archive, and delivers beautifully formatted news directly to your team โ every morning at 10AM. For more such build and step-by-step tutorials, check out: https://www.youtube.com/@Automatewithmarc ๐ Key Features: Perplexity AI Integration: Automatically fetches the most relevant AI developments from the last 24 hours. AI Formatter Agent: Cleans the raw feed, removes duplicates, adds summaries, and ensures human-friendly formatting. Google Sheets Log: Tracks previously reported news items to avoid repetition. Telegram Delivery: Sends a polished daily digest straight to your chat, ready for immediate team consumption. Customizable Scheduling: Preconfigured for daily use, but can be modified to fit your team's preferred cadence. ๐ผ Ideal For: Anyone who wants to stay ahead of fast-moving AI trends with zero manual effort ๐ ๏ธ Tech Stack: Perplexity AI OpenAI (GPT-4 or equivalent) Google Sheets Telegram API โ Setup Notes: Youโll need to connect your own OpenAI, Perplexity, Google Sheets, and Telegram credentials. Replace the Google Sheet ID and Telegram channel settings with your own.
by InfoGrab
This is a response chatbot in public channels through slash commands. I explain more in detail through the YouTube video, but it's only available in Korean. How it works? When you request the created slash command in Slack, the request comes to the webhook. Then, the Switch Node branches appropriately according to each slash command request. Here, a slash command called /ask is connected to the chatbot, and the chatbot generates answers to the questions asked. The final node responds to the channel. Set up steps Create a Slack app. Add chat:write permission in Slack OAuth&Permissions>Scopes. Create a Command in Slack Slash Commands menu and enter the n8n Webhook node's URL. Complete creating the Slash Commands. Enter the created command in the Switch node. ์ฌ๋์ ์ปค๋งจ๋๋ฅผ ํตํ ๊ณต๊ฐ ์ฑ๋์์์ ์๋ต ์ฑ๋ด ์ ๋๋ค. ์ ํ๋ธ ์์์ ๋ ์์ธํ๊ฒ ์ค๋ช ๋๋ฆฝ๋๋ค. ์ค๋ช ์ฌ๋์ ์์ฑํ ์ฌ๋์ ์ปค๋งจ๋๋ฅผ ์ฌ๋์์ ์์ฒญํ๋ฉด ์นํ ์ ์์ฒญ์ด ๋ค์ด์ต๋๋ค. ์ดํ Switch Node์์ ๊ฐ ์ฌ๋์ ์ปค๋งจ๋์ ์์ฒญ์ ๋ฐ๋ผ ์๋ง๊ฒ ๋ถ๊ธฐํฉ๋๋ค. ์ฌ๊ธฐ์์๋ /askโ๋ผ๋ ์ฌ๋์ ์ปค๋งจ๋๊ฐ ์ฑ๋ด์ผ๋ก ์ฐ๊ฒฐ๋์ด ์๊ณ , ์ฑ๋ด์์ ์ง๋ฌธํ ๋ด์ฉ์ ๋ต๋ณ์ ์์ฑํฉ๋๋ค. ๋ง์ง๋ง ๋ ธ๋์์ ์ฑ๋๋ก ์๋ต์ ํฉ๋๋ค. ์ค์ ๋ฐฉ๋ฒ Slack ์ฑ์ ๋ง๋์ธ์. Slack OAuth&Permissions>Scopes ์์ chat:write ๊ถํ์ ์ถ๊ฐํ์ธ์. Slack Slash Commands ๋ฉ๋ด์์ Command๋ฅผ ์์ฑํ๊ณ , n8n Webhook ๋ ธ๋์ url์ ์ ๋ ฅํ์ธ์. Slash Slash Commands ์์ฑ์ ์๋ฃํ์ธ์. Switch ๋ ธ๋์ ์์ฑํ ์ปค๋งจ๋๋ฅผ ์ ๋ ฅํ์ธ์.
by Aashiq
๐ค Whoโs it for This workflow is for content creators, marketers, educators, or anyone who wants to instantly summarize YouTube videos and repurpose them into different formats (LinkedIn post, tweet, etc.) via a simple Telegram chatbot. โ๏ธ How it works This n8n automation listens for messages in Telegram. If the message contains a YouTube link, it: Extracts the video ID Fetches the video transcript using RapidAPI Cleans the transcript of any special characters Sends it to OpenAI to generate a summary If the message is not a link, it simply acts as an AI chatbot using OpenAI with memory support. โ Supports follow-up prompts like: โMake it shorterโ โTurn this into a LinkedIn postโ โCreate a tweet threadโ ๐งโ๐คโ๐ง Multi-User Support This Telegram bot supports multiple users simultaneously. It tracks memory and context separately for each user using Telegram's unique chat_id. โ Each user gets personalized AI replies โ Follow-up commands work per user โ No interference between users ๐ ๏ธ Requirements A Telegram bot token (get via @BotFather) An OpenAI API Key (from https://platform.openai.com/account/api-keys) A RapidAPI Key and Host (typically youtube-transcript3.p.rapidapi.com) > ๐จ API keys must be added manually โ they are not included in the template. ๐งฉ How to Set It Up Configure the Telegram Trigger node with your bot token. In the HTTP Request node, set: X-RapidAPI-Key: your RapidAPI key X-RapidAPI-Host: your RapidAPI host URL Add your OpenAI API credentials to the AI Agent node. Use the provided sticky notes for guidance inside the workflow itself. ๐๏ธ How to Customize Modify AI prompt behavior in the AI Agent node Change the text formatting in the Code node Use a different transcript API if preferred Add commands like make it into a blog post, summarize in bullet points, etc. ๐ Notes All nodes are renamed to reflect their function API credentials are removed for security Includes colored boxes and sticky notes to guide the user Compatible with n8n cloud and self-hosted setups
by Joseph
This n8n workflow automates SEO keyword research by querying the Ahrefs API for keyword data and related keyword insights. The enriched data is then processed by an AI agent to format a response and provide valuable SEO recommendations. Perfect for SEO specialists, content marketers, digital agencies, and anyone looking to gain valuable insights into keyword opportunities to boost their rankings. โ๏ธ How This Workflow Works This workflow guides you through the entire SEO keyword research process, from entering the initial keyword to receiving detailed insights and related keyword suggestions. 1. ๐ฃ๏ธ User Input (Keyword Query) The user enters a keyword they want to research. This input is captured by the Chat Input Node, ready for analysis. 2. ๐ค AI Agent (Input Verification) The AI Agent reviews the keyword input for any grammatical errors or extra commentary. If necessary, it cleans the input to ensure a seamless query to the API. 3. ๐ Ahrefs API (Keyword Data Retrieval) The cleaned keyword is sent to the Ahrefs Keyword Tool API. This retrieves a detailed report including metrics like search volume, keyword difficulty, and CPC. 4. ๐ก Related Keywords Extraction (Using JavaScript Function) The workflow uses a JavaScript function to extract main keyword data and 10 related keywords data from the Ahrefs response. You can tweak the script to adjust the number of related keywords or the level of detail you want. 5. ๐ง AI Agent (Text Formatting) The aggregated data, including both the main keyword and related keywords, is sent to an AI agent. The AI agent formats the data into a concise, readable format that can be shared with the user. 6. ๐จ Final Response The formatted text is delivered to the user with keyword insights, recommendations, and related keyword suggestions. โ Smart Retry & Error Handling Each subworkflow includes a fail-safe mechanism to ensure: โ Proper error handling for any issues with the API request. ๐ Failed API requests are retried after a customizable period (e.g., 2 hours or 1 day). ๐ฌ User input validation prevents any incorrect or malformed queries from being processed. ๐ Ahrefs API Setup To use this workflow, youโll need to set up your Ahrefs API credentials: ๐ Ahrefs API Sign up for an Ahrefs account and get your key here: Ahrefs Keyword Tool API Once signed up, you'll receive an API key, which youโll use in the x-rapidapi-key header in n8n. Ensure you check the Ahrefs Keyword Tool API documentation for more details on available parameters. ๐ฅ How to Import This Workflow Copy the json code. Open your n8n instance. Open a new workflow. Paste anywhere inside the workflow. Voila. ๐ ๏ธ Customization Options Adjust the number of related keywords extracted (default is 10). Customize the AI agent response formatting or add specific recommendations for users. Modify the JavaScript function to extract different metrics from the Ahrefs API. ๐งช Use Case Example Trying to optimize your blog post around a specific keyword? Query a broad keyword, like โSEO tipsโ. Get related keyword data and search volume insights. Use the AI agent to provide keyword recommendations and additional topics to target. ๐ฅ Boost your content strategy with fresh keywords and relevant search data!
by Lucas Walter
Who's it for This workflow is perfect for directory site creators, content managers, and developers who need to automatically find and select the highest quality favicon or logo for websites they're showcasing. Instead of manually hunting down brand assets or settling for blurry default icons, this workflow does the heavy lifting by fetching multiple options and using AI to pick the best one. How it works The workflow takes a website URL and domain as input, then intelligently fetches favicon images from three different sources: Google's Favicon API - Gets the site's actual favicon Logo.dev - Provides high-quality brand logos Clearbit - Alternative logo source for business websites Once all images are collected, the workflow uses OpenAI's vision model to analyze each icon based on: Image quality and resolution (minimum 256x256) Brand authenticity (avoiding generic framework icons) Visual clarity without artifacts or blur Professional presentation suitable for directory listings The AI assigns quality scores from 0.0 to 1.0, and the workflow automatically returns the URL of the highest-scoring favicon. Requirements OpenAI API key (for image analysis) Logo.dev API key (free tier available) How to set up Configure API credentials: Add your OpenAI API key to n8n credentials Sign up for Logo.dev and add your API token The Clearbit and Google APIs require no authentication Test the workflow: Use the pinned test data (Fyxer AI example) or replace with your own Ensure all HTTP nodes can successfully fetch images Verify the AI analysis is working by checking the quality scores Customize input format: Modify the workflow trigger to accept your preferred input format Adjust the domain extraction logic if needed for your use case How to customize the workflow For different quality criteria: Edit the AI prompt in the "analyze_each_icon" node to emphasize different aspects (transparency, size, style preferences) For additional favicon sources: Add more HTTP Request nodes pointing to other favicon/logo APIs Update the merge node to handle additional inputs Modify the final URL construction logic to handle new sources For batch processing: Wrap this workflow in a loop to process multiple websites at once Add error handling for failed requests or AI analysis timeouts The workflow is designed to be reliable and handles errors gracefully - if one favicon source fails, it continues with the available options and still provides the best result possible.
by Sebastian/OptiLever
Who's it for This workflow is designed for users who want to implement iterative AI-powered content improvement processes. It's ideal for content creators, marketers, product managers, and anyone who needs to refine ideas through multiple rounds of critique and enhancement until they meet quality standards. How it works The workflow creates a sophisticated feedback loop using three specialized AI agents that work together to continuously improve content. Starting with an initial input (like a product description), the system generates ideas and then enters a reasoning loop where: A Critic Agent analyzes the current output and identifies flaws or areas for improvement A Refiner Agent takes the original input plus the critic's feedback to create enhanced versions An Evaluator Agent assesses the refined output and determines if it meets the quality threshold The loop continues until either the evaluator determines the output is satisfactory or a maximum number of iterations is reached (configurable, default is 5 turns). How to set up Configure the initial AI agent to generate your starting content Set up the loop structure with "Reset Loop" enabled in the loop node options Configure three AI agents within the loop: Critic: Provide detailed analysis prompts for identifying improvements Refiner: Create prompts that incorporate feedback to enhance content Evaluator: Define quality criteria and decision-making logic Add Edit Fields nodes at the beginning and end of the loop to maintain data structure Include a Code node to track iteration count and loop control Set up the IF node to check exit conditions (max turns or completion status) Requirements n8n workflow environment Access to AI/LLM nodes (OpenAI, Anthropic, etc.) Basic understanding of JSON data structures Configured AI model credentials How to customize the workflow Customize the system prompts for each agent based on your specific use case. The critic should focus on your quality criteria, the refiner should understand your improvement goals, and the evaluator should have clear success metrics. Adjust the maximum iteration count in the code node and IF condition based on your complexity needs and token budget considerations.
by Jimleuk
This n8n template watches an outlook shared inbox for support messages and creates an equivalent issue item in JIRA. How it works A scheduled trigger fetches recent Outlook messages from an shared inbox which collects support requests. These support requests are filtered to ensure they are only processed once and their HTML body is converted to markdown for easier parsing. Each support request is then triaged via an AI Agent which adds appropriate labels, assesses priority and summarises a title and description of the original request. Finally, the AI generated values are used to create an issue in JIRA to be actioned. How to use Ensure the messages fetched are solely support requests otherwise you'll need to classify messages before processing them. Specify the labels and priorities to use in the system prompt of the AI agent. Requirements Outlook for incoming support OpenAI for LLM JIRA for issue management Customising this workflow Consider automating more steps after the issue is created such as attempting issue resolution or capacity planning.
by assert
Who this template is for This template is for every engineer who wants to automate their code reviews or just get a 2nd opinion on their PR. How it works This workflow will automatically review your changes in a Gitlab PR using the power of AI. It will trigger whenever you comment with +0 to a Gitlab PR, get the code changes, analyze them with GPT, and reply to the PR discussion. Set up Steps Set up webhook of note_events in Gitlab repository (see here on how to do it) Configure ChatGPT credentials Note "+0" in MergeRequest to trigger automatic review by ChatGPT
by Tarek Mustafa
Who is this for? Jira users who want to automate the generation of a Lessons Learned or Retrospective report after an Epic is Done. What problem is this workflow solving? / use case Lessons Learned / Retrospective reports are often omitted in Agile teams because they take time to write. With the use of n8n and AI this process can be automated. What is this workflow doing Triggers automatically upon an Epic reaching the "Done" status in Jira. Collects all related tasks and comments associated with the completed Epic. Intelligently filters the gathered data to provide the LLM with the most relevant information. Utilizes an LLM with a structured System Message to generate insightful reports. Delivers the finalized report directly to your specified Google Docs document. Setup Create a Jira API key and follow the Credentials Setup in the Jira trigger node. Create credentials for Google Docs and paste your document ID into the Node. How to customize this workflow to your needs Change the System Message in the AI Agent to fit your needs.
by Airtop
Trump-o-meter: Extract and Evaluate Truth Social Posts Use Case Automatically extracting posts from Donald Trump's Truth Social account and estimating their potential impact on the U.S. stock market enables teams to monitor high-profile communications that may influence financial markets. This automation streamlines intelligence gathering for analysts, traders, and policy observers. What This Automation Does This automation retrieves up to 3 posts from Donald Trump's Truth Social profile and outputs structured information including: Author name Image URL Post text Post URL Estimated stock market impact: Direction: positive, negative, or neutral Magnitude: None, Small, Medium, Large How It Works Creates a browser session on Truth Social using an Airtop profile. Navigates to https://truthsocial.com/@realDonaldTrump. Uses a natural language prompt with a defined JSON schema to extract structured data for up to 3 posts. Splits the results into individual post items. Filters posts that contain actual content and have a non-zero estimated market impact. Sends selected posts and impact summaries to a Slack channel. Terminates the browser session to clean up. Setup Requirements Airtop API Key โ free to generate. An Airtop Profile that is connected and logged into Truth Social. A Slack workspace and authorized app with write permissions to a target channel. Next Steps Integrate with Trading Signals**: Link output to financial alert systems or dashboards for timely insights. Expand Monitoring**: Extend to other high-impact accounts (e.g., politicians, CEOs). Enhance Analysis**: Add sentiment scoring or topic classification for deeper context. Legal Disclaimer This tool is intended solely for informational and analytical purposes. The market impact estimations provided are speculative and should not be construed as financial advice. Do not make investment decisions based on this automation. Always consult with a licensed financial advisor before making any trades. Read more about Trump-o-meter automation