SAP Knowledge Base Article - Public

2154063 - SCORM 1.2 API Calls - Learning Management System

Symptom

SCORM content communicates with an LMS via a client-side API. This API is designed to process a set of functions (defined by SCORM), and relay the information to the LMS. It is important to note the communication portion of SCORM 1.2 was borrowed from the AICC standard and thus shares roughly the same data model as AICC.

Environment

SuccessFactors Learning Management System (LMS) - All Supported Versions

Resolution

 

LMSInitialize( ) The content must call this function before calling any other API function. It indicates to the LMS system that the content is going to communicate. The LMS can take any initialization steps required in this function. For instance, this can contact the CMI via AICC messaging to pull down the cmi.core variables for quick access.
LMSGetValue( )

This function is used to pass data from the CMI to the content. Only one value is returned for each call. The category and/or element is named in the parameter.

The following LMSGetValue parameters are supported by SuccessFactors:

  • cmi.core._children - returns "student_id, student_name, lesson_location, credit, lesson_status, entry, score, total_time, exit, session_time"·
  • cmi.core.student_id
  • cmi.core.student_name
  • cmi.core.lesson_location - 255 char string typically used for bookmarking
  • cmi.core.credit - returns "no-credit" or "credit"
  • cmi.core.lesson_status - indicates SCO completion - returns one of the following: "passed", "completed", "failed", "incomplete", "browsed", or "not attempted"
  • cmi.core.entry - returns "ab-initio", "resume", or ""
  • cmi.core.score._children - returns "raw, min, max"
  • cmi.core.score.raw - the raw score value
  • cmi.core.score.max - the maximum possible score - if not set, assumed 100
  • cmi.core.score.min - the minimum possible score - if not set, assumed 0
  • cmi.core.total_time - returns the sum of all a learner's session times
  • cmi.core.lesson_mode - returns "browse", "normal", or "review"
  • cmi.suspend_data - 4096 char string usually used for progress data
  • cmi.launch_data - 4096 char string used to pass data to the SCO on launch from the LMS
  • cmi.objectives._children - returns "id, score, status"
  • cmi.objectives._count - returns the number of objectives currently stored for this SCO.
  • cmi.objectives.n.id - returns the objective identifier where "n" is the objective number
  • cmi.objectives.n.score._children - returns "raw, min, max "
  • cmi.objectives.n.score.raw - the raw objective score value
  • cmi.objectives.n.score.min - The minimum possible score - if not set, assumed 0
  • cmi.objectives.n.score.max - the maximum possible objective score - if not set, assumed 100
  • cmi.objectives.n.status - indicates if the learner has completed the objective - returns one of the following: "passed", "completed", "failed", "incomplete", "browsed", or "not attempted"
The following are legitimate element names, but are write-only. These would therefore return "" and set an error: 404 - element is write-only.
  • cmi.core.exit
  • cmi.core.session_time
LMSSetValue( )

This function is used to pass data from the content to the LMS. The parameter indicates which category or element is being set. Only one value may be set with a single function call.

The following LMSSetValue parameters are supported by SuccessFactors:

  • cmi.core.lesson_location - 255 char string usually used for bookmarking
  • cmi.core.lesson_status - indicates SCO completion - accepts "passed", "completed", "failed", "incomplete", "browsed", "not attempted"
  • cmi.core.score.raw - the raw score value
  • cmi.core.score.max - the maximum possible score - if not set, assumed 100
  • cmi.core.score.min - the minimum possible score - if not set, assumed 0
  • cmi.core.exit - indicates how the learner left the SCO - accepts "time-out", "suspend", or "logout"
  • cmi.core_session_time - Time spent in the SCO - HHHH:MM:SS.SS
  • cmi.suspend_data - 4096 char string usually used for progress data
  • cmi.objectives.n.id - the objective identifier where "n" is the objective number
  • cmi.objectives.n.score.raw - the raw objective score value
  • cmi.objectives.n.score.min - The minimum possible score - if not set, assumed 0
  • cmi.objectives.n.score.max - the maximum possible objective score - if not set, assumed 100
  • cmi.objectives.n.status - indicates if the learner has completed the objective - accepts "passed", "completed", "failed", "incomplete", "browsed", or "not attempted"

The following are legitimate element names, but are read-only. These would therefore return "false" and set an error: 403 - element is read-only:

  • cmi.core.student_id
  • cmi.core.student_name
  • cmi.core.credit
  • cmi.core.entry
  • cmi.core.total_time
  • cmi.core.lesson_mode
  • cmi.launch_data
The following elements are legitimate element names, but are keywords for multiple elements. These would therefore return "" and set the error code 402 - "Invalid set value, element is a keyword":
  • cmi.core._children
  • cmi.core.score._children
  • cmi.objectives._children
  • cmi.objectives._count
  • cmi.objectives.n.score._children
LMSCommit( ) Any values set using the LMSSetValue command are stored for delivery. This function submits any values not yet sent to the LMS.
LMSFinish( ) The content must call this function before it terminates, if it successfully called LMSInitialize at any point. It signals to the LMS that the content has finished communicating. The content may not call any API function except LMSGetLastError after it calls LMSFinish
LMSGetLastError( ) This function provides content with a way of assessing whether or not any given API call was successful, and if it was not successful, what went wrong. This routine returns an error code from the previous API call. Each time an API function is called (with the exception of this one), the error code is reset in the API. The content may call this any number of times to retrieve the error code, and the code will not change until the next API call.
LMSGetErrorString( ) This function returns a textual description of the error represented by an error code number.
LMSGetDiagnostic( ) This function would return an LMS-specific error description based on an error code number.

This information and more is also available for other content standards on this page: http://icontent.plateau.com/icontent/cig/index.htm?cso=1

Keywords

SCORM 1.2 API Calls; SCORM; LMSInitialize; LMSGetValue; LMSSetValue; LMSCommit; LMSFinish; LMSGetLastError; LMSGetErrorString; LMSGetDiagnostic; , KBA , LOD-SF-LMS-PCM , LMS Icontent , LOD-SF-LMS , SuccessFactors Learning , How To

Product

SAP SuccessFactors Learning all versions