#maxim-k_api
1 messages ¡ Page 1 of 1 (latest)
đ 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/1326759474093887518
đ 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.
- maxim-k_api, 6 hours ago, 62 messages
Hi
Can you share with me the details about the error?
one sec
so actual payment element implementation is:
stripe = Stripe(Settings.public_key);
let elements = Setting.stripe.elements();
elements.create("card", {style: style, hidePostalCode: true});
And it works for just a card
I need to add extra payment methods (bank etc)
Can you open browser console and see if there are any error messages?
Example above works
for a 5 years
Now example that doesn;t work and error for it
elements.create("payment");
Ok, you can use paymentElement https://docs.stripe.com/payments/accept-a-payment?platform=web&ui=elements follow this guide to get started.
Error: In order to create a payment element, you must pass a clientSecret or mode when creating the Elements group.
So, it works for cards without client secret as i noted above
How should i recall "elements.create("payment");"?
Can I suggest you to walk through the guide that I share earlier?
Is it possible to create "payment" element without passing ClientSercret?
Sure, looking on it
But eventually you still need to create a paymentIntent and use the clientSecret to confirm the payment from client side
Of course
So, this setup doesn't work - this is exactly what i'm doing
ahh, no. there is no mode option
Sorry
Thank you!
How i can leave only certain payment methods ? I need just "card" and us bank account?
https://docs.stripe.com/payments/accept-a-payment-deferred?platform=web&type=payment#additional-options set paymentMethodTypes to ['card', 'us_bank_account']