Back to Integrations
integrationHTTP Request node
integrationMongoDB node

HTTP Request and MongoDB integration

Save yourself the work of writing custom integrations for HTTP Request and MongoDB and use n8n instead. Build adaptable and scalable Development, Core Nodes, and Data & Storage workflows that work with your technology stack. All within a building experience you will love.

How to connect HTTP Request and MongoDB

  • Step 1: Create a new workflow
  • Step 2: Add and configure nodes
  • Step 3: Connect
  • Step 4: Customize and extend your integration
  • Step 5: Test and activate your workflow

Step 1: Create a new workflow and add the first step

In n8n, click the "Add workflow" button in the Workflows tab to create a new workflow. Add the starting point – a trigger on when your workflow should run: an app event, a schedule, a webhook call, another workflow, an AI chat, or a manual trigger. Sometimes, the HTTP Request node might already serve as your starting point.

HTTP Request and MongoDB integration: Create a new workflow and add the first step

Step 2: Add and configure HTTP Request and MongoDB nodes

You can find HTTP Request and MongoDB in the nodes panel. Drag them onto your workflow canvas, selecting their actions. Click each node, choose a credential, and authenticate to grant n8n access. Configure HTTP Request and MongoDB nodes one by one: input data on the left, parameters in the middle, and output data on the right.

HTTP Request and MongoDB integration: Add and configure HTTP Request and MongoDB nodes

Step 3: Connect HTTP Request and MongoDB

A connection establishes a link between HTTP Request and MongoDB (or vice versa) to route data through the workflow. Data flows from the output of one node to the input of another. You can have single or multiple connections for each node.

HTTP Request and MongoDB integration: Connect HTTP Request and MongoDB

Step 4: Customize and extend your HTTP Request and MongoDB integration

Use n8n's core nodes such as If, Split Out, Merge, and others to transform and manipulate data. Write custom JavaScript or Python in the Code node and run it as a step in your workflow. Connect HTTP Request and MongoDB with any of n8n’s 1000+ integrations, and incorporate advanced AI logic into your workflows.

HTTP Request and MongoDB integration: Customize and extend your HTTP Request and MongoDB integration

Step 5: Test and activate your HTTP Request and MongoDB workflow

Save and run the workflow to see if everything works as expected. Based on your configuration, data should flow from HTTP Request to MongoDB or vice versa. Easily debug your workflow: you can check past executions to isolate and fix the mistake. Once you've tested everything, make sure to save your workflow and activate it.

HTTP Request and MongoDB integration: Test and activate your HTTP Request and MongoDB workflow

Scrape and store data from multiple website pages

This workflow allows extracting data from multiple pages website.

