How it works
What this system does
This package coordinates seven n8n workflows to recover open proposals that have gone quiet. HubSpot holds current deal and contact records. PostgreSQL stores processing state, approvals, idempotency keys, and audit history. Import all seven workflows separately; the preview shows only workflow 01.
Detect, draft, and route
The daily detector searches configured proposal stages for proposals aged five to seven days. It checks summary activity timestamps with a 15-minute proposal-send grace period, contact suppression, associations, and prior follow-up state. Ambiguous cases go to manual review. Email and CRM-email proposals can use SMTP; LinkedIn, WhatsApp, SMS, and manual channels produce owner tasks rather than sending through those services.
The planner generates a deterministic personalized draft first. Optional AI enhancement is disabled by default and falls back to that draft if its response fails validation. High-value deals require human approval before entering the send queue. The supplied threshold is 25,000; review it against your deal values and currency conventions.
Revalidate before delivery
The sender fetches fresh CRM records immediately before delivery. Changed stages, recent activity, changed proposal dates or email addresses, opt-outs, and do-not-contact flags block sending. All workflows import inactive and send_enabled is false. SMTP uses one configured verified mailbox, not automatically the assigned salesperson's mailbox.
The SMTP node has no automatic retry. Stale or ambiguous SENDING cases become SEND_REVIEW_REQUIRED and must be reconciled manually, avoiding automatic resend. Reply events use stable UUIDs to avoid duplicate notes and tasks, mark the deal re-engaged, and notify its owner through a high-priority CRM task.
Validation status
The supplied report covers static structure, code syntax, timing rules, routing, and guards. Live n8n execution, PostgreSQL DDL, HubSpot calls, SMTP delivery, and optional AI generation were not tested. Complete sandbox acceptance before enabling delivery.
How to use
Before you start
You need n8n, PostgreSQL, HubSpot access for deals, contacts, companies, tasks and notes, and a verified SMTP mailbox. OpenAI is optional. Assign an owner for review tasks and confirm the exact permissions in your HubSpot account.
1. Download and import
Download and extract the complete ZIP. Read README.md and validation-report.txt. Import each of the seven .n8n.json files separately and keep them inactive. SQL, property definitions, sample requests, and the report are supporting files, not n8n imports.
2. Configure storage and credentials
Review and run database-setup.sql in the database designated for this package. Attach PostgreSQL credentials to every database node. Attach HubSpot Header Auth with header Authorization and value Bearer YOUR_TOKEN. Configure the verified SMTP credential in workflow 04 and separate Header Auth credentials for approval and reply endpoints. Store secrets in n8n credentials.
3. Prepare CRM fields and configuration
Inspect hubspot-proposal-properties.json and run workflow 06 manually once. Your proposal process must populate revops_proposal_sent_at, revops_proposal_channel, and the draft context fields. Replace every REPLACE_ placeholder. Set internal HubSpot proposal stage IDs in both workflows 01 and 04; stage labels are not API IDs. Configure portal ID, public n8n URL, high_value_threshold, verified from_email, and from_name. Review schedule timing and max_results against your volume; the supplied detector limits a search to 100 results.
Set workflow 07 as the error workflow for workflows 01, 02, 04, and 05. These workflows coordinate through shared PostgreSQL state; importing them does not configure credentials or activate their schedules.
4. Test detection and drafting with sending disabled
Keep send_enabled:false in workflow 04 and use_ai:false in workflow 02. Use sandbox deals to check the five-to-seven-day window, recent activity, ownership, contact and company associations, multiple open company deals, opt-outs, missing channels, and existing follow-up state. Confirm manual channels create tasks and never attempt channel delivery. Review the actual subject and body before rollout.
The activity checks use HubSpot summary properties. If your process tracks customer activity elsewhere, extend the authoritative timestamp checks in the imported workflow code and revalidate. The README mentions ghosted-logic.js, but no separate file with that name is included in this upload.
5. Review high-value cases
On your n8n host, GET /webhook/revops-li-007-pending with the approval credential. Review the case and draft. Adapt sample-approval-request.json and POST to /webhook/revops-li-007-approval with case_id, approval_token, decision APPROVE or REJECT, approver_email, and a note. Tokens expire after seven days and rotate after a decision. Use n8n's displayed test URLs when testing webhooks before activation. Confirm expired and replayed tokens cannot authorize delivery.
6. Connect reply events
Configure your inbound email provider, channel parser, or a HubSpot workflow to POST authenticated events to /webhook/revops-li-007-reply. Adapt sample-reply-event.json with a stable event_id UUID, deal_id, contact_id, reply_at, channel, and bounded summary. The package does not connect your inbox automatically. Replay the same event to verify it creates no duplicate note or task. Confirm the deal is marked re-engaged and the owner task appears.
7. Validate delivery and roll out
Confirm the supplied HubSpot note/task association IDs in your portal during acceptance testing. Test SMTP from the verified mailbox and review sender identity. If every salesperson needs a separate sender, implement and test an owner-to-mailbox mapping or dedicated mail-provider nodes first.
Only after acceptance of timing, suppression, associations, approvals, and message content should you set send_enabled:true and activate the required detector, planner, approval, sender, reply, and operations workflows. Keep workflow 06 manual. Investigate SEND_REVIEW_REQUIRED against mailbox delivery evidence before taking further action; do not blindly resend an ambiguous case.
Optional AI enhancement
Configure OpenAI Header Auth, replace REPLACE_OPENAI_MODEL with an available structured-output model, and set use_ai:true in workflow 02. Test both valid responses and failure fallback with approved CRM context before rollout.
Related systems
Use the GA4 & HubSpot Lead Attribution System as a separately configured companion system.
Use the HubSpot Duplicate Detection & Approved Merge System as a separately configured companion system.
Use the HubSpot Intelligent Lead Routing & Response System as a separately configured companion system.
Website links connect the documentation; they do not connect credentials or workflows. Verify shared HubSpot field ownership and record references before combining packages. Read the Revenue Operations Intelligence blueprint and Lead Routing blueprint for the wider operating model.