Class: WorkOS::SubResourceScopedRoleNotAllowedErrorBodyWithRoleSlug

Inherits:
Types::BaseModel
  • Object
show all
Defined in:
lib/workos/shared/sub_resource_scoped_role_not_allowed_error_body_with_role_slug.rb

Constant Summary collapse

HASH_ATTRS =
{
  message: :message,
  code: :code,
  role_slug: :role_slug
}.freeze

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(json) ⇒ SubResourceScopedRoleNotAllowedErrorBodyWithRoleSlug

Returns a new instance of SubResourceScopedRoleNotAllowedErrorBodyWithRoleSlug.



18
19
20
21
22
23
# File 'lib/workos/shared/sub_resource_scoped_role_not_allowed_error_body_with_role_slug.rb', line 18

def initialize(json)
  hash = self.class.normalize(json)
  @message = hash[:message]
  @code = hash[:code]
  @role_slug = hash[:role_slug]
end

Instance Attribute Details

#code ⇒ Object

Returns the value of attribute code.



13
14
15
# File 'lib/workos/shared/sub_resource_scoped_role_not_allowed_error_body_with_role_slug.rb', line 13

def code
  @code
end

#message ⇒ Object

Returns the value of attribute message.



13
14
15
# File 'lib/workos/shared/sub_resource_scoped_role_not_allowed_error_body_with_role_slug.rb', line 13

def message
  @message
end

#role_slug ⇒ Object

Returns the value of attribute role_slug.



13
14
15
# File 'lib/workos/shared/sub_resource_scoped_role_not_allowed_error_body_with_role_slug.rb', line 13

def role_slug
  @role_slug
end