ExGAM.Fallback (ExGAM v0.1.0)

Copy Markdown View Source

Fail-closed handling for a declared refusal policy.

A fallback is either silence or a fresh Candidate built from a static template. It applies only to :refused: :undecidable and :unknown_class remain distinct queryable outcomes. It never reuses the refused Candidate's Evidence, Presentation or resolved Mandate. The returned Candidate still crosses normal admission and receives no special authority. The public proposal driver executes at most one fallback and returns its result without applying this policy again. This pure builder does not infer execution origin from an application-controlled identity key.

Summary

Functions

Materializes the one declared response to an explicitly refused Decision.

Types

result()

@type result() ::
  :silence | {:candidate_template | :governed_handoff, ExGAM.Candidate.t()}

Functions

materialize(policy, decision, context)

@spec materialize(
  ExGAM.Fallback.Policy.t() | map() | atom(),
  ExGAM.Decision.t(),
  ExGAM.SubmissionContext.t()
) :: {:ok, result()} | {:error, term()}

Materializes the one declared response to an explicitly refused Decision.