π₯ ZoomClone - Video Conferencing with AI Face Recognition Attendance
A full-stack video conferencing application with real-time AI-powered face recognition for automated attendance tracking. Built with React, Node.js, WebRTC, and TensorFlow.js.
πΉ Real-time Video Calls - WebRTC peer-to-peer connections
π€ Audio/Video Controls - Mute/unmute, camera on/off
π₯οΈ Screen Sharing - Share your screen with participants
π¬ In-Meeting Chat - Real-time text messaging
π₯ Multi-participant Support - Group video calls
AI-Powered Attendance System
π€ Face Recognition - TensorFlow.js powered face detection
π Automated Attendance - Tracks presence every 10 seconds
ποΈ Real-time Monitoring - Live attendance dashboard for meeting owners
π Attendance Reports - Detailed reports with presence percentage
β
Smart Status - Present (β₯75%), Partial (50-75%), Absent (<50%)
π User Authentication - Secure login/registration with bcrypt
π Meeting History - View past meetings and attendance records
π Meeting Owner System - First user becomes the meeting owner
Technology
Version
Purpose
React
18.2.0
UI Framework
Material-UI
5.18.0
Component Library
Socket.io-client
4.7.3
Real-time Communication
@vladmandic/face-api
1.7.15
Face Recognition
TensorFlow.js
4.22.0
ML Runtime
React Router
6.21.1
Navigation
Axios
1.6.5
HTTP Client
Technology
Version
Purpose
Node.js
18+
Runtime
Express.js
4.18.2
Web Framework
Socket.io
4.7.3
WebSocket Server
MongoDB
-
Database
Mongoose
8.0.3
ODM
Bcrypt
5.1.1
Password Hashing
Component
Purpose
RTCPeerConnection
Peer-to-peer media streaming
getUserMedia
Camera/microphone access
STUN Server
NAT traversal (Google STUN)
βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
β CLIENT (React) β
βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ€
β βββββββββββββββ βββββββββββββββ βββββββββββββββββββββββββββ β
β β Video β β Chat β β Face Recognition β β
β β Stream β β Panel β β (TensorFlow.js) β β
β ββββββββ¬βββββββ ββββββββ¬βββββββ βββββββββββββ¬ββββββββββββββ β
β β β β β
β ββββββββββββββββββΌββββββββββββββββββββββ β
β β β
β βββββββββ΄ββββββββ β
β β Socket.io β β
β β Client β β
β βββββββββ¬ββββββββ β
ββββββββββββββββββββββββββββΌβββββββββββββββββββββββββββββββββββββββ
β WebSocket
βΌ
ββββββββββββββββββββββββββββ΄βββββββββββββββββββββββββββββββββββββββ
β SERVER (Node.js) β
βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ€
β βββββββββββββββ βββββββββββββββ βββββββββββββββββββββββββββ β
β β Express β β Socket.io β β Attendance β β
β β API β β Server β β Manager β β
β ββββββββ¬βββββββ ββββββββ¬βββββββ βββββββββββββ¬ββββββββββββββ β
β β β β β
β ββββββββββββββββββΌββββββββββββββββββββββ β
β β β
β βββββββββ΄ββββββββ β
β β Mongoose β β
β β ODM β β
β βββββββββ¬ββββββββ β
ββββββββββββββββββββββββββββΌβββββββββββββββββββββββββββββββββββββββ
β
βΌ
ββββββββββββββββ
β MongoDB β
β Atlas β
ββββββββββββββββ
Node.js 18+ installed
MongoDB Atlas account (or local MongoDB)
Git
Step 1: Clone the Repository
git clone < repository-url>
cd Zoom
Create .env file in backend folder:
PORT = 8000
MONGO_URI = mongodb+srv://<username>:<password>@cluster.mongodb.net/zoomclone
cd ../frontend
npm install
Step 4: Start the Application
Terminal 1 - Backend:
Terminal 2 - Frontend:
Step 5: Access the Application
Zoom/
βββ backend/
β βββ src/
β β βββ app.js # Express server entry point
β β βββ controllers/
β β β βββ socketManager.js # Socket.io event handlers
β β β βββ user.controller.js # User authentication logic
β β βββ models/
β β β βββ user.model.js # User schema
β β β βββ face.model.js # Face descriptor schema
β β β βββ meeting.model.js # Meeting history schema
β β β βββ attendance.model.js# Attendance record schema
β β βββ routes/
β β βββ users.routes.js # Auth API routes
β β βββ attendance.routes.js# Attendance API routes
β βββ package.json
β
βββ frontend/
β βββ public/
β β βββ index.html
β βββ src/
β β βββ App.js # Main app with routing
β β βββ environment.js # Backend URL config
β β βββ contexts/
β β β βββ AuthContext.jsx # Authentication state
β β βββ pages/
β β β βββ landing.jsx # Homepage
β β β βββ authentication.jsx # Login/Register
β β β βββ home.jsx # Dashboard after login
β β β βββ VideoMeet.jsx # Video call + attendance
β β β βββ history.jsx # Meeting history
β β β βββ AttendanceHistory.jsx # Attendance reports
β β βββ styles/
β β β βββ videoComponent.module.css
β β βββ utils/
β β βββ withAuth.jsx # Auth HOC
β βββ package.json
β
βββ README.md
Landing Page β Login/Register β Home Dashboard β Join/Create Meeting
1. User joins meeting URL (e.g., /abc123)
2. Camera/Mic permissions requested
3. Socket.io connection established
4. WebRTC peer connections created with other users
5. Video/audio streams exchanged
3. Face Recognition Attendance Flow
1. User joins meeting
2. Face enrollment modal appears
3. User's face is captured and 128D descriptor extracted
4. Descriptor saved to MongoDB
5. Every 10 seconds:
- Face detection runs on local video
- Detected face compared with enrolled face
- If match (>60% confidence): verifiedTime += 10s
- Data sent to server via Socket.io
6. On meeting end:
- Attendance report generated
- Report sent to meeting owner
- Saved to database
4. Attendance Calculation
verifiedPercent = ( verifiedTime / totalTime ) * 100
Status :
- Present : verifiedPercent >= 75 %
- Partial : verifiedPercent >= 50 % && < 75 %
- Absent : verifiedPercent < 50 %
Method
Endpoint
Description
POST
/api/v1/users/register
Create new user
POST
/api/v1/users/login
User login
POST
/api/v1/users/logout
User logout
POST
/api/v1/users/add_to_activity
Log meeting activity
GET
/api/v1/users/get_all_activity
Get user's meeting history
Method
Endpoint
Description
GET
/api/v1/attendance/reports
Get all attendance reports
GET
/api/v1/attendance/owner-reports/:owner
Get reports for meeting owner
Method
Endpoint
Description
GET
/api/health
Server health check
Event
Data
Description
join-call
(path, userId, userName, isOwner)
Join a meeting room
signal
(toId, message)
WebRTC signaling
chat-message
(data, sender)
Send chat message
register-face
{meetingId, userId, descriptor}
Register face descriptor
verified-update
{meetingId, userId, userName, verifiedDelta}
Update attendance
end-meeting
{meetingId}
End meeting & generate report
Event
Data
Description
user-joined
(socketId, allSocketIds)
New user joined
user-left
(socketId)
User left meeting
signal
(fromId, message)
WebRTC signal relay
chat-message
(data, sender, socketId)
New chat message
you-are-owner
-
Notify meeting owner
live-attendance
{participants}
Live attendance data
attendance-report
{report}
Final attendance report
owner-attendance-report
{report}
Owner's detailed report
{
name : String , // Display name
username : String , // Unique login ID
password : String , // Bcrypt hashed
token : String // Session token
}
{
userId : String , // Username
meetingId : String , // Meeting code
descriptor : [ Number ] // 128D face descriptor
}
{
meetingId : String ,
meetingOwner : String ,
participants : [ {
userId : String ,
name : String ,
totalTime : Number ,
verifiedTime : Number ,
verifiedPercent : Number ,
status : String // 'Present'|'Partial'|'Absent'
} ] ,
startTime : Date ,
endTime : Date
}
# Windows
netstat -ano | findstr :8000
taskkill /F /PID < PID>
# Or use npm script
cd backend && npm run kill-port
2. Camera/Microphone Not Working
Check browser permissions
Ensure HTTPS in production (WebRTC requires secure context)
Try refreshing the page
3. Face Recognition Not Loading
4. WebRTC Connection Failed
Check STUN server connectivity
Ensure both users have camera enabled
Check firewall settings
5. MongoDB Connection Failed
Verify MONGO_URI in .env file
Check network connectivity
Ensure IP is whitelisted in MongoDB Atlas
6. Socket Connection Refused
Ensure backend is running on port 8000
Check frontend environment.js has correct URL
Verify CORS configuration
Phase 1: Enhanced Security
Phase 2: Advanced Features
π¨βπ» Scripts Reference
npm run dev # Start with nodemon (hot reload)
npm start # Production start
npm run kill-port # Kill process on port 8000
npm run restart # Kill port + start dev
npm start # Development server
npm run build # Production build
npm test # Run tests
This project is licensed under the ISC License.
Made with β€οΈ for modern video conferencing