Library based on processing ... wait for it ... webhooks".
[1] https://github.com/hbcondo/revenut-app
[2] https://github.com/stripe/stripe-dotnet/issues/2284#issuecom...
Let me know how you find it! Happy to implement any fixes and PRs welcome!
I've linked a demo app linked in the post to try this out:
It uses Clerk for auth and Clerk seems to be having problems:
<https://downdetector.com/status/clerk-inc/>
So if you're having any issues loading the app, you may have to wait a bit!
And also, if you record all the webhooks events (and a backfill), that basically gives you your whole Stripe data available locally - I’ve actually put it to good use in diagnosing payment failure issues before.
Then, you run the `sync` command - it matches prices by a composite key: `productId:amount:currency:interval`. Since the amount has changed, it won't find a match for the old price. So, it will create a new price in Stripe and update the Price ID. Your new customers automatically get the new price in the Pricing Table component.
Your old subscriptions stay on the old price - which is still active in Stripe. We haven't added support for migrating these customers to the new price yet but it's in the roadmap!
I would like to add that we've tried making the porcelain / user API for the library to best fit today's commonly uses SaaS pricing models so most actions usually do what you would expect (like this price update) but, it's hard to strike a balance between customizability and the _just works_ factor.