Changes the lock status of a PolarDB database account.
Try it now

RAM authorization
Action | Access level | Resource type | Condition key | Dependent action |
polardb:ModifyAccountLockState | get | *dbcluster
| None | None |
Request parameters
Parameter | Type | Required | Description | Example |
DBClusterId | string | Yes | The cluster ID. Note You can call the DescribeDBClusters operation to view information about all clusters in a region, including cluster IDs. | pc-*** |
AccountName | string | Yes | The name of the database account. | your_account_name |
AccountLockState | string | Yes | The lock status of the account. Valid values:
| Lock |
AccountPasswordValidTime | string | No | The time when the password for the database account expires. The time must be in the `yyyy-MM-dd HH:mm:ss` format. | 2026-09-17 10:00:00 |
Response elements
Element | Type | Description | Example |
object | |||
RequestId | string | The request ID. | B762E8C5-0129-51DB-80C8-******** |
Examples
Success response
JSON
format
{ "RequestId": "B762E8C5-0129-51DB-80C8-********" }
Error codes
HTTP status code | Error code | Error message | Description |
---|---|---|---|
404 | InvalidDBCluster.NotFound | The DBClusterId provided does not exist in our records. | The specified DBClusterId parameter does not exist in the current record. |
See Error Codes for a complete list.
Release notes
See Release Notes for a complete list.