#scedroni-webhook-invoice

1 messages ยท Page 1 of 1 (latest)

twilit umbra
#

HEllo!

velvet tinsel
#

Hi ๐Ÿ™‚

twilit umbra
#

Can you give me a bit more context? Are you using Billing? Invoicing? Checkout? Something else?

velvet tinsel
#

Sure sorry. Checkout

#

Do you need any other information?

twilit umbra
#

Okay so you use Checkout, but then what? Is this for recurring payments or one-time payments? Are you trying to provision their account for the first payment in Checkout or future payments?

velvet tinsel
#

Yes so it is simple website with premium content and a paywall. Users subscribe to a monthly membership (with monthly recurring payments).
Therefore when they go through the Stripe Checkout, I need to update their account on the backend and turn a Boolean to true.
This Boolean will need to be updated every month, whether or not the user unsubscribes

twilit umbra
#

Okay so for the first payment you should use checkout.session.completed specifically. This would tell you when the Subscription and its first Invoice is paid basically https://stripe.com/docs/payments/checkout/fulfill-orders

For future cycles you should listen to invoice.paid specifically that indicates when an Invoice is paid properly. You can listen to other Events such as customer.subscription.updated to know when a Subscription is updated (cycle change for example, status change, etc) and also invoice.payment_failed (to know when a payment failed and when it will be retried next) and customer.subscription.deleted (when a Subscription is canceled, for example after too many failed payments)

velvet tinsel
#

Thank you very much, this was very helpful! ๐Ÿ™๐Ÿป๐Ÿ™๐Ÿป