Class: ThePlaidApi::BeaconUserUpdateResponse
- Inherits:
-
BaseModel
- Object
- CoreLibrary::BaseModel
- BaseModel
- ThePlaidApi::BeaconUserUpdateResponse
- Defined in:
- lib/the_plaid_api/models/beacon_user_update_response.rb
Overview
A Beacon User represents an end user that has been scanned against the Beacon Network.
Instance Attribute Summary collapse
-
#audit_trail ⇒ BeaconAuditTrail
Information about the last change made to the parent object specifying what caused the change as well as when it occurred.
-
#client_user_id ⇒ String
A unique ID that identifies the end user in your system.
-
#created_at ⇒ DateTime
An ISO8601 formatted timestamp.
-
#id ⇒ String
ID of the associated Beacon User.
-
#item_ids ⇒ Array[String]
An array of Plaid Item IDs corresponding to the Accounts associated with this Beacon User.
-
#program_id ⇒ String
ID of the associated Beacon Program.
-
#request_id ⇒ String
A unique identifier for the request, which can be used for troubleshooting.
-
#status ⇒ BeaconUserStatus
A status of a Beacon User.
-
#updated_at ⇒ DateTime
An ISO8601 formatted timestamp.
-
#user ⇒ BeaconUserData
A Beacon User’s data and resulting analysis when checked against duplicate records and the Beacon Fraud Network.
-
#version ⇒ Integer
The ‘version` field begins with 1 and increments each time the user is updated.
Class Method Summary collapse
-
.from_hash(hash) ⇒ Object
Creates an instance of the object from a hash.
-
.names ⇒ Object
A mapping from model property names to API property names.
-
.nullables ⇒ Object
An array for nullable fields.
-
.optionals ⇒ Object
An array for optional fields.
Instance Method Summary collapse
-
#initialize(item_ids:, id:, version:, created_at:, updated_at:, status:, program_id:, client_user_id:, user:, audit_trail:, request_id:, additional_properties: nil) ⇒ BeaconUserUpdateResponse
constructor
A new instance of BeaconUserUpdateResponse.
-
#inspect ⇒ Object
Provides a debugging-friendly string with detailed object information.
- #to_custom_created_at ⇒ Object
- #to_custom_updated_at ⇒ Object
-
#to_s ⇒ Object
Provides a human-readable string representation of the object.
Methods inherited from BaseModel
#check_for_conflict, #process_additional_properties, #process_array, #process_basic_value, #process_hash, #to_hash, #to_json
Constructor Details
#initialize(item_ids:, id:, version:, created_at:, updated_at:, status:, program_id:, client_user_id:, user:, audit_trail:, request_id:, additional_properties: nil) ⇒ BeaconUserUpdateResponse
Returns a new instance of BeaconUserUpdateResponse.
102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 |
# File 'lib/the_plaid_api/models/beacon_user_update_response.rb', line 102 def initialize(item_ids:, id:, version:, created_at:, updated_at:, status:, program_id:, client_user_id:, user:, audit_trail:, request_id:, additional_properties: nil) # Add additional model properties to the instance additional_properties = {} if additional_properties.nil? @item_ids = item_ids @id = id @version = version @created_at = created_at @updated_at = updated_at @status = status @program_id = program_id @client_user_id = client_user_id @user = user @audit_trail = audit_trail @request_id = request_id @additional_properties = additional_properties end |
Instance Attribute Details
#audit_trail ⇒ BeaconAuditTrail
Information about the last change made to the parent object specifying what caused the change as well as when it occurred.
67 68 69 |
# File 'lib/the_plaid_api/models/beacon_user_update_response.rb', line 67 def audit_trail @audit_trail end |
#client_user_id ⇒ String
A unique ID that identifies the end user in your system. Either a ‘user_id` or the `client_user_id` must be provided. This ID can also be used to associate user-specific data from other Plaid products. Financial Account Matching requires this field and the `/link/token/create` `client_user_id` to be consistent. Personally identifiable information, such as an email address or phone number, should not be used in the `client_user_id`.
57 58 59 |
# File 'lib/the_plaid_api/models/beacon_user_update_response.rb', line 57 def client_user_id @client_user_id end |
#created_at ⇒ DateTime
An ISO8601 formatted timestamp.
30 31 32 |
# File 'lib/the_plaid_api/models/beacon_user_update_response.rb', line 30 def created_at @created_at end |
#id ⇒ String
ID of the associated Beacon User.
21 22 23 |
# File 'lib/the_plaid_api/models/beacon_user_update_response.rb', line 21 def id @id end |
#item_ids ⇒ Array[String]
An array of Plaid Item IDs corresponding to the Accounts associated with this Beacon User.
17 18 19 |
# File 'lib/the_plaid_api/models/beacon_user_update_response.rb', line 17 def item_ids @item_ids end |
#program_id ⇒ String
ID of the associated Beacon Program.
47 48 49 |
# File 'lib/the_plaid_api/models/beacon_user_update_response.rb', line 47 def program_id @program_id end |
#request_id ⇒ String
A unique identifier for the request, which can be used for troubleshooting. This identifier, like all Plaid identifiers, is case sensitive.
73 74 75 |
# File 'lib/the_plaid_api/models/beacon_user_update_response.rb', line 73 def request_id @request_id end |
#status ⇒ BeaconUserStatus
A status of a Beacon User. ‘rejected`: The Beacon User has been rejected for fraud. Users can be automatically or manually rejected. `pending_review`: The Beacon User has been marked for review. `cleared`: The Beacon User has been cleared of fraud.
43 44 45 |
# File 'lib/the_plaid_api/models/beacon_user_update_response.rb', line 43 def status @status end |
#updated_at ⇒ DateTime
An ISO8601 formatted timestamp. This field indicates the last time the resource was modified.
35 36 37 |
# File 'lib/the_plaid_api/models/beacon_user_update_response.rb', line 35 def updated_at @updated_at end |
#user ⇒ BeaconUserData
A Beacon User’s data and resulting analysis when checked against duplicate records and the Beacon Fraud Network.
62 63 64 |
# File 'lib/the_plaid_api/models/beacon_user_update_response.rb', line 62 def user @user end |
#version ⇒ Integer
The ‘version` field begins with 1 and increments each time the user is updated.
26 27 28 |
# File 'lib/the_plaid_api/models/beacon_user_update_response.rb', line 26 def version @version end |
Class Method Details
.from_hash(hash) ⇒ Object
Creates an instance of the object from a hash.
123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 |
# File 'lib/the_plaid_api/models/beacon_user_update_response.rb', line 123 def self.from_hash(hash) return nil unless hash # Extract variables from the hash. item_ids = hash.key?('item_ids') ? hash['item_ids'] : nil id = hash.key?('id') ? hash['id'] : nil version = hash.key?('version') ? hash['version'] : nil created_at = if hash.key?('created_at') (DateTimeHelper.from_rfc3339(hash['created_at']) if hash['created_at']) end updated_at = if hash.key?('updated_at') (DateTimeHelper.from_rfc3339(hash['updated_at']) if hash['updated_at']) end status = hash.key?('status') ? hash['status'] : nil program_id = hash.key?('program_id') ? hash['program_id'] : nil client_user_id = hash.key?('client_user_id') ? hash['client_user_id'] : nil user = BeaconUserData.from_hash(hash['user']) if hash['user'] audit_trail = BeaconAuditTrail.from_hash(hash['audit_trail']) if hash['audit_trail'] request_id = hash.key?('request_id') ? hash['request_id'] : nil # Create a new hash for additional properties, removing known properties. new_hash = hash.reject { |k, _| names.value?(k) } additional_properties = APIHelper.get_additional_properties( new_hash, proc { |value| value } ) # Create object from extracted values. BeaconUserUpdateResponse.new(item_ids: item_ids, id: id, version: version, created_at: created_at, updated_at: updated_at, status: status, program_id: program_id, client_user_id: client_user_id, user: user, audit_trail: audit_trail, request_id: request_id, additional_properties: additional_properties) end |
.names ⇒ Object
A mapping from model property names to API property names.
76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 |
# File 'lib/the_plaid_api/models/beacon_user_update_response.rb', line 76 def self.names @_hash = {} if @_hash.nil? @_hash['item_ids'] = 'item_ids' @_hash['id'] = 'id' @_hash['version'] = 'version' @_hash['created_at'] = 'created_at' @_hash['updated_at'] = 'updated_at' @_hash['status'] = 'status' @_hash['program_id'] = 'program_id' @_hash['client_user_id'] = 'client_user_id' @_hash['user'] = 'user' @_hash['audit_trail'] = 'audit_trail' @_hash['request_id'] = 'request_id' @_hash end |
.nullables ⇒ Object
An array for nullable fields
98 99 100 |
# File 'lib/the_plaid_api/models/beacon_user_update_response.rb', line 98 def self.nullables [] end |
.optionals ⇒ Object
An array for optional fields
93 94 95 |
# File 'lib/the_plaid_api/models/beacon_user_update_response.rb', line 93 def self.optionals [] end |
Instance Method Details
#inspect ⇒ Object
Provides a debugging-friendly string with detailed object information.
185 186 187 188 189 190 191 192 193 |
# File 'lib/the_plaid_api/models/beacon_user_update_response.rb', line 185 def inspect class_name = self.class.name.split('::').last "<#{class_name} item_ids: #{@item_ids.inspect}, id: #{@id.inspect}, version:"\ " #{@version.inspect}, created_at: #{@created_at.inspect}, updated_at:"\ " #{@updated_at.inspect}, status: #{@status.inspect}, program_id: #{@program_id.inspect},"\ " client_user_id: #{@client_user_id.inspect}, user: #{@user.inspect}, audit_trail:"\ " #{@audit_trail.inspect}, request_id: #{@request_id.inspect}, additional_properties:"\ " #{@additional_properties}>" end |
#to_custom_created_at ⇒ Object
166 167 168 |
# File 'lib/the_plaid_api/models/beacon_user_update_response.rb', line 166 def to_custom_created_at DateTimeHelper.to_rfc3339(created_at) end |
#to_custom_updated_at ⇒ Object
170 171 172 |
# File 'lib/the_plaid_api/models/beacon_user_update_response.rb', line 170 def to_custom_updated_at DateTimeHelper.to_rfc3339(updated_at) end |
#to_s ⇒ Object
Provides a human-readable string representation of the object.
175 176 177 178 179 180 181 182 |
# File 'lib/the_plaid_api/models/beacon_user_update_response.rb', line 175 def to_s class_name = self.class.name.split('::').last "<#{class_name} item_ids: #{@item_ids}, id: #{@id}, version: #{@version}, created_at:"\ " #{@created_at}, updated_at: #{@updated_at}, status: #{@status}, program_id:"\ " #{@program_id}, client_user_id: #{@client_user_id}, user: #{@user}, audit_trail:"\ " #{@audit_trail}, request_id: #{@request_id}, additional_properties:"\ " #{@additional_properties}>" end |