#pramay_08848

1 messages · Page 1 of 1 (latest)

hearty tuskBOT
small pawn
#

the upcoming invoice includes the cost of the next month of the Gold plan.

#

the canonical way proration works is like this
https://stripe.com/docs/billing/subscriptions/prorations
https://stripe.com/docs/api/invoices/upcoming
https://stripe.com/docs/billing/subscriptions/prorations#preview-proration

The way proration and updates works in Stripe by default is

  • you have a subscription that is from 1 Oct -> 1 Nov for $100
  • on Oct 20 you change to a plan that is $200
  • we generate two prorations
    • a charge for 10 days of $200
    • a refund for 10 days of $100
  • on 1 Nov, the Invoice has three line items, the charge, the refund, and the $200 for the upcoming Nov 1 -> Dec 1.
#

However, when I retrieve the upcoming invoice, it's showing $25.
you can look directly at the lines on the Invoice and see what it's charging for as a breakdown.

stuck wedge
#

I want to get current month's prorated ammount's invoice

small pawn
#

not sure what that means sorry. Our proration works in only one way, and a very specific way.

#

For the Silver plan, the cost is $10, and for Gold, it's $20.
I expect the invoice to reflect $15 for that month (10 USD for Silver for the first half and 20 USD for Gold for the second half).
let's start with this.
when is this invoice that you expect? At the time you make the update, or at the start of the next billing period?

stuck wedge
#

at the time I make the upgrade

small pawn
#

ok. Then you can pass proration_behavior:"always_invoice:

#

in your example, it will calculate :
15 days of $10 (say it's $5) as a negative amount
15 says of $20(say its's $10) as a positive amount

and charge that invoice, so $10 - $5, it will charge roughly $5.
Then the next Invoice at the end of the month will be for $20.

stuck wedge
#

is invoice is made for next month? means is it prepaid?

small pawn
#

not sure what you mean, sorry.

stuck wedge
#

At the end of the month is it not done like below?
15 days of $10 = $5
15 days of $20 = $10
invoice total = $15
I am confused about the above scenario.

small pawn
#

At the end of the month is it not done like below?
at the end of the month, if you do not use proration_behavior:"always_invoice then the invoice will be :

  • unused time on Silver : -$5
  • remaining time on Gold : $10
  • upcoming month on Gold : $20

so $25.