AVAILABLE WITH BUSINESS SUBSCRIPTION

Method: listCourseModules

Note:

  • With this method, you can retrieve a list of modules (both content items and trainings) belonging to a single course.

Permissions to Run Request

The Account OwnerAccount AdministratorsDepartment Administrators, Course Authors, or custom roles with the 'Can edit' access to the content item. 

Department AdministratorsCourse Authors, and users with a custom role can only retrieve info regarding users belonging to the departments they manage and their sub-departments.

Request Parameters

Parameter

Type

Description

token (required)stringAccess token. You can obtain a token by making a request
courseId (required)stringThe course ID
pageSize (optional)string

The number of entries per page. If not indicated, equal to 1000

pageToken (optional)stringThe token needed to continue to the next page

Response Parameters

After the request is successfully processed, the system returns an object with the following properties:

Parameter

Type

Description

modulesarrayAn array containing a list of course modules
modulearrayAn array containing information about a course module
moduleIdstringThe course module ID
itemIdstring

The ID of the content item or a training belonging to the course. 

This parameter indicates the ID of a content item or a training assigned to it in the account, outside the course, and doesn't coincide with the moduleId parameter

courseIdstringThe ID of the course to which the module belongs
titlestringThe name of the course module
descriptionstringThe description of the course module
authorIdstringThe ID of the content’s author (appears in the response only if the type parameter = content item)
addedDatedateTimeThe creation date of a content item or a training included in a course
viewUrlstringThe link to view a course content (appears in the response only if the type parameter = content item)
typestring

The course module type. The possible values are:

  • content item
  • training
trainingType[trainingTypeId],
trainingType[trainingTypeTitle]
string

The type of training that includes ID and title.
It appears in the response only if the type = training

nextPageTokenstringThe key needed to continue to the next page
sequentialNumberstringSequential number of the module in the course

Possible Errors

ErrorDescription
Unknown content itemThe course with the indicated ID was not found
Permission deniedThe user doesn't have permission to complete the request or can't edit the content item. 

Sample Request

<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:soap="http://ispringlearn.com/go/services/api/soap">
   <soapenv:Header/>
   <soapenv:Body>
      <soap:ListCourseModulesRequest>
         <soap:credentials>
            <soap:token>K8yyVyTp3Zhe_IUqAnKSVLGzHtZdq5ixuCl94yWSxfE</soap:token>
         </soap:credentials>
         <soap:courseId>a849d840-6a8a-11ef-b992-36bad3a603e7</soap:courseId>
         <!--Optional:-->
<!--         <soap:pageToken>?</soap:pageToken>
-->
         <!--Optional:-->
<!--         <soap:pageSize>?</soap:pageSize>
-->
      </soap:ListCourseModulesRequest>
   </soapenv:Body>
</soapenv:Envelope>
XML

Sample Response

<SOAP-ENV:Envelope xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/" xmlns:ns1="http://ispringlearn.com/go/services/api/soap">
   <SOAP-ENV:Body>
      <ns1:ListCourseModulesResult>
         <ns1:modules>
            <ns1:module>
               <ns1:moduleId>ec712528-6a8a-11ef-8749-be6337f13907</ns1:moduleId>
               <ns1:itemId>ec5e8328-6a8a-11ef-9bd7-36bad3a603e7</ns1:itemId>
               <ns1:courseId>a849d840-6a8a-11ef-b992-36bad3a603e7</ns1:courseId>
               <ns1:title>Task</ns1:title>
               <ns1:description>Task for sales managers</ns1:description>
               <ns1:authorId>ec8f0c3e-6443-11ef-bd38-42a2a95d78c2</ns1:authorId>
               <ns1:addedDate>2024-09-04T06:57:17+00:00</ns1:addedDate>
               <ns1:viewUrl>https://courses.ispringlearn.com/view/35050-KHrJL-8FRvR-hmBHP</ns1:viewUrl>
               <ns1:type>material</ns1:type>
               <ns1:trainingType/>
               <ns1:sequentialNumber>1</ns1:sequentialNumber>
            </ns1:module>
            <ns1:module>
               <ns1:moduleId>0e028092-6a9a-11ef-b60f-c298d4afc52f</ns1:moduleId>
               <ns1:itemId>0dd3d554-6a9a-11ef-b4ad-723c165888c7</ns1:itemId>
               <ns1:courseId>a849d840-6a8a-11ef-b992-36bad3a603e7</ns1:courseId>
               <ns1:title>Quiz</ns1:title>
               <ns1:description>Quiz for sales managers</ns1:description>
               <ns1:authorId>ec8f0c3e-6443-11ef-bd38-42a2a95d78c2</ns1:authorId>
               <ns1:addedDate>2024-09-04T08:45:36+00:00</ns1:addedDate>
               <ns1:viewUrl>https://courses.ispringlearn.com/view/35050-AcGpe-PFf7E-eBzuw</ns1:viewUrl>
               <ns1:type>material</ns1:type>
               <ns1:trainingType/>
               <ns1:sequentialNumber>2</ns1:sequentialNumber>
            </ns1:module>
         </ns1:modules>
      </ns1:ListCourseModulesResult>
   </SOAP-ENV:Body>
</SOAP-ENV:Envelope>
XML