Managed Instances - Create Or Update

Creates or updates a managed instance.

PUT https://management.azure.com/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/managedInstances/{managedInstanceName}?api-version=2023-08-01

URI Parameters

Name In Required Type Description
managedInstanceName
path True

string

The name of the managed instance.

resourceGroupName
path True

string

The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

subscriptionId
path True

string

The subscription ID that identifies an Azure subscription.

api-version
query True

string

The API version to use for the request.

Request Body

Name Required Type Description
location True

string

Resource location.

identity

ResourceIdentity

The Azure Active Directory identity of the managed instance.

properties.administratorLogin

string

Administrator username for the managed instance. Can only be specified when the managed instance is being created (and is required for creation).

properties.administratorLoginPassword

string

The administrator login password (required for managed instance creation).

properties.administrators

ManagedInstanceExternalAdministrator

The Azure Active Directory administrator of the instance. This can only be used at instance create time. If used for instance update, it will be ignored or it will result in an error. For updates individual APIs will need to be used.

properties.authenticationMetadata

AuthMetadataLookupModes

The managed instance's authentication metadata lookup mode.

properties.collation

string

Collation of the managed instance.

properties.databaseFormat

ManagedInstanceDatabaseFormat

Specifies the internal format of instance databases specific to the SQL engine version.

properties.dnsZonePartner

string (arm-id)

The resource id of another managed instance whose DNS zone this managed instance will share after creation.

properties.hybridSecondaryUsage

HybridSecondaryUsage

Hybrid secondary usage. Possible values are 'Active' (default value) and 'Passive' (customer uses the secondary as Passive DR).

properties.instancePoolId

string

The Id of the instance pool this managed server belongs to.

properties.isGeneralPurposeV2

boolean

Whether or not this is a GPv2 variant of General Purpose edition.

properties.keyId

string

A CMK URI of the key to use for encryption.

properties.licenseType

ManagedInstanceLicenseType

The license type. Possible values are 'LicenseIncluded' (regular price inclusive of a new SQL license) and 'BasePrice' (discounted AHB price for bringing your own SQL licenses).

properties.maintenanceConfigurationId

string

Specifies maintenance configuration id to apply to this managed instance.

properties.managedInstanceCreateMode

ManagedServerCreateMode

Specifies the mode of database creation.

Default: Regular instance creation.

Restore: Creates an instance by restoring a set of backups to specific point in time. RestorePointInTime and SourceManagedInstanceId must be specified.

properties.minimalTlsVersion

string

Minimal TLS version. Allowed values: 'None', '1.0', '1.1', '1.2'

properties.pricingModel

PricingModel

Pricing model of Managed Instance.

properties.primaryUserAssignedIdentityId

string (arm-id)

The resource id of a user assigned identity to be used by default.

properties.proxyOverride

ManagedInstanceProxyOverride

Connection type used for connecting to the instance.

properties.publicDataEndpointEnabled

boolean

Whether or not the public data endpoint is enabled.

properties.requestedBackupStorageRedundancy

BackupStorageRedundancy

The storage account type to be used to store backups for this instance. The options are Local (LocallyRedundantStorage), Zone (ZoneRedundantStorage), Geo (GeoRedundantStorage) and GeoZone(GeoZoneRedundantStorage)

properties.restorePointInTime

string (date-time)

Specifies the point in time (ISO8601 format) of the source database that will be restored to create the new database.

properties.servicePrincipal

ServicePrincipal

The managed instance's service principal.

properties.sourceManagedInstanceId

string (arm-id)

The resource identifier of the source managed instance associated with create operation of this instance.

properties.storageIOps

integer (int32)

Storage IOps. Minimum value: 300. Maximum value: 80000. Increments of 1 IOps allowed only. Maximum value depends on the selected hardware family and number of vCores.

properties.storageSizeInGB

integer (int32)

Storage size in GB. Minimum value: 32. Maximum value: 16384. Increments of 32 GB allowed only. Maximum value depends on the selected hardware family and number of vCores.

properties.storageThroughputMBps

integer (int32)

Storage throughput MBps parameter is not supported in the instance create/update operation.

properties.subnetId

string (arm-id)

Subnet resource ID for the managed instance.

properties.timezoneId

string

Id of the timezone. Allowed values are timezones supported by Windows. Windows keeps details on supported timezones, including the id, in registry under KEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Time Zones. You can get those registry values via SQL Server by querying SELECT name AS timezone_id FROM sys.time_zone_info. List of Ids can also be obtained by executing [System.TimeZoneInfo]::GetSystemTimeZones() in PowerShell. An example of valid timezone id is "Pacific Standard Time" or "W. Europe Standard Time".

properties.vCores

integer (int32)

The number of vCores. Allowed values: 8, 16, 24, 32, 40, 64, 80.

properties.zoneRedundant

boolean

Whether or not the multi-az is enabled.

sku

Sku

Managed instance SKU. Allowed values for sku.name: GP_Gen5, GP_G8IM, GP_G8IH, BC_Gen5, BC_G8IM, BC_G8IH

tags

object

Resource tags.

Responses

Name Type Description
200 OK

ManagedInstance

Successfully updated the managed instance.

201 Created

ManagedInstance

Successfully created the managed instance.

202 Accepted

Accepted

Headers

Location: string

Other Status Codes

ErrorResponse

