iam.password-policy.updateSet the password policy (the whole policy)
Applies to IAM-user console passwords only. `consolePasswordsAllowed: false` turns IAM-user password sign-in off; an enforced SSO connection does too.
Request syntax
PUT /iam/api/password-policy
{
"minLength": "number",
"requireUppercase": "boolean",
"requireLowercase": "boolean",
"requireNumbers": "boolean",
"requireSymbols": "boolean",
"maxAgeDays": "number",
"lockoutThreshold": "number",
"lockoutMinutes": "number",
"maxSessionHours": "number",
"consolePasswordsAllowed": "boolean"
}Request body
minLengthRequirednumber
The fewest characters a password may have (12 by default)
Constraints: integer, 8-128
requireUppercaseRequiredboolean
A password needs an uppercase letter A–Z (true by default)
requireLowercaseRequiredboolean
A password needs a lowercase letter a–z (true by default)
requireNumbersRequiredboolean
A password needs a digit 0–9 (true by default)
requireSymbolsRequiredboolean
A password needs a character that is not a letter or digit (false by default)
maxAgeDaysRequirednumber
Days after which a password must be changed; null: never (null by default)
Constraints: integer, 1-365
May be null.
lockoutThresholdRequirednumber
Wrong passwords in a row from one address before sign-in from it is locked (5 by default)
Constraints: integer, 3-20
lockoutMinutesRequirednumber
Minutes a lockout lasts (15 by default)
Constraints: integer, 1-1440
maxSessionHoursRequirednumber
Hours a console session of an IAM user lasts before signing in again (12 by default)
Constraints: integer, 1-168
consolePasswordsAllowedRequiredboolean
false turns console password sign-in off for every IAM user of the organization (true by default)
Response
200 with the policy as stored.
A JSON response is wrapped as { "success": true, "data": … }; the CLI prints the whole body with --json.
Errors
- 400The request does not pass the schema above. The body is { "error": …, "issues": […] }, one issue per field.
- 401No credentials, or an access key that is unknown, revoked or expired.
- 403The caller's policies do not allow iam:UpdatePasswordPolicy on this resource. The body names the action and the resource, and the refusal is recorded in the audit log.
- 404The resource does not exist in your organization.
Examples
The required parameters only, with example values. Replace id and the other placeholders with your own.
dcloud iam password-policy update --min-length 1 --require-uppercase --require-lowercase --require-numbers --require-symbols --max-age-days 1 --lockout-threshold 1 --lockout-minutes 1 --max-session-hours 1 --console-passwords-allowedcurl -X PUT "https://console.platform-development.deutschecloud.app/iam/api/password-policy" \
-H "Authorization: EWS-ACCESS-KEY $ACCESS_KEY" \
-H "Content-Type: application/json" \
-d '{"minLength":1,"requireUppercase":true,"requireLowercase":true,"requireNumbers":true,"requireSymbols":true,"maxAgeDays":1,"lockoutThreshold":1,"lockoutMinutes":1,"maxSessionHours":1,"consolePasswordsAllowed":true}'Generated from the API description, the same one the API checks requests against and the CLI is built from. MCP tool: dcloud_iam_password-policy_update.