Skip to content

ApprovalToolResultPart

Namespace: Vercel.AI.GenerateText

public sealed class ApprovalToolResultPart : ApprovalHistoryPart

A tool result stored beside an approval response.

Inheritance: object → ApprovalHistoryPart

View source

ApprovalToolResultPart(string, string, string, JsonElement?, string?)

Section titled “ApprovalToolResultPart(string, string, string, JsonElement?, string?)”
public ApprovalToolResultPart(string toolCallId, string toolName, string outputType, JsonElement? outputValue = null, string? reason = null)

Creates a tool result part.

Parameters

Name Type Description
toolCallId string
toolName string
outputType string
outputValue JsonElement?
reason string

View source

public string OutputType { get; }

Output type, such as text or execution-denied.

Value: string

View source

public JsonElement? OutputValue { get; }

Output value for text and JSON results.

Value: JsonElement?

View source

public string? Reason { get; }

Denial reason.

Value: string

View source

public string ToolCallId { get; }

Tool call id.

Value: string

View source

public string ToolName { get; }

Tool name.

Value: string

View source

Apache-2.0 · Copyright 2023 Vercel, Inc. · unofficial community port, not an official Vercel product