Class: OpenAI::Models::Beta::HostedSkillParam::SkillReference

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

Instance Attribute Summary collapse

Attributes inherited from Internal::Type::BaseModel

#last_response

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_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 ⇒ SkillReference

Returns a new instance of SkillReference.

Parameters:

  • skill_id —

    The ID of the skill created through /v1/skills.

  • version —

    The skill version, a positive integer or latest; omission selects the default.

  • type —

    The type of the object. Always skill_reference.

  • skill_id: (String)
  • version: (String, nil)
  • type: (:skill_reference)


30
31
32
33
34
# File 'sig/openai/models/beta/hosted_skill_param.rbs', line 30

def initialize: (
  skill_id: String,
  ?version: String?,
  ?type: :skill_reference
) -> void

Instance Attribute Details

#skill_id ⇒ String

The ID of the skill created through /v1/skills.

Returns:

  • (String)


23
# File 'lib/openai/models/beta/hosted_skill_param.rb', line 23

required :skill_id, String

#type ⇒ :skill_reference

The type of the object. Always skill_reference.

Returns:

  • (:skill_reference)


29
# File 'lib/openai/models/beta/hosted_skill_param.rb', line 29

required :type, const: :skill_reference

#version ⇒ String?

The skill version, a positive integer or latest; omission selects the default.

Returns:

  • (String, nil)


35
# File 'lib/openai/models/beta/hosted_skill_param.rb', line 35

optional :version, String, nil?: true

Instance Method Details

#to_hash ⇒ { skill_id: String, ?type: :skill_reference, ?version: String? }

Returns:

  • ({ skill_id: String, ?type: :skill_reference, ?version: String? })


36
37
38
39
40
# File 'sig/openai/models/beta/hosted_skill_param.rbs', line 36

def to_hash: -> {
  skill_id: String,
  ?type: :skill_reference,
  ?version: String?
}