iamsrikanthnani / saas-app

Seamlessly integrated webhooks with Stripe and Clerk for streamlined functionality. Plug and play, ready for you to build upon, enhanced with shard.cn components. Built with Next.js 14, Clerk, MongoDB, and Stripe for effortless development. πŸš€

Home Page:https://saas-app.srikanthnani.com/

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

πŸš€ SaaS Boilerplate

This is a robust boilerplate solution crafted with Next.js 14, Clerk, MongoDB, and Stripe, seamlessly integrated with webhooks for enhanced functionality. Ideal for building SaaS applications with ease. πŸš€

Login Pricing

πŸ› οΈ Getting Started

Step 1: Clone the repository

git clone https://github.com/iamsrikanthnani/saas-app.git

Step 2: Navigate into the project directory

cd saas-app

Step 3: Install dependencies

npm install

Step 4: Set up environment variables

cp .env.example .env

Fill in the following environment variables:

  • NEXT_PUBLIC_CLERK_PUBLISHABLE_KEY: Your Clerk Publishable Key. Get this from clerk dashboard.
  • CLERK_SECRET_KEY: Your Clerk Secret Key. Get this from clerk dashboard.
  • MONGODB_HOST: Your MongoDB host URL.

Step 5: Set up Clerk webhooks

  • Go to the clerk dashboard and on the sidebar click on webhooks, and click add endpoint.
  • Enable the following webhook events: user.created, user.deleted, user.updated.
  • Set the Endpoint URL as: https://[your-deployed-url]/api/webhooks/user.
  • copy Signing Secret from Webhooks and paste it in env => CLERK_WEBHOOK_SECRET.
  • still not working? checkout Webhook docs

Step 6: Set up Stripe webhooks

  • Go to the sripe dashboard and click on webhooks, and click add an endpoint.
  • Enable the following webhook event: checkout.session.completed.
  • Set the Endpoint URL as: https://[your-deployed-url]/api/webhooks/stripe.
  • copy Signing Secret from Webhooks and paste it in env => STRIPE_WEBHOOK_SECRET.
  • still not working? checkout Webhook docs

πŸš€ Run

npm run dev

This will start the development server. at localhost:3000

🀝 Contributing

Contributions are welcome! Feel free to open an issue or submit a pull request.

πŸ“„ License

This project is licensed under the MIT License.

πŸŽ‰ Happy Coding!

Thank you for checking out the SaaS Boilerplate! I hope this boilerplate helps you kickstart your SaaS projects. If you have any questions or suggestions, feel free to open an issue or submit a pull request.

Buy Me A Coffee

Don't forget to visit my portfolio for more projects and updates!

πŸš€ Keep coding and building amazing things!

About

Seamlessly integrated webhooks with Stripe and Clerk for streamlined functionality. Plug and play, ready for you to build upon, enhanced with shard.cn components. Built with Next.js 14, Clerk, MongoDB, and Stripe for effortless development. πŸš€

https://saas-app.srikanthnani.com/


Languages

Language:TypeScript 96.0%Language:CSS 3.6%Language:JavaScript 0.4%