Name
Availability
Breeze 4
Description
Provides information about each course the current user is or was enrolled in.
The returned courses include future courses, past courses, and courses the user is presently taking. The list of courses can be quite large, so remember to use a filter to reduce the response.
Each course has a permission-id that shows the level of access the user has to the course. For example, the access might be view, publish, or manage.
Request URL
http://server_name/api/xml ?action=report-my-courses &filter-definition=value &sort-definition=value &session=BreezeSessionCookieValue
Parameters
|
Type |
Required |
Description |
filter-definition |
Filter definition |
N |
A filter to reduce the volume of the response. |
sort-definition |
Sort definition |
N |
A sort to return results in a certain sequence. |
session |
String |
N |
The value of the BREEZESESSION cookie. Use this parameter if you do not use a client-side cookie management library. |
Filters
You can filter or sort the response on any element or attribute it contains.
Response structure
<?xml version="1.0" encoding="utf-8" ?> <results> <status code=allowedValue /> <my-courses> <course sco-id=integer type="content" icon="course" permission-id=allowedValue> <name>string</name> <description>string</description> <url>string</url> <date-created>datetime</date-created> <date-modified>datetime</date-modified> <date-begin>datetime</date-begin> <url-path>string</url-path> <expired>boolean</expired> <completed>boolean</completed> </course> ... </my-courses> </results>
Response values
Element |
Attribute |
Type |
Description |
---|---|---|---|
results | Container |
All results the action returns. |
|
status | Empty, with attributes |
The status of the response. |
|
code | Allowed value |
A code indicating the response status (see status). |
|
my-courses | Container |
Information about all courses the user is enrolled in. |
|
course | Container |
Information about one course the user is enrolled in. |
|
sco-id | BIGINT |
The unique ID of the course. |
|
type | Allowed value |
The type of the course (for allowed values, see type). |
|
icon | Allowed value |
The type of icon that identifies the course in the user interface. For a course, always course. |
|
permission-id | Allowed value |
The level of permission the user has on the course (see permission-id for values). |
|
name | String |
The name of the course. |
|
url | String |
The URL at which a user can reach the course on the server. Includes the domain name and the course identifier. |
|
date-created | Datetime |
The date and time the course was created. |
|
date-modified | Datetime |
The date and time the course was last modified. |
|
date-begin | Datetime |
The date and time the course is available for users to start. |
|
date-end | Datetime |
The date and time the course closes. |
|
url-path | String |
The part of the course URL that is the course identifier, after the domain name. |
|
expired | Boolean |
Whether the course has expired (true if it has, false if it has not). |
|
completed | Boolean |
Whether the user has completed the course (true if yes, false if no). |
Sample request
https://example.com/api/xml?action=report-my-courses
Sample response
<?xml version="1.0" encoding="utf-8" ?> <results> <status code="ok" /> <my-courses> <course sco-id="2006298431" type="content" icon="course" permission-id="view"> <name>Test Course</name> <url>example.com/test/</url> <date-created>2006-05-03T10:21:46.810-07:00</date-created> <date-modified>2006-05-03T10:22:30.803-07:00</date-modified> <date-begin>2006-05-03T10:15:00.000-07:00</date-begin> <url-path>/test/</url-path> <expired>false</expired> <completed>false</completed> </course> </my-courses> </results>