#pauliita_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/1413581130573156372
đ 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.
- pauliita_api, 26 minutes ago, 11 messages
So in the previous conversation I was advised to set the payment method types manually on the stripe element in the client, then create the invoice with the same payment method types. I just want to validate my approach because I couldnt find much documentation about it online
You can create a one-time Invoice, then pass its Payment Intent client secret to collect the payment method details from the Payment Element
Are you facing any problem with this?
So this approach is correct?
No
I wanted to validate the approach
because the other thread was closed
When you pass the client secret to the client side, it should be set at Elements options, not at the confirmation request. It should work if you set the client secret at the correct place
I set it here
this.args.stripeInstance
.confirmPayment({
elements: this.args.stripeElements,
clientSecret: response.client_secret,
confirmParams: {
return_url: response.return_url,
payment_method_data: {
billing_details:
{
email: this.session.currentUser.email,
},
},
},
})
and it works
Generally, we recommend to set the client secret at the Elements group if you're using Payment Element.
elements = stripe.elements({ appearance, clientSecret });
const paymentElement = elements.create("payment");
For confirmation request, clientSecret doesn't have to be set
but I dont have the payment intent client secret at the time of the creation of the element
Im using the element without intent approach
Ah I see! Then the deferred intent flow like yours should work
great!! Thank you
And just another quik question.
I dont see apple pay and google pay as possible options for the payment_method_types
what should I do in that case?
Have you registered your domain with Stripe? https://docs.stripe.com/payments/payment-methods/pmd-registration
Apple Pay and Google Pay will only show after the domain is registered. Your website should be on HTTPS (not HTTP)
Apple Pay and Google Pay are part of card payment method type
Excelent!! thank you so much