Module: OpenAI::Models::Conversations::ConversationItem

Extended by:
Internal::Type::Union
Defined in:
lib/openai/models/conversations/conversation_item.rb

Overview

A single item within a conversation. The set of possible types are the same as the ‘output` type of a [Response object](platform.openai.com/docs/api-reference/responses/object#responses/object-output).

Defined Under Namespace

Classes: ImageGenerationCall, LocalShellCall, LocalShellCallOutput, McpApprovalRequest, McpApprovalResponse, McpCall, McpListTools

Class Method Summary collapse

Instance Method Summary collapse

Methods included from Internal::Type::Union

==, ===, coerce, dump, hash, inspect, to_sorbet_type, variants

Methods included from Internal::Util::SorbetRuntimeSupport

#const_missing, #define_sorbet_constant!, #sorbet_constant_defined?, #to_sorbet_type, to_sorbet_type

Methods included from Internal::Type::Converter

#coerce, coerce, #dump, dump, inspect, #inspect, meta_info, new_coerce_state, type_info

Class Method Details

.valuesArray<Symbol>

Returns:

  • (Array<Symbol>)


# File 'lib/openai/models/conversations/conversation_item.rb', line 138

Instance Method Details

#initialize(id: , approval_request_id: , approve: , reason: nil, type: :mcp_approval_response) ⇒ Object

Some parameter documentations has been truncated, see McpApprovalResponse for more details.

A response to an MCP approval request.

Parameters:

  • id (String) (defaults to: )

    The unique ID of the approval response

  • approval_request_id (String) (defaults to: )

    The ID of the approval request being answered.

  • approve (Boolean) (defaults to: )

    Whether the request was approved.

  • reason (String, nil) (defaults to: nil)

    Optional reason for the decision.

  • type (Symbol, :mcp_approval_response) (defaults to: :mcp_approval_response)

    The type of the item. Always ‘mcp_approval_response`.



# File 'lib/openai/models/conversations/conversation_item.rb', line 391