Software Update Configurations - List

Get all software update configurations for the account.

GET https://management.azure.com/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Automation/automationAccounts/{automationAccountName}/softwareUpdateConfigurations?api-version=2019-06-01
GET https://management.azure.com/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Automation/automationAccounts/{automationAccountName}/softwareUpdateConfigurations?api-version=2019-06-01&$filter={$filter}

URI Parameters

Name In Required Type Description
automationAccountName
path True

string

The name of the automation account.

resourceGroupName
path True

string

Name of an Azure Resource group.

Regex pattern: ^[-\w\._]+$

subscriptionId
path True

string

Gets subscription credentials which uniquely identify Microsoft Azure subscription. The subscription ID forms part of the URI for every service call.

api-version
query True

string

Client Api Version.

$filter
query

string

The filter to apply on the operation.

Request Header

Name Required Type Description
clientRequestId

string

Identifies this specific client request.

Responses

Name Type Description
200 OK

softwareUpdateConfigurationListResult

Return list of software update configurations.

Other Status Codes

ErrorResponse

Automation error response describing why the operation failed.

Security

azure_auth

Azure Active Directory OAuth2 Flow

Type: oauth2
Flow: implicit
Authorization URL: https://login.microsoftonline.com/common/oauth2/authorize

Scopes

Name Description
user_impersonation impersonate your user account

Examples

List software update configurations
List software update configurations Targeting a specific azure virtual machine

List software update configurations

Sample request

GET https://management.azure.com/subscriptions/1a7d4044-286c-4acb-969a-96639265bf2e/resourceGroups/mygroup/providers/Microsoft.Automation/automationAccounts/myaccount/softwareUpdateConfigurations?api-version=2019-06-01

Sample response

