Global Lead Processing Platform

A centralized intake and routing system for marketing leads collected across multiple brands and regional markets.

Node.jsTypeScriptGCP Pub/SubPostgreSQLRedisDockerTerraform
Duration
18 months
Team
6 engineers
Role
Senior Frontend & Integration Engineer

Overview

This platform handles the end-to-end lifecycle of marketing leads generated across multiple brands and regional markets. Leads arrive from web forms, landing pages, and third-party ad channels. The system validates, enriches, deduplicates, and routes them to downstream CRM and sales systems.

Problem

The company operated with fragmented lead collection: each campaign had its own form handler, database writes were ad hoc, and downstream CRM integrations were duplicated across services. This led to data inconsistency, missed leads during high-traffic periods, and significant maintenance overhead each time a new market or brand went live.

Solution

We designed a centralized intake API as the single point of entry for all lead data. The API validates incoming payloads against per-brand schemas, applies deduplication logic via a Redis cache, and publishes events to a GCP Pub/Sub topic. Downstream consumers handle CRM writes, email notification triggers, and data warehouse ingestion independently and at their own pace — decoupling intake from processing.

Your Role

I was responsible for the frontend intake layer — the form infrastructure capturing lead data across landing pages — and for defining the API contract between the frontend and the intake service. I designed the TypeScript SDK used by all frontend consumers, defined the validation schema format in collaboration with the backend team, and contributed to integration tests for the intake endpoint.

Architecture

  • Intake API (Node.js / TypeScript): Validates payloads, checks deduplication via Redis, publishes to Pub/Sub
  • Frontend SDK (TypeScript): Lightweight wrapper for form submissions with retry logic and error normalization
  • GCP Pub/Sub: Decouples intake from downstream processing, enabling independent scaling
  • CRM Consumer: Subscribes to Pub/Sub and writes to Salesforce via REST
  • Data Warehouse Consumer: Streams validated leads to BigQuery for analytics
  • PostgreSQL: Stores raw lead records and full audit trail
  • Redis: Short-TTL deduplication cache to prevent duplicate CRM entries

Impact

The platform handles thousands of leads per day across multiple markets. Lead loss during traffic spikes dropped after introducing the async processing model. Frontend teams across brands adopted the TypeScript SDK, reducing integration time for new campaigns from days to hours. A single schema registry replaced five independently maintained form handlers.