#dishant0144_32519
1 messages ยท Page 1 of 1 (latest)
I am loading stripe's payment element without creating payment intent in stripe dashboard
- If standard payment intent integration, client secret will be set at Elements initiation and client secret is not required at
confirmPayment(): https://stripe.com/docs/payments/accept-a-payment?platform=web&ui=elements - If deferred payment intent integration, i.e. doesn't set client secret at Elements initiation, then client secret is needed at
confirmPayment(): https://stripe.com/docs/payments/accept-a-payment-deferred?platform=web&type=payment
In any case, Payment Intent client secret is required for any payment. It's just a matter where it should be set
No problem! Happy to help ๐
Without clientSecret can payment method validates the data
for ex. if I enter expired card number and then done payment it'll show expired card but before that one payment intent is created in stripe dashboard
so can we restrict that?
https://stripe.com/docs/payments/accept-a-payment-deferred?platform=web&type=payment&client=html
in this when stripe.confirmPayment is called before that payment intent is created and clientSecret is shared while confirming the payment, What if payment is failed and I again submit the request in that case new payment intent is created in stripe
Am I right?
???
Thanks for waiting! Looking into it now
At Payment Element, it will validate the expiry of the card at the point of entering the card details. When the payment method is used in a payment some time later, i.e. after creating a payment intent, the expiry will be validated again by the card issuer
At the confirmPayment() is called, a Payment Intent should have been created
okay
got it
So before confirm payment there should be clientSecret to be present
Is that correct?
Yes!