#uh oh
1 messages · Page 1 of 1 (latest)
Because if I use PaymentElement, the docs say I need to include the client secret in the options prop in Elements
Hello 👋
I think you'd still need to pass in the promise that loads Stripe and initialises the SDK using public key as shown here
https://stripe.com/docs/payments/card-element?client=react
Hi! Yeah, but do I need to initialize it with the client secret here? like in this doc?
On Step 5, there is the client secret in the options props for <Elements>
But then in this documentation (it uses <CardElement> which is my use case), it doesn't require you to do so https://stripe.com/docs/payments/save-and-reuse-cards-only?platform=web
Afaik you don't need to initialise it the same way, no.
Thank you!!
If I wanted to use confirmCardSetup with a connect account
what is the format?
const result = await stripe.confirmCardSetup('{{CLIENT_SECRET}}', {
payment_method: {
card: elements.getElement(CardElement),
billing_details: {
name: 'Jenny Rosen',
},
}
});```
Yep that looks right. Have you tried that code on your test page?
Yes, but I would like to confirm it with a connected account
Can you keep track of setup intents on stripe dashboard?
Yes if you go to https://dashboard.stripe.com/setup_intents/{SETUP_INTENT_ID} you can see info about the setup intent in your dashboard
Sign in to the Stripe Dashboard to manage business payments and operations in your account. Manage payments and refunds, respond to disputes and more.
What if it's for a connect account?
That is taken care of when initializing Stripe.js
If you are creating these setup intents on one of your connected accounts, you should be initializing Stirpe.js to also use that connect account's ID https://stripe.com/docs/js/initializing#init_stripe_js-options-stripeAccount