GET /courses
List courses that the user can view or register for.
The authenticated user can access courses they own. Users own courses when they are a collaborator through their organization.
Name | Type | Description |
---|---|---|
limit |
query |
The maximum number of courses to return. If less than 1, it will be set to 1. If greater than 100, it'll be set to 100. Anything that's not a number will result in a 400 response. |
offset |
query |
The offset from 0 to start at. |
POST /courses/validate
Returns a JSON object containing the validated value and errors.
curl -X POST \
-d '{ "yaml": "title: yep" }' \
-H "Content-Type: application/json" \
https://lab.github.com/api/v0/courses/validate
Name | Type | Description |
---|---|---|
yaml |
requestBody |
A YAML code string to parse and validate. |
type |
requestBody |
The type of course, either repo or nested (defaults to repo ) |
GET /courses/:owner/:course
Return a specific course to the user by full name
Name | Type | Description |
---|---|---|
owner |
path |
The owner of the course being returned. If the owner doesn't exist, a 404 will be returned. |
course |
path |
The name of the course to be returned. If you don't have permission to access the course or if it doesn't exist, a 404 will be returned. |