Production-ready foundation for a mobile-first online secretary system with React + Express + Supabase + AI pipeline.
- Frontend: React (Vite), JavaScript (JSX), Tailwind, shadcn-style UI, Zustand, TanStack Query
- Backend: Node.js + Express
- Database/Auth/Storage: Supabase PostgreSQL + Auth + Storage
- AI: UzbekVoice STT/TTS + OpenAI
- Deploy: Vercel (frontend) + Render/Railway (backend) + Supabase
frontend/: responsive admin web appbackend/: secure API + scheduler jobssupabase/schema.sql: DB schema + RLS policies
- Install dependencies:
npm install- Configure env files:
- Copy
backend/.env.example->backend/.env - Copy
frontend/.env.example->frontend/.env
- Apply Supabase SQL:
- Run
supabase/schema.sqlin Supabase SQL Editor - Create storage bucket:
reminder-audio
- Start both apps:
npm run dev- Frontend:
http://localhost:5173 - Backend:
http://localhost:8080
PORTAPP_ORIGINCORS_ORIGINSSUPABASE_URLSUPABASE_ANON_KEYSUPABASE_SERVICE_ROLE_KEYOPENAI_API_KEYOPENAI_MODELUZBEKVOICE_STT_URLUZBEKVOICE_STT_API_KEYUZBEKVOICE_TTS_URLUZBEKVOICE_TTS_API_KEYTELEGRAM_BOT_TOKEN
VITE_API_BASE_URLVITE_SUPABASE_URLVITE_SUPABASE_ANON_KEY
Every endpoint returns:
{
"success": true,
"data": {},
"message": ""
}- Auth/profile/settings
- Secretary pipeline (text + voice)
- Reminders (pre-generated TTS audio URL)
- Meetings (+auto-message job queue)
- Clients
- Expenses
- Dashboard analytics + AI recommendation text
- Admin overview
- Cron job processor (
system_jobs)
- No hardcoded URLs. Use env vars only.
- Scheduler is backend-only (never frontend).
- Configure CORS allowlist via
CORS_ORIGINS. - Frontend can deploy to Vercel directly from
frontend/. - Backend can deploy to Render/Railway from
backend/with start command:
npm start- Add Redis-backed queues (BullMQ) for high job volume
- Add retry dead-letter table for failed jobs
- Add Sentry/Logtail for central logging
- Add stricter zod schemas for settings/prompt management
- Add e2e tests for scheduler and reminder cadence correctness
- Add signed URL strategy if audio should not be public