#tom-hacohen_subscriptions-invoice-finalize

1 messages ยท Page 1 of 1 (latest)

craggy magnetBOT
#

๐Ÿ‘‹ 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/1395470305119572141

๐Ÿ“ Have more to share? Add more details, code, screenshots, videos, etc. below.

red lark
craggy magnetBOT
wild oracle
#

Thanks @red lark, how do I fix it though? It's not clear to me even from the link you shared (which I've previously read) what is the way to fix it.

red lark
wild oracle
#

I guess I can set the "send reminders if recurring invoice hasn't been paid"

#

but there's no option to make it continue to finalize and send invoices (I spent a lot of time on this page)

grizzled knot
#

Hi ๐Ÿ‘‹

I'm stepping in as my colleague needs to go. Can you describe the scenario where this would apply?

but there's no option to make it continue to finalize and send invoices (I spent a lot of time on this page)

craggy magnetBOT
wild oracle
#

Sure

#

Let's say we have a customer, ACME. They have a subscription with us. They haven't paid on June 16th (last month) so they get a failed invoice last month. It's been a month since then, and they've continued to use the service, but the July 16th invoice is still a draft today (rather than finalized) so they don't get notified about the failed payment for the additional invoice as it's not finalized and doesn't even try. We want it to continue to the next invoice and essentially never have drafts (for longer than the default 1hr), always finalize invoices.
I guess that now that I'm saying it, what I can do is just listen to "draft invoice created" webhooks and call the "charge" API. Though is there an automatic way of doing it?

#

well, only for automatic ones that have a subscription attached.

grizzled knot
#

No, there isn't an automatic way you can configure that in the Dashboard. I"m not sure what you mean by the Charge API but you can use the Invoices APIs to finalize https://docs.stripe.com/api/invoices/finalize an Invoice.

One question I have, is if the user still has an outstanding Invoice for June, but pays their July Invoice, what should the status of the Subscription be as far as your business is concerned?

wild oracle
#

unpaid

#

but it's not the end of the world for us, as this we can manage (we'll continue chasing old invoices).

grizzled knot
#

Ah the /Pay API

#

You can either collect a new Payment Method from the Customer or retry the default payment method using that API

#

The reason I ask about the status is that, IIRC, have the latest Invoice become paid will reset the Subscription to active

wild oracle
#

Yeah

#

it'll auto finalize, right?

#

@grizzled knot, not ideal, but not the end of the world for us as we'll chase old invoices. ๐Ÿ™‚

grizzled knot
#

No the request to /pay will fail if the Invoice has not finalized. You would need to finalize the Invoice first

wild oracle
#

gotcha, so I need to finalize + pay, or if I finalize with "auto advance" it'll just pay on its own?

grizzled knot
#

If the payment_behavior is charge_automatically, then yes it will attempt to charge the default PM

wild oracle
#

And one last thing: any downside to listening to the invoice.draft.created (or whatever it's called) webhook and calling finailze immediately?

#

I guess I'll have to check: (1) it was created as part of a subscirption, and not manually, and (2) that charge_automatically is set on the invoice. Though anything else?

grizzled knot
#

We have the 1 hour draft period to allow you to take any follow up actions you want to for a specific Invoice (i.e. add custom footer, add a one-off charge, etc.). If you know your Invoice is good to go, you can finalize immediately.

wild oracle
#

thanks!

grizzled knot
#

Happy to shed what ๐Ÿ’ก I can ๐Ÿ™‚

wild oracle
#

๐Ÿ™‚

craggy magnetBOT