#spendsmart_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/1312002946879197188
đ Have more to share? Add more details, code, screenshots, videos, etc. below.
Hi, let me help you with this.
When you set the PaymentMethod on the Subscription it should already be set up by that time, i.e. 3DS has already been taken care of.
How are you getting the PaymentMethod right now?
At that time 3DS taken care. In my system, customer add multiple card, I switch card using payment method id I already have.
but when card get switch it should ask 3DS again for already stored card.
https://docs.stripe.com/api/subscriptions/update#update_subscription-default_payment_method
I am following this api, the payment method get switch automatically when I call the api. But when it try to process invoice it gets failed.
Complete reference documentation for the Stripe API. Includes code snippets and examples for our Python, Java, PHP, Node.js, Go, Ruby, and .NET libraries.
but when card get switch it should ask 3DS again for already stored card.
Why?
because generally when we create subscription on card, it generate mandates in the card after confirming 3DS.
Is this your own requirement to ask for 3DS before updating the card?
https://docs.stripe.com/api/subscriptions/update#update_subscription-default_payment_method
I am following this api, the payment method get updated when I call the api. But when it try to process invoice it gets failed and ask for 3DS.
Complete reference documentation for the Stripe API. Includes code snippets and examples for our Python, Java, PHP, Node.js, Go, Ruby, and .NET libraries.
The point of using SetupIntents to collect PaymentMethods is to avoid needing to do 3DS in the future: https://docs.stripe.com/payments/save-and-reuse?platform=web&ui=elements
After the card is set up you can use it with Subscriptions and one-off payments freely, without repeating 3DS
Let me explain you.
I have normal upfront package buying those are like one time payment.
I have other subscription payment.
So I may have already stored payment methods which were used for single time payment.
Now I am switching payment method to one of the stored payment method
Generally, if the PaymentMethod wasn't created with SetupIntents or PaymentIntents with setup_future_usage parameter, it should only be used once.
So you have to ask your customers to add a new PaymentMethod with one of those methods/parameters
ok
is there any programming way to generate link https://docs.stripe.com/billing/subscriptions/update-payment-method ?
Yes, using SetupIntents (or Stripe Checkout with mode=setup) and calling update Subscription API to set default_payment_method.