Some example Web API manual incl. Bearer Token Login and Refresh Token calls (using CCL url): https://docs.google.com/document/d/1NLMKQCH2TnScvVLdaHxxmJutTX_EM21PScWePyeuwd4
=================================================================================================
It is important to understand the data structure of the LMS and how the objects connected to each other.
Basic LMS objects and their relation to each other:
- The organization path (orgPath) /Root/[org url name] identifies your top level path (i.e. to get user profile data)
- An organization contains navigation pages (NavPages) and courses (course paths). NavPages are used to structure/group courses and other content
- Courses contain one or more course offerings.
- A course offering contains student registrations and instructors
- Every assessment result (i.e. exam) is bound to a specific student registration
- Completing a course means completing a registration. If a user retakes a course, they get re-registered and will complete a new registration
Please note that some parameters are optional and may be useful to you to filter the data you need.
The 'path' or 'course path' is an internal LMS path to identify the page or course you would like to get information from. Every path starts with /Root/[org url name] which identifies your organization in the LMS. If you navigate to a page/course in the LMS you can find the current path you are at in the browser Url. For example, the LMS path for https://orgname.marinels.com/Cnt/Root/OrgUrlName/PedestalCraneOpsManual/ is /Root/OrgUrlName/PedestalCraneOpsManual.
A list of courses and their paths can be retrieved via API endpoint Services/api/Content/GetCoursePaths?path={path}. The parameter 'path' could be that of the main organization (/Root/[org url name]) or a sub path to only get a subset of courses in your system.
Every course has at least one course offering, identified by an Id (GUID). The course offerings themselves reference the student registration objects. In order to get the course offerings of a course, you can use either API endpoint Services/api/Registration/GetCourseOfferingsByPath?coursePath={coursePath}&pageSize={pageSize}&startIndex={startIndex}&sortField={sortField}&sortDirection={sortDirection}&startDate={startDate}&endDate={endDate}&nameFilter={nameFilter} or Services/api/Registration/GetDefaultOfferingByCoursePath?coursePath={coursePath} using a coursePath from the previous call 'GetCoursePaths'.
Most of our customers only use 1 course offering per course. If that is true for you the endpoint Services/api/Registration/GetDefaultOfferingByCoursePath?coursePath={coursePath} may be useful to get the one course offering of a course.
Once you have identified the course offerings you are interested in you can get student registrations bound to those course offerings via API endpoint Services/api/Registration/GetRegistrationsByCourseOfferingId?coursePath={coursePath}&offeringId={offeringId}&pageSize={pageSize}&startIndex={startIndex}&fromRegistrationDate={fromRegistrationDate}&toRegistrationDate={toRegistrationDate}.
A course offering may have instructors associated - the API call Services/api/Registration/GetInstructorsByCourseOfferingId?offeringId={offeringId} would get you the instructors of a specific course offering.
A registration may contain assessment data like exam results. To retrieve those, API endpoints Services/api/Audit/GetStudentResultsByRegistrationId?registrationId={registrationId} and Services/api/Audit/GetStudentResultsByRegistrationIds can be used, passing the registration Ids from previous API calls.
User information is returned where applicable (i.e. registration). If user information is returned as part of an object like registration only a so called 'shallow user' is returned. A shallow user object contains minimal information to identify the user. Additional API endpoints are available to get full user profile information. Use the Id (GUID) of the shallow user to retrieve a full user profile via Services/api/User/GetUser?userId={userId}, Services/api/User/GetUsersByIds?path={path} or Services/api/User/GetUsersWithOrgProfileValues?path={path} just to list a few endpoints.
In addition to standard user information like first name, last name, email address optional 'OrgProfileFields' (OPFs) are available and are configured on the organization. If OPFs are configured the user values for OPFs can be retrieved via endpoints
0 Comments