pub struct ToolResultExpanded {Show 17 fields
pub binary_results_for_llm: Option<Vec<ExternalToolTextResultForLlmBinaryResultsForLlm>>,
pub citable_sources: Option<Vec<Value>>,
pub contents: Option<Vec<Value>>,
pub error: Option<String>,
pub mcp_meta: Option<HashMap<String, Value>>,
pub new_messages: Option<Vec<ToolResultNewMessage>>,
pub post_tool_use_failure_hooks_processed: Option<bool>,
pub result_type: ToolResultType,
pub session_log: Option<String>,
pub skill_invocation: Option<Value>,
pub skip_large_output_processing: Option<bool>,
pub structured_content: Option<Value>,
pub task_completion_decision: Option<TaskCompletionDecision>,
pub text_result_for_llm: String,
pub tool_references: Option<Vec<String>>,
pub tool_telemetry: Option<Value>,
pub ui_resource: Option<Value>,
}Expand description
Expanded canonical result returned by a session tool.
Experimental. This type is part of an experimental wire-protocol surface and may change or be removed in future SDK or CLI releases.
Fields§
§binary_results_for_llm: Option<Vec<ExternalToolTextResultForLlmBinaryResultsForLlm>>Base64-encoded binary results returned to the model.
citable_sources: Option<Vec<Value>>Sources returned by the tool that the model may cite.
contents: Option<Vec<Value>>Structured content blocks returned to the model.
error: Option<String>Error message for an unsuccessful execution.
mcp_meta: Option<HashMap<String, Value>>Metadata propagated with the tool result, including information-flow labels.
new_messages: Option<Vec<ToolResultNewMessage>>Messages to inject after the tool result.
post_tool_use_failure_hooks_processed: Option<bool>Whether post-tool-use failure hooks have already processed this result.
result_type: ToolResultTypeExecution outcome classification.
session_log: Option<String>Detailed log content available for session display.
skill_invocation: Option<Value>Skill invocation metadata produced by the tool.
skip_large_output_processing: Option<bool>Whether large-output post-processing should be skipped.
structured_content: Option<Value>Structured result content in addition to the model-facing text.
task_completion_decision: Option<TaskCompletionDecision>Completion-review decision produced by the task-completion tool.
text_result_for_llm: StringText result returned to the model.
tool_references: Option<Vec<String>>Deferred tool names made available by this result.
tool_telemetry: Option<Value>Tool-specific telemetry payload.
ui_resource: Option<Value>Optional UI resource produced by the tool.
Trait Implementations§
Source§impl Clone for ToolResultExpanded
impl Clone for ToolResultExpanded
Source§fn clone(&self) -> ToolResultExpanded
fn clone(&self) -> ToolResultExpanded
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read more