#dr.schuego

1 messages · Page 1 of 1 (latest)

merry runeBOT
ember sapphire
#

This endpoint lets you preview invoices, not sure if you can preview metered usage. Consulting my colleagueshttps://stripe.com/docs/api/invoices/upcoming

gilded shadow
#

If a subscription exists, and it has an item with metered usage where some is already reported, then the upcoming invoice preview works fine.

ember sapphire
#

Yep, but you are trying to preview the usage itself it sounds like?

gilded shadow
#

Not the usage itself, but what it would cost if a customer would be subscribed to a usage based product with usage x.

ember sapphire
#

Gotcha, that was what I meant but I see how that was phrased strangely

#

Checking in to this and will get back to you

gilded shadow
#

Great, thanks 👍

merry runeBOT
ember sapphire
#

Apologies for the delay, unfortunately it looks like we currently do not offer this in our API at the moment but I will put in feedback about it.

#

If you have calculations on top of your base price like tax, you may be able to do something like calculate the base price of all the items and then preview the upcoming invoice with a one-off invoice item of that value, but I don't think we have a good solution for this today unfortunately.