#fedeb_api
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/1351997833825222870
๐ Have more to share? Add more details, code, screenshots, videos, etc. below.
Hello, can you tell me more about why you are looking to add the dummy phase? Would creating a short trial or a period with a $0 price work for this potentially?
so trial no , 0 price yes could be.
I dont want to generate any invoice or nothing that can impact the current subscript as it is.
I want to add a dummy phase because Stripe does't like gap phases.
Asking other way : how I can add a phase that start on Abril 30? if the last currnet phase ends March 29
What kind of update is the new phase making? And are you trying to change when the subscription cycles as well?
Unfortunately we don't have a good way to do exactly what you are describing, so I am trying to think of potential workarounds.
I dont want tu change billing or cycle I just want to update the plan price but on a specific date.
We are doing migration for all users to new prices.
so we have two options:
1)run the day of migration 30 Abril, and update all users phases to the new SKU plans and it will impact inmediatly.
since there are a lot of users takes hours and days to fiish this.
(this works I tested before)
- I want to do the same but ahead of time, like establish a phase that will start on Abril 30 with the new plan and future phases with new sku plans .
but I will run this script that takes days does't matter since I will run this on Abril first.
If you only want to switch to a new price on a specific date, you can just have phase one go all the way to 30 Abril and then start the next phase then. Our phases don't have to line up with the subscription's cycles. You can also set proration_behavior to specify whether you want the user to be charged or not for switching prices at that point in the cycle
If that isn't what you are looking for, can you walk me through an example of what you want this to look like on each day of the schedule?
can you check the logs from here https://dashboard.stripe.com/test/logs/req_1PTCTuw8VbLZbL ?
you will see what Im sending in the request and the error
I get the error that you are getting and why. I am still a bit unclear on what exactly you are trying to do overall. Once I get that, I may be able to help suggest another way to accomplish it
Im sending this
{
"phases": {
"0": {
"automatic_tax": {
"enabled": "False"
},
"currency": "usd",
"end_date": "1743282276",
"plans": {
"0": {
"plan": "price_1NQvogE8gsL5R1XuBMzOMsdr",
"price": "price_1NQvogE8gsL5R1XuBMzOMsdr",
"quantity": "1"
}
},
"prorate": "True",
"proration_behavior": "create_prorations",
"start_date": "1740776676"
},
"1": {
"plans": {
"0": {
"price": "price_1Qw5vBE8gsL5R1XuK6DynKLQ"
}
},
"start_date": "1746021600"
}
},
"proration_behavior": "none"
}
the first phase is the same phase that API stripe returned when I call the API to crete scheduled stripe.SubscriptionSchedule.create.
this is the new phase that I want to add:
"1": {
"plans": {
"0": {
"price": "price_1Qw5vBE8gsL5R1XuK6DynKLQ"
}
},
"start_date": "1746021600"
}
},
"proration_behavior": "none"
๐ stepping in
hi
The end_date of a certain phase needs to match the start_date of the next phase.
In the erroring request there is a gap, as it says in the error message.
yes, how I can create a dummy phase or a phase that doest do anything? or maintein the same as previus phase?
since I want a phase to start on Abril 30, but the current last phase end_date is March 29
so there is a gap, what I can do in that gap
You would change the end_date of the previous phase to be until April 30th
Or you create a new phase in between
Up to you
but that will not modify his subscriptions or something? I dont want to change his billying cycle.
okay, and what I could I send in this phase to not modify his price, his billing cycle, etc
The billing cycle anchor would only change when the new phase is reached
I'd recommend testing this out using a Test Clock (https://docs.stripe.com/billing/testing/test-clocks) so you get a better sense of how this works.
okay thanks I will try playing with the end_date
but still API scheduled phases is hard to understand since we dont have control how its created or how can impact the original subscription, we can easly edit or remove that that we didt want to do in the firs place. etc
If you can pass the feedback to improve the documentation.