Support Article
Pega API users\logout method returns "Insufficient privilege"
Summary
Attempting to use the Pega API users method to logout a user fails with "Insufficient privilege" message. Other methods are working as expected.
Error Messages
When I using the API to log someone out "Response Code: 401"
2017-10-31 09:05:50,717 [ WebContainer : 7] [ STANDARD] [ ] [ PegaRULES:07.10] ( internal.services.ServiceAPI) ERROR pvm00082.unix.corp|xxx.xxx.xxx.xxx|Rest|api|v1|users|A0EE4412D9C2A6FBB7E099B901344E511 - Rest service [api][v1][users] failed:Authentication failed
The fiddler trace shows the following:
WWW-Authenticate: Basic realm="xxxxxxxxx-xxxxx.xxxxxx.xxxx at xxxxxxxxxxxxxx"
X-Powered-By: Servlet/3.0
Date: Tue, 31 Oct 2017 12:21:24 GMT
HTTP/1.1 401 Unauthorized
Testing in Pega API Gallery:
Steps to Reproduce
Test the users/logout Pega API.
Root Cause
User's method requires the role PegaRULES:PegaAPISysAdmin. This was missing.
Resolution
In order to use the users method you need to add the extra role PegaRULES:PegaAPISysAdmin to the access group.
Published March 3, 2018 - Updated October 8, 2020
Have a question? Get answers now.
Visit the Collaboration Center to ask questions, engage in discussions, share ideas, and help others.