*** Error Responses: ***

  • 400 SubnetMissingRequiredDelegation - Selected subnet is not delegated for SQL Managed Instance.

  • 400 UnspecifiedTargetEditionAndTrueGPV2NotAllowedInCreateOfMI - Combination of unspecified target edition (sku.name/sku.tier parameters) and the value TRUE for the isGeneralPurposeV2 parameter is not allowed in the create operation.

  • 400 UnspecifiedTargetEditionAndTrueGPV2NotAllowedInUpdateOfGPV1MI - Combination of unspecified target edition (sku.name/sku.tier parameters) and the value TRUE for the isGeneralPurposeV2 parameter is not allowed in the update operation of General Purpose V1 Managed Instance.

  • 400 UnspecifiedTargetEditionAndFalseGPV2NotAllowedInUpdateOfGPV2MI - Combination of unspecified target edition (sku.name/sku.tier parameters) and the value FALSE for the isGeneralPurposeV2 parameter is not allowed in the update operation of General Purpose V2 Managed Instance.

  • 400 NameAlreadyExists - The provided name already exists.

  • 400 GPTargetEditionAndUnspecifiedGPV2NotAllowedInUpdateOFGPV2MI - Combination of General Purpose target edition (sku.name/sku.tier parameters) and unspecified value for the isGeneralPurposeV2 parameter is not allowed in the update operation of General Purpose V2 Managed Instance.

  • 400 InvalidCollation - Invalid collation.

  • 400 ProvisioningDisabled - Displays error message from resources operation authorizer as is, without changes

  • 400 BCTargetEditionAndSpecifiedGPV2ParamNotAllowedInCreateUpdateOfMI - Combination of Business Critical target edition (sku.name/sku.tier parameters) with a specified isGeneralPurposeV2 parameter is not allowed in the create/update operation.

  • 400 UnspecifiedTargetEditionAndSpecifiedGPV2ParamNotAllowedInUpdateOfBCMI - Combination of unspecified target edition (sku.name/sku.tier parameters) with a specified isGeneralPurposeV2 parameter is not allowed in the update operation of Business Critical Managed Instance.

  • 400 RegionDoesNotAllowProvisioning - The selected location is not accepting new Windows Azure SQL Database servers. This may change at a later time.

  • 400 MemorySizeInGBNotSupported - Memory size in GB parameter is not allowed in the instance create/update operation.

  • 400 MemorySizeInGBNotSupportedForSpecifiedEdition - Memory size in GB parameter is not allowed in the instance create/update operation for the specified service tier or hardware generation.

  • 400 InvalidSubnetForGPV2Edition - General Purpose v2 edition of Managed Instance is not compatible with the specified subnet. Target subnet must be either empty, or all instances in it must run with November 2022 Feature Wave.

  • 400 MemorySizeInGBInvalidLimit - The specified memory value is invalid. Please ensure the memory size in GB is within the allowable range of 28 to 870 and corresponds appropriately to the number of vCores and service tier. The available memory sizes for the selected vCores and service tier are {0}. For details around resource limits visit: https://go.microsoft.com/fwlink/?linkid=2293407

  • 400 UnableToResolveRemoteServer - The remote partner server name could not be resolved due to an invalid server name or DNS connectivity issues.

  • 400 ManagedInstanceUpdateSloGPv2PerDatabaseFileLimitExceeded - The operation could not be completed because there is at least one database whose number of files is exceeding the limit of {0} files per database on General Purpose v2 edition.

  • 400 NextGenGPNotSupportedForCmwCustomers - Next-Gen General Purpose edition of Managed Instance does not support Custom Maintenance Window.

  • 400 HkCannotSwitchToInactive - The database cannot proceed with pricing-tier update as it has memory-optimized objects. Please drop such objects and try again.

  • 400 TokenTooLong - The provided token is too long.

  • 400 ManagedInstanceFreemiumNotAvailableForInputParameters - Managed instance creation or update executed with SLO that is not allowed for freemium.

  • 400 ManagedInstanceFreemiumNotAvailableOnRegion - Creation of a freemium managed instance on a region that is not allowlisted for freemium.

  • 400 ManagementServiceSubnetMaintenanceInProgress - User tried to initiate managed instance create/update while incompatible maintenance is in progress.

  • 400 ManagedInstanceFreemiumNotAvailableForSubscription - Freemium is not enabled for this subscription type.

  • 400 ManagedInstanceInvalidEditionForInstancePool - User tried to select invalid service tier for managed instance inside an existing instance pool.

  • 400 ManagedInstanceInvalidSubnetForInstancePool - User tried to select invalid subnet for managed instance inside an existing instance pool.

  • 400 CloudLifterUnsupportedFeature - The functionality is not available on the Managed Instance at this time.

  • 400 ManagedInstanceSloUpdateFailed - SLO '{0}' operation cannot succeed as the memory usage of '{1}' exceeds the quota.

  • 400 OperationCanNotStartDueToMiLink - The '{0}' operation cannot be completed as there exists a database in a process of creation through Managed Instance link. Please wait for the link creation to complete, or delete the link, and retry the operation again.

  • 400 ManagedInstanceInvalidHardwareFamilyForInstancePool - User tried to select invalid hardware family for managed instance inside an existing instance pool.

  • 400 ManagedInstanceInvalidLicenseTypeForInstancePool - User tried to select invalid license type for managed instance inside an existing instance pool.

  • 400 ManagedInstanceLocalStorageUpdateSloDisabled - Update SLO for managed instances with local storage is not supported yet.

  • 400 ManagedInstanceUpdateSloFromVersionlessToVersionedNotAllowed - Changing the database format from '{0}' to '{1}' is not supported. Check the database format property value specified and visit https://aka.ms/sqlmidatabaseformat for more details.

  • 400 ManagedInstanceUpdateSloFromNewerToOlderVersionEditionNotAllowed - Changing the database format from '{0}' to '{1}' is not supported. Check the database format property value specified and visit https://aka.ms/sqlmidatabaseformat for more details.

  • 400 InvalidSubnetResourceId - The provided subnet resource ID for the managed instance create or update is invalid.

  • 400 ManagedInstanceUpdateSloFromVersionedToVersionlessWorkerCLNotAllowed - Changing the database format is not supported for this managed instance. Check the database format property value specified and visit https://aka.ms/sqlmi-fwnov2022 for more details.

  • 400 ManagedInstanceVersionEditionParameterNotAllowedForUsing - Specifying the database format property value is not supported at this time.

  • 400 ManagedInstanceFreemiumInvalidArchitecture - A freemium instance can not be created in the specified subnet '(0)'.

  • 400 ManagedInstanceWithGeoDRMoveToInstancePoolNotAllowed - Customer has attempted to move a standalone Managed Instance with an existing auto-failover group configured into an instance pool, which is not supported. Only standalone instances without existing auto-failover groups configured can be moved to instance pools.

  • 400 ManagedInstanceZoneRedudantFeatureTemporarilyDisabledPerRegion - Creation of ZoneRedundant SQL MI is temporarily disabled on this region. You can create Zone Redundant SQL Managed Instances in many other regions in Azure. https://learn.microsoft.com/en-us/azure/azure-sql/managed-instance/high-availability-sla?view=azuresql-mi#zone-redundant-availability.

  • 400 VnetInWrongRegion - Virtual network is in wrong region.

  • 400 ManagedInstanceZoneRedudantFeatureTemporarilyDisabledPerHardwareGeneration - Creation of ZoneRedundant SQL MI is temporarily disabled for this hardware generation on this region. You can create Zone Redundant SQL Managed Instances with different hardware generation on this region or many other regions in Azure. https://learn.microsoft.com/en-us/azure/azure-sql/managed-instance/high-availability-sla?view=azuresql-mi#zone-redundant-availability.

  • 400 AlterDbDeactivatedNotSupported - Database Operation failed for Server '{0}', Database '{1}' due to unexpected delay. Please try again.

  • 400 ManagedInstanceUpdateSloGeoPrimaryWithNewerVersionEditionThanSecondary - Database format change must be performed on the secondary instance of the failover group first. See https://go.microsoft.com/fwlink/?linkid=2251601 for more details.

  • 400 ManagedInstanceFreemiumInstanceAlreadyExists - Only one free SQL Managed Instance is allowed per subscription.

  • 400 ManagementServiceGeodrSecondaryDatabaseInCreation - The '{0}' operation cannot be completed as there exists a database in a process of creation through failover group deployment. Please wait for the failover group deployment to complete, or alternatively delete the failover group and retry the operation again.

  • 400 VnetAddressRangeError - Virtual network address range is invalid.

  • 400 RegionDoesNotSupportVersion - A user attempted to create a server of a specified version in a location where that server version isn't supported.

  • 400 ManagedInstanceConversionRegularToFreemiumNotAllowed - User tried converting a Regular SQL Managed Instance to Free SQL Managed Instance.

  • 400 ManagedInstanceConversionFreemiumToRegularAndUpdateSLOWhileStoppedNotAllowed - User tried converting a Free SQL Managed Instance to Regular SQL Managed Instance and Update SLO in same request, while Instance is stopped.

  • 400 ManagedInstanceMaintenanceWindowChangeNotAllowedWhenInInstancePool - Maintenance window is set at instance pool level and cannot be set individually per pooled instance.

  • 400 ManagedInstanceMoveToInstancePoolExceedsDbCountLimit - Cannot move the instance into the pool due to pool database count limit.

  • 400 ManagedInstancePoolZoneRedundancyNotSupported - Cannot move a zone-redundant instance into the pool as zone-redundancy is not supported in pools.

  • 400 VnetConfigIsNotAllowed - Virtual network configuration is not allowed.

  • 400 DeploymentIntoPrivateSubnetsNotAllowed - Deploying managed instances and instance pools into private subnets is not supported.

  • 400 ManagedInstanceDeprecatedMinimalTlsVersionLowerThan12DuringCreateUpdate - Operation '{0}' could not be completed because the minimum TLS version required is 1.2 or higher. Earlier versions of TLS are no longer supported as they are considered deprecated.

  • 400 InstanceFailoverGroupDoesNotExist - Failover group does not exist on a server.

  • 400 MaintenanceWindowMismatchBetweenInstanceAndInstancePool - Instance maintenance window must be set to match instance pool maintenance window.

  • 400 ManagedInstanceClassicVnetNotSupported - Managed Instance cannot be joined to a classic virtual network.

  • 400 ManagedInstanceMinTlsVersionGreaterThanMaxAllowedVersion - Operation '{0}' could not be completed because the minimum TLS version parameter is higher than max allowed.

  • 400 VnetConfigHasNsg - User tried to inject Managed Server subnet with Network Security Groups.

  • 400 VnetConfigHasNoUdr - User tried to inject Managed Server subnet without default User Defined Route Table.

  • 400 VnetConfigHasInvalidUdr - User tried to inject Managed Server subnet with invalid User Defined Route Table.

  • 400 VnetConfigHasInvalidDns - User tried to inject Managed Server subnet with invalid custom DNS.

  • 400 VnetConfigHasServiceEndpoints - User tried to inject Managed Server subnet with service endpoints.

  • 400 VnetSubnetIsInUse - User tried to inject Managed Server subnet that is not empty.

  • 400 VnetSubnetIsLocked - User tried to inject Managed Server subnet that is in locked scope.

  • 400 VnetSubnetIsGateway - User tried to inject Managed Server subnet that is Gateway subnet.

  • 400 VnetSubnetIsUnknown - User tried to inject Managed Server subnet that does not exist.

  • 400 VnetSubnetConflictWithIntendedPolicy - User tried to inject Managed Server subnet that has a conflict with IntendedPolicy.

  • 400 ManagedInstanceInvalidEditionForSku - The specified edition {0} is not consistent with the specified SKU {1}.

  • 400 ManagedInstanceInvalidLicenseType - The specified license type {0} is not valid.

  • 400 ManagedInstanceUpdateSloInProgress - "The operation could not be completed because a service tier change is in progress for managed instance '{0}.' Please wait for the operation in progress to complete and try again."

  • 400 VnetResourceNotFound - Resource not found: '{0}'.

  • 400 InstanceCollationUpdateNotSupported - User cannot change instance collation on Managed Instance.

  • 400 CreateManagedInstanceWithNonDefaultCollationNotSupported - User can create a Managed Instance only with collation 'SQL_Latin1_General_CP1_CI_AS'.

  • 400 ManagedInstanceOperationInProgress - The operation could not be completed because {0} operation is in progress. Please wait for the operation in progress to complete and try again.

  • 400 ManagedInstanceExceedMaxAzureStorage - The operation could not be completed because total allocated storage size for General Purpose instance would exceed {0}. Please reduce the number of database files and retry operation.

  • 400 ManagedInstanceHasGeoReplica - The operation could not be completed because instance has configured geo replicated secondary instance.

  • 400 InvalidDnsZone - The operation has failed because you are attempting to deploy managed instance as a geo-replication secondary to the subnet {0} in which there already exists a managed instance. Deploying managed instance as a geo-replication secondary is supported only in cases when managed instance is the first instance deployed in a subnet. Consider deploying managed instance as a geo-replication secondary to a different subnet in which there are no existing managed instances, or if deploying to a subnet with existing managed instance disable the geo-replication option.

  • 400 ManagedInstanceInvalidStorageSizeLessThenCurrentSizeUsed - Invalid storage size: Storage size limit ({0} GB) is less that current storage used ({1} GB). Please specify higher storage size limit.

  • 400 InvalidTimezone - Invalid timezone.

  • 400 InstanceTimezoneUpdateNotSupported - Instance timezone update not supported.

  • 400 CreateManagedInstanceWithNonDefaultTimezoneNotSupported - Create Managed Instance with non-default timezone not supported.

  • 400 ManagedInstanceIpAddressRangeLimit - Cannot perform creation/scaling of the managed instance as there are not enough available IP addresses in the subnet for performing the operation.

  • 400 VnetDelegationNotAllowed - User tried to inject Managed Server to subnet which is delegated.

  • 400 SubnetHasResourcesOfDifferentType - User tried to create MI in subnet that has resources of different type.

  • 400 UpdateManagedServerWithMaintenanceWindowNotAllowed - Update of Managed Instance with maintenance window settings is not allowed.

  • 400 OperationNotAllowedInCurrentGeodrConfiguration - The operation is not allowed because the current geo-replication configuration does not allow this combination of {0}. Change the setting on the geo-replication partner before applying the change on this instance.

  • 400 VnetPrepareNIPFailed - User tried to prepare subnet that has a conflict with NetworkIntentPolicy.

  • 400 ManagedInstanceDeprecatedHardwareFamily - Changing the hardware generation to deprecated {0} generation is not possible.

  • 400 ManagedInstanceBackupStorageTypeNotSupported - Backup storage type parameter is not allowed in the instance update operation.

  • 400 EmptyPDCInvalidDnsZone - This managed instance cannot be deployed because its DNS-zone does not match the DNS-prefix of its intended virtual cluster for subnet {0}. Although this virtual cluster is empty, its DNS-prefix cannot be changed. Empty virtual clusters will be automatically removed after several hours. Consider waiting for this virtual cluster to expire or manually deleting this virtual cluster and then creating the managed instance.

  • 400 MissingIdentityId - No user assigned identity is provided when the identity type is set to UserAssigned

  • 400 InvalidPrimaryIdentityId - User provides a value for PrimaryUserIdentityId but the same is not listed in the IdentityId parameter

  • 400 ManagedInstanceZoneRedudantFeatureNotSupported - ZoneRedundant feature is not supported for the selected service tier. For more details visit aka.ms/sqlmi-service-tier-characteristics.

  • 400 ManagedInstanceZoneRedudantFeatureCantBeEnabled - Enabling zoneRedundant feature is not possible once managed instance is created. For more details visit aka.ms/sqlmi-high-availability.

  • 400 ManagedInstanceZoneRedudantFeatureCantBeDisabled - Disabling zoneRedundant feature is not possible once managed instance is created. For more details visit aka.ms/sqlmi-high-availability.

  • 400 UmiMissingAkvPermissions - PrimaryUserAssignedIdentityId provided by user does not have access to KeyId provided

  • 400 MissingPrimaryIdentity - PrimaryUserAssignedIdentityId provided by user does not have access to KeyId provided

  • 400 SubnetIdCantBeUpdated - Changing managed instance subnet is not supported operation. Please remove this parameter from the request.

  • 400 MigrationToAnotherVNetNotSupported - Selected subnet is in another Virtual Network. Moving managed instance to another Virtual Network is not possible. Please provide subnet from Virtual Network {0}.

  • 400 MigrationToSubnetWithDifferentDnsZoneNotSupported - Provided subnet is having different DNS zone from the current. Changing instance DNS zone is not supported. Please provide subnet with same DNS zone, create a new subnet or provide empty one.

  • 400 MigrationToGen4SubnetNotSupported - It is not possible to update subnet while running on Gen4 hardware as it is being deprecated. Please upgrade your hardware from Gen4 to Gen5 as part of the changing managed instance subnet operation by specifying both parameters at the same time: destination subnet and hardware generation.

  • 400 PrimaryIdentityMissingPermissionForKeyId - KeyId is provided by user during create but PrimaryUserAssignedIdentityId is not provided in the API call

  • 400 InvalidIdentityTypeForKeyId - KeyId is provided by user during create but identity type is not set to 'UserAssigned'

  • 400 ServerNotFound - The requested server was not found.

  • 400 ManagedInstanceFileExceededMaxAzureStorageFileSizeLimit - The operation could not be completed because some of the database files are exceeding maximum General Purpose file size limit of {0} GB.

  • 400 ManagedInstanceStoppingOrStopped - Conflicting operation submitted while instance is in stopping/stopped state

  • 400 ManagedInstanceStarting - Conflicting operation submitted while instance is in starting state

  • 400 InstancePoolNotEnoughCapacity - An instance pool does not have enough capacity

  • 400 SourceAndTargetSubnetsMustBeVnetPeered - Subnet currently used by managed instance and provided destination subnet are part of the virtual networks that are not connected with virtual network peering, or have peering established but don't have allowed traffic. In order to move managed instance from one subnet to another, virtual network peering needs to be established from both source and target virtual network. Please configure virtual network requirements and then try the operation again. Learn more https://docs.microsoft.com/en-us/azure/virtual-network/tutorial-connect-virtual-networks-portal#peer-virtual-networks.

  • 400 ManagedInstanceAndSubnetAreNotOnTheSameSubscription - Subnet provided for managed instance deployment is located on subscription different than the one submitted for managed instance. Managed instance and subnet used for deploying the instance must be on the same subscription. Please provide another subnet or switch to the subnet subscription and then try the operation again.

  • 400 CreateManagedInstanceInvalidSubnetSize - User attempted to create managed instance in a subnet that is smaller than the allowed minimal subnet size.

  • 400 AddressRangeOfTargetSubnetAndSubnetOfGeoDRReplicaCantOverlap - Subnet selected for managed instance migration has address range that overlaps with address range of subnet that holds geo replicated secondary instance. Please verify that your subnet is configured according to guidelines in https://aka.ms/move-managed-instance.

  • 400 TargetSubnetMustBeConfiguredToAllowGeoDRReplication - Subnet selected for managed instance migration is not configured to enable communication with a geo replicated secondary instance. Please check if all of the required ports are open. To properly configure your subnet read the guidelines in https://aka.ms/move-managed-instance.

  • 400 InvalidIdentifier - The identifier contains NULL or an invalid unicode character.

  • 400 InvalidLoginName - The provided login name is invalid.

  • 400 InvalidUsername - Supplied user name contains invalid characters.

  • 400 PasswordTooShort - The provided password is too short

  • 400 PasswordTooLong - The provided password is too long.

  • 400 PasswordNotComplex - The provided password is not complex enough.

  • 400 GatewayInvalidEdition - '{0}' is not a valid database edition in this version of SQL Server.

  • 400 StorageIOpsNotSupported - Storage IOps parameter is not allowed in the instance create/update operation.

  • 400 StorageThroughputMBpsNotSupported - Storage throughput MBps parameter is not allowed in the instance create/update operation.

  • 400 StorageIOpsNotSupportedForSpecifiedEdition - Storage IOps parameter is not allowed in the instance create/update operation for the specified edition.

  • 400 StorageThroughputMBpsNotSupportedForSpecifiedEdition - Storage throughput MBps parameter is not allowed in the instance create/update operation for the specified edition.

  • 400 InvalidLocation - An invalid location was specified.

  • 400 InvalidParameterValue - An invalid value was given to a parameter.

  • 400 InvalidServerName - Invalid server name specified.

  • 400 InvalidManagedServerDnsZonePartner - The resource URI of the geo-primary managed instance specified in the create request is invalid. Please ensure that the property is of the format /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/managedInstances/{managedInstanceName}

  • 400 ManagementServiceManagedServerDisabled - Operation failed since Managed Instance '{0}' is disabled. Please enable Managed Instance and try again.

  • 400 MiGeoRestoreWithWrongBackupStorageRedundancy - Geo-Restore is not allowed for managed instances with LRS/ZRS backup storage redundancy.

  • 400 LastBackupNameHasNewline - Please do not use forbidden characters ('\n', '\r') in lastBackupName.

  • 400 LastBackupNameHasNonAsciiCharacter - The operation was aborted because the 'LastBackupName' parameter contains invalid characters. Only ASCII characters are allowed.

  • 400 ProvisioningDisabled - Displays error message from resources operation authorizer as is, without changes

  • 400 LRSCutoverDatabaseDoesNotExist - The operation was aborted because the database name specified in the request doesn't match any database name on the specified server.

  • 400 LRSCutoverDatabaseNotInRestoringState - The operation was aborted because the specified database is not in restoring state.

  • 400 LRSCutoverDatabaseAlreadyRestored - The operation was aborted because the specified database was already restored.

  • 400 LRSCutoverAlreadyInitiated - The operation was aborted because a cutover for the specified database is already in progress.

  • 400 ManagementServiceFeatureDisabled - User attempted to use a feature which is disabled.

  • 400 AadOnlyAuthenticationIsEnabled - Azure Active Directory Only Authentication is enabled. Please contact your system administrator.

  • 400 UpdatingInstanceAndBackupRedundancy - Instance zone redundancy and backup storage redundancy cannot be updated in the same request.

  • 400 DeleteOfManagedInstanceIsDisabled - Delete operation of managed instance is disabled.

  • 400 RequestCantLandOnPaaSv2Platform - Request needs to land on PaaSv2 platform but PaaSv2 is not enabled.

  • 400 CustomMaintenanceWindowIsDisabled - Custom maintenance window is not enabled.

  • 400 DeleteOfVersion2VirtualClusterIsDisabled - Delete of virtual cluster with version 2 is not enabled.

  • 400 DeleteOfVirtualClusterIsDisabled - Delete of virtual cluster is not enabled.

  • 400 MICantBeMovedFromOrToInstancePool - Existing managed instance can't be moved to managed instance pool.

  • 400 DnsRefreshOnVirtualClusterIsDisabled - Refresh of DNS records on virtual cluster is not enabled.

  • 400 MismatchingResourceGroupNameWithUrl - The provided resource group name did not match the name in the Url.

  • 400 MismatchingSubscriptionWithUrl - The provided subscription did not match the subscription in the Url.

  • 400 InvalidMinimalTlsVersion - Invalid minimal TLS version.

  • 400 InvalidResourceId - Invalid resource identifier.

  • 400 InvalidParameterValue - An invalid value was given to a parameter.

  • 400 DeleteOfManagedInstanceIsDisabled - Delete operation of managed instance is disabled.

  • 400 CustomMaintenanceWindowIsDisabled - Custom maintenance window is not enabled.

  • 400 MICantBeMovedFromOrToInstancePool - Existing managed instance can't be moved to managed instance pool.

  • 400 InvalidMaintenanceWindowSettings - Invalid maintenance window settings.

  • 400 InvalidMaintenanceWindowProperty - Invalid maintenance window property was specified.

  • 400 InvalidMaintenanceWindowPropertyNull - Invalid maintenance window with required properties null.

  • 400 InvalidMaintenanceWindowTypeWithPropertySpecified - Maintenance window type must not have certain properties specified.

  • 400 UpdateOfParameterNotSupported - Update of '{0}' is not supported.

  • 400 MaintenancePolicyFeatureIsDisabled - Assigning customer maintenance policy is not enabled for provided subscription. Please use maintenanceConfigurationId property instead.

  • 400 MaintenancePolicyInvalidType - The provided value for w type is not valid. Please use one of the following values: SystemDefined, CustomerDefined.

  • 400 MaintenancePolicyInvalidMaintenanceConfigurationId - The provided value for maintenanceConfigurationId is not valid. Please check Public Maintenance Configuration list to get the list of available configurations.

  • 400 MaintenancePolicyInvalidStartHour - The provided value for startHour is not valid. Start time represents the hour of the day when maintenance event should start. Accepted values are 00-23. Please retry with appropriate value.

  • 400 MaintenancePolicyInvalidDayOfWeek - The provided value for dayOfWeek is not valid. Please use one of the following values: Monday, Tuesday, Wednesday, Thursday, Friday, Saturday, Sunday.

  • 400 ManagedInstanceStoppingOrStopped - Conflicting operation submitted while instance is in stopping/stopped state

  • 400 ManagedInstanceStarting - Conflicting operation submitted while instance is in starting state

  • 400 AadOnlyAuthenticationIsEnabled - Azure Active Directory Only Authentication is enabled. Please contact your system administrator.

  • 400 InvalidExternalAdministratorLogin - Invalid or missing external administrator login name.

  • 400 InvalidExternalAdministratorSid - Invalid or missing external administrator object id.

  • 400 InvalidExternalAdministratorTenantId - Invalid or missing external administrator tenant id.

  • 400 ExternalAdministratorPrincipalType - Invalid or missing external administrator principal type. Please select from User, Application or Group.

  • 400 MissingExternalAdministratorWithAadOnlyAuth - In order to use Azure AD Only Authentication, please provide details of an external administrator.

  • 400 ExternalAdministratorLoginSameAsSqlAdmin - The names of the Azure Active Directory administrator and of the server admin account must be different. Please provide different values.

  • 400 LongTermRetentionMigrationRequestNotSupported - Subscription is not allowed LTR backup Migration feature.

  • 400 LongTermRetentionMigrationCrossClusterRequestNotSupported - Source and target subscriptions are not allowed to communicate for LTR backup copy feature.

  • 400 LongTermRetentionMigrationParameterMissing - Required parameter missing for the operation.

  • 400 LongTermRetentionMigrationSameServerNotSupported - LTR Copy feature is not supported to copy LTR backups within same server.

  • 400 LongTermRetentionMigrationTargetServerNotFound - Target server does not exists or is not ready for LTR backup copy operation.

  • 400 LongTermRetentionMigrationTargetDatabaseNotFound - Target Database does not exists on the server.

  • 400 LongTermRetentionMigrationStorageTypeNotSupported - Specified Backup Storage Redundancy is not supported in target region.

  • 400 LongTermRetentionMigrationStorageMismatch - Active backup redundancy of database does not match backup redundancy requested by customer.

  • 400 LtrOperationFailedBackupImmutable - Deleting Long Term Retention backup failed because the backup is immutable.

  • 400 LongTermRetentionMigrationDatabaseTypeNotSupported - LTR migration is only supported for managed instance and Azure SQL DB LTR backups.

  • 400 LongTermRetentionMigrationBackupStorageRedundancyNotAllowed - Changing backup storage redundancy is not allowed for LTR Copy operations.

  • 400 LtrRestoreFailedArchiveStorageTier - Restoring archived long-term retention backup is not supported. Restore can be performed only on rehydrated or regular long-term retention backups.

  • 400 LtrArchiveStorageTierNotEnabled - Archiving long-term retention backups is not enabled.

  • 400 LtrArchiveWrongParameters - ChangeLongTermRetentionBackupAccessTier is not supported for the desired (backupStorageAccessTier, operationMode) combination. Only (Archive, Move) and (Hot, Copy) are allowed.

  • 400 LTRArchiveRedundancyChangeFailed - Updating the backup storage redundancy type to zone-redundant storage is not supported when a long-term retention policy with the 'archive' backup storage access tier is set

  • 400 LongTermRetentionMigrationSubscriptionNotFound - The subscription could not be found.

  • 400 SecurityAdalPrincipalCertExpiredError - The operation could not be completed because the Azure Key Vault principal certificate has expired.

  • 400 AkvHostNotResolvingFromNode - AKV host '{0}' is not resolvable from SQL, on server '{1}'.

  • 400 SecurityInvalidAzureKeyVaultRecoveryLevel - The provided Key Vault uri is not valid.

  • 400 MissingKeyVaultUriForRestore - Azure Key Vault key URI '{0}' is required to successfully restore the database '{1}' under server '{2}'.

  • 400 AzureKeyVaultKeyUsedOnGeoPrimary - The operation could not be completed because the Azure Key Vault Key name {0} is currently set as encryption protector on geo-primary.

  • 400 KeyMaterialNotFoundOnRemoteServer - Remote server does not have access to key material used as a TDE protector.

  • 400 PerDatabaseCMKAKVKeyMaterialMissingOnGeoSecondary - All databases in geo replication must contain the same key material as the encryption protector of the source database. Please add the key '{0}' with the same key material to the target database '{1}'.

  • 400 AzureKeyVaultRsaKeyNotSupported - The provided key vault uses unsupported RSA Key Size or Key Type. The supported RSA key size is 2048 or 3072 and Key Type is RSA or RSA-HSM.

  • 400 PerDatabaseCMKAKVKeyUriMissingOnGeoSecondary - When the automatic rotation of database level TDE Protector is enabled, both source and target databases must be connected to the same key vault. Please add key '{0}' (from the same key vault that is connected to source database) to the target database '{1}'.

  • 400 PerDatabaseCMKCopyOrReplicationAttemptedWithoutCurrentKeysWithDatabaseName - While attempting to replicate a database configured with database level encryption protector, the current keys being used by the primary database must be passed to the secondary database '{0}'

  • 400 ManagedInstanceNoConditionToMakeDatabaseAccessible - The operation could not be completed because there is no sufficient permissions to start accessible workflow on managed instance {0}.

  • 400 UmiMissingAkvPermissions - PrimaryUserAssignedIdentityId provided by user does not have access to KeyId provided

  • 400 SameKeyUriNotFoundOnRemoteServer - Secondary server does not have the key material from the same key vault as the primary server's encryption protector with key auto-rotation enabled.

  • 400 SameKeyMaterialNotFoundOnRemoteServer - Secondary server does not have the key material of the primary server's encryption protector.

  • 400 SecurityAzureKeyVaultGeoChainError - Creating secondary of secondary (a process known as chaining) is not supported when enabling Transparent Data Encryption using Azure Key Vault (BYOK).

  • 400 PerDatabaseCMKDWNotSupported - Database-level CMK in preview is not supported for Datawarehouse edition.

  • 400 BlockSystemAssignedIdentityForCrossTenantCMK - Cross tenant CMK can only be configured when the server is configured with a User Assigned Managed Identity. Refer to https://aka.ms/sqltdebyokumi to configure User Assigned Managed Identity.

  • 400 PerDatabaseCMKCopyOrReplicationAttemptedWithoutCurrentKeys - While attempting to replicate a database configured with database level encryption protector, the current keys being used by the primary must be passed to the secondary database.

  • 400 CannotDropDatabaseAKVError - The database {0} on server {1} cannot be safely dropped because it is encrypted with a customer managed key that is no longer accessible to take the last backup before drop. Please restore Azure Key Vault Access on the server and revalidate the keys to make this database accessible and then proceed with the drop. For details see https://aka.ms/tdecmkrestorability

  • 400 CreateDatabaseAttemptedWithRotationInProgress - The create database operation can not be performed at this time due to ongoing Transparent Data Encryption (TDE) key rotation on the server. Please try the operation again later.

  • 400 AzureKeyVaultKeyDisabled - The operation could not be completed on the server because the Azure Key Vault key is disabled.

  • 400 PerDatabaseCMKRestoreNotSupported - Database restore is not supported when Database-level CMK is configured in preview.

  • 400 AzureKeyVaultInvalidExpirationDate - The operation could not be completed because the Azure Key Vault key expiration date is invalid.

  • 400 PerDatabaseCMKHSNotSupported - Database-level CMK in preview is not supported for Hyperscale edition.

  • 400 SecurityAzureKeyVaultUrlNullOrEmpty - The operation could not be completed because the Azure Key Vault Uri is null or empty.

  • 400 CMKOperationNotAllowed - User tried to perform an operation on the server when the server did not have Azure Key Vault Access.

  • 400 AkvEndpointNotReachableFromNode - AKV endpoint '{0}' is not reachable from SQL, on server '{1}'.

  • 400 AzureKeyVaultNoServerIdentity - The server identity is not correctly configured.

  • 400 AzureKeyVaultInvalidUri - An invalid response from Azure Key Vault. Please use a valid Azure Key Vault URI.

  • 400 AzureKeyVaultMissingPermissions - The server is missing required permissions on the Azure Key Vault.

  • 400 AzureKeyVaultKeyNameCurrentlyInUse - The operation could not be completed because the Azure Key Vault Key name {0} is currently in use.

  • 400 AzureKeyVaultKeyThumbprintIsDifferent - The operation could not be completed because the Azure Key Vault Key material is different than the current encryption protector key.

  • 400 SecurityAzureKeyVaultInvalidKeyName - The operation could not be completed because of an invalid Server Key name.

  • 400 OldGenerationOfAKVKeyBeingUsedError - Using an old version of AKV key as TDE protector is not allowed. Please use the latest version of the AKV key as the encryption protector

  • 400 PerDatabaseCMKMissingIdentityOnGeoSecondaryDatabase - Per Database CMK identity not setup on the target database.

  • 400 AdalGenericError - The operation could not be completed because an Azure Active Directory error was encountered.

  • 400 AdalServicePrincipalNotFound - The operation could not be completed because an Azure Active Directory library Service Principal not found error was encountered.

  • 400 AzureKeyVaultMalformedVaultUri - The provided Key Vault uri is not valid.

  • 400 ServerPrincipalCreateLoginBadSyntax - There was an Syntax Error when executing Create Login statement for Azure AD Administrator.

  • 400 ManagedInstanceIsBusy - Managed Instance is busy with another request.

  • 400 InvalidLoginName - The provided login name is invalid.

  • 400 ServicePrincipalLookupInAadFailedIdentityForbidden - AzureAD Lookup failed because MSI was not granted read permissions on AAD.

  • 400 PrincipalNotFoundInTenant - AzureAD Lookup returned no results for this name.

  • 400 ServerPrincipalHasDuplicateDisplayNameInAad - AzureAD Lookup returned multiple results for this name.

  • 400 InvalidPrincipalType - This principal type is not supported in Windows Azure SQL Database.

  • 400 InvalidParameterValue - An invalid value was given to a parameter.

  • 400 ServicePrincipalLookupInAadFailed - AzureAD Lookup failed due to service infrastructure errors.

  • 400 TenantNotFoundInActiveDirectory - Tenant is not available in active directory.

  • 400 InvalidUsername - Supplied user name contains invalid characters.

  • 400 ManagedInstanceHasNoPermissionsToAccessAad - Attempt to perform operation, which involves a non-existing login or login on which executing principal has no permissions.

  • 404 ManagedInstanceNotInSubscriptionResourceGroup - Specified managed instance does not exist in the specified resource group and subscription.

  • 404 SubscriptionNotFound - The requested subscription was not found.

  • 404 ServerNotInSubscription - Specified server does not exist on the specified subscription.

  • 404 OperationIdNotFound - The operation with Id does not exist.

  • 404 ResourceDoesNotExist - Resource with the name '{0}' does not exist. To continue, specify a valid resource name.

  • 404 InstancePoolNotFound - An instance pool cannot be found

  • 404 SubscriptionNotFound - The requested subscription was not found.

  • 404 ResourceNotFound - The requested resource was not found.

  • 404 LongTermRetentionMigrationBackupNotFound - LTR backup specified does not exists.

  • 405 InvalidVcoreValue - vCore value {0} is not valid. Please specify a valid vCore value.

  • 405 InvalidHardwareGenerationValue - HardwareGeneration {0} is not valid. Please specify a valid HardwareGeneration value.

  • 405 InvalidStorageSizeValue - "Invalid storage size: {0} GB. Storage size must be specified between {1} and {2} gigabytes, in increments of {3} GB.

  • 405 InvalidStorageIOpsLimitValue - Invalid storage IOps limit: {0} IOps. Storage IOps limit must be specified between {1} IOps and {2} IOps, in increments of {3} IOps.

  • 405 InvalidStorageThroughputMBpsLimitValue - Invalid storage throughput limit: {0} MBps. Storage throughput limit must be specified between {1} MBps and {2} MBps, in increments of {3} MBps.

  • 409 CannotCancelOperation - The management operation is in a state that cannot be cancelled.

  • 409 OperationCancelled - The operation has been cancelled by user.

  • 409 OperationInterrupted - The operation on the resource could not be completed because it was interrupted by another operation on the same resource.

  • 409 ConflictingServerOperation - An operation is currently in progress for the server.

  • 409 SubscriptionDisabled - Subscription is disabled.

  • 409 ServerOverridePreconditionFailed - Failed to apply server override on category '{0}', because physical db or instance '{1}' in server '{2}' is currently not in 'Ready' or 'Deactivated' state.

  • 409 ManagedInstanceIsBusy - The server '{0}' is currently busy. Please wait a few minutes before trying again.

  • 409 ServerAlreadyExists - Duplicate server name.

  • 409 ServerDisabled - Server is disabled.

  • 409 ServerQuotaExceeded - Server cannot be added to a subscription because it will exceed quota.

  • 409 MiCreateFailedNonDelegatedSubnet - User tried to deploy Managed Instance or Managed Instance pool in subnet that is not delegated to Microsoft.Sql/managedInstances.

  • 409 InstancePoolBusy - An instance pool is busy with another ongoing operation

  • 409 ConflictingManagedInstanceOperation - An operation is currently in progress for the managed instance.

  • 409 BackupRedundancyUpdateAndInstanceRedundancyConflict - The instance is multi-az but backup storage is being updated from zone redundant to non-zone redundant.

  • 409 InstanceRedundancyUpdateWhileBackupRedundancyUpdateInProgress - Cannot update instance redundancy because backup storage redundancy update is in progress.

  • 409 InstanceRedundancyUpdateAndBackupRedundancyConflict - The backup storage is non-zone redundant but instance redundancy is being updated to zone redundant.

  • 409 BackupRedundancyUpdateConflict - Cannot update backup storage redundancy because a backup storage redundancy update is already in progress.

  • 409 MiDropFailedOnAuthLocks - User tried to drop last Managed Instance in subnet that has Lock applied on resource(s).

  • 409 LongTermRetentionMigrationRequestConflict - A conflict operation on this LTR backup is still in progress.

  • 409 LongTermRetentionMigrationBackupConflict - Another LTR backup with same backup time for target database exists.

  • 409 ServerKeyNameAlreadyExists - The server key already exists on the server.

  • 409 ServerKeyUriAlreadyExists - The server key URI already exists on the server.

  • 409 ServerKeyDoesNotExists - The server key does not exist.

  • 409 AzureKeyVaultKeyNameNotFound - The operation could not be completed because the Azure Key Vault Key name does not exist.

  • 409 AzureKeyVaultKeyInUse - The key is currently being used by the server.

  • 409 ServerPrincipalOwnsJobs - Attempt to remove a login when it has active jobs.

  • 409 ServerPrincipalOwnsObjects - Attempt to drop a login, which owns objects.

  • 409 ServerPrincipalIsGrantorOfPermissions - Attempt to drop a server principal, which is a grantor of permissions.

  • 409 ServerPrincipalOwnsDatabase - Change the owner of the database(s) before dropping the login.

  • 409 ServerPrincipalCurrentlyLoggedIn - Self-explanatory.

  • 409 ServerPrincipalAlreadyExists - Attempt to create server principal with non-unique name.

  • 409 ServerPrincipalUsedInTriggerOrEventNotification - Attempt to drop login, which is used as an execution context of a trigger or event notification.

  • 412 InstanceNotReadyForBackupRedundancyUpdate - Cannot update backup storage redundancy because the instance is not ready.

  • 429 SubscriptionTooManyCreateUpdateRequests - Requests beyond max requests that can be processed by available resources.

  • 429 SubscriptionTooManyRequests - Requests beyond max requests that can be processed by available resources.

  • 429 SubscriptionTooManyCreateUpdateRequests - Requests beyond max requests that can be processed by available resources.

  • 429 SubscriptionTooManyRequests - Requests beyond max requests that can be processed by available resources.

  • 429 ConflictingSubscriptionOperation - An operation is currently in progress for the subscription.

  • 429 SubscriptionTooManyCreateUpdateRequests - Requests beyond max requests that can be processed by available resources.

  • 429 SubscriptionTooManyRequests - Requests beyond max requests that can be processed by available resources.

  • 429 SubscriptionTooManyCreateUpdateRequests - Requests beyond max requests that can be processed by available resources.

  • 429 SubscriptionTooManyRequests - Requests beyond max requests that can be processed by available resources.

  • 429 ConflictingSubscriptionOperation - An operation is currently in progress for the subscription.

  • 500 OperationTimedOut - The operation timed out and automatically rolled back. Please retry the operation.

  • 500 GatewayInternalServerError - The server encountered an unexpected exception.

  • 500 LongTermRetentionMigrationRequestFailedToStartOnTarget - Failed to start LTR backup copy request in target region.

  • 500 LongTermRetentionMigrationRequestCopyFailed - Copy operation failed for LTR backup blobs.

  • 500 LongTermRetentionMigrationRestoreVerExceeded - Restore verification failed after max attempts were reached.

  • 500 LongTermRetentionMigrationRestoreVerFailed - Restore verification failed.

  • 500 ActiveDirectoryLookupTimedOut - The operation could not be completed at this time. Please try again later.

  • 503 TooManyRequests - Requests beyond max requests that can be processed by available resources.

  • 503 TooManyRequests - Requests beyond max requests that can be processed by available resources.

  • 503 TooManyRequests - Requests beyond max requests that can be processed by available resources.

  • 503 TooManyRequests - Requests beyond max requests that can be processed by available resources.

  • 503 AzureKeyVaultConnectionFailed - The operation could not be completed on the server because attempts to connect to Azure Key Vault have failed

  • 503 AzureKeyVaultGenericConnectionError - The operation could not be completed because an error was encountered when attempting to retrieve Key Vault information .

  • 504 RequestTimeout - Service request exceeded the allowed timeout.

  • 504 RequestTimeout - Service request exceeded the allowed timeout.

  • 504 RequestTimeout - Service request exceeded the allowed timeout.

