#hsoftware-subscriptions

1 messages · Page 1 of 1 (latest)

marble merlin
#

Hello! Give me one minute and I can help

prime pumice
#

Hi karbi! Sorry for the delay, I didn't get a notification. Yes, I've been looking at the docs. So far the only way I can see to update Stripe is to tell it not usage, but the actual total cost. What are your thoughts? Do you see a better way?

#

The issue I'm seeing is that the price per call can only be determined by an API call.

marble merlin
#

Usage-based billing is centered around the idea that you report usage to Stripe, and we take that total usage and calculate the cost for you - does that sound like what you want?

prime pumice
#

Yes

#

Do you have any ideas how we can report usage in our very complex setting?

#

Karbi, does that answer your question? Do you have any other questions for me?

marble merlin
#

Sorry I completely missed your follow up! What in particular about your usage reporting are you concerned about? I imagine you'd model this with a few different prices on a single subscription, and then report usage to the relevant price (depending on the information you get from the phone provider), but I may be oversimplifying your question

prime pumice
#

No problem at all

#

Well, I'm concerned about how we would report usage. How would you do it?

marble merlin
prime pumice
#

Right, that's what I saw, but we're talking about possibly a different price for every call that a customer makes.

marble merlin
#

Ahhh, that's the part I was missing - I assumed you'd have a set number of prices that you'd be working with, but if you need to use a custom price for EVERY usage call that's different

prime pumice
#

Right, it's even more complicated.

#

So the phone operator bills all US Local calls the same. If we did it this way we'd create a new subscription_item_id for every call, but all US Local Calls should share the same subscription item id.

marble merlin
#

But those you'd model differently - if you know your US Local calls are always billed the same, you can just create a single subscription item for it and report all usage on that one item as it comes in.

prime pumice
#

But then we'd need a way to do a db query for the subscription_item_id

marble merlin
#

Well no matter what you'll need to know what subscription to report usage for, and if you have the Subscription you can retrieve it's subscription items and look for the one that matches the US Local calls product

#

But backing up a bit, it may be easier for you to think about this in a different way -

prime pumice
#

Oh yeah? How so?

#

My current idea is to just store the price per call in our DB, manually calculate the aggreate bill every month, and just report the dollar amount to Stripe

#

Other solutions seem really complicated

marble merlin
#

You could choose to keep track of all this yourself, and then generate an Invoice Item that reflects the total amount you want to charge. If you do this in combination with a $0 Subscription, the subscription will continue to generate Invoices and automatically pull in the Invoice Items you create.

prime pumice
#

Aah, so if I'm understanding correctly you also suggest just reporting the total dollar amount to Stripe. Is that correct?

marble merlin
#

Yup! it seems like your billing model is complicated enough that just reporting a total dollar amount is easiest

prime pumice
#

Got it.

marble merlin
#

If you were working with a standard set of prices (no custom one-of pricing for certain amounts of usage) then I'd suggest you go with reporting usage and letting stripe aggregate it, but it doesn't sound like that'll work for you

prime pumice
#

brb