Microsoft.Compute (stable:2025-04-01)

2025/10/15 • 11 updated methods

VirtualMachines_ListByLocation (updated)
Description Gets all the virtual machines under the specified subscription for the specified location.
Reference Link ¶

⚶ Changes

{
  "#id": "VirtualMachines_ListByLocation",
  "$responses": {
    "200": {
      "$properties": {
        "value": {
          "$properties": {
            "properties": [
              {
                "storageProfile": [
                  {
                    "dataDisks": {
                      "$properties": [
                        {
                          "#name": "diskIOPSReadWrite",
                          "Description": {
                            "new": "Specifies the Read-Write IOPS for the managed disk when StorageAccountType is UltraSSD_LRS.",
                            "old": "Specifies the Read-Write IOPS for the managed disk when StorageAccountType is UltraSSD_LRS. Returned only for VirtualMachine ScaleSet VM disks. Can be updated only via updates to the VirtualMachine Scale Set."
                          }
                        },
                        {
                          "#name": "diskMBpsReadWrite",
                          "Description": {
                            "new": "Specifies the bandwidth in MB per second for the managed disk when StorageAccountType is UltraSSD_LRS.",
                            "old": "Specifies the bandwidth in MB per second for the managed disk when StorageAccountType is UltraSSD_LRS. Returned only for VirtualMachine ScaleSet VM disks. Can be updated only via updates to the VirtualMachine Scale Set."
                          }
                        }
                      ]
                    }
                  }
                ]
              }
            ]
          }
        }
      }
    }
  }
}

⚼ Request

GET:  /subscriptions/{subscriptionId}/providers/Microsoft.Compute/locations/{location}/virtualMachines
{
api-version: string ,
subscriptionId: string ,
location: string ,
}

⚐ Response (200)

{
value:
[
{
properties:
{
hardwareProfile:
{
vmSize: enum ,
vmSizeProperties:
{
vCPUsAvailable: integer ,
vCPUsPerCore: integer ,
}
,
}
,
scheduledEventsPolicy:
{
userInitiatedRedeploy:
{
automaticallyApprove: boolean ,
}
,
userInitiatedReboot:
{
automaticallyApprove: boolean ,
}
,
scheduledEventsAdditionalPublishingTargets:
{
eventGridAndResourceGraph:
{
enable: boolean ,
scheduledEventsApiVersion: string ,
}
,
}
,
allInstancesDown:
{
automaticallyApprove: boolean ,
}
,
}
,
storageProfile:
{
imageReference:
{
publisher: string ,
offer: string ,
sku: string ,
version: string ,
exactVersion: string ,
sharedGalleryImageId: string ,
communityGalleryImageId: string ,
}
,
osDisk:
{
osType: enum ,
encryptionSettings:
{
diskEncryptionKey:
{
secretUrl: string ,
sourceVault:
{
id: string ,
}
,
}
,
keyEncryptionKey:
{
keyUrl: string ,
sourceVault:
{
id: string ,
}
,
}
,
enabled: boolean ,
}
,
name: string ,
vhd:
{
uri: string ,
}
,
image:
{
uri: string ,
}
,
caching: enum ,
writeAcceleratorEnabled: boolean ,
diffDiskSettings:
{
option: enum ,
placement: enum ,
}
,
createOption: enum ,
diskSizeGB: integer ,
managedDisk:
{
storageAccountType: enum ,
diskEncryptionSet: object ,
securityProfile:
{
securityEncryptionType: enum ,
diskEncryptionSet: object ,
}
,
}
,
deleteOption: enum ,
}
,
dataDisks:
[
{
lun: integer ,
name: string ,
vhd:
{
uri: string ,
}
,
image:
{
uri: string ,
}
,
caching: enum ,
writeAcceleratorEnabled: boolean ,
createOption: enum ,
diskSizeGB: integer ,
managedDisk:
{
storageAccountType: enum ,
diskEncryptionSet: object ,
securityProfile:
{
securityEncryptionType: enum ,
diskEncryptionSet: object ,
}
,
}
,
sourceResource:
{
id: string ,
}
,
toBeDetached: boolean ,
diskIOPSReadWrite: integer ,
diskMBpsReadWrite: integer ,
detachOption: enum ,
deleteOption: enum ,
}
,
]
,
diskControllerType: enum ,
alignRegionalDisksToVMZone: boolean ,
}
,
additionalCapabilities:
{
ultraSSDEnabled: boolean ,
hibernationEnabled: boolean ,
enableFips1403Encryption: boolean ,
}
,
osProfile:
{
computerName: string ,
adminUsername: string ,
adminPassword: string ,
customData: string ,
windowsConfiguration:
{
provisionVMAgent: boolean ,
enableAutomaticUpdates: boolean ,
timeZone: string ,
additionalUnattendContent:
[
{
passName: enum ,
componentName: enum ,
settingName: enum ,
content: string ,
}
,
]
,
patchSettings:
{
patchMode: enum ,
enableHotpatching: boolean ,
assessmentMode: enum ,
automaticByPlatformSettings:
{
rebootSetting: enum ,
bypassPlatformSafetyChecksOnUserSchedule: boolean ,
}
,
}
,
winRM:
{
listeners:
[
{
protocol: enum ,
certificateUrl: string ,
}
,
]
,
}
,
enableVMAgentPlatformUpdates: boolean ,
}
,
linuxConfiguration:
{
disablePasswordAuthentication: boolean ,
ssh:
{
publicKeys:
[
{
path: string ,
keyData: string ,
}
,
]
,
}
,
provisionVMAgent: boolean ,
patchSettings:
{
patchMode: enum ,
assessmentMode: enum ,
automaticByPlatformSettings:
{
rebootSetting: enum ,
bypassPlatformSafetyChecksOnUserSchedule: boolean ,
}
,
}
,
enableVMAgentPlatformUpdates: boolean ,
}
,
secrets:
[
{
sourceVault:
{
id: string ,
}
,
vaultCertificates:
[
{
certificateUrl: string ,
certificateStore: string ,
}
,
]
,
}
,
]
,
allowExtensionOperations: boolean ,
requireGuestProvisionSignal: boolean ,
}
,
networkProfile:
{
networkInterfaces:
[
{
properties:
{
primary: boolean ,
deleteOption: enum ,
}
,
}
,
]
,
networkApiVersion: enum ,
networkInterfaceConfigurations:
[
{
name: string ,
properties:
{
primary: boolean ,
deleteOption: enum ,
enableAcceleratedNetworking: boolean ,
disableTcpStateTracking: boolean ,
enableFpga: boolean ,
enableIPForwarding: boolean ,
networkSecurityGroup:
{
id: string ,
}
,
dnsSettings:
{
dnsServers:
[
string ,
]
,
}
,
ipConfigurations:
[
{
name: string ,
properties:
{
subnet:
{
id: string ,
}
,
primary: boolean ,
publicIPAddressConfiguration:
{
name: string ,
properties:
{
idleTimeoutInMinutes: integer ,
deleteOption: enum ,
dnsSettings:
{
domainNameLabel: string ,
domainNameLabelScope: enum ,
}
,
ipTags:
[
{
ipTagType: string ,
tag: string ,
}
,
]
,
publicIPPrefix:
{
id: string ,
}
,
publicIPAddressVersion: enum ,
publicIPAllocationMethod: enum ,
}
,
sku:
{
name: enum ,
tier: enum ,
}
,
tags: object ,
}
,
privateIPAddressVersion: enum ,
applicationSecurityGroups:
[
{
id: string ,
}
,
]
,
applicationGatewayBackendAddressPools:
[
{
id: string ,
}
,
]
,
loadBalancerBackendAddressPools:
[
{
id: string ,
}
,
]
,
}
,
}
,
]
,
dscpConfiguration:
{
id: string ,
}
,
auxiliaryMode: enum ,
auxiliarySku: enum ,
}
,
tags: object ,
}
,
]
,
}
,
securityProfile:
{
uefiSettings:
{
secureBootEnabled: boolean ,
vTpmEnabled: boolean ,
}
,
encryptionAtHost: boolean ,
securityType: enum ,
encryptionIdentity:
{
userAssignedIdentityResourceId: string ,
}
,
proxyAgentSettings:
{
enabled: boolean ,
mode: enum ,
keyIncarnationId: integer ,
wireServer:
{
mode: enum ,
inVMAccessControlProfileReferenceId: string ,
}
,
imds:
{
mode: enum ,
inVMAccessControlProfileReferenceId: string ,
}
,
addProxyAgentExtension: boolean ,
}
,
}
,
diagnosticsProfile:
{
bootDiagnostics:
{
enabled: boolean ,
storageUri: string ,
}
,
}
,
availabilitySet:
{
id: string ,
}
,
virtualMachineScaleSet:
{
id: string ,
}
,
proximityPlacementGroup:
{
id: string ,
}
,
priority: enum ,
evictionPolicy: enum ,
billingProfile:
{
maxPrice: number ,
}
,
host:
{
id: string ,
}
,
hostGroup:
{
id: string ,
}
,
provisioningState: string ,
instanceView:
{
platformUpdateDomain: integer ,
platformFaultDomain: integer ,
computerName: string ,
osName: string ,
osVersion: string ,
hyperVGeneration: enum ,
rdpThumbPrint: string ,
vmAgent:
{
vmAgentVersion: string ,
extensionHandlers:
[
{
type: string ,
typeHandlerVersion: string ,
status:
{
code: string ,
level: enum ,
displayStatus: string ,
message: string ,
time: string ,
}
,
}
,
]
,
statuses:
[
{
code: string ,
level: enum ,
displayStatus: string ,
message: string ,
time: string ,
}
,
]
,
}
,
maintenanceRedeployStatus:
{
isCustomerInitiatedMaintenanceAllowed: boolean ,
preMaintenanceWindowStartTime: string ,
preMaintenanceWindowEndTime: string ,
maintenanceWindowStartTime: string ,
maintenanceWindowEndTime: string ,
lastOperationResultCode: enum ,
lastOperationMessage: string ,
}
,
disks:
[
{
name: string ,
encryptionSettings:
[
{
diskEncryptionKey:
{
secretUrl: string ,
sourceVault:
{
id: string ,
}
,
}
,
keyEncryptionKey:
{
keyUrl: string ,
sourceVault:
{
id: string ,
}
,
}
,
enabled: boolean ,
}
,
]
,
statuses:
[
{
code: string ,
level: enum ,
displayStatus: string ,
message: string ,
time: string ,
}
,
]
,
}
,
]
,
extensions:
[
{
name: string ,
type: string ,
typeHandlerVersion: string ,
substatuses:
[
{
code: string ,
level: enum ,
displayStatus: string ,
message: string ,
time: string ,
}
,
]
,
statuses:
[
{
code: string ,
level: enum ,
displayStatus: string ,
message: string ,
time: string ,
}
,
]
,
}
,
]
,
vmHealth:
{
status:
{
code: string ,
level: enum ,
displayStatus: string ,
message: string ,
time: string ,
}
,
}
,
bootDiagnostics:
{
consoleScreenshotBlobUri: string ,
serialConsoleLogBlobUri: string ,
status:
{
code: string ,
level: enum ,
displayStatus: string ,
message: string ,
time: string ,
}
,
}
,
assignedHost: string ,
statuses:
[
{
code: string ,
level: enum ,
displayStatus: string ,
message: string ,
time: string ,
}
,
]
,
patchStatus:
{
availablePatchSummary:
{
status: enum ,
assessmentActivityId: string ,
rebootPending: boolean ,
criticalAndSecurityPatchCount: integer ,
otherPatchCount: integer ,
startTime: string ,
lastModifiedTime: string ,
error:
{
details:
[
{
code: string ,
target: string ,
message: string ,
}
,
]
,
innererror:
{
exceptiontype: string ,
errordetail: string ,
}
,
code: string ,
target: string ,
message: string ,
}
,
}
,
lastPatchInstallationSummary:
{
status: enum ,
installationActivityId: string ,
maintenanceWindowExceeded: boolean ,
notSelectedPatchCount: integer ,
excludedPatchCount: integer ,
pendingPatchCount: integer ,
installedPatchCount: integer ,
failedPatchCount: integer ,
startTime: string ,
lastModifiedTime: string ,
error:
{
details:
[
{
code: string ,
target: string ,
message: string ,
}
,
]
,
innererror:
{
exceptiontype: string ,
errordetail: string ,
}
,
code: string ,
target: string ,
message: string ,
}
,
}
,
configurationStatuses:
[
{
code: string ,
level: enum ,
displayStatus: string ,
message: string ,
time: string ,
}
,
]
,
}
,
isVMInStandbyPool: boolean ,
}
,
licenseType: string ,
vmId: string ,
extensionsTimeBudget: string ,
platformFaultDomain: integer ,
scheduledEventsProfile:
{
terminateNotificationProfile:
{
notBeforeTimeout: string ,
enable: boolean ,
}
,
osImageNotificationProfile:
{
notBeforeTimeout: string ,
enable: boolean ,
}
,
}
,
userData: string ,
capacityReservation:
{
capacityReservationGroup:
{
id: string ,
}
,
}
,
applicationProfile:
{
galleryApplications:
[
{
tags: string ,
order: integer ,
packageReferenceId: string ,
configurationReference: string ,
treatFailureAsDeploymentFailure: boolean ,
enableAutomaticUpgrade: boolean ,
}
,
]
,
}
,
timeCreated: string ,
}
,
plan:
{
name: string ,
publisher: string ,
product: string ,
promotionCode: string ,
}
,
resources:
[
{
properties:
{
forceUpdateTag: string ,
publisher: string ,
type: string ,
typeHandlerVersion: string ,
autoUpgradeMinorVersion: boolean ,
enableAutomaticUpgrade: boolean ,
settings: string ,
protectedSettings: string ,
provisioningState: string ,
instanceView:
{
name: string ,
type: string ,
typeHandlerVersion: string ,
substatuses:
[
{
code: string ,
level: enum ,
displayStatus: string ,
message: string ,
time: string ,
}
,
]
,
statuses:
[
{
code: string ,
level: enum ,
displayStatus: string ,
message: string ,
time: string ,
}
,
]
,
}
,
suppressFailures: boolean ,
protectedSettingsFromKeyVault:
{
secretUrl: string ,
sourceVault:
{
id: string ,
}
,
}
,
provisionAfterExtensions:
[
string ,
]
,
}
,
}
,
]
,
identity:
{
principalId: string ,
tenantId: string ,
type: enum ,
userAssignedIdentities: object ,
}
,
zones:
[
string ,
]
,
extendedLocation:
{
name: string ,
type: enum ,
}
,
managedBy: string ,
etag: string ,
placement:
{
zonePlacementPolicy: enum ,
includeZones:
[
string ,
]
,
excludeZones:
[
string ,
]
,
}
,
}
,
]
,
nextLink: string ,
}

⚐ Response (default)

{
error:
{
details:
[
{
code: string ,
target: string ,
message: string ,
}
,
]
,
innererror:
{
exceptiontype: string ,
errordetail: string ,
}
,
code: string ,
target: string ,
message: string ,
}
,
}
VirtualMachines_ListAll (updated)
Description Lists all of the virtual machines in the specified subscription. Use the nextLink property in the response to get the next page of virtual machines.
Reference Link ¶

⚶ Changes

{
  "#id": "VirtualMachines_ListAll",
  "$responses": {
    "200": {
      "$properties": {
        "value": {
          "$properties": {
            "properties": [
              {
                "storageProfile": [
                  {
                    "dataDisks": {
                      "$properties": [
                        {
                          "#name": "diskIOPSReadWrite",
                          "Description": {
                            "new": "Specifies the Read-Write IOPS for the managed disk when StorageAccountType is UltraSSD_LRS.",
                            "old": "Specifies the Read-Write IOPS for the managed disk when StorageAccountType is UltraSSD_LRS. Returned only for VirtualMachine ScaleSet VM disks. Can be updated only via updates to the VirtualMachine Scale Set."
                          }
                        },
                        {
                          "#name": "diskMBpsReadWrite",
                          "Description": {
                            "new": "Specifies the bandwidth in MB per second for the managed disk when StorageAccountType is UltraSSD_LRS.",
                            "old": "Specifies the bandwidth in MB per second for the managed disk when StorageAccountType is UltraSSD_LRS. Returned only for VirtualMachine ScaleSet VM disks. Can be updated only via updates to the VirtualMachine Scale Set."
                          }
                        }
                      ]
                    }
                  }
                ]
              }
            ]
          }
        }
      }
    }
  }
}

⚼ Request

GET:  /subscriptions/{subscriptionId}/providers/Microsoft.Compute/virtualMachines
{
api-version: string ,
subscriptionId: string ,
statusOnly: string ,
$filter: string ,
$expand: string ,
}

⚐ Response (200)

{
value:
[
{
properties:
{
hardwareProfile:
{
vmSize: enum ,
vmSizeProperties:
{
vCPUsAvailable: integer ,
vCPUsPerCore: integer ,
}
,
}
,
scheduledEventsPolicy:
{
userInitiatedRedeploy:
{
automaticallyApprove: boolean ,
}
,
userInitiatedReboot:
{
automaticallyApprove: boolean ,
}
,
scheduledEventsAdditionalPublishingTargets:
{
eventGridAndResourceGraph:
{
enable: boolean ,
scheduledEventsApiVersion: string ,
}
,
}
,
allInstancesDown:
{
automaticallyApprove: boolean ,
}
,
}
,
storageProfile:
{
imageReference:
{
publisher: string ,
offer: string ,
sku: string ,
version: string ,
exactVersion: string ,
sharedGalleryImageId: string ,
communityGalleryImageId: string ,
}
,
osDisk:
{
osType: enum ,
encryptionSettings:
{
diskEncryptionKey:
{
secretUrl: string ,
sourceVault:
{
id: string ,
}
,
}
,
keyEncryptionKey:
{
keyUrl: string ,
sourceVault:
{
id: string ,
}
,
}
,
enabled: boolean ,
}
,
name: string ,
vhd:
{
uri: string ,
}
,
image:
{
uri: string ,
}
,
caching: enum ,
writeAcceleratorEnabled: boolean ,
diffDiskSettings:
{
option: enum ,
placement: enum ,
}
,
createOption: enum ,
diskSizeGB: integer ,
managedDisk:
{
storageAccountType: enum ,
diskEncryptionSet: object ,
securityProfile:
{
securityEncryptionType: enum ,
diskEncryptionSet: object ,
}
,
}
,
deleteOption: enum ,
}
,
dataDisks:
[
{
lun: integer ,
name: string ,
vhd:
{
uri: string ,
}
,
image:
{
uri: string ,
}
,
caching: enum ,
writeAcceleratorEnabled: boolean ,
createOption: enum ,
diskSizeGB: integer ,
managedDisk:
{
storageAccountType: enum ,
diskEncryptionSet: object ,
securityProfile:
{
securityEncryptionType: enum ,
diskEncryptionSet: object ,
}
,
}
,
sourceResource:
{
id: string ,
}
,
toBeDetached: boolean ,
diskIOPSReadWrite: integer ,
diskMBpsReadWrite: integer ,
detachOption: enum ,
deleteOption: enum ,
}
,
]
,
diskControllerType: enum ,
alignRegionalDisksToVMZone: boolean ,
}
,
additionalCapabilities:
{
ultraSSDEnabled: boolean ,
hibernationEnabled: boolean ,
enableFips1403Encryption: boolean ,
}
,
osProfile:
{
computerName: string ,
adminUsername: string ,
adminPassword: string ,
customData: string ,
windowsConfiguration:
{
provisionVMAgent: boolean ,
enableAutomaticUpdates: boolean ,
timeZone: string ,
additionalUnattendContent:
[
{
passName: enum ,
componentName: enum ,
settingName: enum ,
content: string ,
}
,
]
,
patchSettings:
{
patchMode: enum ,
enableHotpatching: boolean ,
assessmentMode: enum ,
automaticByPlatformSettings:
{
rebootSetting: enum ,
bypassPlatformSafetyChecksOnUserSchedule: boolean ,
}
,
}
,
winRM:
{
listeners:
[
{
protocol: enum ,
certificateUrl: string ,
}
,
]
,
}
,
enableVMAgentPlatformUpdates: boolean ,
}
,
linuxConfiguration:
{
disablePasswordAuthentication: boolean ,
ssh:
{
publicKeys:
[
{
path: string ,
keyData: string ,
}
,
]
,
}
,
provisionVMAgent: boolean ,
patchSettings:
{
patchMode: enum ,
assessmentMode: enum ,
automaticByPlatformSettings:
{
rebootSetting: enum ,
bypassPlatformSafetyChecksOnUserSchedule: boolean ,
}
,
}
,
enableVMAgentPlatformUpdates: boolean ,
}
,
secrets:
[
{
sourceVault:
{
id: string ,
}
,
vaultCertificates:
[
{
certificateUrl: string ,
certificateStore: string ,
}
,
]
,
}
,
]
,
allowExtensionOperations: boolean ,
requireGuestProvisionSignal: boolean ,
}
,
networkProfile:
{
networkInterfaces:
[
{
properties:
{
primary: boolean ,
deleteOption: enum ,
}
,
}
,
]
,
networkApiVersion: enum ,
networkInterfaceConfigurations:
[
{
name: string ,
properties:
{
primary: boolean ,
deleteOption: enum ,
enableAcceleratedNetworking: boolean ,
disableTcpStateTracking: boolean ,
enableFpga: boolean ,
enableIPForwarding: boolean ,
networkSecurityGroup:
{
id: string ,
}
,
dnsSettings:
{
dnsServers:
[
string ,
]
,
}
,
ipConfigurations:
[
{
name: string ,
properties:
{
subnet:
{
id: string ,
}
,
primary: boolean ,
publicIPAddressConfiguration:
{
name: string ,
properties:
{
idleTimeoutInMinutes: integer ,
deleteOption: enum ,
dnsSettings:
{
domainNameLabel: string ,
domainNameLabelScope: enum ,
}
,
ipTags:
[
{
ipTagType: string ,
tag: string ,
}
,
]
,
publicIPPrefix:
{
id: string ,
}
,
publicIPAddressVersion: enum ,
publicIPAllocationMethod: enum ,
}
,
sku:
{
name: enum ,
tier: enum ,
}
,
tags: object ,
}
,
privateIPAddressVersion: enum ,
applicationSecurityGroups:
[
{
id: string ,
}
,
]
,
applicationGatewayBackendAddressPools:
[
{
id: string ,
}
,
]
,
loadBalancerBackendAddressPools:
[
{
id: string ,
}
,
]
,
}
,
}
,
]
,
dscpConfiguration:
{
id: string ,
}
,
auxiliaryMode: enum ,
auxiliarySku: enum ,
}
,
tags: object ,
}
,
]
,
}
,
securityProfile:
{
uefiSettings:
{
secureBootEnabled: boolean ,
vTpmEnabled: boolean ,
}
,
encryptionAtHost: boolean ,
securityType: enum ,
encryptionIdentity:
{
userAssignedIdentityResourceId: string ,
}
,
proxyAgentSettings:
{
enabled: boolean ,
mode: enum ,
keyIncarnationId: integer ,
wireServer:
{
mode: enum ,
inVMAccessControlProfileReferenceId: string ,
}
,
imds:
{
mode: enum ,
inVMAccessControlProfileReferenceId: string ,
}
,
addProxyAgentExtension: boolean ,
}
,
}
,
diagnosticsProfile:
{
bootDiagnostics:
{
enabled: boolean ,
storageUri: string ,
}
,
}
,
availabilitySet:
{
id: string ,
}
,
virtualMachineScaleSet:
{
id: string ,
}
,
proximityPlacementGroup:
{
id: string ,
}
,
priority: enum ,
evictionPolicy: enum ,
billingProfile:
{
maxPrice: number ,
}
,
host:
{
id: string ,
}
,
hostGroup:
{
id: string ,
}
,
provisioningState: string ,
instanceView:
{
platformUpdateDomain: integer ,
platformFaultDomain: integer ,
computerName: string ,
osName: string ,
osVersion: string ,
hyperVGeneration: enum ,
rdpThumbPrint: string ,
vmAgent:
{
vmAgentVersion: string ,
extensionHandlers:
[
{
type: string ,
typeHandlerVersion: string ,
status:
{
code: string ,
level: enum ,
displayStatus: string ,
message: string ,
time: string ,
}
,
}
,
]
,
statuses:
[
{
code: string ,
level: enum ,
displayStatus: string ,
message: string ,
time: string ,
}
,
]
,
}
,
maintenanceRedeployStatus:
{
isCustomerInitiatedMaintenanceAllowed: boolean ,
preMaintenanceWindowStartTime: string ,
preMaintenanceWindowEndTime: string ,
maintenanceWindowStartTime: string ,
maintenanceWindowEndTime: string ,
lastOperationResultCode: enum ,
lastOperationMessage: string ,
}
,
disks:
[
{
name: string ,
encryptionSettings:
[
{
diskEncryptionKey:
{
secretUrl: string ,
sourceVault:
{
id: string ,
}
,
}
,
keyEncryptionKey:
{
keyUrl: string ,
sourceVault:
{
id: string ,
}
,
}
,
enabled: boolean ,
}
,
]
,
statuses:
[
{
code: string ,
level: enum ,
displayStatus: string ,
message: string ,
time: string ,
}
,
]
,
}
,
]
,
extensions:
[
{
name: string ,
type: string ,
typeHandlerVersion: string ,
substatuses:
[
{
code: string ,
level: enum ,
displayStatus: string ,
message: string ,
time: string ,
}
,
]
,
statuses:
[
{
code: string ,
level: enum ,
displayStatus: string ,
message: string ,
time: string ,
}
,
]
,
}
,
]
,
vmHealth:
{
status:
{
code: string ,
level: enum ,
displayStatus: string ,
message: string ,
time: string ,
}
,
}
,
bootDiagnostics:
{
consoleScreenshotBlobUri: string ,
serialConsoleLogBlobUri: string ,
status:
{
code: string ,
level: enum ,
displayStatus: string ,
message: string ,
time: string ,
}
,
}
,
assignedHost: string ,
statuses:
[
{
code: string ,
level: enum ,
displayStatus: string ,
message: string ,
time: string ,
}
,
]
,
patchStatus:
{
availablePatchSummary:
{
status: enum ,
assessmentActivityId: string ,
rebootPending: boolean ,
criticalAndSecurityPatchCount: integer ,
otherPatchCount: integer ,
startTime: string ,
lastModifiedTime: string ,
error:
{
details:
[
{
code: string ,
target: string ,
message: string ,
}
,
]
,
innererror:
{
exceptiontype: string ,
errordetail: string ,
}
,
code: string ,
target: string ,
message: string ,
}
,
}
,
lastPatchInstallationSummary:
{
status: enum ,
installationActivityId: string ,
maintenanceWindowExceeded: boolean ,
notSelectedPatchCount: integer ,
excludedPatchCount: integer ,
pendingPatchCount: integer ,
installedPatchCount: integer ,
failedPatchCount: integer ,
startTime: string ,
lastModifiedTime: string ,
error:
{
details:
[
{
code: string ,
target: string ,
message: string ,
}
,
]
,
innererror:
{
exceptiontype: string ,
errordetail: string ,
}
,
code: string ,
target: string ,
message: string ,
}
,
}
,
configurationStatuses:
[
{
code: string ,
level: enum ,
displayStatus: string ,
message: string ,
time: string ,
}
,
]
,
}
,
isVMInStandbyPool: boolean ,
}
,
licenseType: string ,
vmId: string ,
extensionsTimeBudget: string ,
platformFaultDomain: integer ,
scheduledEventsProfile:
{
terminateNotificationProfile:
{
notBeforeTimeout: string ,
enable: boolean ,
}
,
osImageNotificationProfile:
{
notBeforeTimeout: string ,
enable: boolean ,
}
,
}
,
userData: string ,
capacityReservation:
{
capacityReservationGroup:
{
id: string ,
}
,
}
,
applicationProfile:
{
galleryApplications:
[
{
tags: string ,
order: integer ,
packageReferenceId: string ,
configurationReference: string ,
treatFailureAsDeploymentFailure: boolean ,
enableAutomaticUpgrade: boolean ,
}
,
]
,
}
,
timeCreated: string ,
}
,
plan:
{
name: string ,
publisher: string ,
product: string ,
promotionCode: string ,
}
,
resources:
[
{
properties:
{
forceUpdateTag: string ,
publisher: string ,
type: string ,
typeHandlerVersion: string ,
autoUpgradeMinorVersion: boolean ,
enableAutomaticUpgrade: boolean ,
settings: string ,
protectedSettings: string ,
provisioningState: string ,
instanceView:
{
name: string ,
type: string ,
typeHandlerVersion: string ,
substatuses:
[
{
code: string ,
level: enum ,
displayStatus: string ,
message: string ,
time: string ,
}
,
]
,
statuses:
[
{
code: string ,
level: enum ,
displayStatus: string ,
message: string ,
time: string ,
}
,
]
,
}
,
suppressFailures: boolean ,
protectedSettingsFromKeyVault:
{
secretUrl: string ,
sourceVault:
{
id: string ,
}
,
}
,
provisionAfterExtensions:
[
string ,
]
,
}
,
}
,
]
,
identity:
{
principalId: string ,
tenantId: string ,
type: enum ,
userAssignedIdentities: object ,
}
,
zones:
[
string ,
]
,
extendedLocation:
{
name: string ,
type: enum ,
}
,
managedBy: string ,
etag: string ,
placement:
{
zonePlacementPolicy: enum ,
includeZones:
[
string ,
]
,
excludeZones:
[
string ,
]
,
}
,
}
,
]
,
nextLink: string ,
}

