Class: ThePlaidApi::EntityScreeningHitAnalysis

Inherits:
BaseModel
  • Object
show all
Defined in:
lib/the_plaid_api/models/entity_screening_hit_analysis.rb

Overview

Analysis information describing why a screening hit matched the provided entity information

Instance Attribute Summary collapse

Class Method Summary collapse

Instance Method Summary collapse

Methods inherited from BaseModel

#check_for_conflict, #process_additional_properties, #process_array, #process_basic_value, #process_hash, #to_hash, #to_json

Constructor Details

#initialize(search_terms_version:, documents: SKIP, email_addresses: SKIP, locations: SKIP, names: SKIP, phone_numbers: SKIP, urls: SKIP, additional_properties: nil) ⇒ EntityScreeningHitAnalysis

Returns a new instance of EntityScreeningHitAnalysis.



142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
# File 'lib/the_plaid_api/models/entity_screening_hit_analysis.rb', line 142

def initialize(search_terms_version:, documents: SKIP,
               email_addresses: SKIP, locations: SKIP, names: SKIP,
               phone_numbers: SKIP, urls: SKIP, additional_properties: nil)
  # Add additional model properties to the instance
  additional_properties = {} if additional_properties.nil?

  @documents = documents unless documents == SKIP
  @email_addresses = email_addresses unless email_addresses == SKIP
  @locations = locations unless locations == SKIP
  @names = names unless names == SKIP
  @phone_numbers = phone_numbers unless phone_numbers == SKIP
  @urls = urls unless urls == SKIP
  @search_terms_version = search_terms_version
  @additional_properties = additional_properties
end

Instance Attribute Details

#documentsMatchSummaryCode1

An enum indicating the match type between data provided by user and data checked against an external data source. ‘match` indicates that the provided input data was a strong match against external data. `partial_match` indicates the data approximately matched against external data. For example, “Knope” vs. “Knope-Wyatt” for last name. `no_match` indicates that Plaid was able to perform a check against an external data source and it did not match the provided input data. `no_data` indicates that Plaid was unable to find external data to compare against the provided input data. `no_input` indicates that Plaid was unable to perform a check because no information was provided for this field by the end user.

Returns:



26
27
28
# File 'lib/the_plaid_api/models/entity_screening_hit_analysis.rb', line 26

def documents
  @documents
end

#email_addressesMatchSummaryCode1

An enum indicating the match type between data provided by user and data checked against an external data source. ‘match` indicates that the provided input data was a strong match against external data. `partial_match` indicates the data approximately matched against external data. For example, “Knope” vs. “Knope-Wyatt” for last name. `no_match` indicates that Plaid was able to perform a check against an external data source and it did not match the provided input data. `no_data` indicates that Plaid was unable to find external data to compare against the provided input data. `no_input` indicates that Plaid was unable to perform a check because no information was provided for this field by the end user.

Returns:



41
42
43
# File 'lib/the_plaid_api/models/entity_screening_hit_analysis.rb', line 41

def email_addresses
  @email_addresses
end

#locationsMatchSummaryCode1

An enum indicating the match type between data provided by user and data checked against an external data source. ‘match` indicates that the provided input data was a strong match against external data. `partial_match` indicates the data approximately matched against external data. For example, “Knope” vs. “Knope-Wyatt” for last name. `no_match` indicates that Plaid was able to perform a check against an external data source and it did not match the provided input data. `no_data` indicates that Plaid was unable to find external data to compare against the provided input data. `no_input` indicates that Plaid was unable to perform a check because no information was provided for this field by the end user.

Returns:



56
57
58
# File 'lib/the_plaid_api/models/entity_screening_hit_analysis.rb', line 56

def locations
  @locations
end

#namesMatchSummaryCode1

An enum indicating the match type between data provided by user and data checked against an external data source. ‘match` indicates that the provided input data was a strong match against external data. `partial_match` indicates the data approximately matched against external data. For example, “Knope” vs. “Knope-Wyatt” for last name. `no_match` indicates that Plaid was able to perform a check against an external data source and it did not match the provided input data. `no_data` indicates that Plaid was unable to find external data to compare against the provided input data. `no_input` indicates that Plaid was unable to perform a check because no information was provided for this field by the end user.

Returns:



71
72
73
# File 'lib/the_plaid_api/models/entity_screening_hit_analysis.rb', line 71

def names
  @names
end

#phone_numbersMatchSummaryCode1