{
  "value": [
    {
      "name": "testpatch-01",
      "id": "/subscriptions/1a7d4044-286c-4acb-969a-96639265bf2e/resourceGroups/Mo-Resources-WCUS/providers/Microsoft.Automation/automationAccounts/Mo-AAA-WCUS/softwareUpdateConfigurations/testpatch-01",
      "properties": {
        "updateConfiguration": {
          "operatingSystem": "Windows",
          "windows": {
            "includedUpdateClassifications": "Critical, Security, UpdateRollup, FeaturePack, ServicePack, Definition, Tools, Updates",
            "excludedKbNumbers": null
          },
          "linux": null,
          "targets": {
            "azureQueries": [
              {
                "scope": [
                  "/subscriptions/422b6c61-95b0-4213-b3be-7282315df71d/resourceGroups/a-stasku-rg0",
                  "/subscriptions/422b6c61-95b0-4213-b3be-7282315df71d"
                ],
                "tagSettings": {
                  "tags": {
                    "tag1": [
                      "tag1Value1",
                      "tag1Value2"
                    ],
                    "tag2": [
                      "tag2Value1",
                      "tag2Value2"
                    ]
                  },
                  "filterOperator": "All"
                },
                "locations": null
              }
            ]
          },
          "duration": "PT2H",
          "azureVirtualMachines": [
            "/subscriptions/1a7d4044-286c-4acb-969a-96639265bf2e/resourceGroups/myresources/providers/Microsoft.Compute/virtualMachines/vm-01",
            "/subscriptions/1a7d4044-286c-4acb-969a-96639265bf2e/resourceGroups/myresources/providers/Microsoft.Compute/virtualMachines/vm-02",
            "/subscriptions/1a7d4044-286c-4acb-969a-96639265bf2e/resourceGroups/myresources/providers/Microsoft.Compute/virtualMachines/vm-03"
          ],
          "nonAzureComputerNames": null
        },
        "tasks": {
          "preTask": {
            "source": "HelloWorld",
            "parameters": {
              "COMPUTERNAME": "Computer1"
            }
          },
          "postTask": {
            "source": "GetCache",
            "parameters": null
          }
        },
        "frequency": "Week",
        "startTime": "2017-10-19T12:22:00-07:00",
        "creationTime": "2017-10-19T18:54:50.5233333+00:00",
        "lastModifiedTime": "2017-10-19T18:54:50.68+00:00",
        "provisioningState": "Succeeded",
        "nextRun": "2017-10-23T12:22:00-07:00"
      }
    },
    {
      "name": "testpatch-02",
      "id": "/subscriptions/1a7d4044-286c-4acb-969a-96639265bf2e/resourceGroups/Mo-Resources-WCUS/providers/Microsoft.Automation/automationAccounts/Mo-AAA-WCUS/softwareUpdateConfigurations/testpatch-02",
      "properties": {
        "updateConfiguration": {
          "operatingSystem": "Windows",
          "windows": {
            "includedUpdateClassifications": "Critical, FeaturePack",
            "excludedKbNumbers": null
          },
          "linux": null,
          "targets": {
            "azureQueries": [
              {
                "scope": [
                  "/subscriptions/422b6c61-95b0-4213-b3be-7282315df71d/resourceGroups/a-stasku-rg0",
                  "/subscriptions/422b6c61-95b0-4213-b3be-7282315df71d"
                ],
                "tagSettings": {
                  "tags": {
                    "tag1": [
                      "tag1Value1",
                      "tag1Value2"
                    ],
                    "tag2": [
                      "tag2Value1",
                      "tag2Value2"
                    ]
                  },
                  "filterOperator": "All"
                },
                "locations": [
                  "Japan East",
                  "UK South"
                ]
              }
            ]
          },
          "duration": "PT2H30M",
          "azureVirtualMachines": [
            "/subscriptions/1a7d4044-286c-4acb-969a-96639265bf2e/resourceGroups/myresources/providers/Microsoft.Compute/virtualMachines/vm-04",
            "/subscriptions/1a7d4044-286c-4acb-969a-96639265bf2e/resourceGroups/myresources/providers/Microsoft.Compute/virtualMachines/vm-05",
            "/subscriptions/1a7d4044-286c-4acb-969a-96639265bf2e/resourceGroups/myresources/providers/Microsoft.Compute/virtualMachines/vm-06"
          ],
          "nonAzureComputerNames": null
        },
        "tasks": {
          "preTask": {
            "source": "HelloWorld",
            "parameters": {
              "COMPUTERNAME": "Computer1"
            }
          },
          "postTask": {
            "source": "GetCache",
            "parameters": null
          }
        },
        "frequency": "Hour",
        "startTime": "2018-05-05T12:26:00-07:00",
        "creationTime": "2017-08-11T21:52:02.7733333+00:00",
        "lastModifiedTime": "2017-08-11T21:52:22.88+00:00",
        "provisioningState": "Succeeded",
        "nextRun": "2018-05-05T12:26:00-07:00"
      }
    }
  ]
}

List software update configurations Targeting a specific azure virtual machine

Sample request

GET https://management.azure.com/subscriptions/1a7d4044-286c-4acb-969a-96639265bf2e/resourceGroups/mygroup/providers/Microsoft.Automation/automationAccounts/myaccount/softwareUpdateConfigurations?api-version=2019-06-01&$filter=properties/updateConfiguration/azureVirtualMachines/any(m: m eq '/subscriptions/1a7d4044-286c-4acb-969a-96639265bf2e/resourceGroups/myresources/providers/Microsoft.Compute/virtualMachines/vm-01')

Sample response

