DEVFLOW

Reference

Prompt Templates

Prompts for feature design and recording a completed manual deployment after SQL Steward is installed.

Design a new database feature

We need private user-owned documents with optional public publishing.

Read `AGENTS.md` and `supabase/README-db-workflow.md` first. Before writing
SQL, establish the actors, ownership, public visibility, deletion behavior,
sensitive fields, expected reads/writes, and whether existing production data
exists.

Then prepare a new migration file, RLS/grant design, pre-apply checks,
post-apply verification SQL, API-path authorization tests, concurrency/risk
analysis, and manual Supabase SQL Editor instructions.

Do not apply hosted SQL. I will apply reviewed SQL manually.

Record a manual deployment

I manually applied the committed migration
`supabase/migrations/YYYYMMDDHHMMSS_description.sql` to the production
Supabase project and completed the provided verification.

Read the database protocol and create the required deployment record under
`supabase/deployments/production/`. Include the migration Git revision,
checksum, UTC application time, verification performed and observed result.
Do not apply or modify database SQL.