From 6635aea317e5e142fd45d4bc4845012fae95cc2c Mon Sep 17 00:00:00 2001 From: Azure SDK for Python bot Date: Thu, 12 Apr 2018 14:09:07 -0700 Subject: [PATCH] [AutoPR web/resource-manager] Adding new API version for Microsoft.Web RP which fixes swagger errors (#2340) * Generated from 574e458be59a062c8af950ba83768ea41095a1d2 Fixing API version in the examples * Generated from 8957477812a8f2abbc895a363756062be9f2ca45 Removed location element for top level domain examples --- .../models/default_error_response_error.py | 4 +- ...fault_error_response_error_details_item.py | 4 +- .../web/operations/web_apps_operations.py | 58 ++----------------- 3 files changed, 8 insertions(+), 58 deletions(-) diff --git a/azure-mgmt-web/azure/mgmt/web/models/default_error_response_error.py b/azure-mgmt-web/azure/mgmt/web/models/default_error_response_error.py index c12f968877e1..a310e52fd21b 100644 --- a/azure-mgmt-web/azure/mgmt/web/models/default_error_response_error.py +++ b/azure-mgmt-web/azure/mgmt/web/models/default_error_response_error.py @@ -32,8 +32,8 @@ class DefaultErrorResponseError(Model): """ _validation = { - 'code': {'required': True, 'readonly': True}, - 'message': {'required': True, 'readonly': True}, + 'code': {'readonly': True}, + 'message': {'readonly': True}, 'target': {'readonly': True}, 'innererror': {'readonly': True}, } diff --git a/azure-mgmt-web/azure/mgmt/web/models/default_error_response_error_details_item.py b/azure-mgmt-web/azure/mgmt/web/models/default_error_response_error_details_item.py index bb0a260d8c93..7434138df870 100644 --- a/azure-mgmt-web/azure/mgmt/web/models/default_error_response_error_details_item.py +++ b/azure-mgmt-web/azure/mgmt/web/models/default_error_response_error_details_item.py @@ -27,8 +27,8 @@ class DefaultErrorResponseErrorDetailsItem(Model): """ _validation = { - 'code': {'required': True, 'readonly': True}, - 'message': {'required': True, 'readonly': True}, + 'code': {'readonly': True}, + 'message': {'readonly': True}, 'target': {'readonly': True}, } diff --git a/azure-mgmt-web/azure/mgmt/web/operations/web_apps_operations.py b/azure-mgmt-web/azure/mgmt/web/operations/web_apps_operations.py index 3bf64d3266ad..1d1bb5d4bb57 100644 --- a/azure-mgmt-web/azure/mgmt/web/operations/web_apps_operations.py +++ b/azure-mgmt-web/azure/mgmt/web/operations/web_apps_operations.py @@ -248,7 +248,7 @@ def get( def _create_or_update_initial( - self, resource_group_name, name, site_envelope, skip_dns_registration=None, skip_custom_domain_verification=None, force_dns_registration=None, ttl_in_seconds=None, custom_headers=None, raw=False, **operation_config): + self, resource_group_name, name, site_envelope, custom_headers=None, raw=False, **operation_config): # Construct URL url = self.create_or_update.metadata['url'] path_format_arguments = { @@ -260,14 +260,6 @@ def _create_or_update_initial( # Construct parameters query_parameters = {} - if skip_dns_registration is not None: - query_parameters['skipDnsRegistration'] = self._serialize.query("skip_dns_registration", skip_dns_registration, 'bool') - if skip_custom_domain_verification is not None: - query_parameters['skipCustomDomainVerification'] = self._serialize.query("skip_custom_domain_verification", skip_custom_domain_verification, 'bool') - if force_dns_registration is not None: - query_parameters['forceDnsRegistration'] = self._serialize.query("force_dns_registration", force_dns_registration, 'bool') - if ttl_in_seconds is not None: - query_parameters['ttlInSeconds'] = self._serialize.query("ttl_in_seconds", ttl_in_seconds, 'str') query_parameters['api-version'] = self._serialize.query("self.api_version", self.api_version, 'str') # Construct headers @@ -307,7 +299,7 @@ def _create_or_update_initial( return deserialized def create_or_update( - self, resource_group_name, name, site_envelope, skip_dns_registration=None, skip_custom_domain_verification=None, force_dns_registration=None, ttl_in_seconds=None, custom_headers=None, raw=False, **operation_config): + self, resource_group_name, name, site_envelope, custom_headers=None, raw=False, **operation_config): """Creates a new web, mobile, or API app in an existing resource group, or updates an existing app. @@ -323,19 +315,6 @@ def create_or_update( :param site_envelope: A JSON representation of the app properties. See example. :type site_envelope: ~azure.mgmt.web.models.Site - :param skip_dns_registration: If true web app hostname is not - registered with DNS on creation. This parameter is - only used for app creation. - :type skip_dns_registration: bool - :param skip_custom_domain_verification: If true, custom (non - *.azurewebsites.net) domains associated with web app are not verified. - :type skip_custom_domain_verification: bool - :param force_dns_registration: If true, web app hostname is force - registered with DNS. - :type force_dns_registration: bool - :param ttl_in_seconds: Time to live in seconds for web app's default - domain name. - :type ttl_in_seconds: str :param dict custom_headers: headers that will be added to the request :param bool raw: returns the direct response alongside the deserialized response @@ -350,10 +329,6 @@ def create_or_update( resource_group_name=resource_group_name, name=name, site_envelope=site_envelope, - skip_dns_registration=skip_dns_registration, - skip_custom_domain_verification=skip_custom_domain_verification, - force_dns_registration=force_dns_registration, - ttl_in_seconds=ttl_in_seconds, custom_headers=custom_headers, raw=True, **operation_config @@ -399,7 +374,7 @@ def get_long_running_output(response): create_or_update.metadata = {'url': '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}'} def delete( - self, resource_group_name, name, delete_metrics=None, delete_empty_server_farm=None, skip_dns_registration=None, custom_headers=None, raw=False, **operation_config): + self, resource_group_name, name, delete_metrics=None, delete_empty_server_farm=None, custom_headers=None, raw=False, **operation_config): """Deletes a web, mobile, or API app, or one of the deployment slots. Deletes a web, mobile, or API app, or one of the deployment slots. @@ -415,8 +390,6 @@ def delete( will be empty after app deletion and you want to delete the empty App Service plan. By default, the empty App Service plan is not deleted. :type delete_empty_server_farm: bool - :param skip_dns_registration: If true, DNS registration is skipped. - :type skip_dns_registration: bool :param dict custom_headers: headers that will be added to the request :param bool raw: returns the direct response alongside the deserialized response @@ -441,8 +414,6 @@ def delete( query_parameters['deleteMetrics'] = self._serialize.query("delete_metrics", delete_metrics, 'bool') if delete_empty_server_farm is not None: query_parameters['deleteEmptyServerFarm'] = self._serialize.query("delete_empty_server_farm", delete_empty_server_farm, 'bool') - if skip_dns_registration is not None: - query_parameters['skipDnsRegistration'] = self._serialize.query("skip_dns_registration", skip_dns_registration, 'bool') query_parameters['api-version'] = self._serialize.query("self.api_version", self.api_version, 'str') # Construct headers @@ -470,7 +441,7 @@ def delete( delete.metadata = {'url': '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}'} def update( - self, resource_group_name, name, site_envelope, skip_dns_registration=None, skip_custom_domain_verification=None, force_dns_registration=None, ttl_in_seconds=None, custom_headers=None, raw=False, **operation_config): + self, resource_group_name, name, site_envelope, custom_headers=None, raw=False, **operation_config): """Creates a new web, mobile, or API app in an existing resource group, or updates an existing app. @@ -486,19 +457,6 @@ def update( :param site_envelope: A JSON representation of the app properties. See example. :type site_envelope: ~azure.mgmt.web.models.SitePatchResource - :param skip_dns_registration: If true web app hostname is not - registered with DNS on creation. This parameter is - only used for app creation. - :type skip_dns_registration: bool - :param skip_custom_domain_verification: If true, custom (non - *.azurewebsites.net) domains associated with web app are not verified. - :type skip_custom_domain_verification: bool - :param force_dns_registration: If true, web app hostname is force - registered with DNS. - :type force_dns_registration: bool - :param ttl_in_seconds: Time to live in seconds for web app's default - domain name. - :type ttl_in_seconds: str :param dict custom_headers: headers that will be added to the request :param bool raw: returns the direct response alongside the deserialized response @@ -520,14 +478,6 @@ def update( # Construct parameters query_parameters = {} - if skip_dns_registration is not None: - query_parameters['skipDnsRegistration'] = self._serialize.query("skip_dns_registration", skip_dns_registration, 'bool') - if skip_custom_domain_verification is not None: - query_parameters['skipCustomDomainVerification'] = self._serialize.query("skip_custom_domain_verification", skip_custom_domain_verification, 'bool') - if force_dns_registration is not None: - query_parameters['forceDnsRegistration'] = self._serialize.query("force_dns_registration", force_dns_registration, 'bool') - if ttl_in_seconds is not None: - query_parameters['ttlInSeconds'] = self._serialize.query("ttl_in_seconds", ttl_in_seconds, 'str') query_parameters['api-version'] = self._serialize.query("self.api_version", self.api_version, 'str') # Construct headers