Human-in-the-Loop

Approval gates that pause workflow execution until a human reviews and approves. Critical for high-stakes actions like sending outreach, publishing content, or committing to deals.


What is Human-in-the-Loop?

A Human-in-the-Loop (HitL) gate pauses a workflow at a specific step and waits for a human to review the output and decide whether to proceed. Nothing irreversible happens until you say so.

HitL is not a separate step type — it is a flag on any step that produces output requiring review. When approvalRequired: true, the execution pauses after that step completes, shows you the output, and waits for your decision before routing to the next step.


Configuration

{
  id: "draft_email",
  type: "aiAction",
  // ... step config ...

  next: {
    conditions: {
      approvalRequired: true,
      approveLabel: "Send email",     // optional — customize the approve button
      approvers: [                    // optional — notify specific team members
        { userId: "user_abc" }
      ]
    }
  }
}

After the step runs, the execution status becomes pending approval. It stays paused indefinitely until someone approves or rejects.


What the Reviewer Sees

The reviewer gets the full step output — draft email body, enriched data, scored results — presented in the execution dashboard. From there they can:

  • Approve — The workflow continues to the next step. For email steps, approval triggers the send action.
  • Reject — The execution is closed without proceeding. Rejection is logged with a timestamp.
  • Edit & Approve — For supported step types (email, text), the reviewer can modify the output before approving. The edited version is what gets used downstream.

Notifications

When execution pauses for approval, reviewers are notified through:

  • Dashboard — The execution appears in Needs your attention with a pending badge. Always on.
  • Email — Notification sent to the workflow owner or specified approvers. Includes a direct link to the review page.
  • Slack — Configure via workspace notification settings. Message includes the step output summary and an approve/reject link.

Timeout Behavior

By default, HitL gates wait indefinitely — there is no auto-approve or auto-reject timeout. The execution stays in pending state until a human acts. If you need time-bounded approval (e.g., auto-reject after 48 hours), combine HitL with a Proactive Agent that monitors for stale pending executions and notifies or escalates automatically.


Example: Outreach Review

A local business outreach workflow:

Step 1Research the prospect (website scrape, LinkedIn, news).

Step 2AI drafts a personalised cold email (from, to, subject, body).

PauseapprovalRequired: true — rep reviews and optionally edits the draft. Approval button labeled “Send email”.

Step 3On approval, the email is sent via the connected Gmail account. Execution completes.


Next Steps

  • Proactive Agents — Monitor for stale approvals and escalate automatically
  • Auto-Fix — Autonomous error recovery when human review isn't needed
  • Agents as Step — Combine agent steps with approval gates for supervised automation