Class: WorkOS::CreateObjectRequest

Inherits:
Types::BaseModel show all
Defined in:
lib/workos/vault/create_object_request.rb

Constant Summary collapse

HASH_ATTRS =
{
  key_context: :key_context,
  name: :name,
  value: :value
}.freeze

Instance Attribute Summary collapse

Attributes inherited from Types::BaseModel

#last_response

Instance Method Summary collapse

Methods inherited from Types::BaseModel

normalize

Methods included from HashProvider

#inspect, #to_h, #to_json

Constructor Details

#initialize(json) ⇒ CreateObjectRequest

Returns a new instance of CreateObjectRequest.



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

def initialize(json)
  hash = self.class.normalize(json)
  @key_context = hash[:key_context] || {}
  @name = hash[:name]
  @value = hash[:value]
end

Instance Attribute Details

#key_contextObject

Returns the value of attribute key_context.



13
14
15
# File 'lib/workos/vault/create_object_request.rb', line 13

def key_context
  @key_context
end

#nameObject

Returns the value of attribute name.



13
14
15
# File 'lib/workos/vault/create_object_request.rb', line 13

def name
  @name
end

#valueObject

Returns the value of attribute value.



13
14
15
# File 'lib/workos/vault/create_object_request.rb', line 13

def value
  @value
end