Screen contact activity from CSV with MCP client and OpenAI gpt-4o-mini
Quick Overview This workflow manually processes a contacts CSV, fetches website/Facebook/Instagram page text via an MCP browser endpoint, then uses OpenAI to classify each contact as active, inactive, or uncertain and writes the results to an output CSV.
How it works Starts manually and reads a contacts CSV file from the local filesystem. Parses the CSV into individual contact records and processes them in batches. For each contact, builds browser automation steps to visit the provided website, Facebook, and Instagram URLs (when present) and extract visible page text through an MCP Client endpoint. Cleans and aggregates the scraped text per channel and constructs an evidence-based screening prompt. Sends the prompt to OpenAI (gpt-4o-mini) to return a JSON verdict (active/inactive/uncertain) with confidence and reasoning. Formats one output row per contact (including evidence excerpts and timestamps) and writes all results to a CSV file, aborting if an unexpected runaway loop produces too many rows.
Setup Add your OpenAI API credentials and confirm the model selection in the OpenAI node. Set up and run an MCP endpoint reachable at the configured URL (default: http://localhost:8931/mcp) and ensure it supports the browser_navigate, browser_wait_for, and browser_evaluate tools. Update the input CSV path and output CSV path to valid locations for your n8n host, and ensure the input columns match the expected fields (e.g. name, website_url, facebook_url, instagram_url). Adjust the maximum expected row limit in the safety check code if you plan to process larger batches.
Related Templates
Get Airtable data via AI and Obsidian Notes
I am submitting this workflow for the Obsidian community to showcase the potential of integrating Obsidian with n8n. Whi...
Use OpenRouter in n8n versions <1.78
What it is: In version 1.78, n8n introduced a dedicated node to use the OpenRouter service, which lets you to use a lot...
AI SEO Readability Audit: Check Website Friendliness for LLMs
Who is this for? This workflow is designed for SEO specialists, content creators, marketers, and website developers who ...
🔒 Please log in to import templates to n8n and favorite templates
Workflow Visualization
Loading...
Preparing workflow renderer
Comments (0)
Login to post comments