Learning History Web Service PDF
Learning History Web Service PDF
Learning History Web Service PDF
1.1 Introduction
The Learning History web service is intended to externalize user Learning History interactions for a customer portal. This web service
returns a user's Learning History details. The design is based upon the capabilities and constraints of the Learning History in the
SuccessFactors Learning user interface. For 1505 this web service has been extended to return the individual User’s Item Rating. Users
are able to provide an Item Rating providing “User Rating” has been enabled for the Item and the User has a corresponding Learning
History record against the Item. The Rating Sequence number can be used in conjunction with the 1505 “Update User Item Rating” Web
Service which allows the User’s Item Rating to be set or updated.
1.3 Deprecation
As of May 5, 2015, all new customer / new webservices implementations are required to use OData
APIs for integrations (http://help.sap.com/hr_api/). This guide will remain available and RESTful web
services will continue to be supported (but no longer enhanced) for customers that had already
implemented a solution based on the RESTful APIs prior to May 5, 2015.
Authentication Mechanism
Webservice client will access the token provider tool in the LMS to get the user based token which later on will be passed with rest
API call. A Secret Key will be shared between LMS token provider and webservice client and will be used for authentication when web
service client is requesting for the token.
Service Invocation
RESOURCE DESCRIPTION
https://(learning server)/learning/rest/public-api/v1/current-user/learning-
history?targetUserID={targetUserID}&maxNumberToRetrieve={maxNumberToR
Request URL
etrieve}&itemID={itemID}&itemRevisionDate={itemRevisionDate}&itemType={ite
mType}&fromDate={completion from date}&toDate={completion to date}
Request Method GET
Description Learning History
Request Header Accept: application/json (Optional)
Parameters None
Inputs
Inputs are supplied to the REST API via request query-string parameters.
# Input Parameter Required? DataType Description Details/Business
Rules
1 targerUserID Yes String This is the target user id LMS user id whose learning
history is being requested
2 maxNumberToRetrieve No Number Maximum number of records Maximum number of records
to be returned to be returned
3 itemID No String This is the ID for the course Must align to the Item Type ID
(Item) defined within the LMS’
Reference Values
4 itemType No String Item Type for the Item Must be a valid Item ID in the
LMS
5 itemRevisionDate No Timestamp Revision date of the Item Must align to the revision date
of the item being queried.
Format: MMDDYYY
24HHMMSS
6 fromDate No Date From Date If specified, only those
learning history records are
returned where completion
date is on or after the from
date
7 toDate No Date To Date If specified, only those
learning history records are
returned where completion
date is on or before the to
date
Outputs
RestOperationStatusVOX
Field Description
operation Operation name
status Success/Fail
data Data returned (as described in Response body above in service invocation section)
errors Json errors (if any)
warnings Json warnings (if any)
The HTTP Response Code is used as a primary indicator of the success or failure of the API call:
HTTP Error Code Description
400 Bad request – invalid or missing inputs
401 Unauthorized – authentication credential is missing or incorrect
403 Forbidden – you are not allowed to perform this operation
404 Not found – the API itself does not exist
500 Internal server error
Validations
Error Code Error Message
500 User does not exist
500 User does not have access to Learning History workflow
500 User does not have Learning History
500 Item does not exist