# cristalynllarenas19-oss/mobile-face-verification-and-geotagged-attendance-with-leave-management-system architecture

> Architecture diagram of the GitHub repository cristalynllarenas19-oss/mobile-face-verification-and-geotagged-attendance-with-leave-management-system, generated by GitDiagram from its file tree, README and a sample of source files (last updated 2026-11-13). It is an AI-made overview: check details against the source.

- Interactive diagram: https://gitdiagram.com/cristalynllarenas19-oss/mobile-face-verification-and-geotagged-attendance-with-leave-management-system
- Repository: https://github.com/cristalynllarenas19-oss/mobile-face-verification-and-geotagged-attendance-with-leave-management-system

## Overview

This is a mobile face-verification and geotagged attendance system with employee self-service and an administrative portal. Employees authenticate, record attendance using location and face/liveness checks, and manage leave; supervisors review attendance and leave, while administrators manage staff, schedules, reports, and system settings. The web and mobile apps call a NestJS API, whose domain modules implement these capabilities. The README is only a title, so additional capabilities and some client-to-server links are inferred from the source index or left unverified; unsampled backend internals are represented at their existing module directories.

Main entry points: [`apps/admin-web/src/lib/api.ts`](https://github.com/cristalynllarenas19-oss/mobile-face-verification-and-geotagged-attendance-with-leave-management-system/blob/main/apps/admin-web/src/lib/api.ts) (Web API Client), [`apps/admin-web/src/app/App.tsx`](https://github.com/cristalynllarenas19-oss/mobile-face-verification-and-geotagged-attendance-with-leave-management-system/blob/main/apps/admin-web/src/app/App.tsx) (Admin Portal), [`apps/employee-mobile/src/api.ts`](https://github.com/cristalynllarenas19-oss/mobile-face-verification-and-geotagged-attendance-with-leave-management-system/blob/main/apps/employee-mobile/src/api.ts) (Mobile API Client), [`backend/src/prisma/prisma.service.ts`](https://github.com/cristalynllarenas19-oss/mobile-face-verification-and-geotagged-attendance-with-leave-management-system/blob/main/backend/src/prisma/prisma.service.ts) (Application Database)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_clients["User Applications"]
  node_admin_app["Admin Portal<br/>[App.tsx]"]
  node_mobile_app["Mobile App<br/>[App.tsx]"]
  node_admin_api["Web API Client<br/>[api.ts]"]
  node_mobile_api["Mobile API Client<br/>[api.ts]"]
end

subgraph group_attendance["Attendance and Location"]
  node_admin_attendance["Attendance Portal<br/>[AttendancePage.tsx]"]
  node_employee_attendance["Employee Attendance"]
  node_face_registration["Face Registration"]
  node_attendance_api["Attendance API"]
  node_face_api["Face Verification API"]
  node_face_profiles["Face Profiles API"]
  node_geolocation["Geofencing API"]
end

subgraph group_workforce["Workforce Administration"]
  node_employee_admin["Employee Management<br/>[EmployeesPage.tsx]"]
  node_employees_api["Employees API"]
  node_schedules["Schedules API"]
  node_reports["Reports API"]
  node_dashboard["Dashboard API"]
end

subgraph group_leave["Leave and Reviews"]
  node_employee_leave["Employee Leave<br/>[LeavePage.tsx]"]
  node_leave_admin["Leave Management<br/>[LeavePage.tsx]"]
  node_leave_api["Leave API"]
  node_regularization["Regularization Review"]
end

subgraph group_platform["Identity and Platform"]
  node_auth_api["Authentication API<br/>[auth.service.ts]"]
  node_audit_logs["Audit Logging"]
  node_database[("Application Database<br/>[prisma.service.ts]")]
end

node_employee(("Employee"))
node_supervisor(("Supervisor"))
node_administrator(("Administrator"))

node_employee -->|"uses"| node_mobile_app
node_supervisor -->|"uses"| node_mobile_app
node_administrator -->|"uses"| node_admin_app
node_admin_app -->|"renders"| node_admin_attendance
node_admin_app -->|"renders"| node_employee_admin
node_admin_app -->|"renders"| node_face_registration
node_employee -.->|"records attendance"| node_employee_attendance
node_mobile_app -->|"requests data"| node_mobile_api
node_admin_app -.->|"requests data"| node_admin_api
node_mobile_api -.->|"calls API"| node_attendance_api
node_admin_api -.->|"calls API"| node_employees_api
node_attendance_api -.->|"reads and writes"| node_database
node_employees_api -.->|"reads and writes"| node_database
node_face_registration -.->|"manages profiles"| node_face_profiles
node_face_profiles -.->|"stores profiles"| node_database
node_attendance_api -.->|"uses geofencing"| node_geolocation
node_mobile_api -.->|"calls API"| node_face_api
node_mobile_api -.->|"calls API"| node_geolocation
node_admin_api -.->|"calls API"| node_schedules
node_admin_api -.->|"calls API"| node_reports
node_admin_api -.->|"calls API"| node_dashboard
node_employee -.->|"requests leave"| node_employee_leave
node_supervisor -.->|"reviews leave"| node_leave_admin
node_employee_leave -.->|"requests data"| node_mobile_api
node_admin_api -.->|"calls API"| node_leave_api
node_leave_api -.->|"reads and writes"| node_database
node_supervisor -.->|"reviews cases"| node_regularization
node_admin_api -.->|"authenticates"| node_auth_api
node_auth_api -->|"reads and writes"| node_database
node_auth_api -->|"records events"| node_audit_logs
node_employees_api -->|"scopes supervisor access"| node_employees_api
node_leave_api -->|"scopes supervisor access"| node_leave_api

click node_admin_app "https://github.com/cristalynllarenas19-oss/mobile-face-verification-and-geotagged-attendance-with-leave-management-system/blob/main/apps/admin-web/src/app/App.tsx"
click node_mobile_app "https://github.com/cristalynllarenas19-oss/mobile-face-verification-and-geotagged-attendance-with-leave-management-system/blob/main/apps/employee-mobile/App.tsx"
click node_admin_api "https://github.com/cristalynllarenas19-oss/mobile-face-verification-and-geotagged-attendance-with-leave-management-system/blob/main/apps/admin-web/src/lib/api.ts"
click node_mobile_api "https://github.com/cristalynllarenas19-oss/mobile-face-verification-and-geotagged-attendance-with-leave-management-system/blob/main/apps/employee-mobile/src/api.ts"
click node_admin_attendance "https://github.com/cristalynllarenas19-oss/mobile-face-verification-and-geotagged-attendance-with-leave-management-system/blob/main/apps/admin-web/src/features/attendance/AttendancePage.tsx"
click node_employee_attendance "https://github.com/cristalynllarenas19-oss/mobile-face-verification-and-geotagged-attendance-with-leave-management-system/blob/main/apps/employee-mobile/src/screens/AttendanceScreen.tsx"
click node_face_registration "https://github.com/cristalynllarenas19-oss/mobile-face-verification-and-geotagged-attendance-with-leave-management-system/blob/main/apps/admin-web/src/features/face-registration/FaceRegistrationPage.tsx"
click node_attendance_api "https://github.com/cristalynllarenas19-oss/mobile-face-verification-and-geotagged-attendance-with-leave-management-system/blob/main/backend/src/modules/attendance/attendance.controller.ts"
click node_face_api "https://github.com/cristalynllarenas19-oss/mobile-face-verification-and-geotagged-attendance-with-leave-management-system/tree/main/backend/src/modules/face-verification"
click node_face_profiles "https://github.com/cristalynllarenas19-oss/mobile-face-verification-and-geotagged-attendance-with-leave-management-system/blob/main/backend/src/modules/face-profiles/face-profiles.controller.ts"
click node_geolocation "https://github.com/cristalynllarenas19-oss/mobile-face-verification-and-geotagged-attendance-with-leave-management-system/blob/main/backend/src/modules/geolocation/geolocation.controller.ts"
click node_employee_admin "https://github.com/cristalynllarenas19-oss/mobile-face-verification-and-geotagged-attendance-with-leave-management-system/blob/main/apps/admin-web/src/features/employees/EmployeesPage.tsx"
click node_employees_api "https://github.com/cristalynllarenas19-oss/mobile-face-verification-and-geotagged-attendance-with-leave-management-system/blob/main/backend/src/modules/employees/employees.controller.ts"
click node_schedules "https://github.com/cristalynllarenas19-oss/mobile-face-verification-and-geotagged-attendance-with-leave-management-system/blob/main/backend/src/modules/schedules/schedules.controller.ts"
click node_reports "https://github.com/cristalynllarenas19-oss/mobile-face-verification-and-geotagged-attendance-with-leave-management-system/tree/main/backend/src/modules/reports"
click node_dashboard "https://github.com/cristalynllarenas19-oss/mobile-face-verification-and-geotagged-attendance-with-leave-management-system/tree/main/backend/src/modules/dashboard"
click node_employee_leave "https://github.com/cristalynllarenas19-oss/mobile-face-verification-and-geotagged-attendance-with-leave-management-system/blob/main/apps/admin-web/src/features/employee-portal/LeavePage.tsx"
click node_leave_admin "https://github.com/cristalynllarenas19-oss/mobile-face-verification-and-geotagged-attendance-with-leave-management-system/blob/main/apps/admin-web/src/features/leave/LeavePage.tsx"
click node_leave_api "https://github.com/cristalynllarenas19-oss/mobile-face-verification-and-geotagged-attendance-with-leave-management-system/blob/main/backend/src/modules/leave/leave.controller.ts"
click node_regularization "https://github.com/cristalynllarenas19-oss/mobile-face-verification-and-geotagged-attendance-with-leave-management-system/blob/main/apps/employee-mobile/src/screens/supervisor/RegularizationReviewScreen.tsx"
click node_auth_api "https://github.com/cristalynllarenas19-oss/mobile-face-verification-and-geotagged-attendance-with-leave-management-system/blob/main/backend/src/modules/auth/auth.service.ts"
click node_audit_logs "https://github.com/cristalynllarenas19-oss/mobile-face-verification-and-geotagged-attendance-with-leave-management-system/blob/main/backend/src/modules/audit-logs/audit-logs.service.ts"
click node_database "https://github.com/cristalynllarenas19-oss/mobile-face-verification-and-geotagged-attendance-with-leave-management-system/blob/main/backend/src/prisma/prisma.service.ts"

classDef toneNeutral fill:#f8fafc,stroke:#334155,stroke-width:1.5px,color:#0f172a
classDef toneBlue fill:#dbeafe,stroke:#2563eb,stroke-width:1.5px,color:#172554
classDef toneAmber fill:#fef3c7,stroke:#d97706,stroke-width:1.5px,color:#78350f
classDef toneMint fill:#dcfce7,stroke:#16a34a,stroke-width:1.5px,color:#14532d
classDef toneRose fill:#ffe4e6,stroke:#e11d48,stroke-width:1.5px,color:#881337
classDef toneIndigo fill:#e0e7ff,stroke:#4f46e5,stroke-width:1.5px,color:#312e81
classDef toneTeal fill:#ccfbf1,stroke:#0f766e,stroke-width:1.5px,color:#134e4a
class node_admin_app,node_mobile_app,node_admin_api,node_mobile_api toneBlue
class node_admin_attendance,node_employee_attendance,node_face_registration,node_attendance_api,node_face_api,node_face_profiles,node_geolocation toneAmber
class node_employee_admin,node_employees_api,node_schedules,node_reports,node_dashboard toneMint
class node_employee_leave,node_leave_admin,node_leave_api,node_regularization toneRose
class node_auth_api,node_audit_logs,node_database,node_employee,node_supervisor,node_administrator toneIndigo
```

## Components

### User Applications

- [Admin Portal](https://github.com/cristalynllarenas19-oss/mobile-face-verification-and-geotagged-attendance-with-leave-management-system/blob/main/apps/admin-web/src/app/App.tsx): `apps/admin-web/src/app/App.tsx`
- [Mobile App](https://github.com/cristalynllarenas19-oss/mobile-face-verification-and-geotagged-attendance-with-leave-management-system/blob/main/apps/employee-mobile/App.tsx): `apps/employee-mobile/App.tsx`
- [Web API Client](https://github.com/cristalynllarenas19-oss/mobile-face-verification-and-geotagged-attendance-with-leave-management-system/blob/main/apps/admin-web/src/lib/api.ts): `apps/admin-web/src/lib/api.ts`
- [Mobile API Client](https://github.com/cristalynllarenas19-oss/mobile-face-verification-and-geotagged-attendance-with-leave-management-system/blob/main/apps/employee-mobile/src/api.ts): `apps/employee-mobile/src/api.ts`

### Attendance and Location

- [Attendance Portal](https://github.com/cristalynllarenas19-oss/mobile-face-verification-and-geotagged-attendance-with-leave-management-system/blob/main/apps/admin-web/src/features/attendance/AttendancePage.tsx): `apps/admin-web/src/features/attendance/AttendancePage.tsx`
- [Employee Attendance](https://github.com/cristalynllarenas19-oss/mobile-face-verification-and-geotagged-attendance-with-leave-management-system/blob/main/apps/employee-mobile/src/screens/AttendanceScreen.tsx): `apps/employee-mobile/src/screens/AttendanceScreen.tsx`
- [Face Registration](https://github.com/cristalynllarenas19-oss/mobile-face-verification-and-geotagged-attendance-with-leave-management-system/blob/main/apps/admin-web/src/features/face-registration/FaceRegistrationPage.tsx): `apps/admin-web/src/features/face-registration/FaceRegistrationPage.tsx`
- [Attendance API](https://github.com/cristalynllarenas19-oss/mobile-face-verification-and-geotagged-attendance-with-leave-management-system/blob/main/backend/src/modules/attendance/attendance.controller.ts): `backend/src/modules/attendance/attendance.controller.ts`
- [Face Verification API](https://github.com/cristalynllarenas19-oss/mobile-face-verification-and-geotagged-attendance-with-leave-management-system/tree/main/backend/src/modules/face-verification): `backend/src/modules/face-verification`
- [Face Profiles API](https://github.com/cristalynllarenas19-oss/mobile-face-verification-and-geotagged-attendance-with-leave-management-system/blob/main/backend/src/modules/face-profiles/face-profiles.controller.ts): `backend/src/modules/face-profiles/face-profiles.controller.ts`
- [Geofencing API](https://github.com/cristalynllarenas19-oss/mobile-face-verification-and-geotagged-attendance-with-leave-management-system/blob/main/backend/src/modules/geolocation/geolocation.controller.ts): `backend/src/modules/geolocation/geolocation.controller.ts`

### Workforce Administration

- [Employee Management](https://github.com/cristalynllarenas19-oss/mobile-face-verification-and-geotagged-attendance-with-leave-management-system/blob/main/apps/admin-web/src/features/employees/EmployeesPage.tsx): `apps/admin-web/src/features/employees/EmployeesPage.tsx`
- [Employees API](https://github.com/cristalynllarenas19-oss/mobile-face-verification-and-geotagged-attendance-with-leave-management-system/blob/main/backend/src/modules/employees/employees.controller.ts): `backend/src/modules/employees/employees.controller.ts`
- [Schedules API](https://github.com/cristalynllarenas19-oss/mobile-face-verification-and-geotagged-attendance-with-leave-management-system/blob/main/backend/src/modules/schedules/schedules.controller.ts): `backend/src/modules/schedules/schedules.controller.ts`
- [Reports API](https://github.com/cristalynllarenas19-oss/mobile-face-verification-and-geotagged-attendance-with-leave-management-system/tree/main/backend/src/modules/reports): `backend/src/modules/reports`
- [Dashboard API](https://github.com/cristalynllarenas19-oss/mobile-face-verification-and-geotagged-attendance-with-leave-management-system/tree/main/backend/src/modules/dashboard): `backend/src/modules/dashboard`

### Leave and Reviews

- [Employee Leave](https://github.com/cristalynllarenas19-oss/mobile-face-verification-and-geotagged-attendance-with-leave-management-system/blob/main/apps/admin-web/src/features/employee-portal/LeavePage.tsx): `apps/admin-web/src/features/employee-portal/LeavePage.tsx`
- [Leave Management](https://github.com/cristalynllarenas19-oss/mobile-face-verification-and-geotagged-attendance-with-leave-management-system/blob/main/apps/admin-web/src/features/leave/LeavePage.tsx): `apps/admin-web/src/features/leave/LeavePage.tsx`
- [Leave API](https://github.com/cristalynllarenas19-oss/mobile-face-verification-and-geotagged-attendance-with-leave-management-system/blob/main/backend/src/modules/leave/leave.controller.ts): `backend/src/modules/leave/leave.controller.ts`
- [Regularization Review](https://github.com/cristalynllarenas19-oss/mobile-face-verification-and-geotagged-attendance-with-leave-management-system/blob/main/apps/employee-mobile/src/screens/supervisor/RegularizationReviewScreen.tsx): `apps/employee-mobile/src/screens/supervisor/RegularizationReviewScreen.tsx`

### Identity and Platform

- [Authentication API](https://github.com/cristalynllarenas19-oss/mobile-face-verification-and-geotagged-attendance-with-leave-management-system/blob/main/backend/src/modules/auth/auth.service.ts): `backend/src/modules/auth/auth.service.ts`
- [Audit Logging](https://github.com/cristalynllarenas19-oss/mobile-face-verification-and-geotagged-attendance-with-leave-management-system/blob/main/backend/src/modules/audit-logs/audit-logs.service.ts): `backend/src/modules/audit-logs/audit-logs.service.ts`
- [Application Database](https://github.com/cristalynllarenas19-oss/mobile-face-verification-and-geotagged-attendance-with-leave-management-system/blob/main/backend/src/prisma/prisma.service.ts): `backend/src/prisma/prisma.service.ts`

### Other components

- **Employee**
- **Supervisor**
- **Administrator**

## Connections

- Employee → Mobile App: uses (evidence: `apps/employee-mobile/App.tsx`)
- Supervisor → Mobile App: uses (evidence: `apps/employee-mobile/App.tsx`)
- Administrator → Admin Portal: uses (evidence: `apps/admin-web/src/app/App.tsx`)
- Admin Portal → Attendance Portal: renders (evidence: `apps/admin-web/src/app/App.tsx`)
- Admin Portal → Employee Management: renders (evidence: `apps/admin-web/src/app/App.tsx`)
- Admin Portal → Face Registration: renders (evidence: `apps/admin-web/src/app/App.tsx`)
- Employee → Employee Attendance: records attendance
- Mobile App → Mobile API Client: requests data (evidence: `apps/employee-mobile/App.tsx`)
- Admin Portal → Web API Client: requests data (evidence: `apps/admin-web/src/app/App.tsx`)
- Mobile API Client → Attendance API: calls API
- Web API Client → Employees API: calls API
- Attendance API → Application Database: reads and writes
- Employees API → Application Database: reads and writes
- Face Registration → Face Profiles API: manages profiles
- Face Profiles API → Application Database: stores profiles
- Attendance API → Geofencing API: uses geofencing
- Mobile API Client → Face Verification API: calls API
- Mobile API Client → Geofencing API: calls API
- Web API Client → Schedules API: calls API
- Web API Client → Reports API: calls API
- Web API Client → Dashboard API: calls API
- Employee → Employee Leave: requests leave
- Supervisor → Leave Management: reviews leave
- Employee Leave → Mobile API Client: requests data
- Web API Client → Leave API: calls API
- Leave API → Application Database: reads and writes
- Supervisor → Regularization Review: reviews cases
- Web API Client → Authentication API: authenticates
- Authentication API → Application Database: reads and writes (evidence: `backend/src/modules/auth/auth.service.ts`)
- Authentication API → Audit Logging: records events (evidence: `backend/src/modules/auth/auth.service.ts`)
- Employees API → Employees API: scopes supervisor access (evidence: `backend/src/modules/employees/employees.controller.ts`)
- Leave API → Leave API: scopes supervisor access (evidence: `backend/src/modules/leave/leave.controller.ts`)
