How zendacross97/ai-interview-coach works
AI Interview Coach serves candidates through account and payment flows into resume-backed, real-time AI interviews, then stores completed transcripts and scorecards for review. The map follows documented capabilities and the sampled controller, WebSocket, service, and model calls. Some routes and integrations are represented from README or index references; unsampled implementation details and their wiring are not inferred.
Main entry points: interviewService.js Session & scorecards · interviewController.js Interview APIs · handler.js Live interview handler · resumeService.js Resume ingestion
Components 26
Accounts & access
- HTTP server
app.js - Account routes
routes/userRoutes.js - Account workflows
controllers/userController.js - JWT authentication
middlewares/auth.js - Payment routes
routes/paymentRoute.js - Payment workflow
controllers/paymentController.js
Interview experience
- Interview routes
routes/interviewRoute.js - Interview APIs
controllers/interviewController.js - WebSocket gateway
ws/index.js - Socket authentication
ws/middleware.js - Live interview handler
ws/handler.js - Interview client
public/js/interview.js
Domain services
- User service
services/userServices.js - Resume ingestion
services/resumeService.js - Session & scorecards
services/interviewService.js - Active-session cache
services/redisService.js - Session cleanup
cron/sessionCleanup.js
Persistence & state
- User records
model/user.js - Resume records
model/resume.js - Interview records
model/interview.js
External integrations
- Cashfree service
services/cashfreeService.js - S3 file service
services/awsServices.js - Gemini AI service
services/geminiService.js - Redis
- Brevo email service
services/brevoService.js
Other components
- Candidate
Connections 38
- Candidate → HTTP server: uses
README.md - HTTP server → Account routes: mounts
app.js - HTTP server → Payment routes: mounts
app.js - HTTP server → Interview routes: mounts
app.js - Account routes → Account workflows: dispatches
routes/userRoutes.js - Account routes → JWT authentication: protects
routes/userRoutes.js - Account workflows → User service: calls
controllers/userController.js - Account workflows → Brevo email service: sends reset email
controllers/userController.js - User service → User records: reads and writes
services/userServices.js - JWT authentication → User records: loads user
middlewares/auth.js - Payment routes → Payment workflow: dispatches
routes/paymentRoute.js - Payment routes → JWT authentication: protects
routes/paymentRoute.js - Payment workflow → Cashfree service: creates and checks orders
controllers/paymentController.js - Payment workflow → User service: updates order
controllers/paymentController.js - Interview routes → Interview APIs: dispatches
routes/interviewRoute.js - Interview routes → JWT authentication: protects
routes/interviewRoute.js - Interview APIs → Resume ingestion: checks and saves resume
controllers/interviewController.js - Interview APIs → S3 file service: requests upload URL
controllers/interviewController.js - Interview APIs → Session & scorecards: queries and finalizes
controllers/interviewController.js - Interview APIs → Active-session cache: checks active session
controllers/interviewController.js - Resume ingestion → S3 file service: downloads resume
services/resumeService.js - Resume ingestion → Gemini AI service: parses resume
services/resumeService.js - Resume ingestion → Resume records: reads and updates
services/resumeService.js - WebSocket gateway → Socket authentication: authenticates
ws/index.js - WebSocket gateway → Live interview handler: dispatches
ws/index.js - Socket authentication → User records: loads user
ws/middleware.js - Socket authentication → Interview records: checks session
ws/middleware.js - Socket authentication → Active-session cache: checks session state
ws/middleware.js - Interview client → WebSocket gateway: opens live interview
- Live interview handler → Resume ingestion: loads resume context
ws/handler.js - Live interview handler → Session & scorecards: manages session
ws/handler.js - Live interview handler → Gemini AI service: streams interview
ws/handler.js - Live interview handler → Active-session cache: tracks active session
ws/handler.js - Session & scorecards → Interview records: stores transcript and scores
services/interviewService.js - Session & scorecards → Active-session cache: sets and clears session key
services/interviewService.js - Session & scorecards → Gemini AI service: generates scorecard
services/interviewService.js - Active-session cache → Redis: reads and writes keys
services/redisService.js - Session cleanup → Session & scorecards: cleans stale sessions
cron/sessionCleanup.js