pub struct PreToolUseInput {
pub base: BaseHookInput,
pub subagent: SubagentContext,
pub tool_name: String,
pub tool_input: Value,
pub tool_use_id: String,
}Expand description
Input payload for PreToolUse.
Fields§
§base: BaseHookInputShared hook context (session_id, transcript_path, cwd, …).
subagent: SubagentContextOptional sub-agent attribution.
tool_name: StringTool the model wants to invoke.
tool_input: ValueThe model’s proposed input.
tool_use_id: StringOpaque tool-use identifier the CLI will reference in the matching
PostToolUse / PostToolUseFailure frame.
Trait Implementations§
Source§impl Clone for PreToolUseInput
impl Clone for PreToolUseInput
Source§fn clone(&self) -> PreToolUseInput
fn clone(&self) -> PreToolUseInput
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 PreToolUseInput
impl Debug for PreToolUseInput
Source§impl<'de> Deserialize<'de> for PreToolUseInput
impl<'de> Deserialize<'de> for PreToolUseInput
Source§fn deserialize<__D>(
__deserializer: __D,
) -> Result<PreToolUseInput, <__D as Deserializer<'de>>::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(
__deserializer: __D,
) -> Result<PreToolUseInput, <__D as Deserializer<'de>>::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Source§impl Serialize for PreToolUseInput
impl Serialize for PreToolUseInput
Source§fn serialize<__S>(
&self,
__serializer: __S,
) -> Result<<__S as Serializer>::Ok, <__S as Serializer>::Error>where
__S: Serializer,
fn serialize<__S>(
&self,
__serializer: __S,
) -> Result<<__S as Serializer>::Ok, <__S as Serializer>::Error>where
__S: Serializer,
Serialize this value into the given Serde serializer. Read more
Auto Trait Implementations§
impl Freeze for PreToolUseInput
impl RefUnwindSafe for PreToolUseInput
impl Send for PreToolUseInput
impl Sync for PreToolUseInput
impl Unpin for PreToolUseInput
impl UnsafeUnpin for PreToolUseInput
impl UnwindSafe for PreToolUseInput
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