Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.
Comment: Migrated to Confluence 4.0

LAMS server-to-server registration and deregistration service

Table of Contents
Info

In order to use this feature you must enable the "Enable remote server user registration" option in the sysadmin configuration settings menu.

In case any integrations want to register all the users at one go they can use the following API. Please note that required parameters are marked in bold.

External calls to LAMS

Add user to group lessons

You can add a user to group lessons by making a request to the Register Action on the LAMS side. For example:

http://localhost/lams/services/Register?method=addUserToGroupLessons&....

The parameters are (in bold denotes mandatory fields):

  • method=addUserToGroupLessons - selfexplanatory.
  • serverId - the server id
  • datetime - a character string with the date and time you make this request (format example 2011100608:15:10)
  • hashValue - the hash value is generated using the SHA1 algorithm on the following (all in lower case) [ datetime + username + method + serverId + serverKey ]
  • username - the username of the user
  • courseId - optional parameter which stands for the id of the course from the LMS. If it's specified then user gets added to the course and its lessons, if not - just create the user.
  • lessonId - optional parameter which stands for the id of the lesson from the LMS. If it's specified then user gets added to this lesson, if not - just create the user.
  • firstName - his first name
  • lastName - last name
  • email - email
  • isJoinLesson - if set to 1 - then join user to lesson
  • isEmailParticipant - if set to 1 - then LAMS will email the user his/her login details
  • isEmailCoordinator - if an email confirmation to admin is required, just put the email address for the admin person here
  • usePrefix - if set to 1 - force the addition of the server integration prefix to usernames (unless you are using LAMS from an integration server or writing your own, set this to 0 or simply don't include this parameter.

Remove users from LMS lessons

You can remove user from group lessons by making the following request:

http://localhost/lams/services/Register?method=removeUserFromGroup&....

The parameters are (in bold denotes mandatory fields):

  • method=removeUserFromGroup - selfexplanatory.
  • serverId - the server id
  • datetime - a character string with the date and time you make this request (format example 2011100608:15:10)
  • hashValue - the hash value is generated using the SHA1 algorithm on the following (all in lower case) [ datetime + username + method + serverId + serverKey ]
  • username - the username of the user
  • courseId - id of the course from the LMS
  • isRemoveFromAllCourses - if set to 1 - then ignores courseId parameter and removes user from all courses
  • usePrefix - if set to 1 - force the addition of the server integration prefix to usernames (unless you are using LAMS from an integration server or writing your own, set this to 0 or simply don't include this parameter.

Reset user's time limit

You can resets user's time limit for all lessons in a group. It will work for lessons with scheduledToCloseForIndividuals setting on, otherwise it does nothing. Request format is as follows:

http://localhost/lams/services/Register?method=resetUserTimeLimit&....

The parameters are (in bold denotes mandatory fields):

  • method=resetUserTimeLimit - selfexplanatory.
  • serverId - the server id
  • datetime - a character string with the date and time you make this request (format example 2011100608:15:10)
  • hashValue - the hash value is generated using the SHA1 algorithm on the following (all in lower case) [ datetime + username + method + serverId + serverKey ]
  • courseId - id of the course from the LMS
  • username - the username of the user
  • usePrefix - if set to 1 - force the addition of the server integration prefix to usernames (unless you are using LAMS from an integration server or writing your own, set this to 0 or simply don't include this parameter.