AnthropicToolResultContent
Namespace: Vercel.AI.Anthropic
public sealed class AnthropicToolResultContent : GeneratedContentA provider-executed tool result returned inside a Messages response.
Inheritance: object → GeneratedContent
Constructors
Section titled “Constructors”AnthropicToolResultContent(string, string, string, bool, JsonElement?)
Section titled “AnthropicToolResultContent(string, string, string, bool, JsonElement?)”public AnthropicToolResultContent(string toolCallId, string toolName, string resultJson, bool isError, JsonElement? providerMetadata)Creates a tool result.
Parameters
| Name | Type | Description |
|---|---|---|
toolCallId |
string | |
toolName |
string | |
resultJson |
string | |
isError |
bool | |
providerMetadata |
JsonElement? |
Properties
Section titled “Properties”IsError
Section titled “IsError”public bool IsError { get; }Whether the tool failed.
Value: bool
ProviderMetadata
Section titled “ProviderMetadata”public JsonElement? ProviderMetadata { get; }Provider metadata, including caller information.
Value: JsonElement?
ResultJson
Section titled “ResultJson”public string ResultJson { get; }JSON result.
Value: string
ToolCallId
Section titled “ToolCallId”public string ToolCallId { get; }Matching tool call id.
Value: string
ToolName
Section titled “ToolName”public string ToolName { get; }Tool name.
Value: string
Apache-2.0 · Copyright 2023 Vercel, Inc. · unofficial community port, not an official Vercel product