#ash_api

1 messages ¡ Page 1 of 1 (latest)

grizzled marlinBOT
#

👋 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/1290238990854651977

📝 Have more to share? Add more details, code, screenshots, videos, etc. below.

Below are links to other discussions we've had with you in the past week in case you want to review that information. If your question is related to one of these previous discussions, please provide a comprehensive summary of the current state and what you need help with now. We help many users simultaneously, so a summary allows us to resolve your issue as soon as possible.

radiant pilot
#

Can I Implement a Card Element and Express Checkout Element in the same UI with the same stripe provider ?
Yes you should be able to do that I think yes.

#

I invite you to make a quick test for that.

upbeat matrix
#

Yes you're right, I can render both, but the Express Checkout Element needs a client secret

#

which API should I be calling to retrieve a client secret and intialize the Express checkout elements

#
Unable to select session. Make sure Elements is initialized with clientSecret
      or use the nullableSessionSelector() instead
radiant pilot
#

You need to create a PaymentIntent and use its client_secret then

upbeat matrix
#

and can I attach a paymentIntent into a customer later on ?

radiant pilot
#

If you have a Customer, then attach it from the begining

#

when you create the PaymentINtent

upbeat matrix
#

Okay okay

#

What's the difference between using a PaymentIntent and SetupIntent for this use case ?

#

Because for my use case, where I am creating a payment method on the user, I use setup intent and attach the payment method there

radiant pilot
#

What's the difference between using a PaymentIntent and SetupIntent for this use case ?
PaymentIntent is for charging the customer now. While the SetupIntent is for saving/collecting the payment method for future usage. And you can do both (accept a payment and save the PaymentMethod for a future usage) at the same time using PaymentIntent

upbeat matrix
#

I see I see

#

okay makes sense

#

And when I use Express checkout am I creating a paymetn method that I can attach to a setupIntent ?

grizzled marlinBOT
radiant pilot
#

SetupIntent is for collecting a PaymentMethod.

upbeat matrix
#

I see

#

OK

#

thank you