Setup & Connection

Project connection, client layers, and environment.

Creative Hub uses a dedicated Supabase project. All data lives in hub_* tables with Row Level Security enabled.

Project

ItemDetail
Project ref
Dashboard
Storage bucket

Client layers

FileUsed by
lib/supabase/client.tsBrowser — auth UI, realtime, client mutations
lib/supabase/server.tsServer Components & Server Actions
lib/supabase/middleware.tsSession refresh on every request
lib/supabase/admin.tsService role — dev bypass, admin invites

Connection

env
NEXT_PUBLIC_SUPABASE_URL=https://rnyeonvbnrwephpviyzu.supabase.co
NEXT_PUBLIC_SUPABASE_ANON_KEY=your_anon_key
SUPABASE_SERVICE_ROLE_KEY=your_service_role_key