#Jeff Jin

1 messages · Page 1 of 1 (latest)

celest matrixBOT
slim geode
#

Hello, yes there is a way to get this via the API. You have to retrieve a couple layers of objects

#

Basically a successful PaymentIntent will have a list of charges, the first Charge in that list will be the successful one, that charge has a balance_transaction property that represent the funds from that charge going to your account, on that balance transaction there is a fee property that shows the stripe fee that was charged

#

Can you tell me a bit more about how and when you would like to look up those fees? I am happy to link to our API references that are useful here

crimson citrus
#

Hi, @slim geode thank you for your help. I want to retrieve the processing fee after i create a payment intent.

#

using stripe card.

slim geode
#

If you expand charges.data.balance_transaction, you can go from your payment intent, to the first charge in its charges list, to that charge's balance_transaction property, and to that balance transaction's fee https://stripe.com/docs/api/balance_transactions#balance_transaction_object-fee

crimson citrus
#

@slim geode I want to get the Feeamount using payment object or api.

slim geode
#

The code that I mentioned should do that. One sec I can link to each field:

crimson citrus
#

Oh, thank you