#jarcher
1 messages · Page 1 of 1 (latest)
hello! you can expand the charge and it's balance_transaction from the PaymentIntent object - the balance transaction will contain the fee
so to get the net fees for a payment intent, we'd have to grab all the charges for that payment intent, expand to include balance transaction, then calculate the net
you should only have one successful charge for the PaymentIntent, unless you're doing multi-capture?
sure one positive charge, but to account for refunds there may be multiple charges?
in most cases, Stripe doesn't charge fees for refunds : https://stripe.com/pricing
have you taken a look at the pricing for your country and payment methods that you're using to see if fees are being charged for refunds?
The payment processing fees from the original charge are not returned
yeah, so all you would need to do is to retrieve the original charge? I'm a bit confused as to why refunds come into play here
I'd like to be able to deterministically tell the "net revenue" for each payment intent. It should be as simple as amount_captured - amount_refunded - stripe_fees.
you can expand the refunds in the charge object too : https://stripe.com/docs/api/charges/object#charge_object-refunds
gotcha. Thank you for now! have a great day