runbookify
← All plans
Marketing Operations / Lead Scoring & Nurture

Lead Routing & Round-Robin Assigner

Build an internal tool that automatically assigns every inbound lead to the right rep by territory, industry, or round-robin while respecting capacity caps and out-of-office, with a human approval gate before anyone is notified.

IntermediateA weekendBuilds onNext.js (App Router) on VercelSupabase (Postgres, Auth, RLS, Storage)Resend (email notifications)
What you'll build

A logged-in tool that takes incoming leads, applies your routing rules, proposes an owner for each, lets an admin approve or override, then notifies the owner and exports a clean assigned-leads CSV.

Gated download

Enter your email — the plan downloads instantly and a copy lands in your inbox.

By submitting your email you'll also receive the weekly runbookify newsletter. You can unsubscribe at any time.

Before you start

  • A free Supabase account
  • A free Vercel account
  • A free Resend account (for owner notifications)
  • Your current rep roster (territories, specialties, capacity) in a spreadsheet
  • A list of recent inbound leads as a CSV to test with

The problem this kills

Inbound leads are gold, and they leak. A form fills overnight and sits unassigned until someone notices. A West-coast enterprise lead lands on a rep who only does small accounts in the Midwest. One rep is drowning in fifty open leads while another is idle. Someone is on vacation but still getting assigned hot prospects that go cold. And every so often the same person fills out the form twice and two reps both start working them, which is awkward for everyone.

Most teams "solve" this with a shared spreadsheet, a Slack channel, and a manager who manually drags leads around. That manager becomes the bottleneck, the rules live only in their head, and there's no record of who decided what or why.

This tool turns your routing rules into something the computer actually runs, while keeping a human firmly in charge of the final call.

What you'll build

A small, private web app for your marketing/sales ops team. Leads come in (from a form, a CSV import, or your existing system). The tool applies your rules - territory, industry/specialty, then round-robin to break ties - and checks each candidate rep's capacity and availability. It proposes an owner for every lead and flags the tricky ones (a territory with no available rep, a rep already at their cap, a lead that's being re-routed).

Then it stops and waits for you. An ops admin reviews the proposed assignments, overrides anything that needs a human's judgment, and approves. Only then does the tool notify the chosen owners and commit the assignment. You can export the whole batch as a clean assigned-leads CSV in exactly the columns your CRM expects.

What's inside the Implementation Plan

The plan is a complete, paste-and-go runbook for an AI coding agent (Claude Code). You don't write code - you paste, answer questions, and approve.

It opens by interviewing you about your business - your real territories, how you name industries and segments, your capacity caps, how you mark a rep as out-of-office, and your messiest edge cases - so the tool fits the way your team actually distributes leads instead of a generic template. The agent reads a short tailored spec back to you and waits for your thumbs-up before it builds anything.

From there it walks step by step: the data model shaped to your fields, the routing engine, the review-and-approve screen, owner notifications, the audit trail, and the CSV import/export fallback so you can run the whole thing today even with no CRM integration.

The governance it includes (this is the point)

This isn't a script that fires emails on its own. Governance is built in from the first step:

  • Login so only your team can open the tool.
  • Row-level security so each organization only ever sees its own leads, reps, and assignments.
  • A human-in-the-loop approval gate - the engine drafts assignments, a person reviews and approves, and only then is anything committed or notified.
  • A complete audit trail - who proposed, who overrode, who approved, and when, for every lead.
  • Duplicate guards keyed on lead email so one lead gets exactly one owner, plus a re-route cooldown warning so a lead isn't bounced between reps in a short window.

Who it's for

Marketing operations and sales operations folks who own the inbound lead flow for a team of reps - and who are tired of being the human router. If you can fill out a spreadsheet and follow steps, you can build this. No coding background required.

You've got this - paste the first prompt and let the agent interview you.

Gated download

Enter your email — the plan downloads instantly and a copy lands in your inbox.

By submitting your email you'll also receive the weekly runbookify newsletter. You can unsubscribe at any time.