Class: LunchMoney::Calls::PlaidAccounts
- Defined in:
- lib/lunchmoney/calls/plaid_accounts.rb
Overview
https://lunchmoney.dev/#plaid-accounts
Constant Summary
Constants inherited from Base
Instance Attribute Summary
Attributes inherited from Base
Instance Method Summary collapse
-
#plaid_accounts ⇒ Array<LunchMoney::Objects::PlaidAccount>, LunchMoney::Errors
-
#plaid_accounts_fetch(start_date: nil, end_date: nil, plaid_account_id: nil) ⇒ Boolean, LunchMoney::Errors
Methods inherited from Base
Constructor Details
This class inherits a constructor from LunchMoney::Calls::Base
Instance Method Details
#plaid_accounts ⇒ Array<LunchMoney::Objects::PlaidAccount>, LunchMoney::Errors
11 12 13 14 15 16 17 18 19 |
# File 'lib/lunchmoney/calls/plaid_accounts.rb', line 11 def plaid_accounts response = get("plaid_accounts") handle_api_response(response) do |body| body[:plaid_accounts].map do |plaid_account| LunchMoney::Objects::PlaidAccount.new(**plaid_account) end end end |
#plaid_accounts_fetch(start_date: nil, end_date: nil, plaid_account_id: nil) ⇒ Boolean, LunchMoney::Errors
28 29 30 31 32 33 34 35 |
# File 'lib/lunchmoney/calls/plaid_accounts.rb', line 28 def plaid_accounts_fetch(start_date: nil, end_date: nil, plaid_account_id: nil) params = clean_params({ start_date:, end_date:, plaid_account_id: }) response = post("plaid_accounts/fetch", params) handle_api_response(response) do |body| body end end |