{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://artifacts.apis.io/microsoft-azure-virtual-machines/json-schema/microsoft-azure-virtual-machines-virtual-machine-scale-set-vm-schema.json",
  "title": "VirtualMachineScaleSetVM",
  "description": "Describes a virtual machine scale set virtual machine.",
  "x-generated": "2026-11-04",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/microsoft-azure-virtual-machines-compute-openapi.yml#/components/schemas/VirtualMachineScaleSetVM",
  "type": "object",
  "properties": {
    "properties": {
      "$ref": "#/$defs/VirtualMachineScaleSetVMProperties"
    },
    "instanceId": {
      "type": "string",
      "description": "The virtual machine instance ID.",
      "readOnly": true
    },
    "sku": {
      "$ref": "#/$defs/Sku"
    },
    "plan": {
      "$ref": "#/$defs/Plan"
    },
    "resources": {
      "type": "array",
      "description": "The virtual machine child extension resources.",
      "items": {
        "$ref": "#/$defs/VirtualMachineExtension"
      },
      "readOnly": true
    },
    "zones": {
      "type": "array",
      "description": "The virtual machine zones.",
      "items": {
        "type": "string"
      },
      "readOnly": true
    },
    "identity": {
      "$ref": "#/$defs/VirtualMachineIdentity"
    },
    "etag": {
      "type": "string",
      "description": "Etag is property returned in Update/Get response of the VMSS VM, so that customer can supply it in the header to ensure optimistic updates.",
      "readOnly": true
    }
  },
  "allOf": [
    {
      "$ref": "../../../../../../common-types/resource-management/v3/types.json#/definitions/TrackedResource"
    }
  ],
  "$defs": {
    "AdditionalCapabilities": {
      "type": "object",
      "description": "Enables or disables a capability on the virtual machine or virtual machine scale set.",
      "properties": {
        "ultraSSDEnabled": {
          "type": "boolean",
          "description": "The flag that enables or disables a capability to have one or more managed data disks with UltraSSD_LRS storage account type on the VM or VMSS. Managed disks with storage account type UltraSSD_LRS can be added to a virtual machine or virtual machine scale set only if this property is enabled."
        },
        "hibernationEnabled": {
          "type": "boolean",
          "description": "The flag that enables or disables hibernation capability on the VM."
        },
        "enableFips1403Encryption": {
          "type": "boolean",
          "description": "The flag enables the usage of FIPS 140-3 compliant cryptography on the protectedSettings of an extension. Learn more at: https://aka.ms/linuxagentfipssupport."
        }
      }
    },
    "AdditionalDiskProperties": {
      "type": "object",
      "description": "Specifies additional properties for a managed disk that can be set at the time of implicit creation of the disk.",
      "properties": {
        "managedDiskProperties": {
          "$ref": "#/$defs/ManagedDiskProperties"
        }
      }
    },
    "AdditionalUnattendContent": {
      "type": "object",
      "description": "Specifies additional XML formatted information that can be included in the Unattend.xml file, which is used by Windows Setup. Contents are defined by setting name, component name, and the pass in which the content is applied.",
      "properties": {
        "passName": {
          "$ref": "#/$defs/PassNames"
        },
        "componentName": {
          "$ref": "#/$defs/ComponentNames"
        },
        "settingName": {
          "$ref": "#/$defs/SettingNames"
        },
        "content": {
          "type": "string",
          "description": "Specifies the XML formatted content that is added to the unattend.xml file for the specified path and component. The XML must be less than 4KB and must include the root element for the setting or feature that is being inserted."
        }
      }
    },
    "ApiEntityReference": {
      "type": "object",
      "description": "The API entity reference.",
      "properties": {
        "id": {
          "type": "string",
          "description": "The ARM resource id in the form of /subscriptions/{SubscriptionId}/resourceGroups/{ResourceGroupName}/..."
        }
      }
    },
    "AvailabilityPolicyDiskDelay": {
      "type": "string",
      "description": "Determines how to handle disks with slow I/O.",
      "enum": [
        "None",
        "AutomaticReattach"
      ],
      "x-ms-enum": {
        "name": "AvailabilityPolicyDiskDelay",
        "modelAsString": true,
        "values": [
          {
            "name": "None",
            "value": "None",
            "description": "Defaults to behavior without availability policy specified, which is VM restart upon slow disk I/O."
          },
          {
            "name": "AutomaticReattach",
            "value": "AutomaticReattach",
            "description": "Upon a disk I/O failure or slow response, try detaching then reattaching the disk."
          }
        ]
      }
    },
    "BootDiagnostics": {
      "type": "object",
      "description": "Boot Diagnostics is a debugging feature which allows you to view Console Output and Screenshot to diagnose VM status. You can easily view the output of your console log. Azure also enables you to see a screenshot of the VM from the hypervisor.",
      "properties": {
        "enabled": {
          "type": "boolean",
          "description": "Whether boot diagnostics should be enabled on the Virtual Machine."
        },
        "storageUri": {
          "type": "string",
          "description": "Uri of the storage account to use for placing the console output and screenshot. If storageUri is not specified while enabling boot diagnostics, managed storage will be used."
        }
      }
    },
    "BootDiagnosticsInstanceView": {
      "type": "object",
      "description": "The instance view of a virtual machine boot diagnostics.",
      "properties": {
        "consoleScreenshotBlobUri": {
          "type": "string",
          "description": "The console screenshot blob URI. **Note:** This will **not** be set if boot diagnostics is currently enabled with managed storage.",
          "readOnly": true
        },
        "serialConsoleLogBlobUri": {
          "type": "string",
          "description": "The serial console log blob Uri. **Note:** This will **not** be set if boot diagnostics is currently enabled with managed storage.",
          "readOnly": true
        },
        "status": {
          "$ref": "#/$defs/InstanceViewStatus"
        }
      }
    },
    "CachingTypes": {
      "type": "string",
      "description": "Specifies the caching requirements. Possible values are: **None,** **ReadOnly,** **ReadWrite.** The default values are: **None for Standard storage. ReadOnly for Premium storage**",
      "enum": [
        "None",
        "ReadOnly",
        "ReadWrite"
      ],
      "x-ms-enum": {
        "name": "CachingTypes",
        "modelAsString": false
      }
    },
    "CapacityReservationProfile": {
      "type": "object",
      "description": "The parameters of a capacity reservation Profile.",
      "properties": {
        "capacityReservationGroup": {
          "$ref": "../../common-types/v1/common.json#/definitions/SubResource"
        },
        "disableCapacityReservationAssignment": {
          "type": "boolean",
          "description": "Specifies whether the virtual machine is explicitly opted out from being associated with any capacity reservation. When set to true, the virtual machine will not be allowed to implicitly or explicitly associate with any type of capacity reservation and will consume capacity from the publicly available capacity. Minimum api-version: 2026-04-01."
        }
      }
    },
    "CapacityReservationType": {
      "type": "string",
      "description": "Specifies which type of capacity reservation the virtual machine will consume capacity from if eligible or whether it is explicitly opted out from being associated and consuming capacity from any reserved capacity available in the subscription. Minimum api-version: 2026-04-01.",
      "enum": [
        "NotEligible",
        "Targeted",
        "Open",
        "Disabled",
        "Block"
      ],
      "x-ms-enum": {
        "name": "CapacityReservationType",
        "modelAsString": true,
        "values": [
          {
            "name": "NotEligible",
            "value": "NotEligible",
            "description": "The virtual machine is not eligible to be implicitly associated with an open capacity reservation and is not explicitly associated with any capacity reservation group, so it will consume capacity from the publicly available capacity."
          },
          {
            "name": "Targeted",
            "value": "Targeted",
            "description": "The virtual machine will consume capacity from a specific matching capacity reservation when associated with a capacity reservation group resource of type targeted, but can fall back to consume capacity from the publicly available capacity if there is no capacity available in the targeted reservation."
          },
          {
            "name": "Open",
            "value": "Open",
            "description": "The virtual machine if eligible will implicitly associate and consume any available capacity from a matching open capacity reservation created or shared in the subscription. **Note:** The VM should not be explicitly associated with the open capacity reservation group resource containing the matching reservation."
          },
          {
            "name": "Disabled",
            "value": "Disabled",
            "description": "The virtual machine has capacity reservation assignment disabled and will not be allowed to implicitly or explicitly associate with any type of capacity reservation."
          },
          {
            "name": "Block",
            "value": "Block",
            "description": "The virtual machine consumes capacity from a specific matching capacity reservation when associated with a capacity reservation group resource of type block, and will hit capacity failures if there is no available capacity in the block reservation."
          }
        ]
      }
    },
    "Common.HyperVGeneration": {
      "type": "string",
      "description": "The hypervisor generation of the Virtual Machine.",
      "enum": [
        "V1",
        "V2"
      ],
      "x-ms-enum": {
        "name": "HyperVGeneration",
        "modelAsString": true,
        "values": [
          {
            "name": "V1",
            "value": "V1"
          },
          {
            "name": "V2",
            "value": "V2"
          }
        ]
      }
    },
    "Common.OperatingSystemTypes": {
      "type": "string",
      "description": "This property allows you to specify the type of the OS that is included in the disk if creating a VM from user-image or a specialized VHD. Possible values are: **Windows,** **Linux.**",
      "enum": [
        "Windows",
        "Linux"
      ],
      "x-ms-enum": {
        "name": "OperatingSystemTypes",
        "modelAsString": false
      }
    },
    "Common.ResourceIdentityType": {
      "type": "string",
      "description": "The type of identity used for the virtual machine scale set. The type 'SystemAssigned, UserAssigned' includes both an implicitly created identity and a set of user assigned identities. The type 'None' will remove any identities from the virtual machine scale set.",
      "enum": [
        "SystemAssigned",
        "UserAssigned",
        "SystemAssigned, UserAssigned",
        "None"
      ],
      "x-ms-enum": {
        "name": "ResourceIdentityType",
        "modelAsString": false
      }
    },
    "Common.UserAssignedIdentitiesValue": {
      "type": "object",
      "properties": {
        "principalId": {
          "type": "string",
          "description": "The principal id of user assigned identity.",
          "readOnly": true
        },
        "clientId": {
          "type": "string",
          "description": "The client id of user assigned identity.",
          "readOnly": true
        }
      }
    },
    "ComponentNames": {
      "type": "string",
      "enum": [
        "Microsoft-Windows-Shell-Setup"
      ],
      "x-ms-enum": {
        "modelAsString": false
      },
      "nullable": false
    },
    "DataDisk": {
      "type": "object",
      "description": "Describes a data disk.",
      "properties": {
        "lun": {
          "type": "integer",
          "format": "int32",
          "description": "Specifies the logical unit number of the data disk. This value is used to identify data disks within the VM and therefore must be unique for each data disk attached to a VM."
        },
        "name": {
          "type": "string",
          "description": "The disk name."
        },
        "vhd": {
          "$ref": "#/$defs/VirtualHardDisk"
        },
        "image": {
          "$ref": "#/$defs/VirtualHardDisk"
        },
        "caching": {
          "$ref": "#/$defs/CachingTypes"
        },
        "writeAcceleratorEnabled": {
          "type": "boolean",
          "description": "Specifies whether writeAccelerator should be enabled or disabled on the disk."
        },
        "createOption": {
          "$ref": "#/$defs/DiskCreateOptionTypes"
        },
        "diskSizeGB": {
          "type": "integer",
          "format": "int32",
          "description": "Specifies the size of an empty data disk in gigabytes. This element can be used to overwrite the size of the disk in a virtual machine image. The property 'diskSizeGB' is the number of bytes x 1024^3 for the disk and the value cannot be larger than 1023."
        },
        "storageFaultDomainAlignment": {
          "$ref": "#/$defs/StorageFaultDomainAlignmentType"
        },
        "managedDisk": {
          "$ref": "#/$defs/ManagedDiskParameters"
        },
        "sourceResource": {
          "$ref": "#/$defs/ApiEntityReference"
        },
        "toBeDetached": {
          "type": "boolean",
          "description": "Specifies whether the data disk is in process of detachment from the VirtualMachine/VirtualMachineScaleset"
        },
        "diskIOPSReadWrite": {
          "type": "integer",
          "format": "int64",
          "description": "Specifies the Read-Write IOPS for the managed disk when StorageAccountType is UltraSSD_LRS."
        },
        "diskMBpsReadWrite": {
          "type": "integer",
          "format": "int64",
          "description": "Specifies the bandwidth in MB per second for the managed disk when StorageAccountType is UltraSSD_LRS."
        },
        "detachOption": {
          "$ref": "#/$defs/DiskDetachOptionTypes"
        },
        "deleteOption": {
          "$ref": "#/$defs/DiskDeleteOptionTypes"
        }
      },
      "required": [
        "lun",
        "createOption"
      ]
    },
    "DeleteOptions": {
      "type": "string",
      "description": "Specify what happens to the network interface when the VM is deleted",
      "enum": [
        "Delete",
        "Detach"
      ],
      "x-ms-enum": {
        "name": "DeleteOptions",
        "modelAsString": true,
        "values": [
          {
            "name": "Delete",
            "value": "Delete"
          },
          {
            "name": "Detach",
            "value": "Detach"
          }
        ]
      }
    },
    "DiagnosticsProfile": {
      "type": "object",
      "description": "Specifies the boot diagnostic settings state. Minimum api-version: 2015-06-15.",
      "properties": {
        "bootDiagnostics": {
          "$ref": "#/$defs/BootDiagnostics"
        }
      }
    },
    "DiffDiskOptions": {
      "type": "string",
      "description": "Specifies the ephemeral disk option for operating system disk.",
      "enum": [
        "Local"
      ],
      "x-ms-enum": {
        "name": "DiffDiskOptions",
        "modelAsString": true,
        "values": [
          {
            "name": "Local",
            "value": "Local"
          }
        ]
      }
    },
    "DiffDiskPlacement": {
      "type": "string",
      "description": "Specifies the ephemeral disk placement for operating system disk. This property can be used by user in the request to choose the location i.e, cache disk, resource disk or nvme disk space for Ephemeral OS disk provisioning. For more information on Ephemeral OS disk size requirements, please refer Ephemeral OS disk size requirements for Windows VM at https://docs.microsoft.com/azure/virtual-machines/windows/ephemeral-os-disks#size-requirements and Linux VM at https://docs.microsoft.com/azure/virtual-machines/linux/ephemeral-os-disks#size-requirements. Minimum api-version for NvmeDisk: 2024-03-01.",
      "enum": [
        "CacheDisk",
        "ResourceDisk",
        "NvmeDisk"
      ],
      "x-ms-enum": {
        "name": "DiffDiskPlacement",
        "modelAsString": true,
        "values": [
          {
            "name": "CacheDisk",
            "value": "CacheDisk"
          },
          {
            "name": "ResourceDisk",
            "value": "ResourceDisk"
          },
          {
            "name": "NvmeDisk",
            "value": "NvmeDisk"
          }
        ]
      }
    },
    "DiffDiskSettings": {
      "type": "object",
      "description": "Describes the parameters of ephemeral disk settings that can be specified for operating system disk. **Note:** The ephemeral disk settings can only be specified for managed disk.",
      "properties": {
        "option": {
          "$ref": "#/$defs/DiffDiskOptions"
        },
        "placement": {
          "$ref": "#/$defs/DiffDiskPlacement"
        },
        "enableFullCaching": {
          "type": "boolean",
          "description": "Specifies whether or not to enable full caching for this VM which will cache the OS disk locally on the host and make this VM more resilient to storage outages"
        }
      }
    },
    "DiskApiVersion": {
      "type": "string",
      "description": "Specifies the Disk API version used when applying additionalDiskProperties to managed disks. The value must be in the format YYYY-MM-DD.",
      "enum": [
        