From d26b8ee10c1ad7e8ff6031caebdafa6f85c50f2d Mon Sep 17 00:00:00 2001 From: SDKAuto Date: Thu, 16 Feb 2023 14:25:06 +0000 Subject: [PATCH] CodeGen from PR 22642 in Azure/azure-rest-api-specs Merge 1dfbc16cd0844aeb91cd1cbb274bd94455711fce into 3d8685062f830eae770780a43a9a656f155412f3 --- .../azure-mgmt-authorization/_meta.json | 4 +- .../authorization/v2015_06_01/_version.py | 2 +- .../authorization/v2015_07_01/_version.py | 2 +- .../v2018_01_01_preview/_version.py | 2 +- .../v2018_05_01_preview/_version.py | 2 +- .../v2018_07_01_preview/_version.py | 2 +- .../v2018_09_01_preview/_version.py | 2 +- .../v2019_08_01_preview/_version.py | 2 +- .../v2020_04_01_preview/_version.py | 2 +- .../authorization/v2020_10_01/_version.py | 2 +- .../v2020_10_01_preview/_version.py | 2 +- .../v2021_01_01_preview/_version.py | 2 +- .../v2021_03_01_preview/_version.py | 2 +- .../v2021_07_01_preview/_version.py | 2 +- .../v2021_12_01_preview/_version.py | 2 +- .../operations/_alert_operation_operations.py | 58 +------------ .../v2021_12_01_preview/models/__init__.py | 2 - .../v2021_12_01_preview/models/_models_py3.py | 53 +++++------- .../operations/_alert_operation_operations.py | 82 ------------------- .../authorization/v2022_04_01/_version.py | 2 +- 20 files changed, 38 insertions(+), 191 deletions(-) diff --git a/sdk/authorization/azure-mgmt-authorization/_meta.json b/sdk/authorization/azure-mgmt-authorization/_meta.json index 978cb26ce5a9..539c05fb1926 100644 --- a/sdk/authorization/azure-mgmt-authorization/_meta.json +++ b/sdk/authorization/azure-mgmt-authorization/_meta.json @@ -1,11 +1,11 @@ { - "commit": "d37b3db5ec88a9fc2afcae36bf8d2004b1c5b537", + "commit": "160d46bc2f5d07fd641ffc910dd758696de930f4", "repository_url": "https://github.com/Azure/azure-rest-api-specs", "autorest": "3.9.2", "use": [ "@autorest/python@6.4.0", "@autorest/modelerfour@4.24.3" ], - "autorest_command": "autorest specification/authorization/resource-manager/readme.md --generate-sample=True --include-x-ms-examples-original-file=True --python --python-sdks-folder=/home/vsts/work/1/azure-sdk-for-python/sdk --use=@autorest/python@6.4.0 --use=@autorest/modelerfour@4.24.3 --version=3.9.2 --version-tolerant=False", + "autorest_command": "autorest specification/authorization/resource-manager/readme.md --generate-sample=True --include-x-ms-examples-original-file=True --python --python-sdks-folder=/mnt/vss/_work/1/s/azure-sdk-for-python/sdk --use=@autorest/python@6.4.0 --use=@autorest/modelerfour@4.24.3 --version=3.9.2 --version-tolerant=False", "readme": "specification/authorization/resource-manager/readme.md" } \ No newline at end of file diff --git a/sdk/authorization/azure-mgmt-authorization/azure/mgmt/authorization/v2015_06_01/_version.py b/sdk/authorization/azure-mgmt-authorization/azure/mgmt/authorization/v2015_06_01/_version.py index 48b05f9c489c..e5754a47ce68 100644 --- a/sdk/authorization/azure-mgmt-authorization/azure/mgmt/authorization/v2015_06_01/_version.py +++ b/sdk/authorization/azure-mgmt-authorization/azure/mgmt/authorization/v2015_06_01/_version.py @@ -6,4 +6,4 @@ # Changes may cause incorrect behavior and will be lost if the code is regenerated. # -------------------------------------------------------------------------- -VERSION = "3.1.0b1" +VERSION = "1.0.0b1" diff --git a/sdk/authorization/azure-mgmt-authorization/azure/mgmt/authorization/v2015_07_01/_version.py b/sdk/authorization/azure-mgmt-authorization/azure/mgmt/authorization/v2015_07_01/_version.py index 48b05f9c489c..e5754a47ce68 100644 --- a/sdk/authorization/azure-mgmt-authorization/azure/mgmt/authorization/v2015_07_01/_version.py +++ b/sdk/authorization/azure-mgmt-authorization/azure/mgmt/authorization/v2015_07_01/_version.py @@ -6,4 +6,4 @@ # Changes may cause incorrect behavior and will be lost if the code is regenerated. # -------------------------------------------------------------------------- -VERSION = "3.1.0b1" +VERSION = "1.0.0b1" diff --git a/sdk/authorization/azure-mgmt-authorization/azure/mgmt/authorization/v2018_01_01_preview/_version.py b/sdk/authorization/azure-mgmt-authorization/azure/mgmt/authorization/v2018_01_01_preview/_version.py index 48b05f9c489c..e5754a47ce68 100644 --- a/sdk/authorization/azure-mgmt-authorization/azure/mgmt/authorization/v2018_01_01_preview/_version.py +++ b/sdk/authorization/azure-mgmt-authorization/azure/mgmt/authorization/v2018_01_01_preview/_version.py @@ -6,4 +6,4 @@ # Changes may cause incorrect behavior and will be lost if the code is regenerated. # -------------------------------------------------------------------------- -VERSION = "3.1.0b1" +VERSION = "1.0.0b1" diff --git a/sdk/authorization/azure-mgmt-authorization/azure/mgmt/authorization/v2018_05_01_preview/_version.py b/sdk/authorization/azure-mgmt-authorization/azure/mgmt/authorization/v2018_05_01_preview/_version.py index 48b05f9c489c..e5754a47ce68 100644 --- a/sdk/authorization/azure-mgmt-authorization/azure/mgmt/authorization/v2018_05_01_preview/_version.py +++ b/sdk/authorization/azure-mgmt-authorization/azure/mgmt/authorization/v2018_05_01_preview/_version.py @@ -6,4 +6,4 @@ # Changes may cause incorrect behavior and will be lost if the code is regenerated. # -------------------------------------------------------------------------- -VERSION = "3.1.0b1" +VERSION = "1.0.0b1" diff --git a/sdk/authorization/azure-mgmt-authorization/azure/mgmt/authorization/v2018_07_01_preview/_version.py b/sdk/authorization/azure-mgmt-authorization/azure/mgmt/authorization/v2018_07_01_preview/_version.py index 48b05f9c489c..e5754a47ce68 100644 --- a/sdk/authorization/azure-mgmt-authorization/azure/mgmt/authorization/v2018_07_01_preview/_version.py +++ b/sdk/authorization/azure-mgmt-authorization/azure/mgmt/authorization/v2018_07_01_preview/_version.py @@ -6,4 +6,4 @@ # Changes may cause incorrect behavior and will be lost if the code is regenerated. # -------------------------------------------------------------------------- -VERSION = "3.1.0b1" +VERSION = "1.0.0b1" diff --git a/sdk/authorization/azure-mgmt-authorization/azure/mgmt/authorization/v2018_09_01_preview/_version.py b/sdk/authorization/azure-mgmt-authorization/azure/mgmt/authorization/v2018_09_01_preview/_version.py index 48b05f9c489c..e5754a47ce68 100644 --- a/sdk/authorization/azure-mgmt-authorization/azure/mgmt/authorization/v2018_09_01_preview/_version.py +++ b/sdk/authorization/azure-mgmt-authorization/azure/mgmt/authorization/v2018_09_01_preview/_version.py @@ -6,4 +6,4 @@ # Changes may cause incorrect behavior and will be lost if the code is regenerated. # -------------------------------------------------------------------------- -VERSION = "3.1.0b1" +VERSION = "1.0.0b1" diff --git a/sdk/authorization/azure-mgmt-authorization/azure/mgmt/authorization/v2019_08_01_preview/_version.py b/sdk/authorization/azure-mgmt-authorization/azure/mgmt/authorization/v2019_08_01_preview/_version.py index 48b05f9c489c..e5754a47ce68 100644 --- a/sdk/authorization/azure-mgmt-authorization/azure/mgmt/authorization/v2019_08_01_preview/_version.py +++ b/sdk/authorization/azure-mgmt-authorization/azure/mgmt/authorization/v2019_08_01_preview/_version.py @@ -6,4 +6,4 @@ # Changes may cause incorrect behavior and will be lost if the code is regenerated. # -------------------------------------------------------------------------- -VERSION = "3.1.0b1" +VERSION = "1.0.0b1" diff --git a/sdk/authorization/azure-mgmt-authorization/azure/mgmt/authorization/v2020_04_01_preview/_version.py b/sdk/authorization/azure-mgmt-authorization/azure/mgmt/authorization/v2020_04_01_preview/_version.py index 48b05f9c489c..e5754a47ce68 100644 --- a/sdk/authorization/azure-mgmt-authorization/azure/mgmt/authorization/v2020_04_01_preview/_version.py +++ b/sdk/authorization/azure-mgmt-authorization/azure/mgmt/authorization/v2020_04_01_preview/_version.py @@ -6,4 +6,4 @@ # Changes may cause incorrect behavior and will be lost if the code is regenerated. # -------------------------------------------------------------------------- -VERSION = "3.1.0b1" +VERSION = "1.0.0b1" diff --git a/sdk/authorization/azure-mgmt-authorization/azure/mgmt/authorization/v2020_10_01/_version.py b/sdk/authorization/azure-mgmt-authorization/azure/mgmt/authorization/v2020_10_01/_version.py index 48b05f9c489c..e5754a47ce68 100644 --- a/sdk/authorization/azure-mgmt-authorization/azure/mgmt/authorization/v2020_10_01/_version.py +++ b/sdk/authorization/azure-mgmt-authorization/azure/mgmt/authorization/v2020_10_01/_version.py @@ -6,4 +6,4 @@ # Changes may cause incorrect behavior and will be lost if the code is regenerated. # -------------------------------------------------------------------------- -VERSION = "3.1.0b1" +VERSION = "1.0.0b1" diff --git a/sdk/authorization/azure-mgmt-authorization/azure/mgmt/authorization/v2020_10_01_preview/_version.py b/sdk/authorization/azure-mgmt-authorization/azure/mgmt/authorization/v2020_10_01_preview/_version.py index 48b05f9c489c..e5754a47ce68 100644 --- a/sdk/authorization/azure-mgmt-authorization/azure/mgmt/authorization/v2020_10_01_preview/_version.py +++ b/sdk/authorization/azure-mgmt-authorization/azure/mgmt/authorization/v2020_10_01_preview/_version.py @@ -6,4 +6,4 @@ # Changes may cause incorrect behavior and will be lost if the code is regenerated. # -------------------------------------------------------------------------- -VERSION = "3.1.0b1" +VERSION = "1.0.0b1" diff --git a/sdk/authorization/azure-mgmt-authorization/azure/mgmt/authorization/v2021_01_01_preview/_version.py b/sdk/authorization/azure-mgmt-authorization/azure/mgmt/authorization/v2021_01_01_preview/_version.py index 48b05f9c489c..e5754a47ce68 100644 --- a/sdk/authorization/azure-mgmt-authorization/azure/mgmt/authorization/v2021_01_01_preview/_version.py +++ b/sdk/authorization/azure-mgmt-authorization/azure/mgmt/authorization/v2021_01_01_preview/_version.py @@ -6,4 +6,4 @@ # Changes may cause incorrect behavior and will be lost if the code is regenerated. # -------------------------------------------------------------------------- -VERSION = "3.1.0b1" +VERSION = "1.0.0b1" diff --git a/sdk/authorization/azure-mgmt-authorization/azure/mgmt/authorization/v2021_03_01_preview/_version.py b/sdk/authorization/azure-mgmt-authorization/azure/mgmt/authorization/v2021_03_01_preview/_version.py index 48b05f9c489c..e5754a47ce68 100644 --- a/sdk/authorization/azure-mgmt-authorization/azure/mgmt/authorization/v2021_03_01_preview/_version.py +++ b/sdk/authorization/azure-mgmt-authorization/azure/mgmt/authorization/v2021_03_01_preview/_version.py @@ -6,4 +6,4 @@ # Changes may cause incorrect behavior and will be lost if the code is regenerated. # -------------------------------------------------------------------------- -VERSION = "3.1.0b1" +VERSION = "1.0.0b1" diff --git a/sdk/authorization/azure-mgmt-authorization/azure/mgmt/authorization/v2021_07_01_preview/_version.py b/sdk/authorization/azure-mgmt-authorization/azure/mgmt/authorization/v2021_07_01_preview/_version.py index 48b05f9c489c..e5754a47ce68 100644 --- a/sdk/authorization/azure-mgmt-authorization/azure/mgmt/authorization/v2021_07_01_preview/_version.py +++ b/sdk/authorization/azure-mgmt-authorization/azure/mgmt/authorization/v2021_07_01_preview/_version.py @@ -6,4 +6,4 @@ # Changes may cause incorrect behavior and will be lost if the code is regenerated. # -------------------------------------------------------------------------- -VERSION = "3.1.0b1" +VERSION = "1.0.0b1" diff --git a/sdk/authorization/azure-mgmt-authorization/azure/mgmt/authorization/v2021_12_01_preview/_version.py b/sdk/authorization/azure-mgmt-authorization/azure/mgmt/authorization/v2021_12_01_preview/_version.py index 48b05f9c489c..e5754a47ce68 100644 --- a/sdk/authorization/azure-mgmt-authorization/azure/mgmt/authorization/v2021_12_01_preview/_version.py +++ b/sdk/authorization/azure-mgmt-authorization/azure/mgmt/authorization/v2021_12_01_preview/_version.py @@ -6,4 +6,4 @@ # Changes may cause incorrect behavior and will be lost if the code is regenerated. # -------------------------------------------------------------------------- -VERSION = "3.1.0b1" +VERSION = "1.0.0b1" diff --git a/sdk/authorization/azure-mgmt-authorization/azure/mgmt/authorization/v2021_12_01_preview/aio/operations/_alert_operation_operations.py b/sdk/authorization/azure-mgmt-authorization/azure/mgmt/authorization/v2021_12_01_preview/aio/operations/_alert_operation_operations.py index 3ccd6d860aa2..c30830e2a5c9 100644 --- a/sdk/authorization/azure-mgmt-authorization/azure/mgmt/authorization/v2021_12_01_preview/aio/operations/_alert_operation_operations.py +++ b/sdk/authorization/azure-mgmt-authorization/azure/mgmt/authorization/v2021_12_01_preview/aio/operations/_alert_operation_operations.py @@ -26,7 +26,7 @@ from ... import models as _models from ..._vendor import _convert_request -from ...operations._alert_operation_operations import build_get_request, build_list_for_scope_request +from ...operations._alert_operation_operations import build_get_request if sys.version_info >= (3, 8): from typing import Literal # pylint: disable=no-name-in-module, ungrouped-imports @@ -113,59 +113,3 @@ async def get(self, scope: str, operation_id: str, **kwargs: Any) -> _models.Ale return deserialized get.metadata = {"url": "/{scope}/providers/Microsoft.Authorization/roleManagementAlertOperations/{operationId}"} - - @distributed_trace_async - async def list_for_scope(self, scope: str, **kwargs: Any) -> _models.AlertOperationListResult: - """Gets alert operations for a resource scope. - - :param scope: The scope of the alert operation. Required. - :type scope: str - :keyword callable cls: A custom type or function that will be passed the direct response - :return: AlertOperationListResult or the result of cls(response) - :rtype: ~azure.mgmt.authorization.v2021_12_01_preview.models.AlertOperationListResult - :raises ~azure.core.exceptions.HttpResponseError: - """ - error_map = { - 401: ClientAuthenticationError, - 404: ResourceNotFoundError, - 409: ResourceExistsError, - 304: ResourceNotModifiedError, - } - error_map.update(kwargs.pop("error_map", {}) or {}) - - _headers = kwargs.pop("headers", {}) or {} - _params = case_insensitive_dict(kwargs.pop("params", {}) or {}) - - api_version: Literal["2022-08-01-preview"] = kwargs.pop( - "api_version", _params.pop("api-version", "2022-08-01-preview") - ) - cls: ClsType[_models.AlertOperationListResult] = kwargs.pop("cls", None) - - request = build_list_for_scope_request( - scope=scope, - api_version=api_version, - template_url=self.list_for_scope.metadata["url"], - headers=_headers, - params=_params, - ) - request = _convert_request(request) - request.url = self._client.format_url(request.url) - - pipeline_response: PipelineResponse = await self._client._pipeline.run( # pylint: disable=protected-access - request, stream=False, **kwargs - ) - - response = pipeline_response.http_response - - if response.status_code not in [200]: - map_error(status_code=response.status_code, response=response, error_map=error_map) - raise HttpResponseError(response=response, error_format=ARMErrorFormat) - - deserialized = self._deserialize("AlertOperationListResult", pipeline_response) - - if cls: - return cls(pipeline_response, deserialized, {}) - - return deserialized - - list_for_scope.metadata = {"url": "/{scope}/providers/Microsoft.Authorization/roleManagementAlertOperations"} diff --git a/sdk/authorization/azure-mgmt-authorization/azure/mgmt/authorization/v2021_12_01_preview/models/__init__.py b/sdk/authorization/azure-mgmt-authorization/azure/mgmt/authorization/v2021_12_01_preview/models/__init__.py index ec0b44dcef81..a167baab0da8 100644 --- a/sdk/authorization/azure-mgmt-authorization/azure/mgmt/authorization/v2021_12_01_preview/models/__init__.py +++ b/sdk/authorization/azure-mgmt-authorization/azure/mgmt/authorization/v2021_12_01_preview/models/__init__.py @@ -42,7 +42,6 @@ from ._models_py3 import AlertIncidentListResult from ._models_py3 import AlertIncidentProperties from ._models_py3 import AlertListResult -from ._models_py3 import AlertOperationListResult from ._models_py3 import AlertOperationResult from ._models_py3 import AzureRolesAssignedOutsidePimAlertConfigurationProperties from ._models_py3 import AzureRolesAssignedOutsidePimAlertIncidentProperties @@ -122,7 +121,6 @@ "AlertIncidentListResult", "AlertIncidentProperties", "AlertListResult", - "AlertOperationListResult", "AlertOperationResult", "AzureRolesAssignedOutsidePimAlertConfigurationProperties", "AzureRolesAssignedOutsidePimAlertIncidentProperties", diff --git a/sdk/authorization/azure-mgmt-authorization/azure/mgmt/authorization/v2021_12_01_preview/models/_models_py3.py b/sdk/authorization/azure-mgmt-authorization/azure/mgmt/authorization/v2021_12_01_preview/models/_models_py3.py index 5e0b94757ba1..0eb252a172af 100644 --- a/sdk/authorization/azure-mgmt-authorization/azure/mgmt/authorization/v2021_12_01_preview/models/_models_py3.py +++ b/sdk/authorization/azure-mgmt-authorization/azure/mgmt/authorization/v2021_12_01_preview/models/_models_py3.py @@ -3190,39 +3190,6 @@ def __init__( self.next_link = next_link -class AlertOperationListResult(_serialization.Model): - """Alert operation list operation result. - - :ivar value: Alert operation list. - :vartype value: list[~azure.mgmt.authorization.v2021_12_01_preview.models.AlertOperationResult] - :ivar next_link: The URL to use for getting the next set of results. - :vartype next_link: str - """ - - _attribute_map = { - "value": {"key": "value", "type": "[AlertOperationResult]"}, - "next_link": {"key": "nextLink", "type": "str"}, - } - - def __init__( - self, - *, - value: Optional[List["_models.AlertOperationResult"]] = None, - next_link: Optional[str] = None, - **kwargs: Any - ) -> None: - """ - :keyword value: Alert operation list. - :paramtype value: - list[~azure.mgmt.authorization.v2021_12_01_preview.models.AlertOperationResult] - :keyword next_link: The URL to use for getting the next set of results. - :paramtype next_link: str - """ - super().__init__(**kwargs) - self.value = value - self.next_link = next_link - - class AlertOperationResult(_serialization.Model): """Alert operation result. @@ -3232,16 +3199,32 @@ class AlertOperationResult(_serialization.Model): :vartype id: str :ivar status: The status of the alert operation. :vartype status: str + :ivar status_detail: The status detail of the alert operation. + :vartype status_detail: str + :ivar created_date_time: The created date of the alert operation. + :vartype created_date_time: ~datetime.datetime + :ivar last_action_date_time: The last action date of the alert operation. + :vartype last_action_date_time: ~datetime.datetime + :ivar resource_location: The location of the alert associated with the operation. + :vartype resource_location: str """ _validation = { "id": {"readonly": True}, "status": {"readonly": True}, + "status_detail": {"readonly": True}, + "created_date_time": {"readonly": True}, + "last_action_date_time": {"readonly": True}, + "resource_location": {"readonly": True}, } _attribute_map = { "id": {"key": "id", "type": "str"}, "status": {"key": "status", "type": "str"}, + "status_detail": {"key": "statusDetail", "type": "str"}, + "created_date_time": {"key": "createdDateTime", "type": "iso-8601"}, + "last_action_date_time": {"key": "lastActionDateTime", "type": "iso-8601"}, + "resource_location": {"key": "resourceLocation", "type": "str"}, } def __init__(self, **kwargs: Any) -> None: @@ -3249,6 +3232,10 @@ def __init__(self, **kwargs: Any) -> None: super().__init__(**kwargs) self.id = None self.status = None + self.status_detail = None + self.created_date_time = None + self.last_action_date_time = None + self.resource_location = None class AzureRolesAssignedOutsidePimAlertConfigurationProperties(AlertConfigurationProperties): diff --git a/sdk/authorization/azure-mgmt-authorization/azure/mgmt/authorization/v2021_12_01_preview/operations/_alert_operation_operations.py b/sdk/authorization/azure-mgmt-authorization/azure/mgmt/authorization/v2021_12_01_preview/operations/_alert_operation_operations.py index b833b3b71471..6df18d19019e 100644 --- a/sdk/authorization/azure-mgmt-authorization/azure/mgmt/authorization/v2021_12_01_preview/operations/_alert_operation_operations.py +++ b/sdk/authorization/azure-mgmt-authorization/azure/mgmt/authorization/v2021_12_01_preview/operations/_alert_operation_operations.py @@ -68,32 +68,6 @@ def build_get_request(scope: str, operation_id: str, **kwargs: Any) -> HttpReque return HttpRequest(method="GET", url=_url, params=_params, headers=_headers, **kwargs) -def build_list_for_scope_request(scope: str, **kwargs: Any) -> HttpRequest: - _headers = case_insensitive_dict(kwargs.pop("headers", {}) or {}) - _params = case_insensitive_dict(kwargs.pop("params", {}) or {}) - - api_version: Literal["2022-08-01-preview"] = kwargs.pop( - "api_version", _params.pop("api-version", "2022-08-01-preview") - ) - accept = _headers.pop("Accept", "application/json") - - # Construct URL - _url = kwargs.pop("template_url", "/{scope}/providers/Microsoft.Authorization/roleManagementAlertOperations") - path_format_arguments = { - "scope": _SERIALIZER.url("scope", scope, "str", skip_quote=True), - } - - _url: str = _format_url_section(_url, **path_format_arguments) # type: ignore - - # Construct parameters - _params["api-version"] = _SERIALIZER.query("api_version", api_version, "str") - - # Construct headers - _headers["Accept"] = _SERIALIZER.header("accept", accept, "str") - - return HttpRequest(method="GET", url=_url, params=_params, headers=_headers, **kwargs) - - class AlertOperationOperations: """ .. warning:: @@ -171,59 +145,3 @@ def get(self, scope: str, operation_id: str, **kwargs: Any) -> _models.AlertOper return deserialized get.metadata = {"url": "/{scope}/providers/Microsoft.Authorization/roleManagementAlertOperations/{operationId}"} - - @distributed_trace - def list_for_scope(self, scope: str, **kwargs: Any) -> _models.AlertOperationListResult: - """Gets alert operations for a resource scope. - - :param scope: The scope of the alert operation. Required. - :type scope: str - :keyword callable cls: A custom type or function that will be passed the direct response - :return: AlertOperationListResult or the result of cls(response) - :rtype: ~azure.mgmt.authorization.v2021_12_01_preview.models.AlertOperationListResult - :raises ~azure.core.exceptions.HttpResponseError: - """ - error_map = { - 401: ClientAuthenticationError, - 404: ResourceNotFoundError, - 409: ResourceExistsError, - 304: ResourceNotModifiedError, - } - error_map.update(kwargs.pop("error_map", {}) or {}) - - _headers = kwargs.pop("headers", {}) or {} - _params = case_insensitive_dict(kwargs.pop("params", {}) or {}) - - api_version: Literal["2022-08-01-preview"] = kwargs.pop( - "api_version", _params.pop("api-version", "2022-08-01-preview") - ) - cls: ClsType[_models.AlertOperationListResult] = kwargs.pop("cls", None) - - request = build_list_for_scope_request( - scope=scope, - api_version=api_version, - template_url=self.list_for_scope.metadata["url"], - headers=_headers, - params=_params, - ) - request = _convert_request(request) - request.url = self._client.format_url(request.url) - - pipeline_response: PipelineResponse = self._client._pipeline.run( # pylint: disable=protected-access - request, stream=False, **kwargs - ) - - response = pipeline_response.http_response - - if response.status_code not in [200]: - map_error(status_code=response.status_code, response=response, error_map=error_map) - raise HttpResponseError(response=response, error_format=ARMErrorFormat) - - deserialized = self._deserialize("AlertOperationListResult", pipeline_response) - - if cls: - return cls(pipeline_response, deserialized, {}) - - return deserialized - - list_for_scope.metadata = {"url": "/{scope}/providers/Microsoft.Authorization/roleManagementAlertOperations"} diff --git a/sdk/authorization/azure-mgmt-authorization/azure/mgmt/authorization/v2022_04_01/_version.py b/sdk/authorization/azure-mgmt-authorization/azure/mgmt/authorization/v2022_04_01/_version.py index 48b05f9c489c..e5754a47ce68 100644 --- a/sdk/authorization/azure-mgmt-authorization/azure/mgmt/authorization/v2022_04_01/_version.py +++ b/sdk/authorization/azure-mgmt-authorization/azure/mgmt/authorization/v2022_04_01/_version.py @@ -6,4 +6,4 @@ # Changes may cause incorrect behavior and will be lost if the code is regenerated. # -------------------------------------------------------------------------- -VERSION = "3.1.0b1" +VERSION = "1.0.0b1"