#scif-paymentelement-mandate
1 messages · Page 1 of 1 (latest)
Hi there! Just to confirm, is there a gap of time between steps 2 & 3 above?
In other words, if you're asking whether the flow above should be used to immediately create a charge, then no. If you're creating a charge shortly after collecting a customer's payment details, you can skip steps 1&2 altogether. If any authentication is required, this will happen when your frontend confirms the PI
There is no time gap, all steps will be done in one session. The idea of 1&2 is next: we support multiple payment methods and creation of subscription/PI requires different set of parameters for different PM's (for example: card vs SEPA vs Giropay — requires 3 different sets of parameters)
Hm, not sure I follow. If you're using Subscriptions, you should allow the PI to be automatically created by the subscription.
If you want only some PMs to be available to use for a given Subscription's invoices, you can list those out when creating the Subscription: https://stripe.com/docs/api/subscriptions/create#create_subscription-payment_settings-payment_method_types
Subscriptions to be paid by Sepa should be created with 'payment_behavior' => 'allow_incomplete' while to those paid by a card must be created with 'payment_behavior' => 'default_incomplete',
Therefore I cannot create one subscription, fetch it's PI's clientSecret and use it for confirmSepaPayment() as well as confirmCardPayment()
Hi, stepping in and catching up here
I'm re-reading the ask here and not fully understanding the ask, I'm sorry. Can you reword this 'Will customer be requested second time to pass 3ds/confirm electronic mandate/whateverSCAcheck on step #5' ask please?
Use stripe.confirmCardSetup in the Setup Intents API flow when the customer submits your payment form. When called, it will confirm the SetupIntent with data you provide and carry out 3DS or other next actions if they are required.
This is a quote from docs. So if a customer in India then they will be asked to accept electronic mandate or/and pass 3ds checks
Use stripe.confirmCardPayment when the customer submits your payment form. When called, it will confirm the PaymentIntent with data you provide and carry out 3DS or other next actions if they are required.
This is for confirm*payment methods
As I can see, both methods are going to conduct any checks required customer actions (3ds/electronic mandate/etc)
Does my question make sense now?
scif-paymentelement-mandate
👋 I'm not really following your multiple separate asks. Can you share concrete example requests for me to work backwards from?
also if you could link the exact doc(s) you are reading, because you are quoting parts of it but we have hundreds of docs and I don't really get what you're looking at
Mostly start from your real question. Because no one should really be using confirmCardSetup() in most cases. So what are you really trying to do. Why do you create the SetupIntent yourself? Why do you then create the PaymentIntent? Where does SEPA Debit (europe) come into play vs you talking about Indian regulations
Sorry you just asked many mixed up things that are quite different and right now I don't really understand what the real original question is
If you do SEPA and others, you really should be using PaymentElement instead
You also mentioned Subscriptions but started with PaymentIntents so I'm totally confused
Thanks for your patience and trying to figure out! Let me explain
My platform sells both one-off (implemented as invoice charges) and subscriptions. Also, I'm trying to provide as much payment methods as possible: cards, gpay, for EU: sepa/giropay/ideal, for India:netbanking, upi…
Okay so you have an Invoice, that Invoice has a PaymentIntent, and you use PaymentElement to confirm that PaymentIntent
If you aren't doing that, you're already making your life harder
For one-off purchases I create an invoice, grab PI's clientSecret and send it to FE. On FE I use confirmCard/Sepa/…Payment()
But! Invoice must be created with different params based on particular payment method customer tried to use
Like 'collection_method' for some methods should have value of 'send_invoice' and 'charge_automatically' for others
Therefore I cannot create one invoice and try to complete the payment using any payment type
Is this correct?
I don't really grasp what that could mean so I want to say not really. But yes some payment methods only work with send_invoice. But do you really need every single payment method?
Ok, let's imagine just two: for EU clients: card and giropay. Card does not require while giropay requires
The idea how to overcome that issue was next: I create a setupIntent (SI) and ask customer to confirm it. Once I've collected it, I could be sure, that card or bank account has passed all required checks (sca/3ds/etc). Therefore I can create a PI just for this payment method and customer will not be willing to change it
Does it make sense?
what does that mean "giropay requires"/ Requires what?
Collection method to be set to send_invoice
sure but if you care about Giropay absolutely then you would default to that and it works fine for card
Ok. Cool. Will do, but similar issue happen with subscriptions
For cards I have to set 'payment_behavior' => 'default_incomplete', but for other types to 'allow_incomplete'
but why? that's the part I'm lost about
To use completeCard/Sepa/*Payment() I have to provide a clientSEcret
but just use PaymentElement and use the normal confirmPayment()
Sorry, that's where I'm lost 🙂 How the PaymentElement will help with this? The requirement to specify correct payment_behavior comes from Stripe api, afaik
I'm fairly confident that is not correct
I haven't tried this in a while that's why I'd like to get more specific details from you
Hmmm. That's interesting. So, does it mean I should just create a subscription with no payment_behavior specified using my BE and then try to use confirmPayment()?
I think so
Ok, let me try
Will this be working fine if there are several payment elements mounted to the same Stripe instance?
why would there be?
One page contains several methods, so I use the same variable to store stripe
what does "contains several methods" even mean?
The goal of PaymentElement is to take one client_secret and render a UI to offer any support payment method all in one screen
what does "contains several methods" even mean?
Ahh, I remembered why using of confirmPayment() is not really the case to us — we handle coupons on the same page and creation of a subscription must be done once coupon entered
😅 yeah I'm sorry I'm really struggling to grasp what you're doing, you seem to have a really complex payment flow
yeah I think overall you seem to have a strange integration path and then my advice with PaymentElement is not going to work for you if you don't change your payment form
Do you mean PaymentElement===stripe.confirmPayment() or any stripe.confirmCard/Sepa…Payment()?
😅 I don't even know what your sentence could mean.
But yes PaymentElement goes hand in hand with confirmPayment()
Do you mean https://stripe.com/docs/js/payment_intents/confirm_card_payment would not really suit my flow as well as confirmPayment()?
since you have multiple payment method types, it would be easier for you to use the Payment Element and confirmPayment. confirm_card_payment only works for cards
We went through this above. This will never work for them. They have a super complex flow collecting a Coupon upfront, it's just not viable. Unless they re-design their whole UI, the best option is to stick with "separate elements for each payment method type"
aaah
I mean overall what they really want is the https://stripe.com/docs/payments/accept-a-payment-deferred beta I think
Wow, that looks promising!
if you want to get access to it, you can reach out via the contact us on that page