GET ./staff_att/activities

Handles the GET request for retrieving staff attendance activities.

Query Params

NameValue TypeValidationDetails
ascIDintegerOptionalMust be a natural number excluding zero
statusstringOptionalMust be trimmed
namestringOptionalMust be trimmed
descriptionstringOptionalMust be trimmed
timetableActivityIDstringOptionalMust be trimmed
startDateTimestringOptionalMust be a valid date in 'Y-m-d' format, validated by _check_date method
endDateTimestringOptionalMust be a valid date in 'Y-m-d' format, validated by _check_date method
cmcIDstringOptionalMust be trimmed
isVisibleStudentsstringOptionalMust be trimmed
isScheduledstringOptionalMust be trimmed

Example

GET /api/v2/staff_att/activities?ascID=1&status=active

Response

{
"meta": {
"countTotal": "1000",
"countData": "100",
"countOffset": "0"
},
"data": [
{
"id": 1,
"cadID": 43,
"ascID": 12,
"startDateTime": "2022-04-05 10:30:00",
"endDateTime": "2022-04-05 12:30:00",
"status": "active",
"name": "Morning Meeting",
"description": "Daily stand-up meeting",
"timetableActivityID": "123",
"cmcID": "321",
"isVisibleStudents": "yes",
"isScheduled": "yes"
}
]
}

Validation Custom Errors

Error Code: 101

Error Message: The {field} is not a valid date.

Description: This error is returned when a startDateTime or endDateTime parameter is provided but does not contain a valid date in the format 'Y-m-d'.

Example:

{
"errorCode": "101",
"errorMessage": "The startDateTime is not a valid date."
}