#Th3FalleN
1 messages ยท Page 1 of 1 (latest)
"the attempted key bet set to true" what does that mean?
Can you clarify which API endpoint exactly you are reaching?
the attempted key in the subscription preview
Complete reference documentation for the Stripe API. Includes code snippets and examples for our Python, Java, PHP, Node.js, Go, Ruby, and .NET libraries.
providing a subscription id customer and subscription line items
attempted is a property of an Invoice, not a subscription. And the preview does not actually create an invoice
So no, it won't
so, how would one determine is the current update to the subscription im previewing would include a previous failed balance?
What do you mean "failed balance"?
Do you mean a full billing cycle where payment was not collected?
And then you want to preview the next billing cycle's invoice?
so a customer has a subscription, and their due day was yesterday but the rebill failed for any reason
Stripe won't roll over unpaid balances to a new invoice
when they come into resolve that they can technically make alterations to their seats which would result in an update to the subscription
who's total would be the update + the prior balance
If the prior invoice was generated, Stripe expects you to attempt collection
okay, we'll have to update our flow to not let them modify their subscription when renewing
or cancel the subscription and create a new one would be the correct flow in that case?
I would not cancel, since you would lose that history. However, you entirely control what the customer can do in terms of updating their subscriptions so you could include logic that requires payment of past invoices before modifications.
which would involve using the invoice search endpoint to get any past due ones i assume?
That depends on the flow. I would not recommend Search for anything super critical as there are race condition scenarios. Search isn't realtime and we call that out. You can use the List API which is indexed faster than Search and it allows filtering by Customer and Status: https://stripe.com/docs/api/invoices/list
Happy to help ๐
also do you guys have any integration reps that advise on the best way to setup products in stripe etc for particular flows?
I don't think so.
๐ figured i'd ask thanks again as always!