⚐ Response (default)

{
error:
{
details:
[
{
code: string ,
target: string ,
message: string ,
}
,
]
,
innererror:
{
exceptiontype: string ,
errordetail: string ,
}
,
code: string ,
target: string ,
message: string ,
}
,
}
VirtualMachineScaleSetVMs_List (updated)
Description Gets a list of all virtual machines in a VM scale sets.
Reference Link ¶

⚶ Changes

{
  "#id": "VirtualMachineScaleSetVMs_List",
  "$responses": {
    "200": {
      "$properties": {
        "value": {
          "$properties": {
            "properties": [
              {
                "storageProfile": [
                  {
                    "dataDisks": {
                      "$properties": [
                        {
                          "#name": "diskIOPSReadWrite",
                          "Description": {
                            "new": "Specifies the Read-Write IOPS for the managed disk when StorageAccountType is UltraSSD_LRS.",
                            "old": "Specifies the Read-Write IOPS for the managed disk when StorageAccountType is UltraSSD_LRS. Returned only for VirtualMachine ScaleSet VM disks. Can be updated only via updates to the VirtualMachine Scale Set."
                          }
                        },
                        {
                          "#name": "diskMBpsReadWrite",
                          "Description": {
                            "new": "Specifies the bandwidth in MB per second for the managed disk when StorageAccountType is UltraSSD_LRS.",
                            "old": "Specifies the bandwidth in MB per second for the managed disk when StorageAccountType is UltraSSD_LRS. Returned only for VirtualMachine ScaleSet VM disks. Can be updated only via updates to the VirtualMachine Scale Set."
                          }
                        }
                      ]
                    }
                  }
                ]
              }
            ]
          }
        }
      }
    }
  }
}

⚼ Request

GET:  /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Compute/virtualMachineScaleSets/{virtualMachineScaleSetName}/virtualMachines
{
api-version: string ,
subscriptionId: string ,
resourceGroupName: string ,
virtualMachineScaleSetName: string ,
$filter: string ,
$select: string ,
$expand: string ,
}

⚐ Response (200)

{
value:
[
{
properties:
{
latestModelApplied: boolean ,
vmId: string ,
instanceView:
{
platformUpdateDomain: integer ,
platformFaultDomain: integer ,
rdpThumbPrint: string ,
vmAgent:
{
vmAgentVersion: string ,
extensionHandlers:
[
{
type: string ,
typeHandlerVersion: string ,
status:
{
code: string ,
level: enum ,
displayStatus: string ,
message: string ,
time: string ,
}
,
}
,
]
,
statuses:
[
{
code: string ,
level: enum ,
displayStatus: string ,
message: string ,
time: string ,
}
,
]
,
}
,
maintenanceRedeployStatus:
{
isCustomerInitiatedMaintenanceAllowed: boolean ,
preMaintenanceWindowStartTime: string ,
preMaintenanceWindowEndTime: string ,
maintenanceWindowStartTime: string ,
maintenanceWindowEndTime: string ,
lastOperationResultCode: enum ,
lastOperationMessage: string ,
}
,
disks:
[
{
name: string ,
encryptionSettings:
[
{
diskEncryptionKey:
{
secretUrl: string ,
sourceVault:
{
id: string ,
}
,
}
,
keyEncryptionKey:
{
keyUrl: string ,
sourceVault:
{
id: string ,
}
,
}
,
enabled: boolean ,
}
,
]
,
statuses:
[
{
code: string ,
level: enum ,
displayStatus: string ,
message: string ,
time: string ,
}
,
]
,
}
,
]
,
extensions:
[
{
name: string ,
type: string ,
typeHandlerVersion: string ,
substatuses:
[
{
code: string ,
level: enum ,
displayStatus: string ,
message: string ,
time: string ,
}
,
]
,
statuses:
[
{
code: string ,
level: enum ,
displayStatus: string ,
message: string ,
time: string ,
}
,
]
,
}
,
]
,
vmHealth:
{
status:
{
code: string ,
level: enum ,
displayStatus: string ,
message: string ,
time: string ,
}
,
}
,
bootDiagnostics:
{
consoleScreenshotBlobUri: string ,
serialConsoleLogBlobUri: string ,
status:
{
code: string ,
level: enum ,
displayStatus: string ,
message: string ,
time: string ,
}
,
}
,
statuses:
[
{
code: string ,
level: enum ,
displayStatus: string ,
message: string ,
time: string ,
}
,
]
,
assignedHost: string ,
placementGroupId: string ,
computerName: string ,
osName: string ,
osVersion: string ,
hyperVGeneration: enum ,
}
,
hardwareProfile:
{
vmSize: enum ,
vmSizeProperties:
{
vCPUsAvailable: integer ,
vCPUsPerCore: integer ,
}
,
}
,
resilientVMDeletionStatus: enum ,
storageProfile:
{
imageReference:
{
publisher: string ,
offer: string ,
sku: string ,
version: string ,
exactVersion: string ,
sharedGalleryImageId: string ,
communityGalleryImageId: string ,
}
,
osDisk:
{
osType: enum ,
encryptionSettings:
{
diskEncryptionKey:
{
secretUrl: string ,
sourceVault:
{
id: string ,
}
,
}
,
keyEncryptionKey:
{
keyUrl: string ,
sourceVault:
{
id: string ,
}
,
}
,
enabled: boolean ,
}
,
name: string ,
vhd:
{
uri: string ,
}
,
image:
{
uri: string ,
}
,
caching: enum ,
writeAcceleratorEnabled: boolean ,
diffDiskSettings:
{
option: enum ,
placement: enum ,
}
,
createOption: enum ,
diskSizeGB: integer ,
managedDisk:
{
storageAccountType: enum ,
diskEncryptionSet: object ,
securityProfile:
{
securityEncryptionType: enum ,
diskEncryptionSet: object ,
}
,
}
,
deleteOption: enum ,
}
,
dataDisks:
[
{
lun: integer ,
name: string ,
vhd:
{
uri: string ,
}
,
image:
{
uri: string ,
}
,
caching: enum ,
writeAcceleratorEnabled: boolean ,
createOption: enum ,
diskSizeGB: integer ,
managedDisk:
{
storageAccountType: enum ,
diskEncryptionSet: object ,
securityProfile:
{
securityEncryptionType: enum ,
diskEncryptionSet: object ,
}
,
}
,
sourceResource:
{
id: string ,
}
,
toBeDetached: boolean ,
diskIOPSReadWrite: integer ,
diskMBpsReadWrite: integer ,
detachOption: enum ,
deleteOption: enum ,
}
,
]
,
diskControllerType: enum ,
alignRegionalDisksToVMZone: boolean ,
}
,
additionalCapabilities:
{
ultraSSDEnabled: boolean ,
hibernationEnabled: boolean ,
enableFips1403Encryption: boolean ,
}
,
osProfile:
{
computerName: string ,
adminUsername: string ,
adminPassword: string ,
customData: string ,
windowsConfiguration:
{
provisionVMAgent: boolean ,
enableAutomaticUpdates: boolean ,
timeZone: string ,
additionalUnattendContent:
[
{
passName: enum ,
componentName: enum ,
settingName: enum ,
content: string ,
}
,
]
,
patchSettings:
{
patchMode: enum ,
enableHotpatching: boolean ,
assessmentMode: enum ,
automaticByPlatformSettings:
{
rebootSetting: enum ,
bypassPlatformSafetyChecksOnUserSchedule: boolean ,
}
,
}
,
winRM:
{
listeners:
[
{
protocol: enum ,
certificateUrl: string ,
}
,
]
,
}
,
enableVMAgentPlatformUpdates: boolean ,
}
,
linuxConfiguration:
{
disablePasswordAuthentication: boolean ,
ssh:
{
publicKeys:
[
{
path: string ,
keyData: string ,
}
,
]
,
}
,
provisionVMAgent: boolean ,
patchSettings:
{
patchMode: enum ,
assessmentMode: enum ,
automaticByPlatformSettings:
{
rebootSetting: enum ,
bypassPlatformSafetyChecksOnUserSchedule: boolean ,
}
,
}
,
enableVMAgentPlatformUpdates: boolean ,
}
,
secrets:
[
{
sourceVault:
{
id: string ,
}
,
vaultCertificates:
[
{
certificateUrl: string ,
certificateStore: string ,
}
,
]
,
}
,
]
,
allowExtensionOperations: boolean ,
requireGuestProvisionSignal: boolean ,
}
,
securityProfile:
{
uefiSettings:
{
secureBootEnabled: boolean ,
vTpmEnabled: boolean ,
}
,
encryptionAtHost: boolean ,
securityType: enum ,
encryptionIdentity:
{
userAssignedIdentityResourceId: string ,
}
,
proxyAgentSettings:
{
enabled: boolean ,
mode: enum ,
keyIncarnationId: integer ,
wireServer:
{
mode: enum ,
inVMAccessControlProfileReferenceId: string ,
}
,
imds:
{
mode: enum ,
inVMAccessControlProfileReferenceId: string ,
}
,
addProxyAgentExtension: boolean ,
}
,
}
,
networkProfile:
{
networkInterfaces:
[
{
properties:
{
primary: boolean ,
deleteOption: enum ,
}
,
}
,
]
,
networkApiVersion: enum ,
networkInterfaceConfigurations:
[
{
name: string ,
properties:
{
primary: boolean ,
deleteOption: enum ,
enableAcceleratedNetworking: boolean ,
disableTcpStateTracking: boolean ,
enableFpga: boolean ,
enableIPForwarding: boolean ,
networkSecurityGroup:
{
id: string ,
}
,
dnsSettings:
{
dnsServers:
[
string ,
]
,
}
,
ipConfigurations:
[
{
name: string ,
properties:
{
subnet:
{
id: string ,
}
,
primary: boolean ,
publicIPAddressConfiguration:
{
name: string ,
properties:
{
idleTimeoutInMinutes: integer ,
deleteOption: enum ,
dnsSettings:
{
domainNameLabel: string ,
domainNameLabelScope: enum ,
}
,
ipTags:
[
{
ipTagType: string ,
tag: string ,
}
,
]
,
publicIPPrefix:
{
id: string ,
}
,
publicIPAddressVersion: enum ,
publicIPAllocationMethod: enum ,
}
,
sku:
{
name: enum ,
tier: enum ,
}
,
tags: object ,
}
,
privateIPAddressVersion: enum ,
applicationSecurityGroups:
[
{
id: string ,
}
,
]
,
applicationGatewayBackendAddressPools:
[
{
id: string ,
}
,
]
,
loadBalancerBackendAddressPools:
[
{
id: string ,
}
,
]
,
}
,
}
,
]
,
dscpConfiguration:
{
id: string ,
}
,
auxiliaryMode: enum ,
auxiliarySku: enum ,
}
,
tags: object ,
}
,
]
,
}
,
networkProfileConfiguration:
{
networkInterfaceConfigurations:
[
{
name: string ,
properties:
{
primary: boolean ,
enableAcceleratedNetworking: boolean ,
disableTcpStateTracking: boolean ,
enableFpga: boolean ,
networkSecurityGroup:
{
id: string ,
}
,
dnsSettings:
{
dnsServers:
[
string ,
]
,
}
,
ipConfigurations:
[
{
name: string ,
properties:
{
subnet:
{
id: string ,
}
,
primary: boolean ,
publicIPAddressConfiguration:
{
name: string ,
properties:
{
idleTimeoutInMinutes: integer ,
dnsSettings:
{
domainNameLabel: string ,
domainNameLabelScope: enum ,
}
,
ipTags:
[
{
ipTagType: string ,
tag: string ,
}
,
]
,
publicIPPrefix:
{
id: string ,
}
,
publicIPAddressVersion: enum ,
deleteOption: enum ,
}
,
sku:
{
name: enum ,
tier: enum ,
}
,
tags: object ,
}
,
privateIPAddressVersion: enum ,
applicationGatewayBackendAddressPools:
[
{
id: string ,
}
,
]
,
applicationSecurityGroups:
[
{
id: string ,
}
,
]
,
loadBalancerBackendAddressPools:
[
{
id: string ,
}
,
]
,
loadBalancerInboundNatPools:
[
{
id: string ,
}
,
]
,
}
,
}
,
]
,
enableIPForwarding: boolean ,
deleteOption: enum ,
auxiliaryMode: enum ,
auxiliarySku: enum ,
}
,
tags: object ,
}
,
]
,
}
,
diagnosticsProfile:
{
bootDiagnostics:
{
enabled: boolean ,
storageUri: string ,
}
,
}
,
availabilitySet:
{
id: string ,
}
,
provisioningState: string ,
licenseType: string ,
modelDefinitionApplied: string ,
protectionPolicy:
{
protectFromScaleIn: boolean ,
protectFromScaleSetActions: boolean ,
}
,
userData: string ,
timeCreated: string ,
}
,
instanceId: string ,
sku:
{
name: string ,
tier: string ,
capacity: integer ,
}
,
plan:
{
name: string ,
publisher: string ,
product: string ,
promotionCode: string ,
}
,
resources:
[
{
properties:
{
forceUpdateTag: string ,
publisher: string ,
type: string ,
typeHandlerVersion: string ,
autoUpgradeMinorVersion: boolean ,
enableAutomaticUpgrade: boolean ,
settings: string ,
protectedSettings: string ,
provisioningState: string ,
instanceView:
{
name: string ,
type: string ,
typeHandlerVersion: string ,
substatuses:
[
{
code: string ,
level: enum ,
displayStatus: string ,
message: string ,
time: string ,
}
,
]
,
statuses:
[
{
code: string ,
level: enum ,
displayStatus: string ,
message: string ,
time: string ,
}
,
]
,
}
,
suppressFailures: boolean ,
protectedSettingsFromKeyVault:
{
secretUrl: string ,
sourceVault:
{
id: string ,
}
,
}
,
provisionAfterExtensions:
[
string ,
]
,
}
,
}
,
]
,
zones:
[
string ,
]
,
identity:
{
principalId: string ,
tenantId: string ,
type: enum ,
userAssignedIdentities: object ,
}
,
etag: string ,
}
,
]
,
nextLink: string ,
}

⚐ Response (default)

{
error:
{
details:
[
{
code: string ,
target: string ,
message: string ,
}
,
]
,
innererror:
{
exceptiontype: string ,
errordetail: string ,
}
,
code: string ,
target: string ,
message: string ,
}
,
}
VirtualMachineScaleSetVMs_Get (updated)
Description Gets a virtual machine from a VM scale set.
Reference Link ¶

⚶ Changes

{
  "#id": "VirtualMachineScaleSetVMs_Get",
  "$responses": {
    "200": {
      "$properties": {
        "properties": [
          {
            "storageProfile": [
              {
                "dataDisks": {
                  "$properties": [
                    {
                      "#name": "diskIOPSReadWrite",
                      "Description": {
                        "new": "Specifies the Read-Write IOPS for the managed disk when StorageAccountType is UltraSSD_LRS.",
                        "old": "Specifies the Read-Write IOPS for the managed disk when StorageAccountType is UltraSSD_LRS. Returned only for VirtualMachine ScaleSet VM disks. Can be updated only via updates to the VirtualMachine Scale Set."
                      }
                    },
                    {
                      "#name": "diskMBpsReadWrite",
                      "Description": {
                        "new": "Specifies the bandwidth in MB per second for the managed disk when StorageAccountType is UltraSSD_LRS.",
                        "old": "Specifies the bandwidth in MB per second for the managed disk when StorageAccountType is UltraSSD_LRS. Returned only for VirtualMachine ScaleSet VM disks. Can be updated only via updates to the VirtualMachine Scale Set."
                      }
                    }
                  ]
                }
              }
            ]
          }
        ]
      }
    }
  }
}

⚼ Request

GET:  /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Compute/virtualMachineScaleSets/{vmScaleSetName}/virtualMachines/{instanceId}
{
api-version: string ,
subscriptionId: string ,
resourceGroupName: string ,
vmScaleSetName: string ,
instanceId: string ,
$expand: string ,
}

⚐ Response (200)

{
properties:
{
latestModelApplied: boolean ,
vmId: string ,
instanceView:
{
platformUpdateDomain: integer ,
platformFaultDomain: integer ,
rdpThumbPrint: string ,
vmAgent:
{
vmAgentVersion: string ,
extensionHandlers:
[
{
type: string ,
typeHandlerVersion: string ,
status:
{
code: string ,
level: enum ,
displayStatus: string ,
message: string ,
time: string ,
}
,
}
,
]
,
statuses:
[
{
code: string ,
level: enum ,
displayStatus: string ,
message: string ,
time: string ,
}
,
]
,
}
,
maintenanceRedeployStatus:
{
isCustomerInitiatedMaintenanceAllowed: boolean ,
preMaintenanceWindowStartTime: string ,
preMaintenanceWindowEndTime: string ,
maintenanceWindowStartTime: string ,
maintenanceWindowEndTime: string ,
lastOperationResultCode: enum ,
lastOperationMessage: string ,
}
,
disks:
[
{
name: string ,
encryptionSettings:
[
{
diskEncryptionKey:
{
secretUrl: string ,
sourceVault:
{
id: string ,
}
,
}
,
keyEncryptionKey:
{
keyUrl: string ,
sourceVault:
{
id: string ,
}
,
}
,
enabled: boolean ,
}
,
]
,
statuses:
[
{
code: string ,
level: enum ,
displayStatus: string ,
message: string ,
time: string ,
}
,
]
,
}
,
]
,
extensions:
[
{
name: string ,
type: string ,
typeHandlerVersion: string ,
substatuses:
[
{
code: string ,
level: enum ,
displayStatus: string ,
message: string ,
time: string ,
}
,
]
,
statuses:
[
{
code: string ,
level: enum ,
displayStatus: string ,
message: string ,
time: string ,
}
,
]
,
}
,
]
,
vmHealth:
{
status:
{
code: string ,
level: enum ,
displayStatus: string ,
message: string ,
time: string ,
}
,
}
,
bootDiagnostics:
{
consoleScreenshotBlobUri: string ,
serialConsoleLogBlobUri: string ,
status:
{
code: string ,
level: enum ,
displayStatus: string ,
message: string ,
time: string ,
}
,
}
,
statuses:
[
{
code: string ,
level: enum ,
displayStatus: string ,
message: string ,
time: string ,
}
,
]
,
assignedHost: string ,
placementGroupId: string ,
computerName: string ,
osName: string ,
osVersion: string ,
hyperVGeneration: enum ,
}
,
hardwareProfile:
{
vmSize: enum ,
vmSizeProperties:
{
vCPUsAvailable: integer ,
vCPUsPerCore: integer ,
}
,
}
,
resilientVMDeletionStatus: enum ,
storageProfile:
{
imageReference:
{
publisher: string ,
offer: string ,
sku: string ,
version: string ,
exactVersion: string ,
sharedGalleryImageId: string ,
communityGalleryImageId: string ,
}
,
osDisk:
{
osType: enum ,
encryptionSettings:
{
diskEncryptionKey:
{
secretUrl: string ,
sourceVault:
{
id: string ,
}
,
}
,
keyEncryptionKey:
{
keyUrl: string ,
sourceVault:
{
id: string ,
}
,
}
,
enabled: boolean ,
}
,
name: string ,
vhd:
{
uri: string ,
}
,
image:
{
uri: string ,
}
,
caching: enum ,
writeAcceleratorEnabled: boolean ,
diffDiskSettings:
{
option: enum ,
placement: enum ,
}
,
createOption: enum ,
diskSizeGB: integer ,
managedDisk:
{
storageAccountType: enum ,
diskEncryptionSet: object ,
securityProfile:
{
securityEncryptionType: enum ,
diskEncryptionSet: object ,
}
,
}
,
deleteOption: enum ,
}
,
dataDisks:
[
{
lun: integer ,
name: string ,
vhd:
{
uri: string ,
}
,
image:
{
uri: string ,
}
,
caching: enum ,
writeAcceleratorEnabled: boolean ,
createOption: enum ,
diskSizeGB: integer ,
managedDisk:
{
storageAccountType: enum ,
diskEncryptionSet: object ,
securityProfile:
{
securityEncryptionType: enum ,
diskEncryptionSet: object ,
}
,
}
,
sourceResource:
{
id: string ,
}
,
toBeDetached: boolean ,
diskIOPSReadWrite: integer ,
diskMBpsReadWrite: integer ,
detachOption: enum ,
deleteOption: enum ,
}
,
]
,
diskControllerType: enum ,
alignRegionalDisksToVMZone: boolean ,
}
,
additionalCapabilities:
{
ultraSSDEnabled: boolean ,
hibernationEnabled: boolean ,
enableFips1403Encryption: boolean ,
}
,
osProfile:
{
computerName: string ,
adminUsername: string ,
adminPassword: string ,
customData: string ,
windowsConfiguration:
{
provisionVMAgent: boolean ,
enableAutomaticUpdates: boolean ,
timeZone: string ,
additionalUnattendContent:
[
{
passName: enum ,
componentName: enum ,
settingName: enum ,
content: string ,
}
,
]
,
patchSettings:
{
patchMode: enum ,
enableHotpatching: boolean ,
assessmentMode: enum ,
automaticByPlatformSettings:
{
rebootSetting: enum ,
bypassPlatformSafetyChecksOnUserSchedule: boolean ,
}
,
}
,
winRM:
{
listeners:
[
{
protocol: enum ,
certificateUrl: string ,
}
,
]
,
}
,
enableVMAgentPlatformUpdates: boolean ,
}
,
linuxConfiguration:
{
disablePasswordAuthentication: boolean ,
ssh:
{
publicKeys:
[
{
path: string ,
keyData: string ,
}
,
]
,
}
,
provisionVMAgent: boolean ,
patchSettings:
{
patchMode: enum ,
assessmentMode: enum ,
automaticByPlatformSettings:
{
rebootSetting: enum ,
bypassPlatformSafetyChecksOnUserSchedule: boolean ,
}
,
}
,
enableVMAgentPlatformUpdates: boolean ,
}
,
secrets:
[
{
sourceVault:
{
id: string ,
}
,
vaultCertificates:
[
{
certificateUrl: string ,
certificateStore: string ,
}
,
]
,
}
,
]
,
allowExtensionOperations: boolean ,
requireGuestProvisionSignal: boolean ,
}
,
securityProfile:
{
uefiSettings:
{
secureBootEnabled: boolean ,
vTpmEnabled: boolean ,
}
,
encryptionAtHost: boolean ,
securityType: enum ,
encryptionIdentity:
{
userAssignedIdentityResourceId: string ,
}
,
proxyAgentSettings:
{
enabled: boolean ,
mode: enum ,
keyIncarnationId: integer ,
wireServer:
{
mode: enum ,
inVMAccessControlProfileReferenceId: string ,
}
,
imds:
{
mode: enum ,
inVMAccessControlProfileReferenceId: string ,
}
,
addProxyAgentExtension: boolean ,
}
,
}
,
networkProfile:
{
networkInterfaces:
[
{
properties:
{
primary: boolean ,
deleteOption: enum ,
}
,
}
,
]
,
networkApiVersion: enum ,
networkInterfaceConfigurations:
[
{
name: string ,
properties:
{
primary: boolean ,
deleteOption: enum ,
enableAcceleratedNetworking: boolean ,
disableTcpStateTracking: boolean ,
enableFpga: boolean ,
enableIPForwarding: boolean ,
networkSecurityGroup:
{
id: string ,
}
,
dnsSettings:
{
dnsServers:
[
string ,
]
,
}
,
ipConfigurations:
[
{
name: string ,
properties:
{
subnet:
{
id: string ,
}
,
primary: boolean ,
publicIPAddressConfiguration:
{
name: string ,
properties:
{
idleTimeoutInMinutes: integer ,
deleteOption: enum ,
dnsSettings:
{
domainNameLabel: string ,
domainNameLabelScope: enum ,
}
,
ipTags:
[
{
ipTagType: string ,
tag: string ,
}
,
]
,
publicIPPrefix:
{
id: string ,
}
,
publicIPAddressVersion: enum ,
publicIPAllocationMethod: enum ,
}
,
sku:
{
name: enum ,
tier: enum ,
}
,
tags: object ,
}
,
privateIPAddressVersion: enum ,
applicationSecurityGroups:
[
{
id: string ,
}
,
]
,
applicationGatewayBackendAddressPools:
[
{
id: string ,
}
,
]
,
loadBalancerBackendAddressPools:
[
{
id: string ,
}
,
]
,
}
,
}
,
]
,
dscpConfiguration:
{
id: string ,
}
,
auxiliaryMode: enum ,
auxiliarySku: enum ,
}
,
tags: object ,
}
,
]
,
}
,
networkProfileConfiguration:
{
networkInterfaceConfigurations:
[
{
name: string ,
properties:
{
primary: boolean ,
enableAcceleratedNetworking: boolean ,
disableTcpStateTracking: boolean ,
enableFpga: boolean ,
networkSecurityGroup:
{
id: string ,
}
,
dnsSettings:
{
dnsServers:
[
string ,
]
,
}
,
ipConfigurations:
[
{
name: string ,
properties:
{
subnet:
{
id: string ,
}
,
primary: boolean ,
publicIPAddressConfiguration:
{
name: string ,
properties:
{
idleTimeoutInMinutes: integer ,
dnsSettings:
{
domainNameLabel: string ,
domainNameLabelScope: enum ,
}
,
ipTags:
[
{
ipTagType: string ,
tag: string ,
}
,
]
,
publicIPPrefix:
{
id: string ,
}
,
publicIPAddressVersion: enum ,
deleteOption: enum ,
}
,
sku:
{
name: enum ,
tier: enum ,
}
,
tags: object ,
}
,
privateIPAddressVersion: enum ,
applicationGatewayBackendAddressPools:
[
{
id: string ,
}
,
]
,
applicationSecurityGroups:
[
{
id: string ,
}
,
]
,
loadBalancerBackendAddressPools:
[
{
id: string ,
}
,
]
,
loadBalancerInboundNatPools:
[
{
id: string ,
}
,
]
,
}
,
}
,
]
,
enableIPForwarding: boolean ,
deleteOption: enum ,
auxiliaryMode: enum ,
auxiliarySku: enum ,
}
,
tags: object ,
}
,
]
,
}
,
diagnosticsProfile:
{
bootDiagnostics:
{
enabled: boolean ,
storageUri: string ,
}
,
}
,
availabilitySet:
{
id: string ,
}
,
provisioningState: string ,
licenseType: string ,
modelDefinitionApplied: string ,
protectionPolicy:
{
protectFromScaleIn: boolean ,
protectFromScaleSetActions: boolean ,
}
,
userData: string ,
timeCreated: string ,
}
,
instanceId: string ,
sku:
{
name: string ,
tier: string ,
capacity: integer ,
}
,
plan:
{
name: string ,
publisher: string ,
product: string ,
promotionCode: string ,
}
,
resources:
[
{
properties:
{
forceUpdateTag: string ,
publisher: string ,
type: string ,
typeHandlerVersion: string ,
autoUpgradeMinorVersion: boolean ,
enableAutomaticUpgrade: boolean ,
settings: string ,
protectedSettings: string ,
provisioningState: string ,
instanceView:
{
name: string ,
type: string ,
typeHandlerVersion: string ,
substatuses:
[
{
code: string ,
level: enum ,
displayStatus: string ,
message: string ,
time: string ,
}
,
]
,
statuses:
[
{
code: string ,
level: enum ,
displayStatus: string ,
message: string ,
time: string ,
}
,
]
,
}
,
suppressFailures: boolean ,
protectedSettingsFromKeyVault:
{
secretUrl: string ,
sourceVault:
{
id: string ,
}
,
}
,
provisionAfterExtensions:
[
string ,
]
,
}
,
}
,
]
,
zones:
[
string ,
]
,
identity:
{
principalId: string ,
tenantId: string ,
type: enum ,
userAssignedIdentities: object ,
}
,
etag: string ,
}

