#denno020
1 messages · Page 1 of 1 (latest)
Hi there, https://stripe.com/docs/billing/subscriptions/upgrade-downgrade have you got a chance to go through this doc?
I have not, but it looks like exactly what I'm after! Thanks
However in saying that, I still end up on the same Proration page that has me a litle confused (as I want to preview the proration beforehand)..
This is the code in question:
const items = [{
id: subscription.items.data[0].id,
price: 'price_CBb6IXqvTLXp3f', // Switch to new price
}];
const invoice = await stripe.invoices.retrieveUpcoming({
customer: 'cus_4fdAW5ftNQow1a',
subscription: 'sub_49ty4767H20z6a',
subscription_items: items,
subscription_proration_date: proration_date,
});
am I able to pass items like this (pulled from the upgrade and downgrade page):
[
{
id: '{{SUB_ITEM_ID}}',
deleted: true,
},
{
price: '{{NEW_PRICE_ID}}',
},
]
to the retrieveUpcoming function of invoices?
Thanks for waiting, discord is busy today