Conjure.ToolResult (Conjure v0.1.1-alpha)
View SourceResult of executing a tool call.
Tool results are sent back to Claude in the conversation to report the outcome of tool executions. They include the original tool call ID, the result content, and an error flag.
Content Types
The content can be:
- A simple string for text output
- A list of content blocks for complex responses (text, images)
Example
A successful file read:
%Conjure.ToolResult{
tool_use_id: "toolu_01ABC123",
content: "File contents here...",
is_error: false
}A failed command:
%Conjure.ToolResult{
tool_use_id: "toolu_01ABC123",
content: "Command failed with exit code 1: No such file",
is_error: true
}
Summary
Functions
Creates an error tool result.
Creates a successful tool result.
Converts the tool result to the format expected by the Claude API.
Types
Functions
Creates an error tool result.
Creates a successful tool result.
Converts the tool result to the format expected by the Claude API.