#ilyeselb
1 messages · Page 1 of 1 (latest)
Hey there
heyy
Can you provide me an example Subscription ID that I can look at?
Thanks, taking a look
okay thank you
Okay so looks like you are using a SetupIntent to collect a PaymentMethod and then passing that PaymentMethod to the Subscription as the default_payment_method, correct?
yes
Are you anticipating starting these Subscriptions later on after collecting the payment method when your customer is no longer present on your website?
Or are you starting the Subsriptions immediately?
we are starting the subscription immediately after the payment
Okay gotcha
So in that case you don't want to use a SetupIntent here at all.
What you want to do instead is create the Subscription using payment_behavior: default_incomplete.
Then you pass the Invoice's PaymentIntent's client_secret to your frontend to use with PaymentElement and confirm that PaymentIntent.
That will both decrease the latency of your flow (less API requests) and handle 3DS whenver it is required for that initial payment.
The last thing you want to do is use payment_settings.save_default_payment_method
That will cause the PaymentMethod that is used to pay that initial Invoice/PaymentIntent to be set as the default for the Subscription
okay thank you, i will talk with the developer that coded that for us