#xiaowo_api

1 messages · Page 1 of 1 (latest)

sick knollBOT
#

👋 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/1293150637391089699

📝 Have more to share? Add more details, code, screenshots, videos, etc. below.

oak lodge
#

Hi, let me help you with this.

#

Yes, you can update the PaymentMethod at any time. How do you want the customer experience to look like exactly?

graceful hedge
#

Can you please send me the link to the document for modifying the bank card number By update the paymentMethod?

oak lodge
#

There's many ways to do this. How are you currently creating the Subscription?

graceful hedge
#

this is the currenty way save the bank number when create the subscription

#

we may prefer to use code ways to help user to modify the card number

oak lodge
graceful hedge
#

hi, In practical applications, modifying bank cards is actually a relatively rare scenario, so I actually prefer not to modify existing subscription related codes. May I ask if there are any other ways for me to modify the user's bank card?

#

Of course, if this method does not exist. I will also redesign according to your suggestion above

oak lodge
#

Stripe will use the Subscription.default_payment_method, and if it's not available Customer.invoice_settings.default_payment_method.
So if Subscription.default_payment_method is not present, you can jut modify the Customer object. But, if default_payment_method is present on Subscription, updating the Customer object will not have any effect.
Overall, I would recommend updating the Subscription object directly.

graceful hedge
#

did i update the Subscription.payment_settings.payment_method_options.card feild

#

?

graceful hedge
graceful hedge
#

thanks very very much, I will carefully read the document first to see how to implement my requirements