Be part of JetBrains PHPverse 2026 on June 9 – a free online event bringing PHP devs worldwide together.

connecteev's avatar

Refresh for Laracasts series for "How to Accept Payments" with Stripe

I found this, which implements the Laracasts series for "How to Accept Payments" from 2016: https://github.com/v-syromiatnykov/laracasts-stripe

At this point, it's VERY out of date as Stripe has changed significantly.

Is there a refresh of these lessons somewhere, ie sample code for payments with Laravel (ideally using Cashier), Vue.js and Stripe? I am looking for sample code for payments with Laravel (ideally using Cashier), Vue.js and Stripe. I found https://github.com/tnylea/laravel-cashier-examples but it doesnt come close to scratching the surface of the (old) Laracasts code.

If anyone has any sample code to share (for any of the pieces below) that would be much appreciated.

Tech Stack:

  • Laravel 7.* with Cashier back-end
  • Nuxt.js or Vue.js front-end

The functionality I have to build:

  • Checkout with Stripe elements (in Vue - or Nuxt frontend)
  • Accept Recurring Subscriptions
  • Trigger Welcome Email on subscription plan start (doesnt have to send the email, just a back-end hook is fine)
  • Cron: Invoice Email for subscription (before/after billing for SAAS)
  • Record the customer ID, Handle failed charges elegantly
  • Receive and respond to (any one) Webhook
  • Trigger Invoice Email on subscription plan start
  • Cancel subscription (and trigger email on subscription plan cancel)
  • Change subscription plan (and trigger email on subscription plan change). Like https://laracasts.com/settings/subscription/plan
  • Resume a (canceled) subscription (and trigger renewal email on subscription plan cancel)
  • Update credit card, like https://laracasts.com/settings/card/edit
  • View past Invoices / Payment History like https://laracasts.com/settings/subscription/invoices
  • Nice to have: Unit tests for everything
  • Nice to have: Pro-rate first months charges
  • Nice to have: Subscribe with / without authenticated user account?
  • Nice to have: Apply coupon code
  • Nice to have: Grace periods

Any help is welcomed. I'm trying to flatten the curve and save time so I can work on the other parts of my app.

0 likes
8 replies
connecteev's avatar

Thanks @bobbybouwmann I wasnt looking for a complete end to end solution, thats too much of an ask. Just pieces so I can flatten the curve and piece things together. I will start with the documentation and reverse engineering the old code.

That said, if you or anyone has any sample code to share (for any of the pieces above) that would be much appreciated.

Any help is welcomed. I'm trying to flatten the curve and save time so I can work on the other parts of my app.

connecteev's avatar

@bobbybouwmann I have an existing Laravel 7 app with a lot of functionality. Does using Spark mean I'd have to start frm scratch and migrate everything to Spark? Or would I copy-and-paste from Spark into my Laravel 7 app?

Also what does it cost - do you get lifetime updates for Spark by paying $99 once?

bobbybouwmann's avatar
Level 88

Normally you would start with Spark and build your app around it. You can probably drop it in as well, I don't see a problem in that.

I believe the license gives you lifetime support, but I'm not 100% sure.

I'm not saying Spark is exactly what you're looking for, but it might be a good starting point for you!

connecteev's avatar

@bobbybouwmann sounds good, thank you!

Btw Should I keep this discussion open for Jeffrey Way, since it's filed as a request?

bobbybouwmann's avatar

@connecteev If Jeffrey read this and he is gonna do a refresh of the series, it's probably already on his todo list for series ;)

1 like

Please or to participate in this conversation.