Examples

Create managed instance with all properties
Create managed instance with minimal properties

Create managed instance with all properties

Sample request

PUT https://management.azure.com/subscriptions/20D7082A-0FC7-4468-82BD-542694D5042B/resourceGroups/testrg/providers/Microsoft.Sql/managedInstances/testinstance?api-version=2023-08-01

{
  "tags": {
    "tagKey1": "TagValue1"
  },
  "location": "Japan East",
  "sku": {
    "name": "GP_Gen5",
    "tier": "GeneralPurpose"
  },
  "properties": {
    "administratorLogin": "dummylogin",
    "administratorLoginPassword": "PLACEHOLDER",
    "subnetId": "/subscriptions/20D7082A-0FC7-4468-82BD-542694D5042B/resourceGroups/testrg/providers/Microsoft.Network/virtualNetworks/vnet1/subnets/subnet1",
    "vCores": 8,
    "storageSizeInGB": 1024,
    "licenseType": "LicenseIncluded",
    "collation": "SQL_Latin1_General_CP1_CI_AS",
    "dnsZonePartner": "/subscriptions/20D7082A-0FC7-4468-82BD-542694D5042B/resourceGroups/testrg/providers/Microsoft.Sql/managedInstances/testinstance",
    "publicDataEndpointEnabled": false,
    "proxyOverride": "Redirect",
    "minimalTlsVersion": "1.2",
    "timezoneId": "UTC",
    "instancePoolId": "/subscriptions/20D7082A-0FC7-4468-82BD-542694D5042B/resourceGroups/testrg/providers/Microsoft.Sql/instancePools/pool1",
    "maintenanceConfigurationId": "/subscriptions/20D7082A-0FC7-4468-82BD-542694D5042B/providers/Microsoft.Maintenance/publicMaintenanceConfigurations/SQL_JapanEast_MI_1",
    "requestedBackupStorageRedundancy": "Geo",
    "administrators": {
      "principalType": "User",
      "login": "bob@contoso.com",
      "sid": "00000011-1111-2222-2222-123456789111",
      "tenantId": "00000011-1111-2222-2222-123456789111",
      "azureADOnlyAuthentication": true
    },
    "hybridSecondaryUsage": "Passive",
    "servicePrincipal": {
      "type": "SystemAssigned"
    },
    "databaseFormat": "AlwaysUpToDate",
    "authenticationMetadata": "AzureAD"
  }
}

