#dopeboyz
1 messages · Page 1 of 1 (latest)
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
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?
Sorry for the delay, having a look.
So this is the request you made: https://dashboard.stripe.com/test/logs/req_oAXlYACw3RjrO5
But both price have the same amount ($20) is that expected?
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
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
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?
Could you please look at my code and tell me if i am doin it correctly
As i am doing it manually in video
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?
No, you just need to make sure that the new price Id you are creating/using is for a different amount.
How do i write the phase in schedule update could you please explain in my case
Am i creating the phases correctly?
Based on https://dashboard.stripe.com/test/logs/req_oAXlYACw3RjrO5 your code looks correct, you just need to use a different price ID in the second phase.