Class: OpenAI::Models::Responses::ResponseFunctionToolCall

Inherits:
Internal::Type::BaseModel show all
Defined in:
lib/openai/models/responses/response_function_tool_call.rb

Direct Known Subclasses

ResponseFunctionToolCallItem

Defined Under Namespace

Modules: Status

Instance Attribute Summary collapse

Instance Method Summary collapse

Methods inherited from Internal::Type::BaseModel

==, #==, #[], coerce, #deconstruct_keys, #deep_to_h, dump, 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, #dump, dump, #inspect, inspect, 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(arguments: , call_id: , name: , id: nil, status: nil, type: :function_call) ⇒ Object

Some parameter documentations has been truncated, see OpenAI::Models::Responses::ResponseFunctionToolCall for more details.

A tool call to run a function. See the [function calling guide](platform.openai.com/docs/guides/function-calling) for more information.

Parameters:

  • arguments (String) (defaults to: )

    A JSON string of the arguments to pass to the function.

  • call_id (String) (defaults to: )

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

  • name (String) (defaults to: )

    The name of the function to run.

  • id (String) (defaults to: nil)

    The unique ID of the function tool call.

  • status (Symbol, OpenAI::Models::Responses::ResponseFunctionToolCall::Status) (defaults to: nil)

    The status of the item. One of ‘in_progress`, `completed`, or

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

    The type of the function tool call. Always ‘function_call`.



# File 'lib/openai/models/responses/response_function_tool_call.rb', line 50

Instance Attribute Details

#argumentsString

A JSON string of the arguments to pass to the function.

Returns:

  • (String)


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

required :arguments, String

#call_idString

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

Returns:

  • (String)


23
# File 'lib/openai/models/responses/response_function_tool_call.rb', line 23

required :call_id, String

#idString?

The unique ID of the function tool call.

Returns:

  • (String, nil)


41
# File 'lib/openai/models/responses/response_function_tool_call.rb', line 41

optional :id, String

#nameString

The name of the function to run.

Returns:

  • (String)


29
# File 'lib/openai/models/responses/response_function_tool_call.rb', line 29

required :name, String

#parsedObject?

The parsed contents of the arguments.

Returns:

  • (Object, nil)


17
# File 'lib/openai/models/responses/response_function_tool_call.rb', line 17

required :parsed, OpenAI::Internal::Type::Unknown

#statusSymbol, ...

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



48
# File 'lib/openai/models/responses/response_function_tool_call.rb', line 48

optional :status, enum: -> { OpenAI::Responses::ResponseFunctionToolCall::Status }

#typeSymbol, :function_call

The type of the function tool call. Always ‘function_call`.

Returns:

  • (Symbol, :function_call)


35
# File 'lib/openai/models/responses/response_function_tool_call.rb', line 35

required :type, const: :function_call