swagger: "2.0"
schemes:
  - https
host: management.azure.com
info:
  description: The Azure SQL Database management API provides a RESTful set of web APIs that interact with Azure SQL Database services to manage your databases. The API enables users to create, retrieve, update, and delete databases, servers, and other entities.
  title: SqlManagementClient
  version: 2015-05-01-preview
  x-apisguru-categories:
    - cloud
  x-logo:
    url: https://api.apis.guru/v2/cache/logo/https_assets.onestore.ms_cdnfiles_onestorerolling-1606-01000_shell_v3_images_logo_microsoft.png
  x-origin:
    - format: swagger
      url: https://raw.githubusercontent.com/Azure/azure-rest-api-specs/master/specification/sql/resource-manager/Microsoft.Sql/preview/2015-05-01-preview/managedInstances.json
      version: "2.0"
  x-preferred: false
  x-providerName: azure.com
  x-serviceName: sql-managedInstances
  x-tags:
    - Azure
    - Microsoft
consumes:
  - application/json
produces:
  - application/json
securityDefinitions:
  azure_auth:
    authorizationUrl: https://login.microsoftonline.com/common/oauth2/authorize
    description: Azure Active Directory OAuth2 Flow
    flow: implicit
    scopes:
      user_impersonation: impersonate your user account
    type: oauth2
parameters:
  ApiVersionParameter:
    description: The API version to use for the request.
    in: query
    name: api-version
    required: true
    type: string
    x-ms-parameter-location: client
  BlobAuditingPolicyNameParameter:
    description: The name of the blob auditing policy.
    enum:
      - default
    in: path
    name: blobAuditingPolicyName
    required: true
    type: string
    x-ms-parameter-location: method
  DatabaseNameParameter:
    description: The name of the database.
    in: path
    name: databaseName
    required: true
    type: string
    x-ms-parameter-location: method
  ManagedInstanceNameParameter:
    description: The name of the managed instance.
    in: path
    name: managedInstanceName
    required: true
    type: string
    x-ms-parameter-location: method
  ResourceGroupParameter:
    description: The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.
    in: path
    name: resourceGroupName
    required: true
    type: string
    x-ms-parameter-location: method
  ServerNameParameter:
    description: The name of the server.
    in: path
    name: serverName
    required: true
    type: string
    x-ms-parameter-location: method
  SqlVirtualMachineContainerNameParameter:
    description: The name of the SqlVirtualMachineContainer.
    in: path
    name: sqlVirtualMachineContainerName
    required: true
    type: string
    x-ms-parameter-location: method
  SqlVirtualMachineInstanceNameParameter:
    description: The name of the SqlVirtualMachineInstance.
    in: path
    name: sqlVirtualMachineInstanceName
    required: true
    type: string
    x-ms-parameter-location: method
  SubscriptionIdParameter:
    description: The subscription ID that identifies an Azure subscription.
    in: path
    name: subscriptionId
    required: true
    type: string
    x-ms-parameter-location: client
  VirtualClusterNameParameter:
    description: The name of the virtual cluster.
    in: path
    name: virtualClusterName
    required: true
    type: string
    x-ms-parameter-location: method
