BoilerPrompt
Windsurf

Windsurf prompt to build a SaaS starter app

Point Windsurf at an empty folder and this spec walks Cascade through auth, teams, roles, and billing stubs in a single flow, including the invite and session edge cases most scaffolds skip. It finishes by running the migration and booting the app, so you know the starter actually starts.

Last updated

Prompt
Scaffold a SaaS starter app in a new project: {{language}} on the backend, {{database}} for persistence, and {{addon}} wired in from the start. Core pieces: email-plus-password auth with session cookies, an organizations table so every user belongs to a team, role checks (owner, member) enforced in middleware, and a billing page stubbed with plan tiers read from config. Routes: /signup, /login, /app (protected shell), /app/settings, /app/team with an invite-by-email flow that stores pending invites. Handle the ugly cases: invite accepted by an existing account, last owner trying to leave a team, and expired sessions redirecting back to the original URL after login. Generate migrations, a .env.example listing every required variable, and a README section on first-run setup. Run the migration and boot the app in the terminal to prove it starts clean, then summarize the folder structure you created.

Customize it

Runs in your browser. Nothing you type here is sent anywhere.

Your customized prompt
Scaffold a SaaS starter app in a new project: TypeScript on the backend, PostgreSQL for persistence, and input validation wired in from the start. Core pieces: email-plus-password auth with session cookies, an organizations table so every user belongs to a team, role checks (owner, member) enforced in middleware, and a billing page stubbed with plan tiers read from config. Routes: /signup, /login, /app (protected shell), /app/settings, /app/team with an invite-by-email flow that stores pending invites. Handle the ugly cases: invite accepted by an existing account, last owner trying to leave a team, and expired sessions redirecting back to the original URL after login. Generate migrations, a .env.example listing every required variable, and a README section on first-run setup. Run the migration and boot the app in the terminal to prove it starts clean, then summarize the folder structure you created.

Same task in other tools

Questions about this prompt

Should I have Cascade wire real payments in the first pass?

No. Land the scaffold with the stubbed plan config, boot it, and commit. Then run a second flow connecting the stub to your payment provider using test keys from .env.example. Separating the two makes it obvious whether a failure is scaffold or billing.

The scaffold stalled partway through. How do I resume without duplicates?

Reply in the same conversation with 'continue from the last completed step, re-list what remains before writing'. Cascade re-reads the files it already created, so it continues rather than regenerating, and the re-listed plan lets you spot anything it forgot.

How do I keep later features consistent with these starter conventions?

Capture the decisions in a Windsurf rules file: session-cookie auth, the owner and member roles, migration naming, where routes live. Cascade loads rules on every flow, so future prompts can stay short while still following the starter's structure.

Related prompts