#siv_api

1 messages ¡ Page 1 of 1 (latest)

violet mulchBOT
#

👋 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/1361749182746202133

📝 Have more to share? Add more details, code, screenshots, videos, etc. below.

summer brook
#

apiVersion: '2024-09-30.acacia'

violet mulchBOT
native mica
#

Hi! Sorry for the delay. So you're just adding a new item, not updating the existing one.

summer brook
#

Hey no worries. I currently am adding a new item but yeah I want to replace the subscription

#

Not sure if stripe checkout can handle all this

ivory cove
#

hiya! fyi i'm taking over for timebox - just wanted to let you know that there are several open threads atm but i will get back to you asap!

summer brook
#

Hey, thank you! No rush, as long as this thread doesn't go into read only mode I don't mind

ivory cove
summer brook
#

I have, but can you link people right to the correct upgrade place? I am worried people will get lost. Also we wont be able to track analytics. Finally the business plan is a multi seat plan so quantity is a factor as well

ivory cove
#

have you tried setting up the portal yet? the UI is pretty straightforward - it takes people straight to a page where they see their subscriptions, and if you've configured it so they can change their plan there's a big "update subscription" button

#

but yeah regarding analytics etc, you are losing that if you send them to a stripe hosted page

summer brook
#

Yeah I set it up in staging let me check again

ivory cove
summer brook
#

Thank you! I did read that doc. So my only worry with that is free trial behavior.

If you start a business trial and I update your subscription from pro to business via webhooks What happens after the trial. When you successfully finish your trial it should be all good with proration and everything.

But what happens if they cancel their trial? Would they automatically go back to pro?

ivory cove
#

a subscription doesn't really have an automatic memory like that - it has a Price / Product, and it can either be in trial or it isn't. so if you update the Price in the subscription while putting it into trial mode, and the trial ends, they will stay in the Price that you updated them to

summer brook
#

So when should I update them? So say I am a pro user and I start a 7 day free trial for business. Lets say I have 6 months left on my pro subscription I should be prorated like 50 dollars.

If I switch them on day 1 of their trial and they don't convert on their free trial do they go to having no active subscription at all? What about the amount they paid for?

#

Or I could wait until the trial is over but then they wouldn't get their 50 dollar proration they would be charged the full $400 business price

ivory cove
#

when a trial period ends, it automatically starts the billing period on whatever price they're on - so in this case not converting would mean they are either

  1. cancelling the subscription
  2. changing the subscription back to the previous price

any time you cancel or change a subscription you can handle whether prorations are created, and typically the easiest approach is just to update the subscription immediately, generate prorations, and then they're on the new plan right away

#

for cases like this it can be really helpful to just build a test integration using test clocks to see how things behave with different parameters - have you tried using test clocks yet?

summer brook
#

I have used test clocks before and it would definitely help test a solution once implemented but just want get my head around the solution before implementing

ivory cove
#

i honestly think they can be really useful in figuring out the particulars of how things work - i have a scripts repo locally where i will create test subscriptions with various settings and just progress them along using test clocks to see what happens

#

if you immediately update the customer to the trial + new subscription mode, we generate prorations by default, so whatever "credit" they had left on the subscription will either go to their next invoice, or to their customer invoice balance
https://docs.stripe.com/billing/customer/balance