Class: OpenAI::Models::Realtime::ClientSecretCreateParams

Inherits:
Internal::Type::BaseModel show all
Extended by:
Internal::Type::RequestParameters::Converter
Includes:
Internal::Type::RequestParameters
Defined in:
lib/openai/models/realtime/client_secret_create_params.rb,
sig/openai/models/realtime/client_secret_create_params.rbs

Overview

See Also:

  • OpenAI::Resources::Realtime::ClientSecrets#create

Defined Under Namespace

Modules: Session Classes: ExpiresAfter

Instance Attribute Summary collapse

Attributes included from Internal::Type::RequestParameters

#request_options

Attributes inherited from Internal::Type::BaseModel

#last_response

Class Method Summary collapse

Instance Method Summary collapse

Methods included from Internal::Type::RequestParameters::Converter

dump_request

Methods included from Internal::Type::RequestParameters

included

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_cached, coerce_with_error, #dump, dump, #inspect, inspect, meta_info, new_coerce_state, resolve_type, 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 ⇒ ClientSecretCreateParams

Returns a new instance of ClientSecretCreateParams.

Parameters:

  • expires_after —

    Configuration for the client secret expiration. Expiration refers to the time after which a client secret will no longer be valid for creating sessions. The session itself may continue after that time once started. A secret can be used to create multiple sessions until it expires.

  • session —

    Session configuration to use for the client secret. Choose either a realtime session or a transcription session.

  • expires_after: (OpenAI::Realtime::ClientSecretCreateParams::ExpiresAfter)
  • session: (OpenAI::Models::Realtime::ClientSecretCreateParams::session)
  • request_options: (OpenAI::request_opts)


47
48
49
50
51
# File 'sig/openai/models/realtime/client_secret_create_params.rbs', line 47

def initialize: (
  ?expires_after: OpenAI::Realtime::ClientSecretCreateParams::ExpiresAfter,
  ?session: OpenAI::Models::Realtime::ClientSecretCreateParams::session,
  ?request_options: OpenAI::request_opts
) -> void

Instance Attribute Details

#expires_after ⇒ OpenAI::Realtime::ClientSecretCreateParams::ExpiresAfter?

Configuration for the client secret expiration. Expiration refers to the time after which a client secret will no longer be valid for creating sessions. The session itself may continue after that time once started. A secret can be used to create multiple sessions until it expires.

Returns:

  • (OpenAI::Realtime::ClientSecretCreateParams::ExpiresAfter, nil)


18
# File 'lib/openai/models/realtime/client_secret_create_params.rb', line 18

optional :expires_after, -> { OpenAI::Realtime::ClientSecretCreateParams::ExpiresAfter }

#session ⇒ OpenAI::Models::Realtime::ClientSecretCreateParams::session?

Session configuration to use for the client secret. Choose either a realtime session or a transcription session.

Returns:

  • (OpenAI::Models::Realtime::ClientSecretCreateParams::session, nil)


25
# File 'lib/openai/models/realtime/client_secret_create_params.rb', line 25

optional :session, union: -> { OpenAI::Realtime::ClientSecretCreateParams::Session }

Class Method Details

.values ⇒ Array<Symbol>

Returns:

  • (Array<Symbol>)


# File 'lib/openai/models/realtime/client_secret_create_params.rb', line 83

Instance Method Details

#to_hash ⇒ { ?expires_after: OpenAI::Realtime::ClientSecretCreateParams::ExpiresAfter, ?session: OpenAI::Models::Realtime::ClientSecretCreateParams::session, ?request_options: OpenAI::RequestOptions }

Returns:

  • ({ ?expires_after: OpenAI::Realtime::ClientSecretCreateParams::ExpiresAfter, ?session: OpenAI::Models::Realtime::ClientSecretCreateParams::session, ?request_options: OpenAI::RequestOptions })


53
54
55
56
57
# File 'sig/openai/models/realtime/client_secret_create_params.rbs', line 53

def to_hash: -> {
  ?expires_after: OpenAI::Realtime::ClientSecretCreateParams::ExpiresAfter,
  ?session: OpenAI::Models::Realtime::ClientSecretCreateParams::session,
  ?request_options: OpenAI::RequestOptions
}