{
  "value": [
    {
      "name": "testpatch-01",
      "id": "/subscriptions/1a7d4044-286c-4acb-969a-96639265bf2e/resourceGroups/Mo-Resources-WCUS/providers/Microsoft.Automation/automationAccounts/Mo-AAA-WCUS/softwareUpdateConfigurations/testpatch-01",
      "properties": {
        "updateConfiguration": {
          "operatingSystem": "Windows",
          "windows": {
            "includedUpdateClassifications": "Critical, Security, UpdateRollup, FeaturePack, ServicePack, Definition, Tools, Updates",
            "excludedKbNumbers": null
          },
          "linux": null,
          "duration": "PT2H",
          "azureVirtualMachines": [
            "/subscriptions/1a7d4044-286c-4acb-969a-96639265bf2e/resourceGroups/myresources/providers/Microsoft.Compute/virtualMachines/vm-01",
            "/subscriptions/1a7d4044-286c-4acb-969a-96639265bf2e/resourceGroups/myresources/providers/Microsoft.Compute/virtualMachines/vm-02",
            "/subscriptions/1a7d4044-286c-4acb-969a-96639265bf2e/resourceGroups/myresources/providers/Microsoft.Compute/virtualMachines/vm-03"
          ],
          "nonAzureComputerNames": null
        },
        "tasks": {
          "preTask": {
            "source": "HelloWorld",
            "parameters": {
              "COMPUTERNAME": "Computer1"
            }
          },
          "postTask": {
            "source": "GetCache",
            "parameters": null
          }
        },
        "frequency": "Week",
        "startTime": "2017-10-19T12:22:00-07:00",
        "creationTime": "2017-10-19T18:54:50.5233333+00:00",
        "lastModifiedTime": "2017-10-19T18:54:50.68+00:00",
        "provisioningState": "Succeeded",
        "nextRun": "2017-10-23T12:22:00-07:00"
      }
    },
    {
      "name": "testpatch-02",
      "id": "/subscriptions/1a7d4044-286c-4acb-969a-96639265bf2e/resourceGroups/Mo-Resources-WCUS/providers/Microsoft.Automation/automationAccounts/Mo-AAA-WCUS/softwareUpdateConfigurations/testpatch-02",
      "properties": {
        "updateConfiguration": {
          "operatingSystem": "Windows",
          "windows": {
            "includedUpdateClassifications": "Critical, FeaturePack",
            "excludedKbNumbers": null
          },
          "linux": null,
          "duration": "PT2H30M",
          "azureVirtualMachines": [
            "/subscriptions/1a7d4044-286c-4acb-969a-96639265bf2e/resourceGroups/myresources/providers/Microsoft.Compute/virtualMachines/vm-01",
            "/subscriptions/1a7d4044-286c-4acb-969a-96639265bf2e/resourceGroups/myresources/providers/Microsoft.Compute/virtualMachines/vm-05",
            "/subscriptions/1a7d4044-286c-4acb-969a-96639265bf2e/resourceGroups/myresources/providers/Microsoft.Compute/virtualMachines/vm-06"
          ],
          "nonAzureComputerNames": null
        },
        "tasks": {
          "preTask": {
            "source": "HelloWorld",
            "parameters": {
              "COMPUTERNAME": "Computer1"
            }
          },
          "postTask": {
            "source": "GetCache",
            "parameters": null
          }
        },
        "frequency": "Hour",
        "startTime": "2018-05-05T12:26:00-07:00",
        "creationTime": "2017-08-11T21:52:02.7733333+00:00",
        "lastModifiedTime": "2017-08-11T21:52:22.88+00:00",
        "provisioningState": "Succeeded",
        "nextRun": "2018-05-05T12:26:00-07:00"
      }
    }
  ]
}

Definitions

Name Description
AzureQueryProperties

Azure query for the update configuration.

ErrorResponse

Error response of an operation failure

LinuxProperties

Linux specific update configuration.

LinuxUpdateClasses

Update classifications included in the software update configuration.

NonAzureQueryProperties

Non Azure query for the update configuration.

OperatingSystemType

operating system of target machines

ScheduleFrequency

Gets or sets the frequency of the schedule.

softwareUpdateConfigurationCollectionItem

Software update configuration collection item properties.

softwareUpdateConfigurationListResult

result of listing all software update configuration

softwareUpdateConfigurationTasks

Task properties of the software update configuration.

TagOperators

Filter VMs by Any or All specified tags.

TagSettingsProperties

Tag filter information for the VM.

TargetProperties

Group specific to the update configuration.

taskProperties

Task properties of the software update configuration.

updateConfiguration

Update specific properties of the software update configuration.

WindowsProperties

Windows specific update configuration.

WindowsUpdateClasses

Update classification included in the software update configuration. A comma separated string with required values

AzureQueryProperties

Azure query for the update configuration.

Name Type Description
locations

string[]

List of locations to scope the query to.

scope

string[]

List of Subscription or Resource Group ARM Ids.

tagSettings

TagSettingsProperties

Tag settings for the VM.

ErrorResponse

Error response of an operation failure

Name Type Description
code

string

Error code

message

string

Error message indicating why the operation failed.

LinuxProperties

Linux specific update configuration.

