Skip to content

darylhjd/oams

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

OAMS 📑

Online Attendance Management System for NTU.

OAMS comes with a website! If you are an administrative user, you may login to explore more features.

NOTE: OAMS is currently in development and is not open for public testing. If you are an NTU student and wish to try out this system, please feel free to drop me a message.

External Services

Although OAMS comes with a built-in signature authentication system for attendance taking (which is used by the website), it is not the only possible method for attendance authentication.

OAMS provides avenues for integration with external services. External services act as middlemen, allowing them to introduce different methods of attendance authentication before updating a user's attendance. For example, biometric, QR-Code, or geo-fencing capabilities for authenticating a user's identity can be added before sending a request to change a user's attendance record.

Anyone is capable of creating an external service if they are so inclined!

API Endpoints

The following endpoints are available for usage by external services.

Endpoint Description Methods Codes Request Result
/upcoming-class-group-sessions Gets upcoming class group sessions. GET 200: Success -
Response
{
    "result": boolean,
    "upcoming_class_group_session": []UpcomingClassGroupSession
}
            
/upcoming-class-group-sessions/{sessionId}/attendances Get attendance records for class group session with {sessionId} GET 200: Success -
Response
{
    "result": boolean,
    "upcoming_class_group_session": UpcomingClassGroupSession,
    "attendance_entries": []AttendanceEntry
}
            
404: Session does not exist or is not upcoming.
/upcoming-class-group-sessions/{sessionId}/attendances/{enrollmentId} Change attendance status for a given {sessionId} and {enrollmentId}. PATCH 200: Success
Request
{
    "attended": boolean
}
            
Response
{
    "result": boolean,
    "attended: boolean
}
            
401: Not allowed to change attendance
Entity Format
UpcomingClassGroupSession
Example
{
    "id": 1,
    "start_time": "2024-01-15T08:30:00+08:00",
    "end_time": "2024-01-15T09:20:00+08:00",
    "venue": "TR+15 NORTH,NS4-05-93",
    "code": "SC1015",
    "year": 2023,
    "semester": "2",
    "name": "A21",
    "class_type": "TUT",
    "managing_role": "TEACHING_ASSISTANT" // Can be ignored for external services.
}
            
AttendanceEntry
Example
{
    "id": 2,
    "session_id": 1,
    "user_id": "TEST1345",
    "user_name": "JOHN TAN",
    "attended": false
}