#cnguyen

1 messages · Page 1 of 1 (latest)

timber etherBOT
brittle arrow
stuck cipher
#

what is the difference with succeeded ?

Because, the flow I want is :

  • Front > Call a WS "get setup intent client secret"
  • Back > WS > Create the customer + create the SetupIntent and return the client secret
  • Front > Display the credit card form and use the client secret to associate the payment method to the customer in order to use the pm later
  • Back > Once the pm is associated through the SetupIntent, I generate a subscription

I think that in my case, I have to listen the setup_intent.succeeded ?

#

And I read
"Use stripe.confirmSetup to complete the setup using details collected by the Payment Element. Provide a return_url to this function so that Stripe can redirect the user after they complete setup. We may first redirect them to an intermediate site, like a bank authorization page, before redirecting them to the return_url. If your user saves their card details, we immediately redirect them to the return_url when setup is successful."

But I just want to enter the credit card info throughCardNumberElement, and like a PI, I want to display the 3DS if needed, then just display a OK message without to be redirected to an other page.

Is it possible ?

brittle arrow
#

Our Elements would handle 3DS for you.

stuck cipher
#

In the front, I have to use await stripe.confirmSetup

#

but I don't understand the url param ? Is it mandatory ? Because, in my case, I want to stay on the same page and display a popin OK when it's successful

brittle arrow
#

Let's back up here... you mentioned you generate a subscription after you use Setup Intent, can you speak more into this? Are you immediately creating a Subscription after the Setup Intent succeeds?

stuck cipher
#

I don't know yet

#

that's why I try to check all the possibilities

#

to allow me to choose

#

First option => directly after => I think I have to use setup_intent.succeeded

#

2nd option => X days later => I have to keep the date when it's will be X and do the stuff

brittle arrow