⚐ Response (default)

{
error:
{
details:
[
{
code: string ,
target: string ,
message: string ,
}
,
]
,
innererror:
{
exceptiontype: string ,
errordetail: string ,
}
,
code: string ,
target: string ,
message: string ,
}
,
}
VirtualMachineScaleSetVMs_Update (updated)
Description Updates a virtual machine of a VM scale set.
Reference Link ¶

⚶ Changes

{
  "#id": "VirtualMachineScaleSetVMs_Update",
  "$parameters": {
    "parameters": {
      "$properties": {
        "properties": [
          {
            "storageProfile": [
              {
                "dataDisks": {
                  "$properties": [
                    {
                      "#name": "diskIOPSReadWrite",
                      "Description": {
                        "new": "Specifies the Read-Write IOPS for the managed disk when StorageAccountType is UltraSSD_LRS.",
                        "old": "Specifies the Read-Write IOPS for the managed disk when StorageAccountType is UltraSSD_LRS. Returned only for VirtualMachine ScaleSet VM disks. Can be updated only via updates to the VirtualMachine Scale Set."
                      }
                    },
                    {
                      "#name": "diskMBpsReadWrite",
                      "Description": {
                        "new": "Specifies the bandwidth in MB per second for the managed disk when StorageAccountType is UltraSSD_LRS.",
                        "old": "Specifies the bandwidth in MB per second for the managed disk when StorageAccountType is UltraSSD_LRS. Returned only for VirtualMachine ScaleSet VM disks. Can be updated only via updates to the VirtualMachine Scale Set."
                      }
                    }
                  ]
                }
              }
            ]
          }
        ]
      }
    }
  },
  "$responses": {
    "200": {
      "$properties": {
        "properties": [
          {
            "storageProfile": [
              {
                "dataDisks": {
                  "$properties": [
                    {
                      "#name": "diskIOPSReadWrite",
                      "Description": {
                        "new": "Specifies the Read-Write IOPS for the managed disk when StorageAccountType is UltraSSD_LRS.",
                        "old": "Specifies the Read-Write IOPS for the managed disk when StorageAccountType is UltraSSD_LRS. Returned only for VirtualMachine ScaleSet VM disks. Can be updated only via updates to the VirtualMachine Scale Set."
                      }
                    },
                    {
                      "#name": "diskMBpsReadWrite",
                      "Description": {
                        "new": "Specifies the bandwidth in MB per second for the managed disk when StorageAccountType is UltraSSD_LRS.",
                        "old": "Specifies the bandwidth in MB per second for the managed disk when StorageAccountType is UltraSSD_LRS. Returned only for VirtualMachine ScaleSet VM disks. Can be updated only via updates to the VirtualMachine Scale Set."
                      }
                    }
                  ]
                }
              }
            ]
          }
        ]
      }
    },
    "202": {
      "$properties": {
        "properties": [
          {
            "storageProfile": [
              {
                "dataDisks": {
                  "$properties": [
                    {
                      "#name": "diskIOPSReadWrite",
                      "Description": {
                        "new": "Specifies the Read-Write IOPS for the managed disk when StorageAccountType is UltraSSD_LRS.",
                        "old": "Specifies the Read-Write IOPS for the managed disk when StorageAccountType is UltraSSD_LRS. Returned only for VirtualMachine ScaleSet VM disks. Can be updated only via updates to the VirtualMachine Scale Set."
                      }
                    },
                    {
                      "#name": "diskMBpsReadWrite",
                      "Description": {
                        "new": "Specifies the bandwidth in MB per second for the managed disk when StorageAccountType is UltraSSD_LRS.",
                        "old": "Specifies the bandwidth in MB per second for the managed disk when StorageAccountType is UltraSSD_LRS. Returned only for VirtualMachine ScaleSet VM disks. Can be updated only via updates to the VirtualMachine Scale Set."
                      }
                    }
                  ]
                }
              }
            ]
          }
        ]
      }
    }
  }
}

⚼ Request

PUT:  /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Compute/virtualMachineScaleSets/{vmScaleSetName}/virtualMachines/{instanceId}
{
api-version: string ,
subscriptionId: string ,
resourceGroupName: string ,
vmScaleSetName: string ,
instanceId: string ,
If-Match: string ,
If-None-Match: string ,
parameters:
{
properties:
{
latestModelApplied: boolean ,
vmId: string ,
instanceView:
{
platformUpdateDomain: integer ,
platformFaultDomain: integer ,
rdpThumbPrint: string ,
vmAgent:
{
vmAgentVersion: string ,
extensionHandlers:
[
{
type: string ,
typeHandlerVersion: string ,
status:
{
code: string ,
level: enum ,
displayStatus: string ,
message: string ,
time: string ,
}
,
}
,
]
,
statuses:
[
{
code: string ,
level: enum ,
displayStatus: string ,
message: string ,
time: string ,
}
,
]
,
}
,
maintenanceRedeployStatus:
{
isCustomerInitiatedMaintenanceAllowed: boolean ,
preMaintenanceWindowStartTime: string ,
preMaintenanceWindowEndTime: string ,
maintenanceWindowStartTime: string ,
maintenanceWindowEndTime: string ,
lastOperationResultCode: enum ,
lastOperationMessage: string ,
}
,
disks:
[
{
name: string ,
encryptionSettings:
[
{
diskEncryptionKey:
{
secretUrl: string ,
sourceVault:
{
id: string ,
}
,
}
,
keyEncryptionKey:
{
keyUrl: string ,
sourceVault:
{
id: string ,
}
,
}
,
enabled: boolean ,
}
,
]
,
statuses:
[
{
code: string ,
level: enum ,
displayStatus: string ,
message: string ,
time: string ,
}
,
]
,
}
,
]
,
extensions:
[
{
name: string ,
type: string ,
typeHandlerVersion: string ,
substatuses:
[
{
code: string ,
level: enum ,
displayStatus: string ,
message: string ,
time: string ,
}
,
]
,
statuses:
[
{
code: string ,
level: enum ,
displayStatus: string ,
message: string ,
time: string ,
}
,
]
,
}
,
]
,
vmHealth:
{
status:
{
code: string ,
level: enum ,
displayStatus: string ,
message: string ,
time: string ,
}
,
}
,
bootDiagnostics:
{
consoleScreenshotBlobUri: string ,
serialConsoleLogBlobUri: string ,
status:
{
code: string ,
level: enum ,
displayStatus: string ,
message: string ,
time: string ,
}
,
}
,
statuses:
[
{
code: string ,
level: enum ,
displayStatus: string ,
message: string ,
time: string ,
}
,
]
,
assignedHost: string ,
placementGroupId: string ,
computerName: string ,
osName: string ,
osVersion: string ,
hyperVGeneration: enum ,
}
,
hardwareProfile:
{
vmSize: enum ,
vmSizeProperties:
{
vCPUsAvailable: integer ,
vCPUsPerCore: integer ,
}
,
}
,
resilientVMDeletionStatus: enum ,
storageProfile:
{
imageReference:
{
publisher: string ,
offer: string ,
sku: string ,
version: string ,
exactVersion: string ,
sharedGalleryImageId: string ,
communityGalleryImageId: string ,
}
,
osDisk:
{
osType: enum ,
encryptionSettings:
{
diskEncryptionKey:
{
secretUrl: string ,
sourceVault:
{
id: string ,
}
,
}
,
keyEncryptionKey:
{
keyUrl: string ,
sourceVault:
{
id: string ,
}
,
}
,
enabled: boolean ,
}
,
name: string ,
vhd:
{
uri: string ,
}
,
image:
{
uri: string ,
}
,
caching: enum ,
writeAcceleratorEnabled: boolean ,
diffDiskSettings:
{
option: enum ,
placement: enum ,
}
,
createOption: enum ,
diskSizeGB: integer ,
managedDisk:
{
storageAccountType: enum ,
diskEncryptionSet: object ,
securityProfile:
{
securityEncryptionType: enum ,
diskEncryptionSet: object ,
}
,
}
,
deleteOption: enum ,
}
,
dataDisks:
[
{
lun: integer ,
name: string ,
vhd:
{
uri: string ,
}
,
image:
{
uri: string ,
}
,
caching: enum ,
writeAcceleratorEnabled: boolean ,
createOption: enum ,
diskSizeGB: integer ,
managedDisk:
{
storageAccountType: enum ,
diskEncryptionSet: object ,
securityProfile:
{
securityEncryptionType: enum ,
diskEncryptionSet: object ,
}
,
}
,
sourceResource:
{
id: string ,
}
,
toBeDetached: boolean ,
diskIOPSReadWrite: integer ,
diskMBpsReadWrite: integer ,
detachOption: enum ,
deleteOption: enum ,
}
,
]
,
diskControllerType: enum ,
alignRegionalDisksToVMZone: boolean ,
}
,
additionalCapabilities:
{
ultraSSDEnabled: boolean ,
hibernationEnabled: boolean ,
enableFips1403Encryption: boolean ,
}
,
osProfile:
{
computerName: string ,
adminUsername: string ,
adminPassword: string ,
customData: string ,
windowsConfiguration:
{
provisionVMAgent: boolean ,
enableAutomaticUpdates: boolean ,
timeZone: string ,
additionalUnattendContent:
[
{
passName: enum ,
componentName: enum ,
settingName: enum ,
content: string ,
}
,
]
,
patchSettings:
{
patchMode: enum ,
enableHotpatching: boolean ,
assessmentMode: enum ,
automaticByPlatformSettings:
{
rebootSetting: enum ,
bypassPlatformSafetyChecksOnUserSchedule: boolean ,
}
,
}
,
winRM:
{
listeners:
[
{
protocol: enum ,
certificateUrl: string ,
}
,
]
,
}
,
enableVMAgentPlatformUpdates: boolean ,
}
,
linuxConfiguration:
{
disablePasswordAuthentication: boolean ,
ssh:
{
publicKeys:
[
{
path: string ,
keyData: string ,
}
,
]
,
}
,
provisionVMAgent: boolean ,
patchSettings:
{
patchMode: enum ,
assessmentMode: enum ,
automaticByPlatformSettings:
{
rebootSetting: enum ,
bypassPlatformSafetyChecksOnUserSchedule: boolean ,
}
,
}
,
enableVMAgentPlatformUpdates: boolean ,
}
,
secrets:
[
{
sourceVault:
{
id: string ,
}
,
vaultCertificates:
[
{
certificateUrl: string ,
certificateStore: string ,
}
,
]
,
}
,
]
,
allowExtensionOperations: boolean ,
requireGuestProvisionSignal: boolean ,
}
,
securityProfile:
{
uefiSettings:
{
secureBootEnabled: boolean ,
vTpmEnabled: boolean ,
}
,
encryptionAtHost: boolean ,
securityType: enum ,
encryptionIdentity:
{
userAssignedIdentityResourceId: string ,
}
,
proxyAgentSettings:
{
enabled: boolean ,
mode: enum ,
keyIncarnationId: integer ,
wireServer:
{
mode: enum ,
inVMAccessControlProfileReferenceId: string ,
}
,
imds:
{
mode: enum ,
inVMAccessControlProfileReferenceId: string ,
}
,
addProxyAgentExtension: boolean ,
}
,
}
,
networkProfile:
{
networkInterfaces:
[
{
properties:
{
primary: boolean ,
deleteOption: enum ,
}
,
}
,
]
,
networkApiVersion: enum ,
networkInterfaceConfigurations:
[
{
name: string ,
properties:
{
primary: boolean ,
deleteOption: enum ,
enableAcceleratedNetworking: boolean ,
disableTcpStateTracking: boolean ,
enableFpga: boolean ,
enableIPForwarding: boolean ,
networkSecurityGroup:
{
id: string ,
}
,
dnsSettings:
{
dnsServers:
[
string ,
]
,
}
,
ipConfigurations:
[
{
name: string ,
properties:
{
subnet:
{
id: string ,
}
,
primary: boolean ,
publicIPAddressConfiguration:
{
name: string ,
properties:
{
idleTimeoutInMinutes: integer ,
deleteOption: enum ,
dnsSettings:
{
domainNameLabel: string ,
domainNameLabelScope: enum ,
}
,
ipTags:
[
{
ipTagType: string ,
tag: string ,
}
,
]
,
publicIPPrefix:
{
id: string ,
}
,
publicIPAddressVersion: enum ,
publicIPAllocationMethod: enum ,
}
,
sku:
{
name: enum ,
tier: enum ,
}
,
tags: object ,
}
,
privateIPAddressVersion: enum ,
applicationSecurityGroups:
[
{
id: string ,
}
,
]
,
applicationGatewayBackendAddressPools:
[
{
id: string ,
}
,
]
,
loadBalancerBackendAddressPools:
[
{
id: string ,
}
,
]
,
}
,
}
,
]
,
dscpConfiguration:
{
id: string ,
}
,
auxiliaryMode: enum ,
auxiliarySku: enum ,
}
,
tags: object ,
}
,
]
,
}
,
networkProfileConfiguration:
{
networkInterfaceConfigurations:
[
{
name: string ,
properties:
{
primary: boolean ,
enableAcceleratedNetworking: boolean ,
disableTcpStateTracking: boolean ,
enableFpga: boolean ,
networkSecurityGroup:
{
id: string ,
}
,
dnsSettings:
{
dnsServers:
[
string ,
]
,
}
,
ipConfigurations:
[
{
name: string ,
properties:
{
subnet:
{
id: string ,
}
,
primary: boolean ,
publicIPAddressConfiguration:
{
name: string ,
properties:
{
idleTimeoutInMinutes: integer ,
dnsSettings:
{
domainNameLabel: string ,
domainNameLabelScope: enum ,
}
,
ipTags:
[
{
ipTagType: string ,
tag: string ,
}
,
]
,
publicIPPrefix:
{
id: string ,
}
,
publicIPAddressVersion: enum ,
deleteOption: enum ,
}
,
sku:
{
name: enum ,
tier: enum ,
}
,
tags: object ,
}
,
privateIPAddressVersion: enum ,
applicationGatewayBackendAddressPools:
[
{
id: string ,
}
,
]
,
applicationSecurityGroups:
[
{
id: string ,
}
,
]
,
loadBalancerBackendAddressPools:
[
{
id: string ,
}
,
]
,
loadBalancerInboundNatPools:
[
{
id: string ,
}
,
]
,
}
,
}
,
]
,
enableIPForwarding: boolean ,
deleteOption: enum ,
auxiliaryMode: enum ,
auxiliarySku: enum ,
}
,
tags: object ,
}
,
]
,
}
,
diagnosticsProfile:
{
bootDiagnostics:
{
enabled: boolean ,
storageUri: string ,
}
,
}
,
availabilitySet:
{
id: string ,
}
,
provisioningState: string ,
licenseType: string ,
modelDefinitionApplied: string ,
protectionPolicy:
{
protectFromScaleIn: boolean ,
protectFromScaleSetActions: boolean ,
}
,
userData: string ,
timeCreated: string ,
}
,
instanceId: string ,
sku:
{
name: string ,
tier: string ,
capacity: integer ,
}
,
plan:
{
name: string ,
publisher: string ,
product: string ,
promotionCode: string ,
}
,
resources:
[
{
properties:
{
forceUpdateTag: string ,
publisher: string ,
type: string ,
typeHandlerVersion: string ,
autoUpgradeMinorVersion: boolean ,
enableAutomaticUpgrade: boolean ,
settings: string ,
protectedSettings: string ,
provisioningState: string ,
instanceView:
{
name: string ,
type: string ,
typeHandlerVersion: string ,
substatuses:
[
{
code: string ,
level: enum ,
displayStatus: string ,
message: string ,
time: string ,
}
,
]
,
statuses:
[
{
code: string ,
level: enum ,
displayStatus: string ,
message: string ,
time: string ,
}
,
]
,
}
,
suppressFailures: boolean ,
protectedSettingsFromKeyVault:
{
secretUrl: string ,
sourceVault:
{
id: string ,
}
,
}
,
provisionAfterExtensions:
[
string ,
]
,
}
,
}
,
]
,
zones:
[
string ,
]
,
identity:
{
principalId: string ,
tenantId: string ,
type: enum ,
userAssignedIdentities: object ,
}
,
etag: string ,
}
,
}

⚐ Response (200)

