3 Commits

Author SHA1 Message Date
9e96ecc231 feat(app): wire up Express app factory and production entry point (Task 13)
Initializes DB, creates default admin user, connects brokers/PG sources,
starts query timers, and serves frontend/dist as SPA.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-04-06 12:56:43 +02:00
44f4b6d010 feat(api): add all REST route handlers and display-api test (Task 12)
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-04-06 12:56:35 +02:00
f7d16c077e feat(middleware): add JWT auth module with bcryptjs login and protected routes
- src/api/middleware/auth.ts: signToken, verifyToken, authMiddleware (Bearer JWT, 24h expiry)
- src/api/routes/auth.ts: POST /api/auth/login (bcryptjs verify) and GET /api/auth/me (protected)
- src/index.ts: mount auth router at /api/auth
- tests/api/auth.test.ts: 7 tests covering login success, wrong password, no token, invalid token, valid access
- Using bcryptjs (pure JS) instead of bcrypt (requires Visual Studio on Windows)

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-04-06 12:46:50 +02:00