pub enum AskForApproval {
UnlessTrusted,
OnFailure,
OnRequest,
Reject {
sandbox_approval: bool,
rules: bool,
mcp_elicitations: bool,
},
Never,
}Expand description
Policy mode controlling when tool invocations require human approval.
Variants§
UnlessTrusted
Skip approval if the command matches a trusted prefix; otherwise require it.
OnFailure
Allow execution and only request approval after a failure occurs.
OnRequest
Always require approval before execution.
Reject
Reject invocations outright based on specific criteria.
Fields
Never
Never require approval; forbid commands that would need it.
Trait Implementations§
Source§impl Clone for AskForApproval
impl Clone for AskForApproval
Source§fn clone(&self) -> AskForApproval
fn clone(&self) -> AskForApproval
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for AskForApproval
impl Debug for AskForApproval
Source§impl<'de> Deserialize<'de> for AskForApproval
impl<'de> Deserialize<'de> for AskForApproval
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
impl Eq for AskForApproval
Source§impl PartialEq for AskForApproval
impl PartialEq for AskForApproval
Source§fn eq(&self, other: &AskForApproval) -> bool
fn eq(&self, other: &AskForApproval) -> bool
Tests for
self and other values to be equal, and is used by ==.Source§impl Serialize for AskForApproval
impl Serialize for AskForApproval
impl StructuralPartialEq for AskForApproval
Auto Trait Implementations§
impl Freeze for AskForApproval
impl RefUnwindSafe for AskForApproval
impl Send for AskForApproval
impl Sync for AskForApproval
impl Unpin for AskForApproval
impl UnsafeUnpin for AskForApproval
impl UnwindSafe for AskForApproval
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more