#JaviBarredo
1 messages · Page 1 of 1 (latest)
Hi there!
hey
Any metadata you add with stripe.subscription.create will be added to the Subscription object. Once you receive the payment_intent.payment_failed event, you can make a call to retrieve the PaymentIntent and expand invoice.subscription
what call ?
I am trying stripe.events.retrieve
but it's not giving me the metadata
After you receive the payment_intent.payment_failed event, you'd have to make a call to retrieve the PaymentIntent. The payment_intent.payment_failed event should include the ID of the PaymentIntent that failed. The metadata you added only exists on the Subscription object, which is why you'd need to expand invoice.subscription when retrieving the PaymentIntent
thanks, do you know the JS SKD call for any chance ?
bump
yeah sorry
I recommend starting here for help on expanding responses, specifically the Node samples: https://stripe.com/docs/expand
okay thanks, I am going to take a look
🫡
if you guys have any recomendation lmk
thanks for the help !
ok so
looking at that doc seems like i need a checkout session ID
that I can't find at the payment_intent.payment_failed webhook
Hi, stepping in and catching up here.
Can you add a bit more clarify on the follow up questions please?
so basically your mate sent me this doc.
But it requires from checkout session id cs_**
and in my case I can only attend to the data given by the payment_intent.payment_failed webhook that seems like it's not returning such id
What does 'I can only attend to the data given' mean?