Microsoft.DocumentDB mongoClusters 2024-02-15-preview

Bicep resource definition

The mongoClusters resource type can be deployed with operations that target:

For a list of changed properties in each API version, see change log.

Resource format

To create a Microsoft.DocumentDB/mongoClusters resource, add the following Bicep to your template.

resource symbolicname 'Microsoft.DocumentDB/mongoClusters@2024-02-15-preview' = {
  location: 'string'
  name: 'string'
  properties: {
    administratorLogin: 'string'
    administratorLoginPassword: 'string'
    createMode: 'string'
    nodeGroupSpecs: [
      {
        diskSizeGB: int
        enableHa: bool
        kind: 'string'
        nodeCount: int
        sku: 'string'
      }
    ]
    restoreParameters: {
      pointInTimeUTC: 'string'
      sourceResourceId: 'string'
    }
    serverVersion: 'string'
  }
  tags: {
    {customized property}: 'string'
  }
}

Property values

Microsoft.DocumentDB/mongoClusters

Name Description Value
location The geo-location where the resource lives string (required)
name The resource name string

Constraints:
Min length = 3
Max length = 3
Pattern = ^[a-z0-9]+(-[a-z0-9]+)* (required)
properties Properties of the mongo cluster. MongoClusterProperties
tags Resource tags Dictionary of tag names and values. See Tags in templates

MongoClusterProperties

Name Description Value
administratorLogin The administrator's login for the mongo cluster. string
administratorLoginPassword The password of the administrator login. string

Constraints:
Sensitive value. Pass in as a secure parameter.
createMode The mode to create a mongo cluster. 'Default'
'PointInTimeRestore'
'Restore'
nodeGroupSpecs The list of node group specs in the cluster. NodeGroupSpec[]
restoreParameters Parameters used for restore operations MongoClusterRestoreParameters
serverVersion The Mongo DB server version. Defaults to the latest available version if not specified. string

MongoClusterRestoreParameters

Name Description Value
pointInTimeUTC UTC point in time to restore a mongo cluster string
sourceResourceId Resource ID to locate the source cluster to restore string

NodeGroupSpec

Name Description Value
diskSizeGB The disk storage size for the node group in GB. Example values: 128, 256, 512, 1024. int
enableHa Whether high availability is enabled on the node group. bool
kind The node type deployed in the node group. 'Shard'
nodeCount The number of nodes in the node group. int
sku The resource sku for the node group. This defines the size of CPU and memory that is provisioned for each node. Example values: 'M30', 'M40'. string

TrackedResourceTags

Name Description Value

ARM template resource definition

The mongoClusters resource type can be deployed with operations that target:

For a list of changed properties in each API version, see change log.

Resource format

To create a Microsoft.DocumentDB/mongoClusters resource, add the following JSON to your template.

{
  "type": "Microsoft.DocumentDB/mongoClusters",
  "apiVersion": "2024-02-15-preview",
  "name": "string",
  "location": "string",
  "properties": {
    "administratorLogin": "string",
    "administratorLoginPassword": "string",
    "createMode": "string",
    "nodeGroupSpecs": [
      {
        "diskSizeGB": "int",
        "enableHa": "bool",
        "kind": "string",
        "nodeCount": "int",
        "sku": "string"
      }
    ],
    "restoreParameters": {
      "pointInTimeUTC": "string",
      "sourceResourceId": "string"
    },
    "serverVersion": "string"
  },
  "tags": {
    "{customized property}": "string"
  }
}

Property values

Microsoft.DocumentDB/mongoClusters

Name Description Value
apiVersion The api version '2024-02-15-preview'
location The geo-location where the resource lives string (required)
name The resource name string

Constraints:
Min length = 3
Max length = 3
Pattern = ^[a-z0-9]+(-[a-z0-9]+)* (required)
properties Properties of the mongo cluster. MongoClusterProperties
tags Resource tags Dictionary of tag names and values. See Tags in templates
type The resource type 'Microsoft.DocumentDB/mongoClusters'