{
properties:
{
latestModelApplied: boolean ,
vmId: string ,
instanceView:
{
platformUpdateDomain: integer ,
platformFaultDomain: integer ,
rdpThumbPrint: string ,
vmAgent:
{
vmAgentVersion: string ,
extensionHandlers:
[
{
type: string ,
typeHandlerVersion: string ,
status:
{
code: string ,
level: enum ,
displayStatus: string ,
message: string ,
time: string ,
}
,
}
,
]
,
statuses:
[
{
code: string ,
level: enum ,
displayStatus: string ,
message: string ,
time: string ,
}
,
]
,
}
,
maintenanceRedeployStatus:
{
isCustomerInitiatedMaintenanceAllowed: boolean ,
preMaintenanceWindowStartTime: string ,
preMaintenanceWindowEndTime: string ,
maintenanceWindowStartTime: string ,
maintenanceWindowEndTime: string ,
lastOperationResultCode: enum ,
lastOperationMessage: string ,
}
,
disks:
[
{
name: string ,
encryptionSettings:
[
{
diskEncryptionKey:
{
secretUrl: string ,
sourceVault:
{
id: string ,
}
,
}
,
keyEncryptionKey:
{
keyUrl: string ,
sourceVault:
{
id: string ,
}
,
}
,
enabled: boolean ,
}
,
]
,
statuses:
[
{
code: string ,
level: enum ,
displayStatus: string ,
message: string ,
time: string ,
}
,
]
,
}
,
]
,
extensions:
[
{
name: string ,
type: string ,
typeHandlerVersion: string ,
substatuses:
[
{
code: string ,
level: enum ,
displayStatus: string ,
message: string ,
time: string ,
}
,
]
,
statuses:
[
{
code: string ,
level: enum ,
displayStatus: string ,
message: string ,
time: string ,
}
,
]
,
}
,
]
,
vmHealth:
{
status:
{
code: string ,
level: enum ,
displayStatus: string ,
message: string ,
time: string ,
}
,
}
,
bootDiagnostics:
{
consoleScreenshotBlobUri: string ,
serialConsoleLogBlobUri: string ,
status:
{
code: string ,
level: enum ,
displayStatus: string ,
message: string ,
time: string ,
}
,
}
,
statuses:
[
{
code: string ,
level: enum ,
displayStatus: string ,
message: string ,
time: string ,
}
,
]
,
assignedHost: string ,
placementGroupId: string ,
computerName: string ,
osName: string ,
osVersion: string ,
hyperVGeneration: enum ,
}
,
hardwareProfile:
{
vmSize: enum ,
vmSizeProperties:
{
vCPUsAvailable: integer ,
vCPUsPerCore: integer ,
}
,
}
,
resilientVMDeletionStatus: enum ,
storageProfile:
{
imageReference:
{
publisher: string ,
offer: string ,
sku: string ,
version: string ,
exactVersion: string ,
sharedGalleryImageId: string ,
communityGalleryImageId: string ,
}
,
osDisk:
{
osType: enum ,
encryptionSettings:
{
diskEncryptionKey:
{
secretUrl: string ,
sourceVault:
{
id: string ,
}
,
}
,
keyEncryptionKey:
{
keyUrl: string ,
sourceVault:
{
id: string ,
}
,
}
,
enabled: boolean ,
}
,
name: string ,
vhd:
{
uri: string ,
}
,
image:
{
uri: string ,
}
,
caching: enum ,
writeAcceleratorEnabled: boolean ,
diffDiskSettings:
{
option: enum ,
placement: enum ,
}
,
createOption: enum ,
diskSizeGB: integer ,
managedDisk:
{
storageAccountType: enum ,
diskEncryptionSet: object ,
securityProfile:
{
securityEncryptionType: enum ,
diskEncryptionSet: object ,
}
,
}
,
deleteOption: enum ,
}
,
dataDisks:
[
{
lun: integer ,
name: string ,
vhd:
{
uri: string ,
}
,
image:
{
uri: string ,
}
,
caching: enum ,
writeAcceleratorEnabled: boolean ,
createOption: enum ,
diskSizeGB: integer ,
managedDisk:
{
storageAccountType: enum ,
diskEncryptionSet: object ,
securityProfile:
{
securityEncryptionType: enum ,
diskEncryptionSet: object ,
}
,
}
,
sourceResource:
{
id: string ,
}
,
toBeDetached: boolean ,
diskIOPSReadWrite: integer ,
diskMBpsReadWrite: integer ,
detachOption: enum ,
deleteOption: enum ,
}
,
]
,
diskControllerType: enum ,
alignRegionalDisksToVMZone: boolean ,
}
,
additionalCapabilities:
{
ultraSSDEnabled: boolean ,
hibernationEnabled: boolean ,
enableFips1403Encryption: boolean ,
}
,
osProfile:
{
computerName: string ,
adminUsername: string ,
adminPassword: string ,
customData: string ,
windowsConfiguration:
{
provisionVMAgent: boolean ,
enableAutomaticUpdates: boolean ,
timeZone: string ,
additionalUnattendContent:
[
{
passName: enum ,
componentName: enum ,
settingName: enum ,
content: string ,
}
,
]
,
patchSettings:
{
patchMode: enum ,
enableHotpatching: boolean ,
assessmentMode: enum ,
automaticByPlatformSettings:
{
rebootSetting: enum ,
bypassPlatformSafetyChecksOnUserSchedule: boolean ,
}
,
}
,
winRM:
{
listeners:
[
{
protocol: enum ,
certificateUrl: string ,
}
,
]
,
}
,
enableVMAgentPlatformUpdates: boolean ,
}
,
linuxConfiguration:
{
disablePasswordAuthentication: boolean ,
ssh:
{
publicKeys:
[
{
path: string ,
keyData: string ,
}
,
]
,
}
,
provisionVMAgent: boolean ,
patchSettings:
{
patchMode: enum ,
assessmentMode: enum ,
automaticByPlatformSettings:
{
rebootSetting: enum ,
bypassPlatformSafetyChecksOnUserSchedule: boolean ,
}
,
}
,
enableVMAgentPlatformUpdates: boolean ,
}
,
secrets:
[
{
sourceVault:
{
id: string ,
}
,
vaultCertificates:
[
{
certificateUrl: string ,
certificateStore: string ,
}
,
]
,
}
,
]
,
allowExtensionOperations: boolean ,
requireGuestProvisionSignal: boolean ,
}
,
securityProfile:
{
uefiSettings:
{
secureBootEnabled: boolean ,
vTpmEnabled: boolean ,
}
,
encryptionAtHost: boolean ,
securityType: enum ,
encryptionIdentity:
{
userAssignedIdentityResourceId: string ,
}
,
proxyAgentSettings:
{
enabled: boolean ,
mode: enum ,
keyIncarnationId: integer ,
wireServer:
{
mode: enum ,
inVMAccessControlProfileReferenceId: string ,
}
,
imds:
{
mode: enum ,
inVMAccessControlProfileReferenceId: string ,
}
,
addProxyAgentExtension: boolean ,
}
,
}
,
networkProfile:
{
networkInterfaces:
[
{
properties:
{
primary: boolean ,
deleteOption: enum ,
}
,
}
,
]
,
networkApiVersion: enum ,
networkInterfaceConfigurations:
[
{
name: string ,
properties:
{
primary: boolean ,
deleteOption: enum ,
enableAcceleratedNetworking: boolean ,
disableTcpStateTracking: boolean ,
enableFpga: boolean ,
enableIPForwarding: boolean ,
networkSecurityGroup:
{
id: string ,
}
,
dnsSettings:
{
dnsServers:
[
string ,
]
,
}
,
ipConfigurations:
[
{
name: string ,
properties:
{
subnet:
{
id: string ,
}
,
primary: boolean ,
publicIPAddressConfiguration:
{
name: string ,
properties:
{
idleTimeoutInMinutes: integer ,
deleteOption: enum ,
dnsSettings:
{
domainNameLabel: string ,
domainNameLabelScope: enum ,
}
,
ipTags:
[
{
ipTagType: string ,
tag: string ,
}
,
]
,
publicIPPrefix:
{
id: string ,
}
,
publicIPAddressVersion: enum ,
publicIPAllocationMethod: enum ,
}
,
sku:
{
name: enum ,
tier: enum ,
}
,
tags: object ,
}
,
privateIPAddressVersion: enum ,
applicationSecurityGroups:
[
{
id: string ,
}
,
]
,
applicationGatewayBackendAddressPools:
[
{
id: string ,
}
,
]
,
loadBalancerBackendAddressPools:
[
{
id: string ,
}
,
]
,
}
,
}
,
]
,
dscpConfiguration:
{
id: string ,
}
,
auxiliaryMode: enum ,
auxiliarySku: enum ,
}
,
tags: object ,
}
,
]
,
}
,
networkProfileConfiguration:
{
networkInterfaceConfigurations:
[
{
name: string ,
properties:
{
primary: boolean ,
enableAcceleratedNetworking: boolean ,
disableTcpStateTracking: boolean ,
enableFpga: boolean ,
networkSecurityGroup:
{
id: string ,
}
,
dnsSettings:
{
dnsServers:
[
string ,
]
,
}
,
ipConfigurations:
[
{
name: string ,
properties:
{
subnet:
{
id: string ,
}
,
primary: boolean ,
publicIPAddressConfiguration:
{
name: string ,
properties:
{
idleTimeoutInMinutes: integer ,
dnsSettings:
{
domainNameLabel: string ,
domainNameLabelScope: enum ,
}
,
ipTags:
[
{
ipTagType: string ,
tag: string ,
}
,
]
,
publicIPPrefix:
{
id: string ,
}
,
publicIPAddressVersion: enum ,
deleteOption: enum ,
}
,
sku:
{
name: enum ,
tier: enum ,
}
,
tags: object ,
}
,
privateIPAddressVersion: enum ,
applicationGatewayBackendAddressPools:
[
{
id: string ,
}
,
]
,
applicationSecurityGroups:
[
{
id: string ,
}
,
]
,
loadBalancerBackendAddressPools:
[
{
id: string ,
}
,
]
,
loadBalancerInboundNatPools:
[
{
id: string ,
}
,
]
,
}
,
}
,
]
,
enableIPForwarding: boolean ,
deleteOption: enum ,
auxiliaryMode: enum ,
auxiliarySku: enum ,
}
,
tags: object ,
}
,
]
,
}
,
diagnosticsProfile:
{
bootDiagnostics:
{
enabled: boolean ,
storageUri: string ,
}
,
}
,
availabilitySet:
{
id: string ,
}
,
provisioningState: string ,
licenseType: string ,
modelDefinitionApplied: string ,
protectionPolicy:
{
protectFromScaleIn: boolean ,
protectFromScaleSetActions: boolean ,
}
,
userData: string ,
timeCreated: string ,
}
,
instanceId: string ,
sku:
{
name: string ,
tier: string ,
capacity: integer ,
}
,
plan:
{
name: string ,
publisher: string ,
product: string ,
promotionCode: string ,
}
,
resources:
[
{
properties:
{
forceUpdateTag: string ,
publisher: string ,
type: string ,
typeHandlerVersion: string ,
autoUpgradeMinorVersion: boolean ,
enableAutomaticUpgrade: boolean ,
settings: string ,
protectedSettings: string ,
provisioningState: string ,
instanceView:
{
name: string ,
type: string ,
typeHandlerVersion: string ,
substatuses:
[
{
code: string ,
level: enum ,
displayStatus: string ,
message: string ,
time: string ,
}
,
]
,
statuses:
[
{
code: string ,
level: enum ,
displayStatus: string ,
message: string ,
time: string ,
}
,
]
,
}
,
suppressFailures: boolean ,
protectedSettingsFromKeyVault:
{
secretUrl: string ,
sourceVault:
{
id: string ,
}
,
}
,
provisionAfterExtensions:
[
string ,
]
,
}
,
}
,
]
,
zones:
[
string ,
]
,
identity:
{
principalId: string ,
tenantId: string ,
type: enum ,
userAssignedIdentities: object ,
}
,
etag: string ,
}

⚐ Response (202)

{
$headers:
{
location: string ,
retry-after: integer ,
}
,
$schema:
{
properties:
{
latestModelApplied: boolean ,
vmId: string ,
instanceView:
{
platformUpdateDomain: integer ,
platformFaultDomain: integer ,
rdpThumbPrint: string ,
vmAgent:
{
vmAgentVersion: string ,
extensionHandlers:
[
{
type: string ,
typeHandlerVersion: string ,
status:
{
code: string ,
level: enum ,
displayStatus: string ,
message: string ,
time: string ,
}
,
}
,
]
,
statuses:
[
{
code: string ,
level: enum ,
displayStatus: string ,
message: string ,
time: string ,
}
,
]
,
}
,
maintenanceRedeployStatus:
{
isCustomerInitiatedMaintenanceAllowed: boolean ,
preMaintenanceWindowStartTime: string ,
preMaintenanceWindowEndTime: string ,
maintenanceWindowStartTime: string ,
maintenanceWindowEndTime: string ,
lastOperationResultCode: enum ,
lastOperationMessage: string ,
}
,
disks:
[
{
name: string ,
encryptionSettings:
[
{
diskEncryptionKey:
{
secretUrl: string ,
sourceVault:
{
id: string ,
}
,
}
,
keyEncryptionKey:
{
keyUrl: string ,
sourceVault:
{
id: string ,
}
,
}
,
enabled: boolean ,
}
,
]
,
statuses:
[
{
code: string ,
level: enum ,
displayStatus: string ,
message: string ,
time: string ,
}
,
]
,
}
,
]
,
extensions:
[
{
name: string ,
type: string ,
typeHandlerVersion: string ,
substatuses:
[
{
code: string ,
level: enum ,
displayStatus: string ,
message: string ,
time: string ,
}
,
]
,
statuses:
[
{
code: string ,
level: enum ,
displayStatus: string ,
message: string ,
time: string ,
}
,
]
,
}
,
]
,
vmHealth:
{
status:
{
code: string ,
level: enum ,
displayStatus: string ,
message: string ,
time: string ,
}
,
}
,
bootDiagnostics:
{
consoleScreenshotBlobUri: string ,
serialConsoleLogBlobUri: string ,
status:
{
code: string ,
level: enum ,
displayStatus: string ,
message: string ,
time: string ,
}
,
}
,
statuses:
[
{
code: string ,
level: enum ,
displayStatus: string ,
message: string ,
time: string ,
}
,
]
,
assignedHost: string ,
placementGroupId: string ,
computerName: string ,
osName: string ,
osVersion: string ,
hyperVGeneration: enum ,
}
,
hardwareProfile:
{
vmSize: enum ,
vmSizeProperties:
{
vCPUsAvailable: integer ,
vCPUsPerCore: integer ,
}
,
}
,
resilientVMDeletionStatus: enum ,
storageProfile:
{
imageReference:
{
publisher: string ,
offer: string ,
sku: string ,
version: string ,
exactVersion: string ,
sharedGalleryImageId: string ,
communityGalleryImageId: string ,
}
,
osDisk:
{
osType: enum ,
encryptionSettings:
{
diskEncryptionKey:
{
secretUrl: string ,
sourceVault:
{
id: string ,
}
,
}
,
keyEncryptionKey:
{
keyUrl: string ,
sourceVault:
{
id: string ,
}
,
}
,
enabled: boolean ,
}
,
name: string ,
vhd:
{
uri: string ,
}
,
image:
{
uri: string ,
}
,
caching: enum ,
writeAcceleratorEnabled: boolean ,
diffDiskSettings:
{
option: enum ,
placement: enum ,
}
,
createOption: enum ,
diskSizeGB: integer ,
managedDisk:
{
storageAccountType: enum ,
diskEncryptionSet: object ,
securityProfile:
{
securityEncryptionType: enum ,
diskEncryptionSet: object ,
}
,
}
,
deleteOption: enum ,
}
,
dataDisks:
[
{
lun: integer ,
name: string ,
vhd:
{
uri: string ,
}
,
image:
{
uri: string ,
}
,
caching: enum ,
writeAcceleratorEnabled: boolean ,
createOption: enum ,
diskSizeGB: integer ,
managedDisk:
{
storageAccountType: enum ,
diskEncryptionSet: object ,
securityProfile:
{
securityEncryptionType: enum ,
diskEncryptionSet: object ,
}
,
}
,
sourceResource:
{
id: string ,
}
,
toBeDetached: boolean ,
diskIOPSReadWrite: integer ,
diskMBpsReadWrite: integer ,
detachOption: enum ,
deleteOption: enum ,
}
,
]
,
diskControllerType: enum ,
alignRegionalDisksToVMZone: boolean ,
}
,
additionalCapabilities:
{
ultraSSDEnabled: boolean ,
hibernationEnabled: boolean ,
enableFips1403Encryption: boolean ,
}
,
osProfile:
{
computerName: string ,
adminUsername: string ,
adminPassword: string ,
customData: string ,
windowsConfiguration:
{
provisionVMAgent: boolean ,
enableAutomaticUpdates: boolean ,
timeZone: string ,
additionalUnattendContent:
[
{
passName: enum ,
componentName: enum ,
settingName: enum ,
content: string ,
}
,
]
,
patchSettings:
{
patchMode: enum ,
enableHotpatching: boolean ,
assessmentMode: enum ,
automaticByPlatformSettings:
{
rebootSetting: enum ,
bypassPlatformSafetyChecksOnUserSchedule: boolean ,
}
,
}
,
winRM:
{
listeners:
[
{
protocol: enum ,
certificateUrl: string ,
}
,
]
,
}
,
enableVMAgentPlatformUpdates: boolean ,
}
,
linuxConfiguration:
{
disablePasswordAuthentication: boolean ,
ssh:
{
publicKeys:
[
{
path: string ,
keyData: string ,
}
,
]
,
}
,
provisionVMAgent: boolean ,
patchSettings:
{
patchMode: enum ,
assessmentMode: enum ,
automaticByPlatformSettings:
{
rebootSetting: enum ,
bypassPlatformSafetyChecksOnUserSchedule: boolean ,
}
,
}
,
enableVMAgentPlatformUpdates: boolean ,
}
,
secrets:
[
{
sourceVault:
{
id: string ,
}
,
vaultCertificates:
[
{
certificateUrl: string ,
certificateStore: string ,
}
,
]
,
}
,
]
,
allowExtensionOperations: boolean ,
requireGuestProvisionSignal: boolean ,
}
,
securityProfile:
{
uefiSettings:
{
secureBootEnabled: boolean ,
vTpmEnabled: boolean ,
}
,
encryptionAtHost: boolean ,
securityType: enum ,
encryptionIdentity:
{
userAssignedIdentityResourceId: string ,
}
,
proxyAgentSettings:
{
enabled: boolean ,
mode: enum ,
keyIncarnationId: integer ,
wireServer:
{
mode: enum ,
inVMAccessControlProfileReferenceId: string ,
}
,
imds:
{
mode: enum ,
inVMAccessControlProfileReferenceId: string ,
}
,
addProxyAgentExtension: boolean ,
}
,
}
,
networkProfile:
{
networkInterfaces:
[
{
properties:
{
primary: boolean ,
deleteOption: enum ,
}
,
}
,
]
,
networkApiVersion: enum ,
networkInterfaceConfigurations:
[
{
name: string ,
properties:
{
primary: boolean ,
deleteOption: enum ,
enableAcceleratedNetworking: boolean ,
disableTcpStateTracking: boolean ,
enableFpga: boolean ,
enableIPForwarding: boolean ,
networkSecurityGroup:
{
id: string ,
}
,
dnsSettings:
{
dnsServers:
[
string ,
]
,
}
,
ipConfigurations:
[
{
name: string ,
properties:
{
subnet:
{
id: string ,
}
,
primary: boolean ,
publicIPAddressConfiguration:
{
name: string ,
properties:
{
idleTimeoutInMinutes: integer ,
deleteOption: enum ,
dnsSettings:
{
domainNameLabel: string ,
domainNameLabelScope: enum ,
}
,
ipTags:
[
{
ipTagType: string ,
tag: string ,
}
,
]
,
publicIPPrefix:
{
id: string ,
}
,
publicIPAddressVersion: enum ,
publicIPAllocationMethod: enum ,
}
,
sku:
{
name: enum ,
tier: enum ,
}
,
tags: object ,
}
,
privateIPAddressVersion: enum ,
applicationSecurityGroups:
[
{
id: string ,
}
,
]
,
applicationGatewayBackendAddressPools:
[
{
id: string ,
}
,
]
,
loadBalancerBackendAddressPools:
[
{
id: string ,
}
,
]
,
}
,
}
,
]
,
dscpConfiguration:
{
id: string ,
}
,
auxiliaryMode: enum ,
auxiliarySku: enum ,
}
,
tags: object ,
}
,
]
,
}
,
networkProfileConfiguration:
{
networkInterfaceConfigurations:
[
{
name: string ,
properties:
{
primary: boolean ,
enableAcceleratedNetworking: boolean ,
disableTcpStateTracking: boolean ,
enableFpga: boolean ,
networkSecurityGroup:
{
id: string ,
}
,
dnsSettings:
{
dnsServers:
[
string ,
]
,
}
,
ipConfigurations:
[
{
name: string ,
properties:
{
subnet:
{
id: string ,
}
,
primary: boolean ,
publicIPAddressConfiguration:
{
name: string ,
properties:
{
idleTimeoutInMinutes: integer ,
dnsSettings:
{
domainNameLabel: string ,
domainNameLabelScope: enum ,
}
,
ipTags:
[
{
ipTagType: string ,
tag: string ,
}
,
]
,
publicIPPrefix:
{
id: string ,
}
,
publicIPAddressVersion: enum ,
deleteOption: enum ,
}
,
sku:
{
name: enum ,
tier: enum ,
}
,
tags: object ,
}
,
privateIPAddressVersion: enum ,
applicationGatewayBackendAddressPools:
[
{
id: string ,
}
,
]
,
applicationSecurityGroups:
[
{
id: string ,
}
,
]
,
loadBalancerBackendAddressPools:
[
{
id: string ,
}
,
]
,
loadBalancerInboundNatPools:
[
{
id: string ,
}
,
]
,
}
,
}
,
]
,
enableIPForwarding: boolean ,
deleteOption: enum ,
auxiliaryMode: enum ,
auxiliarySku: enum ,
}
,
tags: object ,
}
,
]
,
}
,
diagnosticsProfile:
{
bootDiagnostics:
{
enabled: boolean ,
storageUri: string ,
}
,
}
,
availabilitySet:
{
id: string ,
}
,
provisioningState: string ,
licenseType: string ,
modelDefinitionApplied: string ,
protectionPolicy:
{
protectFromScaleIn: boolean ,
protectFromScaleSetActions: boolean ,
}
,
userData: string ,
timeCreated: string ,
}
,
instanceId: string ,
sku:
{
name: string ,
tier: string ,
capacity: integer ,
}
,
plan:
{
name: string ,
publisher: string ,
product: string ,
promotionCode: string ,
}
,
resources:
[
{
properties:
{
forceUpdateTag: string ,
publisher: string ,
type: string ,
typeHandlerVersion: string ,
autoUpgradeMinorVersion: boolean ,
enableAutomaticUpgrade: boolean ,
settings: string ,
protectedSettings: string ,
provisioningState: string ,
instanceView:
{
name: string ,
type: string ,
typeHandlerVersion: string ,
substatuses:
[
{
code: string ,
level: enum ,
displayStatus: string ,
message: string ,
time: string ,
}
,
]
,
statuses:
[
{
code: string ,
level: enum ,
displayStatus: string ,
message: string ,
time: string ,
}
,
]
,
}
,
suppressFailures: boolean ,
protectedSettingsFromKeyVault:
{
secretUrl: string ,
sourceVault:
{
id: string ,
}
,
}
,
provisionAfterExtensions:
[
string ,
]
,
}
,
}
,
]
,
zones:
[
string ,
]
,
identity:
{
principalId: string ,
tenantId: string ,
type: enum ,
userAssignedIdentities: object ,
}
,
etag: string ,
}
,
}

⚐ Response (default)

{
error:
{
details:
[
{
code: string ,
target: string ,
message: string ,
}
,
]
,
innererror:
{
exceptiontype: string ,
errordetail: string ,
}
,
code: string ,
target: string ,
message: string ,
}
,
}
VirtualMachineScaleSetVMs_AttachDetachDataDisks (updated)
Description Attach and detach data disks to/from a virtual machine in a VM scale set.
Reference Link ¶

⚶ Changes

{
  "#id": "VirtualMachineScaleSetVMs_AttachDetachDataDisks",
  "$responses": {
    "200": {
      "$properties": {
        "dataDisks": {
          "$properties": [
            {
              "#name": "diskIOPSReadWrite",
              "Description": {
                "new": "Specifies the Read-Write IOPS for the managed disk when StorageAccountType is UltraSSD_LRS.",
                "old": "Specifies the Read-Write IOPS for the managed disk when StorageAccountType is UltraSSD_LRS. Returned only for VirtualMachine ScaleSet VM disks. Can be updated only via updates to the VirtualMachine Scale Set."
              }
            },
            {
              "#name": "diskMBpsReadWrite",
              "Description": {
                "new": "Specifies the bandwidth in MB per second for the managed disk when StorageAccountType is UltraSSD_LRS.",
                "old": "Specifies the bandwidth in MB per second for the managed disk when StorageAccountType is UltraSSD_LRS. Returned only for VirtualMachine ScaleSet VM disks. Can be updated only via updates to the VirtualMachine Scale Set."
              }
            }
          ]
        }
      }
    }
  }
}

⚼ Request

POST:  /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Compute/virtualMachineScaleSets/{vmScaleSetName}/virtualMachines/{instanceId}/attachDetachDataDisks
{
api-version: string ,
subscriptionId: string ,
resourceGroupName: string ,
vmScaleSetName: string ,
instanceId: string ,
parameters:
{
dataDisksToAttach:
[
{
diskId: string ,
lun: integer ,
caching: enum ,
deleteOption: enum ,
diskEncryptionSet: object ,
writeAcceleratorEnabled: boolean ,
}
,
]
,
dataDisksToDetach:
[
{
diskId: string ,
detachOption: enum ,
}
,
]
,
}
,
}

⚐ Response (200)

{
imageReference:
{
publisher: string ,
offer: string ,
sku: string ,
version: string ,
exactVersion: string ,
sharedGalleryImageId: string ,
communityGalleryImageId: string ,
}
,
osDisk:
{
osType: enum ,
encryptionSettings:
{
diskEncryptionKey:
{
secretUrl: string ,
sourceVault:
{
id: string ,
}
,
}
,
keyEncryptionKey:
{
keyUrl: string ,
sourceVault:
{
id: string ,
}
,
}
,
enabled: boolean ,
}
,
name: string ,
vhd:
{
uri: string ,
}
,
image:
{
uri: string ,
}
,
caching: enum ,
writeAcceleratorEnabled: boolean ,
diffDiskSettings:
{
option: enum ,
placement: enum ,
}
,
createOption: enum ,
diskSizeGB: integer ,
managedDisk:
{
storageAccountType: enum ,
diskEncryptionSet: object ,
securityProfile:
{
securityEncryptionType: enum ,
diskEncryptionSet: object ,
}
,
}
,
deleteOption: enum ,
}
,
dataDisks:
[
{
lun: integer ,
name: string ,
vhd:
{
uri: string ,
}
,
image:
{
uri: string ,
}
,
caching: enum ,
writeAcceleratorEnabled: boolean ,
createOption: enum ,
diskSizeGB: integer ,
managedDisk:
{
storageAccountType: enum ,
diskEncryptionSet: object ,
securityProfile:
{
securityEncryptionType: enum ,
diskEncryptionSet: object ,
}
,
}
,
sourceResource:
{
id: string ,
}
,
toBeDetached: boolean ,
diskIOPSReadWrite: integer ,
diskMBpsReadWrite: integer ,
detachOption: enum ,
deleteOption: enum ,
}
,
]
,
diskControllerType: enum ,
alignRegionalDisksToVMZone: boolean ,
}

⚐ Response (202)

{
location: string ,
retry-after: integer ,
}

⚐ Response (default)

{
error:
{
details:
[
{
code: string ,
target: string ,
message: string ,
}
,
]
,
innererror:
{
exceptiontype: string ,
errordetail: string ,
}
,
code: string ,
target: string ,
message: string ,
}
,
}
VirtualMachines_List (updated)
Description Lists all of the virtual machines in the specified resource group. Use the nextLink property in the response to get the next page of virtual machines.
Reference Link ¶

⚶ Changes

{
  "#id": "VirtualMachines_List",
  "$responses": {
    "200": {
      "$properties": {
        "value": {
          "$properties": {
            "properties": [
              {
                "storageProfile": [
                  {
                    "dataDisks": {
                      "$properties": [
                        {
                          "#name": "diskIOPSReadWrite",
                          "Description": {
                            "new": "Specifies the Read-Write IOPS for the managed disk when StorageAccountType is UltraSSD_LRS.",
                            "old": "Specifies the Read-Write IOPS for the managed disk when StorageAccountType is UltraSSD_LRS. Returned only for VirtualMachine ScaleSet VM disks. Can be updated only via updates to the VirtualMachine Scale Set."
                          }
                        },
                        {
                          "#name": "diskMBpsReadWrite",
                          "Description": {
                            "new": "Specifies the bandwidth in MB per second for the managed disk when StorageAccountType is UltraSSD_LRS.",
                            "old": "Specifies the bandwidth in MB per second for the managed disk when StorageAccountType is UltraSSD_LRS. Returned only for VirtualMachine ScaleSet VM disks. Can be updated only via updates to the VirtualMachine Scale Set."
                          }
                        }
                      ]
                    }
                  }
                ]
              }
            ]
          }
        }
      }
    }
  }
}

