For this guide, I'll be building a small premium content-based app for purely demonstration purposes. To get access to more content you would pay a subscription fee in a recurring fashion. One could argue that Ruby on Rails is overkill for this concept but think of it as room to grow ๐.
We'll leverage Stripe Checkout and Stripe Customer Portal to handle all the subscribing and billing logic. Additionally, we'll sync subscription data to our users and their subscriptions so we have a local copy of important details. To keep everything in sync we listen for events via Webhooks.
๐ Read the full article here: https://web-crunch.com/posts/stripe-checkout-billing-portal-ruby-on-rails
๐บ Watch the full screen cast here: https://youtu.be/bJtgeXtrXT4
Stack:
- Rails 7.0.1
- Tailwind CSS v3