published on Monday, Jun 15, 2026 by Volcengine
published on Monday, Jun 15, 2026 by Volcengine
MongoDB instance database account.
Example Usage
Example coming soon!
Example coming soon!
Example coming soon!
Example coming soon!
Example coming soon!
resources:
mongoDBAccountDemo:
type: volcenginecc:mongodb:Account
name: MongoDBAccountDemo
properties:
accountDesc: this is a test
accountName: ccapi-test
accountPassword: QWExxxxzxc
accountPrivileges:
- db_name: admin
role_name: read
- db_name: admin
role_name: userAdmin
authDb: admin
instanceId: mongo-replica-xxxxxxxx
Example coming soon!
Create Account Resource
Resources are created with functions called constructors. To learn more about declaring and configuring resources, see Resources.
Constructor syntax
new Account(name: string, args: AccountArgs, opts?: CustomResourceOptions);@overload
def Account(resource_name: str,
args: AccountArgs,
opts: Optional[ResourceOptions] = None)
@overload
def Account(resource_name: str,
opts: Optional[ResourceOptions] = None,
account_name: Optional[str] = None,
instance_id: Optional[str] = None,
account_desc: Optional[str] = None,
account_password: Optional[str] = None,
account_privileges: Optional[Sequence[AccountAccountPrivilegeArgs]] = None,
auth_db: Optional[str] = None,
reset_db_account: Optional[bool] = None)func NewAccount(ctx *Context, name string, args AccountArgs, opts ...ResourceOption) (*Account, error)public Account(string name, AccountArgs args, CustomResourceOptions? opts = null)
public Account(String name, AccountArgs args)
public Account(String name, AccountArgs args, CustomResourceOptions options)
type: volcenginecc:mongodb:Account
properties: # The arguments to resource properties.
options: # Bag of options to control resource's behavior.
resource "volcenginecc_mongodb_account" "name" {
# resource properties
}Parameters
- name string
- The unique name of the resource.
- args AccountArgs
- The arguments to resource properties.
- opts CustomResourceOptions
- Bag of options to control resource's behavior.
- resource_name str
- The unique name of the resource.
- args AccountArgs
- The arguments to resource properties.
- opts ResourceOptions
- Bag of options to control resource's behavior.
- ctx Context
- Context object for the current deployment.
- name string
- The unique name of the resource.
- args AccountArgs
- The arguments to resource properties.
- opts ResourceOption
- Bag of options to control resource's behavior.
- name string
- The unique name of the resource.
- args AccountArgs
- The arguments to resource properties.
- opts CustomResourceOptions
- Bag of options to control resource's behavior.
- name String
- The unique name of the resource.
- args AccountArgs
- The arguments to resource properties.
- options CustomResourceOptions
- Bag of options to control resource's behavior.
Constructor example
The following reference example uses placeholder values for all input properties.
var accountResource = new Volcenginecc.Mongodb.Account("accountResource", new()
{
AccountName = "string",
InstanceId = "string",
AccountDesc = "string",
AccountPassword = "string",
AccountPrivileges = new[]
{
new Volcenginecc.Mongodb.Inputs.AccountAccountPrivilegeArgs
{
DbName = "string",
RoleName = "string",
},
},
AuthDb = "string",
ResetDbAccount = false,
});
example, err := mongodb.NewAccount(ctx, "accountResource", &mongodb.AccountArgs{
AccountName: pulumi.String("string"),
InstanceId: pulumi.String("string"),
AccountDesc: pulumi.String("string"),
AccountPassword: pulumi.String("string"),
AccountPrivileges: mongodb.AccountAccountPrivilegeArray{
&mongodb.AccountAccountPrivilegeArgs{
DbName: pulumi.String("string"),
RoleName: pulumi.String("string"),
},
},
AuthDb: pulumi.String("string"),
ResetDbAccount: pulumi.Bool(false),
})
resource "volcenginecc_mongodb_account" "accountResource" {
account_name = "string"
instance_id = "string"
account_desc = "string"
account_password = "string"
account_privileges {
db_name = "string"
role_name = "string"
}
auth_db = "string"
reset_db_account = false
}
var accountResource = new com.volcengine.volcenginecc.mongodb.Account("accountResource", com.volcengine.volcenginecc.mongodb.AccountArgs.builder()
.accountName("string")
.instanceId("string")
.accountDesc("string")
.accountPassword("string")
.accountPrivileges(AccountAccountPrivilegeArgs.builder()
.dbName("string")
.roleName("string")
.build())
.authDb("string")
.resetDbAccount(false)
.build());
account_resource = volcenginecc.mongodb.Account("accountResource",
account_name="string",
instance_id="string",
account_desc="string",
account_password="string",
account_privileges=[{
"db_name": "string",
"role_name": "string",
}],
auth_db="string",
reset_db_account=False)
const accountResource = new volcenginecc.mongodb.Account("accountResource", {
accountName: "string",
instanceId: "string",
accountDesc: "string",
accountPassword: "string",
accountPrivileges: [{
dbName: "string",
roleName: "string",
}],
authDb: "string",
resetDbAccount: false,
});
type: volcenginecc:mongodb:Account
properties:
accountDesc: string
accountName: string
accountPassword: string
accountPrivileges:
- dbName: string
roleName: string
authDb: string
instanceId: string
resetDbAccount: false
Account Resource Properties
To learn more about resource properties and how to use them, see Inputs and Outputs in the Architecture and Concepts docs.
Inputs
In Python, inputs that are objects can be passed either as argument classes or as dictionary literals.
The Account resource accepts the following input properties:
- Account
Name string - Account name.
- Instance
Id string - Instance ID.
- Account
Desc string - Account remarks.
- Account
Password string - Account password.
- Account
Privileges List<Volcengine.Account Account Privilege> - Auth
Db string - Database associated with the account.
- Reset
Db boolAccount - Whether to reset the root account permissions to the initial state (that is, restore all permissions that can be granted to the super administrator account). Value options: false (default): Do not reset. true: Reset. Note: This parameter only applies to the root account in the admin database (that is, AuthDB is admin and AccountName is root).
- Account
Name string - Account name.
- Instance
Id string - Instance ID.
- Account
Desc string - Account remarks.
- Account
Password string - Account password.
- Account
Privileges []AccountAccount Privilege Args - Auth
Db string - Database associated with the account.
- Reset
Db boolAccount - Whether to reset the root account permissions to the initial state (that is, restore all permissions that can be granted to the super administrator account). Value options: false (default): Do not reset. true: Reset. Note: This parameter only applies to the root account in the admin database (that is, AuthDB is admin and AccountName is root).
- account_
name string - Account name.
- instance_
id string - Instance ID.
- account_
desc string - Account remarks.
- account_
password string - Account password.
- account_
privileges list(object) - auth_
db string - Database associated with the account.
- reset_
db_ boolaccount - Whether to reset the root account permissions to the initial state (that is, restore all permissions that can be granted to the super administrator account). Value options: false (default): Do not reset. true: Reset. Note: This parameter only applies to the root account in the admin database (that is, AuthDB is admin and AccountName is root).
- account
Name String - Account name.
- instance
Id String - Instance ID.
- account
Desc String - Account remarks.
- account
Password String - Account password.
- account
Privileges List<AccountAccount Privilege> - auth
Db String - Database associated with the account.
- reset
Db BooleanAccount - Whether to reset the root account permissions to the initial state (that is, restore all permissions that can be granted to the super administrator account). Value options: false (default): Do not reset. true: Reset. Note: This parameter only applies to the root account in the admin database (that is, AuthDB is admin and AccountName is root).
- account
Name string - Account name.
- instance
Id string - Instance ID.
- account
Desc string - Account remarks.
- account
Password string - Account password.
- account
Privileges AccountAccount Privilege[] - auth
Db string - Database associated with the account.
- reset
Db booleanAccount - Whether to reset the root account permissions to the initial state (that is, restore all permissions that can be granted to the super administrator account). Value options: false (default): Do not reset. true: Reset. Note: This parameter only applies to the root account in the admin database (that is, AuthDB is admin and AccountName is root).
- account_
name str - Account name.
- instance_
id str - Instance ID.
- account_
desc str - Account remarks.
- account_
password str - Account password.
- account_
privileges Sequence[AccountAccount Privilege Args] - auth_
db str - Database associated with the account.
- reset_
db_ boolaccount - Whether to reset the root account permissions to the initial state (that is, restore all permissions that can be granted to the super administrator account). Value options: false (default): Do not reset. true: Reset. Note: This parameter only applies to the root account in the admin database (that is, AuthDB is admin and AccountName is root).
- account
Name String - Account name.
- instance
Id String - Instance ID.
- account
Desc String - Account remarks.
- account
Password String - Account password.
- account
Privileges List<Property Map> - auth
Db String - Database associated with the account.
- reset
Db BooleanAccount - Whether to reset the root account permissions to the initial state (that is, restore all permissions that can be granted to the super administrator account). Value options: false (default): Do not reset. true: Reset. Note: This parameter only applies to the root account in the admin database (that is, AuthDB is admin and AccountName is root).
Outputs
All input properties are implicitly available as output properties. Additionally, the Account resource produces the following output properties:
- Account
Type string - Account type. Value options: Super: Super administrator account, that is, root account; UserAdmin: High-privilege account, that is, an account with any permissions on the admin database; Normal: Regular account, that is, an account with no permissions on the admin database.
- Create
Time string - Account creation time. Format: yyyy-MM-ddTHH:mm:ssZ (UTC).
- Id string
- The provider-assigned unique ID for this managed resource.
- Modify
Time string - Last update time of the account. Format: yyyy-MM-ddTHH:mm:ssZ (UTC).
- Account
Type string - Account type. Value options: Super: Super administrator account, that is, root account; UserAdmin: High-privilege account, that is, an account with any permissions on the admin database; Normal: Regular account, that is, an account with no permissions on the admin database.
- Create
Time string - Account creation time. Format: yyyy-MM-ddTHH:mm:ssZ (UTC).
- Id string
- The provider-assigned unique ID for this managed resource.
- Modify
Time string - Last update time of the account. Format: yyyy-MM-ddTHH:mm:ssZ (UTC).
- account_
type string - Account type. Value options: Super: Super administrator account, that is, root account; UserAdmin: High-privilege account, that is, an account with any permissions on the admin database; Normal: Regular account, that is, an account with no permissions on the admin database.
- create_
time string - Account creation time. Format: yyyy-MM-ddTHH:mm:ssZ (UTC).
- id string
- The provider-assigned unique ID for this managed resource.
- modify_
time string - Last update time of the account. Format: yyyy-MM-ddTHH:mm:ssZ (UTC).
- account
Type String - Account type. Value options: Super: Super administrator account, that is, root account; UserAdmin: High-privilege account, that is, an account with any permissions on the admin database; Normal: Regular account, that is, an account with no permissions on the admin database.
- create
Time String - Account creation time. Format: yyyy-MM-ddTHH:mm:ssZ (UTC).
- id String
- The provider-assigned unique ID for this managed resource.
- modify
Time String - Last update time of the account. Format: yyyy-MM-ddTHH:mm:ssZ (UTC).
- account
Type string - Account type. Value options: Super: Super administrator account, that is, root account; UserAdmin: High-privilege account, that is, an account with any permissions on the admin database; Normal: Regular account, that is, an account with no permissions on the admin database.
- create
Time string - Account creation time. Format: yyyy-MM-ddTHH:mm:ssZ (UTC).
- id string
- The provider-assigned unique ID for this managed resource.
- modify
Time string - Last update time of the account. Format: yyyy-MM-ddTHH:mm:ssZ (UTC).
- account_
type str - Account type. Value options: Super: Super administrator account, that is, root account; UserAdmin: High-privilege account, that is, an account with any permissions on the admin database; Normal: Regular account, that is, an account with no permissions on the admin database.
- create_
time str - Account creation time. Format: yyyy-MM-ddTHH:mm:ssZ (UTC).
- id str
- The provider-assigned unique ID for this managed resource.
- modify_
time str - Last update time of the account. Format: yyyy-MM-ddTHH:mm:ssZ (UTC).
- account
Type String - Account type. Value options: Super: Super administrator account, that is, root account; UserAdmin: High-privilege account, that is, an account with any permissions on the admin database; Normal: Regular account, that is, an account with no permissions on the admin database.
- create
Time String - Account creation time. Format: yyyy-MM-ddTHH:mm:ssZ (UTC).
- id String
- The provider-assigned unique ID for this managed resource.
- modify
Time String - Last update time of the account. Format: yyyy-MM-ddTHH:mm:ssZ (UTC).
Look up Existing Account Resource
Get an existing Account resource’s state with the given name, ID, and optional extra properties used to qualify the lookup.
public static get(name: string, id: Input<ID>, state?: AccountState, opts?: CustomResourceOptions): Account@staticmethod
def get(resource_name: str,
id: str,
opts: Optional[ResourceOptions] = None,
account_desc: Optional[str] = None,
account_name: Optional[str] = None,
account_password: Optional[str] = None,
account_privileges: Optional[Sequence[AccountAccountPrivilegeArgs]] = None,
account_type: Optional[str] = None,
auth_db: Optional[str] = None,
create_time: Optional[str] = None,
instance_id: Optional[str] = None,
modify_time: Optional[str] = None,
reset_db_account: Optional[bool] = None) -> Accountfunc GetAccount(ctx *Context, name string, id IDInput, state *AccountState, opts ...ResourceOption) (*Account, error)public static Account Get(string name, Input<string> id, AccountState? state, CustomResourceOptions? opts = null)public static Account get(String name, Output<String> id, AccountState state, CustomResourceOptions options)resources: _: type: volcenginecc:mongodb:Account get: id: ${id}import {
to = volcenginecc_mongodb_account.example
id = "${id}"
}
- name
- The unique name of the resulting resource.
- id
- The unique provider ID of the resource to lookup.
- state
- Any extra arguments used during the lookup.
- opts
- A bag of options that control this resource's behavior.
- resource_name
- The unique name of the resulting resource.
- id
- The unique provider ID of the resource to lookup.
- name
- The unique name of the resulting resource.
- id
- The unique provider ID of the resource to lookup.
- state
- Any extra arguments used during the lookup.
- opts
- A bag of options that control this resource's behavior.
- name
- The unique name of the resulting resource.
- id
- The unique provider ID of the resource to lookup.
- state
- Any extra arguments used during the lookup.
- opts
- A bag of options that control this resource's behavior.
- name
- The unique name of the resulting resource.
- id
- The unique provider ID of the resource to lookup.
- state
- Any extra arguments used during the lookup.
- opts
- A bag of options that control this resource's behavior.
- Account
Desc string - Account remarks.
- Account
Name string - Account name.
- Account
Password string - Account password.
- Account
Privileges List<Volcengine.Account Account Privilege> - Account
Type string - Account type. Value options: Super: Super administrator account, that is, root account; UserAdmin: High-privilege account, that is, an account with any permissions on the admin database; Normal: Regular account, that is, an account with no permissions on the admin database.
- Auth
Db string - Database associated with the account.
- Create
Time string - Account creation time. Format: yyyy-MM-ddTHH:mm:ssZ (UTC).
- Instance
Id string - Instance ID.
- Modify
Time string - Last update time of the account. Format: yyyy-MM-ddTHH:mm:ssZ (UTC).
- Reset
Db boolAccount - Whether to reset the root account permissions to the initial state (that is, restore all permissions that can be granted to the super administrator account). Value options: false (default): Do not reset. true: Reset. Note: This parameter only applies to the root account in the admin database (that is, AuthDB is admin and AccountName is root).
- Account
Desc string - Account remarks.
- Account
Name string - Account name.
- Account
Password string - Account password.
- Account
Privileges []AccountAccount Privilege Args - Account
Type string - Account type. Value options: Super: Super administrator account, that is, root account; UserAdmin: High-privilege account, that is, an account with any permissions on the admin database; Normal: Regular account, that is, an account with no permissions on the admin database.
- Auth
Db string - Database associated with the account.
- Create
Time string - Account creation time. Format: yyyy-MM-ddTHH:mm:ssZ (UTC).
- Instance
Id string - Instance ID.
- Modify
Time string - Last update time of the account. Format: yyyy-MM-ddTHH:mm:ssZ (UTC).
- Reset
Db boolAccount - Whether to reset the root account permissions to the initial state (that is, restore all permissions that can be granted to the super administrator account). Value options: false (default): Do not reset. true: Reset. Note: This parameter only applies to the root account in the admin database (that is, AuthDB is admin and AccountName is root).
- account_
desc string - Account remarks.
- account_
name string - Account name.
- account_
password string - Account password.
- account_
privileges list(object) - account_
type string - Account type. Value options: Super: Super administrator account, that is, root account; UserAdmin: High-privilege account, that is, an account with any permissions on the admin database; Normal: Regular account, that is, an account with no permissions on the admin database.
- auth_
db string - Database associated with the account.
- create_
time string - Account creation time. Format: yyyy-MM-ddTHH:mm:ssZ (UTC).
- instance_
id string - Instance ID.
- modify_
time string - Last update time of the account. Format: yyyy-MM-ddTHH:mm:ssZ (UTC).
- reset_
db_ boolaccount - Whether to reset the root account permissions to the initial state (that is, restore all permissions that can be granted to the super administrator account). Value options: false (default): Do not reset. true: Reset. Note: This parameter only applies to the root account in the admin database (that is, AuthDB is admin and AccountName is root).
- account
Desc String - Account remarks.
- account
Name String - Account name.
- account
Password String - Account password.
- account
Privileges List<AccountAccount Privilege> - account
Type String - Account type. Value options: Super: Super administrator account, that is, root account; UserAdmin: High-privilege account, that is, an account with any permissions on the admin database; Normal: Regular account, that is, an account with no permissions on the admin database.
- auth
Db String - Database associated with the account.
- create
Time String - Account creation time. Format: yyyy-MM-ddTHH:mm:ssZ (UTC).
- instance
Id String - Instance ID.
- modify
Time String - Last update time of the account. Format: yyyy-MM-ddTHH:mm:ssZ (UTC).
- reset
Db BooleanAccount - Whether to reset the root account permissions to the initial state (that is, restore all permissions that can be granted to the super administrator account). Value options: false (default): Do not reset. true: Reset. Note: This parameter only applies to the root account in the admin database (that is, AuthDB is admin and AccountName is root).
- account
Desc string - Account remarks.
- account
Name string - Account name.
- account
Password string - Account password.
- account
Privileges AccountAccount Privilege[] - account
Type string - Account type. Value options: Super: Super administrator account, that is, root account; UserAdmin: High-privilege account, that is, an account with any permissions on the admin database; Normal: Regular account, that is, an account with no permissions on the admin database.
- auth
Db string - Database associated with the account.
- create
Time string - Account creation time. Format: yyyy-MM-ddTHH:mm:ssZ (UTC).
- instance
Id string - Instance ID.
- modify
Time string - Last update time of the account. Format: yyyy-MM-ddTHH:mm:ssZ (UTC).
- reset
Db booleanAccount - Whether to reset the root account permissions to the initial state (that is, restore all permissions that can be granted to the super administrator account). Value options: false (default): Do not reset. true: Reset. Note: This parameter only applies to the root account in the admin database (that is, AuthDB is admin and AccountName is root).
- account_
desc str - Account remarks.
- account_
name str - Account name.
- account_
password str - Account password.
- account_
privileges Sequence[AccountAccount Privilege Args] - account_
type str - Account type. Value options: Super: Super administrator account, that is, root account; UserAdmin: High-privilege account, that is, an account with any permissions on the admin database; Normal: Regular account, that is, an account with no permissions on the admin database.
- auth_
db str - Database associated with the account.
- create_
time str - Account creation time. Format: yyyy-MM-ddTHH:mm:ssZ (UTC).
- instance_
id str - Instance ID.
- modify_
time str - Last update time of the account. Format: yyyy-MM-ddTHH:mm:ssZ (UTC).
- reset_
db_ boolaccount - Whether to reset the root account permissions to the initial state (that is, restore all permissions that can be granted to the super administrator account). Value options: false (default): Do not reset. true: Reset. Note: This parameter only applies to the root account in the admin database (that is, AuthDB is admin and AccountName is root).
- account
Desc String - Account remarks.
- account
Name String - Account name.
- account
Password String - Account password.
- account
Privileges List<Property Map> - account
Type String - Account type. Value options: Super: Super administrator account, that is, root account; UserAdmin: High-privilege account, that is, an account with any permissions on the admin database; Normal: Regular account, that is, an account with no permissions on the admin database.
- auth
Db String - Database associated with the account.
- create
Time String - Account creation time. Format: yyyy-MM-ddTHH:mm:ssZ (UTC).
- instance
Id String - Instance ID.
- modify
Time String - Last update time of the account. Format: yyyy-MM-ddTHH:mm:ssZ (UTC).
- reset
Db BooleanAccount - Whether to reset the root account permissions to the initial state (that is, restore all permissions that can be granted to the super administrator account). Value options: false (default): Do not reset. true: Reset. Note: This parameter only applies to the root account in the admin database (that is, AuthDB is admin and AccountName is root).
Supporting Types
AccountAccountPrivilege, AccountAccountPrivilegeArgs
Import
$ pulumi import volcenginecc:mongodb/account:Account example "instance_id|account_name"
To learn more about importing existing cloud resources, see Importing resources.
Package Details
- Repository
- volcenginecc volcengine/pulumi-volcenginecc
- License
- MPL-2.0
- Notes
- This Pulumi package is based on the
volcengineccTerraform Provider.
published on Monday, Jun 15, 2026 by Volcengine