#Mathieu Ducrot-credit-customer

1 messages · Page 1 of 1 (latest)

hazy sluice
rancid hill
#

Can you explain more about what you're trying to do here @sage grail ? Perhaps with an example?

sage grail
#

In our custom integration it is possible that a customer have negative invoice when updating his subscription.
When it happen i saw that on the dashboard the customer gain credit balance.
Then from what i understand this credit balance his then use on the upcoming invoice to reduce his amount with the credit balance.
What we want from our side is not have to deal with this "credit balance" and instead have stripe refund the customer for that negative amount so that on next upcoming invoice the customer paid full price (so we don't have to do credit balance calculation on our end when we recreate invoice in our backend)

rancid hill
#

Gotcha, ok thanks

#

So, this can't be done automatically, no. The behaviour is to credit the customer.

If you want to refund this instead of applying the balance to a future invoice, you'll need to issue the refund from charges on a previous invoice and make sure to manually adjust the customer balance so that the next invoice is not also credited:
https://stripe.com/docs/billing/customer/balance#modifying

sage grail
#

ok i guess i must use webhook for that ?

rancid hill
#

The events would be related to the invoice, and you could handle there if you like yes

#

eg, after an invoice.paid event you could check if it had a negative/credit total then do some processing to issue a refund

sage grail
#

ok, do you have any recall that some of your client did use this technique ?

rancid hill
#

Sure, I've seen people ask about this in the past. Usually the preference is to keep the default behaviour and credit future payment, though, and only refund in some specific cases via support requests etc

sage grail
#

ok thanks for the feedback we'll see what we do on our side, thanks !

rancid hill
#

NP!