Private family social network — mobile-first app for sharing photos, chatting, and exploring your family tree.
Family-Media/
├── api/ # NestJS backend (PostgreSQL + Redis)
├── mobile/ # Expo React Native app (iOS + Android)
├── docs/ # Design docs
└── docker-compose.yml
- Node.js 20+ (LTS recommended)
- Docker Desktop
- iOS Simulator (Mac) or Android Emulator for mobile dev
docker compose up -dThis starts PostgreSQL (localhost:5432) and Redis (localhost:6379).
cp .env.example api/.env
cp mobile/.env.example mobile/.envcd api
npm install
npm run prisma:migrate:deploy
npm run start:devAPI runs at http://localhost:3000
GET /— API infoGET /health— health check (database + redis)
cd mobile
npm install
npm run startPress i for iOS simulator or a for Android emulator.
The Home tab pings GET /health and shows OK when the API and databases are up.
The app defaults to http://10.0.2.2:3000 on Android. For a physical device, set your machine's LAN IP in mobile/.env:
EXPO_PUBLIC_API_URL=http://192.168.x.x:3000
From the repo root:
| Command | Description |
|---|---|
npm run docker:up |
Start Postgres + Redis |
npm run docker:down |
Stop containers |
npm run api:dev |
Start API in watch mode |
npm run mobile:dev |
Start Expo dev server |
npm run db:migrate |
Run Prisma migrations (dev) |
npm run db:deploy |
Deploy migrations (prod/CI) |
-
docker compose upstarts Postgres + Redis -
GET /healthreturns database + redis status - Mobile Home tab shows API health
- Empty Prisma migration runs cleanly
- Phone OTP auth (
POST /auth/otp/send,POST /auth/otp/verify) — OTP stored in Redis;OTP_DEV_MODEreturnsdevOtp - Profile
GET/PATCH /users/me - Create family + invite code / QR (
POST /families, invite screen) - Admin invite by phone stub (
POST /families/:id/invites) - Join via code → pending
join_requestsvisible to admin (POST /join-requests,GET /families/:id/join-requests)
- Founding admin becomes root
personon family create - Placement onboarding (
POST /join-requests/:id/onboarding) — parent required; spouse/siblings optional; placeholders supported - Admin approve/reject (
POST /join-requests/:id/approve|reject) commits tree edges -
GET /families/:id/tree+GET /persons/:idlineage summary - Mobile Tree tab + join-request approve UI
See family_app_schema_design_a780f16f.plan.md for the full phased roadmap.
Next: Phase 3 — feed (posts, media, reactions, comments).