Class: OpenAI::Models::ContainerCreateParams

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

Overview

See Also:

  • OpenAI::Resources::Containers#create

Defined Under Namespace

Modules: MemoryLimit, NetworkPolicy, Skill 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_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

#initializeObject

Parameters:

  • name

    Name of the container to create.

  • expires_after

    Container expiration time in seconds relative to the 'anchor' time.

  • file_ids

    IDs of files to copy to the container.

  • memory_limit

    Optional memory limit for the container. Defaults to "1g".

  • network_policy

    Network access policy for the container.

  • skills

    An optional list of skills referenced by id or inline data.



71
# File 'sig/openai/models/container_create_params.rbs', line 71

def initialize: (

Instance Attribute Details

#expires_afterOpenAI::ContainerCreateParams::ExpiresAfter?

Container expiration time in seconds relative to the 'anchor' time.

Returns:

  • (OpenAI::ContainerCreateParams::ExpiresAfter, nil)


20
# File 'lib/openai/models/container_create_params.rb', line 20

optional :expires_after, -> { OpenAI::ContainerCreateParams::ExpiresAfter }

#file_ids::Array[String]?

IDs of files to copy to the container.

Returns:

  • (::Array[String], nil)


26
# File 'lib/openai/models/container_create_params.rb', line 26

optional :file_ids, OpenAI::Internal::Type::ArrayOf[String]

#memory_limitOpenAI::Models::ContainerCreateParams::memory_limit?

Optional memory limit for the container. Defaults to "1g".

Returns:

  • (OpenAI::Models::ContainerCreateParams::memory_limit, nil)


32
# File 'lib/openai/models/container_create_params.rb', line 32

optional :memory_limit, enum: -> { OpenAI::ContainerCreateParams::MemoryLimit }

#nameString

Name of the container to create.

Returns:

  • (String)


14
# File 'lib/openai/models/container_create_params.rb', line 14

required :name, String

#network_policyOpenAI::Models::ContainerCreateParams::network_policy?

Network access policy for the container.

Returns:

  • (OpenAI::Models::ContainerCreateParams::network_policy, nil)


38
# File 'lib/openai/models/container_create_params.rb', line 38

optional :network_policy, union: -> { OpenAI::ContainerCreateParams::NetworkPolicy }

#skills::Array[OpenAI::Models::ContainerCreateParams::skill]?

An optional list of skills referenced by id or inline data.

Returns:

  • (::Array[OpenAI::Models::ContainerCreateParams::skill], nil)


44
# File 'lib/openai/models/container_create_params.rb', line 44

optional :skills, -> { OpenAI::Internal::Type::ArrayOf[union: OpenAI::ContainerCreateParams::Skill] }

Class Method Details

.valuesArray<Symbol>

Returns:

  • (Array<Symbol>)


# File 'lib/openai/models/container_create_params.rb', line 98

.variantsArray(OpenAI::Models::Responses::ContainerNetworkPolicyDisabled, OpenAI::Models::Responses::ContainerNetworkPolicyAllowlist)



# File 'lib/openai/models/container_create_params.rb', line 126

Instance Method Details

#to_hash{

Returns:

  • ({)


81
# File 'sig/openai/models/container_create_params.rbs', line 81

def to_hash: -> {