#andrei.sabau

1 messages · Page 1 of 1 (latest)

vital oysterBOT
sudden summit
#

I actually found a way to do this by updating the subscription with a product that is Free - this will create a proration that will be credited to the customer balance and afterwards I cancel the subscription because I don't want any invoices to be created. Is this the correct flow?

clever viper
#

how can I credit the remaining money to his "Invoice credit balance" (not bank account/payment method) so it can be used in the future?
By default, the remaining funds will be credited to customer's balance after canceling the subscription: https://stripe.com/docs/billing/customer/balance

#

Customer balance can be used for future invoices

sudden summit
clever viper
#

Can you share the subscription ID (sub_xxx) that is canceled?

sudden summit
#

I tried this with Test Clocks & everything setup the correct way. Not sure what I'm missing.

#

Give me 2 seconds to create an example.

#

So I just created sub_1O21GdBDHQTgXfBt4M4kAyHU from my SaaS test env, advanced the time with 2 months from the Dashboard and then canceled the subscription from the Dashboard.

#

The total for the yearly subscription was 385 euro, I was expecting somewhere around 320 euro to be credited to customer balance.

clever viper
#

Thanks for sharing! Checking it now

#

The subscription was

  • created at 2025-01-18 00:37:12 UTC (test clock)
  • canceled at 2025-03-18 00:37:12 (test clock)
#

The subscription was canceled exactly two months later that customer uses full susbscription that there is no proration will be created

#

Proration will only be created if customer has unused period

sudden summit
#

but it had products with a Yearly price

clever viper
#

Sorry, my bad

#

I missed the yearly price

#

Let me double check

#

This means that no proration will be created, i.e. the remaining usage won't be refunded

sudden summit
#

can I set that to true from the dashboard UI?

#

meaning this dialog

#

or only by calling the API directly?

#

Ok so I tested this through the API on a new subscription: sub_1O21WZBDHQTgXfBt2h2wBYbx

#

nevermind

#

thanks @clever viper, I figured it out

#

I was mainly testing canceling subscriptions from the dashboard UI and it seems the parameters I was looking for are not available there

#

the prorate field you suggested along with the invoice_now, generates the result I was looking for

clever viper
#

Thanks for waiting! Discord is busy now. Great to hear that it works 🙌