I am having trouble while migrating the Automation Account to Azure Update manager

Adnan Mohsin 0 Reputation points
2025-02-24T11:43:29.6+00:00

I am currently working on migrating our Azure Automation Account to Azure Update Manager using the provided PowerShell script. However, I am encountering an issue related to an invalid API version.

When executing the script, I receive the following error:

"The API version '2023-11-01' is invalid. The supported versions are '2022-08-08, 2021-04-01, etc.'"

When I change the Api version to some other version still, I am facing issues to run the script. Please see the screenshot attached herewith.screenshot_20250224_162217

Azure Update Manager
Azure Update Manager
An Azure service to centrally manages updates and compliance at scale.
353 questions
{count} votes

1 answer

Sort by: Most helpful
  1. Pranay Reddy Madireddy 2,400 Reputation points Microsoft Vendor
    2025-02-25T03:51:55.3533333+00:00

    Hi Adnan Mohsin

    Welcome to the Microsoft Q&A Platform! Thank you for asking your question here.

    The error message specifies supported API versions such as 2024-11-01 and 2024-08-01. Please update your script to use one of these supported versions.

    $apiVersion = '2024-11-01'
    

    https://learn.microsoft.com/en-us/rest/api/searchservice/search-service-api-versions#2024-11-01-preview
    The error message also mentions that the ResourceId parameter is empty. verify that you're passing a valid, non-empty ResourceId in your script. This could be a key point in resolving the issue.

    Please verify that your script is properly authenticated and that you have the necessary permissions to access the resources you're working with in Azure.

    To further isolate the issue, you can create a simplified version of your script to test basic operations using the intended API version. This can help confirm whether the issue is with the API version or another aspect of your script.

    It's important to verify that you have the latest Az PowerShell module installed. You can update it using the following command:

    Update-Module -Name Az
    

    Reference:

    https://learn.microsoft.com/en-us/rest/api/?view=Azure&term=update%20manager

    If you have any further queries, do let us know.


    If the answer is helpful, please and "Upvote it".

    0 comments No comments

Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.