#slaisson_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/1285476094723756104
đ Have more to share? Add more details, code, screenshots, videos, etc. below.
However problem with that is that when they cancel one newsletter but want to keep the others, there is no built-in way to keep track that they are still entitled to the that newsletter until the end of the period
Could you elaborate a bit more here? When they unsubscribe from one items, you can just make an Update Subscription API to remove the specific items, no?
Indeed I can, but how would I keep track that they are still entitled to it for the rest of the period. Let's say they subscribe to 3 newsletters at the start of the month, halfway through they unsubscribe from just 1, they should still keep receiving all of the newsletters until the end of the month. Next month they should only receive the 2 newsletters they kept.
I could use the metadata but it introduces some annoyances. But I think that could be one option.
Simplest way to keep track of this would be to have separate subscriptions for each
I can just set "cancel_at_period_end" and it would be very simple to manage.
Let's think as of 1 Subscription first. How about setting up a schedule that decrease 1 newsleter from the next billing cycle?
You can create a SubSchedule from a Sub, then modify the Schedule to control the Sub future
Hmmm... that could work. I had some trouble wrapping my head around the Schedules. But what you are saying is, that when they cancel one item from a subscription, I could then create a Schedule with phase with all of the items, followed by a phase with just the two items?
Close! You create a SubSchedule from the Subscription first, and save its Id. When you customer make the change, you modify the SubSchedule to reflect the change in next billing cycle
https://docs.stripe.com/billing/subscriptions/subscription-schedules/use-cases#existing-subscription
Okay, having a bit of trouble understanding how the SubSchedule works here. How does the Schedule change the "underlying" Sub?
Can I have no phases at the start?
Customer then removes one item midway through. I would then create a phase with the other 2 newsletters that starts next month?
Can the phase be indefinite?
What happens when the phases run out? Does the whole Schedule get deleted and the underlying Sub continues the way the Schedule changed it?