{"product_id":"fanbase-dm-lead-capture-automation-n8n-apify-google-sheets","title":"FanBase DM Lead Capture Automation (n8n, Apify, Google Sheets)","description":"\u003ch3\u003eTurn FanBase DM purchase intent into tracked leads automatically\u003c\/h3\u003e\n\u003cp\u003eThis n8n workflow scans your FanBase Copilot DMs every 15 minutes for purchase-intent messages, enriches the matching fans via FanBase MCP + Apify Instagram scraping, and writes (or updates) clean lead records in Google Sheets—using a saved watermark so you never re-scan the same messages.\u003c\/p\u003e\n\n\u003ch3\u003eWhat this workflow does\u003c\/h3\u003e\n\u003cul\u003e\n  \u003cli\u003e\n\u003cstrong\u003eRuns on a schedule:\u003c\/strong\u003e Executes every 15 minutes.\u003c\/li\u003e\n  \u003cli\u003e\n\u003cstrong\u003eReads a timestamp watermark:\u003c\/strong\u003e Uses an n8n data table to store the last processed time. On the first run, it falls back to scanning the last 24 hours.\u003c\/li\u003e\n  \u003cli\u003e\n\u003cstrong\u003eQueries FanBase MCP for new DM activity:\u003c\/strong\u003e Fetches events since the watermark using the FanBase MCP OAuth2 credential (for \u003cspan\u003ehttps:\/\/api.copilot.fanbase.gg\/mcp\u003c\/span\u003e).\u003c\/li\u003e\n  \u003cli\u003e\n\u003cstrong\u003eFilters DM events + detects purchase intent:\u003c\/strong\u003e Keeps DM-only events, identifies intent via keyword matching, and maintains \u003cem\u003eone lead per fan\u003c\/em\u003e (including a reply link for the conversation).\u003c\/li\u003e\n  \u003cli\u003e\n\u003cstrong\u003eUpdates the watermark:\u003c\/strong\u003e Writes back the new “last seen” timestamp so only newer messages are processed next time.\u003c\/li\u003e\n  \u003cli\u003e\n\u003cstrong\u003eEnriches using FanBase CRM data:\u003c\/strong\u003e Pulls two pages of FanBase MCP CRM data, merges them, and joins each intent lead to its profile to resolve the fan’s handle and profile URL.\u003c\/li\u003e\n  \u003cli\u003e\n\u003cstrong\u003eScrapes Instagram details with Apify:\u003c\/strong\u003e Runs \u003cstrong\u003eapify\/instagram-profile-scraper\u003c\/strong\u003e for each resolved handle to retrieve profile information (e.g., bio, follower count, external links).\u003c\/li\u003e\n  \u003cli\u003e\n\u003cstrong\u003eUpserts into Google Sheets:\u003c\/strong\u003e Builds a normalized lead record (including an extracted email when available) and appends or updates the row in the \u003cstrong\u003eLeads\u003c\/strong\u003e tab using \u003cstrong\u003efan_id\u003c\/strong\u003e as the unique key.\u003c\/li\u003e\n\u003c\/ul\u003e\n\n\u003ch3\u003eUse cases\u003c\/h3\u003e\n\u003cul\u003e\n  \u003cli\u003eSaaS operators capturing warm leads from purchase-intent DMs without manual triage\u003c\/li\u003e\n  \u003cli\u003eAutomation engineers maintaining a “single source of truth” CRM-style sheet fed by FanBase conversations\u003c\/li\u003e\n  \u003cli\u003eBrands qualifying inbound interest and enriching prospects with Instagram context automatically\u003c\/li\u003e\n\u003c\/ul\u003e\n\n\u003ch3\u003eTechnical details\u003c\/h3\u003e\n\u003cul\u003e\n  \u003cli\u003e\n\u003cstrong\u003eIntegrations:\u003c\/strong\u003e FanBase MCP (OAuth2), Apify (\u003cstrong\u003eapify\/instagram-profile-scraper\u003c\/strong\u003e), Google Sheets\u003c\/li\u003e\n  \u003cli\u003e\n\u003cstrong\u003en8n components\/nodes:\u003c\/strong\u003e code, merge, data table, sticky note, google sheets, apifyn8n-nodes-apify (Apify node)\u003c\/li\u003e\n  \u003cli\u003e\n\u003cstrong\u003eWorkflow state:\u003c\/strong\u003e n8n data table with string columns \u003cem\u003ekey\u003c\/em\u003e and \u003cem\u003evalue\u003c\/em\u003e for the watermark read\/write steps\u003c\/li\u003e\n\u003c\/ul\u003e","brand":"N8N Commerce","offers":[{"title":"Default Title","offer_id":45850683375795,"sku":"N8N-18123","price":3.99,"currency_code":"GBP","in_stock":true}],"thumbnail_url":"\/\/cdn.shopify.com\/s\/files\/1\/0749\/6279\/6723\/files\/X4FtwDe7XjOhltmh5dfCg_SA956G0b.png?v=1786871437","url":"https:\/\/buyflowscripts.com\/products\/fanbase-dm-lead-capture-automation-n8n-apify-google-sheets","provider":"N8N Commerce","version":"1.0","type":"link"}