#kopito_code

1 messages ยท Page 1 of 1 (latest)

azure cradleBOT
#

๐Ÿ‘‹ Welcome to your new thread!

โฒ๏ธ We'll be here soon! Typically we respond in a few minutes, but sometimes we might take a bit longer if the server is busy or if you have a particularly tricky question.

โฑ๏ธ We close idle threads, which makes them read-only. Once a thread is closed it won't be reopened, but you can always start a new thread if you have another question.

๐Ÿ”— This thread will always be available, even after it's closed. You can find it again using Discord's search, or you can save this link: https://discord.com/channels/841573134531821608/1233379005537976451

๐Ÿ“ Have more to share? Add more details, code, screenshots, videos, etc. below.

unreal badgeBOT
tawny estuary
#

๐Ÿ‘‹ happy to help

#

you need to change your integration

#

instead of using the next_action URL

#

you need to create a new page on your app, and basically send them to that page with a unique ID

terse storm
#

so they will need to enter their payment details again, correct?

tawny estuary
#

no they don't

#

but I just found another way to do it

#

but before sharing that other approach let's finish this one

terse storm
#

Okay, so what this new page will do, in my server i have just the payment intent that was created, with what unique ID should i sent them to the page

tawny estuary
#

basically they get to that page, from that link you get the unique ID (which can technically be the pi_xxx but you can decide to hide behind another ID) and you fetch from your backend the client_secret of the PI in question and confirm using only the clientSecret

terse storm
#

Okay, that makes sense, and so then i call the confirmPayment with the client_secret on my backend, but what happens when it requires the 3D secure

tawny estuary
#

confirmPayment with the client_secret on my backend,
on the front end

#

not on the backend

#

you're already sending them to that page because the PM that they provided needed 3DS

#

so by using confirmPayment(clientSecret) and since the PI is in status requires_action Stripe.js will handle the 3DS flow for you

#

this will only work for 3DS

terse storm
tawny estuary
#

while what I'm suggesting works with any kind of PM type

terse storm
#

Okay i will go with the first suggestion, it looks a lot better than this iframe

#

Thank you very much for your time, hopefully it works from the first time and I won't have to bother you again ๐Ÿ˜„

tawny estuary
#

no I didn't mean to use the iframe, but instead send the user the URL we're using to load the iframe

#

that was basically what you were doing

#

but we changed the URL's place technically

#

but in all cases that's not recommended

terse storm
#

I hope the first option works, it makes much more sense, will keep in touch ๐Ÿ™‚ Thanks again