Skip to main content
View as Markdown

Approval & Delay Actions

These two families pause a running workflow. The approval family waits for a human decision (human-in-the-loop). The delay family waits for a duration, a datetime, an external webhook callback, or paces a queue of items.

Approval — Human-in-the-Loop

One operator, request. It suspends the run, notifies approvers, and resumes once a decision is recorded (or the timeout fires). Requires app.auth to be configured.

Prop Description
approvers all-admins, or an array of email addresses / role names. Required.
message Message shown to approvers (templatable). Required.
options Approval choices, minimum 2 ({ value, label? }). Default [{ value: approve }, { value: reject }]. The chosen value becomes the step output.
timeout How long to wait (e.g. 24h, 7d). No timeout by default.
onTimeout On timeout: approve (auto-approve), reject (auto-reject), or escalate (notify escalation).
notifyVia Notification channel: email (default), webhook, or both.
- name: approveRefund
  type: approval
  operator: request
  props:
    approvers: all-admins
    message: 'Approve refund of ${{trigger.data.amount}} for order {{trigger.data.id}}?'
    options:
      - { value: approve, label: 'Approve refund' }
      - { value: reject, label: 'Deny' }
    timeout: 48h
    onTimeout: reject
    notifyVia: email

Delay — Wait, Queue, Webhook

Three operators that pause execution differently.

wait

Pause for a fixed duration or until a specific datetime.

Prop Description
duration Delay as number + unit (ms/s/m/h/d), e.g. 30s, 24h, 7d.
until ISO 8601 datetime (or template) to wait until, e.g. 2025-12-01T09:00:00Z.
- name: cooldown
  type: delay
  operator: wait
  props: { duration: 15m }

queue

Process queued items one at a time with configurable spacing — ideal for rate-limited downstream APIs.

Prop Description
interval Minimum delay between processing each item — number + unit (ms/s/m/h), e.g. 500ms, 2s. Required.
maxQueueSize Max items in the queue before new entries are rejected (default unlimited).
- name: paceApiCalls
  type: delay
  operator: queue
  props: { interval: 1s, maxQueueSize: 1000 }

webhook

Pause until an external webhook callback is received (e.g. an async third-party job completes).

Prop Description
callbackId Custom callback identifier (templatable). Auto-generated when omitted.
timeout Max time to wait for the callback — number + unit, e.g. 1h, 7d.
onTimeout On timeout: continue, stop, or error (default error).
expectedData Expected shape used to validate the inbound callback payload.
- name: awaitProcessing
  type: delay
  operator: webhook
  props:
    callbackId: 'job-{{trigger.data.id}}'
    timeout: 2h
    onTimeout: error