Skip to main content

Get Course Dashboard Users

This endpoint retrieves the list of all users that joined the course identified by {id}; it will also return some useful stats that can be used to make a course dashboard.

info

This operation requires the course manager role.

HTTP Request

GET /api/v2/course/{id}/users/

Parameters

NameInTypeRequiredDescription
idpathstringtrueA unique integer value identifying this course
limitqueryintegerfalseNumber of results to return per page
offsetqueryintegerfalseThe initial index from which to return the results
searchquerystringfalseA search term (search inside username and real_name of the users)

Example Request

const headers = {
'Accept':'application/json',
'Authorization: Bearer <token>'
};

fetch('/api/v2/course/{id}/users/',
{
method: 'GET',
headers: headers
})
.then(function(res) {
return res.json();
}).then(function(body) {
console.log(body);
});

Responses

StatusMeaningDescriptionSchema
200OKResponse status codeInline

Response Schema

Status Code 200

NameTypeRequiredRestrictionsDescription
» countintegerfalsenoneTotal results count
» nextstring(uri)¦nullfalsenoneNext page url
» previousstring(uri)¦nullfalsenonePrevious page url
» resultslist(Course User Dashboard)falsenoneList of results. Every items will contain only the necessary fields