⚼ Request

GET:  /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Compute/virtualMachines
{
api-version: string ,
subscriptionId: string ,
resourceGroupName: string ,
$filter: string ,
$expand: string ,
}

⚐ Response (200)

{
value:
[
{
properties:
{
hardwareProfile:
{
vmSize: enum ,
vmSizeProperties:
{
vCPUsAvailable: integer ,
vCPUsPerCore: integer ,
}
,
}
,
scheduledEventsPolicy:
{
userInitiatedRedeploy:
{
automaticallyApprove: boolean ,
}
,
userInitiatedReboot:
{
automaticallyApprove: boolean ,
}
,
scheduledEventsAdditionalPublishingTargets:
{
eventGridAndResourceGraph:
{
enable: boolean ,
scheduledEventsApiVersion: string ,
}
,
}
,
allInstancesDown:
{
automaticallyApprove: boolean ,
}
,
}
,
storageProfile:
{
imageReference:
{
publisher: string ,
offer: string ,
sku: string ,
version: string ,
exactVersion: string ,
sharedGalleryImageId: string ,
communityGalleryImageId: string ,
}
,
osDisk:
{
osType: enum ,
encryptionSettings:
{
diskEncryptionKey:
{
secretUrl: string ,
sourceVault:
{
id: string ,
}
,
}
,
keyEncryptionKey:
{
keyUrl: string ,
sourceVault:
{
id: string ,
}
,
}
,
enabled: boolean ,
}
,
name: string ,
vhd:
{
uri: string ,
}
,
image:
{
uri: string ,
}
,
caching: enum ,
writeAcceleratorEnabled: boolean ,
diffDiskSettings:
{
option: enum ,
placement: enum ,
}
,
createOption: enum ,
diskSizeGB: integer ,
managedDisk:
{
storageAccountType: enum ,
diskEncryptionSet: object ,
securityProfile:
{
securityEncryptionType: enum ,
diskEncryptionSet: object ,
}
,
}
,
deleteOption: enum ,
}
,
dataDisks:
[
{
lun: integer ,
name: string ,
vhd:
{
uri: string ,
}
,
image:
{
uri: string ,
}
,
caching: enum ,
writeAcceleratorEnabled: boolean ,
createOption: enum ,
diskSizeGB: integer ,
managedDisk:
{
storageAccountType: enum ,
diskEncryptionSet: object ,
securityProfile:
{
securityEncryptionType: enum ,
diskEncryptionSet: object ,
}
,
}
,
sourceResource:
{
id: string ,
}
,
toBeDetached: boolean ,
diskIOPSReadWrite: integer ,
diskMBpsReadWrite: integer ,
detachOption: enum ,
deleteOption: enum ,
}
,
]
,
diskControllerType: enum ,
alignRegionalDisksToVMZone: boolean ,
}
,
additionalCapabilities:
{
ultraSSDEnabled: boolean ,
hibernationEnabled: boolean ,
enableFips1403Encryption: boolean ,
}
,
osProfile:
{
computerName: string ,
adminUsername: string ,
adminPassword: string ,
customData: string ,
windowsConfiguration:
{
provisionVMAgent: boolean ,
enableAutomaticUpdates: boolean ,
timeZone: string ,
additionalUnattendContent:
[
{
passName: enum ,
componentName: enum ,
settingName: enum ,
content: string ,
}
,
]
,
patchSettings:
{
patchMode: enum ,
enableHotpatching: boolean ,
assessmentMode: enum ,
automaticByPlatformSettings:
{
rebootSetting: enum ,
bypassPlatformSafetyChecksOnUserSchedule: boolean ,
}
,
}
,
winRM:
{
listeners:
[
{
protocol: enum ,
certificateUrl: string ,
}
,
]
,
}
,
enableVMAgentPlatformUpdates: boolean ,
}
,
linuxConfiguration:
{
disablePasswordAuthentication: boolean ,
ssh:
{
publicKeys:
[
{
path: string ,
keyData: string ,
}
,
]
,
}
,
provisionVMAgent: boolean ,
patchSettings:
{
patchMode: enum ,
assessmentMode: enum ,
automaticByPlatformSettings:
{
rebootSetting: enum ,
bypassPlatformSafetyChecksOnUserSchedule: boolean ,
}
,
}
,
enableVMAgentPlatformUpdates: boolean ,
}
,
secrets:
[
{
sourceVault:
{
id: string ,
}
,
vaultCertificates:
[
{
certificateUrl: string ,
certificateStore: string ,
}
,
]
,
}
,
]
,
allowExtensionOperations: boolean ,
requireGuestProvisionSignal: boolean ,
}
,
networkProfile:
{
networkInterfaces:
[
{
properties:
{
primary: boolean ,
deleteOption: enum ,
}
,
}
,
]
,
networkApiVersion: enum ,
networkInterfaceConfigurations:
[
{
name: string ,
properties:
{
primary: boolean ,
deleteOption: enum ,
enableAcceleratedNetworking: boolean ,
disableTcpStateTracking: boolean ,
enableFpga: boolean ,
enableIPForwarding: boolean ,
networkSecurityGroup:
{
id: string ,
}
,
dnsSettings:
{
dnsServers:
[
string ,
]
,
}
,
ipConfigurations:
[
{
name: string ,
properties:
{
subnet:
{
id: string ,
}
,
primary: boolean ,
publicIPAddressConfiguration:
{
name: string ,
properties:
{
idleTimeoutInMinutes: integer ,
deleteOption: enum ,
dnsSettings:
{
domainNameLabel: string ,
domainNameLabelScope: enum ,
}
,
ipTags:
[
{
ipTagType: string ,
tag: string ,
}
,
]
,
publicIPPrefix:
{
id: string ,
}
,
publicIPAddressVersion: enum ,
publicIPAllocationMethod: enum ,
}
,
sku:
{
name: enum ,
tier: enum ,
}
,
tags: object ,
}
,
privateIPAddressVersion: enum ,
applicationSecurityGroups:
[
{
id: string ,
}
,
]
,
applicationGatewayBackendAddressPools:
[
{
id: string ,
}
,
]
,
loadBalancerBackendAddressPools:
[
{
id: string ,
}
,
]
,
}
,
}
,
]
,
dscpConfiguration:
{
id: string ,
}
,
auxiliaryMode: enum ,
auxiliarySku: enum ,
}
,
tags: object ,
}
,
]
,
}
,
securityProfile:
{
uefiSettings:
{
secureBootEnabled: boolean ,
vTpmEnabled: boolean ,
}
,
encryptionAtHost: boolean ,
securityType: enum ,
encryptionIdentity:
{
userAssignedIdentityResourceId: string ,
}
,
proxyAgentSettings:
{
enabled: boolean ,
mode: enum ,
keyIncarnationId: integer ,
wireServer:
{
mode: enum ,
inVMAccessControlProfileReferenceId: string ,
}
,
imds:
{
mode: enum ,
inVMAccessControlProfileReferenceId: string ,
}
,
addProxyAgentExtension: boolean ,
}
,
}
,
diagnosticsProfile:
{
bootDiagnostics:
{
enabled: boolean ,
storageUri: string ,
}
,
}
,
availabilitySet:
{
id: string ,
}
,
virtualMachineScaleSet:
{
id: string ,
}
,
proximityPlacementGroup:
{
id: string ,
}
,
priority: enum ,
evictionPolicy: enum ,
billingProfile:
{
maxPrice: number ,
}
,
host:
{
id: string ,
}
,
hostGroup:
{
id: string ,
}
,
provisioningState: string ,
instanceView:
{
platformUpdateDomain: integer ,
platformFaultDomain: integer ,
computerName: string ,
osName: string ,
osVersion: string ,
hyperVGeneration: enum ,
rdpThumbPrint: string ,
vmAgent:
{
vmAgentVersion: string ,
extensionHandlers:
[
{
type: string ,
typeHandlerVersion: string ,
status:
{
code: string ,
level: enum ,
displayStatus: string ,
message: string ,
time: string ,
}
,
}
,
]
,
statuses:
[
{
code: string ,
level: enum ,
displayStatus: string ,
message: string ,
time: string ,
}
,
]
,
}
,
maintenanceRedeployStatus:
{
isCustomerInitiatedMaintenanceAllowed: boolean ,
preMaintenanceWindowStartTime: string ,
preMaintenanceWindowEndTime: string ,
maintenanceWindowStartTime: string ,
maintenanceWindowEndTime: string ,
lastOperationResultCode: enum ,
lastOperationMessage: string ,
}
,
disks:
[
{
name: string ,
encryptionSettings:
[
{
diskEncryptionKey:
{
secretUrl: string ,
sourceVault:
{
id: string ,
}
,
}
,
keyEncryptionKey:
{
keyUrl: string ,
sourceVault:
{
id: string ,
}
,
}
,
enabled: boolean ,
}
,
]
,
statuses:
[
{
code: string ,
level: enum ,
displayStatus: string ,
message: string ,
time: string ,
}
,
]
,
}
,
]
,
extensions:
[
{
name: string ,
type: string ,
typeHandlerVersion: string ,
substatuses:
[
{
code: string ,
level: enum ,
displayStatus: string ,
message: string ,
time: string ,
}
,
]
,
statuses:
[
{
code: string ,
level: enum ,
displayStatus: string ,
message: string ,
time: string ,
}
,
]
,
}
,
]
,
vmHealth:
{
status:
{
code: string ,
level: enum ,
displayStatus: string ,
message: string ,
time: string ,
}
,
}
,
bootDiagnostics:
{
consoleScreenshotBlobUri: string ,
serialConsoleLogBlobUri: string ,
status:
{
code: string ,
level: enum ,
displayStatus: string ,
message: string ,
time: string ,
}
,
}
,
assignedHost: string ,
statuses:
[
{
code: string ,
level: enum ,
displayStatus: string ,
message: string ,
time: string ,
}
,
]
,
patchStatus:
{
availablePatchSummary:
{
status: enum ,
assessmentActivityId: string ,
rebootPending: boolean ,
criticalAndSecurityPatchCount: integer ,
otherPatchCount: integer ,
startTime: string ,
lastModifiedTime: string ,
error:
{
details:
[
{
code: string ,
target: string ,
message: string ,
}
,
]
,
innererror:
{
exceptiontype: string ,
errordetail: string ,
}
,
code: string ,
target: string ,
message: string ,
}
,
}
,
lastPatchInstallationSummary:
{
status: enum ,
installationActivityId: string ,
maintenanceWindowExceeded: boolean ,
notSelectedPatchCount: integer ,
excludedPatchCount: integer ,
pendingPatchCount: integer ,
installedPatchCount: integer ,
failedPatchCount: integer ,
startTime: string ,
lastModifiedTime: string ,
error:
{
details:
[
{
code: string ,
target: string ,
message: string ,
}
,
]
,
innererror:
{
exceptiontype: string ,
errordetail: string ,
}
,
code: string ,
target: string ,
message: string ,
}
,
}
,
configurationStatuses:
[
{
code: string ,
level: enum ,
displayStatus: string ,
message: string ,
time: string ,
}
,
]
,
}
,
isVMInStandbyPool: boolean ,
}
,
licenseType: string ,
vmId: string ,
extensionsTimeBudget: string ,
platformFaultDomain: integer ,
scheduledEventsProfile:
{
terminateNotificationProfile:
{
notBeforeTimeout: string ,
enable: boolean ,
}
,
osImageNotificationProfile:
{
notBeforeTimeout: string ,
enable: boolean ,
}
,
}
,
userData: string ,
capacityReservation:
{
capacityReservationGroup:
{
id: string ,
}
,
}
,
applicationProfile:
{
galleryApplications:
[
{
tags: string ,
order: integer ,
packageReferenceId: string ,
configurationReference: string ,
treatFailureAsDeploymentFailure: boolean ,
enableAutomaticUpgrade: boolean ,
}
,
]
,
}
,
timeCreated: string ,
}
,
plan:
{
name: string ,
publisher: string ,
product: string ,
promotionCode: string ,
}
,
resources:
[
{
properties:
{
forceUpdateTag: string ,
publisher: string ,
type: string ,
typeHandlerVersion: string ,
autoUpgradeMinorVersion: boolean ,
enableAutomaticUpgrade: boolean ,
settings: string ,
protectedSettings: string ,
provisioningState: string ,
instanceView:
{
name: string ,
type: string ,
typeHandlerVersion: string ,
substatuses:
[
{
code: string ,
level: enum ,
displayStatus: string ,
message: string ,
time: string ,
}
,
]
,
statuses:
[
{
code: string ,
level: enum ,
displayStatus: string ,
message: string ,
time: string ,
}
,
]
,
}
,
suppressFailures: boolean ,
protectedSettingsFromKeyVault:
{
secretUrl: string ,
sourceVault:
{
id: string ,
}
,
}
,
provisionAfterExtensions:
[
string ,
]
,
}
,
}
,
]
,
identity:
{
principalId: string ,
tenantId: string ,
type: enum ,
userAssignedIdentities: object ,
}
,
zones:
[
string ,
]
,
extendedLocation:
{
name: string ,
type: enum ,
}
,
managedBy: string ,
etag: string ,
placement:
{
zonePlacementPolicy: enum ,
includeZones:
[
string ,
]
,
excludeZones:
[
string ,
]
,
}
,
}
,
]
,
nextLink: string ,
}

⚐ Response (default)

{
error:
{
details:
[
{
code: string ,
target: string ,
message: string ,
}
,
]
,
innererror:
{
exceptiontype: string ,
errordetail: string ,
}
,
code: string ,
target: string ,
message: string ,
}
,
}
VirtualMachines_Get (updated)
Description Retrieves information about the model view or the instance view of a virtual machine.
Reference Link ¶

⚶ Changes

{
  "#id": "VirtualMachines_Get",
  "$responses": {
    "200": {
      "$properties": {
        "properties": [
          {
            "storageProfile": [
              {
                "dataDisks": {
                  "$properties": [
                    {
                      "#name": "diskIOPSReadWrite",
                      "Description": {
                        "new": "Specifies the Read-Write IOPS for the managed disk when StorageAccountType is UltraSSD_LRS.",
                        "old": "Specifies the Read-Write IOPS for the managed disk when StorageAccountType is UltraSSD_LRS. Returned only for VirtualMachine ScaleSet VM disks. Can be updated only via updates to the VirtualMachine Scale Set."
                      }
                    },
                    {
                      "#name": "diskMBpsReadWrite",
                      "Description": {
                        "new": "Specifies the bandwidth in MB per second for the managed disk when StorageAccountType is UltraSSD_LRS.",
                        "old": "Specifies the bandwidth in MB per second for the managed disk when StorageAccountType is UltraSSD_LRS. Returned only for VirtualMachine ScaleSet VM disks. Can be updated only via updates to the VirtualMachine Scale Set."
                      }
                    }
                  ]
                }
              }
            ]
          }
        ]
      }
    }
  }
}

⚼ Request

GET:  /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Compute/virtualMachines/{vmName}
{
api-version: string ,
subscriptionId: string ,
resourceGroupName: string ,
vmName: string ,
$expand: string ,
}

⚐ Response (200)

{
properties:
{
hardwareProfile:
{
vmSize: enum ,
vmSizeProperties:
{
vCPUsAvailable: integer ,
vCPUsPerCore: integer ,
}
,
}
,
scheduledEventsPolicy:
{
userInitiatedRedeploy:
{
automaticallyApprove: boolean ,
}
,
userInitiatedReboot:
{
automaticallyApprove: boolean ,
}
,
scheduledEventsAdditionalPublishingTargets:
{
eventGridAndResourceGraph:
{
enable: boolean ,
scheduledEventsApiVersion: string ,
}
,
}
,
allInstancesDown:
{
automaticallyApprove: boolean ,
}
,
}
,
storageProfile:
{
imageReference:
{
publisher: string ,
offer: string ,
sku: string ,
version: string ,
exactVersion: string ,
sharedGalleryImageId: string ,
communityGalleryImageId: string ,
}
,
osDisk:
{
osType: enum ,
encryptionSettings:
{
diskEncryptionKey:
{
secretUrl: string ,
sourceVault:
{
id: string ,
}
,
}
,
keyEncryptionKey:
{
keyUrl: string ,
sourceVault:
{
id: string ,
}
,
}
,
enabled: boolean ,
}
,
name: string ,
vhd:
{
uri: string ,
}
,
image:
{
uri: string ,
}
,
caching: enum ,
writeAcceleratorEnabled: boolean ,
diffDiskSettings:
{
option: enum ,
placement: enum ,
}
,
createOption: enum ,
diskSizeGB: integer ,
managedDisk:
{
storageAccountType: enum ,
diskEncryptionSet: object ,
securityProfile:
{
securityEncryptionType: enum ,
diskEncryptionSet: object ,
}
,
}
,
deleteOption: enum ,
}
,
dataDisks:
[
{
lun: integer ,
name: string ,
vhd:
{
uri: string ,
}
,
image:
{
uri: string ,
}
,
caching: enum ,
writeAcceleratorEnabled: boolean ,
createOption: enum ,
diskSizeGB: integer ,
managedDisk:
{
storageAccountType: enum ,
diskEncryptionSet: object ,
securityProfile:
{
securityEncryptionType: enum ,
diskEncryptionSet: object ,
}
,
}
,
sourceResource:
{
id: string ,
}
,
toBeDetached: boolean ,
diskIOPSReadWrite: integer ,
diskMBpsReadWrite: integer ,
detachOption: enum ,
deleteOption: enum ,
}
,
]
,
diskControllerType: enum ,
alignRegionalDisksToVMZone: boolean ,
}
,
additionalCapabilities:
{
ultraSSDEnabled: boolean ,
hibernationEnabled: boolean ,
enableFips1403Encryption: boolean ,
}
,
osProfile:
{
computerName: string ,
adminUsername: string ,
adminPassword: string ,
customData: string ,
windowsConfiguration:
{
provisionVMAgent: boolean ,
enableAutomaticUpdates: boolean ,
timeZone: string ,
additionalUnattendContent:
[
{
passName: enum ,
componentName: enum ,
settingName: enum ,
content: string ,
}
,
]
,
patchSettings:
{
patchMode: enum ,
enableHotpatching: boolean ,
assessmentMode: enum ,
automaticByPlatformSettings:
{
rebootSetting: enum ,
bypassPlatformSafetyChecksOnUserSchedule: boolean ,
}
,
}
,
winRM:
{
listeners:
[
{
protocol: enum ,
certificateUrl: string ,
}
,
]
,
}
,
enableVMAgentPlatformUpdates: boolean ,
}
,
linuxConfiguration:
{
disablePasswordAuthentication: boolean ,
ssh:
{
publicKeys:
[
{
path: string ,
keyData: string ,
}
,
]
,
}
,
provisionVMAgent: boolean ,
patchSettings:
{
patchMode: enum ,
assessmentMode: enum ,
automaticByPlatformSettings:
{
rebootSetting: enum ,
bypassPlatformSafetyChecksOnUserSchedule: boolean ,
}
,
}
,
enableVMAgentPlatformUpdates: boolean ,
}
,
secrets:
[
{
sourceVault:
{
id: string ,
}
,
vaultCertificates:
[
{
certificateUrl: string ,
certificateStore: string ,
}
,
]
,
}
,
]
,
allowExtensionOperations: boolean ,
requireGuestProvisionSignal: boolean ,
}
,
networkProfile:
{
networkInterfaces:
[
{
properties:
{
primary: boolean ,
deleteOption: enum ,
}
,
}
,
]
,
networkApiVersion: enum ,
networkInterfaceConfigurations:
[
{
name: string ,
properties:
{
primary: boolean ,
deleteOption: enum ,
enableAcceleratedNetworking: boolean ,
disableTcpStateTracking: boolean ,
enableFpga: boolean ,
enableIPForwarding: boolean ,
networkSecurityGroup:
{
id: string ,
}
,
dnsSettings:
{
dnsServers:
[
string ,
]
,
}
,
ipConfigurations:
[
{
name: string ,
properties:
{
subnet:
{
id: string ,
}
,
primary: boolean ,
publicIPAddressConfiguration:
{
name: string ,
properties:
{
idleTimeoutInMinutes: integer ,
deleteOption: enum ,
dnsSettings:
{
domainNameLabel: string ,
domainNameLabelScope: enum ,
}
,
ipTags:
[
{
ipTagType: string ,
tag: string ,
}
,
]
,
publicIPPrefix:
{
id: string ,
}
,
publicIPAddressVersion: enum ,
publicIPAllocationMethod: enum ,
}
,
sku:
{
name: enum ,
tier: enum ,
}
,
tags: object ,
}
,
privateIPAddressVersion: enum ,
applicationSecurityGroups:
[
{
id: string ,
}
,
]
,
applicationGatewayBackendAddressPools:
[
{
id: string ,
}
,
]
,
loadBalancerBackendAddressPools:
[
{
id: string ,
}
,
]
,
}
,
}
,
]
,
dscpConfiguration:
{
id: string ,
}
,
auxiliaryMode: enum ,
auxiliarySku: enum ,
}
,
tags: object ,
}
,
]
,
}
,
securityProfile:
{
uefiSettings:
{
secureBootEnabled: boolean ,
vTpmEnabled: boolean ,
}
,
encryptionAtHost: boolean ,
securityType: enum ,
encryptionIdentity:
{
userAssignedIdentityResourceId: string ,
}
,
proxyAgentSettings:
{
enabled: boolean ,
mode: enum ,
keyIncarnationId: integer ,
wireServer:
{
mode: enum ,
inVMAccessControlProfileReferenceId: string ,
}
,
imds:
{
mode: enum ,
inVMAccessControlProfileReferenceId: string ,
}
,
addProxyAgentExtension: boolean ,
}
,
}
,
diagnosticsProfile:
{
bootDiagnostics:
{
enabled: boolean ,
storageUri: string ,
}
,
}
,
availabilitySet:
{
id: string ,
}
,
virtualMachineScaleSet:
{
id: string ,
}
,
proximityPlacementGroup:
{
id: string ,
}
,
priority: enum ,
evictionPolicy: enum ,
billingProfile:
{
maxPrice: number ,
}
,
host:
{
id: string ,
}
,
hostGroup:
{
id: string ,
}
,
provisioningState: string ,
instanceView:
{
platformUpdateDomain: integer ,
platformFaultDomain: integer ,
computerName: string ,
osName: string ,
osVersion: string ,
hyperVGeneration: enum ,
rdpThumbPrint: string ,
vmAgent:
{
vmAgentVersion: string ,
extensionHandlers:
[
{
type: string ,
typeHandlerVersion: string ,
status:
{
code: string ,
level: enum ,
displayStatus: string ,
message: string ,
time: string ,
}
,
}
,
]
,
statuses:
[
{
code: string ,
level: enum ,
displayStatus: string ,
message: string ,
time: string ,
}
,
]
,
}
,
maintenanceRedeployStatus:
{
isCustomerInitiatedMaintenanceAllowed: boolean ,
preMaintenanceWindowStartTime: string ,
preMaintenanceWindowEndTime: string ,
maintenanceWindowStartTime: string ,
maintenanceWindowEndTime: string ,
lastOperationResultCode: enum ,
lastOperationMessage: string ,
}
,
disks:
[
{
name: string ,
encryptionSettings:
[
{
diskEncryptionKey:
{
secretUrl: string ,
sourceVault:
{
id: string ,
}
,
}
,
keyEncryptionKey:
{
keyUrl: string ,
sourceVault:
{
id: string ,
}
,
}
,
enabled: boolean ,
}
,
]
,
statuses:
[
{
code: string ,
level: enum ,
displayStatus: string ,
message: string ,
time: string ,
}
,
]
,
}
,
]
,
extensions:
[
{
name: string ,
type: string ,
typeHandlerVersion: string ,
substatuses:
[
{
code: string ,
level: enum ,
displayStatus: string ,
message: string ,
time: string ,
}
,
]
,
statuses:
[
{
code: string ,
level: enum ,
displayStatus: string ,
message: string ,
time: string ,
}
,
]
,
}
,
]
,
vmHealth:
{
status:
{
code: string ,
level: enum ,
displayStatus: string ,
message: string ,
time: string ,
}
,
}
,
bootDiagnostics:
{
consoleScreenshotBlobUri: string ,
serialConsoleLogBlobUri: string ,
status:
{
code: string ,
level: enum ,
displayStatus: string ,
message: string ,
time: string ,
}
,
}
,
assignedHost: string ,
statuses:
[
{
code: string ,
level: enum ,
displayStatus: string ,
message: string ,
time: string ,
}
,
]
,
patchStatus:
{
availablePatchSummary:
{
status: enum ,
assessmentActivityId: string ,
rebootPending: boolean ,
criticalAndSecurityPatchCount: integer ,
otherPatchCount: integer ,
startTime: string ,
lastModifiedTime: string ,
error:
{
details:
[
{
code: string ,
target: string ,
message: string ,
}
,
]
,
innererror:
{
exceptiontype: string ,
errordetail: string ,
}
,
code: string ,
target: string ,
message: string ,
}
,
}
,
lastPatchInstallationSummary:
{
status: enum ,
installationActivityId: string ,
maintenanceWindowExceeded: boolean ,
notSelectedPatchCount: integer ,
excludedPatchCount: integer ,
pendingPatchCount: integer ,
installedPatchCount: integer ,
failedPatchCount: integer ,
startTime: string ,
lastModifiedTime: string ,
error:
{
details:
[
{
code: string ,
target: string ,
message: string ,
}
,
]
,
innererror:
{
exceptiontype: string ,
errordetail: string ,
}
,
code: string ,
target: string ,
message: string ,
}
,
}
,
configurationStatuses:
[
{
code: string ,
level: enum ,
displayStatus: string ,
message: string ,
time: string ,
}
,
]
,
}
,
isVMInStandbyPool: boolean ,
}
,
licenseType: string ,
vmId: string ,
extensionsTimeBudget: string ,
platformFaultDomain: integer ,
scheduledEventsProfile:
{
terminateNotificationProfile:
{
notBeforeTimeout: string ,
enable: boolean ,
}
,
osImageNotificationProfile:
{
notBeforeTimeout: string ,
enable: boolean ,
}
,
}
,
userData: string ,
capacityReservation:
{
capacityReservationGroup:
{
id: string ,
}
,
}
,
applicationProfile:
{
galleryApplications:
[
{
tags: string ,
order: integer ,
packageReferenceId: string ,
configurationReference: string ,
treatFailureAsDeploymentFailure: boolean ,
enableAutomaticUpgrade: boolean ,
}
,
]
,
}
,
timeCreated: string ,
}
,
plan:
{
name: string ,
publisher: string ,
product: string ,
promotionCode: string ,
}
,
resources:
[
{
properties:
{
forceUpdateTag: string ,
publisher: string ,
type: string ,
typeHandlerVersion: string ,
autoUpgradeMinorVersion: boolean ,
enableAutomaticUpgrade: boolean ,
settings: string ,
protectedSettings: string ,
provisioningState: string ,
instanceView:
{
name: string ,
type: string ,
typeHandlerVersion: string ,
substatuses:
[
{
code: string ,
level: enum ,
displayStatus: string ,
message: string ,
time: string ,
}
,
]
,
statuses:
[
{
code: string ,
level: enum ,
displayStatus: string ,
message: string ,
time: string ,
}
,
]
,
}
,
suppressFailures: boolean ,
protectedSettingsFromKeyVault:
{
secretUrl: string ,
sourceVault:
{
id: string ,
}
,
}
,
provisionAfterExtensions:
[
string ,
]
,
}
,
}
,
]
,
identity:
{
principalId: string ,
tenantId: string ,
type: enum ,
userAssignedIdentities: object ,
}
,
zones:
[
string ,
]
,
extendedLocation:
{
name: string ,
type: enum ,
}
,
managedBy: string ,
etag: string ,
placement:
{
zonePlacementPolicy: enum ,
includeZones:
[
string ,
]
,
excludeZones:
[
string ,
]
,
}
,
}