paths:
  "/subscriptions/{subscriptionId}/providers/Microsoft.Sql/managedInstances":
    get:
      description: Gets a list of all managed instances in the subscription.
      operationId: ManagedInstances_List
      parameters:
        - $ref: "#/parameters/SubscriptionIdParameter"
        - $ref: "#/parameters/ApiVersionParameter"
      responses:
        "200":
          description: Successfully retrieved the list of managed instances.
          schema:
            $ref: "#/definitions/ManagedInstanceListResult"
        default:
          description: "*** Error Responses: ***"
      tags:
        - ManagedInstances
      x-ms-examples:
        List managed instances:
          parameters:
            api-version: 2015-05-01-preview
            subscriptionId: 20D7082A-0FC7-4468-82BD-542694D5042B
          responses:
            "200":
              body:
                value:
                  - id: /subscriptions/20d7082a-0fc7-4468-82bd-542694d5042b/resourceGroups/Test1/providers/Microsoft.Sql/managedInstances/testinstance1
                    location: japaneast
                    name: testinstance1
                    properties:
                      administratorLogin: dummylogin
                      collation: SQL_Latin1_General_CP1_CI_AS
                      dnsZone: 1b4e2caff2530
                      fullyQualifiedDomainName: testinstance1.1b4e2caff2530.database.windows.net
                      licenseType: LicenseIncluded
                      proxyOverride: Default
                      publicDataEndpointEnabled: false
                      state: Ready
                      storageSizeInGB: 1024
                      subnetId: /subscriptions/20D7082A-0FC7-4468-82BD-542694D5042B/resourceGroups/testrg/providers/Microsoft.Network/virtualNetworks/vnet1/subnets/subnet1
                      vCores: 8
                    sku:
                      capacity: 8
                      family: Gen4
                      name: GP_Gen4
                      tier: GeneralPurpose
                    type: Microsoft.Sql/managedInstances
                  - id: /subscriptions/20d7082a-0fc7-4468-82bd-542694d5042b/resourceGroups/Test1/providers/Microsoft.Sql/managedInstances/testinstance2
                    location: japaneast
                    name: testinstance2
                    properties:
                      administratorLogin: dummylogin
                      collation: SQL_Latin1_General_CP1_CI_AS
                      dnsZone: 2c3d1bdae3412
                      fullyQualifiedDomainName: testinstance2.2c3d1bdae3412.database.windows.net
                      licenseType: Full
                      proxyOverride: Default
                      publicDataEndpointEnabled: false
                      state: Ready
                      storageSizeInGB: 1024
                      subnetId: /subscriptions/20D7082A-0FC7-4468-82BD-542694D5042B/resourceGroups/testrg/providers/Microsoft.Network/virtualNetworks/vnet2/subnets/subnet2
                      vCores: 16
                    sku:
                      capacity: 16
                      family: Gen4
                      name: BC_Gen5
                      tier: BusinessCritical
                    type: Microsoft.Sql/managedInstances
      x-ms-pageable:
        nextLinkName: nextLink
  "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/managedInstances":
    get:
      description: Gets a list of managed instances in a resource group.
      operationId: ManagedInstances_ListByResourceGroup
      parameters:
        - $ref: "#/parameters/ResourceGroupParameter"
        - $ref: "#/parameters/SubscriptionIdParameter"
        - $ref: "#/parameters/ApiVersionParameter"
      responses:
        "200":
          description: Successfully retrieved the list of managed instances.
          schema:
            $ref: "#/definitions/ManagedInstanceListResult"
        default:
          description: |-
            *** Error Responses: ***

             * 400 SubscriptionNotFound - The requested subscription was not found.

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

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

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

             * 404 ResourceNotFound - The requested resource was not found.

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

             * 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.

             * 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.

             * 504 RequestTimeout - Service request exceeded the allowed timeout.

             * 504 RequestTimeout - Service request exceeded the allowed timeout.
      tags:
        - ManagedInstances
      x-ms-examples:
        List managed instances by resource group:
          parameters:
            api-version: 2015-05-01-preview
            resourceGroupName: Test1
            subscriptionId: 20D7082A-0FC7-4468-82BD-542694D5042B
          responses:
            "200":
              body:
                value:
                  - id: /subscriptions/20d7082a-0fc7-4468-82bd-542694d5042b/resourceGroups/Test1/providers/Microsoft.Sql/managedInstances/testinstance1
                    location: japaneast
                    name: testinstance1
                    properties:
                      administratorLogin: dummylogin
                      collation: SQL_Latin1_General_CP1_CI_AS
                      dnsZone: 1b4e2caff2530
                      fullyQualifiedDomainName: testinstance1.1b4e2caff2530.database.windows.net
                      licenseType: LicenseIncluded
                      proxyOverride: Default
                      publicDataEndpointEnabled: false
                      state: Ready
                      storageSizeInGB: 1024
                      subnetId: /subscriptions/20D7082A-0FC7-4468-82BD-542694D5042B/resourceGroups/testrg/providers/Microsoft.Network/virtualNetworks/vnet1/subnets/subnet1
                      vCores: 8
                    sku:
                      capacity: 8
                      family: Gen4
                      name: GP_Gen4
                      tier: GeneralPurpose
                    type: Microsoft.Sql/managedInstances
                  - id: /subscriptions/20d7082a-0fc7-4468-82bd-542694d5042b/resourceGroups/Test1/providers/Microsoft.Sql/managedInstances/testinstance2
                    location: japaneast
                    name: testinstance2
                    properties:
                      administratorLogin: dummylogin
                      collation: SQL_Latin1_General_CP1_CI_AS
                      dnsZone: 2c3d1bdae3412
                      fullyQualifiedDomainName: testinstance2.2c3d1bdae3412.database.windows.net
                      licenseType: Full
                      proxyOverride: Default
                      publicDataEndpointEnabled: false
                      state: Ready
                      storageSizeInGB: 1024
                      subnetId: /subscriptions/20D7082A-0FC7-4468-82BD-542694D5042B/resourceGroups/testrg/providers/Microsoft.Network/virtualNetworks/vnet2/subnets/subnet2
                      vCores: 16
                    sku:
                      capacity: 16
                      family: Gen4
                      name: BC_Gen5
                      tier: BusinessCritical
                    type: Microsoft.Sql/managedInstances
      x-ms-pageable:
        nextLinkName: nextLink
  "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/managedInstances/{managedInstanceName}":
    delete:
      description: Deletes a managed instance.
      operationId: ManagedInstances_Delete
      parameters:
        - $ref: "#/parameters/ResourceGroupParameter"
        - $ref: "#/parameters/ManagedInstanceNameParameter"
        - $ref: "#/parameters/SubscriptionIdParameter"
        - $ref: "#/parameters/ApiVersionParameter"
      responses:
        "200":
          description: Successfully deleted the managed instance.
        "202":
          description: Accepted
        "204":
          description: The specified managed instance does not exist.
        default:
          description: |-
            *** Error Responses: ***

             * 400 SubscriptionNotFound - The requested subscription was not found.

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

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

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

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

             * 404 ResourceNotFound - The requested resource was not found.

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

             * 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.

             * 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.

             * 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.

             * 504 RequestTimeout - Service request exceeded the allowed timeout.

             * 504 RequestTimeout - Service request exceeded the allowed timeout.
      tags:
        - ManagedInstances
      x-ms-examples:
        Delete managed instance:
          parameters:
            api-version: 2015-05-01-preview
            managedInstanceName: testinstance
            resourceGroupName: testrg
            subscriptionId: 20D7082A-0FC7-4468-82BD-542694D5042B
          responses:
            "200": {}
            "202": {}
            "204": {}
      x-ms-long-running-operation: true
    get:
      description: Gets a managed instance.
      operationId: ManagedInstances_Get
      parameters:
        - $ref: "#/parameters/ResourceGroupParameter"
        - $ref: "#/parameters/ManagedInstanceNameParameter"
        - $ref: "#/parameters/SubscriptionIdParameter"
        - $ref: "#/parameters/ApiVersionParameter"
      responses:
        "200":
          description: Successfully retrieved the specified managed instance.
          schema:
            $ref: "#/definitions/ManagedInstance"
        default:
          description: |-
            *** Error Responses: ***

             * 400 SubscriptionNotFound - The requested subscription was not found.

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

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

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

             * 404 ResourceNotFound - The requested resource was not found.

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

             * 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.

             * 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.

             * 504 RequestTimeout - Service request exceeded the allowed timeout.

             * 504 RequestTimeout - Service request exceeded the allowed timeout.
      tags:
        - ManagedInstances
      x-ms-examples:
        Get managed instance:
          parameters:
            api-version: 2015-05-01-preview
            managedInstanceName: testinstance
            resourceGroupName: testrg
            subscriptionId: 20d7082a-0fc7-4468-82bd-542694d5042b
          responses:
            "200":
              body:
                id: /subscriptions/20d7082a-0fc7-4468-82bd-542694d5042b/resourceGroups/testrg/providers/Microsoft.Sql/managedInstances/testinstance
                location: japaneast
                name: testinstance
                properties:
                  administratorLogin: dummylogin
                  collation: SQL_Latin1_General_CP1_CI_AS
                  dnsZone: 1b4e2caff2530
                  fullyQualifiedDomainName: testinstance.1b4e2caff2530.database.windows.net
                  instancePoolId: /subscriptions/20d7082a-0fc7-4468-82bd-542694d5042b/resourceGroups/testrg/providers/Microsoft.Sql/instancePools/instancePool1
                  licenseType: LicenseIncluded
                  proxyOverride: Default
                  publicDataEndpointEnabled: false
                  state: Ready
                  storageSizeInGB: 1024
                  subnetId: /subscriptions/20D7082A-0FC7-4468-82BD-542694D5042B/resourceGroups/testrg/providers/Microsoft.Network/virtualNetworks/vnet1/subnets/subnet1
                  vCores: 8
                sku:
                  capacity: 8
                  family: Gen4
                  name: GP_Gen4
                  tier: GeneralPurpose
                tags:
                  key: value
                type: Microsoft.Sql/managedInstances
    patch:
      description: Updates a managed instance.
      operationId: ManagedInstances_Update
      parameters:
        - $ref: "#/parameters/ResourceGroupParameter"
        - $ref: "#/parameters/ManagedInstanceNameParameter"
        - description: The requested managed instance resource state.
          in: body
          name: parameters
          required: true
          schema:
            $ref: "#/definitions/ManagedInstanceUpdate"
        - $ref: "#/parameters/SubscriptionIdParameter"
        - $ref: "#/parameters/ApiVersionParameter"
      responses:
        "200":
          description: Successfully updated the managed instance.
          schema:
            $ref: "#/definitions/ManagedInstance"
        "202":
          description: Accepted
        default:
          description: |-
            *** Error Responses: ***

             * 400 SubscriptionNotFound - The requested subscription was not found.

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

             * 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 InstanceTimezoneUpdateNotSupported - Instance timezone update not supported.

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

             * 400 ManagedInstanceIpAddressRangeLimit - Cannot create a Managed Instance as there are not enough available ip addresses in the selected subnet

             * 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 InvalidUsername - Supplied user name contains invalid characters.

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

             * 400 InstancePoolNotEnoughCapacity - An instance pool does not have enough vCore capacity

             * 400 ServerNotFound - The requested server was not found.

             * 400 TokenTooLong - The provided token is too long.

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

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

             * 400 InvalidLoginName - The provided login name 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 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 InvalidSubnetResourceId - The provided subnet resource ID for the managed instance create or update is invalid.

             * 400 SubscriptionNotFound - The requested subscription was not found.

             * 400 InvalidLocation - An invalid location was specified.

             * 400 VnetInWrongRegion - Virtual network is in wrong region.

             * 400 InvalidServerName - Invalid server name specified.

             * 400 VnetAddressRangeError - Virtual network address range is invalid.

             * 400 VnetConfigIsNotAllowed - Virtual network configuration is not allowed.

             * 400 InvalidCollation - Invalid collation.

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

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

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

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

             * 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 NameAlreadyExists - The provided name already exists.

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

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

             * 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 InvalidTimezone - Invalid timezone.

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

             * 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 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.

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

             * 404 ManagedInstanceNotInSubscriptionResourceGroup - Specified managed instance does not exist in the specified resource group and 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 ResourceNotFound - The requested resource was not found.

             * 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.

             * 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 ServerAlreadyExists - Duplicate server name.

             * 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 ServerDisabled - Server is disabled.

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

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

             * 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.

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

             * 500 GatewayInternalServerError - The server encountered an unexpected exception.

             * 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.

             * 504 RequestTimeout - Service request exceeded the allowed timeout.

             * 504 RequestTimeout - Service request exceeded the allowed timeout.
      tags:
        - ManagedInstances
      x-ms-examples:
        Update managed instance with all properties:
          parameters:
            api-version: 2015-05-01-preview
            managedInstanceName: testinstance
            parameters:
              properties:
                administratorLogin: dummylogin
                administratorLoginPassword: Un53cuRE!
                collation: SQL_Latin1_General_CP1_CI_AS
                licenseType: BasePrice
                proxyOverride: Redirect
                publicDataEndpointEnabled: false
                storageSizeInGB: 448
                vCores: 8
              sku:
                capacity: 8
                name: GP_Gen4
                tier: GeneralPurpose
              tags:
                tagKey1: TagValue1
            resourceGroupName: testrg
            subscriptionId: 20D7082A-0FC7-4468-82BD-542694D5042B
          responses:
            "200":
              body:
                id: /subscriptions/20D7082A-0FC7-4468-82BD-542694D5042B/resourceGroups/testrg/providers/Microsoft.Sql/managedInstances/testinstance
                location: japaneast
                name: testinstance
                properties:
                  administratorLogin: dummylogin
                  collation: SQL_Latin1_General_CP1_CI_AS
                  dnsZone: 1b4e2caff2530
                  fullyQualifiedDomainName: testinstance.1b4e2caff2530.database.windows.net
                  instancePoolId: /subscriptions/20d7082a-0fc7-4468-82bd-542694d5042b/resourceGroups/testrg/providers/Microsoft.Sql/instancePools/instancePool1
                  licenseType: BasePrice
                  proxyOverride: Redirect
                  publicDataEndpointEnabled: false
                  state: Ready
                  storageSizeInGB: 448
                  subnetId: /subscriptions/20D7082A-0FC7-4468-82BD-542694D5042B/resourceGroups/testrg/providers/Microsoft.Network/virtualNetworks/vnet1/subnets/subnet1
                  vCores: 8
                sku:
                  capacity: 8
                  family: Gen4
                  name: GP_Gen4
                  tier: GeneralPurpose
                tags:
                  tagKey1: TagValue1
                type: Microsoft.Sql/managedInstances
            "202": {}
        Update managed instance with minimal properties:
          parameters:
            api-version: 2015-05-01-preview
            managedInstanceName: testinstance
            parameters:
              tags:
                tagKey1: TagValue1
            resourceGroupName: testrg
            subscriptionId: 20D7082A-0FC7-4468-82BD-542694D5042B
          responses:
            "200":
              body:
                id: /subscriptions/20D7082A-0FC7-4468-82BD-542694D5042B/resourceGroups/testrg/providers/Microsoft.Sql/managedInstances/testinstance
                location: japaneast
                name: testinstance
                properties:
                  administratorLogin: dummylogin
                  collation: SQL_Latin1_General_CP1_CI_AS
                  dnsZone: 1b4e2caff2530
                  fullyQualifiedDomainName: testinstance.1b4e2caff2530.database.windows.net
                  instancePoolId: /subscriptions/20D7082A-0FC7-4468-82BD-542694D5042B/resourceGroups/testrg/providers/Microsoft.Sql/instancePools/instancePool1
                  licenseType: LicenseIncluded
                  proxyOverride: Default
                  publicDataEndpointEnabled: false
                  state: Ready
                  storageSizeInGB: 1024
                  subnetId: /subscriptions/20D7082A-0FC7-4468-82BD-542694D5042B/resourceGroups/testrg/providers/Microsoft.Network/virtualNetworks/vnet1/subnets/subnet1
                  vCores: 8
                sku:
                  capacity: 8
                  family: Gen4
                  name: GP_Gen4
                  tier: GeneralPurpose
                tags:
                  tagKey1: TagValue1
                type: Microsoft.Sql/managedInstances
            "202": {}
      x-ms-long-running-operation: true
    put:
      description: Creates or updates a managed instance.
      operationId: ManagedInstances_CreateOrUpdate
      parameters:
        - $ref: "#/parameters/ResourceGroupParameter"
        - $ref: "#/parameters/ManagedInstanceNameParameter"
        - description: The requested managed instance resource state.
          in: body
          name: parameters
          required: true
          schema:
            $ref: "#/definitions/ManagedInstance"
        - $ref: "#/parameters/SubscriptionIdParameter"
        - $ref: "#/parameters/ApiVersionParameter"
      responses:
        "200":
          description: Successfully updated the managed instance.
          schema:
            $ref: "#/definitions/ManagedInstance"
        "201":
          description: Successfully created the managed instance.
          schema:
            $ref: "#/definitions/ManagedInstance"
        "202":
          description: Accepted
        default:
          description: |-
            *** Error Responses: ***

             * 400 SubscriptionNotFound - The requested subscription was not found.

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

             * 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 InstanceTimezoneUpdateNotSupported - Instance timezone update not supported.

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

             * 400 ManagedInstanceIpAddressRangeLimit - Cannot create a Managed Instance as there are not enough available ip addresses in the selected subnet

             * 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 InvalidUsername - Supplied user name contains invalid characters.

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

             * 400 InstancePoolNotEnoughCapacity - An instance pool does not have enough vCore capacity

             * 400 ServerNotFound - The requested server was not found.

             * 400 TokenTooLong - The provided token is too long.

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

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

             * 400 InvalidLoginName - The provided login name 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 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 InvalidSubnetResourceId - The provided subnet resource ID for the managed instance create or update is invalid.

             * 400 SubscriptionNotFound - The requested subscription was not found.

             * 400 InvalidLocation - An invalid location was specified.

             * 400 VnetInWrongRegion - Virtual network is in wrong region.

             * 400 InvalidServerName - Invalid server name specified.

             * 400 VnetAddressRangeError - Virtual network address range is invalid.

             * 400 VnetConfigIsNotAllowed - Virtual network configuration is not allowed.

             * 400 InvalidCollation - Invalid collation.

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

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

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

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

             * 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 NameAlreadyExists - The provided name already exists.

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

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

             * 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 InvalidTimezone - Invalid timezone.

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

             * 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 InvalidManagedServerDnsZonePartner - Invalid DNS zone partner resource id specified in properties.

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

             * 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.

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

             * 404 ManagedInstanceNotInSubscriptionResourceGroup - Specified managed instance does not exist in the specified resource group and 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 ResourceNotFound - The requested resource was not found.

             * 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.

             * 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 ServerAlreadyExists - Duplicate server name.

             * 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 ServerDisabled - Server is disabled.

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

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

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

             * 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.

             * 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.

             * 504 RequestTimeout - Service request exceeded the allowed timeout.

             * 504 RequestTimeout - Service request exceeded the allowed timeout.

             * 504 RequestTimeout - Service request exceeded the allowed timeout.
      tags:
        - ManagedInstances
      x-ms-examples:
        Create managed instance with all properties:
          parameters:
            api-version: 2015-05-01-preview
            managedInstanceName: testinstance
            parameters:
              location: Japan East
              properties:
                administratorLogin: dummylogin
                administratorLoginPassword: Un53cuRE!
                collation: SQL_Latin1_General_CP1_CI_AS
                dnsZonePartner: /subscriptions/20D7082A-0FC7-4468-82BD-542694D5042B/resourceGroups/testrg/providers/Microsoft.Sql/managedInstances/testinstance
                instancePoolId: /subscriptions/20D7082A-0FC7-4468-82BD-542694D5042B/resourceGroups/testrg/providers/Microsoft.Sql/instancePools/pool1
                licenseType: LicenseIncluded
                proxyOverride: Redirect
                publicDataEndpointEnabled: false
                storageSizeInGB: 1024
                subnetId: /subscriptions/20D7082A-0FC7-4468-82BD-542694D5042B/resourceGroups/testrg/providers/Microsoft.Network/virtualNetworks/vnet1/subnets/subnet1
                timezoneId: UTC
                vCores: 8
              sku:
                name: GP_Gen5
                tier: GeneralPurpose
              tags:
                tagKey1: TagValue1
            resourceGroupName: testrg
            subscriptionId: 20D7082A-0FC7-4468-82BD-542694D5042B
          responses:
            "200":
              body:
                id: /subscriptions/20D7082A-0FC7-4468-82BD-542694D5042B/resourceGroups/testrg/providers/Microsoft.Sql/managedInstances/testinstance
                location: japaneast
                name: testinstance
                properties:
                  administratorLogin: dummylogin
                  collation: SQL_Latin1_General_CP1_CI_AS
                  dnsZone: 1b4e2caff2530
                  fullyQualifiedDomainName: testinstance.1b4e2caff2530.database.windows.net
                  instancePoolId: /subscriptions/20D7082A-0FC7-4468-82BD-542694D5042B/resourceGroups/testrg/providers/Microsoft.Sql/instancePools/pool1
                  licenseType: LicenseIncluded
                  proxyOverride: Redirect
                  publicDataEndpointEnabled: false
                  state: Ready
                  storageSizeInGB: 1024
                  subnetId: /subscriptions/20D7082A-0FC7-4468-82BD-542694D5042B/resourceGroups/testrg/providers/Microsoft.Network/virtualNetworks/vnet1/subnets/subnet1
                  timezoneId: UTC
                  vCores: 8
                sku:
                  capacity: 8
                  family: Gen5
                  name: GP_Gen5
                  tier: GeneralPurpose
                tags:
                  tagKey1: TagValue1
                type: Microsoft.Sql/managedInstances
            "201":
              body:
                id: /subscriptions/20d7082a-0fc7-4468-82bd-542694d5042b/resourceGroups/testrg/providers/Microsoft.Sql/managedInstances/testinstance
                location: japaneast
                name: testinstance
                properties:
                  administratorLogin: dummylogin
                  collation: SQL_Latin1_General_CP1_CI_AS
                  dnsZone: 1b4e2caff2530
                  fullyQualifiedDomainName: testinstance.1b4e2caff2530.database.windows.net
                  instancePoolId: /subscriptions/20d7082a-0fc7-4468-82bd-542694d5042b/resourceGroups/testrg/providers/Microsoft.Sql/instancePools/pool1
                  licenseType: LicenseIncluded
                  proxyOverride: Redirect
                  publicDataEndpointEnabled: false
                  state: Ready
                  storageSizeInGB: 1024
                  subnetId: /subscriptions/20D7082A-0FC7-4468-82BD-542694D5042B/resourceGroups/testrg/providers/Microsoft.Network/virtualNetworks/vnet1/subnets/subnet1
                  timezoneId: UTC
                  vCores: 8
                sku:
                  capacity: 8
                  family: Gen5
                  name: GP_Gen5
                  tier: GeneralPurpose
                tags:
                  tagKey1: TagValue1
                type: Microsoft.Sql/managedInstances
            "202": {}
        Create managed instance with minimal properties:
          parameters:
            api-version: 2015-05-01-preview
            managedInstanceName: testinstance
            parameters:
              location: Japan East
              properties:
                administratorLogin: dummylogin
                administratorLoginPassword: Un53cuRE!
                licenseType: LicenseIncluded
                storageSizeInGB: 1024
                subnetId: /subscriptions/20D7082A-0FC7-4468-82BD-542694D5042B/resourceGroups/testrg/providers/Microsoft.Network/virtualNetworks/vnet1/subnets/subnet1
                vCores: 8
              sku:
                name: GP_Gen4
                tier: GeneralPurpose
            resourceGroupName: testrg
            subscriptionId: 20D7082A-0FC7-4468-82BD-542694D5042B
          responses:
            "200":
              body:
                id: /subscriptions/20d7082a-0fc7-4468-82bd-542694d5042b/resourceGroups/testrg/providers/Microsoft.Sql/managedInstances/testinstance
                location: japaneast
                name: testinstance
                properties:
                  administratorLogin: dummylogin
                  collation: SQL_Latin1_General_CP1_CI_AS
                  dnsZone: 1b4e2caff2530
                  fullyQualifiedDomainName: testinstance.1b4e2caff2530.database.windows.net
                  licenseType: LicenseIncluded
                  proxyOverride: Default
                  publicDataEndpointEnabled: false
                  state: Ready
                  storageSizeInGB: 1024
                  subnetId: /subscriptions/20D7082A-0FC7-4468-82BD-542694D5042B/resourceGroups/testrg/providers/Microsoft.Network/virtualNetworks/vnet1/subnets/subnet1
                  vCores: 8
                sku:
                  capacity: 8
                  family: Gen4
                  name: GP_Gen4
                  tier: GeneralPurpose
                tags: {}
                type: Microsoft.Sql/managedInstances
            "201":
              body:
                id: /subscriptions/20d7082a-0fc7-4468-82bd-542694d5042b/resourceGroups/testrg/providers/Microsoft.Sql/managedInstances/testinstance
                location: japaneast
                name: testinstance
                properties:
                  administratorLogin: dummylogin
                  collation: SQL_Latin1_General_CP1_CI_AS
                  dnsZone: 1b4e2caff2530
                  fullyQualifiedDomainName: testinstance.1b4e2caff2530.database.windows.net
                  licenseType: LicenseIncluded
                  proxyOverride: Redirect
                  publicDataEndpointEnabled: false
                  state: Ready
                  storageSizeInGB: 1024
                  subnetId: /subscriptions/20D7082A-0FC7-4468-82BD-542694D5042B/resourceGroups/testrg/providers/Microsoft.Network/virtualNetworks/vnet1/subnets/subnet1
                  vCores: 8
                sku:
                  capacity: 8
                  family: Gen4
                  name: GP_Gen4
                  tier: GeneralPurpose
                tags: {}
                type: Microsoft.Sql/managedInstances
            "202": {}
      x-ms-long-running-operation: true
