Live data from Hacker News

Implementing API Billing with Stripe

daily.co

1–10 of 84 posts

Re: Implementing API Billing with Stripe

#3
Thanks for sharing.

I’m curious why there is an even number of cents requirement on stripe’s end?

I’m also not a fan of the quantity 1 line item rollup, although I understand the workaround. For the customer receiving the invoice, it makes it harder to breakdown the invoice in an automated way, since the detail info is moved to a text block.

Re: Implementing API Billing with Stripe

#6
post #4
post #2

This is unnecessarily complicated. That's why I handle all subscriptions with PayPal.

How does PayPal handle granular billing like this?

Simple. Send the customer to PayPal with a subscription request, the amount and customer id. They activate the subscription and pay. Get that id back via IPN after each new subscription. Deliver the service. Done!

Re: Implementing API Billing with Stripe

#7
post #6
post #4

Earlier quoted context omitted.

How does PayPal handle granular billing like this?

Simple. Send the customer to PayPal with a subscription request, the amount and customer id. They activate the subscription and pay. Get that id back via IPN after each new subscription. Deliver the service. Done!

How does that match the use case here, with billing per minute? If the user has to confirm each subscription, you can't efficiently create new subscriptions for e.g. each call. You also can't know beforehand how much you'll need to bill. If you're at the end of the month sending a single "here's everything" request, I fail to see how that's different from what's described in the article.

Re: Implementing API Billing with Stripe

#8

   A good first question to ask about a data model is, "where does the data live?"

   In general, we think it's a good idea to make Stripe the "one true source" for as much of your customer and billing data as possible.
Our company went the opposite way, we have our own model and we abstract stripe as a payment option supported. Recently with the same model we were able to add Paypal and other country specific payment methods.

Re: Implementing API Billing with Stripe

#10
post #7
post #6

Earlier quoted context omitted.

Simple. Send the customer to PayPal with a subscription request, the amount and customer id. They activate the subscription and pay. Get that id back via IPN after each new subscription. Deliver the service. Done!

How does that match the use case here, with billing per minute? If the user has to confirm each subscription, you can't efficiently create new subscriptions for e.g. each call. You also can't know beforehand how much you'll need to bill. If you're at the end of the month sending a single "here's everything" request, I fail to see how that's different from what's described in the article.

Paypal has APIs that support that. Example: https://developer.paypal.com/docs/classic/express-checkout/e...
Post reply on HN