Add Dataset ACL

Overview

This operation adds the specified NamedResource.EXECUTE and Dataset.DML CREATE, MODIFY, or DELETE permissions to the specified named tables for the specified users. The EXECUTE permission is always added if CREATE, MODIFY, or DELETE are specified.

All users or roles are given permission on the specified named tables. It is not possible to specify different permissions for each user or role in a single request.

Note: When viewed in the Spectrum Management Console, EXECUTE permissions are added to the NamedResource entity override, while the CREATE, MODIFY, and DELETE are added to the Dataset.DML entity override.

ACL Authorization Flow

The user making this request will only be able to add permission on named tables within the repository folders (or subfolders) on which they have WRITE permissions.

HTTP PUT URL Format

The following format is used for HTTP PUT requests to add dataset ACL permissions:

HTTP PUT URL:  /acl/tables
PUT DATA:    {
   "users":[
      "user1"
   ],
   "roles":[
      "role1"
   ],
   "resources":[
      "/Samples/NamedTables/WorldTable"
   ],
   "permissions":[
      "EXECUTE",
      "CREATE",
      "DELETE",
      "MODIFY"
   ]
}
PUT HEADER: Content-Type:application/json

Parameters

Parameter Type Required Description
users String Yes Specifies a list of users. Required only when roles are not given in the request.
roles String Yes Specifies a list of roles. Required only when users are not given in the request.
resources String Yes Specifies a list of named tables.
permissions String Yes Specifies the permission the named table needs to be given. The permission can be one or more of EXECUTE, CREATE, DELETE, or MODIFY.

Returns

Adds the specified NamedResource.EXECUTE and DatasetDML CREATE, MODIFY, or DELETE permissions to the specified named tables for the specified users.

Example for PUT

Request URL
http://<server>:<port>/rest/Spatial/AccessControlService/acl/tables

Request Body

{
   "users":[
      "user1"
   ],
   "roles":[
      "role1"
   ],
   "resources":[
      "/Samples/NamedTables/WorldTable"
   ],
   "permissions":[
      "EXECUTE",
      "CREATE",
      "DELETE",
      "MODIFY"
   ]
}

Response

{
   "users":[
      "user1"
   ],
   "roles":[
      "role1"
   ],
   "resources":[
      "/Samples/NamedTables/WorldTable"
   ]
}