Stripe Billing Portal

Episode #460 by Teacher's Avatar David Kimura

Summary

In this episode, we revisit embedding Stripe, now that it's out of beta, and demonstrate how to integrate it seamlessly into your Rails application. We explore setting up Stripe for handling subscriptions, including a hosted management page where users can view invoices, change plans, or cancel subscriptions.
rails stripe payments 25:33

Chapters

  • Introduction (0:00)
  • Setting the secret keys (2:06)
  • Adding and configuring Stripe (2:51)
  • Planning the endpoints (3:35)
  • Adding attributes to the User (5:31)
  • Setting up the User model (6:35)
  • Checkouts Controller (7:55)
  • Creating the embedded view (13:17)
  • Fixing the routes (14:56)
  • Testing out the embedded checkout (15:24)
  • Payments controller (15:49)
  • Submitting the payment (18:02)
  • Addressing a flow in the subscription (18:19)
  • Billing Portal (21:33)
  • Saving Stripe Checkout Settings page (23:32)
  • Final thoughts (24:09)
Student & Teacher
$ 9 /mo

Valid School Email Required

Same Access as Pro

Subscribe Now
Pro Monthly
$ 19 /mo

Access to Pro Episodes

Invite to Slack Channel

Priority Suggestions

Ad Free

Subscribe Now
Pro Annual
Autumn Sale
$ 144 190 /yr

Access to Pro Episodes

Invite to Slack Channel

Priority Suggestions

Ad Free

Subscribe Now
Teams
$ 57 /mo

3 Users Minimum

$19.00 / user / month

Same Access as Pro

Subscribe to Teams