Threshold-triggered actions (score > X → notify sales)
Why it matters
Lead scores that accumulate without triggering any action are a vanity metric. The system faithfully increments a number, the number crosses 100, and nothing happens — no CRM task, no Slack notification, no lifecycle stage change. CWE-691 (Insufficient Control Flow Management) applies: the application collects state (score) but fails to enforce the behavioral transitions that state is supposed to trigger. iso-25010:2011 functional-suitability.functional-completeness rates the scoring system as incomplete when threshold actions are missing. In practice, sales-ready leads sit uncontacted because the handoff mechanism was never wired.
Severity rationale
High because scores without threshold actions mean qualified leads are never routed to sales, producing invisible pipeline leakage from a system that appears to be working correctly.
Remediation
Implement evaluateScoreThresholds with idempotent, crossing-triggered actions. Track the highest threshold already fired on the contact record to prevent repeat notifications.
const THRESHOLDS = [
{ score: 50, action: 'mark_mql', label: 'Marketing Qualified Lead' },
{ score: 100, action: 'mark_sql', label: 'Sales Qualified Lead' },
{ score: 150, action: 'notify_sales', label: 'Hot Lead — Notify Rep' },
]
async function evaluateScoreThresholds(contactId: string, currentScore: number) {
const contact = await db.contact.findUnique({ where: { id: contactId } })
for (const threshold of THRESHOLDS) {
const alreadyFired = (contact.highestTriggeredThreshold ?? 0) >= threshold.score
if (currentScore >= threshold.score && !alreadyFired) {
await fireThresholdAction(contact, threshold.action)
await db.contact.update({
where: { id: contactId },
data: { highestTriggeredThreshold: threshold.score }
})
}
}
}
Define at least two thresholds with distinct actions (e.g., MQL at 50, SQL at 100). Thresholds stored only in comments or documentation with no wired handler do not satisfy this check.
DetectionPro
The detection method for this pattern is part of AuditBuffet Pro.
The full method (what to look for, pass and fail conditions, and how results get reported) ships inside the Campaign Orchestration & Sequencing Audit. The pattern definition, severity rationale, and remediation remain openly licensed under CC-BY-4.0.
External references
- cwe · CWE-691 — Insufficient Control Flow Management
- iso-25010:2011 · functional-suitability.functional-completeness
Taxons
History
- 2026-04-18·v1.0.0·Initial import from campaign-orchestration-sequencing·automated