Returns a list of courses that the requesting user is permitted to view,restricted to those that match the request. Returned courses are ordered bycreation time, with the most recently created coming first.
gc_courses_list( studentId = NULL, pageToken = NULL, pageSize = NULL, teacherId = NULL, courseStates = NULL )
studentId | Restricts returned courses to those having a student with the specified |
---|---|
pageToken | nextPageToken |
pageSize | Maximum number of items to return |
teacherId | Restricts returned courses to those having a teacher with the specified |
courseStates | Restricts returned courses to those in one of the specified states |
This method returns the following error codes:
PERMISSION_DENIED
for access errors.
INVALID_ARGUMENT
if the query argument is malformed.
NOT_FOUND
if any users specified in the query arguments do not exist.
Authentication scopes used by this function are:
https://www.googleapis.com/auth/classroom.courses
https://www.googleapis.com/auth/classroom.courses.readonly
Set options(googleAuthR.scopes.selected = c("https://www.googleapis.com/auth/classroom.courses", "https://www.googleapis.com/auth/classroom.courses.readonly")
Then run googleAuthR::gar_auth()
to authenticate.
See gar_auth
for details.