Attendance Management System API

A comprehensive attendance management system API with user authentication, attendance tracking, and reporting features.

Operational

All systems are running normally

Version v1.0.0
Uptime 0m 0s
Last Updated 4:22:04 AM

📊 System Information

Node.js Version

v20.19.5

Platform

linux

Architecture

x64

🔐 Authentication Endpoints

/api/auth

Endpoints for user authentication and session management.

POST /api/auth/login

Authenticate user and generate JWT token for API access.

Parameters

  • username
    string (required)
  • password
    string (required)

Response

  • token
    JWT token for authentication
  • user
    User object with details

👥 User Management Endpoints

/api/users

Endpoints for managing users in the system.

GET /api/users

Retrieve all users in the system. Requires admin authentication.

Authentication

Required (Admin role)

Response

Array of user objects

POST /api/users

Create a new user in the system. Requires admin authentication.

Authentication

Required (Admin role)

Parameters

  • username
    string (required)
  • email
    string (required)
  • password
    string (required)
  • first_name
    string (required)
  • last_name
    string (required)
  • role_id
    integer (2=Manager, 3=Employee)
  • manager_id
    integer (optional, for employees)

Response

Created user object

GET /api/users/managers

Retrieve all managers in the system.

Authentication

Required

Response

Array of manager objects

⏰ Attendance Endpoints

/api/attendance

Endpoints for tracking and managing attendance records.

POST /api/attendance/check-in

Record user check-in time.

Authentication

Required

Parameters

  • userId
    integer (required)

Response

Attendance record with check-in time

POST /api/attendance/check-out

Record user check-out time.

Authentication

Required

Parameters

  • userId
    integer (required)

Response

Attendance record with check-out time

GET /api/attendance/:userId

Get attendance records for a specific user.

Authentication

Required

Response

Array of attendance records for the user

📚 Detailed Documentation 🩺 Health Check