#Babu Munavarbasha

1 messages · Page 1 of 1 (latest)

deep orbitBOT
final furnace
elfin geode
#

req_PZZvlBTJm4FoeA

#

I am trying to confirm an off_session payment from end user

#

using handleCardAction

final furnace
#

Is this the same PaymentIntent? because the error is different -> Your card was declined. This transaction requires authentication.

elfin geode
#

The request I gave u is the payment intent which needs to be confirmed

#

handleCardAction: The PaymentIntent supplied is not in the requires_action state.

#

This is the error I am getting on UI

#

there is no request generated for this handleCardAction

final furnace
elfin geode
#

Man, i am trying to explain i am using handleCardAction method and its giving an error on the UI and not generating any request on the stripe server

#

it is not confirm payment which i am using

#

i am using stripe.handleCardAction

final furnace
#

It should be a different request, but not this one. This request was made in backend, not frontend.

#

Or can you share with the paymentIntent ID that you pass to handleCardAction?

elfin geode
#

"pi_3MRsf1RNcO3F2LRl0kZw1KTQ"

#

ClientSecret: "pi_3MRsf1RNcO3F2LRl0kZw1KTQ_secret_JboArQpinS4F9jcKA72q5gc6j"

#

As i said, Its not generating any request on the logs when i do handlecardaction

#

errorhandler.js:23 IntegrationError: handleCardAction: The PaymentIntent supplied is not in the requires_action state.

final furnace
#

You only call handleCardAction when the PI's status is requires_action, the status of the PI is requires_payment_method

elfin geode
#

okay, what is the right way to get authenticated for an off_session payment

#

one of your customer support told me this

#

confirm payment requires element? but this is just authenticating the payment

final furnace
#

You should follow this guide.

If the payment failed due to an authentication_required decline code, use the declined PaymentIntent’s client secret and payment method with confirmCardPayment to allow the customer to authenticate the payment.

#

Basically you need to call confirmCardPayment, not handleCardAction

elfin geode
#

okay thanks works now