{"product_id":"n8n-workflow-sync-hubspot-contacts-from-gmail-auto-replies","title":"n8n Workflow: Sync HubSpot Contacts from Gmail Auto-Replies","description":"\u003ch3\u003eAutomatically detect when leads leave or go out of office—and route HubSpot updates for approval\u003c\/h3\u003e\n\u003cp\u003eThis n8n workflow scans Gmail hourly for auto-replies and permanent bounces, uses Anthropic Claude to detect whether a contact has \u003cem\u003eleft the company\u003c\/em\u003e or is \u003cem\u003eout of office\u003c\/em\u003e, and then posts Slack approvals before updating your HubSpot contacts with accurate lead status changes, CRM notes, replacement contacts, and follow-up tasks.\u003c\/p\u003e\n\n\u003ch3\u003eWhat this workflow does\u003c\/h3\u003e\n\u003cul\u003e\n  \u003cli\u003e\n\u003cstrong\u003eRuns every hour\u003c\/strong\u003e and loads settings such as lookback window, approval timeout, and the target Slack channel.\u003c\/li\u003e\n  \u003cli\u003e\n\u003cstrong\u003eValidates the HubSpot app token\u003c\/strong\u003e and required scopes before accessing any email data.\u003c\/li\u003e\n  \u003cli\u003e\n\u003cstrong\u003eSearches Gmail\u003c\/strong\u003e for recent auto-replies and bounce messages, \u003cstrong\u003ededuplicates\u003c\/strong\u003e results across runs, and selects the most relevant reply per contact.\u003c\/li\u003e\n  \u003cli\u003e\n\u003cstrong\u003eChecks HubSpot\u003c\/strong\u003e for a matching contact (by sender or bounced address). It skips emails that aren’t tied to an existing contact or contacts already marked with your configured \u003cem\u003eleft\u003c\/em\u003e lead status.\u003c\/li\u003e\n  \u003cli\u003e\n\u003cstrong\u003eUses Anthropic Claude\u003c\/strong\u003e to classify the message as \u003cem\u003eleft_company\u003c\/em\u003e, \u003cem\u003eout_of_office\u003c\/em\u003e, or \u003cem\u003eother\u003c\/em\u003e, extracting supporting quotes and replacement details when present.\u003c\/li\u003e\n  \u003cli\u003e\n\u003cstrong\u003eBuilds a safe update plan\u003c\/strong\u003e and routes outcomes:\n    \u003cul\u003e\n      \u003cli\u003ePosts \u003cstrong\u003e“left company”\u003c\/strong\u003e cases and \u003cstrong\u003epermanent bounces\u003c\/strong\u003e to \u003cstrong\u003eSlack\u003c\/strong\u003e for approval.\u003c\/li\u003e\n      \u003cli\u003eCreates \u003cstrong\u003eHubSpot follow-up tasks\u003c\/strong\u003e for validated out-of-office return dates.\u003c\/li\u003e\n      \u003cli\u003ePosts informational Slack alerts when HubSpot lookup errors occur.\u003c\/li\u003e\n    \u003c\/ul\u003e\n  \u003c\/li\u003e\n  \u003cli\u003e\n\u003cstrong\u003eAfter Slack approval\u003c\/strong\u003e (within the configured window), writes the planned updates to HubSpot (lead status change + CRM note, and optional replacement contact) and posts a summary of what succeeded.\u003c\/li\u003e\n\u003c\/ul\u003e\n\n\u003ch3\u003eUse cases\u003c\/h3\u003e\n\u003cul\u003e\n  \u003cli\u003eKeep \u003cstrong\u003eHubSpot lead statuses\u003c\/strong\u003e accurate when Gmail auto-replies indicate a contact left the company.\u003c\/li\u003e\n  \u003cli\u003eHandle \u003cstrong\u003epermanent bounces\u003c\/strong\u003e by routing “lost” contacts to Slack for confirmation before updating CRM.\u003c\/li\u003e\n  \u003cli\u003eAutomatically create \u003cstrong\u003efollow-up tasks\u003c\/strong\u003e when a contact returns from out-of-office.\u003c\/li\u003e\n\u003c\/ul\u003e\n\n\u003ch3\u003eTechnical details\u003c\/h3\u003e\n\u003cul\u003e\n  \u003cli\u003e\n\u003cstrong\u003en8n nodes\/logic:\u003c\/strong\u003e if, set, code, gmail, slack, switch\u003c\/li\u003e\n  \u003cli\u003e\n\u003cstrong\u003eIntegrations:\u003c\/strong\u003e Gmail (auto-replies + permanent bounces), HubSpot (contact lookup + lead status updates, CRM notes, tasks), Slack (approval workflow + alerts), Anthropic Claude (classification and quote extraction)\u003c\/li\u003e\n\u003c\/ul\u003e","brand":"N8N Commerce","offers":[{"title":"Default Title","offer_id":46289007673523,"sku":"N8N-21671","price":34.99,"currency_code":"GBP","in_stock":true}],"thumbnail_url":"\/\/cdn.shopify.com\/s\/files\/1\/0749\/6279\/6723\/files\/TmBZZZe9_oS_JutIw9IVy_DQvlXoZM.png?v=1793005917","url":"https:\/\/buyflowscripts.com\/products\/n8n-workflow-sync-hubspot-contacts-from-gmail-auto-replies","provider":"N8N Commerce","version":"1.0","type":"link"}