#jorge-frota_subs-upgrade-trial
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/1301610768206266439
๐ Have more to share? Add more details, code, screenshots, videos, etc. below.
Hi ๐
Have you tried making your changes via the API?
https://docs.stripe.com/api/subscriptions/update
Also, I am finding your logic for when to/not prorate confusing. Can you break down the specific scenarios for each?
Sure, I'm sorry I wasn't clear. I'll try to break it down.
Let's say user is on the PRO Plan ($20). In the middle of the month, he wants to try the new Premium plan ($60).
I want to make it so that at the end of the trial, he'll only pay the difference (proration) immediately, and his billing date should stay the same as before.
If he feels like Premium plan is not for him and wants to cancel the trialing, nothing should happen, he shouldn't be billed at all and his previous billing date (when he was on PRO) should also stay the same.
I didn't try it through the API yet, but I'll fiddle with it a little bit here
Okay so there's still a free trial period for the new Premium plan even though the customer is already subscribed?
Yup!
I think the easiest way to approach this would be to ignore using Stripe to track this kind of trial altogether.
Here's how I would do it
- Customer has already paid for Pro plan and is in the middle of billing cycle
- Customer upgrades to Premium with 3 day trial - No change made to Stripe subscription (just provision new service)
- If customer wants to keep Premium, update Subscription to the new price and generate prorations for the remainder of the billing period
- If customer decides not the keep Premium - no change is made and the billing cycle keeps going.
Actually, let me amend that. For the period where your already subscribed customer is trying out the Premium level - update the metadata for that Subscription so you can see it in the Stripe dashboard https://docs.stripe.com/api/subscriptions/update#update_subscription-metadata
Great! Something like a boolean flag ("premium_trialing: true") right
I like this solution
Yeah I think that will be the easiest approach for you. Otherwise you are likely to wind up with billing cycles being changed and having all kinds of trouble reverting back
Yeah I was already going crazy with this, but your solution will work out just fine. Thank you so much for your help!
Happy to do it! It's why we're here ๐