Project-link backfills
Linked HubSpot deals to their Zuper projects and moved each deal’s jobs into one project, with a dry run, a landed check and a one-command revert per batch.
Data paths and guards
- HubSpot: Deals and tickets that were missing their link to a Zuper project.
- Snapshots and reverts: Before and after snapshots, and a generated revert script for every batch.
- Backfill tooling: 108 Python scripts across three generations: match, dry run, apply, verify and revert.
- Zuper: Jobs, projects and customers in each contractor’s field-service account.
- From HubSpot to Backfill tooling: Deals and tickets. Deals and tickets missing their Zuper project link, read in batches. A backfill run.
- From Zuper to Backfill tooling: Jobs and projects. Jobs, projects and customers, indexed for matching. A backfill run.
- From Backfill tooling to HubSpot: Project links. The Zuper project number and link written to each matched deal and ticket. A batch that passed its dry run.
- From Backfill tooling to Zuper: Jobs moved into one project. Jobs moved into the deal’s project, and the empty projects left behind deleted. A consolidation batch.
- From Backfill tooling to Snapshots and reverts: Before, after, revert. Snapshots of every record a batch touches, before and after, and its revert script. Every batch that writes.
- On Project links: Dry run, then 5 records. Every run defaults to a dry run, and a live batch writes 5 records before the rest.
- On Jobs moved into one project: Every write read back. Each write is read back and counted only once it has landed, because an empty update to a Zuper project clears every job’s link.
- On Before, after, revert: Revert script per batch. Each batch keeps before and after snapshots and generates its own revert script.
- Built by me
- Platforms I connect to
- Guards
- Active
| Deals and tickets Deals and tickets missing their Zuper project link, read in batches |
|---|
| Jobs and projects Jobs, projects and customers, indexed for matching |
| Project links The Zuper project number and link written to each matched deal and ticket |
| Jobs moved into one project Jobs moved into the deal’s project, and the empty projects left behind deleted |
| Before, after, revert Snapshots of every record a batch touches, before and after, and its revert script |
-
Systems
Each contractor sells in HubSpot and runs its crews in Zuper, but many deals and tickets were missing their link to the Zuper project. Between the two sits Python tooling that matches, writes, verifies and can revert every batch.
-
Data paths
The tooling reads deals and tickets from HubSpot and jobs and projects from Zuper, matches them in tiers and writes each project link back to HubSpot. In Zuper it moves jobs into the deal’s project and deletes the empty projects left behind.
- a Deals and tickets
- b Jobs and projects
- c Project links
- d Jobs moved into one project
- e Before, after, revert
-
Guards
Runs default to dry runs and start with 5 records. Every write is read back before it counts, and every batch keeps before and after snapshots with its own revert script.
- Dry run, then 5 records on c
- Every write read back on d
- Revert script per batch on e
-
Result
832 deals across three contractors were linked to their Zuper projects, 265 jobs moved into their deal’s project and 166 empty projects deleted, and a re-audit of one portal found 0 defects.
What I built
- Three generations of Python tooling, 108 scripts across 4 directories, with every run defaulting to a dry run.
- Matching in tiers: title and due date, with a tolerance for a consistent one-day offset, then external id, email and phone.
- Every batch: a smoke run on 5 records first, before and after snapshots, a check that each write landed and a generated revert script.
- Consolidation tools that move a deal’s jobs into its one Zuper project, then delete the empty projects left behind.
- An independent verification battery that re-derives the backfills, and a playbook checked against every run’s artifacts.
What the guards protect against
| The risk | The guard |
|---|---|
| A wrong match is written across a whole portal at once. | Dry run, then 5 records Every run defaults to a dry run, and a live batch writes 5 records before the rest. |
| A write reports success but never landed, or strips a project’s jobs. | Every write read back Each write is read back and counted only once it has landed, because an empty update to a Zuper project clears every job’s link. |
| A bad batch cannot be undone. | Revert script per batch Each batch keeps before and after snapshots and generates its own revert script. |
Results
- 832 deals across three contractors linked to their Zuper projects.
- 265 jobs moved into their deal’s project and 166 empty projects deleted, for two contractors.
- An independent re-audit of one contractor’s portal found 0 defects.
- For a fourth contractor, 206 ticket rollups and 236 job-id backfills, then a consistency check at 327 of 327.
Facts
- Backfill rates: 412 of 488 deals in one portal, and 227 of 248 with 0 mismatches in another
- In one portal, 51 deals were brought to one project each, and its projects went from 892 to 748
- In another portal, 42 jobs moved and its projects went from 430 to 408
Related builds
-
Field-service rollout
Date: Jul 2026
Fact: 4 job types, with up to 15 gated statuses and 131 checklist fields
Client: For a commercial roofing contractor
Systems: Zuper and Dataforma
Status: In production
-
Two-way ERP sync
Date: Aug 2026
Fact: 11,598 deals linked to the ERP
Client: For a commercial roofing contractor
Systems: Dataforma
Status: In production
-
Per-trade deal budgets
Date: Feb 2026
Fact: Revenue, material and labor budgets across 11 trades
Client: For a residential roofing and exteriors contractor
Systems: SumoQuote and Zuper
Status: In production