Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

Table of Contents
minLevel2
outlinetrue

Introduction

LAMS provides the API described in this page to create rich and powerful interaction with any 3rd party system. The aim for this integration is to make LAMS appear into an LMS system like yet another native tool of the LMS.

...

http://localhost/lams/LoginRequest?....

The parameters are:

Parameter

Description

Restrictions/conditions

uid

The username on the external system

Must be unique. Only alphanumeric characters and these symbols allowed "_" "-")

ts

Number of milliseconds since January 1, 1970, 00:00:00 GMT (known as "the epoch") till the time when the call is made

Required if according integrated server has "Enforce time limitation" setting ON. And if it's OFF it can be a random String.

sid

serverID (see integration configuration)

 


method

either author, monitor, learner or learnerStrictAuth; it sets permissions and redirects user to requested content

Must match one of the methods' name

hash

A SHA1 hash of [ts + uid + method + serverID + serverKey] (Note: all lower case before hashing) If you are using the learnerStrictAuth, you must include the lsId in the hash (see below)

 


mode

Additional directive: "preview" for previewing lesson in learner, "gradebook" to access user gradebook after logging in

 


courseid

the id of the course from the LMS

Must be unique for each LMS course

lsid

Used for monitor, learner and gradebook to tell LAMS the lesson id you want to open

Required if requesting access to monitor, learner or gradebook UIs

firstName

Used if a new user is created

No numbers or special characters permitted

lastName

Used if a new user is created

No numbers or special characters permitted. Only single quotes and spaces allowed ie: O'Harries or Garcia Marquez)

email

Used if a new user is created

Correctly validated email address required

country

Country (must use 2 letter code as ISO 3166-1 alpha-2 code for country)

 


lang

Language code or locale code. In case of just passing language use "es" for Spanish or locale as "es_ES" (see list of available locales in LAMS)

 


isUpdateUserDetails

"true" in case user details should get updated with new information, "false" (or no parameter) otherwise

 


requestSrc

String to identify who is making the call, this is only used in authoring to display on the close button.

 


notifyCloseURL

Callback URL to refresh the page after a sequences has been added.

 


You can use either http method POST or GET.

 


Mapping external roles to LAMS course roles

...

Therefore passing a method with one of these roles will assign the user the following LAMS course roles

 


MethodGrants roles
Authorlearner, monitor and author
Monitormonitor
learnerlearner
learnerStrictAuthlearner

 


The learnerStrictAuth method

...

http://localhost/lams/services/xml/LearningDesignRepository?

The parameters are:

Parameter

Description

username

The username of the current user. Must be unique

datetime

timestamp

serverId

the server id

hashValue

SHA1 hash of [timestamp + username + serverID + serverKey]  (Note: all lower case before hashing)

courseId

the id of the course from the LMS

country

Country (must use 2 letter code as ISO 3166-1 alpha-2 code for country)

lang

Language code or locale code. In case of just passing language use "es" for Spanish or locale as "es_ES" (see list of available locales in LAMS)

mode

"1" returns all learning designs being monitored by the current user, "2" returns all learning designs authored by the user

firstName

used if a new user is created

lastName

used if a new user is created

email

used if a new user is created

You can use either http method POST or GET.

...