Project · WhatsApp lead-qualifier

A WhatsApp agent that answers, qualifies, and hands off.

Inbound leads cool off overnight — a message that lands at 11pm can wait until 9am for its first reply, by which time half the prospects have moved on. So we built a WhatsApp agent that answers in a founder’s voice, qualifies the lead, and hands off the warm ones to a real person. This is the build.

Type: WhatsApp lead-qualifier Surface: WhatsApp Business Cloud API Shape: 14-day build
Hero visual · system shape

Inbound message → founder-voice reply → warm handoff

Above-fold illustration of the conversational loop: WhatsApp Business Cloud webhook in → FastAPI handler → Claude (Sonnet) with founder-voice system prompt + SQLite conversation state → outbound reply → escalation flag → real person picks up the warm thread.

inbound webhook founder voice conversation state qualify warm handoff

The problem

The best leads type at 11pm. Nobody types back until morning.

This is the failure shape we built for. A high-intent inbound channel — organic referrals, paid ads, an alumni network — all funnelling into one WhatsApp number. On a busy day that’s dozens of first-touch messages, and a small team of human advisors who are excellent but also asleep at 11pm, which is exactly when high-intent prospects tend to message: after dinner, when they finally have a moment to think.

A typical first-touch message takes 20+ minutes of advisor time to qualify properly — pulling the context, the goal, the timeline, the budget tolerance, the level of involvement, whether they’ve already shopped a competitor. When that work waits until the next morning, the overnight messages get their first reply 10–14 hours later — and by then a chunk of the prospects have already gone elsewhere.

Off-the-shelf WhatsApp tools sell flows. Most of them can’t handle a real human who switches mid-sentence between a logistics question and an emotional one in a single message. That’s the kind of conversation a founder-voice agent has to hold.


What we built

A founder-voice agent that answers, qualifies, and knows when to step back.

The shape of the system is the boring shape. The thing that makes it actually work isn’t the architecture — it’s the persona. The first chunk of the work is reading a founder’s actual past WhatsApp conversations, pulling out the phrasing, the hard refusals, the warmth markers, the way a price question gets answered without pricing the conversation to death. That voice goes into the system prompt. The infrastructure underneath is what you’d expect.

  • WhatsApp Business Cloud APIInbound webhook + outbound Graph API v20.0. Direct, no middleware vendor. Verified business profile so messages stay inside the 24-hour customer-service window without template friction.
  • Anthropic Claude (Sonnet)Conversational engine. Founder-voice system prompt, knowledge file with the offering, pricing posture, and hard NOs. Structured output for qualification fields.
  • FastAPIAsync webhook handler, HMAC signature verification, per-user rate limiting, graceful shutdown. One process, single binary deploy.
  • SQLite (WAL mode)Conversation state, qualification fields, opt-out flags, retention timestamps. One file. Hourly snapshots. Restore is a single file copy.
  • DPDP-compliant conversation log30-day retention, first-turn consent gate, “forget me” phrase wired to a hard delete. Audit trail in append-only JSONL.
  • Handoff escalationStructured trigger from Claude: warm lead summary delivered to the advisor’s phone as a Telegram-formatted card the second a qualified lead crosses the threshold.

The whole thing runs on a single small VPS. Claude is the only paid surface. The monthly run cost is a coffee budget, not a software-vendor invoice. We share pricing in conversation.


The 14-day shape

How a build like this runs, day by day.

  1. Days 1–3 · Persona excavation Read a founder’s recent WhatsApp threads and pull out the phrasing they actually use for awkward moments — the pricing dodge, the “you’re not our fit” refusal, the warmth markers they lean on when someone is stressed. That becomes the first draft of the system prompt, then rounds of read-back where every line that sounds off gets marked.
  2. Days 4–7 · Cloud API setup + integration WhatsApp Business Cloud API verification, business profile setup, phone number provisioning. FastAPI webhook server, HMAC verification, the Graph API outbound client. First message round-trip by day 6, then a shadow test routing a slice of overflow through the agent in parallel.
  3. Days 8–10 · Hardening + DPDP compliance Rate limiter (token bucket, 5 burst plus sustained). First-turn consent gate — the agent has to weave the 30-day retention notice and the “forget me” phrase into its first reply naturally. Hard regex for opt-out phrases. Append-only audit log. Daily retention sweep that hard-deletes inactive conversations. The data flow gets signed off before anything goes live.
  4. Days 11–12 · Escalation tuning + handoff design Watch conversations come in. Every time a lead crosses the qualification threshold, a structured brief lands on the advisor’s personal WhatsApp — name, interest, urgency signal, tone, suggested opening line. The escalation trigger gets tuned against what’s actually warm vs noise.
  5. Days 13–14 · Cutover Full inbound number routed to the agent, with humans on standby for the first day. Early prompt tweaks land in the first 48 hours — softening a refusal pattern, widening a too-strict qualification threshold. After that, step back.

What the build delivers

What changes when an agent like this is in place.

We don’t have paying customers yet, so there are no client metrics to post here — we won’t invent them. What we can describe is what the system is built to do, and what we’ve seen running it ourselves on the same engine that powers Chronos Auto.

  • Sub-minute first response, around the clock — the overnight messages get answered before morning.
  • Out-of-scope inbound gets filtered before it reaches a human — wrong fit, wrong offering, wrong budget tier.
  • Every qualified lead arrives as a structured brief on the right person’s phone, ready to act on.
  • A DPDP-clean audit trail from the first turn — consent, retention, and a hard “forget me” path built in.
  • 14 days from kickoff to a working agent on your real number.

What we’d do differently

The honest version.

Persona tuning is the long pole. It’s easy to underbudget the founder-voice work and blow past the estimate. The lesson: get 10 sample conversations before writing a single line of prompt. Reading the transcripts is the work. Writing the prompt is the easy part.

The rate limiter is easy to over-engineer. A per-user token bucket with sustained-rate sliding-window math assumes a denial-of-service surface that, for a business with a known customer list, just isn’t the risk. A simpler “one message per second per number” check ships sooner and does the same job.

Ship the escalation threshold loose, then tighten. Set the qualification bar too high and the early hours produce fewer handoffs than a team expects — which reads as “it isn’t working.” Better to ship loose, watch the first 50 escalations, then tighten.

Build the kill switch into the UI from day one. Pausing the agent shouldn’t be a command on a CLI on the server — it should be a button. Not because we expect to need it. Because not having it is a different kind of comfort.

Want this for your team?

If your WhatsApp inbox looks anything like this, talk to us.

14 days from kickoff to production. If it’s not right, you pay nothing. After the MVP: 50% on yes, 50% on delivery. No surprise add-ons. Pricing happens in the conversation, not on this page.

Start the conversation Email or call us