Setting Up Assignment Rules to Route Leads Automatically
A practical walkthrough of CareSuite's assignment rules — how source matching, routing method, and priority combine to put a new lead in front of the right person without anyone touching it by hand.
A lead sitting unassigned for even a few hours is a lead that's colder by the time someone looks at it. CareSuite's assignment rules exist to close that gap — they route incoming leads to a specific person or team automatically, based on rules you configure once.
What an assignment rule actually controls
Each row in care_assignment_rules has a small, specific set of fields, and understanding them is most of understanding the feature:
source_match— which lead source this rule applies to (a Facebook form, your website, a specific campaign channel). Leave it unset and the rule applies broadly; set it to target one source specifically.method— how the rule picks a target among eligible people (for example, round-robin across a group, or a fixed assignee).target_user_id/target_org_unit_id— where the lead actually goes: a specific person, or an org unit, letting you route to a team rather than an individual.priority— when more than one rule could match a given lead, priority decides which one wins.active— turn a rule off without deleting it, useful when a routing scheme is seasonal or tied to a person who's temporarily out.
Setting up your first rule
Start narrow. If you're testing the feature, pick one lead source — say, your website contact form — and create a rule that matches only that source and routes to one person or one org unit. Watch a handful of real leads move through it before you build out a second or third rule for other sources.
Once the first rule is working, layer in more sources and more targets. This is where priority starts to matter: if you have a broad "anything unmatched goes to the general queue" rule and a narrow "leads from this specific campaign go to this specific rep" rule, give the narrow rule the higher priority so it wins when both could technically apply.
Routing to a person versus a team
Assignment rules can target either an individual (target_user_id) or an org unit (target_org_unit_id). Targeting an org unit is worth using whenever "the right person" is really "whoever on this team picks it up next," rather than a single named individual — it avoids the common failure mode of a rule quietly routing everything to someone who's on leave. Structuring your org units before you build out assignment rules makes this decision much easier; if you haven't set up org units yet, that's worth doing first (see the companion guide on org structure).
Why this beats a manual queue
The alternative — a shared lead list someone triages by hand every morning — works fine at low volume and breaks down exactly when lead volume matters most: a marketing push, a seasonal spike, a campaign that suddenly performs. Assignment rules don't care about volume. A lead that matches a rule gets routed the moment it lands, whether that's the third lead of the day or the three-hundredth.
They also make routing logic visible and auditable instead of tribal knowledge. "Leads from the Zalo campaign always go to Minh" is either written down as a rule with a source_match and a target_user_id, or it's something a departing employee takes with them. Encoding it as a rule means the logic survives staff turnover.
A note on testing
Before trusting a new rule with real leads, run one or two test leads through the source it's meant to catch and confirm they land where you expect. Rule priority and source matching interact in ways that are easy to get subtly wrong on the first pass — a rule that's too broad can silently swallow leads meant for a narrower rule with lower priority. A few minutes of verification up front saves a much longer cleanup later.