pub trait InterruptExt {
// Required methods
fn resolve(&self, payload: impl Into<Value>) -> ResumeEntry;
fn cancel(&self) -> ResumeEntry;
fn is_tool_approval(&self) -> bool;
}Expand description
Answering one interrupt, on the interrupt itself.
The protocol type lives in ag-ui-core, which has no opinion about
consuming a run; these are the two things a client always does with one.
Required Methods§
Sourcefn resolve(&self, payload: impl Into<Value>) -> ResumeEntry
fn resolve(&self, payload: impl Into<Value>) -> ResumeEntry
Answers this interrupt with a payload.
Sourcefn cancel(&self) -> ResumeEntry
fn cancel(&self) -> ResumeEntry
Declines this interrupt.
Sourcefn is_tool_approval(&self) -> bool
fn is_tool_approval(&self) -> bool
Whether the interrupt is asking to approve a specific tool call.
Dyn Compatibility§
This trait is not dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety".