LIA StudioLIA Studio
Documentation
⌘K
Back to the IDE
DocsAdvancedApprovals (HITL) & Storage

Approvals (HITL) & Storage

Synchronous and asynchronous Human-in-the-Loop checkpoints, Tag routing, resilient Outbox, cloud attachments, retention policies, and Bring Your Own Storage (BYOS).

LIA includes an end-to-end Human-in-the-Loop (HITL) system to pause or branch workflows whenever explicit human validation is required before executing sensitive business actions (such as approving high-value payments, validating invoices, or authorizing dispatches).

Synchronous vs. Asynchronous mode

LIA provides two complementary patterns depending on your process:

  1. Synchronous — Human Approval (Flow category): pauses the current execution until an approver decides or Timeout Minutes expires, then routes through Approved, Rejected, or Timeout. Ideal for linear flows gated on a single authorization.
  2. Asynchronous (non-blocking) — Request Human Approval + On Approval Resolved: designed for ForEach loops and batch processing. Request Human Approval submits the request (along with its Payload and local files in Attachment Paths) and immediately continues via Exec so the runner keeps processing remaining records without waiting. Once a human approves, rejects, or the timeout expires, the server dispatches the event to the On Approval Resolved push trigger, starting an independent run down Approved, Rejected, or Timeout.

What is the Tag input parameter for?

The Tag input pin (available on both Request Human Approval and On Approval Resolved) acts as an optional routing filter within the same project:

  • Multiple approval checkpoints in one project: if a project requests approvals for different workflows (e.g., Tag = "payments" for treasury and Tag = "discounts" for sales), set the matching Tag on each Request Human Approval → On Approval Resolved pair. When resolved, only triggers with a matching tag fire (case-insensitive, trimmed).
  • Wildcard mode (blank): leaving Tag empty on On Approval Resolved matches any resolved async approval belonging to that project regardless of its tag.

Best practice

Always assign descriptive tags such as payments, invoicing, or contracts when a project has more than one On Approval Resolved trigger so a single decision never triggers two unrelated flows.

Runner affinity & Resilient Outbox

  • Pin to Origin Runner: enable this on Request Human Approval when continuation must execute on the exact machine/runner that created the request (e.g., access to local desktop apps, network shares, or printers).
  • Idempotency & automatic retries: when creating a request, the runner computes a deterministic idempotency key and retries up to 3 times (1s, 3s, 8s) on transient network/5xx errors without creating duplicate requests.
  • Guaranteed delivery & Dead Letter: if no eligible runner is online when a human decides, the event stays queued in PostgreSQL without burning technical retries (up to 7 days) and dispatches immediately upon runner reconnect. Technical execution failures retry with progressive backoff (30s, 2m, 10m, 30m, up to 5 attempts) before entering Dead Letter, logging an execution issue and exposing a Retry continuation button in /approvals.

Assignment, RBAC permissions & project defaults

  • Set Approver Role and/or Approver User directly on the node, or leave them blank to automatically inherit the project's default approvers and timeout (File → Approval settings or from the project card).
  • Access control uses the IAM approval resource with three granular permissions:
    • approval:read: view the /approvals inbox and download attachments.
    • approval:approve: approve or reject requests assigned to your user or role, and retry failed dispatches.
    • approval:manage: decide any organization request, delete attachments to reclaim storage, and manage storage settings.

Private cloud attachments, retention & Bring Your Own Storage (BYOS)

When you pass local file paths to Attachment Paths on Request Human Approval, the runner uploads them to a private bucket (never publicly exposed) so approvers can review documents before deciding, and the continuation runner automatically downloads them into the Attachments output of On Approval Resolved.

In Settings → Storage (/settings?tab=storage) you can configure:

  1. Post-approval retention policy (available across all plans and Self-Hosted):
    • Release after runner finishes: deletes cloud files as soon as the runner confirms completion, keeping your quota free.
    • Temporary retention in days (30 days default): keeps files for auditing for the configured number of days, then auto-purges them.
    • Keep for audit: retains files until an administrator manually deletes them.
  2. Bring Your Own Storage (BYOS):
    • Included on Pro Cloud, Business Cloud, LIA Internal, and all Self-Hosted deployments (configurable per plan).
    • Connect your own AWS S3, Cloudflare R2, MinIO, or S3-compatible bucket with AES-256-GCM encrypted credentials and live PUT/GET/DELETE connection testing.
    • Files stored in your custom bucket do not consume your LIA Cloud storage quota.
Documentation — LIA | LIA Studio