diff --git a/azure-mgmt-apimanagement/azure/mgmt/apimanagement/api_management_client.py b/azure-mgmt-apimanagement/azure/mgmt/apimanagement/api_management_client.py index d801ba354280..8fbad986b5e9 100644 --- a/azure-mgmt-apimanagement/azure/mgmt/apimanagement/api_management_client.py +++ b/azure-mgmt-apimanagement/azure/mgmt/apimanagement/api_management_client.py @@ -25,6 +25,7 @@ from .operations.api_policy_operations import ApiPolicyOperations from .operations.api_schema_operations import ApiSchemaOperations from .operations.api_diagnostic_operations import ApiDiagnosticOperations +from .operations.api_diagnostic_logger_operations import ApiDiagnosticLoggerOperations from .operations.api_issue_operations import ApiIssueOperations from .operations.api_issue_comment_operations import ApiIssueCommentOperations from .operations.api_issue_attachment_operations import ApiIssueAttachmentOperations @@ -34,6 +35,7 @@ from .operations.api_management_operations import ApiManagementOperations from .operations.api_management_service_operations import ApiManagementServiceOperations from .operations.diagnostic_operations import DiagnosticOperations +from .operations.diagnostic_logger_operations import DiagnosticLoggerOperations from .operations.email_template_operations import EmailTemplateOperations from .operations.group_operations import GroupOperations from .operations.group_user_operations import GroupUserOperations @@ -137,6 +139,8 @@ class ApiManagementClient(SDKClient): :vartype api_schema: azure.mgmt.apimanagement.operations.ApiSchemaOperations :ivar api_diagnostic: ApiDiagnostic operations :vartype api_diagnostic: azure.mgmt.apimanagement.operations.ApiDiagnosticOperations + :ivar api_diagnostic_logger: ApiDiagnosticLogger operations + :vartype api_diagnostic_logger: azure.mgmt.apimanagement.operations.ApiDiagnosticLoggerOperations :ivar api_issue: ApiIssue operations :vartype api_issue: azure.mgmt.apimanagement.operations.ApiIssueOperations :ivar api_issue_comment: ApiIssueComment operations @@ -155,6 +159,8 @@ class ApiManagementClient(SDKClient): :vartype api_management_service: azure.mgmt.apimanagement.operations.ApiManagementServiceOperations :ivar diagnostic: Diagnostic operations :vartype diagnostic: azure.mgmt.apimanagement.operations.DiagnosticOperations + :ivar diagnostic_logger: DiagnosticLogger operations + :vartype diagnostic_logger: azure.mgmt.apimanagement.operations.DiagnosticLoggerOperations :ivar email_template: EmailTemplate operations :vartype email_template: azure.mgmt.apimanagement.operations.EmailTemplateOperations :ivar group: Group operations @@ -245,7 +251,7 @@ def __init__( super(ApiManagementClient, self).__init__(self.config.credentials, self.config) client_models = {k: v for k, v in models.__dict__.items() if isinstance(v, type)} - self.api_version = '2018-06-01-preview' + self.api_version = '2018-01-01' self._serialize = Serializer(client_models) self._deserialize = Deserializer(client_models) @@ -273,6 +279,8 @@ def __init__( self._client, self.config, self._serialize, self._deserialize) self.api_diagnostic = ApiDiagnosticOperations( self._client, self.config, self._serialize, self._deserialize) + self.api_diagnostic_logger = ApiDiagnosticLoggerOperations( + self._client, self.config, self._serialize, self._deserialize) self.api_issue = ApiIssueOperations( self._client, self.config, self._serialize, self._deserialize) self.api_issue_comment = ApiIssueCommentOperations( @@ -291,6 +299,8 @@ def __init__( self._client, self.config, self._serialize, self._deserialize) self.diagnostic = DiagnosticOperations( self._client, self.config, self._serialize, self._deserialize) + self.diagnostic_logger = DiagnosticLoggerOperations( + self._client, self.config, self._serialize, self._deserialize) self.email_template = EmailTemplateOperations( self._client, self.config, self._serialize, self._deserialize) self.group = GroupOperations( diff --git a/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/__init__.py b/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/__init__.py index d73cb1b6d680..a1fc918799ac 100644 --- a/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/__init__.py +++ b/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/__init__.py @@ -44,10 +44,7 @@ from .issue_contract_py3 import IssueContract from .issue_comment_contract_py3 import IssueCommentContract from .issue_attachment_contract_py3 import IssueAttachmentContract - from .body_diagnostic_settings_py3 import BodyDiagnosticSettings - from .http_message_diagnostic_py3 import HttpMessageDiagnostic - from .pipeline_diagnostic_settings_py3 import PipelineDiagnosticSettings - from .sampling_settings_py3 import SamplingSettings + from .logger_contract_py3 import LoggerContract from .diagnostic_contract_py3 import DiagnosticContract from .product_entity_base_parameters_py3 import ProductEntityBaseParameters from .product_tag_resource_contract_properties_py3 import ProductTagResourceContractProperties @@ -107,7 +104,6 @@ from .identity_provider_contract_py3 import IdentityProviderContract from .identity_provider_update_parameters_py3 import IdentityProviderUpdateParameters from .identity_provider_base_parameters_py3 import IdentityProviderBaseParameters - from .logger_contract_py3 import LoggerContract from .logger_update_contract_py3 import LoggerUpdateContract from .recipients_contract_properties_py3 import RecipientsContractProperties from .notification_contract_py3 import NotificationContract @@ -193,10 +189,7 @@ from .issue_contract import IssueContract from .issue_comment_contract import IssueCommentContract from .issue_attachment_contract import IssueAttachmentContract - from .body_diagnostic_settings import BodyDiagnosticSettings - from .http_message_diagnostic import HttpMessageDiagnostic - from .pipeline_diagnostic_settings import PipelineDiagnosticSettings - from .sampling_settings import SamplingSettings + from .logger_contract import LoggerContract from .diagnostic_contract import DiagnosticContract from .product_entity_base_parameters import ProductEntityBaseParameters from .product_tag_resource_contract_properties import ProductTagResourceContractProperties @@ -256,7 +249,6 @@ from .identity_provider_contract import IdentityProviderContract from .identity_provider_update_parameters import IdentityProviderUpdateParameters from .identity_provider_base_parameters import IdentityProviderBaseParameters - from .logger_contract import LoggerContract from .logger_update_contract import LoggerUpdateContract from .recipients_contract_properties import RecipientsContractProperties from .notification_contract import NotificationContract @@ -316,6 +308,7 @@ from .product_contract_paged import ProductContractPaged from .schema_contract_paged import SchemaContractPaged from .diagnostic_contract_paged import DiagnosticContractPaged +from .logger_contract_paged import LoggerContractPaged from .issue_contract_paged import IssueContractPaged from .issue_comment_contract_paged import IssueCommentContractPaged from .issue_attachment_contract_paged import IssueAttachmentContractPaged @@ -328,7 +321,6 @@ from .group_contract_paged import GroupContractPaged from .user_contract_paged import UserContractPaged from .identity_provider_contract_paged import IdentityProviderContractPaged -from .logger_contract_paged import LoggerContractPaged from .notification_contract_paged import NotificationContractPaged from .openid_connect_provider_contract_paged import OpenidConnectProviderContractPaged from .subscription_contract_paged import SubscriptionContractPaged @@ -346,8 +338,7 @@ SoapApiType, ApiType, State, - SamplingType, - AlwaysLog, + LoggerType, ProductState, GrantType, AuthorizationMethod, @@ -362,7 +353,6 @@ Confirmation, UserState, IdentityProviderType, - LoggerType, ConnectivityStatusType, SubscriptionState, AsyncOperationStatus, @@ -409,10 +399,7 @@ 'IssueContract', 'IssueCommentContract', 'IssueAttachmentContract', - 'BodyDiagnosticSettings', - 'HttpMessageDiagnostic', - 'PipelineDiagnosticSettings', - 'SamplingSettings', + 'LoggerContract', 'DiagnosticContract', 'ProductEntityBaseParameters', 'ProductTagResourceContractProperties', @@ -472,7 +459,6 @@ 'IdentityProviderContract', 'IdentityProviderUpdateParameters', 'IdentityProviderBaseParameters', - 'LoggerContract', 'LoggerUpdateContract', 'RecipientsContractProperties', 'NotificationContract', @@ -532,6 +518,7 @@ 'ProductContractPaged', 'SchemaContractPaged', 'DiagnosticContractPaged', + 'LoggerContractPaged', 'IssueContractPaged', 'IssueCommentContractPaged', 'IssueAttachmentContractPaged', @@ -544,7 +531,6 @@ 'GroupContractPaged', 'UserContractPaged', 'IdentityProviderContractPaged', - 'LoggerContractPaged', 'NotificationContractPaged', 'OpenidConnectProviderContractPaged', 'SubscriptionContractPaged', @@ -561,8 +547,7 @@ 'SoapApiType', 'ApiType', 'State', - 'SamplingType', - 'AlwaysLog', + 'LoggerType', 'ProductState', 'GrantType', 'AuthorizationMethod', @@ -577,7 +562,6 @@ 'Confirmation', 'UserState', 'IdentityProviderType', - 'LoggerType', 'ConnectivityStatusType', 'SubscriptionState', 'AsyncOperationStatus', diff --git a/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/api_management_client_enums.py b/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/api_management_client_enums.py index f52ede0050c3..3cffd1387ec5 100644 --- a/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/api_management_client_enums.py +++ b/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/api_management_client_enums.py @@ -57,14 +57,10 @@ class State(str, Enum): closed = "closed" #: The issue was closed. -class SamplingType(str, Enum): - - fixed = "fixed" #: Fixed-rate sampling. - - -class AlwaysLog(str, Enum): +class LoggerType(str, Enum): - all_errors = "allErrors" #: Always log all erroneous request regardless of sampling settings. + azure_event_hub = "azureEventHub" #: Azure Event Hub as log destination. + application_insights = "applicationInsights" #: Azure Application Insights as log destination. class ProductState(str, Enum): @@ -172,12 +168,6 @@ class IdentityProviderType(str, Enum): aad_b2_c = "aadB2C" #: Azure Active Directory B2C as Identity provider. -class LoggerType(str, Enum): - - azure_event_hub = "azureEventHub" #: Azure Event Hub as log destination. - application_insights = "applicationInsights" #: Azure Application Insights as log destination. - - class ConnectivityStatusType(str, Enum): initializing = "initializing" diff --git a/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/body_diagnostic_settings.py b/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/body_diagnostic_settings.py deleted file mode 100644 index b0f9021fbada..000000000000 --- a/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/body_diagnostic_settings.py +++ /dev/null @@ -1,32 +0,0 @@ -# coding=utf-8 -# -------------------------------------------------------------------------- -# Copyright (c) Microsoft Corporation. All rights reserved. -# Licensed under the MIT License. See License.txt in the project root for -# license information. -# -# Code generated by Microsoft (R) AutoRest Code Generator. -# Changes may cause incorrect behavior and will be lost if the code is -# regenerated. -# -------------------------------------------------------------------------- - -from msrest.serialization import Model - - -class BodyDiagnosticSettings(Model): - """Body logging settings. - - :param bytes: Number of request body bytes to log. - :type bytes: int - """ - - _validation = { - 'bytes': {'maximum': 8192}, - } - - _attribute_map = { - 'bytes': {'key': 'bytes', 'type': 'int'}, - } - - def __init__(self, **kwargs): - super(BodyDiagnosticSettings, self).__init__(**kwargs) - self.bytes = kwargs.get('bytes', None) diff --git a/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/body_diagnostic_settings_py3.py b/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/body_diagnostic_settings_py3.py deleted file mode 100644 index 4192e4a3dc58..000000000000 --- a/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/body_diagnostic_settings_py3.py +++ /dev/null @@ -1,32 +0,0 @@ -# coding=utf-8 -# -------------------------------------------------------------------------- -# Copyright (c) Microsoft Corporation. All rights reserved. -# Licensed under the MIT License. See License.txt in the project root for -# license information. -# -# Code generated by Microsoft (R) AutoRest Code Generator. -# Changes may cause incorrect behavior and will be lost if the code is -# regenerated. -# -------------------------------------------------------------------------- - -from msrest.serialization import Model - - -class BodyDiagnosticSettings(Model): - """Body logging settings. - - :param bytes: Number of request body bytes to log. - :type bytes: int - """ - - _validation = { - 'bytes': {'maximum': 8192}, - } - - _attribute_map = { - 'bytes': {'key': 'bytes', 'type': 'int'}, - } - - def __init__(self, *, bytes: int=None, **kwargs) -> None: - super(BodyDiagnosticSettings, self).__init__(**kwargs) - self.bytes = bytes diff --git a/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/diagnostic_contract.py b/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/diagnostic_contract.py index dd8d2db36a1c..323523836bbc 100644 --- a/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/diagnostic_contract.py +++ b/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/diagnostic_contract.py @@ -26,44 +26,25 @@ class DiagnosticContract(Resource): :vartype name: str :ivar type: Resource type for API Management resource. :vartype type: str - :param always_log: Specifies for what type of messages sampling settings - should not apply. Possible values include: 'allErrors' - :type always_log: str or ~azure.mgmt.apimanagement.models.AlwaysLog - :param logger_id: Required. Resource Id of a target logger. - :type logger_id: str - :param sampling: Sampling settings for Diagnostic. - :type sampling: ~azure.mgmt.apimanagement.models.SamplingSettings - :param frontend: Diagnostic settings for incoming/outcoming HTTP messages - to the Gateway. - :type frontend: - ~azure.mgmt.apimanagement.models.PipelineDiagnosticSettings - :param backend: Diagnostic settings for incoming/outcoming HTTP messages - to the Backend - :type backend: ~azure.mgmt.apimanagement.models.PipelineDiagnosticSettings + :param enabled: Required. Indicates whether a diagnostic should receive + data or not. + :type enabled: bool """ _validation = { 'id': {'readonly': True}, 'name': {'readonly': True}, 'type': {'readonly': True}, - 'logger_id': {'required': True}, + 'enabled': {'required': True}, } _attribute_map = { 'id': {'key': 'id', 'type': 'str'}, 'name': {'key': 'name', 'type': 'str'}, 'type': {'key': 'type', 'type': 'str'}, - 'always_log': {'key': 'properties.alwaysLog', 'type': 'str'}, - 'logger_id': {'key': 'properties.loggerId', 'type': 'str'}, - 'sampling': {'key': 'properties.sampling', 'type': 'SamplingSettings'}, - 'frontend': {'key': 'properties.frontend', 'type': 'PipelineDiagnosticSettings'}, - 'backend': {'key': 'properties.backend', 'type': 'PipelineDiagnosticSettings'}, + 'enabled': {'key': 'properties.enabled', 'type': 'bool'}, } def __init__(self, **kwargs): super(DiagnosticContract, self).__init__(**kwargs) - self.always_log = kwargs.get('always_log', None) - self.logger_id = kwargs.get('logger_id', None) - self.sampling = kwargs.get('sampling', None) - self.frontend = kwargs.get('frontend', None) - self.backend = kwargs.get('backend', None) + self.enabled = kwargs.get('enabled', None) diff --git a/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/diagnostic_contract_py3.py b/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/diagnostic_contract_py3.py index a6dbcbfe3318..4b1236737bcf 100644 --- a/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/diagnostic_contract_py3.py +++ b/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/diagnostic_contract_py3.py @@ -26,44 +26,25 @@ class DiagnosticContract(Resource): :vartype name: str :ivar type: Resource type for API Management resource. :vartype type: str - :param always_log: Specifies for what type of messages sampling settings - should not apply. Possible values include: 'allErrors' - :type always_log: str or ~azure.mgmt.apimanagement.models.AlwaysLog - :param logger_id: Required. Resource Id of a target logger. - :type logger_id: str - :param sampling: Sampling settings for Diagnostic. - :type sampling: ~azure.mgmt.apimanagement.models.SamplingSettings - :param frontend: Diagnostic settings for incoming/outcoming HTTP messages - to the Gateway. - :type frontend: - ~azure.mgmt.apimanagement.models.PipelineDiagnosticSettings - :param backend: Diagnostic settings for incoming/outcoming HTTP messages - to the Backend - :type backend: ~azure.mgmt.apimanagement.models.PipelineDiagnosticSettings + :param enabled: Required. Indicates whether a diagnostic should receive + data or not. + :type enabled: bool """ _validation = { 'id': {'readonly': True}, 'name': {'readonly': True}, 'type': {'readonly': True}, - 'logger_id': {'required': True}, + 'enabled': {'required': True}, } _attribute_map = { 'id': {'key': 'id', 'type': 'str'}, 'name': {'key': 'name', 'type': 'str'}, 'type': {'key': 'type', 'type': 'str'}, - 'always_log': {'key': 'properties.alwaysLog', 'type': 'str'}, - 'logger_id': {'key': 'properties.loggerId', 'type': 'str'}, - 'sampling': {'key': 'properties.sampling', 'type': 'SamplingSettings'}, - 'frontend': {'key': 'properties.frontend', 'type': 'PipelineDiagnosticSettings'}, - 'backend': {'key': 'properties.backend', 'type': 'PipelineDiagnosticSettings'}, + 'enabled': {'key': 'properties.enabled', 'type': 'bool'}, } - def __init__(self, *, logger_id: str, always_log=None, sampling=None, frontend=None, backend=None, **kwargs) -> None: + def __init__(self, *, enabled: bool, **kwargs) -> None: super(DiagnosticContract, self).__init__(**kwargs) - self.always_log = always_log - self.logger_id = logger_id - self.sampling = sampling - self.frontend = frontend - self.backend = backend + self.enabled = enabled diff --git a/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/group_contract.py b/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/group_contract.py index 89aad685c1e5..402856cb4021 100644 --- a/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/group_contract.py +++ b/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/group_contract.py @@ -39,7 +39,7 @@ class GroupContract(Resource): ~azure.mgmt.apimanagement.models.GroupType :param external_id: For external groups, this property contains the id of the group from the external identity provider, e.g. for Azure Active - Directory `aad://.onmicrosoft.com/groups/`; + Directory aad://.onmicrosoft.com/groups/; otherwise the value is null. :type external_id: str """ diff --git a/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/group_contract_properties.py b/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/group_contract_properties.py index a6cda94f8805..afc509e6305d 100644 --- a/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/group_contract_properties.py +++ b/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/group_contract_properties.py @@ -32,7 +32,7 @@ class GroupContractProperties(Model): :type type: str or ~azure.mgmt.apimanagement.models.GroupType :param external_id: For external groups, this property contains the id of the group from the external identity provider, e.g. for Azure Active - Directory `aad://.onmicrosoft.com/groups/`; + Directory aad://.onmicrosoft.com/groups/; otherwise the value is null. :type external_id: str """ diff --git a/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/group_contract_properties_py3.py b/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/group_contract_properties_py3.py index ab604b4e419b..ea1ff22a7932 100644 --- a/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/group_contract_properties_py3.py +++ b/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/group_contract_properties_py3.py @@ -32,7 +32,7 @@ class GroupContractProperties(Model): :type type: str or ~azure.mgmt.apimanagement.models.GroupType :param external_id: For external groups, this property contains the id of the group from the external identity provider, e.g. for Azure Active - Directory `aad://.onmicrosoft.com/groups/`; + Directory aad://.onmicrosoft.com/groups/; otherwise the value is null. :type external_id: str """ diff --git a/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/group_contract_py3.py b/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/group_contract_py3.py index 5b2c78fbc9f4..89d02fafe9fa 100644 --- a/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/group_contract_py3.py +++ b/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/group_contract_py3.py @@ -39,7 +39,7 @@ class GroupContract(Resource): ~azure.mgmt.apimanagement.models.GroupType :param external_id: For external groups, this property contains the id of the group from the external identity provider, e.g. for Azure Active - Directory `aad://.onmicrosoft.com/groups/`; + Directory aad://.onmicrosoft.com/groups/; otherwise the value is null. :type external_id: str """ diff --git a/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/group_create_parameters.py b/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/group_create_parameters.py index eeb0f54e9854..81c6d9664912 100644 --- a/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/group_create_parameters.py +++ b/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/group_create_parameters.py @@ -26,8 +26,8 @@ class GroupCreateParameters(Model): :type type: str or ~azure.mgmt.apimanagement.models.GroupType :param external_id: Identifier of the external groups, this property contains the id of the group from the external identity provider, e.g. for - Azure Active Directory `aad://.onmicrosoft.com/groups/`; otherwise the value is null. + Azure Active Directory aad://.onmicrosoft.com/groups/; otherwise the value is null. :type external_id: str """ diff --git a/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/group_create_parameters_py3.py b/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/group_create_parameters_py3.py index 5f6f2d22763d..b02e7b7137aa 100644 --- a/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/group_create_parameters_py3.py +++ b/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/group_create_parameters_py3.py @@ -26,8 +26,8 @@ class GroupCreateParameters(Model): :type type: str or ~azure.mgmt.apimanagement.models.GroupType :param external_id: Identifier of the external groups, this property contains the id of the group from the external identity provider, e.g. for - Azure Active Directory `aad://.onmicrosoft.com/groups/`; otherwise the value is null. + Azure Active Directory aad://.onmicrosoft.com/groups/; otherwise the value is null. :type external_id: str """ diff --git a/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/group_update_parameters.py b/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/group_update_parameters.py index 34cb6c6a3b7d..0eec52761c7c 100644 --- a/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/group_update_parameters.py +++ b/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/group_update_parameters.py @@ -24,8 +24,8 @@ class GroupUpdateParameters(Model): :type type: str or ~azure.mgmt.apimanagement.models.GroupType :param external_id: Identifier of the external groups, this property contains the id of the group from the external identity provider, e.g. for - Azure Active Directory `aad://.onmicrosoft.com/groups/`; otherwise the value is null. + Azure Active Directory aad://.onmicrosoft.com/groups/; otherwise the value is null. :type external_id: str """ diff --git a/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/group_update_parameters_py3.py b/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/group_update_parameters_py3.py index 16aee8d02966..697f14db0b9d 100644 --- a/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/group_update_parameters_py3.py +++ b/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/group_update_parameters_py3.py @@ -24,8 +24,8 @@ class GroupUpdateParameters(Model): :type type: str or ~azure.mgmt.apimanagement.models.GroupType :param external_id: Identifier of the external groups, this property contains the id of the group from the external identity provider, e.g. for - Azure Active Directory `aad://.onmicrosoft.com/groups/`; otherwise the value is null. + Azure Active Directory aad://.onmicrosoft.com/groups/; otherwise the value is null. :type external_id: str """ diff --git a/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/http_message_diagnostic.py b/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/http_message_diagnostic.py deleted file mode 100644 index 2c2651f31bb8..000000000000 --- a/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/http_message_diagnostic.py +++ /dev/null @@ -1,32 +0,0 @@ -# coding=utf-8 -# -------------------------------------------------------------------------- -# Copyright (c) Microsoft Corporation. All rights reserved. -# Licensed under the MIT License. See License.txt in the project root for -# license information. -# -# Code generated by Microsoft (R) AutoRest Code Generator. -# Changes may cause incorrect behavior and will be lost if the code is -# regenerated. -# -------------------------------------------------------------------------- - -from msrest.serialization import Model - - -class HttpMessageDiagnostic(Model): - """Http message diagnostic settings. - - :param headers: Array of HTTP Headers to log. - :type headers: list[str] - :param body: Body logging settings. - :type body: ~azure.mgmt.apimanagement.models.BodyDiagnosticSettings - """ - - _attribute_map = { - 'headers': {'key': 'headers', 'type': '[str]'}, - 'body': {'key': 'body', 'type': 'BodyDiagnosticSettings'}, - } - - def __init__(self, **kwargs): - super(HttpMessageDiagnostic, self).__init__(**kwargs) - self.headers = kwargs.get('headers', None) - self.body = kwargs.get('body', None) diff --git a/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/http_message_diagnostic_py3.py b/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/http_message_diagnostic_py3.py deleted file mode 100644 index 28171eee4cd7..000000000000 --- a/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/http_message_diagnostic_py3.py +++ /dev/null @@ -1,32 +0,0 @@ -# coding=utf-8 -# -------------------------------------------------------------------------- -# Copyright (c) Microsoft Corporation. All rights reserved. -# Licensed under the MIT License. See License.txt in the project root for -# license information. -# -# Code generated by Microsoft (R) AutoRest Code Generator. -# Changes may cause incorrect behavior and will be lost if the code is -# regenerated. -# -------------------------------------------------------------------------- - -from msrest.serialization import Model - - -class HttpMessageDiagnostic(Model): - """Http message diagnostic settings. - - :param headers: Array of HTTP Headers to log. - :type headers: list[str] - :param body: Body logging settings. - :type body: ~azure.mgmt.apimanagement.models.BodyDiagnosticSettings - """ - - _attribute_map = { - 'headers': {'key': 'headers', 'type': '[str]'}, - 'body': {'key': 'body', 'type': 'BodyDiagnosticSettings'}, - } - - def __init__(self, *, headers=None, body=None, **kwargs) -> None: - super(HttpMessageDiagnostic, self).__init__(**kwargs) - self.headers = headers - self.body = body diff --git a/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/logger_contract.py b/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/logger_contract.py index 16213cac73bb..d73d8fba23ec 100644 --- a/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/logger_contract.py +++ b/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/logger_contract.py @@ -38,9 +38,6 @@ class LoggerContract(Resource): :param is_buffered: Whether records are buffered in the logger before publishing. Default is assumed to be true. :type is_buffered: bool - :param resource_id: Azure Resource Id of a log target (either Azure Event - Hub resource or Azure Application Insights resource). - :type resource_id: str """ _validation = { @@ -60,7 +57,6 @@ class LoggerContract(Resource): 'description': {'key': 'properties.description', 'type': 'str'}, 'credentials': {'key': 'properties.credentials', 'type': '{str}'}, 'is_buffered': {'key': 'properties.isBuffered', 'type': 'bool'}, - 'resource_id': {'key': 'properties.resourceId', 'type': 'str'}, } def __init__(self, **kwargs): @@ -69,4 +65,3 @@ def __init__(self, **kwargs): self.description = kwargs.get('description', None) self.credentials = kwargs.get('credentials', None) self.is_buffered = kwargs.get('is_buffered', None) - self.resource_id = kwargs.get('resource_id', None) diff --git a/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/logger_contract_py3.py b/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/logger_contract_py3.py index 59ceb33e5ea3..fa2b08eea139 100644 --- a/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/logger_contract_py3.py +++ b/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/logger_contract_py3.py @@ -38,9 +38,6 @@ class LoggerContract(Resource): :param is_buffered: Whether records are buffered in the logger before publishing. Default is assumed to be true. :type is_buffered: bool - :param resource_id: Azure Resource Id of a log target (either Azure Event - Hub resource or Azure Application Insights resource). - :type resource_id: str """ _validation = { @@ -60,13 +57,11 @@ class LoggerContract(Resource): 'description': {'key': 'properties.description', 'type': 'str'}, 'credentials': {'key': 'properties.credentials', 'type': '{str}'}, 'is_buffered': {'key': 'properties.isBuffered', 'type': 'bool'}, - 'resource_id': {'key': 'properties.resourceId', 'type': 'str'}, } - def __init__(self, *, logger_type, credentials, description: str=None, is_buffered: bool=None, resource_id: str=None, **kwargs) -> None: + def __init__(self, *, logger_type, credentials, description: str=None, is_buffered: bool=None, **kwargs) -> None: super(LoggerContract, self).__init__(**kwargs) self.logger_type = logger_type self.description = description self.credentials = credentials self.is_buffered = is_buffered - self.resource_id = resource_id diff --git a/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/pipeline_diagnostic_settings.py b/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/pipeline_diagnostic_settings.py deleted file mode 100644 index 8f7fc4ad6f59..000000000000 --- a/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/pipeline_diagnostic_settings.py +++ /dev/null @@ -1,32 +0,0 @@ -# coding=utf-8 -# -------------------------------------------------------------------------- -# Copyright (c) Microsoft Corporation. All rights reserved. -# Licensed under the MIT License. See License.txt in the project root for -# license information. -# -# Code generated by Microsoft (R) AutoRest Code Generator. -# Changes may cause incorrect behavior and will be lost if the code is -# regenerated. -# -------------------------------------------------------------------------- - -from msrest.serialization import Model - - -class PipelineDiagnosticSettings(Model): - """Diagnostic settings for incoming/outcoming HTTP messages to the Gateway. - - :param request: Diagnostic settings for request. - :type request: ~azure.mgmt.apimanagement.models.HttpMessageDiagnostic - :param response: Diagnostic settings for response. - :type response: ~azure.mgmt.apimanagement.models.HttpMessageDiagnostic - """ - - _attribute_map = { - 'request': {'key': 'request', 'type': 'HttpMessageDiagnostic'}, - 'response': {'key': 'response', 'type': 'HttpMessageDiagnostic'}, - } - - def __init__(self, **kwargs): - super(PipelineDiagnosticSettings, self).__init__(**kwargs) - self.request = kwargs.get('request', None) - self.response = kwargs.get('response', None) diff --git a/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/pipeline_diagnostic_settings_py3.py b/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/pipeline_diagnostic_settings_py3.py deleted file mode 100644 index df30f03b166d..000000000000 --- a/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/pipeline_diagnostic_settings_py3.py +++ /dev/null @@ -1,32 +0,0 @@ -# coding=utf-8 -# -------------------------------------------------------------------------- -# Copyright (c) Microsoft Corporation. All rights reserved. -# Licensed under the MIT License. See License.txt in the project root for -# license information. -# -# Code generated by Microsoft (R) AutoRest Code Generator. -# Changes may cause incorrect behavior and will be lost if the code is -# regenerated. -# -------------------------------------------------------------------------- - -from msrest.serialization import Model - - -class PipelineDiagnosticSettings(Model): - """Diagnostic settings for incoming/outcoming HTTP messages to the Gateway. - - :param request: Diagnostic settings for request. - :type request: ~azure.mgmt.apimanagement.models.HttpMessageDiagnostic - :param response: Diagnostic settings for response. - :type response: ~azure.mgmt.apimanagement.models.HttpMessageDiagnostic - """ - - _attribute_map = { - 'request': {'key': 'request', 'type': 'HttpMessageDiagnostic'}, - 'response': {'key': 'response', 'type': 'HttpMessageDiagnostic'}, - } - - def __init__(self, *, request=None, response=None, **kwargs) -> None: - super(PipelineDiagnosticSettings, self).__init__(**kwargs) - self.request = request - self.response = response diff --git a/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/product_contract.py b/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/product_contract.py index c25ec9bde595..82bde48700b9 100644 --- a/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/product_contract.py +++ b/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/product_contract.py @@ -48,7 +48,7 @@ class ProductContract(Resource): subscriptionRequired property is present and has a value of false. :type approval_required: bool :param subscriptions_limit: Whether the number of subscriptions a user can - have to this product at the same time. Set to null or omit to allow + have to this product at the same time. Set to null or omit to allow unlimited per user subscriptions. Can be present only if subscriptionRequired property is present and has a value of false. :type subscriptions_limit: int diff --git a/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/product_contract_py3.py b/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/product_contract_py3.py index 2183cdb4de8a..adefb099a2e6 100644 --- a/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/product_contract_py3.py +++ b/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/product_contract_py3.py @@ -48,7 +48,7 @@ class ProductContract(Resource): subscriptionRequired property is present and has a value of false. :type approval_required: bool :param subscriptions_limit: Whether the number of subscriptions a user can - have to this product at the same time. Set to null or omit to allow + have to this product at the same time. Set to null or omit to allow unlimited per user subscriptions. Can be present only if subscriptionRequired property is present and has a value of false. :type subscriptions_limit: int diff --git a/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/product_entity_base_parameters.py b/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/product_entity_base_parameters.py index 4e1f97bc6694..25ab8d74a8c1 100644 --- a/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/product_entity_base_parameters.py +++ b/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/product_entity_base_parameters.py @@ -37,7 +37,7 @@ class ProductEntityBaseParameters(Model): subscriptionRequired property is present and has a value of false. :type approval_required: bool :param subscriptions_limit: Whether the number of subscriptions a user can - have to this product at the same time. Set to null or omit to allow + have to this product at the same time. Set to null or omit to allow unlimited per user subscriptions. Can be present only if subscriptionRequired property is present and has a value of false. :type subscriptions_limit: int diff --git a/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/product_entity_base_parameters_py3.py b/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/product_entity_base_parameters_py3.py index 5574461683ea..df6476ffa2cd 100644 --- a/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/product_entity_base_parameters_py3.py +++ b/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/product_entity_base_parameters_py3.py @@ -37,7 +37,7 @@ class ProductEntityBaseParameters(Model): subscriptionRequired property is present and has a value of false. :type approval_required: bool :param subscriptions_limit: Whether the number of subscriptions a user can - have to this product at the same time. Set to null or omit to allow + have to this product at the same time. Set to null or omit to allow unlimited per user subscriptions. Can be present only if subscriptionRequired property is present and has a value of false. :type subscriptions_limit: int diff --git a/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/product_tag_resource_contract_properties.py b/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/product_tag_resource_contract_properties.py index 0b32a2c9df40..ee62ee30fd43 100644 --- a/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/product_tag_resource_contract_properties.py +++ b/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/product_tag_resource_contract_properties.py @@ -39,7 +39,7 @@ class ProductTagResourceContractProperties(ProductEntityBaseParameters): subscriptionRequired property is present and has a value of false. :type approval_required: bool :param subscriptions_limit: Whether the number of subscriptions a user can - have to this product at the same time. Set to null or omit to allow + have to this product at the same time. Set to null or omit to allow unlimited per user subscriptions. Can be present only if subscriptionRequired property is present and has a value of false. :type subscriptions_limit: int diff --git a/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/product_tag_resource_contract_properties_py3.py b/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/product_tag_resource_contract_properties_py3.py index ecb7fef20809..d0b95a1d9782 100644 --- a/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/product_tag_resource_contract_properties_py3.py +++ b/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/product_tag_resource_contract_properties_py3.py @@ -39,7 +39,7 @@ class ProductTagResourceContractProperties(ProductEntityBaseParameters): subscriptionRequired property is present and has a value of false. :type approval_required: bool :param subscriptions_limit: Whether the number of subscriptions a user can - have to this product at the same time. Set to null or omit to allow + have to this product at the same time. Set to null or omit to allow unlimited per user subscriptions. Can be present only if subscriptionRequired property is present and has a value of false. :type subscriptions_limit: int diff --git a/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/product_update_parameters.py b/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/product_update_parameters.py index ce8e0d73d728..3d71fde94ca9 100644 --- a/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/product_update_parameters.py +++ b/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/product_update_parameters.py @@ -37,7 +37,7 @@ class ProductUpdateParameters(Model): subscriptionRequired property is present and has a value of false. :type approval_required: bool :param subscriptions_limit: Whether the number of subscriptions a user can - have to this product at the same time. Set to null or omit to allow + have to this product at the same time. Set to null or omit to allow unlimited per user subscriptions. Can be present only if subscriptionRequired property is present and has a value of false. :type subscriptions_limit: int diff --git a/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/product_update_parameters_py3.py b/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/product_update_parameters_py3.py index 9154962e697d..76d097f2f94c 100644 --- a/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/product_update_parameters_py3.py +++ b/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/product_update_parameters_py3.py @@ -37,7 +37,7 @@ class ProductUpdateParameters(Model): subscriptionRequired property is present and has a value of false. :type approval_required: bool :param subscriptions_limit: Whether the number of subscriptions a user can - have to this product at the same time. Set to null or omit to allow + have to this product at the same time. Set to null or omit to allow unlimited per user subscriptions. Can be present only if subscriptionRequired property is present and has a value of false. :type subscriptions_limit: int diff --git a/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/sampling_settings.py b/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/sampling_settings.py deleted file mode 100644 index c773f5b593b1..000000000000 --- a/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/sampling_settings.py +++ /dev/null @@ -1,36 +0,0 @@ -# coding=utf-8 -# -------------------------------------------------------------------------- -# Copyright (c) Microsoft Corporation. All rights reserved. -# Licensed under the MIT License. See License.txt in the project root for -# license information. -# -# Code generated by Microsoft (R) AutoRest Code Generator. -# Changes may cause incorrect behavior and will be lost if the code is -# regenerated. -# -------------------------------------------------------------------------- - -from msrest.serialization import Model - - -class SamplingSettings(Model): - """Sampling settings for Diagnostic. - - :param sampling_type: Sampling type. Possible values include: 'fixed' - :type sampling_type: str or ~azure.mgmt.apimanagement.models.SamplingType - :param percentage: Rate of sampling for fixed-rate sampling. - :type percentage: float - """ - - _validation = { - 'percentage': {'maximum': 100, 'minimum': 0}, - } - - _attribute_map = { - 'sampling_type': {'key': 'samplingType', 'type': 'str'}, - 'percentage': {'key': 'percentage', 'type': 'float'}, - } - - def __init__(self, **kwargs): - super(SamplingSettings, self).__init__(**kwargs) - self.sampling_type = kwargs.get('sampling_type', None) - self.percentage = kwargs.get('percentage', None) diff --git a/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/sampling_settings_py3.py b/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/sampling_settings_py3.py deleted file mode 100644 index 544dbda52a7f..000000000000 --- a/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/sampling_settings_py3.py +++ /dev/null @@ -1,36 +0,0 @@ -# coding=utf-8 -# -------------------------------------------------------------------------- -# Copyright (c) Microsoft Corporation. All rights reserved. -# Licensed under the MIT License. See License.txt in the project root for -# license information. -# -# Code generated by Microsoft (R) AutoRest Code Generator. -# Changes may cause incorrect behavior and will be lost if the code is -# regenerated. -# -------------------------------------------------------------------------- - -from msrest.serialization import Model - - -class SamplingSettings(Model): - """Sampling settings for Diagnostic. - - :param sampling_type: Sampling type. Possible values include: 'fixed' - :type sampling_type: str or ~azure.mgmt.apimanagement.models.SamplingType - :param percentage: Rate of sampling for fixed-rate sampling. - :type percentage: float - """ - - _validation = { - 'percentage': {'maximum': 100, 'minimum': 0}, - } - - _attribute_map = { - 'sampling_type': {'key': 'samplingType', 'type': 'str'}, - 'percentage': {'key': 'percentage', 'type': 'float'}, - } - - def __init__(self, *, sampling_type=None, percentage: float=None, **kwargs) -> None: - super(SamplingSettings, self).__init__(**kwargs) - self.sampling_type = sampling_type - self.percentage = percentage diff --git a/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/__init__.py b/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/__init__.py index 41c9a8d60767..68983b74f26e 100644 --- a/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/__init__.py +++ b/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/__init__.py @@ -21,6 +21,7 @@ from .api_policy_operations import ApiPolicyOperations from .api_schema_operations import ApiSchemaOperations from .api_diagnostic_operations import ApiDiagnosticOperations +from .api_diagnostic_logger_operations import ApiDiagnosticLoggerOperations from .api_issue_operations import ApiIssueOperations from .api_issue_comment_operations import ApiIssueCommentOperations from .api_issue_attachment_operations import ApiIssueAttachmentOperations @@ -30,6 +31,7 @@ from .api_management_operations import ApiManagementOperations from .api_management_service_operations import ApiManagementServiceOperations from .diagnostic_operations import DiagnosticOperations +from .diagnostic_logger_operations import DiagnosticLoggerOperations from .email_template_operations import EmailTemplateOperations from .group_operations import GroupOperations from .group_user_operations import GroupUserOperations @@ -80,6 +82,7 @@ 'ApiPolicyOperations', 'ApiSchemaOperations', 'ApiDiagnosticOperations', + 'ApiDiagnosticLoggerOperations', 'ApiIssueOperations', 'ApiIssueCommentOperations', 'ApiIssueAttachmentOperations', @@ -89,6 +92,7 @@ 'ApiManagementOperations', 'ApiManagementServiceOperations', 'DiagnosticOperations', + 'DiagnosticLoggerOperations', 'EmailTemplateOperations', 'GroupOperations', 'GroupUserOperations', diff --git a/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/api_diagnostic_logger_operations.py b/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/api_diagnostic_logger_operations.py new file mode 100644 index 000000000000..4131d7561215 --- /dev/null +++ b/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/api_diagnostic_logger_operations.py @@ -0,0 +1,338 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +import uuid +from msrest.pipeline import ClientRawResponse + +from .. import models + + +class ApiDiagnosticLoggerOperations(object): + """ApiDiagnosticLoggerOperations operations. + + :param client: Client for service requests. + :param config: Configuration of service client. + :param serializer: An object model serializer. + :param deserializer: An object model deserializer. + :ivar api_version: Version of the API to be used with the client request. Constant value: "2018-01-01". + """ + + models = models + + def __init__(self, client, config, serializer, deserializer): + + self._client = client + self._serialize = serializer + self._deserialize = deserializer + self.api_version = "2018-01-01" + + self.config = config + + def list_by_service( + self, resource_group_name, service_name, api_id, diagnostic_id, filter=None, top=None, skip=None, custom_headers=None, raw=False, **operation_config): + """Lists all loggers assosiated with the specified Diagnostic of an API. + + :param resource_group_name: The name of the resource group. + :type resource_group_name: str + :param service_name: The name of the API Management service. + :type service_name: str + :param api_id: API identifier. Must be unique in the current API + Management service instance. + :type api_id: str + :param diagnostic_id: Diagnostic identifier. Must be unique in the + current API Management service instance. + :type diagnostic_id: str + :param filter: | Field | Supported operators | Supported + functions | + |-------------|------------------------|-----------------------------------| + | id | ge, le, eq, ne, gt, lt | substringof, startswith, + endswith | + | type | eq | + | + :type filter: str + :param top: Number of records to return. + :type top: int + :param skip: Number of records to skip. + :type skip: int + :param dict custom_headers: headers that will be added to the request + :param bool raw: returns the direct response alongside the + deserialized response + :param operation_config: :ref:`Operation configuration + overrides`. + :return: An iterator like instance of LoggerContract + :rtype: + ~azure.mgmt.apimanagement.models.LoggerContractPaged[~azure.mgmt.apimanagement.models.LoggerContract] + :raises: + :class:`ErrorResponseException` + """ + def internal_paging(next_link=None, raw=False): + + if not next_link: + # Construct URL + url = self.list_by_service.metadata['url'] + path_format_arguments = { + 'resourceGroupName': self._serialize.url("resource_group_name", resource_group_name, 'str'), + 'serviceName': self._serialize.url("service_name", service_name, 'str', max_length=50, min_length=1, pattern=r'^[a-zA-Z](?:[a-zA-Z0-9-]*[a-zA-Z0-9])?$'), + 'apiId': self._serialize.url("api_id", api_id, 'str', max_length=80, min_length=1, pattern=r'(^[\w]+$)|(^[\w][\w\-]+[\w]$)'), + 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str'), + 'diagnosticId': self._serialize.url("diagnostic_id", diagnostic_id, 'str', max_length=80, min_length=1, pattern=r'(^[\w]+$)|(^[\w][\w\-]+[\w]$)') + } + url = self._client.format_url(url, **path_format_arguments) + + # Construct parameters + query_parameters = {} + query_parameters['api-version'] = self._serialize.query("self.api_version", self.api_version, 'str') + if filter is not None: + query_parameters['$filter'] = self._serialize.query("filter", filter, 'str') + if top is not None: + query_parameters['$top'] = self._serialize.query("top", top, 'int', minimum=1) + if skip is not None: + query_parameters['$skip'] = self._serialize.query("skip", skip, 'int', minimum=0) + + else: + url = next_link + query_parameters = {} + + # Construct headers + header_parameters = {} + header_parameters['Accept'] = 'application/json' + if self.config.generate_client_request_id: + header_parameters['x-ms-client-request-id'] = str(uuid.uuid1()) + if custom_headers: + header_parameters.update(custom_headers) + if self.config.accept_language is not None: + header_parameters['accept-language'] = self._serialize.header("self.config.accept_language", self.config.accept_language, 'str') + + # Construct and send request + request = self._client.get(url, query_parameters, header_parameters) + response = self._client.send(request, stream=False, **operation_config) + + if response.status_code not in [200]: + raise models.ErrorResponseException(self._deserialize, response) + + return response + + # Deserialize response + deserialized = models.LoggerContractPaged(internal_paging, self._deserialize.dependencies) + + if raw: + header_dict = {} + client_raw_response = models.LoggerContractPaged(internal_paging, self._deserialize.dependencies, header_dict) + return client_raw_response + + return deserialized + list_by_service.metadata = {'url': '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ApiManagement/service/{serviceName}/apis/{apiId}/diagnostics/{diagnosticId}/loggers'} + + def check_entity_exists( + self, resource_group_name, service_name, api_id, diagnostic_id, loggerid, custom_headers=None, raw=False, **operation_config): + """Checks that logger entity specified by identifier is associated with + the diagnostics entity. + + :param resource_group_name: The name of the resource group. + :type resource_group_name: str + :param service_name: The name of the API Management service. + :type service_name: str + :param api_id: API identifier. Must be unique in the current API + Management service instance. + :type api_id: str + :param diagnostic_id: Diagnostic identifier. Must be unique in the + current API Management service instance. + :type diagnostic_id: str + :param loggerid: Logger identifier. Must be unique in the API + Management service instance. + :type loggerid: str + :param dict custom_headers: headers that will be added to the request + :param bool raw: returns the direct response alongside the + deserialized response + :param operation_config: :ref:`Operation configuration + overrides`. + :return: bool or ClientRawResponse if raw=true + :rtype: bool or ~msrest.pipeline.ClientRawResponse + :raises: + :class:`ErrorResponseException` + """ + # Construct URL + url = self.check_entity_exists.metadata['url'] + path_format_arguments = { + 'resourceGroupName': self._serialize.url("resource_group_name", resource_group_name, 'str'), + 'serviceName': self._serialize.url("service_name", service_name, 'str', max_length=50, min_length=1, pattern=r'^[a-zA-Z](?:[a-zA-Z0-9-]*[a-zA-Z0-9])?$'), + 'apiId': self._serialize.url("api_id", api_id, 'str', max_length=80, min_length=1, pattern=r'(^[\w]+$)|(^[\w][\w\-]+[\w]$)'), + 'diagnosticId': self._serialize.url("diagnostic_id", diagnostic_id, 'str', max_length=80, min_length=1, pattern=r'(^[\w]+$)|(^[\w][\w\-]+[\w]$)'), + 'loggerid': self._serialize.url("loggerid", loggerid, 'str', max_length=80, pattern=r'(^[\w]+$)|(^[\w][\w\-]+[\w]$)'), + 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str') + } + url = self._client.format_url(url, **path_format_arguments) + + # Construct parameters + query_parameters = {} + query_parameters['api-version'] = self._serialize.query("self.api_version", self.api_version, 'str') + + # Construct headers + header_parameters = {} + if self.config.generate_client_request_id: + header_parameters['x-ms-client-request-id'] = str(uuid.uuid1()) + if custom_headers: + header_parameters.update(custom_headers) + if self.config.accept_language is not None: + header_parameters['accept-language'] = self._serialize.header("self.config.accept_language", self.config.accept_language, 'str') + + # Construct and send request + request = self._client.head(url, query_parameters, header_parameters) + response = self._client.send(request, stream=False, **operation_config) + + if response.status_code not in [204, 404]: + raise models.ErrorResponseException(self._deserialize, response) + + deserialized = (response.status_code == 204) + if raw: + client_raw_response = ClientRawResponse(deserialized, response) + return client_raw_response + return deserialized + check_entity_exists.metadata = {'url': '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ApiManagement/service/{serviceName}/apis/{apiId}/diagnostics/{diagnosticId}/loggers/{loggerid}'} + + def create_or_update( + self, resource_group_name, service_name, api_id, diagnostic_id, loggerid, custom_headers=None, raw=False, **operation_config): + """Attaches a logger to a dignostic for an API. + + :param resource_group_name: The name of the resource group. + :type resource_group_name: str + :param service_name: The name of the API Management service. + :type service_name: str + :param api_id: API identifier. Must be unique in the current API + Management service instance. + :type api_id: str + :param diagnostic_id: Diagnostic identifier. Must be unique in the + current API Management service instance. + :type diagnostic_id: str + :param loggerid: Logger identifier. Must be unique in the API + Management service instance. + :type loggerid: str + :param dict custom_headers: headers that will be added to the request + :param bool raw: returns the direct response alongside the + deserialized response + :param operation_config: :ref:`Operation configuration + overrides`. + :return: LoggerContract or ClientRawResponse if raw=true + :rtype: ~azure.mgmt.apimanagement.models.LoggerContract or + ~msrest.pipeline.ClientRawResponse + :raises: + :class:`ErrorResponseException` + """ + # Construct URL + url = self.create_or_update.metadata['url'] + path_format_arguments = { + 'resourceGroupName': self._serialize.url("resource_group_name", resource_group_name, 'str'), + 'serviceName': self._serialize.url("service_name", service_name, 'str', max_length=50, min_length=1, pattern=r'^[a-zA-Z](?:[a-zA-Z0-9-]*[a-zA-Z0-9])?$'), + 'apiId': self._serialize.url("api_id", api_id, 'str', max_length=80, min_length=1, pattern=r'(^[\w]+$)|(^[\w][\w\-]+[\w]$)'), + 'diagnosticId': self._serialize.url("diagnostic_id", diagnostic_id, 'str', max_length=80, min_length=1, pattern=r'(^[\w]+$)|(^[\w][\w\-]+[\w]$)'), + 'loggerid': self._serialize.url("loggerid", loggerid, 'str', max_length=80, pattern=r'(^[\w]+$)|(^[\w][\w\-]+[\w]$)'), + 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str') + } + url = self._client.format_url(url, **path_format_arguments) + + # Construct parameters + query_parameters = {} + query_parameters['api-version'] = self._serialize.query("self.api_version", self.api_version, 'str') + + # Construct headers + header_parameters = {} + header_parameters['Accept'] = 'application/json' + if self.config.generate_client_request_id: + header_parameters['x-ms-client-request-id'] = str(uuid.uuid1()) + if custom_headers: + header_parameters.update(custom_headers) + if self.config.accept_language is not None: + header_parameters['accept-language'] = self._serialize.header("self.config.accept_language", self.config.accept_language, 'str') + + # Construct and send request + request = self._client.put(url, query_parameters, header_parameters) + response = self._client.send(request, stream=False, **operation_config) + + if response.status_code not in [200, 201]: + raise models.ErrorResponseException(self._deserialize, response) + + deserialized = None + + if response.status_code == 200: + deserialized = self._deserialize('LoggerContract', response) + if response.status_code == 201: + deserialized = self._deserialize('LoggerContract', response) + + if raw: + client_raw_response = ClientRawResponse(deserialized, response) + return client_raw_response + + return deserialized + create_or_update.metadata = {'url': '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ApiManagement/service/{serviceName}/apis/{apiId}/diagnostics/{diagnosticId}/loggers/{loggerid}'} + + def delete( + self, resource_group_name, service_name, api_id, diagnostic_id, loggerid, custom_headers=None, raw=False, **operation_config): + """Deletes the specified Logger from Diagnostic for an API. + + :param resource_group_name: The name of the resource group. + :type resource_group_name: str + :param service_name: The name of the API Management service. + :type service_name: str + :param api_id: API identifier. Must be unique in the current API + Management service instance. + :type api_id: str + :param diagnostic_id: Diagnostic identifier. Must be unique in the + current API Management service instance. + :type diagnostic_id: str + :param loggerid: Logger identifier. Must be unique in the API + Management service instance. + :type loggerid: str + :param dict custom_headers: headers that will be added to the request + :param bool raw: returns the direct response alongside the + deserialized response + :param operation_config: :ref:`Operation configuration + overrides`. + :return: None or ClientRawResponse if raw=true + :rtype: None or ~msrest.pipeline.ClientRawResponse + :raises: + :class:`ErrorResponseException` + """ + # Construct URL + url = self.delete.metadata['url'] + path_format_arguments = { + 'resourceGroupName': self._serialize.url("resource_group_name", resource_group_name, 'str'), + 'serviceName': self._serialize.url("service_name", service_name, 'str', max_length=50, min_length=1, pattern=r'^[a-zA-Z](?:[a-zA-Z0-9-]*[a-zA-Z0-9])?$'), + 'apiId': self._serialize.url("api_id", api_id, 'str', max_length=80, min_length=1, pattern=r'(^[\w]+$)|(^[\w][\w\-]+[\w]$)'), + 'diagnosticId': self._serialize.url("diagnostic_id", diagnostic_id, 'str', max_length=80, min_length=1, pattern=r'(^[\w]+$)|(^[\w][\w\-]+[\w]$)'), + 'loggerid': self._serialize.url("loggerid", loggerid, 'str', max_length=80, pattern=r'(^[\w]+$)|(^[\w][\w\-]+[\w]$)'), + 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str') + } + url = self._client.format_url(url, **path_format_arguments) + + # Construct parameters + query_parameters = {} + query_parameters['api-version'] = self._serialize.query("self.api_version", self.api_version, 'str') + + # Construct headers + header_parameters = {} + if self.config.generate_client_request_id: + header_parameters['x-ms-client-request-id'] = str(uuid.uuid1()) + if custom_headers: + header_parameters.update(custom_headers) + if self.config.accept_language is not None: + header_parameters['accept-language'] = self._serialize.header("self.config.accept_language", self.config.accept_language, 'str') + + # Construct and send request + request = self._client.delete(url, query_parameters, header_parameters) + response = self._client.send(request, stream=False, **operation_config) + + if response.status_code not in [200, 204]: + raise models.ErrorResponseException(self._deserialize, response) + + if raw: + client_raw_response = ClientRawResponse(None, response) + return client_raw_response + delete.metadata = {'url': '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ApiManagement/service/{serviceName}/apis/{apiId}/diagnostics/{diagnosticId}/loggers/{loggerid}'} diff --git a/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/api_diagnostic_operations.py b/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/api_diagnostic_operations.py index 110dfc437f15..2c4e7371c105 100644 --- a/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/api_diagnostic_operations.py +++ b/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/api_diagnostic_operations.py @@ -22,7 +22,7 @@ class ApiDiagnosticOperations(object): :param config: Configuration of service client. :param serializer: An object model serializer. :param deserializer: An object model deserializer. - :ivar api_version: Version of the API to be used with the client request. Constant value: "2018-06-01-preview". + :ivar api_version: Version of the API to be used with the client request. Constant value: "2018-01-01". """ models = models @@ -32,7 +32,7 @@ def __init__(self, client, config, serializer, deserializer): self._client = client self._serialize = serializer self._deserialize = deserializer - self.api_version = "2018-06-01-preview" + self.api_version = "2018-01-01" self.config = config @@ -265,7 +265,7 @@ def get( get.metadata = {'url': '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ApiManagement/service/{serviceName}/apis/{apiId}/diagnostics/{diagnosticId}'} def create_or_update( - self, resource_group_name, service_name, api_id, diagnostic_id, parameters, if_match=None, custom_headers=None, raw=False, **operation_config): + self, resource_group_name, service_name, api_id, diagnostic_id, enabled, if_match=None, custom_headers=None, raw=False, **operation_config): """Creates a new Diagnostic for an API or updates an existing one. :param resource_group_name: The name of the resource group. @@ -278,8 +278,9 @@ def create_or_update( :param diagnostic_id: Diagnostic identifier. Must be unique in the current API Management service instance. :type diagnostic_id: str - :param parameters: Create parameters. - :type parameters: ~azure.mgmt.apimanagement.models.DiagnosticContract + :param enabled: Indicates whether a diagnostic should receive data or + not. + :type enabled: bool :param if_match: ETag of the Entity. Not required when creating an entity, but required when updating an entity. :type if_match: str @@ -294,6 +295,8 @@ def create_or_update( :raises: :class:`ErrorResponseException` """ + parameters = models.DiagnosticContract(enabled=enabled) + # Construct URL url = self.create_or_update.metadata['url'] path_format_arguments = { @@ -347,7 +350,7 @@ def create_or_update( create_or_update.metadata = {'url': '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ApiManagement/service/{serviceName}/apis/{apiId}/diagnostics/{diagnosticId}'} def update( - self, resource_group_name, service_name, api_id, diagnostic_id, parameters, if_match, custom_headers=None, raw=False, **operation_config): + self, resource_group_name, service_name, api_id, diagnostic_id, if_match, enabled, custom_headers=None, raw=False, **operation_config): """Updates the details of the Diagnostic for an API specified by its identifier. @@ -361,12 +364,13 @@ def update( :param diagnostic_id: Diagnostic identifier. Must be unique in the current API Management service instance. :type diagnostic_id: str - :param parameters: Diagnostic Update parameters. - :type parameters: ~azure.mgmt.apimanagement.models.DiagnosticContract :param if_match: ETag of the Entity. ETag should match the current entity state from the header response of the GET request or it should be * for unconditional update. :type if_match: str + :param enabled: Indicates whether a diagnostic should receive data or + not. + :type enabled: bool :param dict custom_headers: headers that will be added to the request :param bool raw: returns the direct response alongside the deserialized response @@ -377,6 +381,8 @@ def update( :raises: :class:`ErrorResponseException` """ + parameters = models.DiagnosticContract(enabled=enabled) + # Construct URL url = self.update.metadata['url'] path_format_arguments = { diff --git a/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/api_export_operations.py b/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/api_export_operations.py index 5ec42ec99449..5864d39a96d7 100644 --- a/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/api_export_operations.py +++ b/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/api_export_operations.py @@ -23,7 +23,7 @@ class ApiExportOperations(object): :param serializer: An object model serializer. :param deserializer: An object model deserializer. :ivar export: Query parameter required to export the API details. Constant value: "true". - :ivar api_version: Version of the API to be used with the client request. Constant value: "2018-06-01-preview". + :ivar api_version: Version of the API to be used with the client request. Constant value: "2018-01-01". """ models = models @@ -34,7 +34,7 @@ def __init__(self, client, config, serializer, deserializer): self._serialize = serializer self._deserialize = deserializer self.export = "true" - self.api_version = "2018-06-01-preview" + self.api_version = "2018-01-01" self.config = config diff --git a/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/api_issue_attachment_operations.py b/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/api_issue_attachment_operations.py index d0a2b59844d9..7b18b482800f 100644 --- a/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/api_issue_attachment_operations.py +++ b/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/api_issue_attachment_operations.py @@ -22,7 +22,7 @@ class ApiIssueAttachmentOperations(object): :param config: Configuration of service client. :param serializer: An object model serializer. :param deserializer: An object model deserializer. - :ivar api_version: Version of the API to be used with the client request. Constant value: "2018-06-01-preview". + :ivar api_version: Version of the API to be used with the client request. Constant value: "2018-01-01". """ models = models @@ -32,7 +32,7 @@ def __init__(self, client, config, serializer, deserializer): self._client = client self._serialize = serializer self._deserialize = deserializer - self.api_version = "2018-06-01-preview" + self.api_version = "2018-01-01" self.config = config diff --git a/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/api_issue_comment_operations.py b/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/api_issue_comment_operations.py index 6c950ff934aa..eae12baac8b9 100644 --- a/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/api_issue_comment_operations.py +++ b/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/api_issue_comment_operations.py @@ -22,7 +22,7 @@ class ApiIssueCommentOperations(object): :param config: Configuration of service client. :param serializer: An object model serializer. :param deserializer: An object model deserializer. - :ivar api_version: Version of the API to be used with the client request. Constant value: "2018-06-01-preview". + :ivar api_version: Version of the API to be used with the client request. Constant value: "2018-01-01". """ models = models @@ -32,7 +32,7 @@ def __init__(self, client, config, serializer, deserializer): self._client = client self._serialize = serializer self._deserialize = deserializer - self.api_version = "2018-06-01-preview" + self.api_version = "2018-01-01" self.config = config diff --git a/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/api_issue_operations.py b/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/api_issue_operations.py index 7a75b967eb8a..b3e3633b07d4 100644 --- a/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/api_issue_operations.py +++ b/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/api_issue_operations.py @@ -22,7 +22,7 @@ class ApiIssueOperations(object): :param config: Configuration of service client. :param serializer: An object model serializer. :param deserializer: An object model deserializer. - :ivar api_version: Version of the API to be used with the client request. Constant value: "2018-06-01-preview". + :ivar api_version: Version of the API to be used with the client request. Constant value: "2018-01-01". """ models = models @@ -32,7 +32,7 @@ def __init__(self, client, config, serializer, deserializer): self._client = client self._serialize = serializer self._deserialize = deserializer - self.api_version = "2018-06-01-preview" + self.api_version = "2018-01-01" self.config = config diff --git a/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/api_management_operations.py b/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/api_management_operations.py index 67c71803a719..59b096dd6b81 100644 --- a/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/api_management_operations.py +++ b/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/api_management_operations.py @@ -23,7 +23,7 @@ class ApiManagementOperations(object): :param config: Configuration of service client. :param serializer: An object model serializer. :param deserializer: An object model deserializer. - :ivar api_version: Version of the API to be used with the client request. Constant value: "2018-06-01-preview". + :ivar api_version: Version of the API to be used with the client request. Constant value: "2018-01-01". """ models = models @@ -33,7 +33,7 @@ def __init__(self, client, config, serializer, deserializer): self._client = client self._serialize = serializer self._deserialize = deserializer - self.api_version = "2018-06-01-preview" + self.api_version = "2018-01-01" self.config = config diff --git a/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/api_management_service_operations.py b/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/api_management_service_operations.py index ea9192712dd4..139163ce0d2e 100644 --- a/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/api_management_service_operations.py +++ b/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/api_management_service_operations.py @@ -25,7 +25,7 @@ class ApiManagementServiceOperations(object): :param config: Configuration of service client. :param serializer: An object model serializer. :param deserializer: An object model deserializer. - :ivar api_version: Version of the API to be used with the client request. Constant value: "2018-06-01-preview". + :ivar api_version: Version of the API to be used with the client request. Constant value: "2018-01-01". """ models = models @@ -35,7 +35,7 @@ def __init__(self, client, config, serializer, deserializer): self._client = client self._serialize = serializer self._deserialize = deserializer - self.api_version = "2018-06-01-preview" + self.api_version = "2018-01-01" self.config = config diff --git a/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/api_operation_operations.py b/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/api_operation_operations.py index 62b173bfba1c..70631edd59b9 100644 --- a/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/api_operation_operations.py +++ b/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/api_operation_operations.py @@ -22,7 +22,7 @@ class ApiOperationOperations(object): :param config: Configuration of service client. :param serializer: An object model serializer. :param deserializer: An object model deserializer. - :ivar api_version: Version of the API to be used with the client request. Constant value: "2018-06-01-preview". + :ivar api_version: Version of the API to be used with the client request. Constant value: "2018-01-01". """ models = models @@ -32,7 +32,7 @@ def __init__(self, client, config, serializer, deserializer): self._client = client self._serialize = serializer self._deserialize = deserializer - self.api_version = "2018-06-01-preview" + self.api_version = "2018-01-01" self.config = config diff --git a/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/api_operation_policy_operations.py b/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/api_operation_policy_operations.py index f06f5379e485..ed672d947a4a 100644 --- a/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/api_operation_policy_operations.py +++ b/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/api_operation_policy_operations.py @@ -22,7 +22,7 @@ class ApiOperationPolicyOperations(object): :param config: Configuration of service client. :param serializer: An object model serializer. :param deserializer: An object model deserializer. - :ivar api_version: Version of the API to be used with the client request. Constant value: "2018-06-01-preview". + :ivar api_version: Version of the API to be used with the client request. Constant value: "2018-01-01". :ivar policy_id: The identifier of the Policy. Constant value: "policy". """ @@ -33,7 +33,7 @@ def __init__(self, client, config, serializer, deserializer): self._client = client self._serialize = serializer self._deserialize = deserializer - self.api_version = "2018-06-01-preview" + self.api_version = "2018-01-01" self.policy_id = "policy" self.config = config diff --git a/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/api_operations.py b/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/api_operations.py index 7afd2b2d40c1..10760f4dee9e 100644 --- a/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/api_operations.py +++ b/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/api_operations.py @@ -23,7 +23,7 @@ class ApiOperations(object): :param config: Configuration of service client. :param serializer: An object model serializer. :param deserializer: An object model deserializer. - :ivar api_version: Version of the API to be used with the client request. Constant value: "2018-06-01-preview". + :ivar api_version: Version of the API to be used with the client request. Constant value: "2018-01-01". """ models = models @@ -33,7 +33,7 @@ def __init__(self, client, config, serializer, deserializer): self._client = client self._serialize = serializer self._deserialize = deserializer - self.api_version = "2018-06-01-preview" + self.api_version = "2018-01-01" self.config = config diff --git a/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/api_policy_operations.py b/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/api_policy_operations.py index b121b46ab35a..5cdfe669fca7 100644 --- a/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/api_policy_operations.py +++ b/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/api_policy_operations.py @@ -22,7 +22,7 @@ class ApiPolicyOperations(object): :param config: Configuration of service client. :param serializer: An object model serializer. :param deserializer: An object model deserializer. - :ivar api_version: Version of the API to be used with the client request. Constant value: "2018-06-01-preview". + :ivar api_version: Version of the API to be used with the client request. Constant value: "2018-01-01". :ivar policy_id: The identifier of the Policy. Constant value: "policy". """ @@ -33,7 +33,7 @@ def __init__(self, client, config, serializer, deserializer): self._client = client self._serialize = serializer self._deserialize = deserializer - self.api_version = "2018-06-01-preview" + self.api_version = "2018-01-01" self.policy_id = "policy" self.config = config diff --git a/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/api_product_operations.py b/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/api_product_operations.py index ac5f78c8cef7..2522feb28b70 100644 --- a/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/api_product_operations.py +++ b/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/api_product_operations.py @@ -22,7 +22,7 @@ class ApiProductOperations(object): :param config: Configuration of service client. :param serializer: An object model serializer. :param deserializer: An object model deserializer. - :ivar api_version: Version of the API to be used with the client request. Constant value: "2018-06-01-preview". + :ivar api_version: Version of the API to be used with the client request. Constant value: "2018-01-01". """ models = models @@ -32,7 +32,7 @@ def __init__(self, client, config, serializer, deserializer): self._client = client self._serialize = serializer self._deserialize = deserializer - self.api_version = "2018-06-01-preview" + self.api_version = "2018-01-01" self.config = config diff --git a/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/api_release_operations.py b/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/api_release_operations.py index a5f7c741cb87..a9bc52e3744d 100644 --- a/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/api_release_operations.py +++ b/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/api_release_operations.py @@ -22,7 +22,7 @@ class ApiReleaseOperations(object): :param config: Configuration of service client. :param serializer: An object model serializer. :param deserializer: An object model deserializer. - :ivar api_version: Version of the API to be used with the client request. Constant value: "2018-06-01-preview". + :ivar api_version: Version of the API to be used with the client request. Constant value: "2018-01-01". """ models = models @@ -32,7 +32,7 @@ def __init__(self, client, config, serializer, deserializer): self._client = client self._serialize = serializer self._deserialize = deserializer - self.api_version = "2018-06-01-preview" + self.api_version = "2018-01-01" self.config = config diff --git a/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/api_revisions_operations.py b/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/api_revisions_operations.py index 4e3f81948e78..93b577d75ce9 100644 --- a/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/api_revisions_operations.py +++ b/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/api_revisions_operations.py @@ -22,7 +22,7 @@ class ApiRevisionsOperations(object): :param config: Configuration of service client. :param serializer: An object model serializer. :param deserializer: An object model deserializer. - :ivar api_version: Version of the API to be used with the client request. Constant value: "2018-06-01-preview". + :ivar api_version: Version of the API to be used with the client request. Constant value: "2018-01-01". """ models = models @@ -32,7 +32,7 @@ def __init__(self, client, config, serializer, deserializer): self._client = client self._serialize = serializer self._deserialize = deserializer - self.api_version = "2018-06-01-preview" + self.api_version = "2018-01-01" self.config = config diff --git a/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/api_schema_operations.py b/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/api_schema_operations.py index aef68e1eb5e1..840e113bf93a 100644 --- a/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/api_schema_operations.py +++ b/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/api_schema_operations.py @@ -22,7 +22,7 @@ class ApiSchemaOperations(object): :param config: Configuration of service client. :param serializer: An object model serializer. :param deserializer: An object model deserializer. - :ivar api_version: Version of the API to be used with the client request. Constant value: "2018-06-01-preview". + :ivar api_version: Version of the API to be used with the client request. Constant value: "2018-01-01". """ models = models @@ -32,7 +32,7 @@ def __init__(self, client, config, serializer, deserializer): self._client = client self._serialize = serializer self._deserialize = deserializer - self.api_version = "2018-06-01-preview" + self.api_version = "2018-01-01" self.config = config diff --git a/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/api_version_set_operations.py b/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/api_version_set_operations.py index f97fca24c7da..857602360179 100644 --- a/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/api_version_set_operations.py +++ b/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/api_version_set_operations.py @@ -22,7 +22,7 @@ class ApiVersionSetOperations(object): :param config: Configuration of service client. :param serializer: An object model serializer. :param deserializer: An object model deserializer. - :ivar api_version: Version of the API to be used with the client request. Constant value: "2018-06-01-preview". + :ivar api_version: Version of the API to be used with the client request. Constant value: "2018-01-01". """ models = models @@ -32,7 +32,7 @@ def __init__(self, client, config, serializer, deserializer): self._client = client self._serialize = serializer self._deserialize = deserializer - self.api_version = "2018-06-01-preview" + self.api_version = "2018-01-01" self.config = config diff --git a/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/authorization_server_operations.py b/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/authorization_server_operations.py index 70dcb7eb8eaa..c5eae94af39f 100644 --- a/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/authorization_server_operations.py +++ b/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/authorization_server_operations.py @@ -23,7 +23,7 @@ class AuthorizationServerOperations(object): :param config: Configuration of service client. :param serializer: An object model serializer. :param deserializer: An object model deserializer. - :ivar api_version: Version of the API to be used with the client request. Constant value: "2018-06-01-preview". + :ivar api_version: Version of the API to be used with the client request. Constant value: "2018-01-01". """ models = models @@ -33,7 +33,7 @@ def __init__(self, client, config, serializer, deserializer): self._client = client self._serialize = serializer self._deserialize = deserializer - self.api_version = "2018-06-01-preview" + self.api_version = "2018-01-01" self.config = config diff --git a/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/backend_operations.py b/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/backend_operations.py index bde77d78deab..f0830ff2ecfa 100644 --- a/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/backend_operations.py +++ b/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/backend_operations.py @@ -22,7 +22,7 @@ class BackendOperations(object): :param config: Configuration of service client. :param serializer: An object model serializer. :param deserializer: An object model deserializer. - :ivar api_version: Version of the API to be used with the client request. Constant value: "2018-06-01-preview". + :ivar api_version: Version of the API to be used with the client request. Constant value: "2018-01-01". """ models = models @@ -32,7 +32,7 @@ def __init__(self, client, config, serializer, deserializer): self._client = client self._serialize = serializer self._deserialize = deserializer - self.api_version = "2018-06-01-preview" + self.api_version = "2018-01-01" self.config = config diff --git a/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/certificate_operations.py b/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/certificate_operations.py index c279191ed789..4c36d9ddeea0 100644 --- a/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/certificate_operations.py +++ b/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/certificate_operations.py @@ -22,7 +22,7 @@ class CertificateOperations(object): :param config: Configuration of service client. :param serializer: An object model serializer. :param deserializer: An object model deserializer. - :ivar api_version: Version of the API to be used with the client request. Constant value: "2018-06-01-preview". + :ivar api_version: Version of the API to be used with the client request. Constant value: "2018-01-01". """ models = models @@ -32,7 +32,7 @@ def __init__(self, client, config, serializer, deserializer): self._client = client self._serialize = serializer self._deserialize = deserializer - self.api_version = "2018-06-01-preview" + self.api_version = "2018-01-01" self.config = config diff --git a/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/delegation_settings_operations.py b/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/delegation_settings_operations.py index 7de3330366d9..a43ca87018ba 100644 --- a/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/delegation_settings_operations.py +++ b/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/delegation_settings_operations.py @@ -23,7 +23,7 @@ class DelegationSettingsOperations(object): :param config: Configuration of service client. :param serializer: An object model serializer. :param deserializer: An object model deserializer. - :ivar api_version: Version of the API to be used with the client request. Constant value: "2018-06-01-preview". + :ivar api_version: Version of the API to be used with the client request. Constant value: "2018-01-01". """ models = models @@ -33,7 +33,7 @@ def __init__(self, client, config, serializer, deserializer): self._client = client self._serialize = serializer self._deserialize = deserializer - self.api_version = "2018-06-01-preview" + self.api_version = "2018-01-01" self.config = config diff --git a/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/diagnostic_logger_operations.py b/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/diagnostic_logger_operations.py new file mode 100644 index 000000000000..3f7477ddbfa7 --- /dev/null +++ b/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/diagnostic_logger_operations.py @@ -0,0 +1,323 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +import uuid +from msrest.pipeline import ClientRawResponse + +from .. import models + + +class DiagnosticLoggerOperations(object): + """DiagnosticLoggerOperations operations. + + :param client: Client for service requests. + :param config: Configuration of service client. + :param serializer: An object model serializer. + :param deserializer: An object model deserializer. + :ivar api_version: Version of the API to be used with the client request. Constant value: "2018-01-01". + """ + + models = models + + def __init__(self, client, config, serializer, deserializer): + + self._client = client + self._serialize = serializer + self._deserialize = deserializer + self.api_version = "2018-01-01" + + self.config = config + + def list_by_service( + self, resource_group_name, service_name, diagnostic_id, filter=None, top=None, skip=None, custom_headers=None, raw=False, **operation_config): + """Lists all loggers assosiated with the specified Diagnostic of the API + Management service instance. + + :param resource_group_name: The name of the resource group. + :type resource_group_name: str + :param service_name: The name of the API Management service. + :type service_name: str + :param diagnostic_id: Diagnostic identifier. Must be unique in the + current API Management service instance. + :type diagnostic_id: str + :param filter: | Field | Supported operators | Supported + functions | + |-------------|------------------------|-----------------------------------| + | id | ge, le, eq, ne, gt, lt | substringof, startswith, + endswith | + | type | eq | + | + :type filter: str + :param top: Number of records to return. + :type top: int + :param skip: Number of records to skip. + :type skip: int + :param dict custom_headers: headers that will be added to the request + :param bool raw: returns the direct response alongside the + deserialized response + :param operation_config: :ref:`Operation configuration + overrides`. + :return: An iterator like instance of LoggerContract + :rtype: + ~azure.mgmt.apimanagement.models.LoggerContractPaged[~azure.mgmt.apimanagement.models.LoggerContract] + :raises: + :class:`ErrorResponseException` + """ + def internal_paging(next_link=None, raw=False): + + if not next_link: + # Construct URL + url = self.list_by_service.metadata['url'] + path_format_arguments = { + 'resourceGroupName': self._serialize.url("resource_group_name", resource_group_name, 'str'), + 'serviceName': self._serialize.url("service_name", service_name, 'str', max_length=50, min_length=1, pattern=r'^[a-zA-Z](?:[a-zA-Z0-9-]*[a-zA-Z0-9])?$'), + 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str'), + 'diagnosticId': self._serialize.url("diagnostic_id", diagnostic_id, 'str', max_length=80, min_length=1, pattern=r'(^[\w]+$)|(^[\w][\w\-]+[\w]$)') + } + url = self._client.format_url(url, **path_format_arguments) + + # Construct parameters + query_parameters = {} + query_parameters['api-version'] = self._serialize.query("self.api_version", self.api_version, 'str') + if filter is not None: + query_parameters['$filter'] = self._serialize.query("filter", filter, 'str') + if top is not None: + query_parameters['$top'] = self._serialize.query("top", top, 'int', minimum=1) + if skip is not None: + query_parameters['$skip'] = self._serialize.query("skip", skip, 'int', minimum=0) + + else: + url = next_link + query_parameters = {} + + # Construct headers + header_parameters = {} + header_parameters['Accept'] = 'application/json' + if self.config.generate_client_request_id: + header_parameters['x-ms-client-request-id'] = str(uuid.uuid1()) + if custom_headers: + header_parameters.update(custom_headers) + if self.config.accept_language is not None: + header_parameters['accept-language'] = self._serialize.header("self.config.accept_language", self.config.accept_language, 'str') + + # Construct and send request + request = self._client.get(url, query_parameters, header_parameters) + response = self._client.send(request, stream=False, **operation_config) + + if response.status_code not in [200]: + raise models.ErrorResponseException(self._deserialize, response) + + return response + + # Deserialize response + deserialized = models.LoggerContractPaged(internal_paging, self._deserialize.dependencies) + + if raw: + header_dict = {} + client_raw_response = models.LoggerContractPaged(internal_paging, self._deserialize.dependencies, header_dict) + return client_raw_response + + return deserialized + list_by_service.metadata = {'url': '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ApiManagement/service/{serviceName}/diagnostics/{diagnosticId}/loggers'} + + def check_entity_exists( + self, resource_group_name, service_name, diagnostic_id, loggerid, custom_headers=None, raw=False, **operation_config): + """Checks that logger entity specified by identifier is associated with + the diagnostics entity. + + :param resource_group_name: The name of the resource group. + :type resource_group_name: str + :param service_name: The name of the API Management service. + :type service_name: str + :param diagnostic_id: Diagnostic identifier. Must be unique in the + current API Management service instance. + :type diagnostic_id: str + :param loggerid: Logger identifier. Must be unique in the API + Management service instance. + :type loggerid: str + :param dict custom_headers: headers that will be added to the request + :param bool raw: returns the direct response alongside the + deserialized response + :param operation_config: :ref:`Operation configuration + overrides`. + :return: bool or ClientRawResponse if raw=true + :rtype: bool or ~msrest.pipeline.ClientRawResponse + :raises: + :class:`ErrorResponseException` + """ + # Construct URL + url = self.check_entity_exists.metadata['url'] + path_format_arguments = { + 'resourceGroupName': self._serialize.url("resource_group_name", resource_group_name, 'str'), + 'serviceName': self._serialize.url("service_name", service_name, 'str', max_length=50, min_length=1, pattern=r'^[a-zA-Z](?:[a-zA-Z0-9-]*[a-zA-Z0-9])?$'), + 'diagnosticId': self._serialize.url("diagnostic_id", diagnostic_id, 'str', max_length=80, min_length=1, pattern=r'(^[\w]+$)|(^[\w][\w\-]+[\w]$)'), + 'loggerid': self._serialize.url("loggerid", loggerid, 'str', max_length=80, pattern=r'(^[\w]+$)|(^[\w][\w\-]+[\w]$)'), + 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str') + } + url = self._client.format_url(url, **path_format_arguments) + + # Construct parameters + query_parameters = {} + query_parameters['api-version'] = self._serialize.query("self.api_version", self.api_version, 'str') + + # Construct headers + header_parameters = {} + if self.config.generate_client_request_id: + header_parameters['x-ms-client-request-id'] = str(uuid.uuid1()) + if custom_headers: + header_parameters.update(custom_headers) + if self.config.accept_language is not None: + header_parameters['accept-language'] = self._serialize.header("self.config.accept_language", self.config.accept_language, 'str') + + # Construct and send request + request = self._client.head(url, query_parameters, header_parameters) + response = self._client.send(request, stream=False, **operation_config) + + if response.status_code not in [204, 404]: + raise models.ErrorResponseException(self._deserialize, response) + + deserialized = (response.status_code == 204) + if raw: + client_raw_response = ClientRawResponse(deserialized, response) + return client_raw_response + return deserialized + check_entity_exists.metadata = {'url': '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ApiManagement/service/{serviceName}/diagnostics/{diagnosticId}/loggers/{loggerid}'} + + def create_or_update( + self, resource_group_name, service_name, diagnostic_id, loggerid, custom_headers=None, raw=False, **operation_config): + """Attaches a logger to a dignostic. + + :param resource_group_name: The name of the resource group. + :type resource_group_name: str + :param service_name: The name of the API Management service. + :type service_name: str + :param diagnostic_id: Diagnostic identifier. Must be unique in the + current API Management service instance. + :type diagnostic_id: str + :param loggerid: Logger identifier. Must be unique in the API + Management service instance. + :type loggerid: str + :param dict custom_headers: headers that will be added to the request + :param bool raw: returns the direct response alongside the + deserialized response + :param operation_config: :ref:`Operation configuration + overrides`. + :return: LoggerContract or ClientRawResponse if raw=true + :rtype: ~azure.mgmt.apimanagement.models.LoggerContract or + ~msrest.pipeline.ClientRawResponse + :raises: + :class:`ErrorResponseException` + """ + # Construct URL + url = self.create_or_update.metadata['url'] + path_format_arguments = { + 'resourceGroupName': self._serialize.url("resource_group_name", resource_group_name, 'str'), + 'serviceName': self._serialize.url("service_name", service_name, 'str', max_length=50, min_length=1, pattern=r'^[a-zA-Z](?:[a-zA-Z0-9-]*[a-zA-Z0-9])?$'), + 'diagnosticId': self._serialize.url("diagnostic_id", diagnostic_id, 'str', max_length=80, min_length=1, pattern=r'(^[\w]+$)|(^[\w][\w\-]+[\w]$)'), + 'loggerid': self._serialize.url("loggerid", loggerid, 'str', max_length=80, pattern=r'(^[\w]+$)|(^[\w][\w\-]+[\w]$)'), + 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str') + } + url = self._client.format_url(url, **path_format_arguments) + + # Construct parameters + query_parameters = {} + query_parameters['api-version'] = self._serialize.query("self.api_version", self.api_version, 'str') + + # Construct headers + header_parameters = {} + header_parameters['Accept'] = 'application/json' + if self.config.generate_client_request_id: + header_parameters['x-ms-client-request-id'] = str(uuid.uuid1()) + if custom_headers: + header_parameters.update(custom_headers) + if self.config.accept_language is not None: + header_parameters['accept-language'] = self._serialize.header("self.config.accept_language", self.config.accept_language, 'str') + + # Construct and send request + request = self._client.put(url, query_parameters, header_parameters) + response = self._client.send(request, stream=False, **operation_config) + + if response.status_code not in [200, 201]: + raise models.ErrorResponseException(self._deserialize, response) + + deserialized = None + + if response.status_code == 200: + deserialized = self._deserialize('LoggerContract', response) + if response.status_code == 201: + deserialized = self._deserialize('LoggerContract', response) + + if raw: + client_raw_response = ClientRawResponse(deserialized, response) + return client_raw_response + + return deserialized + create_or_update.metadata = {'url': '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ApiManagement/service/{serviceName}/diagnostics/{diagnosticId}/loggers/{loggerid}'} + + def delete( + self, resource_group_name, service_name, diagnostic_id, loggerid, custom_headers=None, raw=False, **operation_config): + """Deletes the specified Logger from Diagnostic. + + :param resource_group_name: The name of the resource group. + :type resource_group_name: str + :param service_name: The name of the API Management service. + :type service_name: str + :param diagnostic_id: Diagnostic identifier. Must be unique in the + current API Management service instance. + :type diagnostic_id: str + :param loggerid: Logger identifier. Must be unique in the API + Management service instance. + :type loggerid: str + :param dict custom_headers: headers that will be added to the request + :param bool raw: returns the direct response alongside the + deserialized response + :param operation_config: :ref:`Operation configuration + overrides`. + :return: None or ClientRawResponse if raw=true + :rtype: None or ~msrest.pipeline.ClientRawResponse + :raises: + :class:`ErrorResponseException` + """ + # Construct URL + url = self.delete.metadata['url'] + path_format_arguments = { + 'resourceGroupName': self._serialize.url("resource_group_name", resource_group_name, 'str'), + 'serviceName': self._serialize.url("service_name", service_name, 'str', max_length=50, min_length=1, pattern=r'^[a-zA-Z](?:[a-zA-Z0-9-]*[a-zA-Z0-9])?$'), + 'diagnosticId': self._serialize.url("diagnostic_id", diagnostic_id, 'str', max_length=80, min_length=1, pattern=r'(^[\w]+$)|(^[\w][\w\-]+[\w]$)'), + 'loggerid': self._serialize.url("loggerid", loggerid, 'str', max_length=80, pattern=r'(^[\w]+$)|(^[\w][\w\-]+[\w]$)'), + 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str') + } + url = self._client.format_url(url, **path_format_arguments) + + # Construct parameters + query_parameters = {} + query_parameters['api-version'] = self._serialize.query("self.api_version", self.api_version, 'str') + + # Construct headers + header_parameters = {} + if self.config.generate_client_request_id: + header_parameters['x-ms-client-request-id'] = str(uuid.uuid1()) + if custom_headers: + header_parameters.update(custom_headers) + if self.config.accept_language is not None: + header_parameters['accept-language'] = self._serialize.header("self.config.accept_language", self.config.accept_language, 'str') + + # Construct and send request + request = self._client.delete(url, query_parameters, header_parameters) + response = self._client.send(request, stream=False, **operation_config) + + if response.status_code not in [200, 204]: + raise models.ErrorResponseException(self._deserialize, response) + + if raw: + client_raw_response = ClientRawResponse(None, response) + return client_raw_response + delete.metadata = {'url': '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ApiManagement/service/{serviceName}/diagnostics/{diagnosticId}/loggers/{loggerid}'} diff --git a/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/diagnostic_operations.py b/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/diagnostic_operations.py index 5ab22378dd81..6cc4144a945f 100644 --- a/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/diagnostic_operations.py +++ b/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/diagnostic_operations.py @@ -22,7 +22,7 @@ class DiagnosticOperations(object): :param config: Configuration of service client. :param serializer: An object model serializer. :param deserializer: An object model deserializer. - :ivar api_version: Version of the API to be used with the client request. Constant value: "2018-06-01-preview". + :ivar api_version: Version of the API to be used with the client request. Constant value: "2018-01-01". """ models = models @@ -32,7 +32,7 @@ def __init__(self, client, config, serializer, deserializer): self._client = client self._serialize = serializer self._deserialize = deserializer - self.api_version = "2018-06-01-preview" + self.api_version = "2018-01-01" self.config = config @@ -252,7 +252,7 @@ def get( get.metadata = {'url': '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ApiManagement/service/{serviceName}/diagnostics/{diagnosticId}'} def create_or_update( - self, resource_group_name, service_name, diagnostic_id, parameters, if_match=None, custom_headers=None, raw=False, **operation_config): + self, resource_group_name, service_name, diagnostic_id, enabled, if_match=None, custom_headers=None, raw=False, **operation_config): """Creates a new Diagnostic or updates an existing one. :param resource_group_name: The name of the resource group. @@ -262,8 +262,9 @@ def create_or_update( :param diagnostic_id: Diagnostic identifier. Must be unique in the current API Management service instance. :type diagnostic_id: str - :param parameters: Create parameters. - :type parameters: ~azure.mgmt.apimanagement.models.DiagnosticContract + :param enabled: Indicates whether a diagnostic should receive data or + not. + :type enabled: bool :param if_match: ETag of the Entity. Not required when creating an entity, but required when updating an entity. :type if_match: str @@ -278,6 +279,8 @@ def create_or_update( :raises: :class:`ErrorResponseException` """ + parameters = models.DiagnosticContract(enabled=enabled) + # Construct URL url = self.create_or_update.metadata['url'] path_format_arguments = { @@ -330,7 +333,7 @@ def create_or_update( create_or_update.metadata = {'url': '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ApiManagement/service/{serviceName}/diagnostics/{diagnosticId}'} def update( - self, resource_group_name, service_name, diagnostic_id, parameters, if_match, custom_headers=None, raw=False, **operation_config): + self, resource_group_name, service_name, diagnostic_id, if_match, enabled, custom_headers=None, raw=False, **operation_config): """Updates the details of the Diagnostic specified by its identifier. :param resource_group_name: The name of the resource group. @@ -340,12 +343,13 @@ def update( :param diagnostic_id: Diagnostic identifier. Must be unique in the current API Management service instance. :type diagnostic_id: str - :param parameters: Diagnostic Update parameters. - :type parameters: ~azure.mgmt.apimanagement.models.DiagnosticContract :param if_match: ETag of the Entity. ETag should match the current entity state from the header response of the GET request or it should be * for unconditional update. :type if_match: str + :param enabled: Indicates whether a diagnostic should receive data or + not. + :type enabled: bool :param dict custom_headers: headers that will be added to the request :param bool raw: returns the direct response alongside the deserialized response @@ -356,6 +360,8 @@ def update( :raises: :class:`ErrorResponseException` """ + parameters = models.DiagnosticContract(enabled=enabled) + # Construct URL url = self.update.metadata['url'] path_format_arguments = { diff --git a/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/email_template_operations.py b/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/email_template_operations.py index 12a5db0b5b8c..96653c6abda1 100644 --- a/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/email_template_operations.py +++ b/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/email_template_operations.py @@ -23,7 +23,7 @@ class EmailTemplateOperations(object): :param config: Configuration of service client. :param serializer: An object model serializer. :param deserializer: An object model deserializer. - :ivar api_version: Version of the API to be used with the client request. Constant value: "2018-06-01-preview". + :ivar api_version: Version of the API to be used with the client request. Constant value: "2018-01-01". """ models = models @@ -33,7 +33,7 @@ def __init__(self, client, config, serializer, deserializer): self._client = client self._serialize = serializer self._deserialize = deserializer - self.api_version = "2018-06-01-preview" + self.api_version = "2018-01-01" self.config = config diff --git a/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/group_operations.py b/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/group_operations.py index 130c9808f628..c25ba92710c8 100644 --- a/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/group_operations.py +++ b/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/group_operations.py @@ -23,7 +23,7 @@ class GroupOperations(object): :param config: Configuration of service client. :param serializer: An object model serializer. :param deserializer: An object model deserializer. - :ivar api_version: Version of the API to be used with the client request. Constant value: "2018-06-01-preview". + :ivar api_version: Version of the API to be used with the client request. Constant value: "2018-01-01". """ models = models @@ -33,7 +33,7 @@ def __init__(self, client, config, serializer, deserializer): self._client = client self._serialize = serializer self._deserialize = deserializer - self.api_version = "2018-06-01-preview" + self.api_version = "2018-01-01" self.config = config diff --git a/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/group_user_operations.py b/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/group_user_operations.py index df749663809f..90e60fde0033 100644 --- a/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/group_user_operations.py +++ b/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/group_user_operations.py @@ -22,7 +22,7 @@ class GroupUserOperations(object): :param config: Configuration of service client. :param serializer: An object model serializer. :param deserializer: An object model deserializer. - :ivar api_version: Version of the API to be used with the client request. Constant value: "2018-06-01-preview". + :ivar api_version: Version of the API to be used with the client request. Constant value: "2018-01-01". """ models = models @@ -32,7 +32,7 @@ def __init__(self, client, config, serializer, deserializer): self._client = client self._serialize = serializer self._deserialize = deserializer - self.api_version = "2018-06-01-preview" + self.api_version = "2018-01-01" self.config = config diff --git a/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/identity_provider_operations.py b/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/identity_provider_operations.py index 460a6be4331b..764fcdb3a349 100644 --- a/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/identity_provider_operations.py +++ b/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/identity_provider_operations.py @@ -22,7 +22,7 @@ class IdentityProviderOperations(object): :param config: Configuration of service client. :param serializer: An object model serializer. :param deserializer: An object model deserializer. - :ivar api_version: Version of the API to be used with the client request. Constant value: "2018-06-01-preview". + :ivar api_version: Version of the API to be used with the client request. Constant value: "2018-01-01". """ models = models @@ -32,7 +32,7 @@ def __init__(self, client, config, serializer, deserializer): self._client = client self._serialize = serializer self._deserialize = deserializer - self.api_version = "2018-06-01-preview" + self.api_version = "2018-01-01" self.config = config diff --git a/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/logger_operations.py b/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/logger_operations.py index c8c63431964b..d86ffdc7f5fe 100644 --- a/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/logger_operations.py +++ b/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/logger_operations.py @@ -22,7 +22,7 @@ class LoggerOperations(object): :param config: Configuration of service client. :param serializer: An object model serializer. :param deserializer: An object model deserializer. - :ivar api_version: Version of the API to be used with the client request. Constant value: "2018-06-01-preview". + :ivar api_version: Version of the API to be used with the client request. Constant value: "2018-01-01". """ models = models @@ -32,7 +32,7 @@ def __init__(self, client, config, serializer, deserializer): self._client = client self._serialize = serializer self._deserialize = deserializer - self.api_version = "2018-06-01-preview" + self.api_version = "2018-01-01" self.config = config diff --git a/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/network_status_operations.py b/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/network_status_operations.py index d95a74576a3b..4ca95549cf00 100644 --- a/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/network_status_operations.py +++ b/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/network_status_operations.py @@ -22,7 +22,7 @@ class NetworkStatusOperations(object): :param config: Configuration of service client. :param serializer: An object model serializer. :param deserializer: An object model deserializer. - :ivar api_version: Version of the API to be used with the client request. Constant value: "2018-06-01-preview". + :ivar api_version: Version of the API to be used with the client request. Constant value: "2018-01-01". """ models = models @@ -32,7 +32,7 @@ def __init__(self, client, config, serializer, deserializer): self._client = client self._serialize = serializer self._deserialize = deserializer - self.api_version = "2018-06-01-preview" + self.api_version = "2018-01-01" self.config = config diff --git a/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/notification_operations.py b/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/notification_operations.py index bf728a64b625..4f0abab7ef4f 100644 --- a/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/notification_operations.py +++ b/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/notification_operations.py @@ -23,7 +23,7 @@ class NotificationOperations(object): :param config: Configuration of service client. :param serializer: An object model serializer. :param deserializer: An object model deserializer. - :ivar api_version: Version of the API to be used with the client request. Constant value: "2018-06-01-preview". + :ivar api_version: Version of the API to be used with the client request. Constant value: "2018-01-01". """ models = models @@ -33,7 +33,7 @@ def __init__(self, client, config, serializer, deserializer): self._client = client self._serialize = serializer self._deserialize = deserializer - self.api_version = "2018-06-01-preview" + self.api_version = "2018-01-01" self.config = config diff --git a/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/notification_recipient_email_operations.py b/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/notification_recipient_email_operations.py index 59c299a8a79a..327db8d4310c 100644 --- a/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/notification_recipient_email_operations.py +++ b/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/notification_recipient_email_operations.py @@ -22,7 +22,7 @@ class NotificationRecipientEmailOperations(object): :param config: Configuration of service client. :param serializer: An object model serializer. :param deserializer: An object model deserializer. - :ivar api_version: Version of the API to be used with the client request. Constant value: "2018-06-01-preview". + :ivar api_version: Version of the API to be used with the client request. Constant value: "2018-01-01". """ models = models @@ -32,7 +32,7 @@ def __init__(self, client, config, serializer, deserializer): self._client = client self._serialize = serializer self._deserialize = deserializer - self.api_version = "2018-06-01-preview" + self.api_version = "2018-01-01" self.config = config diff --git a/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/notification_recipient_user_operations.py b/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/notification_recipient_user_operations.py index 61f25748e683..519805924706 100644 --- a/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/notification_recipient_user_operations.py +++ b/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/notification_recipient_user_operations.py @@ -22,7 +22,7 @@ class NotificationRecipientUserOperations(object): :param config: Configuration of service client. :param serializer: An object model serializer. :param deserializer: An object model deserializer. - :ivar api_version: Version of the API to be used with the client request. Constant value: "2018-06-01-preview". + :ivar api_version: Version of the API to be used with the client request. Constant value: "2018-01-01". """ models = models @@ -32,7 +32,7 @@ def __init__(self, client, config, serializer, deserializer): self._client = client self._serialize = serializer self._deserialize = deserializer - self.api_version = "2018-06-01-preview" + self.api_version = "2018-01-01" self.config = config diff --git a/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/open_id_connect_provider_operations.py b/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/open_id_connect_provider_operations.py index e1d710c12a4e..eb6151adee2c 100644 --- a/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/open_id_connect_provider_operations.py +++ b/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/open_id_connect_provider_operations.py @@ -23,7 +23,7 @@ class OpenIdConnectProviderOperations(object): :param config: Configuration of service client. :param serializer: An object model serializer. :param deserializer: An object model deserializer. - :ivar api_version: Version of the API to be used with the client request. Constant value: "2018-06-01-preview". + :ivar api_version: Version of the API to be used with the client request. Constant value: "2018-01-01". """ models = models @@ -33,7 +33,7 @@ def __init__(self, client, config, serializer, deserializer): self._client = client self._serialize = serializer self._deserialize = deserializer - self.api_version = "2018-06-01-preview" + self.api_version = "2018-01-01" self.config = config diff --git a/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/operation_operations.py b/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/operation_operations.py index 66ddcf561c84..46f16f6e1129 100644 --- a/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/operation_operations.py +++ b/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/operation_operations.py @@ -23,7 +23,7 @@ class OperationOperations(object): :param config: Configuration of service client. :param serializer: An object model serializer. :param deserializer: An object model deserializer. - :ivar api_version: Version of the API to be used with the client request. Constant value: "2018-06-01-preview". + :ivar api_version: Version of the API to be used with the client request. Constant value: "2018-01-01". """ models = models @@ -33,7 +33,7 @@ def __init__(self, client, config, serializer, deserializer): self._client = client self._serialize = serializer self._deserialize = deserializer - self.api_version = "2018-06-01-preview" + self.api_version = "2018-01-01" self.config = config diff --git a/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/policy_operations.py b/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/policy_operations.py index b9b89a7c4230..e564813dfa05 100644 --- a/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/policy_operations.py +++ b/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/policy_operations.py @@ -23,7 +23,7 @@ class PolicyOperations(object): :param config: Configuration of service client. :param serializer: An object model serializer. :param deserializer: An object model deserializer. - :ivar api_version: Version of the API to be used with the client request. Constant value: "2018-06-01-preview". + :ivar api_version: Version of the API to be used with the client request. Constant value: "2018-01-01". :ivar policy_id: The identifier of the Policy. Constant value: "policy". """ @@ -34,7 +34,7 @@ def __init__(self, client, config, serializer, deserializer): self._client = client self._serialize = serializer self._deserialize = deserializer - self.api_version = "2018-06-01-preview" + self.api_version = "2018-01-01" self.policy_id = "policy" self.config = config diff --git a/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/policy_snippets_operations.py b/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/policy_snippets_operations.py index 9eb852087cd9..073cd8de13c0 100644 --- a/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/policy_snippets_operations.py +++ b/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/policy_snippets_operations.py @@ -23,7 +23,7 @@ class PolicySnippetsOperations(object): :param config: Configuration of service client. :param serializer: An object model serializer. :param deserializer: An object model deserializer. - :ivar api_version: Version of the API to be used with the client request. Constant value: "2018-06-01-preview". + :ivar api_version: Version of the API to be used with the client request. Constant value: "2018-01-01". """ models = models @@ -33,7 +33,7 @@ def __init__(self, client, config, serializer, deserializer): self._client = client self._serialize = serializer self._deserialize = deserializer - self.api_version = "2018-06-01-preview" + self.api_version = "2018-01-01" self.config = config diff --git a/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/product_api_operations.py b/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/product_api_operations.py index 98974e416e73..bd5e5c9be192 100644 --- a/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/product_api_operations.py +++ b/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/product_api_operations.py @@ -22,7 +22,7 @@ class ProductApiOperations(object): :param config: Configuration of service client. :param serializer: An object model serializer. :param deserializer: An object model deserializer. - :ivar api_version: Version of the API to be used with the client request. Constant value: "2018-06-01-preview". + :ivar api_version: Version of the API to be used with the client request. Constant value: "2018-01-01". """ models = models @@ -32,7 +32,7 @@ def __init__(self, client, config, serializer, deserializer): self._client = client self._serialize = serializer self._deserialize = deserializer - self.api_version = "2018-06-01-preview" + self.api_version = "2018-01-01" self.config = config diff --git a/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/product_group_operations.py b/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/product_group_operations.py index 68d4123ad879..0094fee005ba 100644 --- a/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/product_group_operations.py +++ b/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/product_group_operations.py @@ -22,7 +22,7 @@ class ProductGroupOperations(object): :param config: Configuration of service client. :param serializer: An object model serializer. :param deserializer: An object model deserializer. - :ivar api_version: Version of the API to be used with the client request. Constant value: "2018-06-01-preview". + :ivar api_version: Version of the API to be used with the client request. Constant value: "2018-01-01". """ models = models @@ -32,7 +32,7 @@ def __init__(self, client, config, serializer, deserializer): self._client = client self._serialize = serializer self._deserialize = deserializer - self.api_version = "2018-06-01-preview" + self.api_version = "2018-01-01" self.config = config diff --git a/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/product_operations.py b/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/product_operations.py index 387713e13481..d1c93d44123c 100644 --- a/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/product_operations.py +++ b/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/product_operations.py @@ -22,7 +22,7 @@ class ProductOperations(object): :param config: Configuration of service client. :param serializer: An object model serializer. :param deserializer: An object model deserializer. - :ivar api_version: Version of the API to be used with the client request. Constant value: "2018-06-01-preview". + :ivar api_version: Version of the API to be used with the client request. Constant value: "2018-01-01". """ models = models @@ -32,7 +32,7 @@ def __init__(self, client, config, serializer, deserializer): self._client = client self._serialize = serializer self._deserialize = deserializer - self.api_version = "2018-06-01-preview" + self.api_version = "2018-01-01" self.config = config diff --git a/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/product_policy_operations.py b/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/product_policy_operations.py index f4b6548b7e65..7c544c3ce3d1 100644 --- a/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/product_policy_operations.py +++ b/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/product_policy_operations.py @@ -22,7 +22,7 @@ class ProductPolicyOperations(object): :param config: Configuration of service client. :param serializer: An object model serializer. :param deserializer: An object model deserializer. - :ivar api_version: Version of the API to be used with the client request. Constant value: "2018-06-01-preview". + :ivar api_version: Version of the API to be used with the client request. Constant value: "2018-01-01". :ivar policy_id: The identifier of the Policy. Constant value: "policy". """ @@ -33,7 +33,7 @@ def __init__(self, client, config, serializer, deserializer): self._client = client self._serialize = serializer self._deserialize = deserializer - self.api_version = "2018-06-01-preview" + self.api_version = "2018-01-01" self.policy_id = "policy" self.config = config diff --git a/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/product_subscriptions_operations.py b/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/product_subscriptions_operations.py index 46d1982e6dc8..b91eea2bdbee 100644 --- a/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/product_subscriptions_operations.py +++ b/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/product_subscriptions_operations.py @@ -22,7 +22,7 @@ class ProductSubscriptionsOperations(object): :param config: Configuration of service client. :param serializer: An object model serializer. :param deserializer: An object model deserializer. - :ivar api_version: Version of the API to be used with the client request. Constant value: "2018-06-01-preview". + :ivar api_version: Version of the API to be used with the client request. Constant value: "2018-01-01". """ models = models @@ -32,7 +32,7 @@ def __init__(self, client, config, serializer, deserializer): self._client = client self._serialize = serializer self._deserialize = deserializer - self.api_version = "2018-06-01-preview" + self.api_version = "2018-01-01" self.config = config diff --git a/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/property_operations.py b/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/property_operations.py index 0e34da6794f8..d45ccc034af2 100644 --- a/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/property_operations.py +++ b/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/property_operations.py @@ -23,7 +23,7 @@ class PropertyOperations(object): :param config: Configuration of service client. :param serializer: An object model serializer. :param deserializer: An object model deserializer. - :ivar api_version: Version of the API to be used with the client request. Constant value: "2018-06-01-preview". + :ivar api_version: Version of the API to be used with the client request. Constant value: "2018-01-01". """ models = models @@ -33,7 +33,7 @@ def __init__(self, client, config, serializer, deserializer): self._client = client self._serialize = serializer self._deserialize = deserializer - self.api_version = "2018-06-01-preview" + self.api_version = "2018-01-01" self.config = config diff --git a/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/quota_by_counter_keys_operations.py b/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/quota_by_counter_keys_operations.py index fcbcc2e1f2c1..3722a4f234aa 100644 --- a/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/quota_by_counter_keys_operations.py +++ b/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/quota_by_counter_keys_operations.py @@ -22,7 +22,7 @@ class QuotaByCounterKeysOperations(object): :param config: Configuration of service client. :param serializer: An object model serializer. :param deserializer: An object model deserializer. - :ivar api_version: Version of the API to be used with the client request. Constant value: "2018-06-01-preview". + :ivar api_version: Version of the API to be used with the client request. Constant value: "2018-01-01". """ models = models @@ -32,7 +32,7 @@ def __init__(self, client, config, serializer, deserializer): self._client = client self._serialize = serializer self._deserialize = deserializer - self.api_version = "2018-06-01-preview" + self.api_version = "2018-01-01" self.config = config diff --git a/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/quota_by_period_keys_operations.py b/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/quota_by_period_keys_operations.py index 332103c253e7..09bd84880a0c 100644 --- a/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/quota_by_period_keys_operations.py +++ b/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/quota_by_period_keys_operations.py @@ -22,7 +22,7 @@ class QuotaByPeriodKeysOperations(object): :param config: Configuration of service client. :param serializer: An object model serializer. :param deserializer: An object model deserializer. - :ivar api_version: Version of the API to be used with the client request. Constant value: "2018-06-01-preview". + :ivar api_version: Version of the API to be used with the client request. Constant value: "2018-01-01". """ models = models @@ -32,7 +32,7 @@ def __init__(self, client, config, serializer, deserializer): self._client = client self._serialize = serializer self._deserialize = deserializer - self.api_version = "2018-06-01-preview" + self.api_version = "2018-01-01" self.config = config diff --git a/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/regions_operations.py b/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/regions_operations.py index d1c9c8a62718..a6dc3b0f1a41 100644 --- a/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/regions_operations.py +++ b/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/regions_operations.py @@ -23,7 +23,7 @@ class RegionsOperations(object): :param config: Configuration of service client. :param serializer: An object model serializer. :param deserializer: An object model deserializer. - :ivar api_version: Version of the API to be used with the client request. Constant value: "2018-06-01-preview". + :ivar api_version: Version of the API to be used with the client request. Constant value: "2018-01-01". """ models = models @@ -33,7 +33,7 @@ def __init__(self, client, config, serializer, deserializer): self._client = client self._serialize = serializer self._deserialize = deserializer - self.api_version = "2018-06-01-preview" + self.api_version = "2018-01-01" self.config = config diff --git a/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/reports_operations.py b/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/reports_operations.py index c84757ed332b..7c3144ee0261 100644 --- a/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/reports_operations.py +++ b/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/reports_operations.py @@ -23,7 +23,7 @@ class ReportsOperations(object): :param config: Configuration of service client. :param serializer: An object model serializer. :param deserializer: An object model deserializer. - :ivar api_version: Version of the API to be used with the client request. Constant value: "2018-06-01-preview". + :ivar api_version: Version of the API to be used with the client request. Constant value: "2018-01-01". """ models = models @@ -33,7 +33,7 @@ def __init__(self, client, config, serializer, deserializer): self._client = client self._serialize = serializer self._deserialize = deserializer - self.api_version = "2018-06-01-preview" + self.api_version = "2018-01-01" self.config = config diff --git a/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/sign_in_settings_operations.py b/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/sign_in_settings_operations.py index 0c03b0f13fbb..b77d65c4262a 100644 --- a/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/sign_in_settings_operations.py +++ b/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/sign_in_settings_operations.py @@ -23,7 +23,7 @@ class SignInSettingsOperations(object): :param config: Configuration of service client. :param serializer: An object model serializer. :param deserializer: An object model deserializer. - :ivar api_version: Version of the API to be used with the client request. Constant value: "2018-06-01-preview". + :ivar api_version: Version of the API to be used with the client request. Constant value: "2018-01-01". """ models = models @@ -33,7 +33,7 @@ def __init__(self, client, config, serializer, deserializer): self._client = client self._serialize = serializer self._deserialize = deserializer - self.api_version = "2018-06-01-preview" + self.api_version = "2018-01-01" self.config = config diff --git a/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/sign_up_settings_operations.py b/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/sign_up_settings_operations.py index ebcdf9cc4b04..1c037d109642 100644 --- a/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/sign_up_settings_operations.py +++ b/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/sign_up_settings_operations.py @@ -23,7 +23,7 @@ class SignUpSettingsOperations(object): :param config: Configuration of service client. :param serializer: An object model serializer. :param deserializer: An object model deserializer. - :ivar api_version: Version of the API to be used with the client request. Constant value: "2018-06-01-preview". + :ivar api_version: Version of the API to be used with the client request. Constant value: "2018-01-01". """ models = models @@ -33,7 +33,7 @@ def __init__(self, client, config, serializer, deserializer): self._client = client self._serialize = serializer self._deserialize = deserializer - self.api_version = "2018-06-01-preview" + self.api_version = "2018-01-01" self.config = config diff --git a/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/subscription_operations.py b/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/subscription_operations.py index 6b512bbd9a32..1ed52e66382b 100644 --- a/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/subscription_operations.py +++ b/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/subscription_operations.py @@ -22,7 +22,7 @@ class SubscriptionOperations(object): :param config: Configuration of service client. :param serializer: An object model serializer. :param deserializer: An object model deserializer. - :ivar api_version: Version of the API to be used with the client request. Constant value: "2018-06-01-preview". + :ivar api_version: Version of the API to be used with the client request. Constant value: "2018-01-01". """ models = models @@ -32,7 +32,7 @@ def __init__(self, client, config, serializer, deserializer): self._client = client self._serialize = serializer self._deserialize = deserializer - self.api_version = "2018-06-01-preview" + self.api_version = "2018-01-01" self.config = config diff --git a/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/tag_description_operations.py b/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/tag_description_operations.py index c7f822517912..4ebb20e31275 100644 --- a/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/tag_description_operations.py +++ b/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/tag_description_operations.py @@ -22,7 +22,7 @@ class TagDescriptionOperations(object): :param config: Configuration of service client. :param serializer: An object model serializer. :param deserializer: An object model deserializer. - :ivar api_version: Version of the API to be used with the client request. Constant value: "2018-06-01-preview". + :ivar api_version: Version of the API to be used with the client request. Constant value: "2018-01-01". """ models = models @@ -32,7 +32,7 @@ def __init__(self, client, config, serializer, deserializer): self._client = client self._serialize = serializer self._deserialize = deserializer - self.api_version = "2018-06-01-preview" + self.api_version = "2018-01-01" self.config = config diff --git a/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/tag_operations.py b/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/tag_operations.py index cd63ae1354d9..eee4a3eee21d 100644 --- a/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/tag_operations.py +++ b/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/tag_operations.py @@ -23,7 +23,7 @@ class TagOperations(object): :param config: Configuration of service client. :param serializer: An object model serializer. :param deserializer: An object model deserializer. - :ivar api_version: Version of the API to be used with the client request. Constant value: "2018-06-01-preview". + :ivar api_version: Version of the API to be used with the client request. Constant value: "2018-01-01". """ models = models @@ -33,7 +33,7 @@ def __init__(self, client, config, serializer, deserializer): self._client = client self._serialize = serializer self._deserialize = deserializer - self.api_version = "2018-06-01-preview" + self.api_version = "2018-01-01" self.config = config diff --git a/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/tag_resource_operations.py b/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/tag_resource_operations.py index 39b51ff42a0a..8834c67f5e97 100644 --- a/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/tag_resource_operations.py +++ b/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/tag_resource_operations.py @@ -23,7 +23,7 @@ class TagResourceOperations(object): :param config: Configuration of service client. :param serializer: An object model serializer. :param deserializer: An object model deserializer. - :ivar api_version: Version of the API to be used with the client request. Constant value: "2018-06-01-preview". + :ivar api_version: Version of the API to be used with the client request. Constant value: "2018-01-01". """ models = models @@ -33,7 +33,7 @@ def __init__(self, client, config, serializer, deserializer): self._client = client self._serialize = serializer self._deserialize = deserializer - self.api_version = "2018-06-01-preview" + self.api_version = "2018-01-01" self.config = config diff --git a/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/tenant_access_git_operations.py b/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/tenant_access_git_operations.py index 60213bd11d6b..626269771483 100644 --- a/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/tenant_access_git_operations.py +++ b/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/tenant_access_git_operations.py @@ -22,7 +22,7 @@ class TenantAccessGitOperations(object): :param config: Configuration of service client. :param serializer: An object model serializer. :param deserializer: An object model deserializer. - :ivar api_version: Version of the API to be used with the client request. Constant value: "2018-06-01-preview". + :ivar api_version: Version of the API to be used with the client request. Constant value: "2018-01-01". :ivar access_name: The identifier of the Access configuration. Constant value: "access". """ @@ -33,7 +33,7 @@ def __init__(self, client, config, serializer, deserializer): self._client = client self._serialize = serializer self._deserialize = deserializer - self.api_version = "2018-06-01-preview" + self.api_version = "2018-01-01" self.access_name = "access" self.config = config diff --git a/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/tenant_access_operations.py b/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/tenant_access_operations.py index 8b8f42030bb9..0d5403f0ee63 100644 --- a/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/tenant_access_operations.py +++ b/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/tenant_access_operations.py @@ -23,7 +23,7 @@ class TenantAccessOperations(object): :param config: Configuration of service client. :param serializer: An object model serializer. :param deserializer: An object model deserializer. - :ivar api_version: Version of the API to be used with the client request. Constant value: "2018-06-01-preview". + :ivar api_version: Version of the API to be used with the client request. Constant value: "2018-01-01". :ivar access_name: The identifier of the Access configuration. Constant value: "access". """ @@ -34,7 +34,7 @@ def __init__(self, client, config, serializer, deserializer): self._client = client self._serialize = serializer self._deserialize = deserializer - self.api_version = "2018-06-01-preview" + self.api_version = "2018-01-01" self.access_name = "access" self.config = config diff --git a/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/tenant_configuration_operations.py b/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/tenant_configuration_operations.py index 513c3e71f515..2b640a49dde5 100644 --- a/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/tenant_configuration_operations.py +++ b/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/tenant_configuration_operations.py @@ -25,7 +25,7 @@ class TenantConfigurationOperations(object): :param config: Configuration of service client. :param serializer: An object model serializer. :param deserializer: An object model deserializer. - :ivar api_version: Version of the API to be used with the client request. Constant value: "2018-06-01-preview". + :ivar api_version: Version of the API to be used with the client request. Constant value: "2018-01-01". :ivar configuration_name: The identifier of the Git Configuration Operation. Constant value: "configuration". """ @@ -36,7 +36,7 @@ def __init__(self, client, config, serializer, deserializer): self._client = client self._serialize = serializer self._deserialize = deserializer - self.api_version = "2018-06-01-preview" + self.api_version = "2018-01-01" self.configuration_name = "configuration" self.config = config diff --git a/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/user_group_operations.py b/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/user_group_operations.py index 25d5e8a69865..10c90866f585 100644 --- a/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/user_group_operations.py +++ b/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/user_group_operations.py @@ -22,7 +22,7 @@ class UserGroupOperations(object): :param config: Configuration of service client. :param serializer: An object model serializer. :param deserializer: An object model deserializer. - :ivar api_version: Version of the API to be used with the client request. Constant value: "2018-06-01-preview". + :ivar api_version: Version of the API to be used with the client request. Constant value: "2018-01-01". """ models = models @@ -32,7 +32,7 @@ def __init__(self, client, config, serializer, deserializer): self._client = client self._serialize = serializer self._deserialize = deserializer - self.api_version = "2018-06-01-preview" + self.api_version = "2018-01-01" self.config = config diff --git a/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/user_identities_operations.py b/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/user_identities_operations.py index d672dbab772b..32d58b37d88e 100644 --- a/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/user_identities_operations.py +++ b/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/user_identities_operations.py @@ -22,7 +22,7 @@ class UserIdentitiesOperations(object): :param config: Configuration of service client. :param serializer: An object model serializer. :param deserializer: An object model deserializer. - :ivar api_version: Version of the API to be used with the client request. Constant value: "2018-06-01-preview". + :ivar api_version: Version of the API to be used with the client request. Constant value: "2018-01-01". """ models = models @@ -32,7 +32,7 @@ def __init__(self, client, config, serializer, deserializer): self._client = client self._serialize = serializer self._deserialize = deserializer - self.api_version = "2018-06-01-preview" + self.api_version = "2018-01-01" self.config = config diff --git a/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/user_operations.py b/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/user_operations.py index 316d85ee096a..292e683e2735 100644 --- a/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/user_operations.py +++ b/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/user_operations.py @@ -22,7 +22,7 @@ class UserOperations(object): :param config: Configuration of service client. :param serializer: An object model serializer. :param deserializer: An object model deserializer. - :ivar api_version: Version of the API to be used with the client request. Constant value: "2018-06-01-preview". + :ivar api_version: Version of the API to be used with the client request. Constant value: "2018-01-01". """ models = models @@ -32,7 +32,7 @@ def __init__(self, client, config, serializer, deserializer): self._client = client self._serialize = serializer self._deserialize = deserializer - self.api_version = "2018-06-01-preview" + self.api_version = "2018-01-01" self.config = config diff --git a/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/user_subscription_operations.py b/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/user_subscription_operations.py index df837da6cbc9..964af1516d09 100644 --- a/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/user_subscription_operations.py +++ b/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/user_subscription_operations.py @@ -22,7 +22,7 @@ class UserSubscriptionOperations(object): :param config: Configuration of service client. :param serializer: An object model serializer. :param deserializer: An object model deserializer. - :ivar api_version: Version of the API to be used with the client request. Constant value: "2018-06-01-preview". + :ivar api_version: Version of the API to be used with the client request. Constant value: "2018-01-01". """ models = models @@ -32,7 +32,7 @@ def __init__(self, client, config, serializer, deserializer): self._client = client self._serialize = serializer self._deserialize = deserializer - self.api_version = "2018-06-01-preview" + self.api_version = "2018-01-01" self.config = config