User Course Status

This end point is use for get list of completed user course

[GET] /ruangkerja/dashboard/user-course-status

Information

This API contains information about Course status in Ruangkerja. It will present a list of user course completion, based on start and end datetime parameters.

Headers

NameTypeExampleRequiredDescription
Authorizationstringaccess_tokenYESToken of authentication. Get from Authentication API
Acceptstringapplication/jsonYESDefines the message format that is expected by the client
Content-Typestringapplication/jsonYESDefines the message format of the request body that is sent by the client

Parameter

NameTypeRequiredLocationDescription
startTimestampstringYESqueryQuery param for start datetime filter (support all timezone) e.g. 2019-10-12T14:20:50+07:00
endTimestampstringYESqueryQuery param for end datetime filter (support all timezone) e.g. 2019-10-12T14:20:50+07:00

Example cURL Request

curl --location --request GET 'https://api.ruangkerja.id/ruangkerja/dashboard/user-course-status?startTimestamp=2023-10-10T12:00:00+07:00&endTimestamp=2023-10-13T12:00:00+07:00' \
--header 'Authorization: access_token'

Example Success Response

{
    "status": "success",
    "message": "Success",
    "data": {
        "items": [
            ...,
            {
                "assignedCourseSerial": "ASGC-9O8QZE0T",
                "employeeID": "ID-1234",
                "courseName": "Mahir Menggunakan Microsoft Excel",
                "completedAt": "2023-10-12T12:00:00+07:00",
                "updatedAt": "2023-10-12T12:00:00+07:00",
                "status": "completed"
            },
            {
                "assignedCourseSerial": "ASGC-9O8QZE0T",
                "employeeID": "ID-1234",
                "courseName": "Mahir Menggunakan Microsoft Docs",
                "completedAt": "2023-10-11T12:00:00+07:00",
                "updatedAt": "2023-10-11T12:00:00+07:00",
                "status": "completed"
            }
        ]
    }
}

Response Body Terminology

LocationTypeDescription
data.items.*.assignedCourseSerialstringSerial of assigned course to user
data.items.*.employeeIDstringEmployee ID of User
data.items.*.courseNamestringName of course that completed by user
data.items.*.completedAtstringrfc3339 string representation of completed timestamp
data.items.*.updatedAtstringrfc3339 string representation of completed timestamp
data.items.*.statusstringenum(not_started, completed, expired, failed, in_progress)

Example Failed Response

{
    "errorCode": 123,
    "message": "rpc error: code = PermissionDenied desc = Token is not valid",
    "detail": "rpc error: code = PermissionDenied desc = Token is not valid"
}

See also: Error Dictionary.