Workflow sequence
- 01Receive intent signal
- 02Score and route lead
- 03Send first message
- 04Wait for reply or behavior signal
- 05Stop or schedule follow-up
- 06Assign human owner
Sequence definition
Use this definition as a starting point. Replace handlers with your HTTP workers, validate provider responses, and add credentials through the credential store rather than embedding secrets.
{
"id": "event_driven_outreach_v1",
"blocks": [
{ "id": "score", "type": "step", "handler": "score_intent" },
{ "id": "send", "type": "step", "handler": "send_message", "rate_limit_key": "sender:{{context.sender_id}}" },
{ "id": "wait", "type": "wait_for_signal", "signal": "lead_activity", "timeout": "P3D" },
{ "id": "route", "type": "router", "routes": [
{ "condition": "signal.type == 'reply'", "blocks": [{ "id": "handoff", "type": "step", "handler": "assign_owner" }] },
{ "condition": "signal.type == 'high_intent'", "blocks": [{ "id": "priority", "type": "step", "handler": "notify_sales" }] }
], "default": [{ "id": "followup", "type": "step", "handler": "send_followup" }] }
]
}Production controls to keep
✓ Stable idempotency keys around external writes
✓ Explicit validation before the success state
✓ Bounded retries with provider-aware backoff
✓ Searchable source and destination identifiers
✓ A named owner for exhausted retries
✓ A replay test using duplicate input