#Gautam
1 messages · Page 1 of 1 (latest)
Hello 👋
I don't think BalanceTransaction API supports passing anything other than a BalanceTransaction ID in the retrieve API call
https://stripe.com/docs/api/balance_transactions/retrieve
Can you clarify if you're following a guide for the code you're currently using?
Also the API doesn't have any parameter called Taxation ID
Can you elaborate on what information you're trying to fetch exactly?
for USD currency org
const invoiceObj = await invoiceService.retrieveInvoice('in_1NXL86LYNIhg3g0eVGZQ5z9e');
const paymentIntentObj = await paymentIntentService.retrievePaymentIntent(invoiceObj.payment_intent);
const balanceTransaction = await balanceTransactionService.retrieveBalanceTranscation(
paymentIntentObj.charges.data[0].balance_transaction
);
this way we are getting the balance transcation
but for Canadian currency org paymentIntentObj.charges.data[0].balance_transaction ..is not avialble
Can you share an example where you're not seeing the BalanceTransaction in cad currency?
Oh in_1NXL86LYNIhg3g0eVGZQ5z9e seems to be CAD currency
yes
Are you seeing any errors?
That invoice is linked to this payment intent pi_3NXL86LYNIhg3g0e0pjyPl0j and the underlying charge is ch_3NXL86LYNIhg3g0e0y3saI73 which then has txn_3NXL86LYNIhg3g0e0QVTJT3Y as the BalanceTransaction ID
I can not see this txn_3NXL86LYNIhg3g0e0QVTJT3Y .. which object contains this .
The charge object should list it
Oh are you working with a few different API versions?
Looking at the PaymentIntent event
https://dashboard.stripe.com/test/events/evt_3NXL86LYNIhg3g0e0ES8cD8A
The charge is listed under latest_charge property and not charges
for usd paymentIntentObj object contains charges .. but cad it is not availble there .. what I should do for consistent
Oh are you working with a few different API versions? how to check this ..we are working with two different org (us and canada)
Do you have separate accounts for different orgs? If so, you can go to this page
https://dashboard.stripe.com/developers
and look at the API version you're using
Sign in to the Stripe Dashboard to manage business payments and operations in your account. Manage payments and refunds, respond to disputes and more.
for canada --using latest
and for US --
2020-08-27
what we should do .. we should upgrad US to latest as well
You can OR just write custom code to handle two different API responses, we have general guidance here on how you can handle API upgrades
https://stripe.com/docs/upgrades#how-can-i-upgrade-my-api
ok .. great .. Thanks for your support