FeaturesLead Routing

Lead Routing

Lead routing determines how leads are assigned, distributed, and delivered to the right destination.

Overview

Routing includes:

  • Default Values - Set field values for all leads
  • Routing Rules - Conditionally assign leads based on criteria
  • Distribution - Round-robin or weighted assignment
  • Destinations - Where leads are sent (CRM, webhook, team)

Default Values

Set default field values that apply to all leads (or leads from specific sources).

Types of Defaults

TypeDescriptionExample
StaticFixed valuesource = "API"
DynamicSystem-generatedreceived_date = today
FormulaCalculatedlead_id = {{uuid}}

Dynamic Value Options

ValueDescription
{{today}}Current date (YYYY-MM-DD)
{{now}}Current timestamp (ISO 8601)
{{uuid}}Unique identifier
{{lead_id}}Ledly lead ID
{{source_name}}Lead source name
{{vendor_name}}Vendor name

Setting Default Values

Go to SettingsRoutingDefault Values

Add a Default

Click Add Default Value

Configure

  • Field: Which field to set
  • Value: Static, dynamic, or formula
  • Source: Apply to all or specific sources

Save

Click Save to apply


Routing Rules

Create conditional rules that route leads based on field values.

Rule Structure

Each rule has:

  • Conditions - When the rule applies
  • Actions - What happens when it matches
  • Priority - Order of evaluation

Example Rules

Route MBA Leads to MBA Team:

IF program_interest contains "MBA"
THEN
  - Set assigned_team = "mba-admissions"
  - Set priority = "high"

Route California Leads:

IF state = "CA"
THEN
  - Set region = "west"
  - Set rep_email = "[email protected]"

Route High-Value Leads:

IF lead_score >= 80
THEN
  - Set priority = "urgent"
  - Trigger webhook "high-value-alert"

Distribution Methods

Round Robin

Distribute leads evenly across team members:

Lead 1 → Rep A
Lead 2 → Rep B
Lead 3 → Rep C
Lead 4 → Rep A (cycle repeats)

Weighted Distribution

Assign leads based on capacity:

RepWeightExpected %
Rep A350%
Rep B233%
Rep C117%

Skills-Based Routing

Route based on rep expertise:

ProgramAssigned Reps
MBARep A, Rep B
NursingRep C, Rep D
EducationRep E

Destinations

Salesforce

Sync leads directly to Salesforce:

Route TO Salesforce
  Object: Lead
  Owner: Based on routing rules
  Field Mapping: Configured mappings

Webhook

Send leads to an external endpoint:

Route TO Webhook
  URL: https://your-system.com/leads
  Method: POST
  Headers: Authorization: Bearer {{api_key}}

Email Notification

Notify team members:

Route TO Email
  Recipients: [email protected]
  Subject: New Lead: {{program_interest}}
  Body: Lead from {{source}}

Multiple Destinations

Route to multiple destinations simultaneously:

Route TO:
  1. Salesforce (primary CRM)
  2. Webhook (marketing platform)
  3. Email (notification)

Rule Priority

Rules are evaluated in priority order:

PriorityRuleAction
1High ScoreRoute to senior rep
2MBA InterestRoute to MBA team
3Nursing InterestRoute to Nursing team
4DefaultRoute to general queue

First Match Wins

By default, the first matching rule is applied. You can configure:

  • Stop on first match - Only apply one rule
  • Apply all matching - Apply multiple rules

Use “stop on first match” for mutually exclusive destinations. Use “apply all” for additive actions (like notifications).


Vendor-Specific Routing

Override default routing for specific vendors:

VendorDefault OwnerProgram Override
Vendor AUnassignedMBA → Rep A
Vendor BRep BNone
Web FormsRound-robinBy program

Setting Vendor Overrides

  1. Go to Vendors → Select vendor
  2. Click Routing Settings
  3. Configure vendor-specific rules
  4. Save

Field Overrides

Override field values from specific sources:

Use Cases

  • Override vendor-provided values
  • Normalize field values
  • Add source-specific data

Configuration

  1. Go to Vendors → Select vendor → Field Overrides
  2. Add override rules:
Field: source
Override: Set to "Partner - Vendor A"
Field: priority
Override: If empty, set to "normal"

Routing Log

Every routing decision is logged:

Viewing the Log

  1. Go to Leads → Select lead
  2. Click Activity tab
  3. View routing events

Log Entry

{
  "timestamp": "2024-12-25T10:30:00Z",
  "lead_id": "lead_abc123",
  "rules_evaluated": [
    { "rule": "High Score", "matched": false },
    { "rule": "MBA Interest", "matched": true }
  ],
  "actions_taken": [
    { "action": "set_field", "field": "assigned_team", "value": "mba-admissions" },
    { "action": "salesforce_sync", "status": "success" }
  ]
}

API Reference

Get Default Values

GET /api/routing/defaults

Set Default Value

POST /api/routing/defaults
 
{
  "field": "source",
  "value": "API",
  "vendor_id": null
}

Get Routing Rules

GET /api/routing/rules

Create Routing Rule

POST /api/routing/rules
 
{
  "name": "Route MBA Leads",
  "priority": 10,
  "conditions": {
    "operator": "AND",
    "rules": [
      { "field": "program_interest", "operator": "contains", "value": "MBA" }
    ]
  },
  "actions": [
    { "type": "set_field", "field": "assigned_team", "value": "mba-admissions" }
  ]
}

Best Practices

  1. Start simple - Begin with default values, add rules as needed

  2. Test thoroughly - Use test leads before enabling in production

  3. Document rules - Explain why each rule exists

  4. Monitor distribution - Ensure leads are balanced across reps

  5. Review regularly - Remove outdated rules

  6. Use priorities wisely - Keep the most important rules first