MongoClusterProperties

Name Description Value
administratorLogin The administrator's login for the mongo cluster. string
administratorLoginPassword The password of the administrator login. string

Constraints:
Sensitive value. Pass in as a secure parameter.
createMode The mode to create a mongo cluster. 'Default'
'PointInTimeRestore'
'Restore'
nodeGroupSpecs The list of node group specs in the cluster. NodeGroupSpec[]
restoreParameters Parameters used for restore operations MongoClusterRestoreParameters
serverVersion The Mongo DB server version. Defaults to the latest available version if not specified. string

MongoClusterRestoreParameters

Name Description Value
pointInTimeUTC UTC point in time to restore a mongo cluster string
sourceResourceId Resource ID to locate the source cluster to restore string

NodeGroupSpec

Name Description Value
diskSizeGB The disk storage size for the node group in GB. Example values: 128, 256, 512, 1024. int
enableHa Whether high availability is enabled on the node group. bool
kind The node type deployed in the node group. 'Shard'
nodeCount The number of nodes in the node group. int
sku The resource sku for the node group. This defines the size of CPU and memory that is provisioned for each node. Example values: 'M30', 'M40'. string

TrackedResourceTags

Name Description Value

Terraform (AzAPI provider) resource definition

The mongoClusters resource type can be deployed with operations that target:

  • Resource groups

For a list of changed properties in each API version, see change log.

Resource format

To create a Microsoft.DocumentDB/mongoClusters resource, add the following Terraform to your template.

resource "azapi_resource" "symbolicname" {
  type = "Microsoft.DocumentDB/mongoClusters@2024-02-15-preview"
  name = "string"
  location = "string"
  tags = {
    {customized property} = "string"
  }
  body = jsonencode({
    properties = {
      administratorLogin = "string"
      administratorLoginPassword = "string"
      createMode = "string"
      nodeGroupSpecs = [
        {
          diskSizeGB = int
          enableHa = bool
          kind = "string"
          nodeCount = int
          sku = "string"
        }
      ]
      restoreParameters = {
        pointInTimeUTC = "string"
        sourceResourceId = "string"
      }
      serverVersion = "string"
    }
  })
}

Property values

Microsoft.DocumentDB/mongoClusters

Name Description Value
location The geo-location where the resource lives string (required)
name The resource name string

Constraints:
Min length = 3
Max length = 3
Pattern = ^[a-z0-9]+(-[a-z0-9]+)* (required)
properties Properties of the mongo cluster. MongoClusterProperties
tags Resource tags Dictionary of tag names and values.
type The resource type "Microsoft.DocumentDB/mongoClusters@2024-02-15-preview"

MongoClusterProperties

Name Description Value
administratorLogin The administrator's login for the mongo cluster. string
administratorLoginPassword The password of the administrator login. string

Constraints:
Sensitive value. Pass in as a secure parameter.
createMode The mode to create a mongo cluster. 'Default'
'PointInTimeRestore'
'Restore'
nodeGroupSpecs The list of node group specs in the cluster. NodeGroupSpec[]
restoreParameters Parameters used for restore operations MongoClusterRestoreParameters
serverVersion The Mongo DB server version. Defaults to the latest available version if not specified. string

MongoClusterRestoreParameters

Name Description Value
pointInTimeUTC UTC point in time to restore a mongo cluster string
sourceResourceId Resource ID to locate the source cluster to restore string

NodeGroupSpec

Name Description Value
diskSizeGB The disk storage size for the node group in GB. Example values: 128, 256, 512, 1024. int
enableHa Whether high availability is enabled on the node group. bool
kind The node type deployed in the node group. 'Shard'
nodeCount The number of nodes in the node group. int
sku The resource sku for the node group. This defines the size of CPU and memory that is provisioned for each node. Example values: 'M30', 'M40'. string

TrackedResourceTags

Name Description Value