Update management zones for user group
This page will soon be available only on the dedicated Dynatrace Managed Documentation site. Update your bookmarks.
This API call updates management zone permissions for a single user group.
Authentication
To execute this request, you need the Service Provider API (ServiceProviderAPI
) permission assigned to your API token. Generate your API token via Cluster Management Console (CMC). To learn how to obtain and use it, see Cluster API - Authentication.
Endpoint
/api/v1.0/onpremise/groups/managementZones
Parameter
Parameter | Type | Description | In | Required |
---|---|---|---|---|
body | MzPermissionsForGroup | - | body | optional |
Request body objects
The MzPermissionsForGroup
object
Element | Type | Description | Required |
---|---|---|---|
groupId | string | Group ID | optional |
mzPermissionsPerEnvironment | MzListForEnvironment[] | List of management zone permissions per environment | optional |
The MzListForEnvironment
object
Element | Type | Description | Required |
---|---|---|---|
environmentUuid | string | Environment UUID | optional |
mzPermissions | MzPermissionsList[] | List of management zone models with permissions | optional |
The MzPermissionsList
object
Element | Type | Description | Required |
---|---|---|---|
mzId | string | The ID of the required management zone | optional |
permissions | string[] | The list of permissions for the required management zone
| optional |
Request body JSON model
This is a model of the request body, showing the possible elements. It has to be adjusted for usage in an actual request.
1{2 "groupId": "string",3 "mzPermissionsPerEnvironment": [4 {5 "environmentUuid": "string",6 "mzPermissions": [7 {8 "mzId": "string",9 "permissions": [10 "DEMO_USER"11 ]12 }13 ]14 }15 ]16}
Response
Response codes
Code | Description |
---|---|
200 | Successfully updated |
400 | Provided model is incorrect or is missing required elements |
404 | A group, environment or management zone does not exist |
510 | Operation failed |
Example
In this example, you update the salesgroup
user group to assign permissions to 5c6cf54c-5fe3-47e8-af18-54439090370b
environment's
management zones.
Curl
1curl -X 'PUT' \2 'https://mymanaged.cluster.com/api/v1.0/onpremise/groups/managementZones' \3 -H 'accept: */*' \4 -H 'Authorization: Api-Token FG563.LKJHDFLKJHDFHLKJDGV.ABCDEFGHJKLMNOP' \5 -H 'Content-Type: application/json' \6 -d '{7 "groupId": "salesgroup",8 "mzPermissionsPerEnvironment": [9 {10 "environmentUuid": "5c6cf54c-5fe3-47e8-af18-54439090370b",11 "mzPermissions": [12 {13 "mzId": "-3223778520145835472",14 "permissions": [15 "REPLAY_SESSION_DATA",16 "VIEWER",17 "MANAGE_SECURITY_PROBLEMS",18 "REPLAY_SESSION_DATA_WITHOUT_MASKING"19 ]20 }21 ]22 }23 ]24}'
Request URL
1https://mymanaged.cluster.com/api/v1.0/onpremise/groups/managementZones
Response body
No response body
Response code
200