Class: Lithic::Resources::FinancialAccounts::Balances

Inherits:
Object
  • Object
show all
Defined in:
lib/lithic/resources/financial_accounts/balances.rb

Instance Method Summary collapse

Constructor Details

#initialize(client:) ⇒ Balances

This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.

Returns a new instance of Balances.

Parameters:



41
42
43
# File 'lib/lithic/resources/financial_accounts/balances.rb', line 41

def initialize(client:)
  @client = client
end

Instance Method Details

#list(financial_account_token, balance_date: nil, last_transaction_event_token: nil, request_options: {}) ⇒ Lithic::Internal::SinglePage<Lithic::Models::FinancialAccountBalance>

Some parameter documentations has been truncated, see Models::FinancialAccounts::BalanceListParams for more details.

Get the balances for a given financial account.

Parameters:

  • financial_account_token (String)

    Globally unique identifier for financial account.

  • balance_date (Time)

    UTC date of the balance to retrieve. Defaults to latest available balance

  • last_transaction_event_token (String)

    Balance after a given financial event occured.

  • request_options (Lithic::RequestOptions, Hash{Symbol=>Object}, nil)

Returns:

See Also:



25
26
27
28
29
30
31
32
33
34
35
36
# File 'lib/lithic/resources/financial_accounts/balances.rb', line 25

def list(, params = {})
  parsed, options = Lithic::FinancialAccounts::BalanceListParams.dump_request(params)
  query = Lithic::Internal::Util.encode_query_params(parsed)
  @client.request(
    method: :get,
    path: ["v1/financial_accounts/%1$s/balances", ],
    query: query,
    page: Lithic::Internal::SinglePage,
    model: Lithic::FinancialAccountBalance,
    options: options
  )
end