Class: Lithic::Resources::AccountActivity

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

Instance Method Summary collapse

Constructor Details

#initialize(client:) ⇒ AccountActivity

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

Parameters:



75
76
77
# File 'lib/lithic/resources/account_activity.rb', line 75

def initialize(client:)
  @client = client
end

Instance Method Details

#list(account_token: nil, begin_: nil, business_account_token: nil, category: nil, end_: nil, ending_before: nil, financial_account_token: nil, page_size: nil, result: nil, starting_after: nil, status: nil, request_options: {}) ⇒ Lithic::Internal::CursorPage<Lithic::Models::AccountActivityListResponse::Internal, Lithic::Models::BookTransferResponse, Lithic::Models::AccountActivityListResponse::Card, Lithic::Models::Payment, Lithic::Models::ExternalPayment, Lithic::Models::ManagementOperationTransaction>

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

Retrieve a list of transactions across all public accounts.

Parameters:

  • account_token (String)

    Filter by account token

  • begin_ (Time)

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

  • business_account_token (String)

    Filter by business account token

  • category (Symbol, Lithic::Models::AccountActivityListParams::Category)

    Filter by transaction category

  • end_ (Time)

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

  • ending_before (String)

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

  • financial_account_token (String)

    Filter by financial account token

  • page_size (Integer)

    Page size (for pagination).

  • result (Symbol, Lithic::Models::AccountActivityListParams::Result)

    Filter by transaction result

  • starting_after (String)

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

  • status (Symbol, Lithic::Models::AccountActivityListParams::Status)

    Filter by transaction status

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

Returns:

See Also:



40
41
42
43
44
45
46
47
48
49
50
# File 'lib/lithic/resources/account_activity.rb', line 40

def list(params = {})
  parsed, options = Lithic::AccountActivityListParams.dump_request(params)
  @client.request(
    method: :get,
    path: "v1/account_activity",
    query: parsed.transform_keys(begin_: "begin", end_: "end"),
    page: Lithic::Internal::CursorPage,
    model: Lithic::Models::AccountActivityListResponse,
    options: options
  )
end

#retrieve_transaction(transaction_token, request_options: {}) ⇒ Lithic::Models::AccountActivityRetrieveTransactionResponse::Internal, ...

Retrieve a single transaction



63
64
65
66
67
68
69
70
# File 'lib/lithic/resources/account_activity.rb', line 63

def retrieve_transaction(transaction_token, params = {})
  @client.request(
    method: :get,
    path: ["v1/account_activity/%1$s", transaction_token],
    model: Lithic::Models::AccountActivityRetrieveTransactionResponse,
    options: params[:request_options]
  )
end