Class: OpenAI::Models::Responses::ResponseFunctionToolCallOutputItem

Inherits:
Internal::Type::BaseModel show all
Defined in:
lib/openai/models/responses/response_function_tool_call_output_item.rb,
sig/openai/models/responses/response_function_tool_call_output_item.rbs

Defined Under Namespace

Modules: Caller, Output, Status

Instance Attribute Summary collapse

Attributes inherited from Internal::Type::BaseModel

#last_response

Class Method Summary collapse

Instance Method Summary collapse

Methods inherited from Internal::Type::BaseModel

==, #==, #[], #_request_id, #_set_last_response, coerce, #deconstruct_keys, #deep_to_h, dump, #encode_with, fields, hash, #hash, inherited, #inspect, inspect, known_fields, optional, recursively_to_h, required, #to_h, #to_json, #to_s, to_sorbet_type, #to_yaml

Methods included from Internal::Type::Converter

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

Methods included from Internal::Util::SorbetRuntimeSupport

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

Constructor Details

#initialize(id:, output:, status:, call_id: nil, caller_: nil, created_by: nil, name: nil, namespace: nil, type: :function_call_output) ⇒ Object

Parameters:

  • id —

    The unique ID of the function call tool output.

  • output —

    The output from the function call generated by your code. Can be a string or an list of output content.

  • status —

    The status of the item. One of in_progress, completed, or incomplete. Populated when items are returned via API.

  • call_id (defaults to: nil) —

    The unique ID of the function tool call generated by the model.

  • caller_ (defaults to: nil) —

    The execution context that produced this tool call.

  • created_by (defaults to: nil) —

    The identifier of the actor that created the item.

  • name (defaults to: nil) —

    The name of the tool that produced the output.

  • namespace (defaults to: nil) —

    The namespace of the tool that produced the output.

  • type (defaults to: :function_call_output) —

    The type of the function tool call output. Always function_call_output.



# File 'lib/openai/models/responses/response_function_tool_call_output_item.rb', line 68

Instance Attribute Details

#call_id ⇒ String?

The unique ID of the function tool call generated by the model.

Returns:

  • (String, nil)


37
# File 'lib/openai/models/responses/response_function_tool_call_output_item.rb', line 37

optional :call_id, String

#caller_ ⇒ OpenAI::Models::Responses::ResponseFunctionToolCallOutputItem::caller_?

The execution context that produced this tool call.

Returns:

  • (OpenAI::Models::Responses::ResponseFunctionToolCallOutputItem::caller_, nil)


43
44
45
46
47
48
# File 'lib/openai/models/responses/response_function_tool_call_output_item.rb', line 43

optional(
  :caller_,
  union: -> { OpenAI::Responses::ResponseFunctionToolCallOutputItem::Caller },
  api_name: :caller,
  nil?: true
)

#created_by ⇒ String?

The identifier of the actor that created the item.

Returns:

  • (String, nil)


54
# File 'lib/openai/models/responses/response_function_tool_call_output_item.rb', line 54

optional :created_by, String

#id ⇒ String

The unique ID of the function call tool output.

Returns:

  • (String)


11
# File 'lib/openai/models/responses/response_function_tool_call_output_item.rb', line 11

required :id, String

#name ⇒ String?

The name of the tool that produced the output.

Returns:

  • (String, nil)


60
# File 'lib/openai/models/responses/response_function_tool_call_output_item.rb', line 60

optional :name, String

#namespace ⇒ String?

The namespace of the tool that produced the output.

Returns:

  • (String, nil)


66
# File 'lib/openai/models/responses/response_function_tool_call_output_item.rb', line 66

optional :namespace, String

#output ⇒ OpenAI::Models::Responses::ResponseFunctionToolCallOutputItem::output

The output from the function call generated by your code. Can be a string or an list of output content.

Returns:

  • (OpenAI::Models::Responses::ResponseFunctionToolCallOutputItem::output)


18
# File 'lib/openai/models/responses/response_function_tool_call_output_item.rb', line 18

required :output, union: -> { OpenAI::Responses::ResponseFunctionToolCallOutputItem::Output }

#status ⇒ OpenAI::Models::Responses::ResponseFunctionToolCallOutputItem::status

The status of the item. One of in_progress, completed, or incomplete. Populated when items are returned via API.

Returns:

  • (OpenAI::Models::Responses::ResponseFunctionToolCallOutputItem::status)


25
# File 'lib/openai/models/responses/response_function_tool_call_output_item.rb', line 25

required :status, enum: -> { OpenAI::Responses::ResponseFunctionToolCallOutputItem::Status }

#type ⇒ :function_call_output

The type of the function tool call output. Always function_call_output.

Returns:

  • (:function_call_output)


31
# File 'lib/openai/models/responses/response_function_tool_call_output_item.rb', line 31

required :type, const: :function_call_output

Class Method Details

.values ⇒ Array<Symbol>

Returns:

  • (Array<Symbol>)


# File 'lib/openai/models/responses/response_function_tool_call_output_item.rb', line 152

Instance Method Details

#to_hash ⇒ {

Returns:

  • ({)


91
# File 'sig/openai/models/responses/response_function_tool_call_output_item.rbs', line 91

def to_hash: -> {