调用DescribeAccounts接口查询集群的账号信息。
调试
您可以在OpenAPI Explorer中直接运行该接口,免去您计算签名的困扰。运行成功后,OpenAPI Explorer可以自动生成SDK代码示例。
请求参数
名称 | 类型 | 是否必选 | 示例值 | 描述 |
---|---|---|---|---|
Action | String | 是 | DescribeAccounts |
系统规定参数,取值: DescribeAccounts。 |
DBClusterId | String | 是 | rm-uf6wjk5xxxxxxxxxx |
实例ID。 |
AccountName | String | 否 | test_accout |
数据库账号名。 |
AccountType | String | 否 | Normal |
|
返回数据
名称 | 类型 | 示例值 | 描述 |
---|---|---|---|
AccountList | Array of DBAccount |
数据库账号列表。 |
|
DBAccount | |||
AccountDescription | String | 测试数据库账号 |
账号备注。 |
AccountName | String | test1 |
账号名。 |
AccountStatus | String | Available |
账号状态。
|
AccountType | String | Normal |
|
RequestId | String | 64E37E6F-C363-41F3-867A-70EF5DC60EA4 |
请求ID。 |
示例
请求示例
http(s)://[Endpoint]/?Action=DescribeAccounts
&DBClusterId=rm-uf6wjk5xxxxxxxxxx
&<公共请求参数>
正常返回示例
XML
格式
<RequestId>64E37E6F-C363-41F3-867A-70EF5DC60EA4</RequestId>
<AccountList>
<DBAccount>
<AccountDescription>测试数据库账号</AccountDescription>
<AccountStatus>Available</AccountStatus>
<AccountType>Normal</AccountType>
<AccountName>test1</AccountName>
</DBAccount>
</AccountList>
JSON
格式
{
"RequestId":"64E37E6F-C363-41F3-867A-70EF5DC60EA4",
"AccountList":{
"DBAccount":[
{
"AccountDescription":"测试数据库账号",
"AccountStatus":"Available",
"AccountType":"Normal",
"AccountName":"test1"
}
]
}
}
错误码
HttpCode | 错误码 | 错误信息 | 描述 |
---|---|---|---|
404 | InvalidDBCluster.NotFound | The DBClusterId provided does not exist in our records. | 您指定的 DBClusterId 不存在,请确认 DBClusterId 值是否正确。 |
访问错误中心查看更多错误码。
在文档使用中是否遇到以下问题
更多建议
匿名提交