Documentation Index

Fetch the complete documentation index at: https://cli.ncloud-docs.com/llms.txt

Use this file to discover all available pages before exploring further.

getCloudMongoDbUserList

Prev Next

Available in VPC

Get the list of Cloud DB for MongoDB instance DB users.

Syntax

The getCloudMongoDbUserList syntax is as follows:

./ncloud vmongodb getCloudMongoDbUserList \
    --cloudMongoDbInstanceNo <instance-no> \
    [--regionCode <KR|SGN|JPN>] \
    [--output <json|xml>]

Options

This section describes the options available when running getCloudMongoDbUserList.

Required options

The following options are required for getCloudMongoDbUserList.

Options Type Required Description
--cloudMongoDbInstanceNo String Required Instance number of Cloud DB for MongoDB

Common options

For information about the options common to all vmongodb subcommands, see Cloud DB for MongoDB (VPC) options.

Examples

If the request to retrieve the list of DB users is successful, each user's account information is returned.

Command

The command example is as follows:

./ncloud vmongodb getCloudMongoDbUserList \
    --cloudMongoDbInstanceNo 34567890 \
    --regionCode KR \
    --output json

Output

The output example is as follows:

{
  "getCloudMongoDbUserListResponse": {
    "totalRows": 2,
    "cloudMongoDbUserList": [
      {
        "userName": "testuser2",
        "databaseName": "testdb2",
        "authority": "READ_WRITE"
      },
      {
        "userName": "testuser1",
        "databaseName": "testdb1",
        "authority": "READ"
      }
    ],
    "requestId": "b2c3d4e5-f6a7-8901-bcde-f23456789012",
    "returnCode": "0",
    "returnMessage": "success"
  }
}