#dopeboyz

1 messages · Page 1 of 1 (latest)

woven craterBOT
balmy adder
#

Hi there!

#

Can you summarize your question in this new thread?

sterile girder
#

So i am having issue with upgrading and downgrading

#

Here's the video

#

I want to achieve this via code using scheduledUpdate as i am doin it from dashboard

#

The first image has code for downgrading via schedule update

#

And second is for upgrading the pacakage

#

@balmy adder

#

When i do it through API somehow the billing gets $0 i am not sure why

balmy adder
#

Sorry for the delay, having a look now.

#

When i do it through API somehow the billing gets $0 i am not sure why
Can you share the subscription ID (sub_xxx) related to this?

sterile girder
#

Umm okay

#

sub_1MbeJPA6RSS0ndD1omfErJ9g

balmy adder
#

Sorry for the delay, having a look.

#

But both price have the same amount ($20) is that expected?

sterile girder
#

No

#

Please look above code

#

In phase 1 i am adding the new price

#

And could give a look at the video i have attached that's what i want to do while upgrading and downgrading

balmy adder
#

In the request I shared above (based on the subscription ID you sent) I see this:

  • Phase 0: price_1MbeJPA6RSS0ndD1bJWi19bE => $20 monthly
  • Phase 1: price_1MbeKdA6RSS0ndD1qbasttXF => $20 monthly
sterile girder
#

But im creating a new price

#

So is it something wrong with my code?

balmy adder
#

Maybe you shared the wrong subscription ID with me? Or you are passing the wrong price ID? Or when you create the price, you set the wrong amont?

sterile girder
#

Could you please look at my code and tell me if i am doin it correctly

#

As i am doing it manually in video

balmy adder
#

Your code doesn't mean much to me, since I don't know what your variables mean (for example price.id). What I can do is look at a specific request ID to see what you did. In this request req_oAXlYACw3RjrO5, you set a subscription schedule with 2 phases and 2 different price IDs. But both price have the exact same amount.

#

Do you have a different request ID that you want me to look at?

sterile girder
#

Do i have to delete the old price

balmy adder
#

No, you just need to make sure that the new price Id you are creating/using is for a different amount.

sterile girder
#

How do i write the phase in schedule update could you please explain in my case

#

Am i creating the phases correctly?

balmy adder
sterile girder
#

Alright I'll cross check

#

And please don't close this thread i have explained this a lot times