The workflow:

  1. Starts in a country list at https://www.theswiftcodes.com/browse-by-country/.
  2. Loads every country page (https://www.theswiftcodes.com/albania/)
  3. Paginates every page in the country page.
  4. Extracts data from the country page.
  5. Saves data to MongoDB.
  6. Paginates through all pages in all countries.

It uses getWorkflowStaticData('global') method to recover the next page (saved from the previous page), and it goes ahead with all the pages.

There is a first section where the countries list is recovered and extracted.

Later, I try to read if a local cache page is available and I recover the cached page from the disk.

Finally, I save data to MongoDB, and we paginate all the pages in the country and for all the countries.

I have applied a cache system to save a visited page to n8n local disk. If I relaunch workflow, we check if a cache file exists to discard non-required requests to the webpage.

If the data present in the website changes, you can apply a Cron node to check the website once per week.

Finally, before inserting data in MongoDB, the best way to avoid duplicates is to check that swift_code (the primary value of the collection) doesn't exist.

I recommend using a proxy for all requests to avoid IP blocks. A good solution for proxy plus IP rotation is scrapoxy.io.

This workflow is perfect for small data requirements. If you need to scrape dynamic data, you can use a Headless browser or any other service.

If you want to scrape huge lists of URIs, I recommend using Scrapy + Scrapoxy.

Nodes used in this workflow

Popular HTTP Request and MongoDB workflows

+4

University FAQ & Calendar Assistant with Telegram, MongoDB and Gemini AI

🤖 Interactive Academic Chatbot (Telegram + MongoDB) Overview 📋 This project is a template for building a complete academic virtual assistant using n8n. It connects to Telegram, answers frequently asked questions by querying MongoDB, keeps the community informed about key dates (via web scraping), and collects user feedback for continuous improvement. How It Works Architecture and Workflow ⚙️ n8n: Orchestration of 3 workflows (chatbot, scraping worker, announcer). Telegram: Frontend for user interaction and sending announcements. MongoDB: Centralized database for FAQs, academic calendar, and feedback logs. Web Scraping: HTTP Request and HTML Extract nodes to read the university's web calendar. Cron: For automatic periodic executions (daily and weekly). Core Processes 🧠 Real-time reception of user queries via Telegram. Querying MongoDB collections for FAQ answers and calendar dates. Daily scraping of the university website to keep the calendar updated. Instant logging of user feedback (👍/👎) in MongoDB. Proactive sending of weekly announcements to the Telegram channel. Key Benefits ✅ Complete automation of student communication 24/7. An always-accurate academic calendar database without manual intervention. A built-in continuous improvement system through user feedback. Proactive communication of important events to the entire community. Use Cases 💼 Automation of student support in universities, colleges, and institutions. A virtual assistant for any organization needing to manage FAQs and a dynamic calendar. An automated announcements channel to keep a community informed. Requirements 👨‍💻 n8n instance (self-hosted or cloud). Credentials for a Telegram Bot (obtained from @BotFather). Credentials for a MongoDB database (Connection URI). URL of the academic calendar to be scraped. Authors 👥 Doménica Amores Nicole Guevara Adrián Villamar Mentor: Jaren Pazmiño Applicants to the CIAP Polytechnic Artificial Intelligence Club
+6

Predictive Health Monitoring & Alert System with GPT-4o-mini

How It Works The system collects real-time wearable health data, normalizes it, and uses AI to analyze trends and risk scores. It detects anomalies by comparing with historical patterns and automatically triggers alerts and follow-up actions when thresholds are exceeded. Setup Steps Configure Webhook Endpoint - Set up webhook to receive data from wearable devices Connect Database - Initialize storage for health metrics and historical data Set Normalization Rules - Define data standardization parameters for different devices Configure AI Model - Set up health score calculation and risk prediction algorithms Define Thresholds - Establish alert triggers for critical health metrics Connect Notification Channels - Configure email and Slack integrations Set Up Reporting - Create automated report templates and schedules Test Workflow - Run end-to-end tests with sample health data Workflow Template Webhook → Store Database → Normalize Data → Calculate Health Score → Analyze Metrics → Compare Previous → Check Threshold → Generate Reports/Alerts → Email/Slack → Schedule Follow-up Workflow Steps Ingest real-time wearable data via webhook, store and standardize it, and use GPT-4 for trend analysis and risk scoring. Monitor metrics against thresholds, trigger SMS, email, or Slack alerts, generate reports, and schedule follow-ups. Setup Instructions Configure webhook, database, GPT-4 API, notifications, calendar integration, and customize alert thresholds. Prerequisites Wearable API, patient database, GPT-4 key, email SMTP, optional Slack/Twilio, calendar integration. Use Cases Monitor glucose for diabetics, track elderly vitals/fall risk, assess corporate wellness, and post-surgery recovery alerts. Customization Adjust risk algorithms, add metrics, integrate telemedicine. Benefits Early intervention reduces readmissions and automates 80% of monitoring tasks.
+2

Score DNS threats with VirusTotal, Abuse.ch, HashiCorp Vault and Gemini

Stop fighting alerts and start orchestrating intelligence. This workflow is a complete ecosystem designed to combat network threats in real-time. It transforms raw DNS logs into structured knowledge, leveraging Artificial Intelligence to make decisions that previously required hours of manual work by a SOC analyst. Real-World Problems it Solves: Manual Threat Analysis: Automates the process of verifying suspicious domains and IP addresses across multiple CTI sources simultaneously. Security Credential Management: Eliminates the risk of API key leaks through native integration with HashiCorp Vault. Alert Fatigue: Thanks to built-in filtering logic, the system only notifies you when the AI Threat Score exceeds 5 (Malicious/Critical). Data Fragmentation: Consolidates data from multiple CTI providers into a single, cohesive technical report. Core System Components: The workflow manages and communicates with the following elements of your infrastructure: Traffic Capture: Monitors passive DNS traffic to identify new Indicators of Compromise (IoCs). Secret Engine: HashiCorp Vault provides database credentials and API tokens dynamically during workflow execution. Intelligence Layer: Features three independent scanning branches: VirusTotal, Abuse_URLhaus, and Abuse_ThreatFox. AI Brain: Google Gemini AI acts as a "Senior Security Analyst," correlating data and generating verdicts in both English and Polish. Automated Response: An email notification system triggered exclusively for confirmed high-risk threats. Release v1.0.0 Highlights This release (available on https://github.com/lukaszFD/cyber-sentinel/releases) marks the first fully stable production-ready version of the system. Key features of this release: Full Ansible Orchestration: The entire stack—including Nginx, Vault, databases, and n8n—is deployed automatically using Ansible playbooks. Infrastructure as Code (IaC): Secure deployment based on Ansible Vault, requiring only the population of credentials and the presence of a .vault_pass file. Production-Ready: The system has been rigorously tested for stability in both Debian (Proxmox) and Raspberry Pi 5 environments. Documentation : https://lukaszfd.github.io/cyber-sentinel/
+5

Content farming - : AI-powered blog automation for WordPress

==🔥 Upgrade to V4== We’ve released Version 4 of our AI Powered Blog Automation workflow. We heard your complains and made a complete redesign built for serious content creators. ChatGPT 5, Inbound Links, Verified Outbound Links,YOAST seo integration, Company profile, higher SEO ranking, banner images using companys mascot, FAQ sections and conclusions, 35% cost reduction, 📝 Read the New Articles published by Content Farming v4 🛒 View the updated and improved v4 workflow 👻 No technical experience ? use Ghost.Blog Content Farming V2 AI Powered Blog Automation for WordPress This workflow automatically generates and publishes 10 blog posts per day to a WordPress site. It collects tech-related news articles, filters and analyzes them for relevance, expands them with research, generates SEO-optimized long-form articles using AI, creates a matching image using Leonardo AI, and publishes them via the WordPress REST API. Every step is tracked and stored in MongoDB for reference and performance tracking. You can see the demo results for the AI based articles here: Emp0 Articles How it works A scheduler runs daily to fetch the latest news from RSS feeds including BBC, TechCrunch, Wired, MIT Tech Review, HackerNoon, and others. The RSS data is normalized and filtered to include only articles published within the past 24 hours. Each article is passed through an OpenAI-powered classifier to check for relevance to predefined user topics like AI, robotics, or tech policy. Relevant articles are then aggregated, researched, and summarized with supporting sources and citations. An AI agent generates five long-tail SEO blog title ideas, ranks them by uniqueness and performance score, and selects the top one. A blog outline is created including H1 and H2 headers, keyword targeting, content structure, and featured snippet optimization. A full-length article (1000 to 1500 words) is generated based on the outline, with analogies, citations, examples, and keyword density maintained. SEO metadata is produced including meta title, description, image alt text, slug, and a readability audit. An AI-generated image is created based on the blog theme using Leonardo AI, enhanced for emotional storytelling and visual consistency. The blog article, metadata, and image are uploaded to WordPress as a draft, the image is attached, Yoast SEO metadata is set, and the article is published. All outputs including article versions, metadata, generation steps, and final blog URLs are stored in MongoDB to allow for future analytics and feedback. Requirements To run this project, you need accounts and API access for the following: | Tool | Purpose | Notes | |--------------|------------------------------------------------------------------|-----------------------------------------------------------------------| | OpenAI | Used for blog classification, generation, summarization, SEO | Around $0.20 per day, using GPT-4o-mini. Estimated monthly: $6 | | MongoDB | Stores data flexibly including drafts, titles, metadata, logs | Free tier on MongoDB Atlas offers 512 MB, enough for 64,000 articles | | Leonardo AI | Generates featured images for blog articles | $9 for 3500 credits, $5 monthly top-up needed for 300 images | | WordPress | Final publishing platform via REST API | Hosted on Hostinger for $15/year including domain | Setup Instructions Import the provided JSON file into your n8n instance. Configure these credentials in n8n: OpenAI API key MongoDB Atlas connection string HTTP Header Auth for Leonardo AI WordPress REST API credentials Modify the classifier and prompt nodes to reflect your preferred content themes. Adjust scheduler nodes if you want to change post frequency or publishing times. Run the n8n instance continuously using Docker, PM2, or hosted automation platform. Cost Estimate | Component | Daily Usage | Monthly Cost Estimate | |---------------|------------------------------|------------------------| | OpenAI | 10 posts per day | ~$6 | | Leonardo AI | 10 images per day (15 credits each) | ~$14 (9 base + 5 top-up) | | MongoDB | Free up to 512 MB | $0 | | WordPress | Hosting and domain | ~$1.25 | | Total | | ~$21/month | Observations and Learnings This system can scale daily article publishing with zero manual effort. However, current limitations include inconsistent blog length and occasional coherence issues. To address this, I plan to build a feedback loop within the workflow: An SEO Commentator Agent will assess keyword strength, structure, and discoverability. An Editor-in-Chief Agent will review tone, clarity, and narrative structure. Both agents will loop back suggestions to the content generator, improving each draft until it meets human-level standards. The final goal is to consistently produce high-quality, readable, SEO-optimized content that is indistinguishable from human writing.

Automated Upwork Job Alerts with MongoDB & Slack

Overview This automated workflow fetches Upwork job postings using Apify, removes duplicate job listings via MongoDB, and sends new job opportunities to Slack. Key Features: Automated job retrieval** from Upwork via Apify API Duplicate filtering** using MongoDB to store only unique jobs Slack notifications** for new job postings Runs every 20 minutes** during working hours (9 AM - 5 PM) This workflow requires an active Apify subscription to function, as it uses the Apify Upwork API to fetch job listings. Who is This For? This workflow is ideal for: Freelancers looking to track Upwork jobs in real time Recruiters automating job collection for analytics Developers who want to integrate Upwork job data into their applications What Problem Does This Solve? Manually checking Upwork for jobs is time-consuming and inefficient. This workflow: Automates job discovery based on your keywords Filters out duplicate listings, ensuring only new jobs are stored Notifies you on Slack when new jobs appear How the Workflow Works Schedule Trigger (Every 20 Minutes) Triggers the workflow at 20-minute intervals Ensures job searches are only executed during working hours (9 AM - 5 PM) Query Upwork for Jobs Uses Apify API to scrape Upwork job posts for specific keywords (e.g., "n8n", "Python") Find Existing Jobs in MongoDB Searches MongoDB to check if a job (based on title and budget) already exists Filter Out Duplicate Jobs The Merge Node compares Upwork jobs with MongoDB data The IF Node filters out jobs that are already stored in the database Save Only New Jobs in MongoDB The Insert Node adds only new job listings to the MongoDB collection Send a Slack Notification If a new job is found, a Slack message is sent with job details Setup Guide Required API Keys Upwork Scraper (Apify Token) – Get your token from Apify MongoDB Credentials – Set up MongoDB in n8n using your connection string Slack API Token – Connect Slack to n8n and set the channel ID (default: #general) Configuration Steps Modify search keywords in the 'Assign Parameters' node (startUrls) Adjust the Working Hours in the 'If Working Hours' node Set your Slack channel in the Slack node Ensure MongoDB is connected properly Adjust the 'If Working Hours' node to match your timezone and hours, or remove it altogether to receive notifications and updates constantly. How to Customize the Workflow Change keywords: update the startUrls in the 'Assign Parameters' node to track different job categories Change 'If Working Hours': Modify conditions in the IF Node to filter times based on your needs Modify Slack Notifications: Adjust the Slack message format to include additional job details Why Use This Workflow? Automated job tracking without manual searches Prevents duplicate entries in MongoDB Instant Slack notifications for new job opportunities Customizable – adapt the workflow to different job categories Next Steps Run the workflow and test with a small set of keywords Expand job categories for better coverage Enhance notifications by integrating Telegram, Email, or a dashboard This workflow ensures real-time job tracking, prevents duplicates, and keeps you updated effortlessly.
+8

Build a WhatsApp AI shopping bot with virtual try-on using Gemini and GPT

Build a WhatsApp AI shopping bot with virtual try-on using Gemini 📌 Overview This workflow fully automates your T-shirt store's WhatsApp shopping experience using GPT for intent detection, MongoDB Atlas for vector-based product search, Redis for session management, and Google Gemini for AI-powered virtual try-on. It automatically handles customer messages, finds relevant products, processes orders, and generates realistic try-on images — all inside WhatsApp, with no app or website required. Customers can search for T-shirts, place orders, and virtually try on items in a single conversation. Redis ensures fast product caching and session tracking. MongoDB Atlas stores the product catalog and orders. Google Sheets logs every order automatically. Gemini generates realistic try-on images from customer selfies. This workflow eliminates manual order handling, improves customer experience, and gives store owners full visibility into orders and product searches. ⚙️ How it works This workflow runs automatically when a customer sends a WhatsApp message. 🔍 Product search 💬 Receives the customer message via WhatsApp Business API 🧠 GPT classifies the intent as product search, recommendation, or general query ⚡ Checks Redis cache for existing results (TTL: 1 hour) 🔎 On a cache miss, runs MongoDB Atlas vector search using OpenAI embeddings 🛍️ Sends matching products as interactive WhatsApp cards with Order Now and Virtual Try-On buttons 🛒 Order flow 👆 Triggered when the customer taps the Order Now button 📦 AI agent fetches product details from MongoDB 🗃️ Creates a new order document in MongoDB 📊 Logs the order to Google Sheets automatically ✅ Sends an order confirmation message to the customer via WhatsApp 👗 Virtual try-on flow 👆 Triggered when the customer taps the Virtual Try-On button 💾 Stores the product ID in Redis (TTL: 10 minutes) 📸 Prompts the customer to send a clear front-facing selfie 🔍 Gemini validates that exactly one real person is in the photo 🖼️ Merges the product image and selfie and generates a realistic try-on image 📩 Sends the try-on result back to the customer via WhatsApp 🗑️ Clears the Redis context after delivery 🛠 Setup steps Import this workflow into n8n Connect your WhatsApp Business Cloud API credentials Connect your OpenAI API credentials (for embeddings and GPT model) Connect your Google Gemini API credentials Connect your MongoDB Atlas credentials and create a vector index named ShopingBot on the product collection Connect your Redis credentials Connect your Google Drive service account credentials Connect your Google Sheets service account credentials Import your product catalog with embeddings into the MongoDB product collection Activate the workflow The workflow will run automatically when customers send WhatsApp messages. 🚀 Features 🧠 AI-powered shopping 🤖 Automatically classifies customer intent using GPT 🔎 Semantic product search using OpenAI embeddings and MongoDB Atlas vector search ⚡ Redis caching for ultra-fast repeated search results (TTL: 1 hour) 💬 Interactive WhatsApp product cards with Order Now and Virtual Try-On buttons 🔄 Sliding window session memory (last 20 messages per user) 🛒 Order management 📦 Fully automated order creation saved to MongoDB 📊 Automatic order logging to Google Sheets 🤖 AI agent handles the complete order flow without manual input ✅ Instant order confirmation sent to the customer via WhatsApp 👗 Virtual try-on ✨ AI-powered try-on image generation using Google Gemini 📷 Selfie validation ensures exactly one real person is in the photo 🖼️ Product and selfie images resized and merged before generation 📩 Try-on result delivered directly in the WhatsApp conversation 🗑️ Redis TTL automatically clears try-on context after delivery 🔐 Security and reliability 🛡️ Advanced message validation with spam and XSS protection ❌ Unsupported message types rejected with friendly error messages 🔁 Retry logic on critical HTTP request nodes 📦 Modular workflow architecture for easy customisation and scaling 📋 Requirements You need the following accounts and credentials: 🔧 n8n 📱 WhatsApp Business Cloud API 🤖 OpenAI API (embeddings and GPT model) ✨ Google Gemini API 🍃 MongoDB Atlas (with vector index named ShoppingBot on the product collection) ⚡ Redis server 📁 Google Drive (service account) 📊 Google Sheets (service account) 🎯 Benefits 🚀 Fully automated WhatsApp shopping experience 🙌 No manual order handling required 👗 Customers can try on products before buying ⚡ Fast product search with Redis caching 📊 All orders automatically tracked in Google Sheets 💼 Reduces support workload for store owners 🕐 Works 24/7 without human intervention 👨‍💻 Author BytezTech Pvt Ltd

Build your own HTTP Request and MongoDB integration

Create custom HTTP Request and MongoDB workflows by choosing triggers and actions. Nodes come with global operations and settings, as well as app-specific parameters that can be configured. You can also use the HTTP Request node to query data from any app or service with a REST API.

MongoDB supported actions

Create
Drop
List
Update
Aggregate
Aggregate documents
Delete
Delete documents
Find
Find documents
Find And Replace
Find and replace documents
Find And Update
Find and update documents
Insert
Insert documents
Update
Update documents
Use case

Save engineering resources

Reduce time spent on customer integrations, engineer faster POCs, keep your customer-specific functionality separate from product all without having to code.

Learn more

FAQs

  • Can HTTP Request connect with MongoDB?

  • Can I use HTTP Request’s API with n8n?

  • Can I use MongoDB’s API with n8n?

  • Is n8n secure for integrating HTTP Request and MongoDB?

  • How to get started with HTTP Request and MongoDB integration in n8n.io?

Need help setting up your HTTP Request and MongoDB integration?

Discover our latest community's recommendations and join the discussions about HTTP Request and MongoDB integration.
Moiz Contractor
theo
Jon
Dan Burykin
João Textor

Looking to integrate HTTP Request and MongoDB in your company?

Over 3000 companies switch to n8n every single week

Why use n8n to integrate HTTP Request with MongoDB

Build complex workflows, really fast

Build complex workflows, really fast

Handle branching, merging and iteration easily.
Pause your workflow to wait for external events.

Code when you need it, UI when you don't

Simple debugging

Your data is displayed alongside your settings, making edge cases easy to track down.

Use templates to get started fast

Use 1000+ workflow templates available from our core team and our community.

Reuse your work

Copy and paste, easily import and export workflows.

Implement complex processes faster with n8n

red iconyellow iconred iconyellow icon