Managed Service for MongoDB API, gRPC: UserService.List
Retrieves the list of MongoDB User resources in the specified cluster.
gRPC request
rpc List (ListUsersRequest) returns (ListUsersResponse)
ListUsersRequest
{
"clusterId": "string",
"pageSize": "int64",
"pageToken": "string"
}
Field |
Description |
clusterId |
string Required field. ID of the cluster to list MongoDB users in. |
pageSize |
int64 The maximum number of results per page to return. If the number of available |
pageToken |
string Page token. To get the next page of results, set |
ListUsersResponse
{
"users": [
{
"name": "string",
"clusterId": "string",
"permissions": [
{
"databaseName": "string",
"roles": [
"string"
]
}
]
}
],
"nextPageToken": "string"
}
Field |
Description |
users[] |
List of MongoDB User resources. |
nextPageToken |
string This token allows you to get the next page of results for list requests. If the number of results |
User
A MongoDB User resource. For more information, see the
Developer's Guide.
Field |
Description |
name |
string Name of the MongoDB user. |
clusterId |
string ID of the MongoDB cluster the user belongs to. |
permissions[] |
Set of permissions granted to the user. |
Permission
Field |
Description |
databaseName |
string Name of the database that the permission grants access to. |
roles[] |
string MongoDB roles for the |