Queries the list of database access accounts under a tenant.
Try it now
Test
RAM authorization
|
Action |
Access level |
Resource type |
Condition key |
Dependent action |
|
oceanbase:DescribeTenantUsers |
get |
*All Resource
|
None | None |
Request parameters
|
Parameter |
Type |
Required |
Description |
Example |
| TenantId |
string |
Yes |
The tenant ID. |
ob2mr3oae0**** |
| SearchKey |
string |
No |
The filter keyword for fuzzy match when querying the list. |
pay |
| PageNumber |
integer |
No |
The page number of the paged query. Minimum value: 1. Default value: 1. |
1 |
| PageSize |
integer |
No |
The number of rows per page for the paged query. Maximum value: 100. Default value: 10. |
10 |
| UserName |
string |
No |
The database account name. Certain reserved keywords such as SYS and root cannot be used. |
pay_test |
Response elements
|
Element |
Type |
Description |
Example |
|
object |
The response parameters. |
||
| TotalCount |
integer |
The total number of database accounts in the tenant. |
1 |
| RequestId |
string |
The request ID. |
EE205C00-30E4-XXXX-XXXX-87E3A8A2AA0C |
| TenantUsers |
array<object> |
The list of database accounts in the tenant. |
|
|
array<object> |
The details of a database account. |
||
| UserType |
string |
The type of the database account. Valid values:
|
Normal |
| Description |
string |
The description of the database account. |
use for test |
| Databases |
array<object> |
The list of database permissions granted to the account. |
|
|
object |
The details of a database account. |
||
| Database |
string |
The name of the database (schema). |
db_pay1 |
| Role |
string |
The role granted.
For MySQL mode, roles are at the database level and include the following types:
Note
|
ReadOnly |
| Table |
string |
The name of the table. |
tbl_pay1 |
| Privileges |
string |
When a user grants custom permissions on a database, the privileges field returns the custom permission content, separated by commas (","). At all other times, the privileges field returns no data. |
select,delete,update |
| UserStatus |
string |
The status of the database account. Valid values:
|
ONLINE |
| UserName |
string |
The database account name. |
pay_test |
| TenantId |
string |
The ID of the tenant to which the account belongs. |
t4pnum**** |
| InstanceId |
string |
The ID of the cluster to which the account belongs. |
obshc32**** |
| GlobalPermissions |
string |
The global permission information. |
Encrypt,Decrypt |
Examples
Success response
JSON format
{
"TotalCount": 1,
"RequestId": "EE205C00-30E4-XXXX-XXXX-87E3A8A2AA0C",
"TenantUsers": [
{
"UserType": "Normal",
"Description": "use for test",
"Databases": [
{
"Database": "db_pay1",
"Role": "ReadOnly",
"Table": "tbl_pay1",
"Privileges": "select,delete,update"
}
],
"UserStatus": "ONLINE",
"UserName": "pay_test",
"TenantId": "t4pnum**** ",
"InstanceId": "obshc32****",
"GlobalPermissions": "Encrypt,Decrypt"
}
]
}
Error codes
|
HTTP status code |
Error code |
Error message |
Description |
|---|---|---|---|
| 2014 | InternalError | The request processing has failed due to some unknown error. |
See Error Codes for a complete list.
Release notes
See Release Notes for a complete list.