• Home
  • Dynatrace Managed
  • Cluster API
  • Cluster API v1
  • Password policy v1
  • Update cluster password policy

Update cluster password policy

This API call updates a cluster password policy.

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/passwordPolicy

Parameter

ParameterTypeDescriptionInRequired
bodyPasswordPolicy

The JSON body of the request. Contains parameters of password policy configuration.

bodyoptional

Request body objects

The PasswordPolicy object

Password policy configuration.

ElementTypeDescriptionRequired
minPasswordLengthinteger

Minimum password length

required
minNumberOfUppercaseCharsinteger

Minimum number of uppercase characters

required
minNumberOfLowercaseCharsinteger

Minimum number of lowercase characters

required
minNumberOfDigitsinteger

Minimum number of digits

required
minNumberOfNonAlphanumericCharsinteger

Minimum number of non-alphanumeric characters

required

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.

json
{ "minPasswordLength": 1, "minNumberOfUppercaseChars": 1, "minNumberOfLowercaseChars": 1, "minNumberOfDigits": 1, "minNumberOfNonAlphanumericChars": 1 }

Response

Response codes

CodeTypeDescription
204

Successfully updated. Response doesn't have a body.

400ErrorEnvelope

Failed. The input is invalid.

404

Realm not found

Example

In this example, you update the password policy for your managed deployment (myManaged.cluster.com). You define:

  • Minimum password length
  • Minimum number of uppercase characters
  • Minimum number of lowercase characters
  • Minimum number of digits
  • Minimum number of non-alphanumeric characters

In return you receive a response code 204 indicating that the password policy was updated successfully.

Curl

bash
curl -X PUT "https://myManaged.cluster.com/api/v1.0/onpremise/passwordPolicy" -H "accept: */*" -H "Content-Type: application/json" -d "{\"realmId\":\"string\",\"minPasswordLength\":16,\"minNumberOfUppercaseChars\":2,\"minNumberOfLowercaseChars\":4,\"minNumberOfDigits\":2,\"minNumberOfNonAlphanumericChars\":4}"

Request URL

plaintext
https://myManaged.cluster.com/api/v1.0/onpremise/passwordPolicy

Response body

Successfully updated. Response doesn't have a body.

Response code

204