Live setup
Connect one service at a time
Nothing is saved until live services are configured. Production never uses test mode, and an incomplete live setup does not fall back to test data.
1. Neon PostgreSQL — needed
Create a Neon project and set DATABASE_URL to the pooled connection string. Then run npm run db:migrate. The command records applied files and can be run again. If an older run already created the tables, the next run records that first file instead of creating the tables twice.
2. Clerk — needed
Create a Clerk development instance and require verified emails. Set NEXT_PUBLIC_CLERK_PUBLISHABLE_KEY and CLERK_SECRET_KEY. @clerk/nextjs is already installed. The first signed-in person with a verified email who enters the setup code becomes owner of a new workspace. It cannot be used to join an existing one, and it works once. Later people need an invite from that owner.
3. Cloudflare R2 — needed
Create a private R2 bucket with public access disabled. Set R2_ACCOUNT_ID, R2_BUCKET, R2_ACCESS_KEY_ID, and R2_SECRET_ACCESS_KEY. Uploads stay capped at 4 MB until a direct upload to that bucket is built.
4. OpenAI — needed
Set OPENAI_API_KEY. Live imports use OpenAI. Test mode keeps using the local reader.
5. Setup code — needed
Set BOOTSTRAP_TOKEN to a random value of at least 32 characters. Leave it blank in test mode. Live mode stays closed until it is long enough, and the value is not written to logs.
Start with Neon PostgreSQL.
Back to the Phase 0 demo