Class: WorkOS::CheckAuthorization
- Inherits:
-
Types::BaseModel
- Object
- Types::BaseModel
- WorkOS::CheckAuthorization
- Defined in:
- lib/workos/authorization/check_authorization.rb
Constant Summary collapse
- HASH_ATTRS =
{ permission_slug: :permission_slug, resource_id: :resource_id, resource_external_id: :resource_external_id, resource_type_slug: :resource_type_slug }.freeze
Instance Attribute Summary collapse
-
#permission_slug ⇒ Object
Returns the value of attribute permission_slug.
-
#resource_external_id ⇒ Object
Returns the value of attribute resource_external_id.
-
#resource_id ⇒ Object
Returns the value of attribute resource_id.
-
#resource_type_slug ⇒ Object
Returns the value of attribute resource_type_slug.
Attributes inherited from Types::BaseModel
Instance Method Summary collapse
-
#initialize(json) ⇒ CheckAuthorization
constructor
A new instance of CheckAuthorization.
Methods inherited from Types::BaseModel
Methods included from HashProvider
Constructor Details
#initialize(json) ⇒ CheckAuthorization
Returns a new instance of CheckAuthorization.
20 21 22 23 24 25 26 |
# File 'lib/workos/authorization/check_authorization.rb', line 20 def initialize(json) hash = self.class.normalize(json) @permission_slug = hash[:permission_slug] @resource_id = hash[:resource_id] @resource_external_id = hash[:resource_external_id] @resource_type_slug = hash[:resource_type_slug] end |
Instance Attribute Details
#permission_slug ⇒ Object
Returns the value of attribute permission_slug.
14 15 16 |
# File 'lib/workos/authorization/check_authorization.rb', line 14 def @permission_slug end |
#resource_external_id ⇒ Object
Returns the value of attribute resource_external_id.
14 15 16 |
# File 'lib/workos/authorization/check_authorization.rb', line 14 def resource_external_id @resource_external_id end |
#resource_id ⇒ Object
Returns the value of attribute resource_id.
14 15 16 |
# File 'lib/workos/authorization/check_authorization.rb', line 14 def resource_id @resource_id end |
#resource_type_slug ⇒ Object
Returns the value of attribute resource_type_slug.
14 15 16 |
# File 'lib/workos/authorization/check_authorization.rb', line 14 def resource_type_slug @resource_type_slug end |