Multi-Tenancy with Laravel Spark
What I am trying to do:
Im trying to add laravel spark on top of multi-tenancy teams.
What I did so far:
Installed laravel spark and followed this guide: https://spark.laravel.com/docs/spark-stripe/cookbook.html#team-billing
and installed the "filament/spark-billing-provider"
to my panel. What is the issue: My Multi-Tenancy (team selector) now has the "Manage Subscription" option an it links to: http://127.0.0.1:8000/app/billing/team/2 It opens the spark billing portal correctly and shows "Managing billing for Test Team." so it seems to work correctly. However when I get redirected back from the stripe payment it lands on url: http://127.0.0.1:8000/app/billing?checkout=subscription_started Which resulted in 404 error. If I manualy add "/team/2" to the url everything works as expected. http://127.0.0.1:8000/app/billing/team/2?checkout=subscription_started So my question is: How can I manipulate the url from the stripe success redirect?
to my panel. What is the issue: My Multi-Tenancy (team selector) now has the "Manage Subscription" option an it links to: http://127.0.0.1:8000/app/billing/team/2 It opens the spark billing portal correctly and shows "Managing billing for Test Team." so it seems to work correctly. However when I get redirected back from the stripe payment it lands on url: http://127.0.0.1:8000/app/billing?checkout=subscription_started Which resulted in 404 error. If I manualy add "/team/2" to the url everything works as expected. http://127.0.0.1:8000/app/billing/team/2?checkout=subscription_started So my question is: How can I manipulate the url from the stripe success redirect?
Cookbook | Laravel Spark
A perfect starting point for your next great idea.
Solution:Jump to solution
Redirect is fixed in Spark release v4.2.11. Thank you @Nathan for reaching out to the Laravel Spark team.
3 Replies
Hi @Pede I am trying to setup as well, but i get a blank page when trying to access the "manage subscription" (https://github.com/filamentphp/filament/discussions/10099)
Would you be able to share your SparkServiceProvider?
GitHub
Blank page when accessing manage subscription · filamentphp filamen...
I am setting up Spark with https://filamentphp.com/docs/3.x/panels/tenancy#using-laravel-spark and following https://spark.laravel.com/docs/spark-stripe/cookbook.html for team billables When i clic...
I was hopeing for some help 🥲 But sure here you go:
Solution
Redirect is fixed in Spark release v4.2.11. Thank you @Nathan for reaching out to the Laravel Spark team.