#Sharvari96
1 messages ยท Page 1 of 1 (latest)
๐ happy to help
in the case of an async payment method (e.g. US bank account) the checkout session is complete whenever the payment method is created rather than when the payment is made
the only errors in this case can be related to issues with creating the PM itself
rather than the payment made using this PM
Payment scenario - insufficient funds but user is being redirected to success url.
so this is expected
If our webapp needs to handle the error displays - Which event do I need to listen to exactly using a webhook? "type": "charge.failed" - contains the message - insufficient funds - however, doesn't contain the metadata that I need to recognize it."type" : "checkout.session.async_payment_failed" - contains the metadata but not the error message!
when you receive "checkout.session.async_payment_failed" you receive a Checkout Session object instead of a charge
you would then have to retrieve that Session and expand on the Payment Intent https://stripe.com/docs/api/checkout/sessions/object#checkout_session_object-payment_intent to get to the last_payment_error https://stripe.com/docs/api/payment_intents/object#payment_intent_object-last_payment_error
Complete reference documentation for the Stripe API. Includes code snippets and examples for our Python, Java, PHP, Node.js, Go, Ruby, and .NET libraries.
Complete reference documentation for the Stripe API. Includes code snippets and examples for our Python, Java, PHP, Node.js, Go, Ruby, and .NET libraries.
let me check this and get back with followup queries? in 5mins?
hope this thread will be open
sure thing
how long can this thread be open, I need more time to respond
still open for now