Prerequisites
- Node.js 22 or later
- pnpm 10.15.1 (pinned in package.json)
- Supabase project (for authentication and waitlist)
Installation
Install dependencies
Install all required packages using pnpm:The Makefile detects whether pnpm is available and falls back to npm if needed. pnpm matches the CI environment.
Configure environment
Copy the environment template and fill in required variables:Generate a strong See Environment Variables for a complete reference.
FORM_TOKEN_SECRET:Never commit
.env.local to version control. It contains sensitive credentials.Set up Supabase
- Create a Supabase project at supabase.com
-
Add callback URLs to Authentication → URL Configuration:
http://localhost:3000/auth/callback(development)- Your production domain callback URL
-
Record these values in
.env.local:NEXT_PUBLIC_SUPABASE_URL- Your project URLNEXT_PUBLIC_SUPABASE_ANON_KEY- Public anon keySUPABASE_SERVICE_ROLE_KEY- Service role key (keep server-side only)
-
Run the SQL schema to create the waitlist table:
Execute
supabase/schema.sqlin the Supabase SQL editor or viapsqlto create:waitlist_requeststablewaitlist_statusenum- Indexes and RLS policies
-
Seed at least one admin user:
-
(Optional) Tag beta users with
memberrole so they can sign in without consuming guest sessions:
Run local development server
Start the Next.js development server:The app will be available at
http://localhost:3000.make dev-open waits for the server to be ready and automatically opens the browser.Useful Commands
| Command | Purpose |
|---|---|
pnpm lint | Run ESLint with Next.js rules |
pnpm test:unit | Execute Vitest unit tests |
pnpm test:e2e | Run Playwright E2E test suite |
make test | Run full test suite with required env vars |
make clean | Remove .next build output |
Operational Tips
Reset Workspace State
- Hero prompt + attachments: Stored in
sessionStoragekeyshero-initial-messageandhero-uploaded-files - Provider defaults: Stored in
localStoragekeyconfidential-provider-settings-v1 - Provider tokens: Stored in
sessionStoragekeyconfidential-provider-token
Update System Prompt
Editlib/system-prompt.ts or set NEXT_PUBLIC_DEFAULT_SYSTEM_PROMPT environment variable to override the Umbra persona.
Waitlist Status Flow
Statuses defined inlib/waitlist.ts:
requested → contacted → invited → activated → archived
Theme Customization
Tailwind tokens are centralized instyles/globals.css. Use CSS variables instead of hard-coded colors when creating new components.
Next Steps
- Environment Variables - Complete reference for all configuration
- Testing - Run and write tests
