Class: ThePlaidApi::LinkTokenCreateRequestBaseReport
- Inherits:
-
BaseModel
- Object
- CoreLibrary::BaseModel
- BaseModel
- ThePlaidApi::LinkTokenCreateRequestBaseReport
- Defined in:
- lib/the_plaid_api/models/link_token_create_request_base_report.rb
Overview
Specifies options for initializing Link for use with the Base Report product. This field is required if ‘assets` is included in the `products` array and the client is CRA-enabled.
Instance Attribute Summary collapse
-
#client_report_id ⇒ String
Client-generated identifier, which can be used by lenders to track loan applications.
-
#days_requested ⇒ Integer
The maximum integer number of days of history to include in the Base Report.
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(days_requested:, client_report_id: SKIP, additional_properties: nil) ⇒ LinkTokenCreateRequestBaseReport
constructor
A new instance of LinkTokenCreateRequestBaseReport.
-
#inspect ⇒ Object
Provides a debugging-friendly string with detailed object information.
-
#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(days_requested:, client_report_id: SKIP, additional_properties: nil) ⇒ LinkTokenCreateRequestBaseReport
Returns a new instance of LinkTokenCreateRequestBaseReport.
46 47 48 49 50 51 52 53 54 |
# File 'lib/the_plaid_api/models/link_token_create_request_base_report.rb', line 46 def initialize(days_requested:, client_report_id: SKIP, additional_properties: nil) # Add additional model properties to the instance additional_properties = {} if additional_properties.nil? @days_requested = days_requested @client_report_id = client_report_id unless client_report_id == SKIP @additional_properties = additional_properties end |
Instance Attribute Details
#client_report_id ⇒ String
Client-generated identifier, which can be used by lenders to track loan applications.
22 23 24 |
# File 'lib/the_plaid_api/models/link_token_create_request_base_report.rb', line 22 def client_report_id @client_report_id end |
#days_requested ⇒ Integer
The maximum integer number of days of history to include in the Base Report.
17 18 19 |
# File 'lib/the_plaid_api/models/link_token_create_request_base_report.rb', line 17 def days_requested @days_requested end |
Class Method Details
.from_hash(hash) ⇒ Object
Creates an instance of the object from a hash.
57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 |
# File 'lib/the_plaid_api/models/link_token_create_request_base_report.rb', line 57 def self.from_hash(hash) return nil unless hash # Extract variables from the hash. days_requested = hash.key?('days_requested') ? hash['days_requested'] : nil client_report_id = hash.key?('client_report_id') ? hash['client_report_id'] : 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. LinkTokenCreateRequestBaseReport.new(days_requested: days_requested, client_report_id: client_report_id, additional_properties: additional_properties) end |
.names ⇒ Object
A mapping from model property names to API property names.
25 26 27 28 29 30 |
# File 'lib/the_plaid_api/models/link_token_create_request_base_report.rb', line 25 def self.names @_hash = {} if @_hash.nil? @_hash['days_requested'] = 'days_requested' @_hash['client_report_id'] = 'client_report_id' @_hash end |
.nullables ⇒ Object
An array for nullable fields
40 41 42 43 44 |
# File 'lib/the_plaid_api/models/link_token_create_request_base_report.rb', line 40 def self.nullables %w[ client_report_id ] end |
.optionals ⇒ Object
An array for optional fields
33 34 35 36 37 |
# File 'lib/the_plaid_api/models/link_token_create_request_base_report.rb', line 33 def self.optionals %w[ client_report_id ] end |
Instance Method Details
#inspect ⇒ Object
Provides a debugging-friendly string with detailed object information.
87 88 89 90 91 |
# File 'lib/the_plaid_api/models/link_token_create_request_base_report.rb', line 87 def inspect class_name = self.class.name.split('::').last "<#{class_name} days_requested: #{@days_requested.inspect}, client_report_id:"\ " #{@client_report_id.inspect}, additional_properties: #{@additional_properties}>" end |
#to_s ⇒ Object
Provides a human-readable string representation of the object.
80 81 82 83 84 |
# File 'lib/the_plaid_api/models/link_token_create_request_base_report.rb', line 80 def to_s class_name = self.class.name.split('::').last "<#{class_name} days_requested: #{@days_requested}, client_report_id: #{@client_report_id},"\ " additional_properties: #{@additional_properties}>" end |