Creates a database account.
Operation description
Debugging
Authorization information
The following table shows the authorization information corresponding to the API. The authorization information can be used in the Action
policy element to grant a RAM user or RAM role the permissions to call this API operation. Description:
- Operation: the value that you can use in the Action element to specify the operation on a resource.
- Access level: the access level of each operation. The levels are read, write, and list.
- Resource type: the type of the resource on which you can authorize the RAM user or the RAM role to perform the operation. Take note of the following items:
- The required resource types are displayed in bold characters.
- If the permissions cannot be granted at the resource level,
All Resources
is used in the Resource type column of the operation.
- Condition Key: the condition key that is defined by the cloud service.
- Associated operation: other operations that the RAM user or the RAM role must have permissions to perform to complete the operation. To complete the operation, the RAM user or the RAM role must have the permissions to perform the associated operations.
Operation | Access level | Resource type | Condition key | Associated operation |
---|---|---|---|---|
rds:CreateAccount | WRITE |
|
| none |
Request parameters
Parameter | Type | Required | Description | Example |
---|---|---|---|---|
DBInstanceId | string | Yes | The instance ID. You can call the DescribeDBInstances operation to query the instance ID. | rm-uf6wjk5xxxxxxx |
AccountName | string | Yes | The name of the database account.
| test1 |
AccountPassword | string | Yes | The password of the account.
| Test123456 |
AccountDescription | string | No | The description of the account. The value must be 2 to 256 characters in length. The value can contain letters, digits, underscores (_), and hyphens (-), and must start with a letter. Note
: The name cannot start with http:// or https://.
| Test Account A |
AccountType | string | No | The account type. Valid values:
Before you create a system admin account, check whether the RDS instance meets all prerequisites. For more information, see Create a system admin account. | Normal |
Response parameters
Examples
Sample success responses
JSON
format
{
"RequestId": "D4D4BE8A-DD46-440A-BFCD-EE31DA81C9DD"
}
Error codes
HTTP status code | Error code | Error message | Description |
---|---|---|---|
400 | GeneralIns.Creating | The general instance is creating. | An RDS instance is in production. Please wait. |
400 | GeneralIns.Maintaining | The general instance is maintaining. | An RDS instance is being migrated or maintained. Please wait. |
400 | GeneralIns.Switching | The general instance is Switching. | A switchover for high availability is in progress. Please wait. |
400 | InvalidEngineVersion.NotSupported | Current db instance does not support sysadmin. | The operation failed. A sysAdmin account cannot be created on the RDS instance. |
400 | Database.ConnectError | Database connect error. please check instance status and database processlist | A database connection error occurred. Check the instance state and the database connection pool. |
400 | Account.AddError | Create Account failed, please check your input value or may your input value not satisfy instance current policy | Failed to create the account. Check the specified parameters or the parameter policy configuration. |
400 | InvalidAccountPassword.Format | Specified account password is not valid. | The password of the account is invalid. Specify a valid password. |
400 | InvalidAccountDescription.Format | Specified account description is not valid. | The account description is invalid. Specify a valid description. The description can be up to 256 characters in length and cannot be left unspecified. |
400 | InvalidGeneralGroupNameOrGdnInstanceName | The specified params generalGroupName or gdnInstanceName should not be null. | - |
400 | InvalidAccountPrivilege.Malformed | Specified account privilege is not valid. | Your account does not have the required permissions. |
400 | InvalidAccountName.Forbid | Specified account name is a keyword in RDS. | The username is invalid. Forbidden keywords cannot be used for a username. Modify the username. |
400 | InvalidAccountName.Duplicate | Specified account name already exists in this instance. | The username already exists in the RDS instance. Specify a different username. |
400 | InvalidDBDescription.Format | Specified DB description is not valid. | The database description is invalid. Specify a valid description. |
400 | Order.ComboInstanceNotAllowOperate | A package instance is not allowed to operate independently. | A package instance is not allowed to operate independently. |
400 | Price.PricingPlanResultNotFound | Pricing plan price result not found. | Pricing plan price result not found. |
400 | Order.NoRealNameAuthentication | You have not passed the real-name authentication and do not meet the purchase conditions. Please log in to the user center for real-name authentication. | You have not passed the real-name authentication and do not meet the purchase conditions. Please log in to the user center for real-name authentication. |
400 | InsufficientAvailableQuota | Your account quota limit is less than 0, please recharge before trying to purchase. | Your account available limit is less than 0, please recharge before trying to purchase. |
400 | CommodityServiceCalling.Exception | Failed to call commodity service. | Failed to call commodity service return. |
400 | RegionDissolvedEOM | Dear customer, Alibaba Cloud plans to optimize and adjust the current region. Cloud services in this region will cease operations. You are currently unable to operate new purchase orders. Thank you for your understanding and support. | Hello, Alibaba Cloud plans to optimize and adjust the current region. Cloud services in this region will stop operating. In order to ensure your business continuity and smooth transition of data migration, you are currently unable to operate new purchase orders. Thank you for your understanding and support. |
400 | Commodity.InvalidComponent | The module you purchased is not legal, please buy it again. | The module you purchased is not legal, please buy it again. |
400 | RegionEndTimeDissolvedIndia | Cloud services in the India (Mumbai) region will be discontinued. Set the validity date to July 15, 2024 or earlier than July 15, 2024. | Cloud services in the India (Mumbai) region will be discontinued. Set the validity date to July 15, 2024 or earlier than July 15, 2024. |
400 | RegionEndTimeDissolvedAustralia | Cloud services in the Australia (Sydney) region will be discontinued. Set the validity date to September 30, 2024 or earlier than September 30, 2024. | Cloud services in the Australia (Sydney) region will be discontinued. Set the validity date to September 30, 2024 or earlier than September 30, 2024. |
400 | Price.CommoditySys | Commodity system call exception. | Commodity system call exception. |
400 | Pay.InsufficientBalance | Insufficient available balance. | Insufficient available balance. |
400 | Order.PeriodInvalid | There is a problem with the period you selected, please choose again. | There is a problem with the period you selected, please choose again. |
400 | pay.noCreditCard | Account not bound to credit card. | - |
400 | Order.InstHasUnpaidOrder | There is an unpaid order for the service you have purchased. Please pay or void it before placing the order. | There is an unpaid order for the service you have purchased. Please pay or void it before placing the order. |
400 | noAvailablePaymentMethod | No payment method is specified for your account. We recommend that you add a payment method. | - |
400 | BasicInfoUncompleted | Your information is incomplete. Complete your information before the operation. | Your basic information is not complete, please complete your basic information before operation. |
403 | IncorrectDBInstanceState | Current DB instance state does not support this operation. | - |
403 | IncorrectAccountType | Current account type does not support this operation. | This operation is not supported for the current account type. Check the account type. |
403 | AccountLimitExceeded | AccountQuotaExceeded: Exceeding the allowed amount of account | The number of accounts exceeds the maximum number of accounts that are allowed. |
404 | InvalidDBInstanceName.NotFound | The database instance does not exist. | The name of the RDS instance cannot be found. Check the name of the RDS instance. |
404 | IncorrectDBInstanceLockMode | Current DB instance lock mode does not support this operation. | The operation failed. The RDS instance is locked. |
For a list of error codes, visit the Service error codes.
Change history
Change time | Summary of changes | Operation | ||||||||
---|---|---|---|---|---|---|---|---|---|---|
2022-10-28 | The Error code has changed | see changesets | ||||||||
| ||||||||||
2022-06-23 | API Description Update. The Error code has changed | see changesets | ||||||||
| ||||||||||
2021-08-13 | The Error code has changed | see changesets | ||||||||
|