#samip_best-practices
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/1293778789364535357
š Have more to share? Add more details, code, screenshots, videos, etc. below.
Hello, Checkout Sessions isn't what you want for this scenario (it also doesn't work for this), maybe you want to take a look at the Customer portal instead? https://docs.stripe.com/customer-management
your customers can upgrade the subscription through the customer portal
Thank you for the prompt reply
How do I supply the price ?
I tried to supply it inside features.subscription.update.products.prices but I am getting a TS error saying prices does not exists ?
subscription_update: {
enabled: true,
default_allowed_updates: ['promotion_code', 'price'],
products: {
prices: [priceId],
product: productId,
},
},
Complete reference documentation for the Stripe API. Includes code snippets and examples for our Python, Java, PHP, Node.js, Go, Ruby, and .NET libraries.
Sorry, I misread
it's an array of objects š¤¦āāļø
np!
Thank you, this is what I was looking for
One more question though, once the customer updates. Is there a way I can redirect them to my application without them having to click on return ?
I populated return_url but it only redirects after I've clicked on Return to <My Application>
there's no other way unfortunately, they'll need to click on the Return to....
And if the customer has a underlying discount, I can't remove it from the portal session right ?
do you mean you don't want to allow the customer to remove an underlying discount?
Can you please take a look at this invoice ID ? : in_1Q8Dq6Gei7MrDZaxx4eQ9Uvq
I have a customer who subscribed to Product X that has 4 different prices and had a 10$ discount, when the customer upgraded to a different priceID in the same Product X , the 10$ discount got applied.
I don't want it to apply on upgrade because I've already offered it once
are you referring to this coupon? https://dashboard.stripe.com/test/coupons/sAp15YFu
Sign in to the Stripe Dashboard to manage business payments and operations in your account. Manage payments and refunds, respond to disputes and more.
Yes
It is applicable to the same product, I am aware of that. However, I want to offer it only when they are on a smaller value plan and not when upgrading
that level of customization isn't possible right now. Since the coupon itself applies to the same product and over a duration of 12 months, it'll still apply in the situation you mentioned