- Add Express.js server with TypeScript - Configure Prisma ORM with PostgreSQL schema - Implement JWT authentication (register, login, logout, refresh) - Add rate limiting for auth endpoints (10 attempts/15min) - Password strength validation (8+ chars, uppercase, lowercase, number) - Events CRUD API (anniversaries and reminders) - Notes API (single note per user) - AI parse endpoint with DeepSeek integration - Security: Helmet, rate limiting, input validation, error handling - Fix: JWT_SECRET environment variable validation Code review: Architect approved Tests: Build verified
19 lines
455 B
Bash
19 lines
455 B
Bash
# Server
|
|
PORT=3000
|
|
NODE_ENV=development
|
|
|
|
# JWT
|
|
JWT_SECRET=dev-secret-key-do-not-use-in-production
|
|
JWT_EXPIRES_IN=7d
|
|
JWT_REFRESH_EXPIRES_IN=30d
|
|
|
|
# Database (PostgreSQL - update with your local or Tencent Cloud credentials)
|
|
DATABASE_URL=postgresql://qia_admin:your-password@postgres.ap-shanghai.myqcloud.com:5432/qia
|
|
|
|
# DeepSeek AI
|
|
DEEPSEEK_API_KEY=sk-xxx
|
|
DEEPSEEK_API_URL=https://api.deepseek.com/chat/completions
|
|
|
|
# CORS
|
|
CORS_ORIGIN=http://localhost:5173
|