Sample response

{
  "sku": {
    "name": "GP_Gen5",
    "tier": "GeneralPurpose",
    "capacity": 8,
    "family": "Gen5"
  },
  "properties": {
    "fullyQualifiedDomainName": "testinstance.1b4e2caff2530.database.windows.net",
    "administratorLogin": "dummylogin",
    "subnetId": "/subscriptions/20D7082A-0FC7-4468-82BD-542694D5042B/resourceGroups/testrg/providers/Microsoft.Network/virtualNetworks/vnet1/subnets/subnet1",
    "state": "Ready",
    "provisioningState": "Creating",
    "vCores": 8,
    "storageSizeInGB": 1024,
    "licenseType": "LicenseIncluded",
    "collation": "SQL_Latin1_General_CP1_CI_AS",
    "publicDataEndpointEnabled": false,
    "proxyOverride": "Redirect",
    "minimalTlsVersion": "1.2",
    "dnsZone": "1b4e2caff2530",
    "timezoneId": "UTC",
    "instancePoolId": "/subscriptions/20d7082a-0fc7-4468-82bd-542694d5042b/resourceGroups/testrg/providers/Microsoft.Sql/instancePools/pool1",
    "maintenanceConfigurationId": "/subscriptions/20D7082A-0FC7-4468-82BD-542694D5042B/providers/Microsoft.Maintenance/publicMaintenanceConfigurations/SQL_JapanEast_MI_1",
    "currentBackupStorageRedundancy": "Geo",
    "requestedBackupStorageRedundancy": "Geo",
    "administrators": {
      "principalType": "User",
      "login": "bob@contoso.com",
      "sid": "00000011-1111-2222-2222-123456789111",
      "tenantId": "00000011-1111-2222-2222-123456789111",
      "azureADOnlyAuthentication": true
    },
    "servicePrincipal": {
      "principalId": "00000011-1111-2222-2222-123456789111",
      "clientId": "00000011-1111-2222-2222-123456789111",
      "tenantId": "00000011-1111-2222-2222-123456789111",
      "type": "SystemAssigned"
    },
    "externalGovernanceStatus": "Enabled",
    "hybridSecondaryUsage": "Passive",
    "databaseFormat": "AlwaysUpToDate",
    "authenticationMetadata": "AzureAD"
  },
  "location": "japaneast",
  "tags": {
    "tagKey1": "TagValue1"
  },
  "id": "/subscriptions/20d7082a-0fc7-4468-82bd-542694d5042b/resourceGroups/testrg/providers/Microsoft.Sql/managedInstances/testinstance",
  "name": "testinstance",
  "type": "Microsoft.Sql/managedInstances"
}
{
  "sku": {
    "name": "GP_Gen5",
    "tier": "GeneralPurpose",
    "capacity": 8,
    "family": "Gen5"
  },
  "properties": {
    "fullyQualifiedDomainName": "testinstance.1b4e2caff2530.database.windows.net",
    "administratorLogin": "dummylogin",
    "subnetId": "/subscriptions/20D7082A-0FC7-4468-82BD-542694D5042B/resourceGroups/testrg/providers/Microsoft.Network/virtualNetworks/vnet1/subnets/subnet1",
    "state": "Ready",
    "provisioningState": "Creating",
    "vCores": 8,
    "storageSizeInGB": 1024,
    "licenseType": "LicenseIncluded",
    "collation": "SQL_Latin1_General_CP1_CI_AS",
    "publicDataEndpointEnabled": false,
    "proxyOverride": "Redirect",
    "minimalTlsVersion": "1.2",
    "dnsZone": "1b4e2caff2530",
    "timezoneId": "UTC",
    "instancePoolId": "/subscriptions/20d7082a-0fc7-4468-82bd-542694d5042b/resourceGroups/testrg/providers/Microsoft.Sql/instancePools/pool1",
    "maintenanceConfigurationId": "/subscriptions/20D7082A-0FC7-4468-82BD-542694D5042B/providers/Microsoft.Maintenance/publicMaintenanceConfigurations/SQL_JapanEast_MI_1",
    "currentBackupStorageRedundancy": "Geo",
    "requestedBackupStorageRedundancy": "Geo",
    "administrators": {
      "principalType": "User",
      "login": "bob@contoso.com",
      "sid": "00000011-1111-2222-2222-123456789111",
      "tenantId": "00000011-1111-2222-2222-123456789111",
      "azureADOnlyAuthentication": true
    },
    "servicePrincipal": {
      "principalId": "00000011-1111-2222-2222-123456789111",
      "clientId": "00000011-1111-2222-2222-123456789111",
      "tenantId": "00000011-1111-2222-2222-123456789111",
      "type": "SystemAssigned"
    },
    "hybridSecondaryUsage": "Passive",
    "databaseFormat": "AlwaysUpToDate",
    "authenticationMetadata": "AzureAD"
  },
  "location": "japaneast",
  "tags": {
    "tagKey1": "TagValue1"
  },
  "id": "/subscriptions/20d7082a-0fc7-4468-82bd-542694d5042b/resourceGroups/testrg/providers/Microsoft.Sql/managedInstances/testinstance",
  "name": "testinstance",
  "type": "Microsoft.Sql/managedInstances"
}