Name Type Description
excludedPackageNameMasks

string[]

packages excluded from the software update configuration.

includedPackageClassifications

LinuxUpdateClasses

Update classifications included in the software update configuration.

includedPackageNameMasks

string[]

packages included from the software update configuration.

rebootSetting

string

Reboot setting for the software update configuration.

LinuxUpdateClasses

Update classifications included in the software update configuration.

Name Type Description
Critical

string

Other

string

Security

string

Unclassified

string

NonAzureQueryProperties

Non Azure query for the update configuration.

Name Type Description
functionAlias

string

Log Analytics Saved Search name.

workspaceId

string

Workspace Id for Log Analytics in which the saved Search is resided.

OperatingSystemType

operating system of target machines

Name Type Description
Linux

string

Windows

string

ScheduleFrequency

Gets or sets the frequency of the schedule.

Name Type Description
Day

string

Hour

string

Minute

string

The minimum allowed interval for Minute schedules is 15 minutes.

Month

string

OneTime

string

Week

string

softwareUpdateConfigurationCollectionItem

Software update configuration collection item properties.

Name Type Description
id

string

Resource Id of the software update configuration

name

string

Name of the software update configuration.

properties.creationTime

string

Creation time of the software update configuration, which only appears in the response.

properties.frequency

ScheduleFrequency

execution frequency of the schedule associated with the software update configuration

properties.lastModifiedTime

string

Last time software update configuration was modified, which only appears in the response.

properties.nextRun

string

ext run time of the update.

properties.provisioningState

string

Provisioning state for the software update configuration, which only appears in the response.

properties.startTime

string

the start time of the update.

properties.tasks

softwareUpdateConfigurationTasks

Pre and Post Tasks defined

properties.updateConfiguration

updateConfiguration

Update specific properties of the software update configuration.

softwareUpdateConfigurationListResult

result of listing all software update configuration

Name Type Description
value

softwareUpdateConfigurationCollectionItem[]

outer object returned when listing all software update configurations

softwareUpdateConfigurationTasks

Task properties of the software update configuration.

Name Type Description
postTask

taskProperties

Post task properties.

preTask

taskProperties

Pre task properties.

TagOperators

Filter VMs by Any or All specified tags.

Name Type Description
All

string

Any

string

TagSettingsProperties

Tag filter information for the VM.

Name Type Description
filterOperator

TagOperators

Filter VMs by Any or All specified tags.

tags

object

Dictionary of tags with its list of values.

TargetProperties

Group specific to the update configuration.

Name Type Description
azureQueries

AzureQueryProperties[]

List of Azure queries in the software update configuration.

nonAzureQueries

NonAzureQueryProperties[]

List of non Azure queries in the software update configuration.

taskProperties

Task properties of the software update configuration.

Name Type Description
parameters

object

Gets or sets the parameters of the task.

source

string

Gets or sets the name of the runbook.

updateConfiguration

Update specific properties of the software update configuration.

Name Type Description
azureVirtualMachines

string[]

List of azure resource Ids for azure virtual machines targeted by the software update configuration.

duration

string

Maximum time allowed for the software update configuration run. Duration needs to be specified using the format PT[n]H[n]M[n]S as per ISO8601

linux

LinuxProperties

Linux specific update configuration.

nonAzureComputerNames

string[]

List of names of non-azure machines targeted by the software update configuration.

operatingSystem

OperatingSystemType

operating system of target machines

targets

TargetProperties

Group targets for the software update configuration.

windows

WindowsProperties

Windows specific update configuration.

WindowsProperties

Windows specific update configuration.

Name Type Description
excludedKbNumbers

string[]

KB numbers excluded from the software update configuration.

includedKbNumbers

string[]

KB numbers included from the software update configuration.

includedUpdateClassifications

WindowsUpdateClasses

Update classification included in the software update configuration. A comma separated string with required values

rebootSetting

string

Reboot setting for the software update configuration.

WindowsUpdateClasses

Update classification included in the software update configuration. A comma separated string with required values

Name Type Description
Critical

string

Definition

string

FeaturePack

string

Security

string

ServicePack

string

Tools

string

Unclassified

string

UpdateRollup

string

Updates

string