Skip to content

ToolResultPayload

Payload for “tool_result” events — a tool has returned its result.

---
title: ToolResultPayload
config:
  look: handDrawn
  theme: colorful
  class:
    hideEmptyMembersBox: true
---
classDiagram
    class ToolResultPayload {
        +string name
        +ToolResult result
    }
    class ToolResult {
        +ContentPart[] parts
        +text() string [async-capable]
    }
    ToolResultPayload *-- ToolResult
name: get_weather
result:
parts:
- kind: text
value: 72°F and sunny
NameTypeDescription
namestringThe name of the tool that produced the result
resultToolResultThe tool’s result

The following types are composed within ToolResultPayload: