#[non_exhaustive]pub struct ApprovalChange {
pub kind: String,
pub requirement_id: Option<ApprovalRequirementRef>,
pub choice_id: Option<String>,
pub decision: Option<ApprovalDecision>,
pub status: Option<ApprovalPersistenceStatus>,
pub reason: Option<String>,
pub reparsed: Option<bool>,
pub executable: Option<bool>,
}Expand description
The change an approval/updated event reports. kind says what happened,
and only the fields for that kind are present.
Fields (Non-exhaustive)§
This struct is marked as non-exhaustive
Struct { .. } syntax; cannot be matched against without a wildcard ..; and struct update syntax will not work.kind: StringWhat happened: for example stageResolved (a shell stage was
satisfied), policyPersistence (saving a rule succeeded or failed),
reviewStarted or reviewCompleted (the automated LLM judge started or
finished reviewing), restartRecovered (a host restart recovered this
approval: either the host first resolves it abort and a re-ask comes
as a new approval with a new approvalId, or it stays pending under
the same approvalId with refreshed choices), alreadyTerminal
(recovery found it already decided) or resolving (a
computerUseTakeover approval was marked resolving and waits for the
lock broker; a decide now answers -32059). The set is open, so newer
hosts may add kinds.
requirement_id: Option<ApprovalRequirementRef>The stage requirement that was satisfied. Present only when kind is
stageResolved.
choice_id: Option<String>The choiceId that satisfied the stage. Present only when kind is
stageResolved.
decision: Option<ApprovalDecision>The decision the chosen option applied to the stage. Present only when
kind is stageResolved.
status: Option<ApprovalPersistenceStatus>Whether saving the policy rule succeeded or failed; present only when
kind is policyPersistence. A failure does not undo the decision;
only the saved rule is missing.
reason: Option<String>Why saving the policy rule failed, as human-readable text. Present only
when kind is policyPersistence and status is failed.
reparsed: Option<bool>A recovery detail: whether the command was re-parsed during recovery.
Present only when kind is restartRecovered.
executable: Option<bool>A recovery detail: whether the action could run without a new decision.
Present only when kind is restartRecovered.