API: getGroupLearningModules
  • 1 Minute to read
  • Dark
    Light

API: getGroupLearningModules

  • Dark
    Light

Article summary

  • Starting June 1, 2022, SmarterU will require all API calls to POST to HTTPS. Any POST to HTTP will result in the SU:01 error (i.e., No POST data detected.).
  • If you are viewing the help in a language other than English, please change your language to English before copying and pasting any code. All API attributes and functions are in English.
  • Tags are required unless specified.

Description

The getGroupLearningModules method retrieves the group's courses.

Who Has Access

The following users have access to the getGroupLearningModules method:

API Call XML Package

<SmarterU>
   <AccountAPI><![CDATA[]]></AccountAPI>
   <UserAPI><![CDATA[]]></UserAPI>
   <Method>getGroupLearningModules</Method>
   <Parameters>
      <Group>
         <Name><![CDATA[]]></Name>
            - OR -
         <GroupID><![CDATA[]]></GroupID>
      </Group>
   </Parameters>
</SmarterU>

Group Tag Group

The Group tag group is a container for the group filters.

<Group>
   <Name><![CDATA[]]></Name>
      - OR -
   <GroupID><![CDATA[]]></GroupID>
</Group>

The Group tag may contain the following.

Name

The group's name. This tag is mutually exclusive with the GroupID tag. This is the Name returned by the getGroup method.

GroupID

The group's user-specified identifier. This tag is mutually exclusive with the Name tag. This is the GroupID returned by the getGroup method.

API Response XML Package

The API response XML package will always include a Result, Info, and Errors tag.

<SmarterU>
   <Result></Result>
   <Info>
      <LearningModules>
         <LearningModule>
            <LearningModuleID><![CDATA[]]></LearningModuleID>
            <Name><![CDATA[]]></Name>
            <Type><![CDATA[]]></Type>
            <Status><![CDATA[]]></Status>
         </LearningModule>
      </LearningModules>
   </Info>

   <Errors>
      <Error>
         <ErrorID></ErrorID>
         <ErrorMessage></ErrorMessage>
      </Error>
   </Errors>
</SmarterU>

The LearningModules tag is a container for the courses returned by the getGroupLearningModules method. Each course is contained in a LearningModule tag and may contain the following.

LearningModuleID

The course's system-generated identifier.  

Name

The course's name.

Type

The course type (i.e., Online, SCORM, or External). 

Status

The course's status (i.e., Active, Inactive, Archived).

Example API Response XML Package

Below is an example of an API response XML package.

<SmarterU>
   <Result>Success</Result>
   <Info>
      <LearningModules>
         <LearningModule>
            <LearningModuleID><![CDATA[1972]]></LearningModuleID>
            <Name><![CDATA[Employee Onboarding]]></Name>
            <Type><![CDATA[Online]]></Type>
            <Status><![CDATA[Active]]></Status>
         </LearningModule>

         <LearningModule>
            <LearningModuleID><![CDATA[3860]]></LearningModuleID>
            <Name><![CDATA[Forklift Operation]]></Name>
            <Type><![CDATA[External]]></Type>
            <Status><![CDATA[Active]]></Status>
         </LearningModule>
      </LearningModules>
   </Info>

   <Errors>
      <Error>
         <ErrorID></ErrorID>
         <ErrorMessage></ErrorMessage>
      </Error>
   </Errors>
</SmarterU>

Error Codes

Error CodeMessage
GGLM:01
The name provided is not valid.
GGLM:02
The group ID provided is not valid.
GGLM:03
The required permissions are not met to call the getGroupLearningModules method.
GGLM:04
The requested group does not exist.

Was this article helpful?