Class: LockstepSdk::MagicLinkStatusModel
- Inherits:
-
Object
- Object
- LockstepSdk::MagicLinkStatusModel
- Defined in:
- lib/lockstep_sdk/models/magic_link_status_model.rb
Overview
Contains information about the user’s magic link
Instance Attribute Summary collapse
-
#accounting_profile_id ⇒ Uuid
The id of the accounting profile for the Magic Link.
-
#application_id ⇒ Uuid
The id of the application for the Magic Link.
-
#company_id ⇒ Uuid
The id of the target company for the Magic Link.
-
#expires ⇒ Date-time
The UTC date and time when this magic link expires.
-
#magic_link_id ⇒ Uuid
The id of the Magic link used to authenticate.
Instance Method Summary collapse
-
#as_json(options = {}) ⇒ object
This object as a JSON key-value structure.
-
#initialize(params = {}) ⇒ MagicLinkStatusModel
constructor
Initialize the MagicLinkStatusModel using the provided prototype.
-
#to_json(*options) ⇒ String
This object converted to a JSON string.
Constructor Details
#initialize(params = {}) ⇒ MagicLinkStatusModel
Initialize the MagicLinkStatusModel using the provided prototype
25 26 27 28 29 30 31 |
# File 'lib/lockstep_sdk/models/magic_link_status_model.rb', line 25 def initialize(params = {}) @magic_link_id = params.dig(:magic_link_id) @application_id = params.dig(:application_id) @company_id = params.dig(:company_id) @accounting_profile_id = params.dig(:accounting_profile_id) @expires = params.dig(:expires) end |
Instance Attribute Details
#accounting_profile_id ⇒ Uuid
Returns The id of the accounting profile for the Magic Link.
47 48 49 |
# File 'lib/lockstep_sdk/models/magic_link_status_model.rb', line 47 def accounting_profile_id @accounting_profile_id end |
#application_id ⇒ Uuid
Returns The id of the application for the Magic Link.
39 40 41 |
# File 'lib/lockstep_sdk/models/magic_link_status_model.rb', line 39 def application_id @application_id end |
#company_id ⇒ Uuid
Returns The id of the target company for the Magic Link.
43 44 45 |
# File 'lib/lockstep_sdk/models/magic_link_status_model.rb', line 43 def company_id @company_id end |
#expires ⇒ Date-time
Returns The UTC date and time when this magic link expires.
51 52 53 |
# File 'lib/lockstep_sdk/models/magic_link_status_model.rb', line 51 def expires @expires end |
#magic_link_id ⇒ Uuid
Returns The id of the Magic link used to authenticate.
35 36 37 |
# File 'lib/lockstep_sdk/models/magic_link_status_model.rb', line 35 def magic_link_id @magic_link_id end |
Instance Method Details
#as_json(options = {}) ⇒ object
Returns This object as a JSON key-value structure.
55 56 57 58 59 60 61 62 63 |
# File 'lib/lockstep_sdk/models/magic_link_status_model.rb', line 55 def as_json(={}) { 'magicLinkId' => @magic_link_id, 'applicationId' => @application_id, 'companyId' => @company_id, 'accountingProfileId' => @accounting_profile_id, 'expires' => @expires, } end |
#to_json(*options) ⇒ String
Returns This object converted to a JSON string.
67 68 69 |
# File 'lib/lockstep_sdk/models/magic_link_status_model.rb', line 67 def to_json(*) "[#{as_json(*).to_json(*)}]" end |