← All work Internal tool

Cut lead research from a full day to zero

Type
Internal tool · my outreach
Date
May 2026
Stack
Python · Playwright · Claude Haiku · SQLite

The problem

I needed a steady flow of Canterbury business leads for cold outreach. The manual version was brutal: search a directory, copy a name, look up the website, find an owner, verify the email, score the lead, draft an email, log it, follow up.

A few hours every week, every week, before I'd done any actual outreach.

It was 100% structured work I was doing by hand because no off-the-shelf tool covered all 14 NZ-specific directories I wanted. Apollo and ZoomInfo don't index this market well; the ones that do charge enterprise prices.

What I built

A multi-stage pipeline that runs overnight on a laptop:

1. Scrape (14 sources). Playwright for the JavaScript-heavy directories, BeautifulSoup for the static ones. Each source is its own module.

2. Deduplicate. The same business appears across 3–5 directories, soft-matched on normalised name + suburb.

3. Enrich. Crawl each homepage and contact page, detect the tech stack, and send the text to Claude Haiku to extract owner, role, email and notes.

4. Verify. NZBN API for company status and director; SMTP RCPT verify each email; WHOIS on .co.nz domains.

5. Score. 18 weighted signals: email present, SMTP verified, owner found, NZ Ltd, GST registered, job software installed, hiring signal, and more.

6. Draft. For every lead scoring 6+, Claude drafts a personalised cold email citing a specific, verifiable signal about the business. A rule-checking pass rejects anything template-shaped before it can ship.

How it works

Sources (14) Dedupe → Enrich (Claude) → NZBN → SMTP verify → WHOIS Score (18 signals, 0–10) Draft email (Claude, score ≥ 6) ranked CSV + hot_leads CSV

Checkpoint/resume after each phase. If a run crashes it picks up from the last good step. 290 unit tests cover every pure function.

The result

6+ hours / week saved. 50+ qualified leads / week produced unattended. 2,700+ businesses scanned and scored to date. One overnight run after the July rebuild: 1,579 leads found, 649 with a verified email, 355 scoring hot (the run before it managed 199 and 7). ~$8 in API credits to build (Haiku is cheap). 290 unit tests mean it runs reliably and fails loudly.

It has since grown into a small CRM: send scheduling inside business hours, automatic follow-ups, bounce protection, one dashboard. The overnight pipeline feeds it; I approve what goes out.

Tech used

PythonPlaywrightBeautifulSoupClaude HaikuNZBN APISMTP verifySQLitepytest

Want something similar for your business?

Balu Premkumar, founder of Kove60-day warranty · pay the second half only on acceptance
Next case studyStop typing. Tell your machine what to do