#madwifi_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/1288465380825759797
๐ Have more to share? Add more details, code, screenshots, videos, etc. below.
free-days to an an active subscription with prorations
Can you speak more to this? What are you prorating exactly if it's 'free'?
OK, if the subscription is in active phase, I wanted to remaining days to be prorated back to the user. Essentially, if the plan is $20/year, and the user subscribed for 6 months, then in phase 2 the user should be charged only $10 ($20 of plan - $10 from remaining time)
Does this make it clearer?
What's happening in phase 2? Are you upgrading/downgrading their plan?
then in phase 2 the user should be charged only $10 ($20 of plan - $10 from remaining time)
Because what you describe is how basic proration works for upgrades/downgrades โ we'd apply credit for the unused time
Phase 1 - give user free trial
Phase 2 - resume their previous plan
because stripe doesn't allow prorating an active subscription when giving a free trial, this is getting complex for me
I think you'd be better off just applying a coupon/discount for the 2nd phase as you can't really apply prorations in relation to trials
hmm, I cannot do that as there is a different flow for coupon/discounts.
hi there!
when you create the schedule, you can set discount to change the amount the customer has to pay. this should have no impact on your existing flow. https://docs.stripe.com/api/subscription_schedules/create#create_subscription_schedule-phases-items-discounts
hmm. the problem with discount is that the user can choose different plan and they can avail this offer any time as well, so I would be creating arbitary discounts left-right-and-center if I am to use this.
e.g., a user availaling the offer on $30/month plan on day 1 would need different proration than another person who is on a $50/year plan availing the offer on day 25
yes, you could dynamically generate the coupon to adjust the price the customer pays.
technically yes, but just because I can, it doesn't mean that I should. ๐ The Finance/Reporting team would cause a ruckus if I do that, so it would be not an ideal scenario to put it mildly.
then you have to add 3 phrases to your schedule:
- phase 1: free trial
- phase 2: custom price
- phase 3: resume their previous plan
would it be possible to delete the price once the phase 2 is complete?
sure. or don't create a Price at all, and use price_data instead: https://docs.stripe.com/api/subscription_schedules/create?lang=node#create_subscription_schedule-phases-items-price_data
ohh! this is a new info. will look into it.