Project Details
Product Tour
THL Lead Intelligence & CRM Platform
THL Lead Intelligence & CRM is a private, internal B2B lead-generation and sales platform for The Hires Lab. It finds US real estate wholesalers and agents who are likely buyers of THL's cold-calling VA service. It enriches and scores each one against three buyer profiles, removes duplicates, and routes the results to marketers as a daily calling queue. It then tracks everything that happens next: call dispositions, lead submissions and approvals, email campaigns, attendance and payroll, and reporting. It replaces 4–6 hours of manual lead research per person, every day.
I designed and built it end to end. The backend is a Laravel 11 REST API (26 controllers, 30 models, ~65 migrations) with Sanctum cookie auth and TOTP multi-factor auth. Permissions use ability-based RBAC rather than a fixed role ladder: across 4 roles, every backend route and every frontend nav entry goes through a single hasAbility() check, and team-lead data scoping is enforced at the query level. A full audit log records every action.
Enrichment runs asynchronously on Redis queues, drained in priority order (search → enrich → skip-trace → default) under a global rate limit, with tiered caching: 7 days for activity signals, 30 days for skip-trace and deed data. A Node / Playwright headless-Chrome microservice collects Google Maps listings, county deed records (FL/TX), website signals and skip-trace data, with retry loops and graceful degradation when a county source is geo-blocked. The results feed a rules-based scoring engine: a quality gate, an operator-probability model and a buyer-profile classifier (solo mid-level, beginner, small team) that assigns an explainable 1–5 priority.
On the sales side, marketers submit leads and prospects through an approval workflow. The first submitter wins, using duplicate detection on normalized phone numbers, and nothing is written to the leads table until a team lead approves it. The email stack has templates with a variable resolver, campaigns, trigger-based automation rules, open/click tracking and a pluggable email-verification layer. Operations features cover shifts, attendance, payroll details, a meeting calendar, and team and individual performance reports.
The data layer handles ~400k lead records in a 63-column PostgreSQL 16 table, plus CSV/dialer ingestion with per-row validation, a streaming XLSX exporter, two-way Google Sheets sync, and bulk imports of public records (Sunbiz, tax roll, voter file, TX corp). I ran k6 load tests (smoke, marketer journey, breakpoint) against a written capacity model and fixed the bottlenecks they found in the 15-second poll cycle: missing indexes, N+1 queries and oversized list payloads. The whole system runs as 7 Docker Compose services and deploys to a production VPS through GitHub Actions, with ~37 PHPUnit feature tests covering auth, authorization, team scoping and the submission workflow.