Create managed instance with minimal properties

Sample request

PUT https://management.azure.com/subscriptions/20D7082A-0FC7-4468-82BD-542694D5042B/resourceGroups/testrg/providers/Microsoft.Sql/managedInstances/testinstance?api-version=2023-08-01

{
  "sku": {
    "name": "GP_Gen5",
    "tier": "GeneralPurpose"
  },
  "properties": {
    "administratorLogin": "dummylogin",
    "administratorLoginPassword": "PLACEHOLDER",
    "subnetId": "/subscriptions/20D7082A-0FC7-4468-82BD-542694D5042B/resourceGroups/testrg/providers/Microsoft.Network/virtualNetworks/vnet1/subnets/subnet1",
    "vCores": 8,
    "storageSizeInGB": 1024,
    "licenseType": "LicenseIncluded"
  },
  "location": "Japan East"
}

Sample response

{
  "sku": {
    "name": "GP_Gen5",
    "tier": "GeneralPurpose",
    "capacity": 8,
    "family": "Gen4"
  },
  "properties": {
    "fullyQualifiedDomainName": "testinstance.1b4e2caff2530.database.windows.net",
    "administratorLogin": "dummylogin",
    "subnetId": "/subscriptions/20D7082A-0FC7-4468-82BD-542694D5042B/resourceGroups/testrg/providers/Microsoft.Network/virtualNetworks/vnet1/subnets/subnet1",
    "state": "Ready",
    "provisioningState": "Creating",
    "vCores": 8,
    "storageSizeInGB": 1024,
    "licenseType": "LicenseIncluded",
    "collation": "SQL_Latin1_General_CP1_CI_AS",
    "publicDataEndpointEnabled": false,
    "proxyOverride": "Redirect",
    "dnsZone": "1b4e2caff2530",
    "currentBackupStorageRedundancy": "Geo",
    "requestedBackupStorageRedundancy": "Geo",
    "externalGovernanceStatus": "Enabled",
    "hybridSecondaryUsage": "Passive",
    "databaseFormat": "SQLServer2022"
  },
  "location": "japaneast",
  "tags": {},
  "id": "/subscriptions/20d7082a-0fc7-4468-82bd-542694d5042b/resourceGroups/testrg/providers/Microsoft.Sql/managedInstances/testinstance",
  "name": "testinstance",
  "type": "Microsoft.Sql/managedInstances"
}
{
  "sku": {
    "name": "GP_Gen5",
    "tier": "GeneralPurpose",
    "capacity": 8,
    "family": "Gen4"
  },
  "properties": {
    "fullyQualifiedDomainName": "testinstance.1b4e2caff2530.database.windows.net",
    "administratorLogin": "dummylogin",
    "subnetId": "/subscriptions/20D7082A-0FC7-4468-82BD-542694D5042B/resourceGroups/testrg/providers/Microsoft.Network/virtualNetworks/vnet1/subnets/subnet1",
    "state": "Ready",
    "provisioningState": "Creating",
    "vCores": 8,
    "storageSizeInGB": 1024,
    "licenseType": "LicenseIncluded",
    "collation": "SQL_Latin1_General_CP1_CI_AS",
    "publicDataEndpointEnabled": false,
    "proxyOverride": "Redirect",
    "dnsZone": "1b4e2caff2530",
    "currentBackupStorageRedundancy": "Geo",
    "requestedBackupStorageRedundancy": "Geo",
    "externalGovernanceStatus": "Enabled",
    "hybridSecondaryUsage": "Passive",
    "databaseFormat": "SQLServer2022"
  },
  "location": "japaneast",
  "tags": {},
  "id": "/subscriptions/20d7082a-0fc7-4468-82bd-542694d5042b/resourceGroups/testrg/providers/Microsoft.Sql/managedInstances/testinstance",
  "name": "testinstance",
  "type": "Microsoft.Sql/managedInstances"
}

