Get All Privileges
Note:
This functionality is for Dremio v16.0+ Enterprise Edition only.
This API lists all permissions that may be assigned to a user/group for an object type, or grantType
. No user or role information is provided in the API response.
Endpoint Syntax
Method and URLGET /api/v3/catalog/privileges?type={grantType}
Required Privileges
No specific privileges or account type is required to execute this API. It is available to all users.
Request Parameters
The following objects must be used in place of grantType
:
SPACE
SOURCE
FOLDER
orSCHEMA
VDS
orVIEW
PDS
orTABLE
Response Output
Response output{
"availablePrivileges": [
{
"grantType": "SPACE",
"privileges": [
"ALTER",
"ALTER_REFLECTIONS",
"MANAGE_GRANTS",
"MODIFY",
"SELECT",
"VIEW_REFLECTIONS"
]
},
{
"grantType": "SOURCE",
"privileges": [
"ALTER",
"ALTER_REFLECTIONS",
"CREATE_TABLE",
"MANAGE_GRANTS",
"MODIFY",
"SELECT",
"VIEW_REFLECTIONS"
]
},
{
"grantType": "FOLDER",
"privileges": [
"ALTER",
"ALTER_REFLECTIONS",
"CREATE_TABLE",
"SELECT",
"VIEW_REFLECTIONS"
]
},
{
"grantType": "PDS",
"privileges": [
"ALTER",
"SELECT"
]
},
{
"grantType": "VDS",
"privileges": [
"ALTER",
"SELECT"
]
}
]
}
Example: grantType is Space
The following example shows a response when the grantType
is specified as SPACE
.
{
"availablePrivileges": [
{
"grantType": "SPACE",
"privileges": [
"ALTER",
"ALTER_REFLECTIONS",
"MANAGE_GRANTS",
"MODIFY",
"SELECT",
"VIEW_REFLECTIONS"
]
}
]
}
Response Codes
200
- Success.404
- An object with theentityId
is not found.
Example Requests
Curl Request: Privileges for All Objects
Example requestcurl -X GET --location "http://localhost:9047/api/v3/grant?grantType=PROJECT" \
-H "Authorization: _dremiohrr395nv31g8k610616tucp91g" \
-H "Content-Type: application/json" \
-H "Accept: application/json"
Curl Request: Privileges for the Space Object
Example requestcurl -X GET --location "http://localhost:9047/api/v3/grant?grantType=PROJECT" \
-H "Authorization: _dremiohrr395nv31g8k610616tucp91g" \
-H "Content-Type: application/json" \
-H "Accept: application/json"
Was this page helpful?
Glad to hear it! Thank you for your feedback.
Sorry to hear that. Thank you for your feedback.