Extending Laravel Spark to List Stripe Plans from the Database instead of the Configuration

Abishek
Work Done Right
Published in
5 min readJul 29, 2021

--

Recently I had a client that wanted to build an Application and wanted to support

  • Create Users and Invite them to the application.
  • Support for Teams
  • Setup Stripe plans through the application’s backend.
  • Ability to assign Stripe Plan to a user so they can subscribe and pay.
  • Support for Team Billing

I knew this was going to be a pretty interesting project to start with and I knew I had the right tools. So, I knew what I was going to use right away.

  • Laravel Nova — For the Applications backend/admin, so the client can manage all the metadata.
  • Laravel JetStream — Support for Teams with all the scaffolding already done. All I needed was to just add the package and run the migrations and I was good to go.
  • Laravel Spark — This was definitely the go-to package as it supports Subscription Billing for Stripe and also Team-based Billing.

So, I set up everything on my Laravel project and was ready to get the project kick-started.

So, the things I actually need to work on were:

  1. Ability to Create Stripe Plans from the backend…

--

--

Abishek
Work Done Right

I like to write about different stuff that may be of help to people. I am a husband and a software developer constantly learning new things every single day.