#0xNima
1 messages · Page 1 of 1 (latest)
Hi there, can you elaborate more?
I want to know which user each event belongs to? then based on event type, show a payment status like pending, done or failed to user
The checkout session doesn't have a event for open, it only has events when it's completed , expired or async payment failed/succeed (https://stripe.com/docs/api/events/types#event_types-checkout.session.completed)
Complete reference documentation for the Stripe API. Includes code snippets and examples for our Python, Java, PHP, Node.js, Go, Ruby, and .NET libraries.
well actually what I'm looking for, is a way to send user_id in each event.
You can append a client_reference_id to the URL, but as I explained earlier, there's no event to be fired when a checkout session is opened.
but client_reference_id only is sent in session complete event.
Assume I want to get user_id in payment_intent.create too.
what do you mean by user_id in payment_intent.create ?
user_id is just a custom data. Any custom data.
when I got a payment_intent.create event in webhook, I can't infer which user this event belongs to.
customer filed is sent in most of the events to webhook (at least in 4 events that I'm listening) but it is Stripe specific id.
I'm looking for such field instead fill it with my own db's data
OK, so you want to assocaite a checkout session created with payment link to a customer, am I right?
Yes
OK. I don't see a solution right now, and I'd suggest you to reach out to Stripe support and see if they have any suggestions https://support.stripe.com/contact/email
Find help and support for Stripe. Our support center provides answers on all types of situations, including account information, charges and refunds, and subscriptions information. Get your questions answered and find international support for Stripe.