#patchonknee_best-practices
1 messages · Page 1 of 1 (latest)
👋 Welcome to your new thread!
⏲️ We'll be here soon! Typically we respond in a few minutes, but sometimes we might take a bit longer if the server is busy or if you have a particularly tricky question.
⏱️ We close idle threads, which makes them read-only. Once a thread is closed it won't be reopened, but you can always start a new thread if you have another question.
🔗 This thread will always be available, even after it's closed. You can find it again using Discord's search, or you can save this link: https://discord.com/channels/841573134531821608/1389446878957015162
📝 Have more to share? Add more details, code, screenshots, videos, etc. below.
Hi! We need to step away for a bit. We will be back soon.
⛔️ Stripe developers have stepped away for a short while
Please leave your questions here, and we’ll respond as soon as we're back! If you need help urgently, you can contact Stripe support for help.
hi @real oyster , could you share more about "refund a bulk amount across payments". Do you mean performing refunds on multiple payments?
hey @dense flint. thanks for responding. Lets say there is an "order" with 4 separate $25 payments on it, all performed on a different card, and were attempting to refund $80, how would you go about achieving that? currently its my understading that I would have to iterate over each payment and refund the required amount
Your understanding is correct. If there are 4 separate payments, it would mean there's 4 seperate PaymentIntents. The refund will need to be issued on the PaymentIntent, which means full refund on three of the PaymentIntents ($25 x 3), and then a $5 partial refund on the fourth.
damn thats what I thought, is it possible to check if a refund is possible(not just having enough money on the charge) before refunding
the amount used to issue the refund is taken from your Stripe account's available balance. You can check your Stripe account's available balance via the API [0]
these pages might be helpful:
- https://docs.stripe.com/refunds?dashboard-or-api=api#issuing
- https://docs.stripe.com/payments/balances
[0]https://docs.stripe.com/api/balance/balance_objectl#balance_object-available
in the case of a card not accepting a refund (expired/on hold etc), is there no way of knowing that before attempting the refund?
there's no way of knowing for sure but we do have a guide on handling failed refunds: https://docs.stripe.com/refunds?dashboard-or-api=api#failed-refunds