Skip to content

Stripe integration demo in multi tenant (multiple database) SaaS application.

Notifications You must be signed in to change notification settings

tarikulwebx/stripe-integration-in-multi-tenancy

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

27 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Stripe in SaaS

This is a simple SaaS application built with Laravel and React (Inertia.js). It is a basic subscription management system that allows users to subscribe to a plan and manage their subscription.

Features

  • User Authentication
  • Subscription Management
  • Payment Gateway Integration (Stripe)
  • Admin Dashboard
  • User Management
  • Role-based Access Control
  • Email Notifications

Prerequisites

Installation

Step 1: Clone the repository

git clone https://github.com/tarikulwebx/stripe-integration-in-multi-tenancy.git

Step 2: Rename the project as 'stripe-in-saas' because we will run this application using Herd and Herd will use the project name to run the application in http://stripe-in-saas.test. It is necessary step to not run the application in http://localhost:8000. Localhost with port number will not work with stripe webhook.

Step 3: Install dependencies

composer install
npm install

Step 4: Create .env file

cp .env.example .env

Step 5: Generate key

php artisan key:generate

Step 6: Install frontend dependencies

npm install

Step 7: Migrate the database

php artisan migrate

Step 8: Seed the database

php artisan db:seed

Step 9: Run the application

composer run dev

Step 10: Visit the application

http://stripe-in-saas.test

Stripe Webhook local setup

Step 1: Go to stripe dashboard

https://dashboard.stripe.com/test

Step 2: Copy stripe publishable key and secret key in .env file

STRIPE_KEY=<the stripe publishable key>
STRIPE_SECRET=<the stripe secret key>

Step 3: Setup Stripe CLI https://docs.stripe.com/stripe-cli

Step 4: Run Stripe CLI

stripe listen --forward-to http://stripe-in-saas.test/stripe/webhook

Now, you can see the webhook events in your application.

About

Stripe integration demo in multi tenant (multiple database) SaaS application.

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages