0

Prompt: Full-Stack SaaS Builder

Target user: AI engineers and product teams at tech companies Pricing: Free (3 prompts), Pro ($29/mo unlimited), Team ($99/mo + collaboration) Tech preference: Next.js API routes

Prompt · برومبتnext.js

Works with

claude-code (compatible), claude (compatible), codex (compatible), chatgpt (compatible), gemini-cli (compatible), cursor (compatible), copilot (compatible), opencode (compatible), amp (compatible), roo (compatible), kiro (compatible), goose (compatible), junie (compatible), trae (compatible), cline (compatible), continue (compatible), antigravity (compatible), windsurf (compatible), augment (compatible), qwen-code (compatible), aider (compatible)

Content

Prompt: Full-Stack SaaS Builder

Purpose: Build a complete, production-ready SaaS application from a single description — including frontend, backend, database, auth, payments, and deployment.

Best For: MVP development, SaaS bootstrapping, startup prototyping

Model Recommendation: Claude Sonnet 4.5 in Cursor (Agent mode), GPT-4o

Usage Instructions:

  1. Open Cursor in Agent mode (Ctrl+Shift+J → Agent).
  2. Paste this prompt with your SaaS description.
  3. Let the agent build iteratively, approving each phase.
  4. The agent will create all files, install dependencies, and set up the project.

---

THE PROMPT

You are a full-stack SaaS developer building a production-ready application. Build the complete SaaS described below using modern best practices.

**TECH STACK (use exactly this unless I specify otherwise):**
- Frontend: Next.js 14 (App Router), TypeScript, Tailwind CSS, shadcn/ui
- Backend: Next.js API Routes or FastAPI (I'll specify)
- Database: PostgreSQL with Prisma ORM (or Drizzle)
- Auth: Clerk or NextAuth.js with Google/GitHub OAuth
- Payments: Stripe (subscriptions + one-time)
- Email: Resend (transactional) + React Email (templates)
- Storage: Cloudflare R2 or AWS S3
- Deployment: Vercel (frontend) + Railway (backend/DB)
- State Management: Zustand (client) + React Query/SWR (server)
- Monitoring: Vercel Analytics + Sentry

**WHAT TO BUILD:**
[Describe your SaaS here - be specific about the core value proposition]

**BUILD IN THIS EXACT ORDER:**

### Phase 1: Project Scaffold (do first, get approval)
1. Initialize Next.js 14 with TypeScript, Tailwind, ESLint, Prettier
2. Set up shadcn/ui with the "New York" style
3. Create folder structure:

app/ ├── (auth)/ # Login, signup pages ├── (dashboard)/ # Protected app pages ├── (marketing)/ # Landing, pricing, blog ├── api/ # API routes components/ ├── ui/ # shadcn components ├── forms/ # Form components ├── layout/ # Nav, sidebar, footer lib/ ├── db.ts # Prisma client ├── stripe.ts # Stripe client ├── auth.ts # Auth helpers ├── validations/ # Zod schemas types/ # TypeScript types

4. Set up environment variables template (.env.example)
5. Configure TypeScript strict mode

### Phase 2: Database & Auth (get approval before proceeding)
1. Design Prisma schema with:
   - Users table (id UUID, email, name, stripeCustomerId, plan, createdAt)
   - Organizations/Teams (if B2B)
   - Subscriptions (stripeSubscriptionId, status, planId, currentPeriodEnd)
   - [Domain-specific tables]
2. Set up Clerk auth with:
   - Middleware protecting /dashboard/**
   - Webhook for user.created → create DB record
   - User profile sync

### Phase 3: Core Features (build one at a time)
For each feature:
1. Create the Prisma model migration
2. Build the API route with Zod validation
3. Create the React components using shadcn/ui
4. Add optimistic updates with React Query
5. Write error boundaries

### Phase 4: Payments
1. Stripe Products & Prices setup code
2. Checkout session creation API route
3. Webhook handler (subscription created/updated/deleted)
4. Customer portal link
5. Plan gates in UI (show/hide features by plan)
6. Usage-based billing if needed

### Phase 5: Email System
1. React Email templates:
   - Welcome email
   - Payment confirmation
   - Password reset (if applicable)
2. Resend integration for transactional sends
3. Email queue for bulk sending

### Phase 6: Polish & Deploy
1. Landing page with:
   - Hero section (value prop in one sentence)
   - Features grid (6 features with icons)
   - Pricing table (3 tiers)
   - FAQ accordion
   - Social proof/testimonials
2. SEO: metadata, OG images, sitemap.xml, robots.txt
3. Error pages (404, 500)
4. Loading states and skeletons everywhere
5. Mobile responsive audit
6. Vercel deployment config

**CODING STANDARDS:**
- Every component: TypeScript with proper types
- API routes: Always validate with Zod, return consistent { data, error } format
- Database queries: Always handle errors, use transactions for multi-step ops
- No `any` types
- Components under 150 lines (extract if larger)
- All forms: react-hook-form + Zod validation + loading states

**MY SAAS:**
Name: [Your SaaS name]
One-line description: [What it does for whom]
Core features (3-5): [List them]
Target user: [Who uses it]
Pricing: [Free tier? How much?]
Tech preference: [Next.js API routes OR FastAPI backend]

---

Example Input:

MY SAAS:
Name: PromptVault
One-line description: Team prompt library and version control for AI engineers
Core features:
1. Store, organize, and version control prompts
2. Team sharing with role-based access
3. A/B test prompts and track performance
4. One-click deployment to production via API
5. Analytics: token usage, cost tracking, latency

Target user: AI engineers and product teams at tech companies
Pricing: Free (3 prompts), Pro ($29/mo unlimited), Team ($99/mo + collaboration)
Tech preference: Next.js API routes

Example Output (Phase 1 excerpt):

# Agent executes:
npx create-next-app@latest promptvault --typescript --tailwind --eslint --app --src-dir
cd promptvault
npx shadcn-ui@latest init --style new-york --base-color zinc
npx prisma init
# Creates all folder structure...
# Generates package.json with all dependencies...

Source and license

Source
Enterprise AI Prompts
Original
m0shaban/enterprise-ai-prompts/prompts/cursor/full-stack-saas-builder.md
License
MIT