Class: Plaid::ProcessorBalanceGetRequestOptions
- Inherits:
-
BaseModel
- Object
- CoreLibrary::BaseModel
- BaseModel
- Plaid::ProcessorBalanceGetRequestOptions
- Defined in:
- lib/plaid/models/processor_balance_get_request_options.rb
Overview
An optional object to filter ‘/processor/balance/get` results.
Instance Attribute Summary collapse
-
#min_last_updated_datetime ⇒ DateTime
Timestamp in [ISO 8601](wikipedia.org/wiki/ISO_8601) format (‘YYYY-MM-DDTHH:mm:ssZ`) indicating the oldest acceptable balance when making a request to `/accounts/balance/get`.
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(min_last_updated_datetime: SKIP, additional_properties: nil) ⇒ ProcessorBalanceGetRequestOptions
constructor
A new instance of ProcessorBalanceGetRequestOptions.
-
#inspect ⇒ Object
Provides a debugging-friendly string with detailed object information.
- #to_custom_min_last_updated_datetime ⇒ 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(min_last_updated_datetime: SKIP, additional_properties: nil) ⇒ ProcessorBalanceGetRequestOptions
Returns a new instance of ProcessorBalanceGetRequestOptions.
46 47 48 49 50 51 52 53 54 55 |
# File 'lib/plaid/models/processor_balance_get_request_options.rb', line 46 def initialize(min_last_updated_datetime: SKIP, additional_properties: nil) # Add additional model properties to the instance additional_properties = {} if additional_properties.nil? unless min_last_updated_datetime == SKIP @min_last_updated_datetime = min_last_updated_datetime end @additional_properties = additional_properties end |
Instance Attribute Details
#min_last_updated_datetime ⇒ DateTime
Timestamp in [ISO 8601](wikipedia.org/wiki/ISO_8601) format (‘YYYY-MM-DDTHH:mm:ssZ`) indicating the oldest acceptable balance when making a request to `/accounts/balance/get`. If the balance that is pulled for `ins_128026` (Capital One) is older than the given timestamp, an `INVALID_REQUEST` error with the code of `LAST_UPDATED_DATETIME_OUT_OF_RANGE` will be returned with the most recent timestamp for the requested account contained in the response. This field is only used when the institution is `ins_128026` (Capital One), in which case a value must be provided or an `INVALID_REQUEST` error with the code of `INVALID_FIELD` will be returned. For all other institutions, this field is ignored.
25 26 27 |
# File 'lib/plaid/models/processor_balance_get_request_options.rb', line 25 def min_last_updated_datetime @min_last_updated_datetime end |
Class Method Details
.from_hash(hash) ⇒ Object
Creates an instance of the object from a hash.
58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 |
# File 'lib/plaid/models/processor_balance_get_request_options.rb', line 58 def self.from_hash(hash) return nil unless hash # Extract variables from the hash. min_last_updated_datetime = if hash.key?('min_last_updated_datetime') (DateTimeHelper.from_rfc3339(hash['min_last_updated_datetime']) if hash['min_last_updated_datetime']) else SKIP end # 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. ProcessorBalanceGetRequestOptions.new(min_last_updated_datetime: min_last_updated_datetime, additional_properties: additional_properties) end |
.names ⇒ Object
A mapping from model property names to API property names.
28 29 30 31 32 |
# File 'lib/plaid/models/processor_balance_get_request_options.rb', line 28 def self.names @_hash = {} if @_hash.nil? @_hash['min_last_updated_datetime'] = 'min_last_updated_datetime' @_hash end |
.nullables ⇒ Object
An array for nullable fields
42 43 44 |
# File 'lib/plaid/models/processor_balance_get_request_options.rb', line 42 def self.nullables [] end |
.optionals ⇒ Object
An array for optional fields
35 36 37 38 39 |
# File 'lib/plaid/models/processor_balance_get_request_options.rb', line 35 def self.optionals %w[ min_last_updated_datetime ] end |
Instance Method Details
#inspect ⇒ Object
Provides a debugging-friendly string with detailed object information.
92 93 94 95 96 |
# File 'lib/plaid/models/processor_balance_get_request_options.rb', line 92 def inspect class_name = self.class.name.split('::').last "<#{class_name} min_last_updated_datetime: #{@min_last_updated_datetime.inspect},"\ " additional_properties: #{@additional_properties}>" end |
#to_custom_min_last_updated_datetime ⇒ Object
80 81 82 |
# File 'lib/plaid/models/processor_balance_get_request_options.rb', line 80 def to_custom_min_last_updated_datetime DateTimeHelper.to_rfc3339(min_last_updated_datetime) end |
#to_s ⇒ Object
Provides a human-readable string representation of the object.
85 86 87 88 89 |
# File 'lib/plaid/models/processor_balance_get_request_options.rb', line 85 def to_s class_name = self.class.name.split('::').last "<#{class_name} min_last_updated_datetime: #{@min_last_updated_datetime},"\ " additional_properties: #{@additional_properties}>" end |