How sushmitadasari/application-tracking-system-api- works
This is an ATS backend for candidates and company staff. Candidates register or log in, browse jobs, and submit applications; recruiters manage jobs, while recruiters and hiring managers review applications and advance their stages. The API enforces JWT authentication and role checks, validates stage transitions, and records audit history. Notifications are queued for a separate worker, which writes mock email messages to a log. The API excerpt is partial; documented capabilities and relationships are included where supported by the README or source index.
Main entry points: index.ts ATS API routes · data-source.ts TypeORM datasource · Application.ts Application model · Job.ts Job model
Components 19
API and access
- ATS API routes
src/index.ts - JWT authentication
src/middleware/auth.ts - Role authorization
src/middleware/rbac.ts
Hiring workflow
- Job management
src/index.ts - Application handling
src/index.ts - Stage transitions
src/services/stateMachine.ts - Stage audit history
src/entities/ApplicationHistory.ts
Persistence
- Company model
src/entities/Company.ts - User model
src/entities/User.ts - Job model
src/entities/Job.ts - Application model
src/entities/Application.ts - TypeORM datasource
src/config/data-source.ts - PostgreSQL
Notifications
- Notification queue
src/queue/notifications.ts - Redis
- Notification worker
src/worker.ts - Mock email log
src/queue/notifications.ts
Other components
- Candidate
- Recruiter / manager
Connections 25
- Candidate → ATS API routes: uses API
README.md - Recruiter / manager → ATS API routes: uses API
README.md - ATS API routes → JWT authentication: authenticates requests
src/index.ts - ATS API routes → Role authorization: guards routes
src/index.ts - ATS API routes → Job management: routes job actions
README.md - ATS API routes → Application handling: routes applications
README.md - Application handling → Stage transitions: validates stages
README.md - Application handling → Stage audit history: records changes
README.md - ATS API routes → TypeORM datasource: uses datasource
src/index.ts - TypeORM datasource → Company model: registers entity
src/config/data-source.ts - TypeORM datasource → User model: registers entity
src/config/data-source.ts - TypeORM datasource → Job model: registers entity
src/config/data-source.ts - TypeORM datasource → Application model: registers entity
src/config/data-source.ts - TypeORM datasource → Stage audit history: registers entity
src/config/data-source.ts - TypeORM datasource → PostgreSQL: connects to
src/config/data-source.ts - Application model → Job model: references job
src/entities/Application.ts - Application model → User model: references candidate
src/entities/Application.ts - Application model → Stage audit history: has history
src/entities/Application.ts - Job model → Company model: belongs to company
src/entities/Job.ts - Job model → User model: records creator
src/entities/Job.ts - User model → Company model: belongs to company
src/entities/User.ts - Notification queue → Redis: uses queue store
README.md - ATS API routes → Notification queue: enqueues notifications
src/index.ts - Notification worker → Notification queue: starts processor
src/worker.ts - Notification queue → Mock email log: appends messages
src/queue/notifications.ts