SiteVPN is a privacy SaaS that combines private browsing, disposable email, anonymous temporary phone numbers, AI-assisted privacy intelligence, subscriptions, and a Business developer API in one account.
The app is built as a Next.js App Router product with Prisma/PostgreSQL, NextAuth, Stripe subscriptions, Claude-powered AI features, and API-key protected REST endpoints.
- Unified privacy dashboard for VPN, temp email, temp number, account, upgrade, and developer API access
- Auth with email/password and Google OAuth
- Plans: Free, Pro, and Business
- Stripe Checkout and webhook-based plan updates
- Usage limits by plan with daily usage tracking
- Smart VPN server recommendations
- Temp email classification: safe, promotional, phishing, OTP
- OTP extraction from email and SMS
- Pro AI email reply drafts
- Business API keys for reseller/integration use cases
- Signed webhooks for email, SMS, and VPN events
- SEO landing pages for free temp email, temporary phone number, and free VPN no logs
SiteVPN-sitevpn/
src/ Next.js SaaS app
server/ NestJS service scaffold for backend/mail experiments
Most product work currently lives in src/.
- Next.js 16 App Router
- React 19
- Tailwind CSS
- NextAuth.js
- Prisma ORM
- PostgreSQL / Supabase
- Stripe
- Claude API via Anthropic
- TypeScript
/- conversion landing page/signup- redirects to auth/auth/sign-in- sign in / register/dashboard- unified privacy dashboard/dashboard/api-keys- Business API key and webhook management/docs- developer API docs and live tester/tools/temp-email- SEO page for free temp email/tools/temp-number- SEO page for temporary phone number/tools/vpn- SEO page for free VPN no logs
All /api/v1/* routes require:
Authorization: Bearer svpn_your_api_keyEndpoints:
GET /api/v1/email/createGET /api/v1/email/:id/messagesPOST /api/v1/number/requestGET /api/v1/number/:id/smsGET /api/v1/vpn/serversPOST /api/v1/vpn/connect
Create src/.env.local from src/.env.example.
Required for production:
DATABASE_URL=""
NEXTAUTH_URL=""
NEXTAUTH_SECRET=""
GOOGLE_CLIENT_ID=""
GOOGLE_CLIENT_SECRET=""
STRIPE_SECRET_KEY=""
STRIPE_WEBHOOK_SECRET=""
STRIPE_PRO_PRICE_ID=""
STRIPE_BUSINESS_PRICE_ID=""
ANTHROPIC_API_KEY=""
CRON_SECRET=""Notes:
NEXTAUTH_URLshould be your deployed Vercel URL or production domain.NEXTAUTH_SECRETmust be a strong random value.DATABASE_URLshould point to Supabase/PostgreSQL.ANTHROPIC_API_KEYenables Claude. Without it, local deterministic AI fallbacks are used.
cd src
npm install
npm run prisma:generate
npm run devOpen:
http://localhost:3000
Generate Prisma Client:
cd src
npm run prisma:generateCreate/apply database migrations:
npm run prisma:migrateImportant: the schema includes tables for users, usage logs, API keys, and webhook endpoints. Make sure migrations are applied to Supabase before deploying, otherwise runtime API routes that touch those tables will fail.
Create Stripe products/prices:
- Free: no charge
- Pro:
$9/month - Business:
$29/month
The helper script can create products and recurring prices:
cd src
STRIPE_SECRET_KEY=sk_test_xxx npm run stripe:setup-productsCopy the generated Pro and Business price IDs into:
STRIPE_PRO_PRICE_ID=""
STRIPE_BUSINESS_PRICE_ID=""Configure Stripe webhooks to call:
https://your-domain.com/api/stripe/webhook
Listen for:
checkout.session.completedcustomer.subscription.createdcustomer.subscription.updatedcustomer.subscription.deleted
Business users can register a webhook URL at:
/dashboard/api-keys
SiteVPN signs webhook payloads with:
X-SiteVPN-Signature: sha256=<hmac>Verify using the webhook secret shown once at registration.
Events currently emitted by the API prototype:
email.createdemail.receivedsms.receivedvpn.connected
Deploy the src/ directory as the Next.js project root.
Recommended build command:
npm run buildMake sure all production environment variables are set in Vercel.
The server/ folder contains a NestJS backend scaffold. If you deploy it separately on Render, configure its own environment variables and service commands from server/package.json.
Current checks used before handoff:
cd src
npx tsc --noEmit
npm run buildBoth should pass before pushing.
Before real users:
- Apply Prisma migrations to Supabase.
- Add timeout/queueing around customer webhook delivery.
- Wrap Claude JSON parsing in a defensive
try/catch. - Replace mock email/SMS/VPN data with production providers.
- Connect daily usage alerts to an email provider.
- Configure real status, privacy, terms, and blog pages or redirects.
Add your preferred license before public release.