Class: OpenAI::Models::Realtime::RealtimeResponseStatus

Inherits:
Internal::Type::BaseModel show all
Defined in:
lib/openai/models/realtime/realtime_response_status.rb

Defined Under Namespace

Modules: Reason, Type Classes: Error

Instance Attribute Summary collapse

Class Method 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, 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(code: nil, type: nil) ⇒ Object

A description of the error that caused the response to fail, populated when the ‘status` is `failed`.

Parameters:

  • code (String) (defaults to: nil)

    Error code, if any.

  • type (String) (defaults to: nil)

    The type of error.



# File 'lib/openai/models/realtime/realtime_response_status.rb', line 31


Instance Attribute Details

#errorOpenAI::Models::Realtime::RealtimeResponseStatus::Error?

A description of the error that caused the response to fail, populated when the ‘status` is `failed`.



12
# File 'lib/openai/models/realtime/realtime_response_status.rb', line 12

optional :error, -> { OpenAI::Realtime::RealtimeResponseStatus::Error }

#reasonSymbol, ...

The reason the Response did not complete. For a ‘cancelled` Response, one of `turn_detected` (the server VAD detected a new start of speech) or `client_cancelled` (the client sent a cancel event). For an `incomplete` Response, one of `max_output_tokens` or `content_filter` (the server-side safety filter activated and cut off the response).



22
# File 'lib/openai/models/realtime/realtime_response_status.rb', line 22

optional :reason, enum: -> { OpenAI::Realtime::RealtimeResponseStatus::Reason }

#typeSymbol, ...

The type of error that caused the response to fail, corresponding with the ‘status` field (`completed`, `cancelled`, `incomplete`, `failed`).



29
# File 'lib/openai/models/realtime/realtime_response_status.rb', line 29

optional :type, enum: -> { OpenAI::Realtime::RealtimeResponseStatus::Type }

Class Method Details

.valuesArray<Symbol>

Returns:

  • (Array<Symbol>)


# File 'lib/openai/models/realtime/realtime_response_status.rb', line 81