diff --git a/sdk/resources/azure-mgmt-resource/azure/mgmt/resource/policy/_policy_client.py b/sdk/resources/azure-mgmt-resource/azure/mgmt/resource/policy/_policy_client.py index f0e74a66b2a8..5cb862ac32a8 100644 --- a/sdk/resources/azure-mgmt-resource/azure/mgmt/resource/policy/_policy_client.py +++ b/sdk/resources/azure-mgmt-resource/azure/mgmt/resource/policy/_policy_client.py @@ -46,7 +46,7 @@ class PolicyClient(MultiApiClientMixin, SDKClient): :type profile: azure.profiles.KnownProfiles """ - DEFAULT_API_VERSION = '2019-06-01' + DEFAULT_API_VERSION = '2019-09-01' _PROFILE_TAG = "azure.mgmt.resource.policy.PolicyClient" LATEST_PROFILE = ProfileDefinition({ _PROFILE_TAG: { @@ -80,6 +80,7 @@ def models(cls, api_version=DEFAULT_API_VERSION): * 2018-05-01: :mod:`v2018_05_01.models` * 2019-01-01: :mod:`v2019_01_01.models` * 2019-06-01: :mod:`v2019_06_01.models` + * 2019-09-01: :mod:`v2019_09_01.models` """ if api_version == '2015-10-01-preview': from .v2015_10_01_preview import models @@ -105,6 +106,9 @@ def models(cls, api_version=DEFAULT_API_VERSION): elif api_version == '2019-06-01': from .v2019_06_01 import models return models + elif api_version == '2019-09-01': + from .v2019_09_01 import models + return models raise NotImplementedError("APIVersion {} is not available".format(api_version)) @property @@ -119,6 +123,7 @@ def policy_assignments(self): * 2018-05-01: :class:`PolicyAssignmentsOperations` * 2019-01-01: :class:`PolicyAssignmentsOperations` * 2019-06-01: :class:`PolicyAssignmentsOperations` + * 2019-09-01: :class:`PolicyAssignmentsOperations` """ api_version = self._get_api_version('policy_assignments') if api_version == '2015-10-01-preview': @@ -137,6 +142,8 @@ def policy_assignments(self): from .v2019_01_01.operations import PolicyAssignmentsOperations as OperationClass elif api_version == '2019-06-01': from .v2019_06_01.operations import PolicyAssignmentsOperations as OperationClass + elif api_version == '2019-09-01': + from .v2019_09_01.operations import PolicyAssignmentsOperations as OperationClass else: raise NotImplementedError("APIVersion {} is not available".format(api_version)) return OperationClass(self._client, self.config, Serializer(self._models_dict(api_version)), Deserializer(self._models_dict(api_version))) @@ -153,6 +160,7 @@ def policy_definitions(self): * 2018-05-01: :class:`PolicyDefinitionsOperations` * 2019-01-01: :class:`PolicyDefinitionsOperations` * 2019-06-01: :class:`PolicyDefinitionsOperations` + * 2019-09-01: :class:`PolicyDefinitionsOperations` """ api_version = self._get_api_version('policy_definitions') if api_version == '2015-10-01-preview': @@ -171,6 +179,8 @@ def policy_definitions(self): from .v2019_01_01.operations import PolicyDefinitionsOperations as OperationClass elif api_version == '2019-06-01': from .v2019_06_01.operations import PolicyDefinitionsOperations as OperationClass + elif api_version == '2019-09-01': + from .v2019_09_01.operations import PolicyDefinitionsOperations as OperationClass else: raise NotImplementedError("APIVersion {} is not available".format(api_version)) return OperationClass(self._client, self.config, Serializer(self._models_dict(api_version)), Deserializer(self._models_dict(api_version))) @@ -184,6 +194,7 @@ def policy_set_definitions(self): * 2018-05-01: :class:`PolicySetDefinitionsOperations` * 2019-01-01: :class:`PolicySetDefinitionsOperations` * 2019-06-01: :class:`PolicySetDefinitionsOperations` + * 2019-09-01: :class:`PolicySetDefinitionsOperations` """ api_version = self._get_api_version('policy_set_definitions') if api_version == '2017-06-01-preview': @@ -196,6 +207,8 @@ def policy_set_definitions(self): from .v2019_01_01.operations import PolicySetDefinitionsOperations as OperationClass elif api_version == '2019-06-01': from .v2019_06_01.operations import PolicySetDefinitionsOperations as OperationClass + elif api_version == '2019-09-01': + from .v2019_09_01.operations import PolicySetDefinitionsOperations as OperationClass else: raise NotImplementedError("APIVersion {} is not available".format(api_version)) return OperationClass(self._client, self.config, Serializer(self._models_dict(api_version)), Deserializer(self._models_dict(api_version))) diff --git a/sdk/resources/azure-mgmt-resource/azure/mgmt/resource/policy/models.py b/sdk/resources/azure-mgmt-resource/azure/mgmt/resource/policy/models.py index e14bb6e177c2..1d5d79558e5e 100644 --- a/sdk/resources/azure-mgmt-resource/azure/mgmt/resource/policy/models.py +++ b/sdk/resources/azure-mgmt-resource/azure/mgmt/resource/policy/models.py @@ -4,4 +4,4 @@ # Licensed under the MIT License. See License.txt in the project root for # license information. # -------------------------------------------------------------------------- -from .v2019_06_01.models import * +from .v2019_09_01.models import * diff --git a/sdk/resources/azure-mgmt-resource/azure/mgmt/resource/policy/v2019_09_01/models/_models.py b/sdk/resources/azure-mgmt-resource/azure/mgmt/resource/policy/v2019_09_01/models/_models.py index 114036a52a39..f88d67578208 100644 --- a/sdk/resources/azure-mgmt-resource/azure/mgmt/resource/policy/v2019_09_01/models/_models.py +++ b/sdk/resources/azure-mgmt-resource/azure/mgmt/resource/policy/v2019_09_01/models/_models.py @@ -124,8 +124,9 @@ class Identity(Model): :vartype principal_id: str :ivar tenant_id: The tenant ID of the resource identity. :vartype tenant_id: str - :param type: The identity type. Possible values include: 'SystemAssigned', - 'None' + :param type: The identity type. This is the only required field when + adding a system assigned identity to a resource. Possible values include: + 'SystemAssigned', 'None' :type type: str or ~azure.mgmt.resource.policy.v2019_09_01.models.ResourceIdentityType """ @@ -149,7 +150,7 @@ def __init__(self, **kwargs): class ParameterDefinitionsValue(Model): - """ParameterDefinitionsValue. + """The definition of a parameter that can be provided to the policy. :param type: The data type of the parameter. Possible values include: 'String', 'Array', 'Object', 'Boolean', 'Integer', 'Float', 'DateTime' @@ -206,7 +207,7 @@ def __init__(self, **kwargs): class ParameterValuesValue(Model): - """ParameterValuesValue. + """The value of a parameter. :param value: The value of the parameter. :type value: object diff --git a/sdk/resources/azure-mgmt-resource/azure/mgmt/resource/policy/v2019_09_01/models/_models_py3.py b/sdk/resources/azure-mgmt-resource/azure/mgmt/resource/policy/v2019_09_01/models/_models_py3.py index 1b95a34bd701..7a0c0c14935c 100644 --- a/sdk/resources/azure-mgmt-resource/azure/mgmt/resource/policy/v2019_09_01/models/_models_py3.py +++ b/sdk/resources/azure-mgmt-resource/azure/mgmt/resource/policy/v2019_09_01/models/_models_py3.py @@ -124,8 +124,9 @@ class Identity(Model): :vartype principal_id: str :ivar tenant_id: The tenant ID of the resource identity. :vartype tenant_id: str - :param type: The identity type. Possible values include: 'SystemAssigned', - 'None' + :param type: The identity type. This is the only required field when + adding a system assigned identity to a resource. Possible values include: + 'SystemAssigned', 'None' :type type: str or ~azure.mgmt.resource.policy.v2019_09_01.models.ResourceIdentityType """ @@ -149,7 +150,7 @@ def __init__(self, *, type=None, **kwargs) -> None: class ParameterDefinitionsValue(Model): - """ParameterDefinitionsValue. + """The definition of a parameter that can be provided to the policy. :param type: The data type of the parameter. Possible values include: 'String', 'Array', 'Object', 'Boolean', 'Integer', 'Float', 'DateTime' @@ -206,7 +207,7 @@ def __init__(self, *, additional_properties=None, display_name: str=None, descri class ParameterValuesValue(Model): - """ParameterValuesValue. + """The value of a parameter. :param value: The value of the parameter. :type value: object diff --git a/sdk/resources/azure-mgmt-resource/azure/mgmt/resource/policy/v2019_09_01/models/_policy_client_enums.py b/sdk/resources/azure-mgmt-resource/azure/mgmt/resource/policy/v2019_09_01/models/_policy_client_enums.py index 355e37daa4a5..805f0fcafcb8 100644 --- a/sdk/resources/azure-mgmt-resource/azure/mgmt/resource/policy/v2019_09_01/models/_policy_client_enums.py +++ b/sdk/resources/azure-mgmt-resource/azure/mgmt/resource/policy/v2019_09_01/models/_policy_client_enums.py @@ -20,8 +20,8 @@ class EnforcementMode(str, Enum): class ResourceIdentityType(str, Enum): - system_assigned = "SystemAssigned" - none = "None" + system_assigned = "SystemAssigned" #: Indicates that a system assigned identity is associated with the resource. + none = "None" #: Indicates that no identity is associated with the resource or that the existing identity should be removed. class PolicyType(str, Enum): diff --git a/sdk/resources/azure-mgmt-resource/azure/mgmt/resource/resources/_resource_management_client.py b/sdk/resources/azure-mgmt-resource/azure/mgmt/resource/resources/_resource_management_client.py index 5108d2ae9517..01d31833b16c 100644 --- a/sdk/resources/azure-mgmt-resource/azure/mgmt/resource/resources/_resource_management_client.py +++ b/sdk/resources/azure-mgmt-resource/azure/mgmt/resource/resources/_resource_management_client.py @@ -46,7 +46,7 @@ class ResourceManagementClient(MultiApiClientMixin, SDKClient): :type profile: azure.profiles.KnownProfiles """ - DEFAULT_API_VERSION = '2019-08-01' + DEFAULT_API_VERSION = '2019-10-01' _PROFILE_TAG = "azure.mgmt.resource.resources.ResourceManagementClient" LATEST_PROFILE = ProfileDefinition({ _PROFILE_TAG: { @@ -81,6 +81,7 @@ def models(cls, api_version=DEFAULT_API_VERSION): * 2019-05-10: :mod:`v2019_05_10.models` * 2019-07-01: :mod:`v2019_07_01.models` * 2019-08-01: :mod:`v2019_08_01.models` + * 2019-10-01: :mod:`v2019_10_01.models` """ if api_version == '2016-02-01': from .v2016_02_01 import models @@ -109,6 +110,9 @@ def models(cls, api_version=DEFAULT_API_VERSION): elif api_version == '2019-08-01': from .v2019_08_01 import models return models + elif api_version == '2019-10-01': + from .v2019_10_01 import models + return models raise NotImplementedError("APIVersion {} is not available".format(api_version)) @property @@ -124,6 +128,7 @@ def deployment_operations(self): * 2019-05-10: :class:`DeploymentOperations` * 2019-07-01: :class:`DeploymentOperations` * 2019-08-01: :class:`DeploymentOperations` + * 2019-10-01: :class:`DeploymentOperations` """ api_version = self._get_api_version('deployment_operations') if api_version == '2016-02-01': @@ -144,6 +149,8 @@ def deployment_operations(self): from .v2019_07_01.operations import DeploymentOperations as OperationClass elif api_version == '2019-08-01': from .v2019_08_01.operations import DeploymentOperations as OperationClass + elif api_version == '2019-10-01': + from .v2019_10_01.operations import DeploymentOperations as OperationClass else: raise NotImplementedError("APIVersion {} is not available".format(api_version)) return OperationClass(self._client, self.config, Serializer(self._models_dict(api_version)), Deserializer(self._models_dict(api_version))) @@ -161,6 +168,7 @@ def deployments(self): * 2019-05-10: :class:`DeploymentsOperations` * 2019-07-01: :class:`DeploymentsOperations` * 2019-08-01: :class:`DeploymentsOperations` + * 2019-10-01: :class:`DeploymentsOperations` """ api_version = self._get_api_version('deployments') if api_version == '2016-02-01': @@ -181,6 +189,8 @@ def deployments(self): from .v2019_07_01.operations import DeploymentsOperations as OperationClass elif api_version == '2019-08-01': from .v2019_08_01.operations import DeploymentsOperations as OperationClass + elif api_version == '2019-10-01': + from .v2019_10_01.operations import DeploymentsOperations as OperationClass else: raise NotImplementedError("APIVersion {} is not available".format(api_version)) return OperationClass(self._client, self.config, Serializer(self._models_dict(api_version)), Deserializer(self._models_dict(api_version))) @@ -194,6 +204,7 @@ def operations(self): * 2019-05-10: :class:`Operations` * 2019-07-01: :class:`Operations` * 2019-08-01: :class:`Operations` + * 2019-10-01: :class:`Operations` """ api_version = self._get_api_version('operations') if api_version == '2018-05-01': @@ -206,6 +217,8 @@ def operations(self): from .v2019_07_01.operations import Operations as OperationClass elif api_version == '2019-08-01': from .v2019_08_01.operations import Operations as OperationClass + elif api_version == '2019-10-01': + from .v2019_10_01.operations import Operations as OperationClass else: raise NotImplementedError("APIVersion {} is not available".format(api_version)) return OperationClass(self._client, self.config, Serializer(self._models_dict(api_version)), Deserializer(self._models_dict(api_version))) @@ -223,6 +236,7 @@ def providers(self): * 2019-05-10: :class:`ProvidersOperations` * 2019-07-01: :class:`ProvidersOperations` * 2019-08-01: :class:`ProvidersOperations` + * 2019-10-01: :class:`ProvidersOperations` """ api_version = self._get_api_version('providers') if api_version == '2016-02-01': @@ -243,6 +257,8 @@ def providers(self): from .v2019_07_01.operations import ProvidersOperations as OperationClass elif api_version == '2019-08-01': from .v2019_08_01.operations import ProvidersOperations as OperationClass + elif api_version == '2019-10-01': + from .v2019_10_01.operations import ProvidersOperations as OperationClass else: raise NotImplementedError("APIVersion {} is not available".format(api_version)) return OperationClass(self._client, self.config, Serializer(self._models_dict(api_version)), Deserializer(self._models_dict(api_version))) @@ -260,6 +276,7 @@ def resource_groups(self): * 2019-05-10: :class:`ResourceGroupsOperations` * 2019-07-01: :class:`ResourceGroupsOperations` * 2019-08-01: :class:`ResourceGroupsOperations` + * 2019-10-01: :class:`ResourceGroupsOperations` """ api_version = self._get_api_version('resource_groups') if api_version == '2016-02-01': @@ -280,6 +297,8 @@ def resource_groups(self): from .v2019_07_01.operations import ResourceGroupsOperations as OperationClass elif api_version == '2019-08-01': from .v2019_08_01.operations import ResourceGroupsOperations as OperationClass + elif api_version == '2019-10-01': + from .v2019_10_01.operations import ResourceGroupsOperations as OperationClass else: raise NotImplementedError("APIVersion {} is not available".format(api_version)) return OperationClass(self._client, self.config, Serializer(self._models_dict(api_version)), Deserializer(self._models_dict(api_version))) @@ -297,6 +316,7 @@ def resources(self): * 2019-05-10: :class:`ResourcesOperations` * 2019-07-01: :class:`ResourcesOperations` * 2019-08-01: :class:`ResourcesOperations` + * 2019-10-01: :class:`ResourcesOperations` """ api_version = self._get_api_version('resources') if api_version == '2016-02-01': @@ -317,6 +337,8 @@ def resources(self): from .v2019_07_01.operations import ResourcesOperations as OperationClass elif api_version == '2019-08-01': from .v2019_08_01.operations import ResourcesOperations as OperationClass + elif api_version == '2019-10-01': + from .v2019_10_01.operations import ResourcesOperations as OperationClass else: raise NotImplementedError("APIVersion {} is not available".format(api_version)) return OperationClass(self._client, self.config, Serializer(self._models_dict(api_version)), Deserializer(self._models_dict(api_version))) @@ -334,6 +356,7 @@ def tags(self): * 2019-05-10: :class:`TagsOperations` * 2019-07-01: :class:`TagsOperations` * 2019-08-01: :class:`TagsOperations` + * 2019-10-01: :class:`TagsOperations` """ api_version = self._get_api_version('tags') if api_version == '2016-02-01': @@ -354,6 +377,8 @@ def tags(self): from .v2019_07_01.operations import TagsOperations as OperationClass elif api_version == '2019-08-01': from .v2019_08_01.operations import TagsOperations as OperationClass + elif api_version == '2019-10-01': + from .v2019_10_01.operations import TagsOperations as OperationClass else: raise NotImplementedError("APIVersion {} is not available".format(api_version)) return OperationClass(self._client, self.config, Serializer(self._models_dict(api_version)), Deserializer(self._models_dict(api_version))) diff --git a/sdk/resources/azure-mgmt-resource/azure/mgmt/resource/resources/models.py b/sdk/resources/azure-mgmt-resource/azure/mgmt/resource/resources/models.py index 11b69d16b48b..c3d3a5ee0c2d 100644 --- a/sdk/resources/azure-mgmt-resource/azure/mgmt/resource/resources/models.py +++ b/sdk/resources/azure-mgmt-resource/azure/mgmt/resource/resources/models.py @@ -4,4 +4,4 @@ # Licensed under the MIT License. See License.txt in the project root for # license information. # -------------------------------------------------------------------------- -from .v2019_08_01.models import * +from .v2019_10_01.models import * diff --git a/sdk/resources/azure-mgmt-resource/azure/mgmt/resource/resources/v2019_10_01/models/__init__.py b/sdk/resources/azure-mgmt-resource/azure/mgmt/resource/resources/v2019_10_01/models/__init__.py index 79ca2d3552dc..7c6c4fdd0879 100644 --- a/sdk/resources/azure-mgmt-resource/azure/mgmt/resource/resources/v2019_10_01/models/__init__.py +++ b/sdk/resources/azure-mgmt-resource/azure/mgmt/resource/resources/v2019_10_01/models/__init__.py @@ -51,6 +51,7 @@ from ._models_py3 import ResourceGroupProperties from ._models_py3 import ResourceProviderOperationDisplayProperties from ._models_py3 import ResourcesMoveInfo + from ._models_py3 import ScopedDeployment from ._models_py3 import Sku from ._models_py3 import SubResource from ._models_py3 import TagCount @@ -107,6 +108,7 @@ from ._models import ResourceGroupProperties from ._models import ResourceProviderOperationDisplayProperties from ._models import ResourcesMoveInfo + from ._models import ScopedDeployment from ._models import Sku from ._models import SubResource from ._models import TagCount @@ -179,6 +181,7 @@ 'ResourceGroupProperties', 'ResourceProviderOperationDisplayProperties', 'ResourcesMoveInfo', + 'ScopedDeployment', 'Sku', 'SubResource', 'TagCount', diff --git a/sdk/resources/azure-mgmt-resource/azure/mgmt/resource/resources/v2019_10_01/models/_models.py b/sdk/resources/azure-mgmt-resource/azure/mgmt/resource/resources/v2019_10_01/models/_models.py index 65c5ffa9c546..5c72eb92aa53 100644 --- a/sdk/resources/azure-mgmt-resource/azure/mgmt/resource/resources/v2019_10_01/models/_models.py +++ b/sdk/resources/azure-mgmt-resource/azure/mgmt/resource/resources/v2019_10_01/models/_models.py @@ -1413,6 +1413,34 @@ def __init__(self, **kwargs): self.target_resource_group = kwargs.get('target_resource_group', None) +class ScopedDeployment(Model): + """Deployment operation parameters. + + All required parameters must be populated in order to send to Azure. + + :param location: Required. The location to store the deployment data. + :type location: str + :param properties: Required. The deployment properties. + :type properties: + ~azure.mgmt.resource.resources.v2019_10_01.models.DeploymentProperties + """ + + _validation = { + 'location': {'required': True}, + 'properties': {'required': True}, + } + + _attribute_map = { + 'location': {'key': 'location', 'type': 'str'}, + 'properties': {'key': 'properties', 'type': 'DeploymentProperties'}, + } + + def __init__(self, **kwargs): + super(ScopedDeployment, self).__init__(**kwargs) + self.location = kwargs.get('location', None) + self.properties = kwargs.get('properties', None) + + class Sku(Model): """SKU for the resource. diff --git a/sdk/resources/azure-mgmt-resource/azure/mgmt/resource/resources/v2019_10_01/models/_models_py3.py b/sdk/resources/azure-mgmt-resource/azure/mgmt/resource/resources/v2019_10_01/models/_models_py3.py index c604ad9a1a4f..fe13bdb1b954 100644 --- a/sdk/resources/azure-mgmt-resource/azure/mgmt/resource/resources/v2019_10_01/models/_models_py3.py +++ b/sdk/resources/azure-mgmt-resource/azure/mgmt/resource/resources/v2019_10_01/models/_models_py3.py @@ -1413,6 +1413,34 @@ def __init__(self, *, resources=None, target_resource_group: str=None, **kwargs) self.target_resource_group = target_resource_group +class ScopedDeployment(Model): + """Deployment operation parameters. + + All required parameters must be populated in order to send to Azure. + + :param location: Required. The location to store the deployment data. + :type location: str + :param properties: Required. The deployment properties. + :type properties: + ~azure.mgmt.resource.resources.v2019_10_01.models.DeploymentProperties + """ + + _validation = { + 'location': {'required': True}, + 'properties': {'required': True}, + } + + _attribute_map = { + 'location': {'key': 'location', 'type': 'str'}, + 'properties': {'key': 'properties', 'type': 'DeploymentProperties'}, + } + + def __init__(self, *, location: str, properties, **kwargs) -> None: + super(ScopedDeployment, self).__init__(**kwargs) + self.location = location + self.properties = properties + + class Sku(Model): """SKU for the resource. diff --git a/sdk/resources/azure-mgmt-resource/azure/mgmt/resource/resources/v2019_10_01/operations/_deployments_operations.py b/sdk/resources/azure-mgmt-resource/azure/mgmt/resource/resources/v2019_10_01/operations/_deployments_operations.py index 5b0c679c6a42..cda0d0a582f8 100644 --- a/sdk/resources/azure-mgmt-resource/azure/mgmt/resource/resources/v2019_10_01/operations/_deployments_operations.py +++ b/sdk/resources/azure-mgmt-resource/azure/mgmt/resource/resources/v2019_10_01/operations/_deployments_operations.py @@ -765,8 +765,8 @@ def check_existence_at_tenant_scope( def _create_or_update_at_tenant_scope_initial( - self, deployment_name, properties, location=None, custom_headers=None, raw=False, **operation_config): - parameters = models.Deployment(location=location, properties=properties) + self, deployment_name, location, properties, custom_headers=None, raw=False, **operation_config): + parameters = models.ScopedDeployment(location=location, properties=properties) # Construct URL url = self.create_or_update_at_tenant_scope.metadata['url'] @@ -791,7 +791,7 @@ def _create_or_update_at_tenant_scope_initial( header_parameters['accept-language'] = self._serialize.header("self.config.accept_language", self.config.accept_language, 'str') # Construct body - body_content = self._serialize.body(parameters, 'Deployment') + body_content = self._serialize.body(parameters, 'ScopedDeployment') # Construct and send request request = self._client.put(url, query_parameters, header_parameters, body_content) @@ -816,7 +816,7 @@ def _create_or_update_at_tenant_scope_initial( return deserialized def create_or_update_at_tenant_scope( - self, deployment_name, properties, location=None, custom_headers=None, raw=False, polling=True, **operation_config): + self, deployment_name, location, properties, custom_headers=None, raw=False, polling=True, **operation_config): """Deploys resources at tenant scope. You can provide the template and parameters directly in the request or @@ -824,11 +824,11 @@ def create_or_update_at_tenant_scope( :param deployment_name: The name of the deployment. :type deployment_name: str + :param location: The location to store the deployment data. + :type location: str :param properties: The deployment properties. :type properties: ~azure.mgmt.resource.resources.v2019_10_01.models.DeploymentProperties - :param location: The location to store the deployment data. - :type location: str :param dict custom_headers: headers that will be added to the request :param bool raw: The poller return type is ClientRawResponse, the direct response alongside the deserialized response @@ -844,8 +844,8 @@ def create_or_update_at_tenant_scope( """ raw_result = self._create_or_update_at_tenant_scope_initial( deployment_name=deployment_name, - properties=properties, location=location, + properties=properties, custom_headers=custom_headers, raw=True, **operation_config @@ -983,17 +983,17 @@ def cancel_at_tenant_scope( cancel_at_tenant_scope.metadata = {'url': '/providers/Microsoft.Resources/deployments/{deploymentName}/cancel'} def validate_at_tenant_scope( - self, deployment_name, properties, location=None, custom_headers=None, raw=False, **operation_config): + self, deployment_name, location, properties, custom_headers=None, raw=False, **operation_config): """Validates whether the specified template is syntactically correct and will be accepted by Azure Resource Manager.. :param deployment_name: The name of the deployment. :type deployment_name: str + :param location: The location to store the deployment data. + :type location: str :param properties: The deployment properties. :type properties: ~azure.mgmt.resource.resources.v2019_10_01.models.DeploymentProperties - :param location: The location to store the deployment data. - :type location: str :param dict custom_headers: headers that will be added to the request :param bool raw: returns the direct response alongside the deserialized response @@ -1005,7 +1005,7 @@ def validate_at_tenant_scope( or ~msrest.pipeline.ClientRawResponse :raises: :class:`CloudError` """ - parameters = models.Deployment(location=location, properties=properties) + parameters = models.ScopedDeployment(location=location, properties=properties) # Construct URL url = self.validate_at_tenant_scope.metadata['url'] @@ -1030,7 +1030,7 @@ def validate_at_tenant_scope( header_parameters['accept-language'] = self._serialize.header("self.config.accept_language", self.config.accept_language, 'str') # Construct body - body_content = self._serialize.body(parameters, 'Deployment') + body_content = self._serialize.body(parameters, 'ScopedDeployment') # Construct and send request request = self._client.post(url, query_parameters, header_parameters, body_content) @@ -1329,8 +1329,8 @@ def check_existence_at_management_group_scope( def _create_or_update_at_management_group_scope_initial( - self, group_id, deployment_name, properties, location=None, custom_headers=None, raw=False, **operation_config): - parameters = models.Deployment(location=location, properties=properties) + self, group_id, deployment_name, location, properties, custom_headers=None, raw=False, **operation_config): + parameters = models.ScopedDeployment(location=location, properties=properties) # Construct URL url = self.create_or_update_at_management_group_scope.metadata['url'] @@ -1356,7 +1356,7 @@ def _create_or_update_at_management_group_scope_initial( header_parameters['accept-language'] = self._serialize.header("self.config.accept_language", self.config.accept_language, 'str') # Construct body - body_content = self._serialize.body(parameters, 'Deployment') + body_content = self._serialize.body(parameters, 'ScopedDeployment') # Construct and send request request = self._client.put(url, query_parameters, header_parameters, body_content) @@ -1381,7 +1381,7 @@ def _create_or_update_at_management_group_scope_initial( return deserialized def create_or_update_at_management_group_scope( - self, group_id, deployment_name, properties, location=None, custom_headers=None, raw=False, polling=True, **operation_config): + self, group_id, deployment_name, location, properties, custom_headers=None, raw=False, polling=True, **operation_config): """Deploys resources at management group scope. You can provide the template and parameters directly in the request or @@ -1391,11 +1391,11 @@ def create_or_update_at_management_group_scope( :type group_id: str :param deployment_name: The name of the deployment. :type deployment_name: str + :param location: The location to store the deployment data. + :type location: str :param properties: The deployment properties. :type properties: ~azure.mgmt.resource.resources.v2019_10_01.models.DeploymentProperties - :param location: The location to store the deployment data. - :type location: str :param dict custom_headers: headers that will be added to the request :param bool raw: The poller return type is ClientRawResponse, the direct response alongside the deserialized response @@ -1412,8 +1412,8 @@ def create_or_update_at_management_group_scope( raw_result = self._create_or_update_at_management_group_scope_initial( group_id=group_id, deployment_name=deployment_name, - properties=properties, location=location, + properties=properties, custom_headers=custom_headers, raw=True, **operation_config @@ -1557,7 +1557,7 @@ def cancel_at_management_group_scope( cancel_at_management_group_scope.metadata = {'url': '/providers/Microsoft.Management/managementGroups/{groupId}/providers/Microsoft.Resources/deployments/{deploymentName}/cancel'} def validate_at_management_group_scope( - self, group_id, deployment_name, properties, location=None, custom_headers=None, raw=False, **operation_config): + self, group_id, deployment_name, location, properties, custom_headers=None, raw=False, **operation_config): """Validates whether the specified template is syntactically correct and will be accepted by Azure Resource Manager.. @@ -1565,11 +1565,11 @@ def validate_at_management_group_scope( :type group_id: str :param deployment_name: The name of the deployment. :type deployment_name: str + :param location: The location to store the deployment data. + :type location: str :param properties: The deployment properties. :type properties: ~azure.mgmt.resource.resources.v2019_10_01.models.DeploymentProperties - :param location: The location to store the deployment data. - :type location: str :param dict custom_headers: headers that will be added to the request :param bool raw: returns the direct response alongside the deserialized response @@ -1581,7 +1581,7 @@ def validate_at_management_group_scope( or ~msrest.pipeline.ClientRawResponse :raises: :class:`CloudError` """ - parameters = models.Deployment(location=location, properties=properties) + parameters = models.ScopedDeployment(location=location, properties=properties) # Construct URL url = self.validate_at_management_group_scope.metadata['url'] @@ -1607,7 +1607,7 @@ def validate_at_management_group_scope( header_parameters['accept-language'] = self._serialize.header("self.config.accept_language", self.config.accept_language, 'str') # Construct body - body_content = self._serialize.body(parameters, 'Deployment') + body_content = self._serialize.body(parameters, 'ScopedDeployment') # Construct and send request request = self._client.post(url, query_parameters, header_parameters, body_content) diff --git a/sdk/resources/azure-mgmt-resource/azure/mgmt/resource/resources/v2019_10_01/operations/_resources_operations.py b/sdk/resources/azure-mgmt-resource/azure/mgmt/resource/resources/v2019_10_01/operations/_resources_operations.py index 5f7f439be49d..fdf17d68a37a 100644 --- a/sdk/resources/azure-mgmt-resource/azure/mgmt/resource/resources/v2019_10_01/operations/_resources_operations.py +++ b/sdk/resources/azure-mgmt-resource/azure/mgmt/resource/resources/v2019_10_01/operations/_resources_operations.py @@ -61,10 +61,11 @@ def list_by_resource_group( $filter=substringof('demo', name)

You can link more than one substringof together by adding and/or operators.

You can filter by tag names and values. For example, to filter for a tag name and - value, use $filter=tagName eq 'tag1' and tagValue eq - 'Value1'

You can use some properties together when filtering. - The combinations you can use are: substringof and/or resourceType, - plan and plan/publisher and plan/name, identity and + value, use $filter=tagName eq 'tag1' and tagValue eq 'Value1'. When + you filter by a tag name and value, the tags for each resource are not + returned in the results.

You can use some properties together + when filtering. The combinations you can use are: substringof and/or + resourceType, plan and plan/publisher and plan/name, identity and identity/principalId. :type filter: str :param expand: The $expand query parameter. You can expand createdTime @@ -351,10 +352,11 @@ def list( $filter=substringof('demo', name)

You can link more than one substringof together by adding and/or operators.

You can filter by tag names and values. For example, to filter for a tag name and - value, use $filter=tagName eq 'tag1' and tagValue eq - 'Value1'

You can use some properties together when filtering. - The combinations you can use are: substringof and/or resourceType, - plan and plan/publisher and plan/name, identity and + value, use $filter=tagName eq 'tag1' and tagValue eq 'Value1'. When + you filter by a tag name and value, the tags for each resource are not + returned in the results.

You can use some properties together + when filtering. The combinations you can use are: substringof and/or + resourceType, plan and plan/publisher and plan/name, identity and identity/principalId. :type filter: str :param expand: The $expand query parameter. You can expand createdTime @@ -433,7 +435,7 @@ def internal_paging(next_link=None): list.metadata = {'url': '/subscriptions/{subscriptionId}/resources'} def check_existence( - self, resource_group_name, resource_provider_namespace, parent_resource_path, resource_type, resource_name, api_version, custom_headers=None, raw=False, **operation_config): + self, resource_group_name, resource_provider_namespace, parent_resource_path, resource_type, resource_name, custom_headers=None, raw=False, **operation_config): """Checks whether a resource exists. :param resource_group_name: The name of the resource group containing @@ -449,8 +451,6 @@ def check_existence( :param resource_name: The name of the resource to check whether it exists. :type resource_name: str - :param api_version: The API version to use for the operation. - :type api_version: str :param dict custom_headers: headers that will be added to the request :param bool raw: returns the direct response alongside the deserialized response @@ -474,7 +474,7 @@ def check_existence( # Construct parameters query_parameters = {} - query_parameters['api-version'] = self._serialize.query("api_version", api_version, 'str') + query_parameters['api-version'] = self._serialize.query("self.api_version", self.api_version, 'str') # Construct headers header_parameters = {} @@ -503,7 +503,7 @@ def check_existence( def _delete_initial( - self, resource_group_name, resource_provider_namespace, parent_resource_path, resource_type, resource_name, api_version, custom_headers=None, raw=False, **operation_config): + self, resource_group_name, resource_provider_namespace, parent_resource_path, resource_type, resource_name, custom_headers=None, raw=False, **operation_config): # Construct URL url = self.delete.metadata['url'] path_format_arguments = { @@ -518,7 +518,7 @@ def _delete_initial( # Construct parameters query_parameters = {} - query_parameters['api-version'] = self._serialize.query("api_version", api_version, 'str') + query_parameters['api-version'] = self._serialize.query("self.api_version", self.api_version, 'str') # Construct headers header_parameters = {} @@ -543,7 +543,7 @@ def _delete_initial( return client_raw_response def delete( - self, resource_group_name, resource_provider_namespace, parent_resource_path, resource_type, resource_name, api_version, custom_headers=None, raw=False, polling=True, **operation_config): + self, resource_group_name, resource_provider_namespace, parent_resource_path, resource_type, resource_name, custom_headers=None, raw=False, polling=True, **operation_config): """Deletes a resource. :param resource_group_name: The name of the resource group that @@ -558,8 +558,6 @@ def delete( :type resource_type: str :param resource_name: The name of the resource to delete. :type resource_name: str - :param api_version: The API version to use for the operation. - :type api_version: str :param dict custom_headers: headers that will be added to the request :param bool raw: The poller return type is ClientRawResponse, the direct response alongside the deserialized response @@ -577,7 +575,6 @@ def delete( parent_resource_path=parent_resource_path, resource_type=resource_type, resource_name=resource_name, - api_version=api_version, custom_headers=custom_headers, raw=True, **operation_config @@ -599,7 +596,7 @@ def get_long_running_output(response): def _create_or_update_initial( - self, resource_group_name, resource_provider_namespace, parent_resource_path, resource_type, resource_name, api_version, parameters, custom_headers=None, raw=False, **operation_config): + self, resource_group_name, resource_provider_namespace, parent_resource_path, resource_type, resource_name, parameters, custom_headers=None, raw=False, **operation_config): # Construct URL url = self.create_or_update.metadata['url'] path_format_arguments = { @@ -614,7 +611,7 @@ def _create_or_update_initial( # Construct parameters query_parameters = {} - query_parameters['api-version'] = self._serialize.query("api_version", api_version, 'str') + query_parameters['api-version'] = self._serialize.query("self.api_version", self.api_version, 'str') # Construct headers header_parameters = {} @@ -653,7 +650,7 @@ def _create_or_update_initial( return deserialized def create_or_update( - self, resource_group_name, resource_provider_namespace, parent_resource_path, resource_type, resource_name, api_version, parameters, custom_headers=None, raw=False, polling=True, **operation_config): + self, resource_group_name, resource_provider_namespace, parent_resource_path, resource_type, resource_name, parameters, custom_headers=None, raw=False, polling=True, **operation_config): """Creates a resource. :param resource_group_name: The name of the resource group for the @@ -668,8 +665,6 @@ def create_or_update( :type resource_type: str :param resource_name: The name of the resource to create. :type resource_name: str - :param api_version: The API version to use for the operation. - :type api_version: str :param parameters: Parameters for creating or updating the resource. :type parameters: ~azure.mgmt.resource.resources.v2019_10_01.models.GenericResource @@ -692,7 +687,6 @@ def create_or_update( parent_resource_path=parent_resource_path, resource_type=resource_type, resource_name=resource_name, - api_version=api_version, parameters=parameters, custom_headers=custom_headers, raw=True, @@ -719,7 +713,7 @@ def get_long_running_output(response): def _update_initial( - self, resource_group_name, resource_provider_namespace, parent_resource_path, resource_type, resource_name, api_version, parameters, custom_headers=None, raw=False, **operation_config): + self, resource_group_name, resource_provider_namespace, parent_resource_path, resource_type, resource_name, parameters, custom_headers=None, raw=False, **operation_config): # Construct URL url = self.update.metadata['url'] path_format_arguments = { @@ -734,7 +728,7 @@ def _update_initial( # Construct parameters query_parameters = {} - query_parameters['api-version'] = self._serialize.query("api_version", api_version, 'str') + query_parameters['api-version'] = self._serialize.query("self.api_version", self.api_version, 'str') # Construct headers header_parameters = {} @@ -771,7 +765,7 @@ def _update_initial( return deserialized def update( - self, resource_group_name, resource_provider_namespace, parent_resource_path, resource_type, resource_name, api_version, parameters, custom_headers=None, raw=False, polling=True, **operation_config): + self, resource_group_name, resource_provider_namespace, parent_resource_path, resource_type, resource_name, parameters, custom_headers=None, raw=False, polling=True, **operation_config): """Updates a resource. :param resource_group_name: The name of the resource group for the @@ -786,8 +780,6 @@ def update( :type resource_type: str :param resource_name: The name of the resource to update. :type resource_name: str - :param api_version: The API version to use for the operation. - :type api_version: str :param parameters: Parameters for updating the resource. :type parameters: ~azure.mgmt.resource.resources.v2019_10_01.models.GenericResource @@ -810,7 +802,6 @@ def update( parent_resource_path=parent_resource_path, resource_type=resource_type, resource_name=resource_name, - api_version=api_version, parameters=parameters, custom_headers=custom_headers, raw=True, @@ -836,7 +827,7 @@ def get_long_running_output(response): update.metadata = {'url': '/subscriptions/{subscriptionId}/resourcegroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{parentResourcePath}/{resourceType}/{resourceName}'} def get( - self, resource_group_name, resource_provider_namespace, parent_resource_path, resource_type, resource_name, api_version, custom_headers=None, raw=False, **operation_config): + self, resource_group_name, resource_provider_namespace, parent_resource_path, resource_type, resource_name, custom_headers=None, raw=False, **operation_config): """Gets a resource. :param resource_group_name: The name of the resource group containing @@ -851,8 +842,6 @@ def get( :type resource_type: str :param resource_name: The name of the resource to get. :type resource_name: str - :param api_version: The API version to use for the operation. - :type api_version: str :param dict custom_headers: headers that will be added to the request :param bool raw: returns the direct response alongside the deserialized response @@ -878,7 +867,7 @@ def get( # Construct parameters query_parameters = {} - query_parameters['api-version'] = self._serialize.query("api_version", api_version, 'str') + query_parameters['api-version'] = self._serialize.query("self.api_version", self.api_version, 'str') # Construct headers header_parameters = {} @@ -911,15 +900,13 @@ def get( get.metadata = {'url': '/subscriptions/{subscriptionId}/resourcegroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{parentResourcePath}/{resourceType}/{resourceName}'} def check_existence_by_id( - self, resource_id, api_version, custom_headers=None, raw=False, **operation_config): + self, resource_id, custom_headers=None, raw=False, **operation_config): """Checks by ID whether a resource exists. :param resource_id: The fully qualified ID of the resource, including the resource name and resource type. Use the format, /subscriptions/{guid}/resourceGroups/{resource-group-name}/{resource-provider-namespace}/{resource-type}/{resource-name} :type resource_id: str - :param api_version: The API version to use for the operation. - :type api_version: str :param dict custom_headers: headers that will be added to the request :param bool raw: returns the direct response alongside the deserialized response @@ -938,7 +925,7 @@ def check_existence_by_id( # Construct parameters query_parameters = {} - query_parameters['api-version'] = self._serialize.query("api_version", api_version, 'str') + query_parameters['api-version'] = self._serialize.query("self.api_version", self.api_version, 'str') # Construct headers header_parameters = {} @@ -967,7 +954,7 @@ def check_existence_by_id( def _delete_by_id_initial( - self, resource_id, api_version, custom_headers=None, raw=False, **operation_config): + self, resource_id, custom_headers=None, raw=False, **operation_config): # Construct URL url = self.delete_by_id.metadata['url'] path_format_arguments = { @@ -977,7 +964,7 @@ def _delete_by_id_initial( # Construct parameters query_parameters = {} - query_parameters['api-version'] = self._serialize.query("api_version", api_version, 'str') + query_parameters['api-version'] = self._serialize.query("self.api_version", self.api_version, 'str') # Construct headers header_parameters = {} @@ -1002,15 +989,13 @@ def _delete_by_id_initial( return client_raw_response def delete_by_id( - self, resource_id, api_version, custom_headers=None, raw=False, polling=True, **operation_config): + self, resource_id, custom_headers=None, raw=False, polling=True, **operation_config): """Deletes a resource by ID. :param resource_id: The fully qualified ID of the resource, including the resource name and resource type. Use the format, /subscriptions/{guid}/resourceGroups/{resource-group-name}/{resource-provider-namespace}/{resource-type}/{resource-name} :type resource_id: str - :param api_version: The API version to use for the operation. - :type api_version: str :param dict custom_headers: headers that will be added to the request :param bool raw: The poller return type is ClientRawResponse, the direct response alongside the deserialized response @@ -1024,7 +1009,6 @@ def delete_by_id( """ raw_result = self._delete_by_id_initial( resource_id=resource_id, - api_version=api_version, custom_headers=custom_headers, raw=True, **operation_config @@ -1046,7 +1030,7 @@ def get_long_running_output(response): def _create_or_update_by_id_initial( - self, resource_id, api_version, parameters, custom_headers=None, raw=False, **operation_config): + self, resource_id, parameters, custom_headers=None, raw=False, **operation_config): # Construct URL url = self.create_or_update_by_id.metadata['url'] path_format_arguments = { @@ -1056,7 +1040,7 @@ def _create_or_update_by_id_initial( # Construct parameters query_parameters = {} - query_parameters['api-version'] = self._serialize.query("api_version", api_version, 'str') + query_parameters['api-version'] = self._serialize.query("self.api_version", self.api_version, 'str') # Construct headers header_parameters = {} @@ -1095,15 +1079,13 @@ def _create_or_update_by_id_initial( return deserialized def create_or_update_by_id( - self, resource_id, api_version, parameters, custom_headers=None, raw=False, polling=True, **operation_config): + self, resource_id, parameters, custom_headers=None, raw=False, polling=True, **operation_config): """Create a resource by ID. :param resource_id: The fully qualified ID of the resource, including the resource name and resource type. Use the format, /subscriptions/{guid}/resourceGroups/{resource-group-name}/{resource-provider-namespace}/{resource-type}/{resource-name} :type resource_id: str - :param api_version: The API version to use for the operation. - :type api_version: str :param parameters: Create or update resource parameters. :type parameters: ~azure.mgmt.resource.resources.v2019_10_01.models.GenericResource @@ -1122,7 +1104,6 @@ def create_or_update_by_id( """ raw_result = self._create_or_update_by_id_initial( resource_id=resource_id, - api_version=api_version, parameters=parameters, custom_headers=custom_headers, raw=True, @@ -1149,7 +1130,7 @@ def get_long_running_output(response): def _update_by_id_initial( - self, resource_id, api_version, parameters, custom_headers=None, raw=False, **operation_config): + self, resource_id, parameters, custom_headers=None, raw=False, **operation_config): # Construct URL url = self.update_by_id.metadata['url'] path_format_arguments = { @@ -1159,7 +1140,7 @@ def _update_by_id_initial( # Construct parameters query_parameters = {} - query_parameters['api-version'] = self._serialize.query("api_version", api_version, 'str') + query_parameters['api-version'] = self._serialize.query("self.api_version", self.api_version, 'str') # Construct headers header_parameters = {} @@ -1196,15 +1177,13 @@ def _update_by_id_initial( return deserialized def update_by_id( - self, resource_id, api_version, parameters, custom_headers=None, raw=False, polling=True, **operation_config): + self, resource_id, parameters, custom_headers=None, raw=False, polling=True, **operation_config): """Updates a resource by ID. :param resource_id: The fully qualified ID of the resource, including the resource name and resource type. Use the format, /subscriptions/{guid}/resourceGroups/{resource-group-name}/{resource-provider-namespace}/{resource-type}/{resource-name} :type resource_id: str - :param api_version: The API version to use for the operation. - :type api_version: str :param parameters: Update resource parameters. :type parameters: ~azure.mgmt.resource.resources.v2019_10_01.models.GenericResource @@ -1223,7 +1202,6 @@ def update_by_id( """ raw_result = self._update_by_id_initial( resource_id=resource_id, - api_version=api_version, parameters=parameters, custom_headers=custom_headers, raw=True, @@ -1249,15 +1227,13 @@ def get_long_running_output(response): update_by_id.metadata = {'url': '/{resourceId}'} def get_by_id( - self, resource_id, api_version, custom_headers=None, raw=False, **operation_config): + self, resource_id, custom_headers=None, raw=False, **operation_config): """Gets a resource by ID. :param resource_id: The fully qualified ID of the resource, including the resource name and resource type. Use the format, /subscriptions/{guid}/resourceGroups/{resource-group-name}/{resource-provider-namespace}/{resource-type}/{resource-name} :type resource_id: str - :param api_version: The API version to use for the operation. - :type api_version: str :param dict custom_headers: headers that will be added to the request :param bool raw: returns the direct response alongside the deserialized response @@ -1278,7 +1254,7 @@ def get_by_id( # Construct parameters query_parameters = {} - query_parameters['api-version'] = self._serialize.query("api_version", api_version, 'str') + query_parameters['api-version'] = self._serialize.query("self.api_version", self.api_version, 'str') # Construct headers header_parameters = {} diff --git a/sdk/resources/azure-mgmt-resource/azure/mgmt/resource/subscriptions/_subscription_client.py b/sdk/resources/azure-mgmt-resource/azure/mgmt/resource/subscriptions/_subscription_client.py index d594f287777f..f3e3cf240e23 100644 --- a/sdk/resources/azure-mgmt-resource/azure/mgmt/resource/subscriptions/_subscription_client.py +++ b/sdk/resources/azure-mgmt-resource/azure/mgmt/resource/subscriptions/_subscription_client.py @@ -42,7 +42,7 @@ class SubscriptionClient(MultiApiClientMixin, SDKClient): :type profile: azure.profiles.KnownProfiles """ - DEFAULT_API_VERSION = '2018-06-01' + DEFAULT_API_VERSION = '2019-06-01' _PROFILE_TAG = "azure.mgmt.resource.subscriptions.SubscriptionClient" LATEST_PROFILE = ProfileDefinition({ _PROFILE_TAG: { @@ -70,6 +70,7 @@ def models(cls, api_version=DEFAULT_API_VERSION): * 2016-06-01: :mod:`v2016_06_01.models` * 2018-06-01: :mod:`v2018_06_01.models` + * 2019-06-01: :mod:`v2019_06_01.models` """ if api_version == '2016-06-01': from .v2016_06_01 import models @@ -77,6 +78,9 @@ def models(cls, api_version=DEFAULT_API_VERSION): elif api_version == '2018-06-01': from .v2018_06_01 import models return models + elif api_version == '2019-06-01': + from .v2019_06_01 import models + return models raise NotImplementedError("APIVersion {} is not available".format(api_version)) @property @@ -85,12 +89,15 @@ def operations(self): * 2016-06-01: :class:`Operations` * 2018-06-01: :class:`Operations` + * 2019-06-01: :class:`Operations` """ api_version = self._get_api_version('operations') if api_version == '2016-06-01': from .v2016_06_01.operations import Operations as OperationClass elif api_version == '2018-06-01': from .v2018_06_01.operations import Operations as OperationClass + elif api_version == '2019-06-01': + from .v2019_06_01.operations import Operations as OperationClass else: raise NotImplementedError("APIVersion {} is not available".format(api_version)) return OperationClass(self._client, self.config, Serializer(self._models_dict(api_version)), Deserializer(self._models_dict(api_version))) @@ -101,12 +108,15 @@ def subscriptions(self): * 2016-06-01: :class:`SubscriptionsOperations` * 2018-06-01: :class:`SubscriptionsOperations` + * 2019-06-01: :class:`SubscriptionsOperations` """ api_version = self._get_api_version('subscriptions') if api_version == '2016-06-01': from .v2016_06_01.operations import SubscriptionsOperations as OperationClass elif api_version == '2018-06-01': from .v2018_06_01.operations import SubscriptionsOperations as OperationClass + elif api_version == '2019-06-01': + from .v2019_06_01.operations import SubscriptionsOperations as OperationClass else: raise NotImplementedError("APIVersion {} is not available".format(api_version)) return OperationClass(self._client, self.config, Serializer(self._models_dict(api_version)), Deserializer(self._models_dict(api_version))) @@ -117,12 +127,15 @@ def tenants(self): * 2016-06-01: :class:`TenantsOperations` * 2018-06-01: :class:`TenantsOperations` + * 2019-06-01: :class:`TenantsOperations` """ api_version = self._get_api_version('tenants') if api_version == '2016-06-01': from .v2016_06_01.operations import TenantsOperations as OperationClass elif api_version == '2018-06-01': from .v2018_06_01.operations import TenantsOperations as OperationClass + elif api_version == '2019-06-01': + from .v2019_06_01.operations import TenantsOperations as OperationClass else: raise NotImplementedError("APIVersion {} is not available".format(api_version)) return OperationClass(self._client, self.config, Serializer(self._models_dict(api_version)), Deserializer(self._models_dict(api_version))) diff --git a/sdk/resources/azure-mgmt-resource/azure/mgmt/resource/subscriptions/models.py b/sdk/resources/azure-mgmt-resource/azure/mgmt/resource/subscriptions/models.py index 1c47d132a679..e14bb6e177c2 100644 --- a/sdk/resources/azure-mgmt-resource/azure/mgmt/resource/subscriptions/models.py +++ b/sdk/resources/azure-mgmt-resource/azure/mgmt/resource/subscriptions/models.py @@ -4,4 +4,4 @@ # Licensed under the MIT License. See License.txt in the project root for # license information. # -------------------------------------------------------------------------- -from .v2018_06_01.models import * +from .v2019_06_01.models import *