#[non_exhaustive]pub struct ApprovalRequest {
pub id: String,
pub tool_use_id: String,
pub tool: String,
pub kind: ApprovalKind,
pub reason: Option<String>,
pub escape: Option<Escape>,
pub summary: String,
pub input: Value,
pub choices: Vec<Choice>,
pub turn_grant_skips_kind: bool,
pub session: Option<String>,
pub agent: Option<String>,
/* private fields */
}Expand description
approval_request: a gate waiting for an answer.
Fields (Non-exhaustive)§
This struct is marked as non-exhaustive
Non-exhaustive structs could have additional fields added in future. Therefore, non-exhaustive structs cannot be constructed in external crates using the traditional
Struct { .. } syntax; cannot be matched against without a wildcard ..; and struct update syntax will not work.id: StringThe id an answer names.
tool_use_id: StringThe call’s tool_use id (empty inside a script).
tool: StringThe tool’s name.
kind: ApprovalKindWhy it asks.
reason: Option<String>The gate’s reason, when it gives one.
escape: Option<Escape>The escape asked for, when the call asks for one.
summary: StringA one-line summary of the call.
input: ValueThe call’s arguments; null when they were nested too deeply to
read (summary still describes the call).
choices: Vec<Choice>The decisions on offer.
turn_grant_skips_kind: boolWhether allow_for_turn leaves calls of this kind out.
session: Option<String>A sub-agent’s session id.
agent: Option<String>A sub-agent’s name.
Implementations§
Trait Implementations§
Source§impl Clone for ApprovalRequest
impl Clone for ApprovalRequest
Source§impl Debug for ApprovalRequest
impl Debug for ApprovalRequest
Source§impl<'de> Deserialize<'de> for ApprovalRequest
impl<'de> Deserialize<'de> for ApprovalRequest
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
Source§impl PartialEq for ApprovalRequest
impl PartialEq for ApprovalRequest
impl StructuralPartialEq for ApprovalRequest
Auto Trait Implementations§
impl !RefUnwindSafe for ApprovalRequest
impl !UnwindSafe for ApprovalRequest
impl Freeze for ApprovalRequest
impl Send for ApprovalRequest
impl Sync for ApprovalRequest
impl Unpin for ApprovalRequest
impl UnsafeUnpin for ApprovalRequest
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