#tonyp

1 messages · Page 1 of 1 (latest)

lucid flintBOT
tame sleet
#

Hi. Let me help you with this.

#

Could you please share the Subscription ID?

fleet sundial
#

sub_1NxRMyHMOWEObXZmU04fzIcB

#

it's part of a test clock

tame sleet
fleet sundial
#

I saw that but I cannot fit my use case with those settings

tame sleet
#

I am not sure I follow your use case exactly, do you mind elaborating more on what you're trying to achieve?

fleet sundial
#

I just want all sub invoices payments to be attempted no matter what was the previous invoice status, and I want the sub status to stay unpaid until all due invoices are paid

tame sleet
#

And what happens actually?

fleet sundial
#

Right now, next invoices after an unpaid one are kept in draft state

#

If I setup a webhook to catch the invoice.created event, I can manually set the collection_method to charge_automatically when the created invoice is after an unpaid one, so the payment will be attempted on due date

#

but now, when a customer through the customer portal pays its last unpaid invoice, the sub status goes back to active, even if there still are unpaid invoices

tame sleet
#

I understand. This is quite a uncommon flow, you might need to implement it manually:

  1. When the customer wants to re-activate the Subscription you create a standalone Invoice with the sum from all unpaid Invoices' amounts.
  2. When they pay it successfully, you can void the unpaid Invoices and the Subscription should go back to active: https://stripe.com/docs/api/invoices/void
fleet sundial
#

So there is no way for our customers to be autonomous through the customer portal and resolve their due invoices ? Because we don't want to suspend subscriptions while there are unpaid invoices

lucid flintBOT
tame sleet
#

No such a flow is not supported through Customer Portal. You will have to build such business logic yourself.

fleet sundial
#

But even with a custom business logic, I'm a bit stuck with how stripe manages the sub status anyway, as it will update the status to active with the first resolved invoice

hollow idol
#

👋 taking over and catching up

fleet sundial
#

The most concise about what I'm trying to attempt is probably this message :
I just want all sub invoices payments to be attempted no matter what was the previous invoice status, and I want the sub status to stay unpaid until all due invoices are paid

tame sleet
hollow idol
#

This is all called out in our docs here
https://stripe.com/docs/billing/subscriptions/overview#unpaid-subscriptions

All subscription invoices can't be attempted at the same time as thats not how our APIs work. Ideally merchants would

1/ Collect a new PaymentMethod
2/ Either turn automatic collection on by setting auto_advance to true or finalize the invoice by calling the API
3/ The status only changes if the most recent invoice gets paid

fleet sundial
hollow idol
#

Yeah like I mentioned above, the most recent invoice got paid which changed the status to active

fleet sundial
#

Yes so there is no way I can fit my use case with Billing right now ?

hollow idol
#

You can but you'd need to handle the order of the invoice payment manually.

Like you'd likely want to make sure that the past due invoices get paid first before the latest one does and so on..

fleet sundial
#

Okay, I was trying to get it done with the customer portal to make it do a bit of the heavy lifting but seems not possible

hollow idol
#

With customer portal, you as a merchant can't really force the customer to pay all the due invoices. They could just pay one and exit out of the flow.

One thing you could control is the provision of your services. Like you can pause your services if the customer's subscription has any unpaid/past due invoices.

Keep sending them to customer portal until they pay

fleet sundial
#

Ok I see thanks @hollow idol !