⚐ Response (default)

{
error:
{
details:
[
{
code: string ,
target: string ,
message: string ,
}
,
]
,
innererror:
{
exceptiontype: string ,
errordetail: string ,
}
,
code: string ,
target: string ,
message: string ,
}
,
}
VirtualMachines_CreateOrUpdate (updated)
Description The operation to create or update a virtual machine. Please note some properties can be set only during virtual machine creation.
Reference Link ¶

⚶ Changes

{
  "#id": "VirtualMachines_CreateOrUpdate",
  "$parameters": {
    "parameters": {
      "$properties": {
        "properties": [
          {
            "storageProfile": [
              {
                "dataDisks": {
                  "$properties": [
                    {
                      "#name": "diskIOPSReadWrite",
                      "Description": {
                        "new": "Specifies the Read-Write IOPS for the managed disk when StorageAccountType is UltraSSD_LRS.",
                        "old": "Specifies the Read-Write IOPS for the managed disk when StorageAccountType is UltraSSD_LRS. Returned only for VirtualMachine ScaleSet VM disks. Can be updated only via updates to the VirtualMachine Scale Set."
                      }
                    },
                    {
                      "#name": "diskMBpsReadWrite",
                      "Description": {
                        "new": "Specifies the bandwidth in MB per second for the managed disk when StorageAccountType is UltraSSD_LRS.",
                        "old": "Specifies the bandwidth in MB per second for the managed disk when StorageAccountType is UltraSSD_LRS. Returned only for VirtualMachine ScaleSet VM disks. Can be updated only via updates to the VirtualMachine Scale Set."
                      }
                    }
                  ]
                }
              }
            ]
          }
        ]
      }
    }
  },
  "$responses": {
    "200": {
      "$properties": {
        "properties": [
          {
            "storageProfile": [
              {
                "dataDisks": {
                  "$properties": [
                    {
                      "#name": "diskIOPSReadWrite",
                      "Description": {
                        "new": "Specifies the Read-Write IOPS for the managed disk when StorageAccountType is UltraSSD_LRS.",
                        "old": "Specifies the Read-Write IOPS for the managed disk when StorageAccountType is UltraSSD_LRS. Returned only for VirtualMachine ScaleSet VM disks. Can be updated only via updates to the VirtualMachine Scale Set."
                      }
                    },
                    {
                      "#name": "diskMBpsReadWrite",
                      "Description": {
                        "new": "Specifies the bandwidth in MB per second for the managed disk when StorageAccountType is UltraSSD_LRS.",
                        "old": "Specifies the bandwidth in MB per second for the managed disk when StorageAccountType is UltraSSD_LRS. Returned only for VirtualMachine ScaleSet VM disks. Can be updated only via updates to the VirtualMachine Scale Set."
                      }
                    }
                  ]
                }
              }
            ]
          }
        ]
      }
    },
    "201": {
      "$properties": {
        "properties": [
          {
            "storageProfile": [
              {
                "dataDisks": {
                  "$properties": [
                    {
                      "#name": "diskIOPSReadWrite",
                      "Description": {
                        "new": "Specifies the Read-Write IOPS for the managed disk when StorageAccountType is UltraSSD_LRS.",
                        "old": "Specifies the Read-Write IOPS for the managed disk when StorageAccountType is UltraSSD_LRS. Returned only for VirtualMachine ScaleSet VM disks. Can be updated only via updates to the VirtualMachine Scale Set."
                      }
                    },
                    {
                      "#name": "diskMBpsReadWrite",
                      "Description": {
                        "new": "Specifies the bandwidth in MB per second for the managed disk when StorageAccountType is UltraSSD_LRS.",
                        "old": "Specifies the bandwidth in MB per second for the managed disk when StorageAccountType is UltraSSD_LRS. Returned only for VirtualMachine ScaleSet VM disks. Can be updated only via updates to the VirtualMachine Scale Set."
                      }
                    }
                  ]
                }
              }
            ]
          }
        ]
      }
    }
  }
}

⚼ Request

PUT:  /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Compute/virtualMachines/{vmName}
{
api-version: string ,
subscriptionId: string ,
resourceGroupName: string ,
vmName: string ,
If-Match: string ,
If-None-Match: string ,
parameters:
{
properties:
{
hardwareProfile:
{
vmSize: enum ,
vmSizeProperties:
{
vCPUsAvailable: integer ,
vCPUsPerCore: integer ,
}
,
}
,
scheduledEventsPolicy:
{
userInitiatedRedeploy:
{
automaticallyApprove: boolean ,
}
,
userInitiatedReboot:
{
automaticallyApprove: boolean ,
}
,
scheduledEventsAdditionalPublishingTargets:
{
eventGridAndResourceGraph:
{
enable: boolean ,
scheduledEventsApiVersion: string ,
}
,
}
,
allInstancesDown:
{
automaticallyApprove: boolean ,
}
,
}
,
storageProfile:
{
imageReference:
{
publisher: string ,
offer: string ,
sku: string ,
version: string ,
exactVersion: string ,
sharedGalleryImageId: string ,
communityGalleryImageId: string ,
}
,
osDisk:
{
osType: enum ,
encryptionSettings:
{
diskEncryptionKey:
{
secretUrl: string ,
sourceVault:
{
id: string ,
}
,
}
,
keyEncryptionKey:
{
keyUrl: string ,
sourceVault:
{
id: string ,
}
,
}
,
enabled: boolean ,
}
,
name: string ,
vhd:
{
uri: string ,
}
,
image:
{
uri: string ,
}
,
caching: enum ,
writeAcceleratorEnabled: boolean ,
diffDiskSettings:
{
option: enum ,
placement: enum ,
}
,
createOption: enum ,
diskSizeGB: integer ,
managedDisk:
{
storageAccountType: enum ,
diskEncryptionSet: object ,
securityProfile:
{
securityEncryptionType: enum ,
diskEncryptionSet: object ,
}
,
}
,
deleteOption: enum ,
}
,
dataDisks:
[
{
lun: integer ,
name: string ,
vhd:
{
uri: string ,
}
,
image:
{
uri: string ,
}
,
caching: enum ,
writeAcceleratorEnabled: boolean ,
createOption: enum ,
diskSizeGB: integer ,
managedDisk:
{
storageAccountType: enum ,
diskEncryptionSet: object ,
securityProfile:
{
securityEncryptionType: enum ,
diskEncryptionSet: object ,
}
,
}
,
sourceResource:
{
id: string ,
}
,
toBeDetached: boolean ,
diskIOPSReadWrite: integer ,
diskMBpsReadWrite: integer ,
detachOption: enum ,
deleteOption: enum ,
}
,
]
,
diskControllerType: enum ,
alignRegionalDisksToVMZone: boolean ,
}
,
additionalCapabilities:
{
ultraSSDEnabled: boolean ,
hibernationEnabled: boolean ,
enableFips1403Encryption: boolean ,
}
,
osProfile:
{
computerName: string ,
adminUsername: string ,
adminPassword: string ,
customData: string ,
windowsConfiguration:
{
provisionVMAgent: boolean ,
enableAutomaticUpdates: boolean ,
timeZone: string ,
additionalUnattendContent:
[
{
passName: enum ,
componentName: enum ,
settingName: enum ,
content: string ,
}
,
]
,
patchSettings:
{
patchMode: enum ,
enableHotpatching: boolean ,
assessmentMode: enum ,
automaticByPlatformSettings:
{
rebootSetting: enum ,
bypassPlatformSafetyChecksOnUserSchedule: boolean ,
}
,
}
,
winRM:
{
listeners:
[
{
protocol: enum ,
certificateUrl: string ,
}
,
]
,
}
,
enableVMAgentPlatformUpdates: boolean ,
}
,
linuxConfiguration:
{
disablePasswordAuthentication: boolean ,
ssh:
{
publicKeys:
[
{
path: string ,
keyData: string ,
}
,
]
,
}
,
provisionVMAgent: boolean ,
patchSettings:
{
patchMode: enum ,
assessmentMode: enum ,
automaticByPlatformSettings:
{
rebootSetting: enum ,
bypassPlatformSafetyChecksOnUserSchedule: boolean ,
}
,
}
,
enableVMAgentPlatformUpdates: boolean ,
}
,
secrets:
[
{
sourceVault:
{
id: string ,
}
,
vaultCertificates:
[
{
certificateUrl: string ,
certificateStore: string ,
}
,
]
,
}
,
]
,
allowExtensionOperations: boolean ,
requireGuestProvisionSignal: boolean ,
}
,
networkProfile:
{
networkInterfaces:
[
{
properties:
{
primary: boolean ,
deleteOption: enum ,
}
,
}
,
]
,
networkApiVersion: enum ,
networkInterfaceConfigurations:
[
{
name: string ,
properties:
{
primary: boolean ,
deleteOption: enum ,
enableAcceleratedNetworking: boolean ,
disableTcpStateTracking: boolean ,
enableFpga: boolean ,
enableIPForwarding: boolean ,
networkSecurityGroup:
{
id: string ,
}
,
dnsSettings:
{
dnsServers:
[
string ,
]
,
}
,
ipConfigurations:
[
{
name: string ,
properties:
{
subnet:
{
id: string ,
}
,
primary: boolean ,
publicIPAddressConfiguration:
{
name: string ,
properties:
{
idleTimeoutInMinutes: integer ,
deleteOption: enum ,
dnsSettings:
{
domainNameLabel: string ,
domainNameLabelScope: enum ,
}
,
ipTags:
[
{
ipTagType: string ,
tag: string ,
}
,
]
,
publicIPPrefix:
{
id: string ,
}
,
publicIPAddressVersion: enum ,
publicIPAllocationMethod: enum ,
}
,
sku:
{
name: enum ,
tier: enum ,
}
,
tags: object ,
}
,
privateIPAddressVersion: enum ,
applicationSecurityGroups:
[
{
id: string ,
}
,
]
,
applicationGatewayBackendAddressPools:
[
{
id: string ,
}
,
]
,
loadBalancerBackendAddressPools:
[
{
id: string ,
}
,
]
,
}
,
}
,
]
,
dscpConfiguration:
{
id: string ,
}
,
auxiliaryMode: enum ,
auxiliarySku: enum ,
}
,
tags: object ,
}
,
]
,
}
,
securityProfile:
{
uefiSettings:
{
secureBootEnabled: boolean ,
vTpmEnabled: boolean ,
}
,
encryptionAtHost: boolean ,
securityType: enum ,
encryptionIdentity:
{
userAssignedIdentityResourceId: string ,
}
,
proxyAgentSettings:
{
enabled: boolean ,
mode: enum ,
keyIncarnationId: integer ,
wireServer:
{
mode: enum ,
inVMAccessControlProfileReferenceId: string ,
}
,
imds:
{
mode: enum ,
inVMAccessControlProfileReferenceId: string ,
}
,
addProxyAgentExtension: boolean ,
}
,
}
,
diagnosticsProfile:
{
bootDiagnostics:
{
enabled: boolean ,
storageUri: string ,
}
,
}
,
availabilitySet:
{
id: string ,
}
,
virtualMachineScaleSet:
{
id: string ,
}
,
proximityPlacementGroup:
{
id: string ,
}
,
priority: enum ,
evictionPolicy: enum ,
billingProfile:
{
maxPrice: number ,
}
,
host:
{
id: string ,
}
,
hostGroup:
{
id: string ,
}
,
provisioningState: string ,
instanceView:
{
platformUpdateDomain: integer ,
platformFaultDomain: integer ,
computerName: string ,
osName: string ,
osVersion: string ,
hyperVGeneration: enum ,
rdpThumbPrint: string ,
vmAgent:
{
vmAgentVersion: string ,
extensionHandlers:
[
{
type: string ,
typeHandlerVersion: string ,
status:
{
code: string ,
level: enum ,
displayStatus: string ,
message: string ,
time: string ,
}
,
}
,
]
,
statuses:
[
{
code: string ,
level: enum ,
displayStatus: string ,
message: string ,
time: string ,
}
,
]
,
}
,
maintenanceRedeployStatus:
{
isCustomerInitiatedMaintenanceAllowed: boolean ,
preMaintenanceWindowStartTime: string ,
preMaintenanceWindowEndTime: string ,
maintenanceWindowStartTime: string ,
maintenanceWindowEndTime: string ,
lastOperationResultCode: enum ,
lastOperationMessage: string ,
}
,
disks:
[
{
name: string ,
encryptionSettings:
[
{
diskEncryptionKey:
{
secretUrl: string ,
sourceVault:
{
id: string ,
}
,
}
,
keyEncryptionKey:
{
keyUrl: string ,
sourceVault:
{
id: string ,
}
,
}
,
enabled: boolean ,
}
,
]
,
statuses:
[
{
code: string ,
level: enum ,
displayStatus: string ,
message: string ,
time: string ,
}
,
]
,
}
,
]
,
extensions:
[
{
name: string ,
type: string ,
typeHandlerVersion: string ,
substatuses:
[
{
code: string ,
level: enum ,
displayStatus: string ,
message: string ,
time: string ,
}
,
]
,
statuses:
[
{
code: string ,
level: enum ,
displayStatus: string ,
message: string ,
time: string ,
}
,
]
,
}
,
]
,
vmHealth:
{
status:
{
code: string ,
level: enum ,
displayStatus: string ,
message: string ,
time: string ,
}
,
}
,
bootDiagnostics:
{
consoleScreenshotBlobUri: string ,
serialConsoleLogBlobUri: string ,
status:
{
code: string ,
level: enum ,
displayStatus: string ,
message: string ,
time: string ,
}
,
}
,
assignedHost: string ,
statuses:
[
{
code: string ,
level: enum ,
displayStatus: string ,
message: string ,
time: string ,
}
,
]
,
patchStatus:
{
availablePatchSummary:
{
status: enum ,
assessmentActivityId: string ,
rebootPending: boolean ,
criticalAndSecurityPatchCount: integer ,
otherPatchCount: integer ,
startTime: string ,
lastModifiedTime: string ,
error:
{
details:
[
{
code: string ,
target: string ,
message: string ,
}
,
]
,
innererror:
{
exceptiontype: string ,
errordetail: string ,
}
,
code: string ,
target: string ,
message: string ,
}
,
}
,
lastPatchInstallationSummary:
{
status: enum ,
installationActivityId: string ,
maintenanceWindowExceeded: boolean ,
notSelectedPatchCount: integer ,
excludedPatchCount: integer ,
pendingPatchCount: integer ,
installedPatchCount: integer ,
failedPatchCount: integer ,
startTime: string ,
lastModifiedTime: string ,
error:
{
details:
[
{
code: string ,
target: string ,
message: string ,
}
,
]
,
innererror:
{
exceptiontype: string ,
errordetail: string ,
}
,
code: string ,
target: string ,
message: string ,
}
,
}
,
configurationStatuses:
[
{
code: string ,
level: enum ,
displayStatus: string ,
message: string ,
time: string ,
}
,
]
,
}
,
isVMInStandbyPool: boolean ,
}
,
licenseType: string ,
vmId: string ,
extensionsTimeBudget: string ,
platformFaultDomain: integer ,
scheduledEventsProfile:
{
terminateNotificationProfile:
{
notBeforeTimeout: string ,
enable: boolean ,
}
,
osImageNotificationProfile:
{
notBeforeTimeout: string ,
enable: boolean ,
}
,
}
,
userData: string ,
capacityReservation:
{
capacityReservationGroup:
{
id: string ,
}
,
}
,
applicationProfile:
{
galleryApplications:
[
{
tags: string ,
order: integer ,
packageReferenceId: string ,
configurationReference: string ,
treatFailureAsDeploymentFailure: boolean ,
enableAutomaticUpgrade: boolean ,
}
,
]
,
}
,
timeCreated: string ,
}
,
plan:
{
name: string ,
publisher: string ,
product: string ,
promotionCode: string ,
}
,
resources:
[
{
properties:
{
forceUpdateTag: string ,
publisher: string ,
type: string ,
typeHandlerVersion: string ,
autoUpgradeMinorVersion: boolean ,
enableAutomaticUpgrade: boolean ,
settings: string ,
protectedSettings: string ,
provisioningState: string ,
instanceView:
{
name: string ,
type: string ,
typeHandlerVersion: string ,
substatuses:
[
{
code: string ,
level: enum ,
displayStatus: string ,
message: string ,
time: string ,
}
,
]
,
statuses:
[
{
code: string ,
level: enum ,
displayStatus: string ,
message: string ,
time: string ,
}
,
]
,
}
,
suppressFailures: boolean ,
protectedSettingsFromKeyVault:
{
secretUrl: string ,
sourceVault:
{
id: string ,
}
,
}
,
provisionAfterExtensions:
[
string ,
]
,
}
,
}
,
]
,
identity:
{
principalId: string ,
tenantId: string ,
type: enum ,
userAssignedIdentities: object ,
}
,
zones:
[
string ,
]
,
extendedLocation:
{
name: string ,
type: enum ,
}
,
managedBy: string ,
etag: string ,
placement:
{
zonePlacementPolicy: enum ,
includeZones:
[
string ,
]
,
excludeZones:
[
string ,
]
,
}
,
}
,
}

⚐ Response (200)

