#bfitz_1992
1 messages · Page 1 of 1 (latest)
Hello bfitz_1992, we'll be with you shortly! 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.
• https://discord.com/channels/841573134531821608/1163893181100855326, 1 days ago, 93 messages
Sure it's the schedule for sub_1O2bY7EjLMO6STxRBjD9BgaA. I created this through the Stripe dashboard by editing the phases in the UI, and it let me specify the number of months in that last phase
When I look at the phases on that schedule, all I see are the start_date, end_date and the price itself (which tells me it's a monthly price). So I have to do something like end_date - start_date and see how many month periods are in that difference. Which works (so far), but yeah, wondering if there's an easier way to see how many iterations the phase was created with
(For context, I'm trying to insert a new gift phase after the current one, which means I need to push every phase after that back by some amount. I tried calculating the start|end_dates manually, but there are so many datetime gotchas like leap years, so I want to rely on the iterations property when calling subscriptionSchedules.update and let Stripe determine the start|end_dates for each phase)
But for that, I need to know how many iterations that phase originally had
Gotcha
Ok, looking at this 🤔
I don't think there's presently a better way to do this
yeah it's a stumper for sure
one option would be setting your own metadata on the phases to track those initial iterations:
https://stripe.com/docs/api/subscription_schedules/update#update_subscription_schedule-phases-metadata
WHich you; be able to look up later
Hm so if we do it through the Stripe dashboard, add metadata there too perhaps?
I'm not sure if the dashboard supports that
Oh right it's metadata for the entire subscription, not each phase
Oh well, thanks for confirming at least!
Is it possible to put in a feature request, to make that iterations property accessible on the Phase object?
I've shared some feedback about exposing iterations you set to make this easier
Awesome, thank you!