You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
A full-stack web application to help users prepare for technical interviews using AI-powered question generation, timed practice sessions, and personalized session management.
Note: This project is under active development. Some features may be in progress or subject to change.
Login/Register → server sets two HTTPOnly cookies: accessToken (15 min) and refreshToken (7 days)
Requests — axios sends cookies automatically (withCredentials: true); non-GET requests include an x-csrf-token header
Token Refresh — on 401 response, axios interceptor calls POST /api/auth/refresh; if refresh fails, redirects to /
Logout — server clears both cookies; frontend clears user context
Environment Variables
Backend (.env)
Variable
Default
Required
NODE_ENV
development
—
PORT
5000
—
MONGO_DB_URI
—
✅
ALLOWED_ORIGINS
http://localhost:5173
—
JWT_SECRET
—
✅
JWT_REFRESH_SECRET
(fallback set)
Recommended
GOOGLE_API_KEY
—
✅
GOOGLE_AI_MODEL
—
✅
CLOUDINARY_CLOUD_NAME
""
For image uploads
CLOUDINARY_API_KEY
""
For image uploads
CLOUDINARY_API_SECRET
""
For image uploads
IS_PROD
false
—
Frontend (.env.local)
Variable
Purpose
VITE_BASE_URL
Backend API base URL (e.g. http://localhost:5000)
Setup & Run
Backend
cd backend
npm install
npm run dev # starts on http://localhost:5000
Frontend
cd frontend
npm install
npm run dev # starts on http://localhost:5173
Other scripts
npm run build # production build
npm run type-check # TypeScript check (backend)
npm run lint # ESLint
npm run format # Prettier
About
A full-stack web app to help users prepare for technical interviews using AI-powered question generation, practice sessions, and user session management. This repository contains a TypeScript/Node backend and a React + Vite frontend.