View Source Stripe.BalanceTransaction (stripity_stripe v3.2.0)
Balance transactions represent funds moving through your Stripe account. Stripe creates them for every type of transaction that enters or leaves your Stripe account balance.
Related guide: Balance transaction types
Summary
Functions
Returns a list of transactions that have contributed to the Stripe account balance (e.g., charges, transfers, and so forth). The transactions are returned in sorted order, with the most recent transactions appearing first.
Retrieves the balance transaction with the given ID.
Types
@type t() :: %Stripe.BalanceTransaction{ amount: integer(), available_on: integer(), created: integer(), currency: binary(), description: binary() | nil, exchange_rate: term() | nil, fee: integer(), fee_details: term(), id: binary(), net: integer(), object: binary(), reporting_category: binary(), source: (binary() | term()) | nil, status: binary(), type: binary() }
The balance_transaction type.
amountGross amount of this transaction (in cents (or local equivalent)). A positive value represents funds charged to another party, and a negative value represents funds sent to another party.available_onThe date that the transaction's net funds become available in the Stripe balance.createdTime at which the object was created. Measured in seconds since the Unix epoch.currencyThree-letter ISO currency code, in lowercase. Must be a supported currency.descriptionAn arbitrary string attached to the object. Often useful for displaying to users.exchange_rateIf applicable, this transaction uses an exchange rate. If money converts from currency A to currency B, then theamountin currency A, multipled by theexchange_rate, equals theamountin currency B. For example, if you charge a customer 10.00 EUR, the PaymentIntent'samountis1000andcurrencyiseur. If this converts to 12.34 USD in your Stripe account, the BalanceTransaction'samountis1234, itscurrencyisusd, and theexchange_rateis1.234.feeFees (in cents (or local equivalent)) paid for this transaction. Represented as a positive integer when assessed.fee_detailsDetailed breakdown of fees (in cents (or local equivalent)) paid for this transaction.idUnique identifier for the object.netNet impact to a Stripe balance (in cents (or local equivalent)). A positive value represents incrementing a Stripe balance, and a negative value decrementing a Stripe balance. You can calculate the net impact of a transaction on a balance byamount-feeobjectString representing the object's type. Objects of the same type share the same value.reporting_categoryLearn more about how reporting categories can help you understand balance transactions from an accounting perspective.sourceThis transaction relates to the Stripe object.statusThe transaction's net funds status in the Stripe balance, which are eitheravailableorpending.typeTransaction type:adjustment,advance,advance_funding,anticipation_repayment,application_fee,application_fee_refund,charge,climate_order_purchase,climate_order_refund,connect_collection_transfer,contribution,issuing_authorization_hold,issuing_authorization_release,issuing_dispute,issuing_transaction,obligation_outbound,obligation_reversal_inbound,payment,payment_failure_refund,payment_network_reserve_hold,payment_network_reserve_release,payment_refund,payment_reversal,payment_unreconciled,payout,payout_cancel,payout_failure,refund,refund_failure,reserve_transaction,reserved_funds,stripe_fee,stripe_fx_fee,tax_fee,topup,topup_reversal,transfer,transfer_cancel,transfer_failure, ortransfer_refund. Learn more about balance transaction types and what they represent. To classify transactions for accounting purposes, considerreporting_categoryinstead.
Functions
@spec list( params :: %{ optional(:created) => created() | integer(), optional(:currency) => binary(), optional(:ending_before) => binary(), optional(:expand) => [binary()], optional(:limit) => integer(), optional(:payout) => binary(), optional(:source) => binary(), optional(:starting_after) => binary(), optional(:type) => binary() }, opts :: Keyword.t() ) :: {:ok, Stripe.List.t(t())} | {:error, Stripe.ApiErrors.t()} | {:error, term()}
Returns a list of transactions that have contributed to the Stripe account balance (e.g., charges, transfers, and so forth). The transactions are returned in sorted order, with the most recent transactions appearing first.
Note that this endpoint was previously called “Balance history” and used the path /v1/balance/history.
Details
- Method:
get - Path:
/v1/balance_transactions
@spec retrieve( id :: binary(), params :: %{optional(:expand) => [binary()]}, opts :: Keyword.t() ) :: {:ok, t()} | {:error, Stripe.ApiErrors.t()} | {:error, term()}
Retrieves the balance transaction with the given ID.
Note that this endpoint previously used the path /v1/balance/history/:id.
Details
- Method:
get - Path:
/v1/balance_transactions/{id}