ToolResult

data class ToolResult(val value: Document) : UserMessageBlock

Tool execution result provided by the user.

Constructors

Link copied to clipboard
constructor(value: Document)

Properties

Link copied to clipboard

Inherited functions

Link copied to clipboard
fun asText(): String

Casts this UserMessageBlock as a Text and retrieves its kotlin.String value. Throws an exception if the UserMessageBlock is not a Text.

Link copied to clipboard

Casts this UserMessageBlock as a Text and retrieves its kotlin.String value. Returns null if the UserMessageBlock is not a Text.

Link copied to clipboard

Casts this UserMessageBlock as a ToolResult and retrieves its aws.smithy.kotlin.runtime.content.Document value. Throws an exception if the UserMessageBlock is not a ToolResult.

Link copied to clipboard

Casts this UserMessageBlock as a ToolResult and retrieves its aws.smithy.kotlin.runtime.content.Document value. Returns null if the UserMessageBlock is not a ToolResult.