Remove User
POST /object/users/deactivate
Deletes the specified user and its secret keys.
Required Roles
Requires one of the following roles:
SYSTEM_ADMIN
NAMESPACE_ADMIN
Request Payload
<user_delete_param>
<user></user>
<namespace></namespace>
</user_delete_param>
{
"user": "",
"namespace": ""
}
All parameters are required unless otherwise stated.
Field |
Description |
Type |
Notes |
user_delete_param |
|
|
|
user |
User to be deleted |
String |
|
namespace |
Namespace identifier to associate with the user |
String |
|
Response Body
Response indicating Success or Failure to delete user
Examples
Request
POST https://192.168.0.0:4443/object/users/deactivate HTTP/1.1
Content-Type: application/xml
X-SDS-AUTH-TOKEN: <AUTH_TOKEN>
<?xml version="1.0" encoding="UTF-8"?>
<user_delete_param>
<user>wuser2@sanity.local</user>
</user_delete_param>
Response
HTTP/1.1 200 OK
Content-Type: application/xml
Request
POST https://192.168.0.0:4443/object/users/deactivate.json HTTP/1.1
Content-Type: application/json
X-SDS-AUTH-TOKEN: <AUTH_TOKEN>
{
"user": "wuser2@sanity.local"
}
Response
HTTP/1.1 200 OK
Content-Type: application/json
Request
cat body.txt
<?xml version="1.0" encoding="UTF-8"?>
<user_delete_param>
<user>wuser2@sanity.local</user>
</user_delete_param>
curl -H $token -H "Content-Type: application/xml" -X POST --data @body.txt https://$nodeIp:4443/object/users/deactivate
Response
HTTP/1.1 200 OK
Content-Type: application/xml