#colton
1 messages · Page 1 of 1 (latest)
So to get the fee via the api you need to get the balance transaction for the payment intent's charge: https://stripe.com/docs/api/balance_transactions/object
Complete reference documentation for the Stripe API. Includes code snippets and examples for our Python, Java, PHP, Node.js, Go, Ruby, and .NET libraries.
Payment intents have a latest charge: https://stripe.com/docs/api/payment_intents/object#payment_intent_object-latest_charge
Complete reference documentation for the Stripe API. Includes code snippets and examples for our Python, Java, PHP, Node.js, Go, Ruby, and .NET libraries.
And charges have a balance transaction: https://stripe.com/docs/api/charges/object#charge_object-balance_transaction
Complete reference documentation for the Stripe API. Includes code snippets and examples for our Python, Java, PHP, Node.js, Go, Ruby, and .NET libraries.
Thanks for the quick response! Is it possible to expand this balance transaction on the charge request, so that we aren't making a separate request for each charge we're syncing to Netsuite?
The goal is to fetch charges with fees embedded in the response for each charge, to minimize the number of requests we have to make
Yeah balance transaction is expandable
You can see the expandable badge in the api spec above
Recommend reading: https://stripe.com/docs/expand
If you need to learn about expansion