#shahzaib3575
1 messages · Page 1 of 1 (latest)
It sounds like you might want to look at subscription schedules to plan changes for later:
I also had to remove the Cancel Subscription button from the customer portal because it was canceling the current subscription immediately. I had to create my own API request for this:
await this.stripe.subscriptions.update(subscriptionId, {
cancel_at_period_end: true,
})
it looks like a custom solution. aren't there any minimal code solutions for my use case? can't the customer portal session cover this with config change?
at first i thought disabling proration would work for me but it doesn't.
What behaviour do you get when you disable that which is not what you expect/want?
i want something like this: Upgrade current plan at the period end and cancel current plan at the period end.
Upgrading, in this context, is replacing the current plan with a new plan
"cancel" has a specific meaning of ending a subscription, so i'm trying to avoid that
replacing current priceId with the new one
Right, so letting the customer upgrade via the portal and disabling prorations I would expect to do this, i think
You tried that and didn't get what you expect?
yeah. screenshot of the activity is provided.
im using clock to test it out.
What do you mean, can you say more?
@meager oasis
So the customer is created and subscribed to the professional plan with 30 days trial.
Customer went to the portal and added the payment method.
Then he/she subscribed to the Basic plan which happened immediately and the trial of the Professional plan is ended and he's charged for the Basic plan.
Later he/she changed the plan from Basic to the Professional and it happened immediately and also charged.
I want every subscription change to happen at the end of current billing period.
That upgrade to professional seems like it was a full month later, no? Can you share the test subscription ID?
sub_1NnQuqLvHvA7k88Qjri5r6KU
yeah... let me rerun that scenario one more time to be sure. But the Trial to Basic happened immediately, any way to counter that?
Thanks for the ID, checking in to this...
@meager oasis @north needle
I rerun that scenario. Trial of Professional plan -> Basic -> Professional in the same day.
Even though it charged for the Basic plan immediately, the current active subscription plan is Professional.
New subscription ID: sub_1NnRq2LvHvA7k88QooiTgIiE
Thanks for the testing. It is looking like this may be behavior that is specific to the Customer Portal as normally this kind of change does not immediately end trials. Working to confirm this and will get back with what we can find.
@torn badge unfortunately it looks like this is expected behavior at the moment for when the Customer Portal makes this update. We're adding to the feedback to flag this behavior more clearly in our docs and are adding to the feature request for allowing the Customer Portal to change plans without ending trials like this
For now, I think you would need to make your own page for changing plans to avoid this behavior