Class: WorkOS::AuthenticationFactorsCreateRequest

Inherits:
Types::BaseModel show all
Defined in:
lib/workos/multi_factor_auth/authentication_factors_create_request.rb

Constant Summary collapse

HASH_ATTRS =
{
  type: :type,
  phone_number: :phone_number,
  totp_issuer: :totp_issuer,
  totp_user: :totp_user,
  user_id: :user_id
}.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) ⇒ AuthenticationFactorsCreateRequest

Returns a new instance of AuthenticationFactorsCreateRequest.



22
23
24
25
26
27
28
29
# File 'lib/workos/multi_factor_auth/authentication_factors_create_request.rb', line 22

def initialize(json)
  hash = self.class.normalize(json)
  @type = hash[:type]
  @phone_number = hash[:phone_number]
  @totp_issuer = hash[:totp_issuer]
  @totp_user = hash[:totp_user]
  @user_id = hash[:user_id]
end

Instance Attribute Details

#phone_numberObject

Returns the value of attribute phone_number.



15
16
17
# File 'lib/workos/multi_factor_auth/authentication_factors_create_request.rb', line 15

def phone_number
  @phone_number
end

#totp_issuerObject

Returns the value of attribute totp_issuer.



15
16
17
# File 'lib/workos/multi_factor_auth/authentication_factors_create_request.rb', line 15

def totp_issuer
  @totp_issuer
end

#totp_userObject

Returns the value of attribute totp_user.



15
16
17
# File 'lib/workos/multi_factor_auth/authentication_factors_create_request.rb', line 15

def totp_user
  @totp_user
end

#typeObject

Returns the value of attribute type.



15
16
17
# File 'lib/workos/multi_factor_auth/authentication_factors_create_request.rb', line 15

def type
  @type
end

#user_idObject

Returns the value of attribute user_id.



15
16
17
# File 'lib/workos/multi_factor_auth/authentication_factors_create_request.rb', line 15

def user_id
  @user_id
end