{
properties:
{
hardwareProfile:
{
vmSize: enum ,
vmSizeProperties:
{
vCPUsAvailable: integer ,
vCPUsPerCore: integer ,
}
,
}
,
scheduledEventsPolicy:
{
userInitiatedRedeploy:
{
automaticallyApprove: boolean ,
}
,
userInitiatedReboot:
{
automaticallyApprove: boolean ,
}
,
scheduledEventsAdditionalPublishingTargets:
{
eventGridAndResourceGraph:
{
enable: boolean ,
scheduledEventsApiVersion: string ,
}
,
}
,
allInstancesDown:
{
automaticallyApprove: boolean ,
}
,
}
,
storageProfile:
{
imageReference:
{
publisher: string ,
offer: string ,
sku: string ,
version: string ,
exactVersion: string ,
sharedGalleryImageId: string ,
communityGalleryImageId: string ,
}
,
osDisk:
{
osType: enum ,
encryptionSettings:
{
diskEncryptionKey:
{
secretUrl: string ,
sourceVault:
{
id: string ,
}
,
}
,
keyEncryptionKey:
{
keyUrl: string ,
sourceVault:
{
id: string ,
}
,
}
,
enabled: boolean ,
}
,
name: string ,
vhd:
{
uri: string ,
}
,
image:
{
uri: string ,
}
,
caching: enum ,
writeAcceleratorEnabled: boolean ,
diffDiskSettings:
{
option: enum ,
placement: enum ,
}
,
createOption: enum ,
diskSizeGB: integer ,
managedDisk:
{
storageAccountType: enum ,
diskEncryptionSet: object ,
securityProfile:
{
securityEncryptionType: enum ,
diskEncryptionSet: object ,
}
,
}
,
deleteOption: enum ,
}
,
dataDisks:
[
{
lun: integer ,
name: string ,
vhd:
{
uri: string ,
}
,
image:
{
uri: string ,
}
,
caching: enum ,
writeAcceleratorEnabled: boolean ,
createOption: enum ,
diskSizeGB: integer ,
managedDisk:
{
storageAccountType: enum ,
diskEncryptionSet: object ,
securityProfile:
{
securityEncryptionType: enum ,
diskEncryptionSet: object ,
}
,
}
,
sourceResource:
{
id: string ,
}
,
toBeDetached: boolean ,
diskIOPSReadWrite: integer ,
diskMBpsReadWrite: integer ,
detachOption: enum ,
deleteOption: enum ,
}
,
]
,
diskControllerType: enum ,
alignRegionalDisksToVMZone: boolean ,
}
,
additionalCapabilities:
{
ultraSSDEnabled: boolean ,
hibernationEnabled: boolean ,
enableFips1403Encryption: boolean ,
}
,
osProfile:
{
computerName: string ,
adminUsername: string ,
adminPassword: string ,
customData: string ,
windowsConfiguration:
{
provisionVMAgent: boolean ,
enableAutomaticUpdates: boolean ,
timeZone: string ,
additionalUnattendContent:
[
{
passName: enum ,
componentName: enum ,
settingName: enum ,
content: string ,
}
,
]
,
patchSettings:
{
patchMode: enum ,
enableHotpatching: boolean ,
assessmentMode: enum ,
automaticByPlatformSettings:
{
rebootSetting: enum ,
bypassPlatformSafetyChecksOnUserSchedule: boolean ,
}
,
}
,
winRM:
{
listeners:
[
{
protocol: enum ,
certificateUrl: string ,
}
,
]
,
}
,
enableVMAgentPlatformUpdates: boolean ,
}
,
linuxConfiguration:
{
disablePasswordAuthentication: boolean ,
ssh:
{
publicKeys:
[
{
path: string ,
keyData: string ,
}
,
]
,
}
,
provisionVMAgent: boolean ,
patchSettings:
{
patchMode: enum ,
assessmentMode: enum ,
automaticByPlatformSettings:
{
rebootSetting: enum ,
bypassPlatformSafetyChecksOnUserSchedule: boolean ,
}
,
}
,
enableVMAgentPlatformUpdates: boolean ,
}
,
secrets:
[
{
sourceVault:
{
id: string ,
}
,
vaultCertificates:
[
{
certificateUrl: string ,
certificateStore: string ,
}
,
]
,
}
,
]
,
allowExtensionOperations: boolean ,
requireGuestProvisionSignal: boolean ,
}
,
networkProfile:
{
networkInterfaces:
[
{
properties:
{
primary: boolean ,
deleteOption: enum ,
}
,
}
,
]
,
networkApiVersion: enum ,
networkInterfaceConfigurations:
[
{
name: string ,
properties:
{
primary: boolean ,
deleteOption: enum ,
enableAcceleratedNetworking: boolean ,
disableTcpStateTracking: boolean ,
enableFpga: boolean ,
enableIPForwarding: boolean ,
networkSecurityGroup:
{
id: string ,
}
,
dnsSettings:
{
dnsServers:
[
string ,
]
,
}
,
ipConfigurations:
[
{
name: string ,
properties:
{
subnet:
{
id: string ,
}
,
primary: boolean ,
publicIPAddressConfiguration:
{
name: string ,
properties:
{
idleTimeoutInMinutes: integer ,
deleteOption: enum ,
dnsSettings:
{
domainNameLabel: string ,
domainNameLabelScope: enum ,
}
,
ipTags:
[
{
ipTagType: string ,
tag: string ,
}
,
]
,
publicIPPrefix:
{
id: string ,
}
,
publicIPAddressVersion: enum ,
publicIPAllocationMethod: enum ,
}
,
sku:
{
name: enum ,
tier: enum ,
}
,
tags: object ,
}
,
privateIPAddressVersion: enum ,
applicationSecurityGroups:
[
{
id: string ,
}
,
]
,
applicationGatewayBackendAddressPools:
[
{
id: string ,
}
,
]
,
loadBalancerBackendAddressPools:
[
{
id: string ,
}
,
]
,
}
,
}
,
]
,
dscpConfiguration:
{
id: string ,
}
,
auxiliaryMode: enum ,
auxiliarySku: enum ,
}
,
tags: object ,
}
,
]
,
}
,
securityProfile:
{
uefiSettings:
{
secureBootEnabled: boolean ,
vTpmEnabled: boolean ,
}
,
encryptionAtHost: boolean ,
securityType: enum ,
encryptionIdentity:
{
userAssignedIdentityResourceId: string ,
}
,
proxyAgentSettings:
{
enabled: boolean ,
mode: enum ,
keyIncarnationId: integer ,
wireServer:
{
mode: enum ,
inVMAccessControlProfileReferenceId: string ,
}
,
imds:
{
mode: enum ,
inVMAccessControlProfileReferenceId: string ,
}
,
addProxyAgentExtension: boolean ,
}
,
}
,
diagnosticsProfile:
{
bootDiagnostics:
{
enabled: boolean ,
storageUri: string ,
}
,
}
,
availabilitySet:
{
id: string ,
}
,
virtualMachineScaleSet:
{
id: string ,
}
,
proximityPlacementGroup:
{
id: string ,
}
,
priority: enum ,
evictionPolicy: enum ,
billingProfile:
{
maxPrice: number ,
}
,
host:
{
id: string ,
}
,
hostGroup:
{
id: string ,
}
,
provisioningState: string ,
instanceView:
{
platformUpdateDomain: integer ,
platformFaultDomain: integer ,
computerName: string ,
osName: string ,
osVersion: string ,
hyperVGeneration: enum ,
rdpThumbPrint: string ,
vmAgent:
{
vmAgentVersion: string ,
extensionHandlers:
[
{
type: string ,
typeHandlerVersion: string ,
status:
{
code: string ,
level: enum ,
displayStatus: string ,
message: string ,
time: string ,
}
,
}
,
]
,
statuses:
[
{
code: string ,
level: enum ,
displayStatus: string ,
message: string ,
time: string ,
}
,
]
,
}
,
maintenanceRedeployStatus:
{
isCustomerInitiatedMaintenanceAllowed: boolean ,
preMaintenanceWindowStartTime: string ,
preMaintenanceWindowEndTime: string ,
maintenanceWindowStartTime: string ,
maintenanceWindowEndTime: string ,
lastOperationResultCode: enum ,
lastOperationMessage: string ,
}
,
disks:
[
{
name: string ,
encryptionSettings:
[
{
diskEncryptionKey:
{
secretUrl: string ,
sourceVault:
{
id: string ,
}
,
}
,
keyEncryptionKey:
{
keyUrl: string ,
sourceVault:
{
id: string ,
}
,
}
,
enabled: boolean ,
}
,
]
,
statuses:
[
{
code: string ,
level: enum ,
displayStatus: string ,
message: string ,
time: string ,
}
,
]
,
}
,
]
,
extensions:
[
{
name: string ,
type: string ,
typeHandlerVersion: string ,
substatuses:
[
{
code: string ,
level: enum ,
displayStatus: string ,
message: string ,
time: string ,
}
,
]
,
statuses:
[
{
code: string ,
level: enum ,
displayStatus: string ,
message: string ,
time: string ,
}
,
]
,
}
,
]
,
vmHealth:
{
status:
{
code: string ,
level: enum ,
displayStatus: string ,
message: string ,
time: string ,
}
,
}
,
bootDiagnostics:
{
consoleScreenshotBlobUri: string ,
serialConsoleLogBlobUri: string ,
status:
{
code: string ,
level: enum ,
displayStatus: string ,
message: string ,
time: string ,
}
,
}
,
assignedHost: string ,
statuses:
[
{
code: string ,
level: enum ,
displayStatus: string ,
message: string ,
time: string ,
}
,
]
,
patchStatus:
{
availablePatchSummary:
{
status: enum ,
assessmentActivityId: string ,
rebootPending: boolean ,
criticalAndSecurityPatchCount: integer ,
otherPatchCount: integer ,
startTime: string ,
lastModifiedTime: string ,
error:
{
details:
[
{
code: string ,
target: string ,
message: string ,
}
,
]
,
innererror:
{
exceptiontype: string ,
errordetail: string ,
}
,
code: string ,
target: string ,
message: string ,
}
,
}
,
lastPatchInstallationSummary:
{
status: enum ,
installationActivityId: string ,
maintenanceWindowExceeded: boolean ,
notSelectedPatchCount: integer ,
excludedPatchCount: integer ,
pendingPatchCount: integer ,
installedPatchCount: integer ,
failedPatchCount: integer ,
startTime: string ,
lastModifiedTime: string ,
error:
{
details:
[
{
code: string ,
target: string ,
message: string ,
}
,
]
,
innererror:
{
exceptiontype: string ,
errordetail: string ,
}
,
code: string ,
target: string ,
message: string ,
}
,
}
,
configurationStatuses:
[
{
code: string ,
level: enum ,
displayStatus: string ,
message: string ,
time: string ,
}
,
]
,
}
,
isVMInStandbyPool: boolean ,
}
,
licenseType: string ,
vmId: string ,
extensionsTimeBudget: string ,
platformFaultDomain: integer ,
scheduledEventsProfile:
{
terminateNotificationProfile:
{
notBeforeTimeout: string ,
enable: boolean ,
}
,
osImageNotificationProfile:
{
notBeforeTimeout: string ,
enable: boolean ,
}
,
}
,
userData: string ,
capacityReservation:
{
capacityReservationGroup:
{
id: string ,
}
,
}
,
applicationProfile:
{
galleryApplications:
[
{
tags: string ,
order: integer ,
packageReferenceId: string ,
configurationReference: string ,
treatFailureAsDeploymentFailure: boolean ,
enableAutomaticUpgrade: boolean ,
}
,
]
,
}
,
timeCreated: string ,
}
,
plan:
{
name: string ,
publisher: string ,
product: string ,
promotionCode: string ,
}
,
resources:
[
{
properties:
{
forceUpdateTag: string ,
publisher: string ,
type: string ,
typeHandlerVersion: string ,
autoUpgradeMinorVersion: boolean ,
enableAutomaticUpgrade: boolean ,
settings: string ,
protectedSettings: string ,
provisioningState: string ,
instanceView:
{
name: string ,
type: string ,
typeHandlerVersion: string ,
substatuses:
[
{
code: string ,
level: enum ,
displayStatus: string ,
message: string ,
time: string ,
}
,
]
,
statuses:
[
{
code: string ,
level: enum ,
displayStatus: string ,
message: string ,
time: string ,
}
,
]
,
}
,
suppressFailures: boolean ,
protectedSettingsFromKeyVault:
{
secretUrl: string ,
sourceVault:
{
id: string ,
}
,
}
,
provisionAfterExtensions:
[
string ,
]
,
}
,
}
,
]
,
identity:
{
principalId: string ,
tenantId: string ,
type: enum ,
userAssignedIdentities: object ,
}
,
zones:
[
string ,
]
,
extendedLocation:
{
name: string ,
type: enum ,
}
,
managedBy: string ,
etag: string ,
placement:
{
zonePlacementPolicy: enum ,
includeZones:
[
string ,
]
,
excludeZones:
[
string ,
]
,
}
,
}

⚐ Response (201)

{
$headers:
{
location: string ,
retry-after: integer ,
}
,
$schema:
{
properties:
{
hardwareProfile:
{
vmSize: enum ,
vmSizeProperties:
{
vCPUsAvailable: integer ,
vCPUsPerCore: integer ,
}
,
}
,
scheduledEventsPolicy:
{
userInitiatedRedeploy:
{
automaticallyApprove: boolean ,
}
,
userInitiatedReboot:
{
automaticallyApprove: boolean ,
}
,
scheduledEventsAdditionalPublishingTargets:
{
eventGridAndResourceGraph:
{
enable: boolean ,
scheduledEventsApiVersion: string ,
}
,
}
,
allInstancesDown:
{
automaticallyApprove: boolean ,
}
,
}
,
storageProfile:
{
imageReference:
{
publisher: string ,
offer: string ,
sku: string ,
version: string ,
exactVersion: string ,
sharedGalleryImageId: string ,
communityGalleryImageId: string ,
}
,
osDisk:
{
osType: enum ,
encryptionSettings:
{
diskEncryptionKey:
{
secretUrl: string ,
sourceVault:
{
id: string ,
}
,
}
,
keyEncryptionKey:
{
keyUrl: string ,
sourceVault:
{
id: string ,
}
,
}
,
enabled: boolean ,
}
,
name: string ,
vhd:
{
uri: string ,
}
,
image:
{
uri: string ,
}
,
caching: enum ,
writeAcceleratorEnabled: boolean ,
diffDiskSettings:
{
option: enum ,
placement: enum ,
}
,
createOption: enum ,
diskSizeGB: integer ,
managedDisk:
{
storageAccountType: enum ,
diskEncryptionSet: object ,
securityProfile:
{
securityEncryptionType: enum ,
diskEncryptionSet: object ,
}
,
}
,
deleteOption: enum ,
}
,
dataDisks:
[
{
lun: integer ,
name: string ,
vhd:
{
uri: string ,
}
,
image:
{
uri: string ,
}
,
caching: enum ,
writeAcceleratorEnabled: boolean ,
createOption: enum ,
diskSizeGB: integer ,
managedDisk:
{
storageAccountType: enum ,
diskEncryptionSet: object ,
securityProfile:
{
securityEncryptionType: enum ,
diskEncryptionSet: object ,
}
,
}
,
sourceResource:
{
id: string ,
}
,
toBeDetached: boolean ,
diskIOPSReadWrite: integer ,
diskMBpsReadWrite: integer ,
detachOption: enum ,
deleteOption: enum ,
}
,
]
,
diskControllerType: enum ,
alignRegionalDisksToVMZone: boolean ,
}
,
additionalCapabilities:
{
ultraSSDEnabled: boolean ,
hibernationEnabled: boolean ,
enableFips1403Encryption: boolean ,
}
,
osProfile:
{
computerName: string ,
adminUsername: string ,
adminPassword: string ,
customData: string ,
windowsConfiguration:
{
provisionVMAgent: boolean ,
enableAutomaticUpdates: boolean ,
timeZone: string ,
additionalUnattendContent:
[
{
passName: enum ,
componentName: enum ,
settingName: enum ,
content: string ,
}
,
]
,
patchSettings:
{
patchMode: enum ,
enableHotpatching: boolean ,
assessmentMode: enum ,
automaticByPlatformSettings:
{
rebootSetting: enum ,
bypassPlatformSafetyChecksOnUserSchedule: boolean ,
}
,
}
,
winRM:
{
listeners:
[
{
protocol: enum ,
certificateUrl: string ,
}
,
]
,
}
,
enableVMAgentPlatformUpdates: boolean ,
}
,
linuxConfiguration:
{
disablePasswordAuthentication: boolean ,
ssh:
{
publicKeys:
[
{
path: string ,
keyData: string ,
}
,
]
,
}
,
provisionVMAgent: boolean ,
patchSettings:
{
patchMode: enum ,
assessmentMode: enum ,
automaticByPlatformSettings:
{
rebootSetting: enum ,
bypassPlatformSafetyChecksOnUserSchedule: boolean ,
}
,
}
,
enableVMAgentPlatformUpdates: boolean ,
}
,
secrets:
[
{
sourceVault:
{
id: string ,
}
,
vaultCertificates:
[
{
certificateUrl: string ,
certificateStore: string ,
}
,
]
,
}
,
]
,
allowExtensionOperations: boolean ,
requireGuestProvisionSignal: boolean ,
}
,
networkProfile:
{
networkInterfaces:
[
{
properties:
{
primary: boolean ,
deleteOption: enum ,
}
,
}
,
]
,
networkApiVersion: enum ,
networkInterfaceConfigurations:
[
{
name: string ,
properties:
{
primary: boolean ,
deleteOption: enum ,
enableAcceleratedNetworking: boolean ,
disableTcpStateTracking: boolean ,
enableFpga: boolean ,
enableIPForwarding: boolean ,
networkSecurityGroup:
{
id: string ,
}
,
dnsSettings:
{
dnsServers:
[
string ,
]
,
}
,
ipConfigurations:
[
{
name: string ,
properties:
{
subnet:
{
id: string ,
}
,
primary: boolean ,
publicIPAddressConfiguration:
{
name: string ,
properties:
{
idleTimeoutInMinutes: integer ,
deleteOption: enum ,
dnsSettings:
{
domainNameLabel: string ,
domainNameLabelScope: enum ,
}
,
ipTags:
[
{
ipTagType: string ,
tag: string ,
}
,
]
,
publicIPPrefix:
{
id: string ,
}
,
publicIPAddressVersion: enum ,
publicIPAllocationMethod: enum ,
}
,
sku:
{
name: enum ,
tier: enum ,
}
,
tags: object ,
}
,
privateIPAddressVersion: enum ,
applicationSecurityGroups:
[
{
id: string ,
}
,
]
,
applicationGatewayBackendAddressPools:
[
{
id: string ,
}
,
]
,
loadBalancerBackendAddressPools:
[
{
id: string ,
}
,
]
,
}
,
}
,
]
,
dscpConfiguration:
{
id: string ,
}
,
auxiliaryMode: enum ,
auxiliarySku: enum ,
}
,
tags: object ,
}
,
]
,
}
,
securityProfile:
{
uefiSettings:
{
secureBootEnabled: boolean ,
vTpmEnabled: boolean ,
}
,
encryptionAtHost: boolean ,
securityType: enum ,
encryptionIdentity:
{
userAssignedIdentityResourceId: string ,
}
,
proxyAgentSettings:
{
enabled: boolean ,
mode: enum ,
keyIncarnationId: integer ,
wireServer:
{
mode: enum ,
inVMAccessControlProfileReferenceId: string ,
}
,
imds:
{
mode: enum ,
inVMAccessControlProfileReferenceId: string ,
}
,
addProxyAgentExtension: boolean ,
}
,
}
,
diagnosticsProfile:
{
bootDiagnostics:
{
enabled: boolean ,
storageUri: string ,
}
,
}
,
availabilitySet:
{
id: string ,
}
,
virtualMachineScaleSet:
{
id: string ,
}
,
proximityPlacementGroup:
{
id: string ,
}
,
priority: enum ,
evictionPolicy: enum ,
billingProfile:
{
maxPrice: number ,
}
,
host:
{
id: string ,
}
,
hostGroup:
{
id: string ,
}
,
provisioningState: string ,
instanceView:
{
platformUpdateDomain: integer ,
platformFaultDomain: integer ,
computerName: string ,
osName: string ,
osVersion: string ,
hyperVGeneration: enum ,
rdpThumbPrint: string ,
vmAgent:
{
vmAgentVersion: string ,
extensionHandlers:
[
{
type: string ,
typeHandlerVersion: string ,
status:
{
code: string ,
level: enum ,
displayStatus: string ,
message: string ,
time: string ,
}
,
}
,
]
,
statuses:
[
{
code: string ,
level: enum ,
displayStatus: string ,
message: string ,
time: string ,
}
,
]
,
}
,
maintenanceRedeployStatus:
{
isCustomerInitiatedMaintenanceAllowed: boolean ,
preMaintenanceWindowStartTime: string ,
preMaintenanceWindowEndTime: string ,
maintenanceWindowStartTime: string ,
maintenanceWindowEndTime: string ,
lastOperationResultCode: enum ,
lastOperationMessage: string ,
}
,
disks:
[
{
name: string ,
encryptionSettings:
[
{
diskEncryptionKey:
{
secretUrl: string ,
sourceVault:
{
id: string ,
}
,
}
,
keyEncryptionKey:
{
keyUrl: string ,
sourceVault:
{
id: string ,
}
,
}
,
enabled: boolean ,
}
,
]
,
statuses:
[
{
code: string ,
level: enum ,
displayStatus: string ,
message: string ,
time: string ,
}
,
]
,
}
,
]
,
extensions:
[
{
name: string ,
type: string ,
typeHandlerVersion: string ,
substatuses:
[
{
code: string ,
level: enum ,
displayStatus: string ,
message: string ,
time: string ,
}
,
]
,
statuses:
[
{
code: string ,
level: enum ,
displayStatus: string ,
message: string ,
time: string ,
}
,
]
,
}
,
]
,
vmHealth:
{
status:
{
code: string ,
level: enum ,
displayStatus: string ,
message: string ,
time: string ,
}
,
}
,
bootDiagnostics:
{
consoleScreenshotBlobUri: string ,
serialConsoleLogBlobUri: string ,
status:
{
code: string ,
level: enum ,
displayStatus: string ,
message: string ,
time: string ,
}
,
}
,
assignedHost: string ,
statuses:
[
{
code: string ,
level: enum ,
displayStatus: string ,
message: string ,
time: string ,
}
,
]
,
patchStatus:
{
availablePatchSummary:
{
status: enum ,
assessmentActivityId: string ,
rebootPending: boolean ,
criticalAndSecurityPatchCount: integer ,
otherPatchCount: integer ,
startTime: string ,
lastModifiedTime: string ,
error:
{
details:
[
{
code: string ,
target: string ,
message: string ,
}
,
]
,
innererror:
{
exceptiontype: string ,
errordetail: string ,
}
,
code: string ,
target: string ,
message: string ,
}
,
}
,
lastPatchInstallationSummary:
{
status: enum ,
installationActivityId: string ,
maintenanceWindowExceeded: boolean ,
notSelectedPatchCount: integer ,
excludedPatchCount: integer ,
pendingPatchCount: integer ,
installedPatchCount: integer ,
failedPatchCount: integer ,
startTime: string ,
lastModifiedTime: string ,
error:
{
details:
[
{
code: string ,
target: string ,
message: string ,
}
,
]
,
innererror:
{
exceptiontype: string ,
errordetail: string ,
}
,
code: string ,
target: string ,
message: string ,
}
,
}
,
configurationStatuses:
[
{
code: string ,
level: enum ,
displayStatus: string ,
message: string ,
time: string ,
}
,
]
,
}
,
isVMInStandbyPool: boolean ,
}
,
licenseType: string ,
vmId: string ,
extensionsTimeBudget: string ,
platformFaultDomain: integer ,
scheduledEventsProfile:
{
terminateNotificationProfile:
{
notBeforeTimeout: string ,
enable: boolean ,
}
,
osImageNotificationProfile:
{
notBeforeTimeout: string ,
enable: boolean ,
}
,
}
,
userData: string ,
capacityReservation:
{
capacityReservationGroup:
{
id: string ,
}
,
}
,
applicationProfile:
{
galleryApplications:
[
{
tags: string ,
order: integer ,
packageReferenceId: string ,
configurationReference: string ,
treatFailureAsDeploymentFailure: boolean ,
enableAutomaticUpgrade: boolean ,
}
,
]
,
}
,
timeCreated: string ,
}
,
plan:
{
name: string ,
publisher: string ,
product: string ,
promotionCode: string ,
}
,
resources:
[
{
properties:
{
forceUpdateTag: string ,
publisher: string ,
type: string ,
typeHandlerVersion: string ,
autoUpgradeMinorVersion: boolean ,
enableAutomaticUpgrade: boolean ,
settings: string ,
protectedSettings: string ,
provisioningState: string ,
instanceView:
{
name: string ,
type: string ,
typeHandlerVersion: string ,
substatuses:
[
{
code: string ,
level: enum ,
displayStatus: string ,
message: string ,
time: string ,
}
,
]
,
statuses:
[
{
code: string ,
level: enum ,
displayStatus: string ,
message: string ,
time: string ,
}
,
]
,
}
,
suppressFailures: boolean ,
protectedSettingsFromKeyVault:
{
secretUrl: string ,
sourceVault:
{
id: string ,
}
,
}
,
provisionAfterExtensions:
[
string ,
]
,
}
,
}
,
]
,
identity:
{
principalId: string ,
tenantId: string ,
type: enum ,
userAssignedIdentities: object ,
}
,
zones:
[
string ,
]
,
extendedLocation:
{
name: string ,
type: enum ,
}
,
managedBy: string ,
etag: string ,
placement:
{
zonePlacementPolicy: enum ,
includeZones:
[
string ,
]
,
excludeZones:
[
string ,
]
,
}
,
}
,
}

⚐ Response (default)

{
error:
{
details:
[
{
code: string ,
target: string ,
message: string ,
}
,
]
,
innererror:
{
exceptiontype: string ,
errordetail: string ,
}
,
code: string ,
target: string ,
message: string ,
}
,
}
VirtualMachines_Update (updated)
Description The operation to update a virtual machine.
Reference Link ¶

⚶ Changes

{
  "#id": "VirtualMachines_Update",
  "$parameters": {
    "parameters": {
      "$properties": {
        "properties": [
          {
            "storageProfile": [
              {
                "dataDisks": {
                  "$properties": [
                    {
                      "#name": "diskIOPSReadWrite",
                      "Description": {
                        "new": "Specifies the Read-Write IOPS for the managed disk when StorageAccountType is UltraSSD_LRS.",
                        "old": "Specifies the Read-Write IOPS for the managed disk when StorageAccountType is UltraSSD_LRS. Returned only for VirtualMachine ScaleSet VM disks. Can be updated only via updates to the VirtualMachine Scale Set."
                      }
                    },
                    {
                      "#name": "diskMBpsReadWrite",
                      "Description": {
                        "new": "Specifies the bandwidth in MB per second for the managed disk when StorageAccountType is UltraSSD_LRS.",
                        "old": "Specifies the bandwidth in MB per second for the managed disk when StorageAccountType is UltraSSD_LRS. Returned only for VirtualMachine ScaleSet VM disks. Can be updated only via updates to the VirtualMachine Scale Set."
                      }
                    }
                  ]
                }
              }
            ]
          }
        ]
      }
    }
  },
  "$responses": {
    "200": {
      "$properties": {
        "properties": [
          {
            "storageProfile": [
              {
                "dataDisks": {
                  "$properties": [
                    {
                      "#name": "diskIOPSReadWrite",
                      "Description": {
                        "new": "Specifies the Read-Write IOPS for the managed disk when StorageAccountType is UltraSSD_LRS.",
                        "old": "Specifies the Read-Write IOPS for the managed disk when StorageAccountType is UltraSSD_LRS. Returned only for VirtualMachine ScaleSet VM disks. Can be updated only via updates to the VirtualMachine Scale Set."
                      }
                    },
                    {
                      "#name": "diskMBpsReadWrite",
                      "Description": {
                        "new": "Specifies the bandwidth in MB per second for the managed disk when StorageAccountType is UltraSSD_LRS.",
                        "old": "Specifies the bandwidth in MB per second for the managed disk when StorageAccountType is UltraSSD_LRS. Returned only for VirtualMachine ScaleSet VM disks. Can be updated only via updates to the VirtualMachine Scale Set."
                      }
                    }
                  ]
                }
              }
            ]
          }
        ]
      }
    }
  }
}

⚼ Request

