Recipe 2: Opportunity routing & prioritization
Uses the same design patterns as the Lead Qualification flow, applied to pipeline objects.
Business goal
Take opportunity or deal signals and produce priority, owner assignment, and next best action so pipeline hygiene stays consistent.
Prerequisites
- CRM or warehouse events (stage change, amount update) reaching DripPulse via API, import, or webhook.
- Workflow with branching for segment (geo, industry, ARR band).
- Optional: Lead Qualification Agent pattern extended with opportunity-shaped inputs via
execute/inference.
When using the built-in CRM, opportunities live on pipelines and Kanban stages; API updates can move pipeline_stage_id to match your routing outcome.
Architecture (logical)
[Opportunity event] --> [Workflow]
|
+-------------+-------------+
v v v
Rule / score Agent assist SLA timer
| | |
+-------------+-------------+
v
[Owner + priority + follow-up task]
Sample opportunity payload
{
"opportunity_id": "opp_88421",
"account_id": "acct_991",
"stage": "proposal",
"amount_cents": 12000000,
"region": "EMEA",
"owner_id": "usr_legacy"
}
Example: agent evaluation
curl -s -X POST "$API_BASE/api/v1/agents/AGENT_ID/execute" \
-H "Authorization: Bearer $TOKEN" \
-H "Content-Type: application/json" \
-d '{
"input": {
"opportunity_id": "opp_88421",
"stage": "proposal",
"amount_cents": 12000000,
"region": "EMEA"
},
"idempotency_key": "opp-88421-route-20260402"
}'
Illustrative routing output
{
"priority": "P1",
"assigned_owner_id": "usr_enterprise_east",
"next_action": "exec_review_call",
"sla_hours": 24,
"audit_note": "amount > 100k and stage proposal → enterprise pod"
}
What you’ll see in the dashboard (reference)
- Workflows: Branch nodes for region or ARR should light up in test mode when you paste the sample opportunity payload.
- AI Agents: If scoring runs through an agent, execution history shows structured priority and recommended owner fields.
- Monitoring: Watch for spikes in failed executions after CRM field mapping changes.
- Team / CRM: Confirm the assigned owner in your CRM matches the routing output; mismatches usually mean outdated branch rules.
Failure & retry
- Transient model or integration errors: retry with the same
idempotency_keyfor agent calls. - Bad payload: fix mapping at the edge; workflow test mode surfaces validation early.
- Audit: store routing decisions in CRM custom fields or a DripPulse webhook consumer.
Related: How DripPulse works · Workflow builder