Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -20,8 +20,14 @@ model MongoCluster is TrackedResource<MongoClusterProperties> {
@visibility(Lifecycle.Read)
@path
name: string;

...ManagedServiceIdentityProperty;
}

@@added(MongoCluster.identity,
Microsoft.DocumentDB.Versions.v2025_07_01_preview
);

@armResourceOperations
interface MongoClusters {
/** Gets information about a mongo cluster. */
Expand Down Expand Up @@ -198,6 +204,11 @@ model MongoClusterProperties {
/** The authentication configuration for the cluster. */
@added(Versions.v2025_04_01_preview)
authConfig?: AuthConfigProperties;

/** The encryption configuration for the cluster. Depends on identity being configured. */
@added(Versions.v2025_07_01_preview)
@visibility(Lifecycle.Read, Lifecycle.Create)
encryption?: EncryptionProperties;
}

/** The mode that the Mongo Cluster is created with. */
Expand Down Expand Up @@ -553,3 +564,39 @@ union AuthenticationMode {
/** Microsoft Entra ID authentication mode using Entra users assigned to the cluster and auth mechanism 'MONGODB-OIDC'. */
"MicrosoftEntraID",
}

/** The type of identity for key encryption key. */
@added(Versions.v2025_07_01_preview)
union KeyEncryptionKeyIdentityType {
string,

/** User assigned identity. */
UserAssignedIdentity: "UserAssignedIdentity",
}

/** The encryption configuration for the mongo cluster. */
@added(Versions.v2025_07_01_preview)
model EncryptionProperties {
/** Customer managed key encryption settings. */
customerManagedKeyEncryption?: CustomerManagedKeyEncryptionProperties;
}

/** Customer managed key encryption settings. */
@added(Versions.v2025_07_01_preview)
model CustomerManagedKeyEncryptionProperties {
/** The identity used to access the key encryption key. */
keyEncryptionKeyIdentity: KeyEncryptionKeyIdentity;

/** The URI of the key vault key used for encryption. */
keyEncryptionKeyUrl: string;
}

/** The identity used for key encryption key. */
@added(Versions.v2025_07_01_preview)
model KeyEncryptionKeyIdentity {
/** The type of identity. Only 'UserAssignedIdentity' is supported. */
identityType: KeyEncryptionKeyIdentityType;

/** The user assigned identity resource id. */
userAssignedIdentityResourceId: string;
}
Original file line number Diff line number Diff line change
Expand Up @@ -121,5 +121,10 @@ union UserRole {
string,

/** Datbase owner role permissions on the target scope. */
@removed(Versions.v2025_07_01_preview)
DatabaseOwner: "dbOwner",

/** Root role permissions on the target scope. */
@added(Versions.v2025_07_01_preview)
Root: "root",
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,147 @@
{
"operationId": "MongoClusters_CreateOrUpdate",
"title": "Creates a new Mongo Cluster resource.",
"parameters": {
"subscriptionId": "ffffffff-ffff-ffff-ffff-ffffffffffff",
"resourceGroupName": "TestResourceGroup",
"mongoClusterName": "myMongoCluster",
"api-version": "2025-07-01-preview",
"resource": {
"location": "westus2",
"properties": {
"administrator": {
"userName": "mongoAdmin",
"password": "password"
},
"authConfig": {
"allowedModes": [
"NativeAuth"
]
},
"serverVersion": "5.0",
"storage": {
"sizeGb": 128
},
"compute": {
"tier": "M30"
},
"sharding": {
"shardCount": 1
},
"highAvailability": {
"targetMode": "ZoneRedundantPreferred"
}
}
}
},
"responses": {
"200": {
"body": {
"id": "/subscriptions/ffffffff-ffff-ffff-ffff-ffffffffffff/resourceGroups/TestResourceGroup/providers/Microsoft.DocumentDB/mongoClusters/myMongoCluster",
"name": "myMongoCluster",
"type": "/Microsoft.DocumentDB/mongoClusters",
"systemData": {
"createdBy": "user1",
"createdByType": "User",
"createdAt": "2020-01-01T17:18:19.1234567Z",
"lastModifiedBy": "user2",
"lastModifiedByType": "User",
"lastModifiedAt": "2020-01-02T17:18:19.1234567Z"
},
"properties": {
"provisioningState": "Succeeded",
"administrator": {
"userName": "mongoAdmin"
},
"authConfig": {
"allowedModes": [
"NativeAuth"
]
},
"serverVersion": "5.0",
"storage": {
"sizeGb": 128,
"type": "PremiumSSD"
},
"compute": {
"tier": "M30"
},
"sharding": {
"shardCount": 1
},
"highAvailability": {
"targetMode": "SameZone"
},
"backup": {
"earliestRestoreTime": "2023-01-13T20:07:35Z"
},
"previewFeatures": [],
"infrastructureVersion": "2.0",
"publicNetworkAccess": "Enabled",
"connectionString": "mongodb+srv://<user>:<password>@myMongoCluster.mongocluster.cosmos.azure.com",
"replica": {
"role": "Primary"
},
"dataApi": {
"mode": "Disabled"
}
},
"location": "westus2"
}
},
"201": {
"body": {
"id": "/subscriptions/ffffffff-ffff-ffff-ffff-ffffffffffff/resourceGroups/TestResourceGroup/providers/Microsoft.DocumentDB/mongoClusters/myMongoCluster",
"name": "myMongoCluster",
"type": "/Microsoft.DocumentDB/mongoClusters",
"systemData": {
"createdBy": "user1",
"createdByType": "User",
"createdAt": "2020-01-01T17:18:19.1234567Z",
"lastModifiedBy": "user2",
"lastModifiedByType": "User",
"lastModifiedAt": "2020-01-02T17:18:19.1234567Z"
},
"properties": {
"provisioningState": "InProgress",
"administrator": {
"userName": "mongoAdmin"
},
"authConfig": {
"allowedModes": [
"NativeAuth"
]
},
"serverVersion": "5.0",
"storage": {
"sizeGb": 128,
"type": "PremiumSSD"
},
"compute": {
"tier": "M30"
},
"sharding": {
"shardCount": 1
},
"highAvailability": {
"targetMode": "SameZone"
},
"backup": {
"earliestRestoreTime": "2023-01-13T20:07:35Z"
},
"previewFeatures": [],
"infrastructureVersion": "2.0",
"publicNetworkAccess": "Enabled",
"connectionString": "mongodb+srv://<user>:<password>@myMongoCluster.mongocluster.cosmos.azure.com",
"replica": {
"role": "Primary"
},
"dataApi": {
"mode": "Disabled"
}
},
"location": "westus2"
}
}
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,122 @@
{
"operationId": "MongoClusters_CreateOrUpdate",
"title": "Creates a replica Mongo Cluster resource from a source resource.",
"parameters": {
"subscriptionId": "ffffffff-ffff-ffff-ffff-ffffffffffff",
"resourceGroupName": "TestResourceGroup",
"mongoClusterName": "myReplicaMongoCluster",
"api-version": "2025-07-01-preview",
"resource": {
"location": "centralus",
"properties": {
"createMode": "GeoReplica",
"replicaParameters": {
"sourceResourceId": "/subscriptions/ffffffff-ffff-ffff-ffff-ffffffffffff/resourceGroups/TestResourceGroup/providers/Microsoft.DocumentDB/mongoClusters/mySourceMongoCluster",
"sourceLocation": "eastus"
}
}
}
},
"responses": {
"200": {
"body": {
"id": "/subscriptions/ffffffff-ffff-ffff-ffff-ffffffffffff/resourceGroups/TestResourceGroup/providers/Microsoft.DocumentDB/mongoClusters/myReplicaMongoCluster",
"name": "myReplicaMongoCluster",
"type": "/Microsoft.DocumentDB/mongoClusters",
"properties": {
"provisioningState": "Succeeded",
"administrator": {
"userName": "mongoAdmin"
},
"authConfig": {
"allowedModes": [
"NativeAuth"
]
},
"serverVersion": "5.0",
"storage": {
"sizeGb": 128,
"type": "PremiumSSD"
},
"compute": {
"tier": "M30"
},
"sharding": {
"shardCount": 3
},
"highAvailability": {
"targetMode": "SameZone"
},
"backup": {
"earliestRestoreTime": "2023-01-13T20:07:35Z"
},
"previewFeatures": [
"GeoReplicas"
],
"infrastructureVersion": "2.0",
"publicNetworkAccess": "Enabled",
"connectionString": "mongodb+srv://<user>:<password>@myReplicaMongoCluster.mongocluster.cosmos.azure.com",
"replica": {
"role": "GeoAsyncReplica",
"sourceResourceId": "/subscriptions/ffffffff-ffff-ffff-ffff-ffffffffffff/resourceGroups/TestResourceGroup/providers/Microsoft.DocumentDB/mongoClusters/mySourceMongoCluster",
"replicationState": "Provisioning"
},
"dataApi": {
"mode": "Disabled"
}
},
"location": "centralus"
}
},
"201": {
"body": {
"id": "/subscriptions/ffffffff-ffff-ffff-ffff-ffffffffffff/resourceGroups/TestResourceGroup/providers/Microsoft.DocumentDB/mongoClusters/myReplicaMongoCluster",
"name": "myReplicaMongoCluster",
"type": "/Microsoft.DocumentDB/mongoClusters",
"properties": {
"provisioningState": "Succeeded",
"administrator": {
"userName": "mongoAdmin"
},
"authConfig": {
"allowedModes": [
"NativeAuth"
]
},
"serverVersion": "5.0",
"storage": {
"sizeGb": 128,
"type": "PremiumSSD"
},
"compute": {
"tier": "M30"
},
"sharding": {
"shardCount": 1
},
"highAvailability": {
"targetMode": "SameZone"
},
"backup": {
"earliestRestoreTime": "2023-01-13T20:07:35Z"
},
"previewFeatures": [
"GeoReplicas"
],
"infrastructureVersion": "2.0",
"publicNetworkAccess": "Enabled",
"connectionString": "mongodb+srv://<user>:<password>@myReplicaMongoCluster.mongocluster.cosmos.azure.com",
"replica": {
"role": "GeoAsyncReplica",
"sourceResourceId": "/subscriptions/ffffffff-ffff-ffff-ffff-ffffffffffff/resourceGroups/TestResourceGroup/providers/Microsoft.DocumentDB/mongoClusters/mySourceMongoCluster",
"replicationState": "Provisioning"
},
"dataApi": {
"mode": "Disabled"
}
},
"location": "centralus"
}
}
}
}
Loading
Loading