Definitions

Name Description
AdministratorType

Type of the sever administrator.

AuthMetadataLookupModes

The managed instance's authentication metadata lookup mode.

BackupStorageRedundancy

The storage account type used to store backups for this instance. The options are Local (LocallyRedundantStorage), Zone (ZoneRedundantStorage), Geo (GeoRedundantStorage) and GeoZone(GeoZoneRedundantStorage)

ErrorAdditionalInfo

The resource management error additional info.

ErrorDetail

The error detail.

ErrorResponse

Error response

ExternalGovernanceStatus

Status of external governance.

HybridSecondaryUsage

Hybrid secondary usage. Possible values are 'Active' (default value) and 'Passive' (customer uses the secondary as Passive DR).

HybridSecondaryUsageDetected

Hybrid secondary usage detected. Possible values are 'Active' (customer does not meet the requirements to use the secondary as Passive DR) and 'Passive' (customer meets the requirements to use the secondary as Passive DR).

IdentityType

The identity type. Set this to 'SystemAssigned' in order to automatically create and assign an Azure Active Directory principal for the resource.

ManagedInstance

An Azure SQL managed instance.

ManagedInstanceDatabaseFormat

Specifies the internal format of instance databases specific to the SQL engine version.

ManagedInstanceExternalAdministrator

