Skip to main content

Module approval_channels

Module approval_channels 

Source
Expand description

Phase 3.6 approval channels.

A channel is a delivery mechanism that gets an ApprovalRequest in front of a human. The kernel treats channels as fire-and-forget sinks: on failure the request stays in the approval store and can still be fetched via GET /approvals/pending, matching the fail-closed rule in the HITL protocol.

Two channels ship in this phase:

  1. WebhookChannel – blocking HTTP POST to a configured URL. Production integrations wire this into their own dashboard or ticketing system.
  2. RecordingChannel – captures every dispatch in an in-memory ring so tests (and host adapters) can assert that a dispatch fired without standing up an HTTP listener.

Structs§

RecordingChannel
In-memory channel that captures every dispatched ApprovalRequest for later inspection. Useful in tests and for the api-poll dispatch mode (where the “channel” is really the local store itself).
WebhookChannel
Blocking HTTP webhook channel. Uses ureq, which is already in the kernel’s dependency tree.
WebhookPayload
Payload shape delivered by WebhookChannel. Stable so receivers can parse it without pulling in kernel types.