#dingkai031
1 messages · Page 1 of 1 (latest)
hello! how can i help?
Hello I'm trying to set-up a subscription schedule like this(image). But, the status of the subscription is immediately active. Is that normal?
that's expected behaviour for Subscription Schedules. When the schedule starts, the subscription’s initial status will be active with an initial draft invoice that is scheduled to finalize in an hour. Depending on whether payment of the initial invoice is successful or not, the subscription will either stay active or transition to past_due.
okay, can it be not active before any payment is success?
then you may want to consider changing how you integrate then - You may want to first create a subscription, then create a Subscription Schedule from the Subscription
but if I do that, is the subscription will immediately start from phase one?
assuming I add schedule after invoice.paid event
When you create the Subscription (not a Subscription Schedule), you should create it with what you would want it to start with (i.e. the first phase's prices)
sorry, previously in this thread (#1042788378858500097 message). I ask the stripe team to help me to make a subscription flow like this creating a subscription that have a "paid trials" plan for a week, after a week it will start a monthly plan. And the customer will be charge automatically every month until they cancel the subscription
And they suggest me to use a schedule api.
In the docs say that, if the phase one is finish.. it will release to the default subscription plan. I was thinking to make a basic plan for phase one, then when phase one finish.. it will release to premium plan.
So if I start it with the basic plan (in the subscription), later add a schedule phase one to premium plan. I'm afraid if will release back to basic plan after phase one is complete.
Discord is the easiest way to communicate over voice, video, and text. Chat, hang out, and stay close with your friends and communities.
creating a subscription schedule from an existing subscription should still work if you include phase 2 to update the subscription to a premium plan. I'd suggest that you try it out and see how it works
so, what should I do is. Create a subscription with a basic-plan, then after invoice.paid event I add a schedule with 2 phase , which phase one as a basic-plan and phase 2 as a premium-plan ?
yes, that's right
okay, I want to make sure one thing. Will the customer get double charged? (in subscription and phase 1 schedule subscription)
they shouldn't but this is why you'd want to test to make sure that everything is working as expected
in case you haven't seen this yet, you can use test clocks to mimic the passing of time : https://stripe.com/docs/billing/testing/test-clocks
okay, I will try to do that. Thanks
hello, I have try it and I got an error in webhook log <b>Fatal error</b>: Uncaught (Status 400) (Request req_cRmYH26HHtH6Kf) You cannot set `phases` if `from_subscription` is set.
you need to do it in separate requests
when you create a subscription schedule from an existing subscription, you cannot update the phases at the same time
so request 1: create a subscription schedule from an existing subscription, request 2: update the phases of the subscription schedule
okay, I will try that
I receive another error, in webhook log <b>Fatal error</b>: Uncaught (Status 400) (Request req_AoTLJNznRRaLXK) The subscription schedule update is missing at least one phase with a `start_date` to anchor end dates to.
but when I add it I receive another error : <b>Fatal error</b>: Uncaught (Status 400) (Request req_17nrA8yd9irSt9) You can not modify the start date of the current phase.
👋 Taking over from alex, catching up now
hello, thank you
Can you try to set timestamp of the start date in the first to the timestamp in the current phase?
You can get the timestamp from current_phase.start_date
okay will try that
okay it works now, thank you Strip Team 😄
No problem! Happy to help 😄