Class: ThePlaidApi::TransactionsRecurringGetRequest
- Inherits:
-
BaseModel
- Object
- CoreLibrary::BaseModel
- BaseModel
- ThePlaidApi::TransactionsRecurringGetRequest
- Defined in:
- lib/the_plaid_api/models/transactions_recurring_get_request.rb
Overview
TransactionsRecurringGetRequest defines the request schema for ‘/transactions/recurring/get`
Instance Attribute Summary collapse
-
#access_token ⇒ String
The access token associated with the Item data is being requested for.
-
#account_ids ⇒ Array[String]
An optional list of ‘account_ids` to retrieve for the Item.
-
#client_id ⇒ String
Your Plaid API ‘client_id`.
-
#options ⇒ TransactionsRecurringGetRequestOptions
An optional object to be used with the request.
-
#secret ⇒ String
Your Plaid API ‘secret`.
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(access_token:, client_id: SKIP, secret: SKIP, options: SKIP, account_ids: SKIP, additional_properties: nil) ⇒ TransactionsRecurringGetRequest
constructor
A new instance of TransactionsRecurringGetRequest.
-
#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(access_token:, client_id: SKIP, secret: SKIP, options: SKIP, account_ids: SKIP, additional_properties: nil) ⇒ TransactionsRecurringGetRequest
Returns a new instance of TransactionsRecurringGetRequest.
66 67 68 69 70 71 72 73 74 75 76 77 |
# File 'lib/the_plaid_api/models/transactions_recurring_get_request.rb', line 66 def initialize(access_token:, client_id: SKIP, secret: SKIP, options: SKIP, account_ids: SKIP, additional_properties: nil) # Add additional model properties to the instance additional_properties = {} if additional_properties.nil? @client_id = client_id unless client_id == SKIP @access_token = access_token @secret = secret unless secret == SKIP @options = unless == SKIP @account_ids = account_ids unless account_ids == SKIP @additional_properties = additional_properties end |
Instance Attribute Details
#access_token ⇒ String
The access token associated with the Item data is being requested for.
21 22 23 |
# File 'lib/the_plaid_api/models/transactions_recurring_get_request.rb', line 21 def access_token @access_token end |
#account_ids ⇒ Array[String]
An optional list of ‘account_ids` to retrieve for the Item. Retrieves all active accounts on item if no `account_id`s are provided. Note: An error will be returned if a provided `account_id` is not associated with the Item.
38 39 40 |
# File 'lib/the_plaid_api/models/transactions_recurring_get_request.rb', line 38 def account_ids @account_ids end |
#client_id ⇒ String
Your Plaid API ‘client_id`. The `client_id` is required and may be provided either in the `PLAID-CLIENT-ID` header or as part of a request body.
17 18 19 |
# File 'lib/the_plaid_api/models/transactions_recurring_get_request.rb', line 17 def client_id @client_id end |
#options ⇒ TransactionsRecurringGetRequestOptions
An optional object to be used with the request. If specified, ‘options` must not be `null`.
31 32 33 |
# File 'lib/the_plaid_api/models/transactions_recurring_get_request.rb', line 31 def @options end |
#secret ⇒ String
Your Plaid API ‘secret`. The `secret` is required and may be provided either in the `PLAID-SECRET` header or as part of a request body.
26 27 28 |
# File 'lib/the_plaid_api/models/transactions_recurring_get_request.rb', line 26 def secret @secret end |
Class Method Details
.from_hash(hash) ⇒ Object
Creates an instance of the object from a hash.
80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 |
# File 'lib/the_plaid_api/models/transactions_recurring_get_request.rb', line 80 def self.from_hash(hash) return nil unless hash # Extract variables from the hash. access_token = hash.key?('access_token') ? hash['access_token'] : nil client_id = hash.key?('client_id') ? hash['client_id'] : SKIP secret = hash.key?('secret') ? hash['secret'] : SKIP = TransactionsRecurringGetRequestOptions.from_hash(hash['options']) if hash['options'] account_ids = hash.key?('account_ids') ? hash['account_ids'] : 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. TransactionsRecurringGetRequest.new(access_token: access_token, client_id: client_id, secret: secret, options: , account_ids: account_ids, additional_properties: additional_properties) end |
.names ⇒ Object
A mapping from model property names to API property names.
41 42 43 44 45 46 47 48 49 |
# File 'lib/the_plaid_api/models/transactions_recurring_get_request.rb', line 41 def self.names @_hash = {} if @_hash.nil? @_hash['client_id'] = 'client_id' @_hash['access_token'] = 'access_token' @_hash['secret'] = 'secret' @_hash['options'] = 'options' @_hash['account_ids'] = 'account_ids' @_hash end |
.nullables ⇒ Object
An array for nullable fields
62 63 64 |
# File 'lib/the_plaid_api/models/transactions_recurring_get_request.rb', line 62 def self.nullables [] end |
.optionals ⇒ Object
An array for optional fields
52 53 54 55 56 57 58 59 |
# File 'lib/the_plaid_api/models/transactions_recurring_get_request.rb', line 52 def self.optionals %w[ client_id secret options account_ids ] end |
Instance Method Details
#inspect ⇒ Object
Provides a debugging-friendly string with detailed object information.
116 117 118 119 120 121 |
# File 'lib/the_plaid_api/models/transactions_recurring_get_request.rb', line 116 def inspect class_name = self.class.name.split('::').last "<#{class_name} client_id: #{@client_id.inspect}, access_token: #{@access_token.inspect},"\ " secret: #{@secret.inspect}, options: #{@options.inspect}, account_ids:"\ " #{@account_ids.inspect}, additional_properties: #{@additional_properties}>" end |
#to_s ⇒ Object
Provides a human-readable string representation of the object.
108 109 110 111 112 113 |
# File 'lib/the_plaid_api/models/transactions_recurring_get_request.rb', line 108 def to_s class_name = self.class.name.split('::').last "<#{class_name} client_id: #{@client_id}, access_token: #{@access_token}, secret:"\ " #{@secret}, options: #{@options}, account_ids: #{@account_ids}, additional_properties:"\ " #{@additional_properties}>" end |