Symptom
You receive the error "Not Authorized: Check Authorization Restriction for the User" when trying to retrieve data from Employee collection via OData services.
Obs.: This error can also occur when trying to retrieve data from other work centers/views.
Environment
SAP Cloud for Customer
Reproducing the Issue
Open a URL from EmployeeCollection and the error will occur.
Cause
This is the standard behavior. The user is not able to retrieve data from Employee Collection because they don't have the view of Administrator > Employees assigned.
Resolution
The user might have the view of People > Employees assigned, but for accessing Employee Collection via OData it is required to have the view of Employees from Administrator work center assigned:
- Go to the Administrator work center.
- Open the Business Users view.
- Select the required user.
- Click the Edit button, then select Access Rights.
- If the user has a business role, the following steps to add the access right must be done in one of the business role's assignments.
- Go to the Work Center and View Assignment tab.
- Expand the work center SEODADMINWCF / Administrator.
- Assign the view BPM_EMPLOYEES / Employees to the user.
- Save it.
Now the user should be able to access the Employee Collection without errors.
Obs.: If the error occurs for other collections, the same solution of assigning access to the required view should apply.
See Also
3416303 - Error "Not Authorized: Check Authorization Restriction for the User" When Querying Activity OData Collection
Keywords
not authorized; OData collection; authorization; , KBA , LOD-CRM-INT-API , OData API (C4C Only) , How To