definitions:
  ManagedInstance:
    allOf:
      - allOf:
          - description: ARM resource.
            properties:
              id:
                description: Resource ID.
                readOnly: true
                type: string
              name:
                description: Resource name.
                readOnly: true
                type: string
              type:
                description: Resource type.
                readOnly: true
                type: string
            type: object
            x-ms-azure-resource: true
        description: ARM tracked top level resource.
        properties:
          location:
            description: Resource location.
            type: string
            x-ms-mutability:
              - read
              - create
          tags:
            additionalProperties:
              type: string
            description: Resource tags.
            type: object
        required:
          - location
        type: object
    description: An Azure SQL managed instance.
    properties:
      identity:
        description: Azure Active Directory identity configuration for a resource.
        properties:
          principalId:
            description: The Azure Active Directory principal id.
            format: uuid
            readOnly: true
            type: string
          tenantId:
            description: The Azure Active Directory tenant id.
            format: uuid
            readOnly: true
            type: string
          type:
            description: The identity type. Set this to 'SystemAssigned' in order to automatically create and assign an Azure Active Directory principal for the resource.
            enum:
              - SystemAssigned
            type: string
            x-ms-enum:
              modelAsString: true
              name: IdentityType
        type: object
      properties:
        $ref: "#/definitions/ManagedInstanceProperties"
        description: Resource properties.
        x-ms-client-flatten: true
      sku:
        description: An ARM Resource SKU.
        properties:
          capacity:
            description: Capacity of the particular SKU.
            format: int32
            type: integer
          family:
            description: If the service has different generations of hardware, for the same SKU, then that can be captured here.
            type: string
          name:
            description: The name of the SKU, typically, a letter + Number code, e.g. P3.
            type: string
          size:
            description: Size of the particular SKU
            type: string
          tier:
            description: The tier or edition of the particular SKU, e.g. Basic, Premium.
            type: string
        required:
          - name
        type: object
    required:
      - location
    type: object
  ManagedInstanceListResult:
    description: A list of managed instances.
    properties:
      nextLink:
        description: Link to retrieve next page of results.
        readOnly: true
        type: string
      value:
        description: Array of results.
        items:
          $ref: "#/definitions/ManagedInstance"
        readOnly: true
        type: array
    type: object
  ManagedInstanceProperties:
    description: The properties of a managed instance.
    properties:
      administratorLogin:
        description: Administrator username for the managed instance. Can only be specified when the managed instance is being created (and is required for creation).
        type: string
        x-ms-mutability:
          - read
          - create
      administratorLoginPassword:
        description: The administrator login password (required for managed instance creation).
        type: string
        x-ms-mutability:
          - create
          - update
      collation:
        description: Collation of the managed instance.
        type: string
        x-ms-mutability:
          - read
          - create
      dnsZone:
        description: The Dns Zone that the managed instance is in.
        readOnly: true
        type: string
      dnsZonePartner:
        description: The resource id of another managed instance whose DNS zone this managed instance will share after creation.
        type: string
        x-ms-mutability:
          - create
      fullyQualifiedDomainName:
        description: The fully qualified domain name of the managed instance.
        readOnly: true
        type: string
      instancePoolId:
        description: The Id of the instance pool this managed server belongs to.
        type: string
      licenseType:
        description: 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).
        enum:
          - LicenseIncluded
          - BasePrice
        type: string
        x-ms-enum:
          modelAsString: true
          name: ManagedInstanceLicenseType
      managedInstanceCreateMode:
        description: "Specifies the mode of database creation.\r

          \r

          Default: Regular instance creation.\r

          \r

          Restore: Creates an instance by restoring a set of backups to specific point in time. RestorePointInTime and SourceManagedInstanceId must be specified."
        enum:
          - Default
          - PointInTimeRestore
        type: string
        x-ms-enum:
          modelAsString: true
          name: ManagedServerCreateMode
        x-ms-mutability:
          - create
      proxyOverride:
        description: Connection type used for connecting to the instance.
        enum:
          - Proxy
          - Redirect
          - Default
        type: string
        x-ms-enum:
          modelAsString: true
          name: ManagedInstanceProxyOverride
      publicDataEndpointEnabled:
        description: Whether or not the public data endpoint is enabled.
        type: boolean
      restorePointInTime:
        description: Specifies the point in time (ISO8601 format) of the source database that will be restored to create the new database.
        format: date-time
        type: string
        x-ms-mutability:
          - create
      sourceManagedInstanceId:
        description: The resource identifier of the source managed instance associated with create operation of this instance.
        type: string
        x-ms-mutability:
          - create
      state:
        description: The state of the managed instance.
        readOnly: true
        type: string
      storageSizeInGB:
        description: "Storage size in GB. Minimum value: 32. Maximum value: 8192. Increments of 32 GB allowed only."
        format: int32
        type: integer
      subnetId:
        description: Subnet resource ID for the managed instance.
        type: string
      timezoneId:
        description: "Id of the timezone. Allowed values are timezones supported by Windows.\r

          Windows keeps details on supported timezones, including the id, in registry under\r

          KEY_LOCAL_MACHINE\\SOFTWARE\\Microsoft\\Windows NT\\CurrentVersion\\Time Zones.\r

          You can get those registry values via SQL Server by querying SELECT name AS timezone_id FROM sys.time_zone_info.\r

          List of Ids can also be obtained by executing [System.TimeZoneInfo]::GetSystemTimeZones() in PowerShell.\r

          An example of valid timezone id is \"Pacific Standard Time\" or \"W. Europe Standard Time\"."
        type: string
        x-ms-mutability:
          - read
          - create
      vCores:
        description: "The number of vCores. Allowed values: 8, 16, 24, 32, 40, 64, 80."
        format: int32
        type: integer
    type: object
  ManagedInstanceUpdate:
    description: An update request for an Azure SQL Database managed instance.
    properties:
      properties:
        $ref: "#/definitions/ManagedInstanceProperties"
        description: Resource properties.
        x-ms-client-flatten: true
      sku:
        description: An ARM Resource SKU.
        properties:
          capacity:
            description: Capacity of the particular SKU.
            format: int32
            type: integer
          family:
            description: If the service has different generations of hardware, for the same SKU, then that can be captured here.
            type: string
          name:
            description: The name of the SKU, typically, a letter + Number code, e.g. P3.
            type: string
          size:
            description: Size of the particular SKU
            type: string
          tier:
            description: The tier or edition of the particular SKU, e.g. Basic, Premium.
            type: string
        required:
          - name
        type: object
      tags:
        additionalProperties:
          type: string
        description: Resource tags.
        type: object
    type: object
