#cgy
1 messages · Page 1 of 1 (latest)
Hi 👋 that's correct.
checkout.session.completed Events are triggered when a customer completes the flow presented to them by a Checkout Session.
invoice.paid Events are triggered whenever an Invoice is paid, so this can occur every billing period of a Subscription.
invoice.paid Events should contain an Invoice object in them, which has a customer field indicating which Customer the Invoice belongs to:
https://stripe.com/docs/api/invoices/object#invoice_object-customer
Complete reference documentation for the Stripe API. Includes code snippets and examples for our Python, Java, PHP, Node.js, Go, Ruby, and .NET libraries.
Ok, so it seems I should set customer in SessionParams api and save this customer ID in our database then when I receive "invoice.paid" I can know who paid this
If you already have a Customer object created for the customer, then yes, otherwise the Checkout Session will automatically create a new Customer object.