pub enum OutputItem {
Show 23 variants
Message(OutputMessage),
FileSearchCall(FileSearchToolCall),
FunctionCall(FunctionToolCall),
FunctionCallOutput(FunctionToolCallOutputResource),
WebSearchCall(WebSearchToolCall),
ComputerCall(ComputerToolCall),
ComputerCallOutput(ComputerToolCallOutputResource),
Reasoning(ReasoningItem),
Compaction(CompactionBody),
ImageGenerationCall(ImageGenToolCall),
CodeInterpreterCall(CodeInterpreterToolCall),
LocalShellCall(LocalShellToolCall),
ShellCall(FunctionShellCall),
ShellCallOutput(FunctionShellCallOutput),
ApplyPatchCall(ApplyPatchToolCall),
ApplyPatchCallOutput(ApplyPatchToolCallOutput),
McpCall(MCPToolCall),
McpListTools(MCPListTools),
McpApprovalRequest(MCPApprovalRequest),
CustomToolCall(CustomToolCall),
CustomToolCallOutput(CustomToolCallOutputResource),
ToolSearchCall(ToolSearchCall),
ToolSearchOutput(ToolSearchOutput),
}response-types only.Expand description
Output item
Variants§
Message(OutputMessage)
An output message from the model.
FileSearchCall(FileSearchToolCall)
The results of a file search tool call. See the file search guide for more information.
FunctionCall(FunctionToolCall)
A tool call to run a function. See the function calling guide for more information.
FunctionCallOutput(FunctionToolCallOutputResource)
The output of a function tool call.
WebSearchCall(WebSearchToolCall)
The results of a web search tool call. See the web search guide for more information.
ComputerCall(ComputerToolCall)
A tool call to a computer use tool. See the computer use guide for more information.
ComputerCallOutput(ComputerToolCallOutputResource)
The output of a computer tool call.
Reasoning(ReasoningItem)
A description of the chain of thought used by a reasoning model while generating
a response. Be sure to include these items in your input to the Responses API for
subsequent turns of a conversation if you are manually
managing context.
Compaction(CompactionBody)
A compaction item generated by the v1/responses/compact API.
ImageGenerationCall(ImageGenToolCall)
An image generation request made by the model.
CodeInterpreterCall(CodeInterpreterToolCall)
A tool call to run code.
LocalShellCall(LocalShellToolCall)
A tool call to run a command on the local shell.
ShellCall(FunctionShellCall)
A tool call that executes one or more shell commands in a managed environment.
ShellCallOutput(FunctionShellCallOutput)
The output of a shell tool call.
ApplyPatchCall(ApplyPatchToolCall)
A tool call that applies file diffs by creating, deleting, or updating files.
ApplyPatchCallOutput(ApplyPatchToolCallOutput)
The output emitted by an apply patch tool call.
McpCall(MCPToolCall)
An invocation of a tool on an MCP server.
McpListTools(MCPListTools)
A list of tools available on an MCP server.
McpApprovalRequest(MCPApprovalRequest)
A request for human approval of a tool invocation.
CustomToolCall(CustomToolCall)
A call to a custom tool created by the model.
CustomToolCallOutput(CustomToolCallOutputResource)
The output of a custom tool call.
ToolSearchCall(ToolSearchCall)
A tool search call.
ToolSearchOutput(ToolSearchOutput)
A tool search output.
Trait Implementations§
Source§impl Clone for OutputItem
impl Clone for OutputItem
Source§fn clone(&self) -> OutputItem
fn clone(&self) -> OutputItem
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read more