#.gabelbart

1 messages · Page 1 of 1 (latest)

full talonBOT
rugged agate
#

do you have the Invoice ID in_xxx where this happened?

opal trench
#

in_1NZrgKHurCsNkwAvabIzcOW5

#

in_1NZsNiHurCsNkwAvOxL5Hk0C this one too

rugged agate
#

ok. And before I dig too much, your two questions are

  1. you expected to recieve an invoice.created event but apparently didn't, why?
  2. why is the billing_reason:subscription:create for that Invoice?

?

opal trench
#

Yes, though im more interested in the invoice.finalized event. But for this invoice.created is needed anyway I guess.

rugged agate
#

ok.
1)
there is both an invoice.created and an invoice.finalized event, they're here :
https://dashboard.stripe.com/test/events/evt_1NZrgOHurCsNkwAvn7KobXus
https://dashboard.stripe.com/test/events/evt_1NZrgOHurCsNkwAvwB4Qk3Tu

Note that here the Invoice is the first Invoice of a subscription(being created through Checkout), and the first invoice of a subscription is created and finalized immediately. https://stripe.com/docs/billing/invoices/subscription#new-subscription-invoices

Then, later, you are issuing a CreditNote to do a refund on the Invoice. That adjusts the Invoice and thus creates an invoice.updated event https://dashboard.stripe.com/test/events/evt_1NZrjVHurCsNkwAvBv1WMyNO

#
  1. it's subscription_create because it's the first Invoice of a subscription(being created through Checkout)
opal trench
#

Ok, so I never receive an actual 'cancellation invoice' but the original invoice is updated to include the cancellation?

#

I expected to get a distinct invoice for cancellation.

rugged agate
#

to be honest I never use our CreditNotes API so I know little about it

#

was there some docs that implied a cancellation invoice should exist?

#

I appreciate you're probably not using Credit Notes directly, it's just what the Dashboard does when you click whatever buttons you clicked

opal trench
opal trench
rugged agate
#

It likely depends how you cancel it really, like there's an option to refund or not. This is just the way the Dashboard has implemented the cancellation logic.

opal trench
#

I set to refund in the dashboard but its obviously different than invoice_now

#

But there is something I really don't understand: I expected 'finalized' means the invoice will never be changed again, that's why I'm so suprised that it was updated.

rugged agate
#

yep, that is my intuition too

#

but Credit Notes are an exception and allow for the finalized invoice to be changed

#

as I said, I never really use them personally but I assume they are useful for certain use cases

opal trench
#

Probably the credit_note.created event will serve my needs too, I will have to further investigate this. Can I come back to this thread if I get stuck again? Thanks for your help anyway.

dawn sphinx
#

Hi, I will have to close the thread soon, but feel free to post in the main channel.