Class: Lithic::Resources::FinancialAccounts::LoanTapes

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

Instance Method Summary collapse

Constructor Details

#initialize(client:) ⇒ LoanTapes

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 LoanTapes.

Parameters:



73
74
75
# File 'lib/lithic/resources/financial_accounts/loan_tapes.rb', line 73

def initialize(client:)
  @client = client
end

Instance Method Details

#list(financial_account_token, begin_: nil, end_: nil, ending_before: nil, page_size: nil, starting_after: nil, request_options: {}) ⇒ Lithic::Internal::CursorPage<Lithic::Models::FinancialAccounts::LoanTape>

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

List the loan tapes for a given financial account.

Parameters:

  • financial_account_token (String)

    Globally unique identifier for financial account.

  • begin_ (Date)

    Date string in RFC 3339 format. Only entries created after the specified date wi

  • end_ (Date)

    Date string in RFC 3339 format. Only entries created before the specified date w

  • ending_before (String)

    A cursor representing an item’s token before which a page of results should end.

  • page_size (Integer)

    Page size (for pagination).

  • starting_after (String)

    A cursor representing an item’s token after which a page of results should begin

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

Returns:

See Also:



58
59
60
61
62
63
64
65
66
67
68
# File 'lib/lithic/resources/financial_accounts/loan_tapes.rb', line 58

def list(, params = {})
  parsed, options = Lithic::FinancialAccounts::LoanTapeListParams.dump_request(params)
  @client.request(
    method: :get,
    path: ["v1/financial_accounts/%1$s/loan_tapes", ],
    query: parsed.transform_keys(begin_: "begin", end_: "end"),
    page: Lithic::Internal::CursorPage,
    model: Lithic::FinancialAccounts::LoanTape,
    options: options
  )
end

#retrieve(loan_tape_token, financial_account_token:, request_options: {}) ⇒ Lithic::Models::FinancialAccounts::LoanTape

Get a specific loan tape for a given financial account.

Parameters:

  • loan_tape_token (String)

    Globally unique identifier for loan tape.

  • financial_account_token (String)

    Globally unique identifier for financial account.

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

Returns:

See Also:



20
21
22
23
24
25
26
27
28
29
30
31
32
# File 'lib/lithic/resources/financial_accounts/loan_tapes.rb', line 20

def retrieve(loan_tape_token, params)
  parsed, options = Lithic::FinancialAccounts::LoanTapeRetrieveParams.dump_request(params)
   =
    parsed.delete(:financial_account_token) do
      raise ArgumentError.new("missing required path argument #{_1}")
    end
  @client.request(
    method: :get,
    path: ["v1/financial_accounts/%1$s/loan_tapes/%2$s", , loan_tape_token],
    model: Lithic::FinancialAccounts::LoanTape,
    options: options
  )
end