Class: OpenAI::Models::Admin::Organization::RoleUpdateParams

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

Overview

See Also:

  • OpenAI::Resources::Admin::Organization::Roles#update

Instance Attribute Summary collapse

Attributes included from Internal::Type::RequestParameters

#request_options

Attributes inherited from Internal::Type::BaseModel

#last_response

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(role_id:, description: nil, permissions: nil, role_name: nil, request_options: {}) ⇒ RoleUpdateParams

Returns a new instance of RoleUpdateParams.

Parameters:

  • description (defaults to: nil) —

    New description for the role.

  • permissions (defaults to: nil) —

    Updated set of permissions for the role.

  • role_name (defaults to: nil) —

    New name for the role.

  • role_id: (String)
  • description: (String, nil) (defaults to: nil)
  • permissions: (::Array[String], nil) (defaults to: nil)
  • role_name: (String, nil) (defaults to: nil)
  • request_options: (OpenAI::request_opts) (defaults to: {})


# File 'lib/openai/models/admin/organization/role_update_params.rb', line 35

Instance Attribute Details

#description ⇒ String?

New description for the role.

Returns:

  • (String, nil)


21
# File 'lib/openai/models/admin/organization/role_update_params.rb', line 21

optional :description, String, nil?: true

#permissions ⇒ ::Array[String]?

Updated set of permissions for the role.

Returns:

  • (::Array[String], nil)


27
# File 'lib/openai/models/admin/organization/role_update_params.rb', line 27

optional :permissions, OpenAI::Internal::Type::ArrayOf[String], nil?: true

#role_id ⇒ String

Parameters:

  • value (String)

Returns:

  • (String)


15
# File 'lib/openai/models/admin/organization/role_update_params.rb', line 15

required :role_id, String

#role_name ⇒ String?

New name for the role.

Returns:

  • (String, nil)


33
# File 'lib/openai/models/admin/organization/role_update_params.rb', line 33

optional :role_name, String, nil?: true

Instance Method Details

#to_hash ⇒ { role_id: String, ?description: String?, ?permissions: ::Array[String]?, ?role_name: String?, ?request_options: OpenAI::RequestOptions }

Returns:

  • ({ role_id: String, ?description: String?, ?permissions: ::Array[String]?, ?role_name: String?, ?request_options: OpenAI::RequestOptions })


43
44
45
46
47
48
49
# File 'sig/openai/models/admin/organization/role_update_params.rbs', line 43

def to_hash: -> {
  role_id: String,
  ?description: String?,
  ?permissions: ::Array[String]?,
  ?role_name: String?,
  ?request_options: OpenAI::RequestOptions
}