#Osiris

1 messages · Page 1 of 1 (latest)

plain crescentBOT
past flint
#

I missed specifying subscription has a monetary threshold of 500$

latent hatch
#

Hi! Let me help you with this.

#

Could you please share a Subscription ID?

#

sub_xxx

past flint
#

The above is just a simpler example, I can send the test mode subscription on which I verified this behaviour.

#

sub_1MqXGVLJhqt57ntneuLhfijZ In this most recent 2 invoices are due to successive threshold

#

first invoice was due to 51 users. Then I removed a user which led to 50 users but the usage jumped from 0 to 50 and threshold was charged again. So customer was charged 50 units for removing a user. Ideally without threshold, they would have paid for51 users at period end as its max.

latent hatch
#

Could you please share how are you reporting usage?
For example share a Request ID? req_xxx

plain crescentBOT
past flint
#

simple

await stripe.subscriptionItems.createUsageRecord(subLi.vendorLinteItemId, {
          action:QuotaType.Increment,
            timestamp,
            quantity: usage
        });
#

sorry for the delay @latent hatch had a call

edgy sky
#

👋 stepping in as vanya needed to step away

#

Give me a moment to catch up

past flint
#

yeah sure

edgy sky
#

K looking at your example

#

Okay so that example Subscription has many many Prices on it

#

I assume you only mean to have a single Price, correct?

past flint
#

in file-storage example ? yes

edgy sky
#

sub_1MqXGVLJhqt57ntneuLhfijZ is what I'm talking about

#

Can you create a fresh example Subscription that just has the single Price

#

And then add usage as you described above

past flint
#

There are multiple prices in that subscription but only user-seats one is being used in test. The line with following price
price_1Mo1C8LJhqt57ntnO9vykMF9

#

si_NbkmoiF8JaeIHU is line id

edgy sky
#

So yeah it looks like this is happening because you have a billing_threshold set for $2,310.00 usd

#

So when you add usage past that amount for that Price then it is cutting an Invoice