#invester1357

1 messages · Page 1 of 1 (latest)

limpid hareBOT
#

Hello! 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.

wind imp
#

Can you provide the request id req_xxx where you create the SubSchedule?

lilac yoke
#

wait wrong one

#

req_nyMD4hR2kYKSQN

#

is my way of doing it incorrect?

  1.         checkout_session = stripe.checkout.Session.create(
    
  2.     if event_type == 'checkout.session.completed':
         print('🔔 Payment succeeded!')
         handle_checkout_session(session)
    

and I handle creating the schedule in step2

wind imp
#

Yeah that sounds normal. Looking...

#

Alright this looks normal. The Subscription Schedule has 2 phases of Feb5 2024 -> Feb5 2025, which an Invoice is already paid, and a future phases of Feb5 2025 to Feb5 2026 which an Invoice will be generated 1 year later

lilac yoke
#

so that second phase automatically comes when a schedule is created?

#

lets say my user downgrades but has paid for the year. I want to downgrade them next year, at the end of their current billing period

#

do I just need to modify and to swap the second phase my new one?

wind imp
#

You would want to modify the second phase, I think

#

You can try it, and use Billling Test Clock to "advance" to simulated time

lilac yoke
#

got it.

#

ok will try

#

I just didn't think it would create a future invoice billing phase instantenously

#

req_CH7CL3hJTStsaF

#

ok I think that worked?

wind imp
#

Yeah from the response

lilac yoke
#

ok and then when I upgraded..

#

it immediately updated the current phase

#

but kept the second phase as the previous schedule

#

so I would need to change that as well?

#

or the last phase

#

cause it looks like it closed out the first phase...

#

and now theres 2 but the 1st is locked in

#

I think I got the hang of this.

#

appreciate the help

#

I guess my last question would be

#

if I am making changes to a users plan via the API, I need to show them what they are going to be paying (if its an upgrade)

#

is that just an invoice api thing or something

wind imp
#

Yeah there is Invoice Upcoming API

#

You can try it

lilac yoke
#

and how do I ensure that...the latest phase has no expiration date?

#

basically so it will renew every billing period it's set to?

wind imp
#

It should. But you can verify by using the Test Clock

#

Advance the time pass the next and next's next billing cycle

lilac yoke
#

got it