Class: Rafflesia::ApiKeyCreateResponse

Inherits:
Types::BaseModel
  • Object
show all
Defined in:
lib/rafflesia/api_keys/api_key_create_response.rb

Constant Summary collapse

HASH_ATTRS =
{
  created_at: :created_at,
  id: :id,
  key: :key,
  key_prefix: :key_prefix,
  name: :name
}.freeze

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(json) ⇒ ApiKeyCreateResponse

Returns a new instance of ApiKeyCreateResponse.



23
24
25
26
27
28
29
30
31
# File 'lib/rafflesia/api_keys/api_key_create_response.rb', line 23

def initialize(json)
  super()
  hash = self.class.normalize(json)
  @created_at = hash[:created_at]
  @id = hash[:id]
  @key = hash[:key]
  @key_prefix = hash[:key_prefix]
  @name = hash[:name]
end

Instance Attribute Details

#created_atObject

Returns the value of attribute created_at.



16
17
18
# File 'lib/rafflesia/api_keys/api_key_create_response.rb', line 16

def created_at
  @created_at
end

#idObject

Returns the value of attribute id.



16
17
18
# File 'lib/rafflesia/api_keys/api_key_create_response.rb', line 16

def id
  @id
end

#keyObject

Returns the value of attribute key.



16
17
18
# File 'lib/rafflesia/api_keys/api_key_create_response.rb', line 16

def key
  @key
end

#key_prefixObject

Returns the value of attribute key_prefix.



16
17
18
# File 'lib/rafflesia/api_keys/api_key_create_response.rb', line 16

def key_prefix
  @key_prefix
end

#nameObject

Returns the value of attribute name.



16
17
18
# File 'lib/rafflesia/api_keys/api_key_create_response.rb', line 16

def name
  @name
end