Properties of a active directory administrator.

ManagedInstanceLicenseType

The license type. Possible values are 'LicenseIncluded' (regular price inclusive of a new SQL license) and 'BasePrice' (discounted AHB price for bringing your own SQL licenses).

ManagedInstancePecProperty

A private endpoint connection under a managed instance

ManagedInstancePrivateEndpointConnectionProperties

Properties of a private endpoint connection.

ManagedInstancePrivateEndpointProperty
ManagedInstancePrivateLinkServiceConnectionStateProperty
ManagedInstanceProxyOverride

Connection type used for connecting to the instance.

ManagedServerCreateMode

Specifies the mode of database creation.

Default: Regular instance creation.

Restore: Creates an instance by restoring a set of backups to specific point in time. RestorePointInTime and SourceManagedInstanceId must be specified.

PricingModel

Pricing model of Managed Instance.

PrincipalType

Principal Type of the sever administrator.

ProvisioningState

Provisioning state of managed instance.

ResourceIdentity

Azure Active Directory identity configuration for a resource.

ServicePrincipal

The managed instance's service principal configuration for a resource.

ServicePrincipalType

Service principal type.

Sku

An ARM Resource SKU.

UserIdentity

Azure Active Directory identity configuration for a resource.

AdministratorType

Type of the sever administrator.

Value Description
ActiveDirectory

AuthMetadataLookupModes

The managed instance's authentication metadata lookup mode.

Value Description
AzureAD
Paired
Windows

BackupStorageRedundancy

The storage account type used to store backups for this instance. The options are Local (LocallyRedundantStorage), Zone (ZoneRedundantStorage), Geo (GeoRedundantStorage) and GeoZone(GeoZoneRedundantStorage)

Value Description
Geo
GeoZone
Local
Zone

ErrorAdditionalInfo

The resource management error additional info.

Name Type Description
info

object

The additional info.

type

string

The additional info type.

ErrorDetail

The error detail.

Name Type Description
additionalInfo

ErrorAdditionalInfo[]

The error additional info.

code

string

The error code.

details

ErrorDetail[]

The error details.

message

string

The error message.

target

string

The error target.

ErrorResponse

Error response

Name Type Description
error

ErrorDetail

The error object.

ExternalGovernanceStatus

Status of external governance.

Value Description
Disabled
Enabled

HybridSecondaryUsage

Hybrid secondary usage. Possible values are 'Active' (default value) and 'Passive' (customer uses the secondary as Passive DR).

Value Description
Active
Passive

HybridSecondaryUsageDetected

Hybrid secondary usage detected. Possible values are 'Active' (customer does not meet the requirements to use the secondary as Passive DR) and 'Passive' (customer meets the requirements to use the secondary as Passive DR).

Value Description
Active
Passive

IdentityType

The identity type. Set this to 'SystemAssigned' in order to automatically create and assign an Azure Active Directory principal for the resource.

Value Description
None
SystemAssigned
SystemAssigned,UserAssigned
UserAssigned

ManagedInstance

An Azure SQL managed instance.

Name Type Description
id

string

Resource ID.

identity

ResourceIdentity

The Azure Active Directory identity of the managed instance.

location

string

Resource location.

name

string

Resource name.

properties.administratorLogin

string

Administrator username for the managed instance. Can only be specified when the managed instance is being created (and is required for creation).

properties.administratorLoginPassword

string

The administrator login password (required for managed instance creation).

properties.administrators

ManagedInstanceExternalAdministrator

