#meet_code
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/1278125604016881695
๐ 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.
Hi there
hey
Do you want to disable Link as a PaymentMethod entirely?
yeah just want "card", "exp date" and "cvv"
what's the reason behind showing 1-link ? as a default wayy
Let me rephrase
So you're working with the PaymentElement. There are two ways you can control which payment method types are displayed:
??
Wait, before I get there. Are you creating PaymentIntents before rendering the PaymentElement or are you displaying the PaymentElement first?
If you're following a specific guide, can you link it here?
displaying payment element first and then paymentIntent takes place
had a link , but do not remember now
?
Sorry for the delay, give me a few more minutes
okay
Okay, great. In that case, you can pass paymentMethodTypes: ['card'] when creating the Element: https://docs.stripe.com/js/elements_object/create_without_intent#stripe_elements_no_intent-options-paymentMethodTypes
If you only plan on accepting card payments across your entire account, you can disable PaymentMethods in your Dashboard and use dynamic payment methods. This means you can omit paymentMethodOptions altogether and we'd just pull the enabled PM types for your account
for my case, one of the platforms do not need to save the payment info and others might need/ not need (conditional). so I think adding paymentMethodTypes: ['card'] would make more sense.
~~it's working. ~~
do i need to make any changes for the payment handler which charges the card ? (does adding paymentMethodTypes: ['card'] require any additional changes to be made ?)
Give me a few minutes, just double checking this
okk
I see you crossed out it's working above
I take it you still see "Save your info for secure 1-click checkout with Link" in the PaymentElement even after passing paymentMethodTypes: ['card']?
i crossed out because, i got this error: Payment details were collected through Stripe Elements using payment_method_types and cannot be confirmed with a configured with automatic payment methods.
Save your info for secure 1-click checkout with Link is gone !! ๐ฅ
Got it, okay. I take it you likely created the PaymentIntent server side with automatic_payment_methods.enabled: 'true'. You should omit this altogether. This means the PaymentIntent will be created for card only
so, client side's change: paymentMethodTypes: ['card'] follows by ommitting automatic_payment_methods.enabled: 'true' on server-side (where we create paymentIntent) ?
is automatic_payment_methods.enabled: 'true' for getting the payment methods setup in stripe acc dashboard ?
Correct. If you use automatic_payment_methods when creating the PaymentIntent, the payment method types available for that PI will depend on your Dashboard settings
let me verify the changes
on server side, after setting automatic_payment_methods[enabled] to false, i had to remove automatic_payment_methods[allow_redirects] param as well.
do you think are these right server side changes ? it seems logical to me, but want to confirm before it goes to prod
yes, that's correct, but you should be also testing to make sure everything works as per you expect