PATCH:  /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Compute/virtualMachines/{vmName}
{
api-version: string ,
subscriptionId: string ,
resourceGroupName: string ,
vmName: string ,
If-Match: string ,
If-None-Match: string ,
parameters:
{
plan:
{
name: string ,
publisher: string ,
product: string ,
promotionCode: string ,
}
,
properties:
{
hardwareProfile:
{
vmSize: enum ,
vmSizeProperties:
{
vCPUsAvailable: integer ,
vCPUsPerCore: integer ,
}
,
}
,
scheduledEventsPolicy:
{
userInitiatedRedeploy:
{
automaticallyApprove: boolean ,
}
,
userInitiatedReboot:
{
automaticallyApprove: boolean ,
}
,
scheduledEventsAdditionalPublishingTargets:
{
eventGridAndResourceGraph:
{
enable: boolean ,
scheduledEventsApiVersion: string ,
}
,
}
,
allInstancesDown:
{
automaticallyApprove: boolean ,
}
,
}
,
storageProfile:
{
imageReference:
{
publisher: string ,
offer: string ,
sku: string ,
version: string ,
exactVersion: string ,
sharedGalleryImageId: string ,
communityGalleryImageId: string ,
}
,
osDisk:
{
osType: enum ,
encryptionSettings:
{
diskEncryptionKey:
{
secretUrl: string ,
sourceVault:
{
id: string ,
}
,
}
,
keyEncryptionKey:
{
keyUrl: string ,
sourceVault:
{
id: string ,
}
,
}
,
enabled: boolean ,
}
,
name: string ,
vhd:
{
uri: string ,
}
,
image:
{
uri: string ,
}
,
caching: enum ,
writeAcceleratorEnabled: boolean ,
diffDiskSettings:
{
option: enum ,
placement: enum ,
}
,
createOption: enum ,
diskSizeGB: integer ,
managedDisk:
{
storageAccountType: enum ,
diskEncryptionSet: object ,
securityProfile:
{
securityEncryptionType: enum ,
diskEncryptionSet: object ,
}
,
}
,
deleteOption: enum ,
}
,
dataDisks:
[
{
lun: integer ,
name: string ,
vhd:
{
uri: string ,
}
,
image:
{
uri: string ,
}
,
caching: enum ,
writeAcceleratorEnabled: boolean ,
createOption: enum ,
diskSizeGB: integer ,
managedDisk:
{
storageAccountType: enum ,
diskEncryptionSet: object ,
securityProfile:
{
securityEncryptionType: enum ,
diskEncryptionSet: object ,
}
,
}
,
sourceResource:
{
id: string ,
}
,
toBeDetached: boolean ,
diskIOPSReadWrite: integer ,
diskMBpsReadWrite: integer ,
detachOption: enum ,
deleteOption: enum ,
}
,
]
,
diskControllerType: enum ,
alignRegionalDisksToVMZone: boolean ,
}
,
additionalCapabilities:
{
ultraSSDEnabled: boolean ,
hibernationEnabled: boolean ,
enableFips1403Encryption: boolean ,
}
,
osProfile:
{
computerName: string ,
adminUsername: string ,
adminPassword: string ,
customData: string ,
windowsConfiguration:
{
provisionVMAgent: boolean ,
enableAutomaticUpdates: boolean ,
timeZone: string ,
additionalUnattendContent:
[
{
passName: enum ,
componentName: enum ,
settingName: enum ,
content: string ,
}
,
]
,
patchSettings:
{
patchMode: enum ,
enableHotpatching: boolean ,
assessmentMode: enum ,
automaticByPlatformSettings:
{
rebootSetting: enum ,
bypassPlatformSafetyChecksOnUserSchedule: boolean ,
}
,
}
,
winRM:
{
listeners:
[
{
protocol: enum ,
certificateUrl: string ,
}
,
]
,
}
,
enableVMAgentPlatformUpdates: boolean ,
}
,
linuxConfiguration:
{
disablePasswordAuthentication: boolean ,
ssh:
{
publicKeys:
[
{
path: string ,
keyData: string ,
}
,
]
,
}
,
provisionVMAgent: boolean ,
patchSettings:
{
patchMode: enum ,
assessmentMode: enum ,
automaticByPlatformSettings:
{
rebootSetting: enum ,
bypassPlatformSafetyChecksOnUserSchedule: boolean ,
}
,
}
,
enableVMAgentPlatformUpdates: boolean ,
}
,
secrets:
[
{
sourceVault:
{
id: string ,
}
,
vaultCertificates:
[
{
certificateUrl: string ,
certificateStore: string ,
}
,
]
,
}
,
]
,
allowExtensionOperations: boolean ,
requireGuestProvisionSignal: boolean ,
}
,
networkProfile:
{
networkInterfaces:
[
{
properties:
{
primary: boolean ,
deleteOption: enum ,
}
,
}
,
]
,
networkApiVersion: enum ,
networkInterfaceConfigurations:
[
{
name: string ,
properties:
{
primary: boolean ,
deleteOption: enum ,
enableAcceleratedNetworking: boolean ,
disableTcpStateTracking: boolean ,
enableFpga: boolean ,
enableIPForwarding: boolean ,
networkSecurityGroup:
{
id: string ,
}
,
dnsSettings:
{
dnsServers:
[
string ,
]
,
}
,
ipConfigurations:
[
{
name: string ,
properties:
{
subnet:
{
id: string ,
}
,
primary: boolean ,
publicIPAddressConfiguration:
{
name: string ,
properties:
{
idleTimeoutInMinutes: integer ,
deleteOption: enum ,
dnsSettings:
{
domainNameLabel: string ,
domainNameLabelScope: enum ,
}
,
ipTags:
[
{
ipTagType: string ,
tag: string ,
}
,
]
,
publicIPPrefix:
{
id: string ,
}
,
publicIPAddressVersion: enum ,
publicIPAllocationMethod: enum ,
}
,
sku:
{
name: enum ,
tier: enum ,
}
,
tags: object ,
}
,
privateIPAddressVersion: enum ,
applicationSecurityGroups:
[
{
id: string ,
}
,
]
,
applicationGatewayBackendAddressPools:
[
{
id: string ,
}
,
]
,
loadBalancerBackendAddressPools:
[
{
id: string ,
}
,
]
,
}
,
}
,
]
,
dscpConfiguration:
{
id: string ,
}
,
auxiliaryMode: enum ,
auxiliarySku: enum ,
}
,
tags: object ,
}
,
]
,
}
,
securityProfile:
{
uefiSettings:
{
secureBootEnabled: boolean ,
vTpmEnabled: boolean ,
}
,
encryptionAtHost: boolean ,
securityType: enum ,
encryptionIdentity:
{
userAssignedIdentityResourceId: string ,
}
,
proxyAgentSettings:
{
enabled: boolean ,
mode: enum ,
keyIncarnationId: integer ,
wireServer:
{
mode: enum ,
inVMAccessControlProfileReferenceId: string ,
}
,
imds:
{
mode: enum ,
inVMAccessControlProfileReferenceId: string ,
}
,
addProxyAgentExtension: boolean ,
}
,
}
,
diagnosticsProfile:
{
bootDiagnostics:
{
enabled: boolean ,
storageUri: string ,
}
,
}
,
availabilitySet:
{
id: string ,
}
,
virtualMachineScaleSet:
{
id: string ,
}
,
proximityPlacementGroup:
{
id: string ,
}
,
priority: enum ,
evictionPolicy: enum ,
billingProfile:
{
maxPrice: number ,
}
,
host:
{
id: string ,
}
,
hostGroup:
{
id: string ,
}
,
provisioningState: string ,
instanceView:
{
platformUpdateDomain: integer ,
platformFaultDomain: integer ,
computerName: string ,
osName: string ,
osVersion: string ,
hyperVGeneration: enum ,
rdpThumbPrint: string ,
vmAgent:
{
vmAgentVersion: string ,
extensionHandlers:
[
{
type: string ,
typeHandlerVersion: string ,
status:
{
code: string ,
level: enum ,
displayStatus: string ,
message: string ,
time: string ,
}
,
}
,
]
,
statuses:
[
{
code: string ,
level: enum ,
displayStatus: string ,
message: string ,
time: string ,
}
,
]
,
}
,
maintenanceRedeployStatus:
{
isCustomerInitiatedMaintenanceAllowed: boolean ,
preMaintenanceWindowStartTime: string ,
preMaintenanceWindowEndTime: string ,
maintenanceWindowStartTime: string ,
maintenanceWindowEndTime: string ,
lastOperationResultCode: enum ,
lastOperationMessage: string ,
}
,
disks:
[
{
name: string ,
encryptionSettings:
[
{
diskEncryptionKey:
{
secretUrl: string ,
sourceVault:
{
id: string ,
}
,
}
,
keyEncryptionKey:
{
keyUrl: string ,
sourceVault:
{
id: string ,
}
,
}
,
enabled: boolean ,
}
,
]
,
statuses:
[
{
code: string ,
level: enum ,
displayStatus: string ,
message: string ,
time: string ,
}
,
]
,
}
,
]
,
extensions:
[
{
name: string ,
type: string ,
typeHandlerVersion: string ,
substatuses:
[
{
code: string ,
level: enum ,
displayStatus: string ,
message: string ,
time: string ,
}
,
]
,
statuses:
[
{
code: string ,
level: enum ,
displayStatus: string ,
message: string ,
time: string ,
}
,
]
,
}
,
]
,
vmHealth:
{
status:
{
code: string ,
level: enum ,
displayStatus: string ,
message: string ,
time: string ,
}
,
}
,
bootDiagnostics:
{
consoleScreenshotBlobUri: string ,
serialConsoleLogBlobUri: string ,
status:
{
code: string ,
level: enum ,
displayStatus: string ,
message: string ,
time: string ,
}
,
}
,
assignedHost: string ,
statuses:
[
{
code: string ,
level: enum ,
displayStatus: string ,
message: string ,
time: string ,
}
,
]
,
patchStatus:
{
availablePatchSummary:
{
status: enum ,
assessmentActivityId: string ,
rebootPending: boolean ,
criticalAndSecurityPatchCount: integer ,
otherPatchCount: integer ,
startTime: string ,
lastModifiedTime: string ,
error:
{
details:
[
{
code: string ,
target: string ,
message: string ,
}
,
]
,
innererror:
{
exceptiontype: string ,
errordetail: string ,
}
,
code: string ,
target: string ,
message: string ,
}
,
}
,
lastPatchInstallationSummary:
{
status: enum ,
installationActivityId: string ,
maintenanceWindowExceeded: boolean ,
notSelectedPatchCount: integer ,
excludedPatchCount: integer ,
pendingPatchCount: integer ,
installedPatchCount: integer ,
failedPatchCount: integer ,
startTime: string ,
lastModifiedTime: string ,
error:
{
details:
[
{
code: string ,
target: string ,
message: string ,
}
,
]
,
innererror:
{
exceptiontype: string ,
errordetail: string ,
}
,
code: string ,
target: string ,
message: string ,
}
,
}
,
configurationStatuses:
[
{
code: string ,
level: enum ,
displayStatus: string ,
message: string ,
time: string ,
}
,
]
,
}
,
isVMInStandbyPool: boolean ,
}
,
licenseType: string ,
vmId: string ,
extensionsTimeBudget: string ,
platformFaultDomain: integer ,
scheduledEventsProfile:
{
terminateNotificationProfile:
{
notBeforeTimeout: string ,
enable: boolean ,
}
,
osImageNotificationProfile:
{
notBeforeTimeout: string ,
enable: boolean ,
}
,
}
,
userData: string ,
capacityReservation:
{
capacityReservationGroup:
{
id: string ,
}
,
}
,
applicationProfile:
{
galleryApplications:
[
{
tags: string ,
order: integer ,
packageReferenceId: string ,
configurationReference: string ,
treatFailureAsDeploymentFailure: boolean ,
enableAutomaticUpgrade: boolean ,
}
,
]
,
}
,
timeCreated: string ,
}
,
identity:
{
principalId: string ,
tenantId: string ,
type: enum ,
userAssignedIdentities: object ,
}
,
zones:
[
string ,
]
,
}
,
}

⚐ Response (200)

{
$headers:
{
location: string ,
retry-after: integer ,
}
,
$schema:
{
properties:
{
hardwareProfile:
{
vmSize: enum ,
vmSizeProperties:
{
vCPUsAvailable: integer ,
vCPUsPerCore: integer ,
}
,
}
,
scheduledEventsPolicy:
{
userInitiatedRedeploy:
{
automaticallyApprove: boolean ,
}
,
userInitiatedReboot:
{
automaticallyApprove: boolean ,
}
,
scheduledEventsAdditionalPublishingTargets:
{
eventGridAndResourceGraph:
{
enable: boolean ,
scheduledEventsApiVersion: string ,
}
,
}
,
allInstancesDown:
{
automaticallyApprove: boolean ,
}
,
}
,
storageProfile:
{
imageReference:
{
publisher: string ,
offer: string ,
sku: string ,
version: string ,
exactVersion: string ,
sharedGalleryImageId: string ,
communityGalleryImageId: string ,
}
,
osDisk:
{
osType: enum ,
encryptionSettings:
{
diskEncryptionKey:
{
secretUrl: string ,
sourceVault:
{
id: string ,
}
,
}
,
keyEncryptionKey:
{
keyUrl: string ,
sourceVault:
{
id: string ,
}
,
}
,
enabled: boolean ,
}
,
name: string ,
vhd:
{
uri: string ,
}
,
image:
{
uri: string ,
}
,
caching: enum ,
writeAcceleratorEnabled: boolean ,
diffDiskSettings:
{
option: enum ,
placement: enum ,
}
,
createOption: enum ,
diskSizeGB: integer ,
managedDisk:
{
storageAccountType: enum ,
diskEncryptionSet: object ,
securityProfile:
{
securityEncryptionType: enum ,
diskEncryptionSet: object ,
}
,
}
,
deleteOption: enum ,
}
,
dataDisks:
[
{
lun: integer ,
name: string ,
vhd:
{
uri: string ,
}
,
image:
{
uri: string ,
}
,
caching: enum ,
writeAcceleratorEnabled: boolean ,
createOption: enum ,
diskSizeGB: integer ,
managedDisk:
{
storageAccountType: enum ,
diskEncryptionSet: object ,
securityProfile:
{
securityEncryptionType: enum ,
diskEncryptionSet: object ,
}
,
}
,
sourceResource:
{
id: string ,
}
,
toBeDetached: boolean ,
diskIOPSReadWrite: integer ,
diskMBpsReadWrite: integer ,
detachOption: enum ,
deleteOption: enum ,
}
,
]
,
diskControllerType: enum ,
alignRegionalDisksToVMZone: boolean ,
}
,
additionalCapabilities:
{
ultraSSDEnabled: boolean ,
hibernationEnabled: boolean ,
enableFips1403Encryption: boolean ,
}
,
osProfile:
{
computerName: string ,
adminUsername: string ,
adminPassword: string ,
customData: string ,
windowsConfiguration:
{
provisionVMAgent: boolean ,
enableAutomaticUpdates: boolean ,
timeZone: string ,
additionalUnattendContent:
[
{
passName: enum ,
componentName: enum ,
settingName: enum ,
content: string ,
}
,
]
,
patchSettings:
{
patchMode: enum ,
enableHotpatching: boolean ,
assessmentMode: enum ,
automaticByPlatformSettings:
{
rebootSetting: enum ,
bypassPlatformSafetyChecksOnUserSchedule: boolean ,
}
,
}
,
winRM:
{
listeners:
[
{
protocol: enum ,
certificateUrl: string ,
}
,
]
,
}
,
enableVMAgentPlatformUpdates: boolean ,
}
,
linuxConfiguration:
{
disablePasswordAuthentication: boolean ,
ssh:
{
publicKeys:
[
{
path: string ,
keyData: string ,
}
,
]
,
}
,
provisionVMAgent: boolean ,
patchSettings:
{
patchMode: enum ,
assessmentMode: enum ,
automaticByPlatformSettings:
{
rebootSetting: enum ,
bypassPlatformSafetyChecksOnUserSchedule: boolean ,
}
,
}
,
enableVMAgentPlatformUpdates: boolean ,
}
,
secrets:
[
{
sourceVault:
{
id: string ,
}
,
vaultCertificates:
[
{
certificateUrl: string ,
certificateStore: string ,
}
,
]
,
}
,
]
,
allowExtensionOperations: boolean ,
requireGuestProvisionSignal: boolean ,
}
,
networkProfile:
{
networkInterfaces:
[
{
properties:
{
primary: boolean ,
deleteOption: enum ,
}
,
}
,
]
,
networkApiVersion: enum ,
networkInterfaceConfigurations:
[
{
name: string ,
properties:
{
primary: boolean ,
deleteOption: enum ,
enableAcceleratedNetworking: boolean ,
disableTcpStateTracking: boolean ,
enableFpga: boolean ,
enableIPForwarding: boolean ,
networkSecurityGroup:
{
id: string ,
}
,
dnsSettings:
{
dnsServers:
[
string ,
]
,
}
,
ipConfigurations:
[
{
name: string ,
properties:
{
subnet:
{
id: string ,
}
,
primary: boolean ,
publicIPAddressConfiguration:
{
name: string ,
properties:
{
idleTimeoutInMinutes: integer ,
deleteOption: enum ,
dnsSettings:
{
domainNameLabel: string ,
domainNameLabelScope: enum ,
}
,
ipTags:
[
{
ipTagType: string ,
tag: string ,
}
,
]
,
publicIPPrefix:
{
id: string ,
}
,
publicIPAddressVersion: enum ,
publicIPAllocationMethod: enum ,
}
,
sku:
{
name: enum ,
tier: enum ,
}
,
tags: object ,
}
,
privateIPAddressVersion: enum ,
applicationSecurityGroups:
[
{
id: string ,
}
,
]
,
applicationGatewayBackendAddressPools:
[
{
id: string ,
}
,
]
,
loadBalancerBackendAddressPools:
[
{
id: string ,
}
,
]
,
}
,
}
,
]
,
dscpConfiguration:
{
id: string ,
}
,
auxiliaryMode: enum ,
auxiliarySku: enum ,
}
,
tags: object ,
}
,
]
,
}
,
securityProfile:
{
uefiSettings:
{
secureBootEnabled: boolean ,
vTpmEnabled: boolean ,
}
,
encryptionAtHost: boolean ,
securityType: enum ,
encryptionIdentity:
{
userAssignedIdentityResourceId: string ,
}
,
proxyAgentSettings:
{
enabled: boolean ,
mode: enum ,
keyIncarnationId: integer ,
wireServer:
{
mode: enum ,
inVMAccessControlProfileReferenceId: string ,
}
,
imds:
{
mode: enum ,
inVMAccessControlProfileReferenceId: string ,
}
,
addProxyAgentExtension: boolean ,
}
,
}
,
diagnosticsProfile:
{
bootDiagnostics:
{
enabled: boolean ,
storageUri: string ,
}
,
}
,
availabilitySet:
{
id: string ,
}
,
virtualMachineScaleSet:
{
id: string ,
}
,
proximityPlacementGroup:
{
id: string ,
}
,
priority: enum ,
evictionPolicy: enum ,
billingProfile:
{
maxPrice: number ,
}
,
host:
{
id: string ,
}
,
hostGroup:
{
id: string ,
}
,
provisioningState: string ,
instanceView:
{
platformUpdateDomain: integer ,
platformFaultDomain: integer ,
computerName: string ,
osName: string ,
osVersion: string ,
hyperVGeneration: enum ,
rdpThumbPrint: string ,
vmAgent:
{
vmAgentVersion: string ,
extensionHandlers:
[
{
type: string ,
typeHandlerVersion: string ,
status:
{
code: string ,
level: enum ,
displayStatus: string ,
message: string ,
time: string ,
}
,
}
,
]
,
statuses:
[
{
code: string ,
level: enum ,
displayStatus: string ,
message: string ,
time: string ,
}
,
]
,
}
,
maintenanceRedeployStatus:
{
isCustomerInitiatedMaintenanceAllowed: boolean ,
preMaintenanceWindowStartTime: string ,
preMaintenanceWindowEndTime: string ,
maintenanceWindowStartTime: string ,
maintenanceWindowEndTime: string ,
lastOperationResultCode: enum ,
lastOperationMessage: string ,
}
,
disks:
[
{
name: string ,
encryptionSettings:
[
{
diskEncryptionKey:
{
secretUrl: string ,
sourceVault:
{
id: string ,
}
,
}
,
keyEncryptionKey:
{
keyUrl: string ,
sourceVault:
{
id: string ,
}
,
}
,
enabled: boolean ,
}
,
]
,
statuses:
[
{
code: string ,
level: enum ,
displayStatus: string ,
message: string ,
time: string ,
}
,
]
,
}
,
]
,
extensions:
[
{
name: string ,
type: string ,
typeHandlerVersion: string ,
substatuses:
[
{
code: string ,
level: enum ,
displayStatus: string ,
message: string ,
time: string ,
}
,
]
,
statuses:
[
{
code: string ,
level: enum ,
displayStatus: string ,
message: string ,
time: string ,
}
,
]
,
}
,
]
,
vmHealth:
{
status:
{
code: string ,
level: enum ,
displayStatus: string ,
message: string ,
time: string ,
}
,
}
,
bootDiagnostics:
{
consoleScreenshotBlobUri: string ,
serialConsoleLogBlobUri: string ,
status:
{
code: string ,
level: enum ,
displayStatus: string ,
message: string ,
time: string ,
}
,
}
,
assignedHost: string ,
statuses:
[
{
code: string ,
level: enum ,
displayStatus: string ,
message: string ,
time: string ,
}
,
]
,
patchStatus:
{
availablePatchSummary:
{
status: enum ,
assessmentActivityId: string ,
rebootPending: boolean ,
criticalAndSecurityPatchCount: integer ,
otherPatchCount: integer ,
startTime: string ,
lastModifiedTime: string ,
error:
{
details:
[
{
code: string ,
target: string ,
message: string ,
}
,
]
,
innererror:
{
exceptiontype: string ,
errordetail: string ,
}
,
code: string ,
target: string ,
message: string ,
}
,
}
,
lastPatchInstallationSummary:
{
status: enum ,
installationActivityId: string ,
maintenanceWindowExceeded: boolean ,
notSelectedPatchCount: integer ,
excludedPatchCount: integer ,
pendingPatchCount: integer ,
installedPatchCount: integer ,
failedPatchCount: integer ,
startTime: string ,
lastModifiedTime: string ,
error:
{
details:
[
{
code: string ,
target: string ,
message: string ,
}
,
]
,
innererror:
{
exceptiontype: string ,
errordetail: string ,
}
,
code: string ,
target: string ,
message: string ,
}
,
}
,
configurationStatuses:
[
{
code: string ,
level: enum ,
displayStatus: string ,
message: string ,
time: string ,
}
,
]
,
}
,
isVMInStandbyPool: boolean ,
}
,
licenseType: string ,
vmId: string ,
extensionsTimeBudget: string ,
platformFaultDomain: integer ,
scheduledEventsProfile:
{
terminateNotificationProfile:
{
notBeforeTimeout: string ,
enable: boolean ,
}
,
osImageNotificationProfile:
{
notBeforeTimeout: string ,
enable: boolean ,
}
,
}
,
userData: string ,
capacityReservation:
{
capacityReservationGroup:
{
id: string ,
}
,
}
,
applicationProfile:
{
galleryApplications:
[
{
tags: string ,
order: integer ,
packageReferenceId: string ,
configurationReference: string ,
treatFailureAsDeploymentFailure: boolean ,
enableAutomaticUpgrade: boolean ,
}
,
]
,
}
,
timeCreated: string ,
}
,
plan:
{
name: string ,
publisher: string ,
product: string ,
promotionCode: string ,
}
,
resources:
[
{
properties:
{
forceUpdateTag: string ,
publisher: string ,
type: string ,
typeHandlerVersion: string ,
autoUpgradeMinorVersion: boolean ,
enableAutomaticUpgrade: boolean ,
settings: string ,
protectedSettings: string ,
provisioningState: string ,
instanceView:
{
name: string ,
type: string ,
typeHandlerVersion: string ,
substatuses:
[
{
code: string ,
level: enum ,
displayStatus: string ,
message: string ,
time: string ,
}
,
]
,
statuses:
[
{
code: string ,
level: enum ,
displayStatus: string ,
message: string ,
time: string ,
}
,
]
,
}
,
suppressFailures: boolean ,
protectedSettingsFromKeyVault:
{
secretUrl: string ,
sourceVault:
{
id: string ,
}
,
}
,
provisionAfterExtensions:
[
string ,
]
,
}
,
}
,
]
,
identity:
{
principalId: string ,
tenantId: string ,
type: enum ,
userAssignedIdentities: object ,
}
,
zones:
[
string ,
]
,
extendedLocation:
{
name: string ,
type: enum ,
}
,
managedBy: string ,
etag: string ,
placement:
{
zonePlacementPolicy: enum ,
includeZones:
[
string ,
]
,
excludeZones:
[
string ,
]
,
}
,
}
,
}

⚐ Response (default)

{
error:
{
details:
[
{
code: string ,
target: string ,
message: string ,
}
,
]
,
innererror:
{
exceptiontype: string ,
errordetail: string ,
}
,
code: string ,
target: string ,
message: string ,
}
,
}
VirtualMachines_AttachDetachDataDisks (updated)
Description Attach and detach data disks to/from the virtual machine.
Reference Link ¶

⚶ Changes

{
  "#id": "VirtualMachines_AttachDetachDataDisks",
  "$responses": {
    "200": {
      "$properties": {
        "dataDisks": {
          "$properties": [
            {
              "#name": "diskIOPSReadWrite",
              "Description": {
                "new": "Specifies the Read-Write IOPS for the managed disk when StorageAccountType is UltraSSD_LRS.",
                "old": "Specifies the Read-Write IOPS for the managed disk when StorageAccountType is UltraSSD_LRS. Returned only for VirtualMachine ScaleSet VM disks. Can be updated only via updates to the VirtualMachine Scale Set."
              }
            },
            {
              "#name": "diskMBpsReadWrite",
              "Description": {
                "new": "Specifies the bandwidth in MB per second for the managed disk when StorageAccountType is UltraSSD_LRS.",
                "old": "Specifies the bandwidth in MB per second for the managed disk when StorageAccountType is UltraSSD_LRS. Returned only for VirtualMachine ScaleSet VM disks. Can be updated only via updates to the VirtualMachine Scale Set."
              }
            }
          ]
        }
      }
    }
  }
}

⚼ Request

POST:  /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Compute/virtualMachines/{vmName}/attachDetachDataDisks
{
api-version: string ,
subscriptionId: string ,
resourceGroupName: string ,
vmName: string ,
parameters:
{
dataDisksToAttach:
[
{
diskId: string ,
lun: integer ,
caching: enum ,
deleteOption: enum ,
diskEncryptionSet: object ,
writeAcceleratorEnabled: boolean ,
}
,
]
,
dataDisksToDetach:
[
{
diskId: string ,
detachOption: enum ,
}
,
]
,
}
,
}

⚐ Response (200)

{
imageReference:
{
publisher: string ,
offer: string ,
sku: string ,
version: string ,
exactVersion: string ,
sharedGalleryImageId: string ,
communityGalleryImageId: string ,
}
,
osDisk:
{
osType: enum ,
encryptionSettings:
{
diskEncryptionKey:
{
secretUrl: string ,
sourceVault:
{
id: string ,
}
,
}
,
keyEncryptionKey:
{
keyUrl: string ,
sourceVault:
{
id: string ,
}
,
}
,
enabled: boolean ,
}
,
name: string ,
vhd:
{
uri: string ,
}
,
image:
{
uri: string ,
}
,
caching: enum ,
writeAcceleratorEnabled: boolean ,
diffDiskSettings:
{
option: enum ,
placement: enum ,
}
,
createOption: enum ,
diskSizeGB: integer ,
managedDisk:
{
storageAccountType: enum ,
diskEncryptionSet: object ,
securityProfile:
{
securityEncryptionType: enum ,
diskEncryptionSet: object ,
}
,
}
,
deleteOption: enum ,
}
,
dataDisks:
[
{
lun: integer ,
name: string ,
vhd:
{
uri: string ,
}
,
image:
{
uri: string ,
}
,
caching: enum ,
writeAcceleratorEnabled: boolean ,
createOption: enum ,
diskSizeGB: integer ,
managedDisk:
{
storageAccountType: enum ,
diskEncryptionSet: object ,
securityProfile:
{
securityEncryptionType: enum ,
diskEncryptionSet: object ,
}
,
}
,
sourceResource:
{
id: string ,
}
,
toBeDetached: boolean ,
diskIOPSReadWrite: integer ,
diskMBpsReadWrite: integer ,
detachOption: enum ,
deleteOption: enum ,
}
,
]
,
diskControllerType: enum ,
alignRegionalDisksToVMZone: boolean ,
}

⚐ Response (202)

{
location: string ,
retry-after: integer ,
}

⚐ Response (default)

{
error:
{
details:
[
{
code: string ,
target: string ,
message: string ,
}
,
]
,
innererror:
{
exceptiontype: string ,
errordetail: string ,
}
,
code: string ,
target: string ,
message: string ,
}
,
}