Documentation

SAMS Framework

A complete SaaS framework for building secure, scalable applications with Next.js.

SAMS Framework

SAMS is a production-ready SaaS framework built with Next.js 15 that provides everything you need to launch your application marketplace platform. This documentation will guide you through setting up, customizing, and deploying your own SAMS instance.

What is SAMS?

SAMS is a comprehensive SaaS framework that includes:

  • Multi-tenant Organizations: Complete organization management with role-based access
  • Application Marketplace: Built-in marketplace for application subscriptions
  • Authentication System: Multiple authentication methods including OAuth, magic links, and passkeys
  • Subscription Management: Integrated billing with multiple payment providers
  • API Framework: Secure API system with token management
  • Admin Dashboard: Complete platform administration tools

Key Features

🏢 Multi-Tenancy

  • Organization-based user management
  • Role-based permissions (Admin/Member)
  • Isolated data and billing per organization
  • Seamless organization switching

🛒 Application Marketplace

  • Application catalog with subscription tiers
  • Free trial management
  • Usage tracking and analytics
  • Automated billing integration

🔐 Authentication & Security

  • Multiple authentication providers
  • Two-factor authentication
  • Passkey support
  • Session management
  • API token security

💳 Billing & Payments

  • Multiple payment provider support (Stripe, etc.)
  • Subscription management
  • Invoice generation
  • Usage-based billing
  • Trial period handling

🎨 Modern Tech Stack

  • Frontend: Next.js 15 with App Router
  • Styling: Tailwind CSS with shadcn/ui components
  • Database: Prisma ORM with PostgreSQL
  • Authentication: Better Auth
  • API: Hono with OpenAPI
  • Deployment: Docker ready with multiple platform support

Architecture Overview

SAMS follows a modular monorepo architecture:

├── apps/
│   └── web/                 # Main Next.js application
├── packages/
│   ├── api/                 # API layer with Hono
│   ├── auth/                # Authentication system
│   ├── database/            # Database schema and client
│   ├── i18n/                # Internationalization
│   ├── payments/            # Payment provider integrations
│   └── ui/                  # Shared UI components
└── config/                  # Central configuration

Key Design Principles

  1. Type Safety: Full TypeScript coverage with runtime validation
  2. Modularity: Reusable packages for different concerns
  3. Scalability: Multi-tenant architecture from day one
  4. Security: Security-first approach with comprehensive authentication
  5. Developer Experience: Hot reload, type checking, and modern tooling

Who Should Use SAMS?

SAMS is perfect for:

  • SaaS Entrepreneurs building application marketplace platforms
  • Development Teams needing a secure, multi-tenant foundation
  • Enterprises requiring customizable SaaS infrastructure
  • Startups wanting to focus on business logic rather than boilerplate

License & Support

SAMS is a commercial framework. Your purchase includes:

  • Full source code access
  • Production deployment rights
  • 6 months of updates
  • Email support for setup and configuration
  • Deployment assistance

Getting Started

Ready to build your SaaS platform? Continue with the Setup Guide to get SAMS running locally in minutes.

Need Help?

  • 📖 Documentation: You're reading it! Browse the sections for detailed guides
  • 📧 Email Support: Contact our team for technical assistance
  • 🐛 Bug Reports: Report issues and get priority fixes
  • 💡 Feature Requests: Suggest improvements and new features

SAMS - Build secure, scalable SaaS platforms faster than ever.

SAMS Framework | Documentation | SAMS