RemovePermissionsRequest

Removes permissions from the users' set of permissions for a specified repository node or resource. When you remove permissions, the specified permissions are removed from the existing set of permissions. This is the easiest way to restrict a user from accessing a particular resource. By removing the read permission for a user for a particular repository node or resource, they cannot be accessed by that user.

Parameters

The following parameters are used:

Parameter Example Description
action RemovePermissionsRequest

Specifies the method name to remove permissions for a user.

UserName user1

Specifies the user to remove permissions.

ResourcePath /Samples/NamedTables/WorldTable

Specifies the specific repository node (directory) or resource to remove the permissions. The resources specified in resourcePath are listed from the top level of the repository http://<server>:<port>/RepositoryService/repository/default/.

Permissions read

Specifies the permissions. By removing the read permission, a user would no longer have access to a resource. There are five valid permission types: read, all, add, modify, and remove.

Recursive false

Specifies if this operation should be performed recursively on all child nodes of the given node in the repository. The default for recursive permission setting is false. If setting permissions on individual resources in the repository, the Recursive option will have no effect.

Example

The following example removes the read permission for user1 on the WorldTable resource.


<?xml version="1.0"?>  
<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/"
xmlns:v1="http://www.mapinfo.com/midev/service/usermanagement/v1">  
   <soapenv:Header/>  
   <soapenv:Body>  
      <v1:RemovePermissionsRequest>  
         <v1:UserName>user1</v1:UserName>  
         <v1:ResourcePath>/Samples/NamedTables/WorldTable</v1:ResourcePath>  
         <v1:Permissions>  
            <v1:Permission>read</v1:Permission>  
         </v1:Permissions>  
         <v1:Recursive>false</v1:Recursive>  
      </v1:RemovePermissionsRequest>  
   </soapenv:Body>  
</soapenv:Envelope>