Symptom
A permission error occurs when attempting to access certain SAP SuccessFactors Learning APIs.
- Error message: "ERROR: error.Action.Restricted.NonHTML LMS_AUTHORIZATION_00008 error"
- Error code: LMS_AUTHORIZATION_00008
- Message: "You don't have permission to perform this action"
Image/data in this KBA is from SAP internal systems, sample data, or demo systems. Any resemblance to real data is purely coincidental.
Environment
SAP SuccessFactors Learning.
Reproducing the Issue
- Open the Rest Client application.
- Set up the Learning API connection.
- Perform an API metadata call, such as GET /learning/odatav4/user/learningPlan/v1/$metadata.
- Observe the permission error with the message: "You don't have permission to perform this action" and "ERROR: error.Action.Restricted.NonHTML LMS_AUTHORIZATION_00008 error".
Cause
The issue generally occur due to the use of an `admin` token for the API metadata call `/learning/odatav4/user/learningPlan/v1/`. The admin token does not have the required permissions to access user-specific metadata.
Resolution
As per the SAP help document LINK, utilize a `user` token for the metadata call `/learning/odatav4/user/learningPlan/v1/`.
Kindly generate a token for a user with `"userType":"user"` and proceed to test the learning API again. Also, ensure to follow the parameters outlined in the SAP help document- SAP SuccessFactors Learning APIs and Microservices Overview.
See Also
Keywords
permission error, LMS API, SAP SuccessFactors Learning, LMS roles, admin token, user token, metadata call, error.Action.Restricted.NonHTML, LMS_AUTHORIZATION_00008, API connection, learning_public_api, userType , KBA , LOD-SF-LMS-ODA , Web Services OData , How To
SAP Knowledge Base Article - Public