Upgrades a shared-tier cluster to a Flex or Dedicated (M10+) cluster in the specified project. To use this resource, the requesting Service Account or API Key must have the Project Cluster Manager role. Each project supports up to 25 clusters.
This endpoint can also be used to upgrade Flex clusters that were created using the Create Cluster API or former M2/M5 clusters that have been migrated to Flex clusters, using instanceSizeName to “M2” or “M5” until January 2026. This functionality will be available until January 22, 2026, after which it will only be available for M0 clusters. Please use the Upgrade Flex Cluster endpoint instead.
Unique 24-hexadecimal digit string that identifies your project. Use the /groups endpoint to retrieve all projects to which the authenticated user has access.
NOTE: Groups and projects are synonymous terms. Your group id is the same as your project id. For existing groups, your group/project id remains the same. The resource and corresponding endpoints use the term groups.
Format should match the following pattern: ^([a-f0-9]{24})$.
Flag that indicates whether Application wraps the response in an envelope JSON object. Some API clients cannot access the HTTP response headers or status code. To remediate this, set envelope=true in the query. Endpoints that return a list of results use the results object as an envelope. Application adds the status parameter to the response body.
Default value is false.
Flag that indicates whether the response body should be in the prettyprint format.
Default value is false.
Details of the shared-tier cluster upgrade in the specified project.
If reconfiguration is necessary to regain a primary due to a regional outage, submit this field alongside your topology reconfiguration to request a new regional outage resistant topology. Forced reconfigurations during an outage of the majority of electable nodes carry a risk of data loss if replicated writes (even majority committed writes) have not been replicated to the new primary node. MongoDB Atlas docs contain more information. To proceed with an operation which carries that risk, set acceptDataRisksAndForceReplicaSetReconfig to the current date. This parameter expresses its value in the ISO 8601 timestamp format in UTC.
Group of settings that configures a subset of the advanced configuration details.
Range of instance sizes to which your cluster can scale.
Flag that indicates whether the cluster can perform backups. If set to true, the cluster can perform backups. You must set this value to true for NVMe clusters. Backup uses Cloud Backups for dedicated clusters and Shared Cluster Backups for tenant clusters. If set to false, the cluster doesn't use MongoDB Cloud backups.
Settings needed to configure the MongoDB Connector for Business Intelligence for this cluster.
Configuration of nodes that comprise the cluster.
Values are REPLICASET, SHARDED, or GEOSHARDED.
Config Server Management Mode for creating or updating a sharded cluster. When configured as ATLAS_MANAGED, Atlas may automatically switch the cluster's config server type for optimal performance and savings. When configured as FIXED_TO_DEDICATED, the cluster will always use a dedicated config server.
Values are ATLAS_MANAGED or FIXED_TO_DEDICATED. Default value is ATLAS_MANAGED.
Number of hours after cluster creation that this cluster will be automatically deleted.
This field is used to derive deleteAfterDate relative to createDate.
When set to null or zero on cluster creation, the cluster will not be automatically deleted.
When set to a positive value on cluster creation, the cluster will be automatically deleted after the specified number of hours.
When updating this field on an existing (non-deleted) cluster, and this is set to null, then existing values are preserved for this & deleteAfterDate.
When updating this field on an existing (non-deleted) cluster, and this is set to zero, then deleteAfterDate is reset to null (disable auto deletion) regardless of previous configurations.
When updating this field on an existing (non-deleted) cluster, and this is set to a positive value, then createDate + deleteAfterCreationHours must be later than now else the field update is ignored and existing values are preserved for this & deleteAfterDate.
Storage capacity of instance data volumes expressed in gigabytes. Increase this number to add capacity.
This value is not configurable on M0/M2/M5 clusters.
MongoDB Cloud requires this parameter if you set replicationSpecs.
If you specify a disk size below the minimum (10 GB), this parameter defaults to the minimum disk size value.
Storage charge calculations depend on whether you choose the default value or a custom value.
The maximum value for disk storage cannot exceed 50 times the maximum RAM for the selected cluster. If you require more storage space, consider upgrading your cluster to a higher tier.
Minimum value is 10, maximum value is 4096.
Disk warming mode selection.
Values are FULLY_WARMED or VISIBLE_EARLIER. Default value is FULLY_WARMED.
Cloud service provider that manages your customer keys to provide an additional layer of encryption at rest for the cluster. To enable customer key management for encryption at rest, the cluster replicationSpecs[n].regionConfigs[m].{type}Specs.instanceSize setting must be M10 or higher and "backupEnabled" : false or omitted entirely.
Values are NONE, AWS, AZURE, or GCP.
Set this field to configure the Sharding Management Mode when creating a new Global Cluster.
When set to false, the management mode is set to Atlas-Managed Sharding. This mode fully manages the sharding of your Global Cluster and is built to provide a seamless deployment experience.
When set to true, the management mode is set to Self-Managed Sharding. This mode leaves the management of shards in your hands and is built to provide an advanced and flexible deployment experience.
This setting cannot be changed once the cluster is deployed.
Collection of key-value pairs between 1 to 255 characters in length that tag and categorize the cluster. The MongoDB Cloud console doesn't display your labels.
Cluster labels are deprecated and will be removed in a future release. We strongly recommend that you use Resource Tags instead.
Human-readable labels applied to this MongoDB Cloud component.
MongoDB employee granted access level and expiration for a cluster.
MongoDB major version of the cluster.
On creation: Choose from the available versions of MongoDB, or leave unspecified for the current recommended default in the MongoDB Cloud platform. The recommended version is a recent Long Term Support version. The default is not guaranteed to be the most recently released version throughout the entire release cycle. For versions available in a specific project, see the linked documentation or use the API endpoint for project LTS versions endpoint.
On update: Increase version only by 1 major version at a time. If the cluster is pinned to a MongoDB feature compatibility version exactly one major version below the current MongoDB version, the MongoDB version can be downgraded to the previous major version.
Version of MongoDB that the cluster runs.
Format should match the following pattern: ([\d]+\.[\d]+\.[\d]+).
Human-readable label that identifies the cluster.
Format should match the following pattern: ^[a-zA-Z0-9][a-zA-Z0-9-]*$.
Number of shards up to 50 to deploy for a sharded cluster. The resource returns 1 to indicate a replica set and values of 2 and higher to indicate a sharded cluster. The returned value equals the number of shards in the cluster.
Minimum value is 1, maximum value is 50. Default value is 1.
Flag that indicates whether the cluster is paused.
Flag that indicates whether the cluster uses continuous cloud backups.
Flag that indicates whether the M10 or higher cluster can perform Cloud Backups. If set to true, the cluster can perform backups. If this and backupEnabled are set to false, the cluster doesn't use MongoDB Cloud backups.
Set this field to configure the replica set scaling mode for your cluster.
By default, Atlas scales under WORKLOAD_TYPE. This mode allows Atlas to scale your analytics nodes in parallel to your operational nodes.
When configured as SEQUENTIAL, Atlas scales all nodes sequentially. This mode is intended for steady-state workloads and applications performing latency-sensitive secondary reads.
When configured as NODE_TYPE, Atlas scales your electable nodes in parallel with your read-only and analytics nodes. This mode is intended for large, dynamic workloads requiring frequent and timely cluster tier scaling. This is the fastest scaling strategy, but it might impact latency of workloads when performing extensive secondary reads.
Values are SEQUENTIAL, WORKLOAD_TYPE, or NODE_TYPE. Default value is WORKLOAD_TYPE.
Number of members that belong to the replica set. Each member retains a copy of your databases, providing high availability and data redundancy. Use replicationSpecs instead.
Values are 3, 5, or 7. Default value is 3.
Physical location where MongoDB Cloud provisions cluster nodes.
List of settings that configure your cluster regions.
Root Certificate Authority that MongoDB Atlas cluster uses. MongoDB Cloud supports Internet Security Research Group.
Value is ISRGROOTX1. Default value is ISRGROOTX1.
Flag that indicates whether termination protection is enabled on the cluster. If set to true, MongoDB Cloud won't delete the cluster. If set to false, MongoDB Cloud will delete the cluster.
Default value is false.
Method by which the cluster maintains the MongoDB versions. If value is CONTINUOUS, you must not specify mongoDBMajorVersion.
Values are LTS or CONTINUOUS. Default value is LTS.
atlas api clusters upgradeTenantUpgrade --help
import (
"os"
"context"
"log"
sdk "go.mongodb.org/atlas-sdk/v20230101001/admin"
)
func main() {
ctx := context.Background()
clientID := os.Getenv("MONGODB_ATLAS_CLIENT_ID")
clientSecret := os.Getenv("MONGODB_ATLAS_CLIENT_SECRET")
// See https://dochub.mongodb.org/core/atlas-go-sdk-oauth
client, err := sdk.NewClient(sdk.UseOAuthAuth(clientID, clientSecret))
if err != nil {
log.Fatalf("Error: %v", err)
}
params = &sdk.UpgradeGroupClusterTenantUpgradeApiParams{}
sdkResp, httpResp, err := client.ClustersApi.
UpgradeGroupClusterTenantUpgradeWithParams(ctx, params).
Execute()
}
curl --include --header "Authorization: Bearer ${ACCESS_TOKEN}" \
--header "Accept: application/vnd.atlas.2023-01-01+json" \
--header "Content-Type: application/json" \
-X POST "https://cloud.mongodb.com/api/atlas/v2/groups/{groupId}/clusters/tenantUpgrade" \
-d '{ <Payload> }'
curl --user "${PUBLIC_KEY}:${PRIVATE_KEY}" \
--digest --include \
--header "Accept: application/vnd.atlas.2023-01-01+json" \
--header "Content-Type: application/json" \
-X POST "https://cloud.mongodb.com/api/atlas/v2/groups/{groupId}/clusters/tenantUpgrade" \
-d '{ <Payload> }'
{
"acceptDataRisksAndForceReplicaSetReconfig": "2026-05-04T09:42:00Z",
"advancedConfiguration": {
"customOpensslCipherConfigTls12": [
"TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384"
],
"customOpensslCipherConfigTls13": [
"TLS_AES_256_GCM_SHA384"
],
"minimumEnabledTlsProtocol": "TLS1_0",
"tlsCipherConfigMode": "CUSTOM"
},
"autoScaling": {
"compute": {
"enabled": false,
"scaleDownEnabled": false
},
"diskGBEnabled": false
},
"backupEnabled": true,
"biConnector": {
"enabled": true,
"readPreference": "PRIMARY"
},
"clusterType": "REPLICASET",
"configServerManagementMode": "ATLAS_MANAGED",
"deleteAfterCreationHours": 42,
"diskSizeGB": 42.0,
"diskWarmingMode": "FULLY_WARMED",
"encryptionAtRestProvider": "NONE",
"globalClusterSelfManagedSharding": true,
"labels": [
{
"key": "string",
"value": "string"
}
],
"mongoDBEmployeeAccessGrant": {
"expirationTime": "2026-05-04T09:42:00Z",
"grantType": "CLUSTER_DATABASE_LOGS"
},
"mongoDBMajorVersion": "5.0",
"mongoDBVersion": "5.0.25",
"name": "string",
"numShards": 1,
"paused": true,
"pitEnabled": true,
"providerBackupEnabled": true,
"providerSettings": {
"providerName": "AWS",
"autoScaling": {
"compute": {
"maxInstanceSize": "M10",
"minInstanceSize": "M10"
}
},
"diskIOPS": 42,
"encryptEBSVolume": true,
"instanceSizeName": "M10",
"regionName": "US_GOV_WEST_1",
"volumeType": "STANDARD"
},
"replicaSetScalingStrategy": "WORKLOAD_TYPE",
"replicationFactor": 3,
"replicationSpec": {
"additionalProperty1": {
"analyticsNodes": 42,
"electableNodes": 0,
"priority": 42,
"readOnlyNodes": 42
},
"additionalProperty2": {
"analyticsNodes": 42,
"electableNodes": 0,
"priority": 42,
"readOnlyNodes": 42
}
},
"replicationSpecs": [
{
"id": "32b6e34b3d91647abb20e7b8",
"numShards": 1,
"regionsConfig": {
"additionalProperty1": {
"analyticsNodes": 42,
"electableNodes": 0,
"priority": 42,
"readOnlyNodes": 42
},
"additionalProperty2": {
"analyticsNodes": 42,
"electableNodes": 0,
"priority": 42,
"readOnlyNodes": 42
}
},
"zoneName": "string"
}
],
"rootCertType": "ISRGROOTX1",
"tags": [
{
"key": "string",
"value": "string"
}
],
"terminationProtectionEnabled": false,
"versionReleaseSystem": "LTS"
}
{
"acceptDataRisksAndForceReplicaSetReconfig": "2026-05-04T09:42:00Z",
"advancedConfiguration": {
"customOpensslCipherConfigTls12": [
"TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384"
],
"customOpensslCipherConfigTls13": [
"TLS_AES_256_GCM_SHA384"
],
"minimumEnabledTlsProtocol": "TLS1_0",
"tlsCipherConfigMode": "CUSTOM"
},
"autoScaling": {
"compute": {
"enabled": false,
"scaleDownEnabled": false
},
"diskGBEnabled": false
},
"backupEnabled": true,
"biConnector": {
"enabled": true,
"readPreference": "PRIMARY"
},
"clusterType": "REPLICASET",
"configServerManagementMode": "ATLAS_MANAGED",
"configServerType": "DEDICATED",
"connectionStrings": {
"awsPrivateLink": {
"additionalProperty1": "string",
"additionalProperty2": "string"
},
"awsPrivateLinkSrv": {
"additionalProperty1": "string",
"additionalProperty2": "string"
},
"private": "string",
"privateEndpoint": [
{
"connectionString": "string",
"endpoints": [
{
"endpointId": "string",
"providerName": "AWS",
"region": "string"
}
],
"srvConnectionString": "string",
"srvShardOptimizedConnectionString": "string",
"type": "MONGOD"
}
],
"privateSrv": "string",
"standard": "string",
"standardSrv": "string"
},
"createDate": "2026-05-04T09:42:00Z",
"deleteAfterCreationHours": 42,
"deleteAfterDate": "2026-05-04T09:42:00Z",
"diskSizeGB": 42.0,
"diskWarmingMode": "FULLY_WARMED",
"encryptionAtRestProvider": "NONE",
"featureCompatibilityVersion": "string",
"featureCompatibilityVersionExpirationDate": "2026-05-04T09:42:00Z",
"globalClusterSelfManagedSharding": true,
"groupId": "32b6e34b3d91647abb20e7b8",
"id": "32b6e34b3d91647abb20e7b8",
"labels": [
{
"key": "string",
"value": "string"
}
],
"links": [
{
"href": "https://cloud.mongodb.com/api/atlas",
"rel": "self"
}
],
"mongoDBEmployeeAccessGrant": {
"expirationTime": "2026-05-04T09:42:00Z",
"grantType": "CLUSTER_DATABASE_LOGS",
"links": [
{
"href": "https://cloud.mongodb.com/api/atlas",
"rel": "self"
}
]
},
"mongoDBMajorVersion": "5.0",
"mongoDBVersion": "5.0.25",
"mongoURI": "string",
"mongoURIUpdated": "2026-05-04T09:42:00Z",
"mongoURIWithOptions": "string",
"name": "string",
"numShards": 1,
"paused": true,
"pitEnabled": true,
"providerBackupEnabled": true,
"providerSettings": {
"providerName": "AWS",
"autoScaling": {
"compute": {
"maxInstanceSize": "M10",
"minInstanceSize": "M10"
}
},
"diskIOPS": 42,
"encryptEBSVolume": true,
"instanceSizeName": "M10",
"regionName": "US_GOV_WEST_1",
"volumeType": "STANDARD"
},
"replicaSetScalingStrategy": "WORKLOAD_TYPE",
"replicationFactor": 3,
"replicationSpec": {
"additionalProperty1": {
"analyticsNodes": 42,
"electableNodes": 0,
"priority": 42,
"readOnlyNodes": 42
},
"additionalProperty2": {
"analyticsNodes": 42,
"electableNodes": 0,
"priority": 42,
"readOnlyNodes": 42
}
},
"replicationSpecs": [
{
"id": "32b6e34b3d91647abb20e7b8",
"numShards": 1,
"regionsConfig": {
"additionalProperty1": {
"analyticsNodes": 42,
"electableNodes": 0,
"priority": 42,
"readOnlyNodes": 42
},
"additionalProperty2": {
"analyticsNodes": 42,
"electableNodes": 0,
"priority": 42,
"readOnlyNodes": 42
}
},
"zoneName": "string"
}
],
"rootCertType": "ISRGROOTX1",
"srvAddress": "string",
"stateName": "IDLE",
"tags": [
{
"key": "string",
"value": "string"
}
],
"terminationProtectionEnabled": false,
"versionReleaseSystem": "LTS"
}
{
"error": 400,
"detail": "(This is just an example, the exception may not be related to this endpoint) No provider AWS exists.",
"reason": "Bad Request",
"errorCode": "VALIDATION_ERROR"
}
{
"error": 401,
"detail": "(This is just an example, the exception may not be related to this endpoint)",
"reason": "Unauthorized",
"errorCode": "NOT_ORG_GROUP_CREATOR"
}
{
"error": 402,
"detail": "(This is just an example, the exception may not be related to this endpoint)",
"reason": "Payment Required",
"errorCode": "NO_PAYMENT_INFORMATION_FOUND"
}
{
"error": 403,
"detail": "(This is just an example, the exception may not be related to this endpoint)",
"reason": "Forbidden",
"errorCode": "CANNOT_CHANGE_GROUP_NAME"
}
{
"error": 404,
"detail": "(This is just an example, the exception may not be related to this endpoint) Cannot find resource AWS",
"reason": "Not Found",
"errorCode": "RESOURCE_NOT_FOUND"
}
{
"error": 409,
"detail": "(This is just an example, the exception may not be related to this endpoint) Cannot delete organization link while there is active migration in following project ids: 60c4fd418ebe251047c50554",
"reason": "Conflict",
"errorCode": "CANNOT_DELETE_ORG_ACTIVE_LIVE_MIGRATION_ATLAS_ORG_LINK"
}
{
"error": 500,
"detail": "(This is just an example, the exception may not be related to this endpoint)",
"reason": "Internal Server Error",
"errorCode": "UNEXPECTED_ERROR"
}