#jayy26
1 messages ยท Page 1 of 1 (latest)
Hello! We'll be with you shortly. 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.
- jayy26, 3 days ago, 7 messages
Hi there!
I create a setup intent for user to add their payment method
create the subscription and charge it using the payment method ID provided from stripe.
Note that this is a pretty bad flow, since it can result in two 3DS in a row. So we don't recommend doing this.
The recommendation is to first create the Subscription, which will contain PaymentIntent (or SetupIntent), and use that.
do i have to update the subscription or just the customer when updating customer's default payment method
That's up to you, both work. Note that the Subscriptipn default payment method has more priority than the customer's default payment method for that specific subscription.
This is mentionned here: https://stripe.com/docs/api/subscriptions/create?lang=node#create_subscription-default_payment_method
I am honestly not sure what issue i faced with creating the subscription directly before, something that has to do with the current flow in the website that required me to do so. i'll change the flow to what you recommended and then it might pop up with the issue we had ๐
I tried to not include the default payment method, but it always error'd when creating the subscription ..
although the customer has multiple cards on their account
If the customer has a default payment method set, just set payment_behavior: "allow_incomplete" when creating the Subscription, and it should work.
Alright i'll give it a try, thanks soma ๐