#kennyjack_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/1367862140639248486
๐ Have more to share? Add more details, code, screenshots, videos, etc. below.
Below are links to other discussions we've had with you in the past week in case you want to review that information. If your question is related to one of these previous discussions, please provide a comprehensive summary of the current state and what you need help with now. We help many users simultaneously, so a summary allows us to resolve your issue as soon as possible.
- kennyjack_best-practices, 2 hours ago, 54 messages
- kennyjack_best-practices, 2 days ago, 20 messages
Hi i would like to continue from this thread #1367777259456303165 message
hey again
Can you share a quick summary of where you're at now and what you need help with?
Hi, sure
just to clarify, you can absolutely replace one price by another in a Subscription Schedule. so I think your next step is to make that work.
Can i know is there any api that can replace one price by another in a Subscription Schedule?
can you share the Request ID (req_xxx) where you got that error?
The request ID is req_ZxRdgif11boeBt
thanks, taking a look
This upcoming invoice request is incomplete, you need to specify the start_date for the phase (likely just echoing the current start date)
This mirrors making a schedule update request, which must specify these fields for each phase
Which question you're replying?
By the way i'm using Invoice::upcoming API from a subscription that having schedule
I also recommend switching from the old upcoming invoice API to the newer create preview invoice API
https://docs.stripe.com/billing/subscriptions/subscription-schedules#previewing-schedule-creation-and-updates
I'm replying to both. You asked about switch the price on a schedule, you can update the schedule or preview a change, but need to specify the existing phase details too (typically start/end date).
You need to pass in all current and future phases when you update a subscription schedule. You also need to pass in any previously set parameters that you want to keep. Any parameters that were previously set are unset for the existing phase unless you pass those in the update request. You still receive information in the response about past phases.
Thanks let me go through all the documentation
By the way i have one quick question
Can you check this request ID req_t5Whe2qb6mA519? I always facing this error message You can not modify the start date of the current phase.
What i've been doing wrongly or something i'm not understand about the phases? ๐
You're sending now which is not the start of the existing/current phase
you need to send the current phase start date as received from the API
Currently, its 1745988567
(2 days ago)
If you want to start a new phase with the new price, you need to send two phases:
- the current phase
- a second new phase with the new price, and use
start_date=now
but that now can only be on a new second phase, not the current one
Refer to the second example here: https://docs.stripe.com/billing/subscriptions/subscription-schedules#updating
This adds a phase with a new price, starting now
I see, Thanks alot for those information.
Seem like i not really understand the phases. I will go through the documentation.