How ajayreddy510/hrone-attendance-api works
This is a FastAPI employee attendance and analytics service backed by MongoDB. Its main workflow manages employees, records and corrects attendance, then exposes attendance and workforce analytics. The implementation is concentrated in app/main.py, so the graph separates its documented route and domain responsibilities while retaining that shared source path. README documentation supports the broader endpoint and analytics coverage; the excerpts show selected database operations and analytics pipeline details, not every route implementation.
Main entry points: main.py Punch-in
Components 15
API and administration
- Query explain
app/main.py - Health check
app/main.py
Employee management
- Employee routes
app/main.py - Employees collection
Attendance lifecycle
- Punch-in
app/main.py - Punch-out
app/main.py - Attendance listing
app/main.py - Manual regularization
app/main.py - Attendance logs
Analytics
- Monthly summary
app/main.py - Department summary
app/main.py - Late leaderboard
app/main.py - Department trend
app/main.py
Other components
- API client
- MongoDB server
Connections 30
- API client → Employee routes: creates or lists
README.md - Employee routes → Employees collection: reads and writes
app/main.py - API client → Punch-in: punches in
README.md - Punch-in → Employees collection: checks employee
README.md - Punch-in → Attendance logs: creates record
README.md - API client → Punch-out: punches out
README.md - Punch-out → Employees collection: loads employee
app/main.py - Punch-out → Attendance logs: updates record
app/main.py - API client → Attendance listing: lists records
README.md - Attendance listing → Attendance logs: reads records
README.md - API client → Manual regularization: corrects record
README.md - Manual regularization → Attendance logs: updates with history
README.md - API client → Monthly summary: requests summary
README.md - Monthly summary → Employees collection: uses employee data
README.md - Monthly summary → Attendance logs: aggregates attendance
README.md - API client → Department summary: requests metrics
README.md - Department summary → Employees collection: includes headcount
README.md - Department summary → Attendance logs: aggregates logs
README.md - API client → Late leaderboard: requests ranking
README.md - Late leaderboard → Attendance logs: ranks late records
README.md - Late leaderboard → Employees collection: adds employee details
README.md - API client → Department trend: requests trend
README.md - Department trend → Employees collection: checks department
app/main.py - Department trend → Attendance logs: fills daily series
README.md - API client → Query explain: requests plan
README.md - Query explain → MongoDB server: explains query
README.md - API client → Health check: checks readiness
README.md - Health check → MongoDB server: pings server
app/main.py - Employees collection → MongoDB server: stored in
README.md - Attendance logs → MongoDB server: stored in
README.md