The Azure Active Directory administrator of the instance. This can only be used at instance create time. If used for instance update, it will be ignored or it will result in an error. For updates individual APIs will need to be used.

properties.authenticationMetadata

AuthMetadataLookupModes

The managed instance's authentication metadata lookup mode.

properties.collation

string

Collation of the managed instance.

properties.createTime

string (date-time)

Specifies the point in time (ISO8601 format) of the Managed Instance creation.

properties.currentBackupStorageRedundancy

BackupStorageRedundancy

The storage account type used to store backups for this instance. The options are Local (LocallyRedundantStorage), Zone (ZoneRedundantStorage), Geo (GeoRedundantStorage) and GeoZone(GeoZoneRedundantStorage)

properties.databaseFormat

ManagedInstanceDatabaseFormat

Specifies the internal format of instance databases specific to the SQL engine version.

properties.dnsZone

string

The Dns Zone that the managed instance is in.

properties.dnsZonePartner

string (arm-id)

The resource id of another managed instance whose DNS zone this managed instance will share after creation.

properties.externalGovernanceStatus

ExternalGovernanceStatus

Status of external governance.

properties.fullyQualifiedDomainName

string

The fully qualified domain name of the managed instance.

properties.hybridSecondaryUsage

HybridSecondaryUsage

Hybrid secondary usage. Possible values are 'Active' (default value) and 'Passive' (customer uses the secondary as Passive DR).

properties.hybridSecondaryUsageDetected

HybridSecondaryUsageDetected

Hybrid secondary usage detected. Possible values are 'Active' (customer does not meet the requirements to use the secondary as Passive DR) and 'Passive' (customer meets the requirements to use the secondary as Passive DR).

properties.instancePoolId

string

The Id of the instance pool this managed server belongs to.

properties.isGeneralPurposeV2

boolean

Whether or not this is a GPv2 variant of General Purpose edition.

properties.keyId

string

A CMK URI of the key to use for encryption.

properties.licenseType

ManagedInstanceLicenseType

The license type. Possible values are 'LicenseIncluded' (regular price inclusive of a new SQL license) and 'BasePrice' (discounted AHB price for bringing your own SQL licenses).

properties.maintenanceConfigurationId

string

Specifies maintenance configuration id to apply to this managed instance.

properties.managedInstanceCreateMode

ManagedServerCreateMode

Specifies the mode of database creation.

Default: Regular instance creation.

Restore: Creates an instance by restoring a set of backups to specific point in time. RestorePointInTime and SourceManagedInstanceId must be specified.

properties.minimalTlsVersion

string

Minimal TLS version. Allowed values: 'None', '1.0', '1.1', '1.2'

properties.pricingModel

PricingModel

Pricing model of Managed Instance.

properties.primaryUserAssignedIdentityId

string (arm-id)

The resource id of a user assigned identity to be used by default.

properties.privateEndpointConnections

ManagedInstancePecProperty[]

List of private endpoint connections on a managed instance.

properties.provisioningState

ProvisioningState

Provisioning state of managed instance.

properties.proxyOverride

ManagedInstanceProxyOverride

Connection type used for connecting to the instance.

properties.publicDataEndpointEnabled

boolean

Whether or not the public data endpoint is enabled.

properties.requestedBackupStorageRedundancy

BackupStorageRedundancy

The storage account type to be used to store backups for this instance. The options are Local (LocallyRedundantStorage), Zone (ZoneRedundantStorage), Geo (GeoRedundantStorage) and GeoZone(GeoZoneRedundantStorage)

properties.restorePointInTime

string (date-time)

Specifies the point in time (ISO8601 format) of the source database that will be restored to create the new database.

properties.servicePrincipal

ServicePrincipal

The managed instance's service principal.

properties.sourceManagedInstanceId

string (arm-id)

The resource identifier of the source managed instance associated with create operation of this instance.

properties.state

string

The state of the managed instance.

properties.storageIOps

integer (int32)

Storage IOps. Minimum value: 300. Maximum value: 80000. Increments of 1 IOps allowed only. Maximum value depends on the selected hardware family and number of vCores.

properties.storageSizeInGB

integer (int32)

Storage size in GB. Minimum value: 32. Maximum value: 16384. Increments of 32 GB allowed only. Maximum value depends on the selected hardware family and number of vCores.

properties.storageThroughputMBps

integer (int32)

Storage throughput MBps parameter is not supported in the instance create/update operation.

properties.subnetId

string (arm-id)

Subnet resource ID for the managed instance.

properties.timezoneId

string

Id of the timezone. Allowed values are timezones supported by Windows. Windows keeps details on supported timezones, including the id, in registry under KEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Time Zones. You can get those registry values via SQL Server by querying SELECT name AS timezone_id FROM sys.time_zone_info. List of Ids can also be obtained by executing [System.TimeZoneInfo]::GetSystemTimeZones() in PowerShell. An example of valid timezone id is "Pacific Standard Time" or "W. Europe Standard Time".

properties.vCores

integer (int32)

The number of vCores. Allowed values: 8, 16, 24, 32, 40, 64, 80.

properties.virtualClusterId

string

Virtual cluster resource id for the Managed Instance.

properties.zoneRedundant

boolean

Whether or not the multi-az is enabled.

sku

Sku

Managed instance SKU. Allowed values for sku.name: GP_Gen5, GP_G8IM, GP_G8IH, BC_Gen5, BC_G8IM, BC_G8IH

tags

object

Resource tags.

type

string

Resource type.

ManagedInstanceDatabaseFormat

Specifies the internal format of instance databases specific to the SQL engine version.

Value Description
AlwaysUpToDate
SQLServer2022

ManagedInstanceExternalAdministrator

Properties of a active directory administrator.

Name Type Description
administratorType

AdministratorType

Type of the sever administrator.

azureADOnlyAuthentication

boolean

Azure Active Directory only Authentication enabled.

login

string

Login name of the server administrator.

principalType

PrincipalType

Principal Type of the sever administrator.

sid

string (uuid)

SID (object ID) of the server administrator.

tenantId

string (uuid)

Tenant ID of the administrator.

ManagedInstanceLicenseType

The license type. Possible values are 'LicenseIncluded' (regular price inclusive of a new SQL license) and 'BasePrice' (discounted AHB price for bringing your own SQL licenses).

Value Description
BasePrice
LicenseIncluded

ManagedInstancePecProperty

A private endpoint connection under a managed instance

Name Type Description
id

string

Resource ID.

properties

ManagedInstancePrivateEndpointConnectionProperties

Private endpoint connection properties

ManagedInstancePrivateEndpointConnectionProperties

Properties of a private endpoint connection.

Name Type Description
privateEndpoint

ManagedInstancePrivateEndpointProperty

Private endpoint which the connection belongs to.

privateLinkServiceConnectionState

ManagedInstancePrivateLinkServiceConnectionStateProperty

Connection State of the Private Endpoint Connection.

provisioningState

string

State of the Private Endpoint Connection.

ManagedInstancePrivateEndpointProperty

Name Type Description
id

string

Resource id of the private endpoint.

ManagedInstancePrivateLinkServiceConnectionStateProperty

Name Type Description
actionsRequired

string

The private link service connection description.

description

string

The private link service connection description.

status

string

The private link service connection status.

ManagedInstanceProxyOverride

Connection type used for connecting to the instance.

Value Description
Default
Proxy
Redirect

ManagedServerCreateMode

Specifies the mode of database creation.

Default: Regular instance creation.

Restore: Creates an instance by restoring a set of backups to specific point in time. RestorePointInTime and SourceManagedInstanceId must be specified.

Value Description
Default
PointInTimeRestore

PricingModel

Pricing model of Managed Instance.

Value Description
Freemium
Regular

PrincipalType

Principal Type of the sever administrator.

Value Description
Application
Group
User

ProvisioningState

Provisioning state of managed instance.

Value Description
Canceled
Created
Failed
InProgress
Succeeded

ResourceIdentity

Azure Active Directory identity configuration for a resource.

Name Type Description
principalId

string (uuid)

The Azure Active Directory principal id.

tenantId

string (uuid)

The Azure Active Directory tenant id.

type

IdentityType

The identity type. Set this to 'SystemAssigned' in order to automatically create and assign an Azure Active Directory principal for the resource.

userAssignedIdentities

<string,  UserIdentity>

The resource ids of the user assigned identities to use

ServicePrincipal

The managed instance's service principal configuration for a resource.

Name Type Description
clientId

string

The Azure Active Directory application client id.

principalId

string

The Azure Active Directory application object id.

tenantId

string

The Azure Active Directory tenant id.

type

ServicePrincipalType

Service principal type.

ServicePrincipalType

Service principal type.

Value Description
None
SystemAssigned

Sku

An ARM Resource SKU.

Name Type Description
capacity

integer (int32)

Capacity of the particular SKU.

family

string

If the service has different generations of hardware, for the same SKU, then that can be captured here.

name

string

The name of the SKU, typically, a letter + Number code, e.g. P3.

size

string

Size of the particular SKU

tier

string

The tier or edition of the particular SKU, e.g. Basic, Premium.

UserIdentity

Azure Active Directory identity configuration for a resource.

Name Type Description
clientId

string (uuid)

The Azure Active Directory client id.

principalId

string (uuid)

The Azure Active Directory principal id.