{"product_id":"n8n-postgresql-cdc-outbox-sync-to-hubspot-mailchimp-slack","title":"n8n PostgreSQL CDC Outbox Sync to HubSpot, Mailchimp \u0026 Slack","description":"\u003ch3\u003ePostgreSQL changes, synced to HubSpot, Mailchimp, and Slack—automatically every minute\u003c\/h3\u003e\n\u003cp\u003eThis n8n workflow monitors your PostgreSQL \u003ccode\u003ecdc_outbox\u003c\/code\u003e for INSERT\/UPDATE\/DELETE events and reliably delivers them to \u003cstrong\u003eHubSpot\u003c\/strong\u003e, \u003cstrong\u003eMailchimp\u003c\/strong\u003e, and \u003cstrong\u003eSlack\u003c\/strong\u003e on a \u003cstrong\u003e1-minute schedule\u003c\/strong\u003e—with leasing, retries (exponential backoff), dead-lettering, and a \u003cstrong\u003ewebhook requeue endpoint\u003c\/strong\u003e for failed events.\u003c\/p\u003e\n\n\u003ch3\u003eWhat this workflow does\u003c\/h3\u003e\n\u003cul\u003e\n  \u003cli\u003e\n\u003cstrong\u003eRuns every minute\u003c\/strong\u003e and loads sync settings like batch size, which targets are enabled, and retry\/backoff limits.\u003c\/li\u003e\n  \u003cli\u003e\n\u003cstrong\u003eClaims eligible rows\u003c\/strong\u003e from the PostgreSQL \u003ccode\u003ecdc_outbox\u003c\/code\u003e table using a \u003cstrong\u003elease\u003c\/strong\u003e so multiple workers can process safely while preserving \u003cstrong\u003eper-row ordering\u003c\/strong\u003e.\u003c\/li\u003e\n  \u003cli\u003e\n\u003cstrong\u003eExpands each change into delivery tasks\u003c\/strong\u003e for each enabled target:\n    \u003cul\u003e\n      \u003cli\u003e\n\u003cstrong\u003eHubSpot\u003c\/strong\u003e: upsert delivery (as configured)\u003c\/li\u003e\n      \u003cli\u003e\n\u003cstrong\u003eMailchimp\u003c\/strong\u003e: member sync and unsubscribe handling\u003c\/li\u003e\n      \u003cli\u003e\n\u003cstrong\u003eSlack\u003c\/strong\u003e: notification delivery for events\u003c\/li\u003e\n    \u003c\/ul\u003e\n  \u003c\/li\u003e\n  \u003cli\u003e\n\u003cstrong\u003eSends tasks sequentially\u003c\/strong\u003e via HTTP requests and records whether each call succeeded, failed temporarily, or failed permanently.\u003c\/li\u003e\n  \u003cli\u003e\n\u003cstrong\u003eUpdates event status back in PostgreSQL\u003c\/strong\u003e as delivered, scheduled for retry with \u003cstrong\u003eexponential backoff\u003c\/strong\u003e, or \u003cstrong\u003edead-lettered\u003c\/strong\u003e.\u003c\/li\u003e\n  \u003cli\u003e\n\u003cstrong\u003eDead-letter alerting\u003c\/strong\u003e: posts a Slack alert whenever events become dead.\u003c\/li\u003e\n  \u003cli\u003e\n\u003cstrong\u003eRequeue support\u003c\/strong\u003e: exposes \u003ccode\u003ePOST \/cdc-requeue\u003c\/code\u003e to reset dead-lettered event IDs back to pending and returns how many were requeued.\u003c\/li\u003e\n\u003c\/ul\u003e\n\n\u003ch3\u003eUse cases\u003c\/h3\u003e\n\u003cul\u003e\n  \u003cli\u003eKeep \u003cstrong\u003eHubSpot\u003c\/strong\u003e and \u003cstrong\u003eMailchimp\u003c\/strong\u003e contacts in sync with live PostgreSQL customer data.\u003c\/li\u003e\n  \u003cli\u003eSend \u003cstrong\u003eSlack\u003c\/strong\u003e notifications when customer records change or when delivery fails permanently.\u003c\/li\u003e\n  \u003cli\u003eOperationally recover from transient outages by requeuing dead-lettered events without rebuilding the pipeline.\u003c\/li\u003e\n\u003c\/ul\u003e\n\n\u003ch3\u003eTechnical details\u003c\/h3\u003e\n\u003cul\u003e\n  \u003cli\u003e\n\u003cstrong\u003ePrimary source\u003c\/strong\u003e: PostgreSQL \u003ccode\u003ecdc_outbox\u003c\/code\u003e with capture function and trigger (created during manual setup).\u003c\/li\u003e\n  \u003cli\u003e\n\u003cstrong\u003en8n components\u003c\/strong\u003e: if, set, code, no op, switch, webhook.\u003c\/li\u003e\n  \u003cli\u003e\n\u003cstrong\u003eTargets\u003c\/strong\u003e: HTTP-based delivery to \u003cstrong\u003eHubSpot\u003c\/strong\u003e, \u003cstrong\u003eMailchimp\u003c\/strong\u003e, and \u003cstrong\u003eSlack\u003c\/strong\u003e.\u003c\/li\u003e\n\u003c\/ul\u003e\n\u003cp\u003ePerfect for n8n users and automation engineers who need dependable PostgreSQL CDC syncing with robust retry and failure recovery.\u003c\/p\u003e","brand":"N8N Commerce","offers":[{"title":"Default Title","offer_id":46192867705011,"sku":"N8N-20461","price":21.99,"currency_code":"GBP","in_stock":true}],"thumbnail_url":"\/\/cdn.shopify.com\/s\/files\/1\/0749\/6279\/6723\/files\/FAsB-qWT_7eujh7Kr349d_m6QP3105.png?v=1791537760","url":"https:\/\/buyflowscripts.com\/products\/n8n-postgresql-cdc-outbox-sync-to-hubspot-mailchimp-slack","provider":"N8N Commerce","version":"1.0","type":"link"}