An enum indicating the match type between data provided by user and data checked against an external data source. ‘match` indicates that the provided input data was a strong match against external data. `partial_match` indicates the data approximately matched against external data. For example, “Knope” vs. “Knope-Wyatt” for last name. `no_match` indicates that Plaid was able to perform a check against an external data source and it did not match the provided input data. `no_data` indicates that Plaid was unable to find external data to compare against the provided input data. `no_input` indicates that Plaid was unable to perform a check because no information was provided for this field by the end user.

Returns:



86
87
88
# File 'lib/the_plaid_api/models/entity_screening_hit_analysis.rb', line 86

def phone_numbers
  @phone_numbers
end

#search_terms_versionInteger

The version of the entity screening’s ‘search_terms` that were compared when the entity screening hit was added. entity screening hits are immutable once they have been reviewed. If changes are detected due to updates to the entity screening’s ‘search_terms`, the associated entity program, or the list’s source data prior to review, the entity screening hit will be updated to reflect those changes.

Returns:

  • (Integer)


110
111
112
# File 'lib/the_plaid_api/models/entity_screening_hit_analysis.rb', line 110

def search_terms_version
  @search_terms_version
end

#urlsMatchSummaryCode1

An enum indicating the match type between data provided by user and data checked against an external data source. ‘match` indicates that the provided input data was a strong match against external data. `partial_match` indicates the data approximately matched against external data. For example, “Knope” vs. “Knope-Wyatt” for last name. `no_match` indicates that Plaid was able to perform a check against an external data source and it did not match the provided input data. `no_data` indicates that Plaid was unable to find external data to compare against the provided input data. `no_input` indicates that Plaid was unable to perform a check because no information was provided for this field by the end user.

Returns:



101
102
103
# File 'lib/the_plaid_api/models/entity_screening_hit_analysis.rb', line 101

def urls
  @urls
end

Class Method Details

.from_hash(hash) ⇒ Object

Creates an instance of the object from a hash.



159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
# File 'lib/the_plaid_api/models/entity_screening_hit_analysis.rb', line 159

def self.from_hash(hash)
  return nil unless hash

  # Extract variables from the hash.
  search_terms_version =
    hash.key?('search_terms_version') ? hash['search_terms_version'] : nil
  documents = hash.key?('documents') ? hash['documents'] : SKIP
  email_addresses =
    hash.key?('email_addresses') ? hash['email_addresses'] : SKIP
  locations = hash.key?('locations') ? hash['locations'] : SKIP
  names = hash.key?('names') ? hash['names'] : SKIP
  phone_numbers = hash.key?('phone_numbers') ? hash['phone_numbers'] : SKIP
  urls = hash.key?('urls') ? hash['urls'] : SKIP

  # 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.
  EntityScreeningHitAnalysis.new(search_terms_version: search_terms_version,
                                 documents: documents,
                                 email_addresses: email_addresses,
                                 locations: locations,
                                 names: names,
                                 phone_numbers: phone_numbers,
                                 urls: urls,
                                 additional_properties: additional_properties)
end

.namesObject

A mapping from model property names to API property names.



113
114
115
116
117
118
119
120
121
122
123
# File 'lib/the_plaid_api/models/entity_screening_hit_analysis.rb', line 113

def self.names
  @_hash = {} if @_hash.nil?
  @_hash['documents'] = 'documents'
  @_hash['email_addresses'] = 'email_addresses'
  @_hash['locations'] = 'locations'
  @_hash['names'] = 'names'
  @_hash['phone_numbers'] = 'phone_numbers'
  @_hash['urls'] = 'urls'
  @_hash['search_terms_version'] = 'search_terms_version'
  @_hash
end

.nullablesObject

An array for nullable fields



138
139
140
# File 'lib/the_plaid_api/models/entity_screening_hit_analysis.rb', line 138

def self.nullables
  []
end

.optionalsObject

An array for optional fields



126
127
128
129
130
131
132
133
134
135
# File 'lib/the_plaid_api/models/entity_screening_hit_analysis.rb', line 126

def self.optionals
  %w[
    documents
    email_addresses
    locations
    names
    phone_numbers
    urls
  ]
end

Instance Method Details

#inspectObject

Provides a debugging-friendly string with detailed object information.



201
202
203
204
205
206
207
# File 'lib/the_plaid_api/models/entity_screening_hit_analysis.rb', line 201

def inspect
  class_name = self.class.name.split('::').last
  "<#{class_name} documents: #{@documents.inspect}, email_addresses:"\
  " #{@email_addresses.inspect}, locations: #{@locations.inspect}, names: #{@names.inspect},"\
  " phone_numbers: #{@phone_numbers.inspect}, urls: #{@urls.inspect}, search_terms_version:"\
  " #{@search_terms_version.inspect}, additional_properties: #{@additional_properties}>"
end

#to_sObject

Provides a human-readable string representation of the object.



192
193
194
195
196
197
198
# File 'lib/the_plaid_api/models/entity_screening_hit_analysis.rb', line 192

def to_s
  class_name = self.class.name.split('::').last
  "<#{class_name} documents: #{@documents}, email_addresses: #{@email_addresses}, locations:"\
  " #{@locations}, names: #{@names}, phone_numbers: #{@phone_numbers}, urls: #{@urls},"\
  " search_terms_version: #{@search_terms_version}, additional_properties:"\
  " #{@additional_properties}>"
end