Inttegro.BalanceTransactions (inttegro v0.2.0)

Copy Markdown View Source

Reads the immutable ledger entries behind an application's balance.

Balance transactions explain why funds moved: for example, a captured payment adds funds and a refund removes them. Use this API for reconciliation and audit trails rather than deriving a balance from orders or payments. Page through every result when calculating totals.

Summary

Functions

Retrieves one balance transaction by its unique identifier.

Retrieve a paginated list of balance transactions for the authenticated application. Transactions are sorted by created_at in descending order, so page 1 always contains the most recent activity.

Functions

lookup(client, request, options \\ [])

Retrieves one balance transaction by its unique identifier.

Parameters

Returns

Returns {:ok, Inttegro.BalanceTransactions.BalanceTransaction.t()} when Inttegro accepts and decodes the operation. Returns {:error, exception} for API, transport, or decoding failures. A successful API response can still describe an asynchronous resource that has not reached its terminal state.

Example

request = Inttegro.BalanceTransactions.LookupRequest.new!(request_attributes)

case Inttegro.BalanceTransactions.lookup(client, request) do
  {:ok, result} -> result
  {:error, error} -> {:error, error}
end

page(client, request, options \\ [])

Retrieve a paginated list of balance transactions for the authenticated application. Transactions are sorted by created_at in descending order, so page 1 always contains the most recent activity.

Parameters

Returns

Returns {:ok, Inttegro.BalanceTransactions.Page.t()} when Inttegro accepts and decodes the operation. Returns {:error, exception} for API, transport, or decoding failures. A successful API response can still describe an asynchronous resource that has not reached its terminal state.

Example

request = Inttegro.BalanceTransactions.PageRequest.new!(request_attributes)

case Inttegro.BalanceTransactions.page(client, request) do
  {:ok, result} -> result
  {:error, error} -> {:error, error}
end