#sorieng_code
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/1315679925222768640
đ Have more to share? Add more details, code, screenshots, videos, etc. below.
Can you share a sub_xxx or in_xxx ID or something where this is an issue?
Or the API request ID that throws the error(s)?
this is the subscriptionId: sub_1QU5rjRsJoxeHGedU8L9XdOc
Not sure how this works with portal as, AFAIK, it doesn't support those PMs
Hmm, don't see any such errors on that sub?
In the response headers for that request there'll be a req_xxx ID. Can you share it please
req_7tbWmntUTY91jS
Thanks, looking!
OK, looks like an issue with the portal not supporting these PMs. Going to flag internally, give me a moment
Appreciate the patience, we're investigating
thanks! not sure how the process is so is it usually that we can wait for the fix soon or does it take some time (as in days/weeks)? if latter, was hoping to ask questions to handle the upgrade process using server side SDK as a workaround.
It'll be an expedited fix, but I can't give a solid timeline. Certainly not weeks
How can I help with the workaround in the meantime?
I see. When I tried using stripe.paymentIntents.create to handle the upgrade payment on the server, I am currently getting this error: The PaymentMethod provided (kr_card) is not allowed for this PaymentIntent. Please attach a PaymentMethod of one of the following types: card
request-id of a try: req_foSrzf1AvDWOxX
example code that I tried:
await stripe.paymentIntents.create({
amount: getPriceInStripeFormat(priceDiff, currency),
currency,
description: order.name,
automatic_payment_methods: { enabled: true, allow_redirects: 'never' },
customer,
payment_method: latestMethod.id,
setup_future_usage: 'off_session',
});
await stripe.paymentIntents.confirm(paymentIntent.id);
Hmm, why are you creating the intent directly? If you want to update the subscription outside of the portal you'd call this endpoint: https://docs.stripe.com/api/subscriptions/update
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 reason why this errors is because you're excluding the provided PM type (kr_card) by passing allow_redirects: 'never'. The Korean cards require a redirect to work
My recommendation, when you're passing the payment_method parameter like that, is to omit automatic_payment_methods compltely and explicitly pass payment_method_types: ['kr_card']
got it
- if we update the subscription, does it automatically process the payment with the price diff? if so does it not require additional user action?
- what we want is to process the upgrade/payment without user having to enter the payment method again. if it requires redirect does it mean that it is not possible?
No they shouldn't be redirected a 2nd time. It's just a detail on how the PM filtering works