diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/__init__.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/__init__.py index a25abe1811a6..f361c01f449f 100644 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/__init__.py +++ b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/__init__.py @@ -9,10 +9,11 @@ # regenerated. # -------------------------------------------------------------------------- -from .api_management_client import ApiManagementClient -from .version import VERSION +from ._configuration import ApiManagementClientConfiguration +from ._api_management_client import ApiManagementClient +__all__ = ['ApiManagementClient', 'ApiManagementClientConfiguration'] -__all__ = ['ApiManagementClient'] +from .version import VERSION __version__ = VERSION diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/api_management_client.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/_api_management_client.py similarity index 73% rename from sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/api_management_client.py rename to sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/_api_management_client.py index 123b9684fa27..7eb89f8e5be8 100644 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/api_management_client.py +++ b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/_api_management_client.py @@ -11,104 +11,70 @@ from msrest.service_client import SDKClient from msrest import Serializer, Deserializer -from msrestazure import AzureConfiguration -from .version import VERSION -from .operations.api_operations import ApiOperations -from .operations.api_revision_operations import ApiRevisionOperations -from .operations.api_release_operations import ApiReleaseOperations -from .operations.api_operation_operations import ApiOperationOperations -from .operations.api_operation_policy_operations import ApiOperationPolicyOperations -from .operations.tag_operations import TagOperations -from .operations.api_product_operations import ApiProductOperations -from .operations.api_policy_operations import ApiPolicyOperations -from .operations.api_schema_operations import ApiSchemaOperations -from .operations.api_diagnostic_operations import ApiDiagnosticOperations -from .operations.api_issue_operations import ApiIssueOperations -from .operations.api_issue_comment_operations import ApiIssueCommentOperations -from .operations.api_issue_attachment_operations import ApiIssueAttachmentOperations -from .operations.api_tag_description_operations import ApiTagDescriptionOperations -from .operations.operation_operations import OperationOperations -from .operations.api_version_set_operations import ApiVersionSetOperations -from .operations.authorization_server_operations import AuthorizationServerOperations -from .operations.backend_operations import BackendOperations -from .operations.cache_operations import CacheOperations -from .operations.certificate_operations import CertificateOperations -from .operations.api_management_operations import ApiManagementOperations -from .operations.api_management_service_skus_operations import ApiManagementServiceSkusOperations -from .operations.api_management_service_operations import ApiManagementServiceOperations -from .operations.diagnostic_operations import DiagnosticOperations -from .operations.email_template_operations import EmailTemplateOperations -from .operations.group_operations import GroupOperations -from .operations.group_user_operations import GroupUserOperations -from .operations.identity_provider_operations import IdentityProviderOperations -from .operations.issue_operations import IssueOperations -from .operations.logger_operations import LoggerOperations -from .operations.network_status_operations import NetworkStatusOperations -from .operations.notification_operations import NotificationOperations -from .operations.notification_recipient_user_operations import NotificationRecipientUserOperations -from .operations.notification_recipient_email_operations import NotificationRecipientEmailOperations -from .operations.open_id_connect_provider_operations import OpenIdConnectProviderOperations -from .operations.policy_operations import PolicyOperations -from .operations.policy_snippet_operations import PolicySnippetOperations -from .operations.sign_in_settings_operations import SignInSettingsOperations -from .operations.sign_up_settings_operations import SignUpSettingsOperations -from .operations.delegation_settings_operations import DelegationSettingsOperations -from .operations.product_operations import ProductOperations -from .operations.product_api_operations import ProductApiOperations -from .operations.product_group_operations import ProductGroupOperations -from .operations.product_subscriptions_operations import ProductSubscriptionsOperations -from .operations.product_policy_operations import ProductPolicyOperations -from .operations.property_operations import PropertyOperations -from .operations.quota_by_counter_keys_operations import QuotaByCounterKeysOperations -from .operations.quota_by_period_keys_operations import QuotaByPeriodKeysOperations -from .operations.region_operations import RegionOperations -from .operations.reports_operations import ReportsOperations -from .operations.subscription_operations import SubscriptionOperations -from .operations.tag_resource_operations import TagResourceOperations -from .operations.tenant_access_operations import TenantAccessOperations -from .operations.tenant_access_git_operations import TenantAccessGitOperations -from .operations.tenant_configuration_operations import TenantConfigurationOperations -from .operations.user_operations import UserOperations -from .operations.user_group_operations import UserGroupOperations -from .operations.user_subscription_operations import UserSubscriptionOperations -from .operations.user_identities_operations import UserIdentitiesOperations -from .operations.user_confirmation_password_operations import UserConfirmationPasswordOperations -from .operations.api_export_operations import ApiExportOperations -from . import models - - -class ApiManagementClientConfiguration(AzureConfiguration): - """Configuration for ApiManagementClient - Note that all parameters used to create this instance are saved as instance - attributes. - - :param credentials: Credentials needed for the client to connect to Azure. - :type credentials: :mod:`A msrestazure Credentials - object` - :param subscription_id: Subscription credentials which uniquely identify - Microsoft Azure subscription. The subscription ID forms part of the URI - for every service call. - :type subscription_id: str - :param str base_url: Service URL - """ - - def __init__( - self, credentials, subscription_id, base_url=None): - - if credentials is None: - raise ValueError("Parameter 'credentials' must not be None.") - if subscription_id is None: - raise ValueError("Parameter 'subscription_id' must not be None.") - if not base_url: - base_url = 'https://management.azure.com' - - super(ApiManagementClientConfiguration, self).__init__(base_url) - self.add_user_agent('azure-mgmt-apimanagement/{}'.format(VERSION)) - self.add_user_agent('Azure-SDK-For-Python') - - self.credentials = credentials - self.subscription_id = subscription_id +from ._configuration import ApiManagementClientConfiguration +from .operations import ApiOperations +from .operations import ApiRevisionOperations +from .operations import ApiReleaseOperations +from .operations import ApiOperationOperations +from .operations import ApiOperationPolicyOperations +from .operations import TagOperations +from .operations import ApiProductOperations +from .operations import ApiPolicyOperations +from .operations import ApiSchemaOperations +from .operations import ApiDiagnosticOperations +from .operations import ApiIssueOperations +from .operations import ApiIssueCommentOperations +from .operations import ApiIssueAttachmentOperations +from .operations import ApiTagDescriptionOperations +from .operations import OperationOperations +from .operations import ApiVersionSetOperations +from .operations import AuthorizationServerOperations +from .operations import BackendOperations +from .operations import CacheOperations +from .operations import CertificateOperations +from .operations import ApiManagementOperations +from .operations import ApiManagementServiceSkusOperations +from .operations import ApiManagementServiceOperations +from .operations import DiagnosticOperations +from .operations import EmailTemplateOperations +from .operations import GroupOperations +from .operations import GroupUserOperations +from .operations import IdentityProviderOperations +from .operations import IssueOperations +from .operations import LoggerOperations +from .operations import NetworkStatusOperations +from .operations import NotificationOperations +from .operations import NotificationRecipientUserOperations +from .operations import NotificationRecipientEmailOperations +from .operations import OpenIdConnectProviderOperations +from .operations import PolicyOperations +from .operations import PolicyDescriptionOperations +from .operations import SignInSettingsOperations +from .operations import SignUpSettingsOperations +from .operations import DelegationSettingsOperations +from .operations import ProductOperations +from .operations import ProductApiOperations +from .operations import ProductGroupOperations +from .operations import ProductSubscriptionsOperations +from .operations import ProductPolicyOperations +from .operations import NamedValueOperations +from .operations import QuotaByCounterKeysOperations +from .operations import QuotaByPeriodKeysOperations +from .operations import RegionOperations +from .operations import ReportsOperations +from .operations import SubscriptionOperations +from .operations import TagResourceOperations +from .operations import TenantAccessOperations +from .operations import TenantAccessGitOperations +from .operations import TenantConfigurationOperations +from .operations import UserOperations +from .operations import UserGroupOperations +from .operations import UserSubscriptionOperations +from .operations import UserIdentitiesOperations +from .operations import UserConfirmationPasswordOperations +from .operations import ApiExportOperations +from . import models class ApiManagementClient(SDKClient): @@ -189,8 +155,8 @@ class ApiManagementClient(SDKClient): :vartype open_id_connect_provider: azure.mgmt.apimanagement.operations.OpenIdConnectProviderOperations :ivar policy: Policy operations :vartype policy: azure.mgmt.apimanagement.operations.PolicyOperations - :ivar policy_snippet: PolicySnippet operations - :vartype policy_snippet: azure.mgmt.apimanagement.operations.PolicySnippetOperations + :ivar policy_description: PolicyDescription operations + :vartype policy_description: azure.mgmt.apimanagement.operations.PolicyDescriptionOperations :ivar sign_in_settings: SignInSettings operations :vartype sign_in_settings: azure.mgmt.apimanagement.operations.SignInSettingsOperations :ivar sign_up_settings: SignUpSettings operations @@ -207,8 +173,8 @@ class ApiManagementClient(SDKClient): :vartype product_subscriptions: azure.mgmt.apimanagement.operations.ProductSubscriptionsOperations :ivar product_policy: ProductPolicy operations :vartype product_policy: azure.mgmt.apimanagement.operations.ProductPolicyOperations - :ivar property: Property operations - :vartype property: azure.mgmt.apimanagement.operations.PropertyOperations + :ivar named_value: NamedValue operations + :vartype named_value: azure.mgmt.apimanagement.operations.NamedValueOperations :ivar quota_by_counter_keys: QuotaByCounterKeys operations :vartype quota_by_counter_keys: azure.mgmt.apimanagement.operations.QuotaByCounterKeysOperations :ivar quota_by_period_keys: QuotaByPeriodKeys operations @@ -257,7 +223,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 = '2019-01-01' + self.api_version = '2019-12-01-preview' self._serialize = Serializer(client_models) self._deserialize = Deserializer(client_models) @@ -333,7 +299,7 @@ def __init__( self._client, self.config, self._serialize, self._deserialize) self.policy = PolicyOperations( self._client, self.config, self._serialize, self._deserialize) - self.policy_snippet = PolicySnippetOperations( + self.policy_description = PolicyDescriptionOperations( self._client, self.config, self._serialize, self._deserialize) self.sign_in_settings = SignInSettingsOperations( self._client, self.config, self._serialize, self._deserialize) @@ -351,7 +317,7 @@ def __init__( self._client, self.config, self._serialize, self._deserialize) self.product_policy = ProductPolicyOperations( self._client, self.config, self._serialize, self._deserialize) - self.property = PropertyOperations( + self.named_value = NamedValueOperations( self._client, self.config, self._serialize, self._deserialize) self.quota_by_counter_keys = QuotaByCounterKeysOperations( self._client, self.config, self._serialize, self._deserialize) diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/_configuration.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/_configuration.py new file mode 100644 index 000000000000..ec13079f346d --- /dev/null +++ b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/_configuration.py @@ -0,0 +1,50 @@ +# 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 msrestazure import AzureConfiguration + +from .version import VERSION + + +class ApiManagementClientConfiguration(AzureConfiguration): + """Configuration for ApiManagementClient + Note that all parameters used to create this instance are saved as instance + attributes. + + :param credentials: Credentials needed for the client to connect to Azure. + :type credentials: :mod:`A msrestazure Credentials + object` + :param subscription_id: Subscription credentials which uniquely identify + Microsoft Azure subscription. The subscription ID forms part of the URI + for every service call. + :type subscription_id: str + :param str base_url: Service URL + """ + + def __init__( + self, credentials, subscription_id, base_url=None): + + if credentials is None: + raise ValueError("Parameter 'credentials' must not be None.") + if subscription_id is None: + raise ValueError("Parameter 'subscription_id' must not be None.") + if not base_url: + base_url = 'https://management.azure.com' + + super(ApiManagementClientConfiguration, self).__init__(base_url) + + # Starting Autorest.Python 4.0.64, make connection pool activated by default + self.keep_alive = True + + self.add_user_agent('azure-mgmt-apimanagement/{}'.format(VERSION)) + self.add_user_agent('Azure-SDK-For-Python') + + self.credentials = credentials + self.subscription_id = subscription_id diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/__init__.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/__init__.py index 5638845c3e6e..c6d2b8ed1c22 100644 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/__init__.py +++ b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/__init__.py @@ -10,352 +10,368 @@ # -------------------------------------------------------------------------- try: - from .error_field_contract_py3 import ErrorFieldContract - from .error_response_body_py3 import ErrorResponseBody - from .error_response_py3 import ErrorResponse, ErrorResponseException - from .region_contract_py3 import RegionContract - from .resource_py3 import Resource - from .api_export_result_value_py3 import ApiExportResultValue - from .api_export_result_py3 import ApiExportResult - from .product_entity_base_parameters_py3 import ProductEntityBaseParameters - from .product_tag_resource_contract_properties_py3 import ProductTagResourceContractProperties - from .operation_tag_resource_contract_properties_py3 import OperationTagResourceContractProperties - from .subscription_key_parameter_names_contract_py3 import SubscriptionKeyParameterNamesContract - from .open_id_authentication_settings_contract_py3 import OpenIdAuthenticationSettingsContract - from .oauth2_authentication_settings_contract_py3 import OAuth2AuthenticationSettingsContract - from .authentication_settings_contract_py3 import AuthenticationSettingsContract - from .api_version_set_contract_details_py3 import ApiVersionSetContractDetails - from .api_create_or_update_properties_wsdl_selector_py3 import ApiCreateOrUpdatePropertiesWsdlSelector - from .api_contract_properties_py3 import ApiContractProperties - from .api_entity_base_contract_py3 import ApiEntityBaseContract - from .api_tag_resource_contract_properties_py3 import ApiTagResourceContractProperties - from .tag_tag_resource_contract_properties_py3 import TagTagResourceContractProperties - from .tag_resource_contract_py3 import TagResourceContract - from .tag_contract_py3 import TagContract - from .tag_description_contract_py3 import TagDescriptionContract - from .tag_description_create_parameters_py3 import TagDescriptionCreateParameters - from .issue_attachment_contract_py3 import IssueAttachmentContract - from .issue_comment_contract_py3 import IssueCommentContract - from .issue_contract_base_properties_py3 import IssueContractBaseProperties - from .issue_update_contract_py3 import IssueUpdateContract - from .issue_contract_py3 import IssueContract - 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 .diagnostic_contract_py3 import DiagnosticContract - from .schema_contract_py3 import SchemaContract - from .schema_create_or_update_contract_py3 import SchemaCreateOrUpdateContract - from .policy_contract_py3 import PolicyContract - from .policy_collection_py3 import PolicyCollection - from .product_contract_py3 import ProductContract - from .parameter_contract_py3 import ParameterContract - from .representation_contract_py3 import RepresentationContract - from .response_contract_py3 import ResponseContract - from .request_contract_py3 import RequestContract - from .operation_entity_base_contract_py3 import OperationEntityBaseContract - from .operation_update_contract_py3 import OperationUpdateContract - from .operation_contract_py3 import OperationContract - from .api_release_contract_py3 import ApiReleaseContract - from .api_revision_contract_py3 import ApiRevisionContract - from .api_update_contract_py3 import ApiUpdateContract - from .api_contract_py3 import ApiContract - from .api_create_or_update_parameter_py3 import ApiCreateOrUpdateParameter - from .api_version_set_entity_base_py3 import ApiVersionSetEntityBase - from .api_version_set_update_parameters_py3 import ApiVersionSetUpdateParameters - from .api_version_set_contract_py3 import ApiVersionSetContract - from .token_body_parameter_contract_py3 import TokenBodyParameterContract - from .authorization_server_contract_base_properties_py3 import AuthorizationServerContractBaseProperties - from .authorization_server_update_contract_py3 import AuthorizationServerUpdateContract - from .authorization_server_contract_py3 import AuthorizationServerContract - from .backend_reconnect_contract_py3 import BackendReconnectContract - from .backend_tls_properties_py3 import BackendTlsProperties - from .backend_proxy_contract_py3 import BackendProxyContract - from .backend_authorization_header_credentials_py3 import BackendAuthorizationHeaderCredentials - from .backend_credentials_contract_py3 import BackendCredentialsContract - from .x509_certificate_name_py3 import X509CertificateName - from .backend_service_fabric_cluster_properties_py3 import BackendServiceFabricClusterProperties - from .backend_properties_py3 import BackendProperties - from .backend_base_parameters_py3 import BackendBaseParameters - from .backend_update_parameters_py3 import BackendUpdateParameters - from .backend_contract_py3 import BackendContract - from .cache_update_parameters_py3 import CacheUpdateParameters - from .cache_contract_py3 import CacheContract - from .certificate_contract_py3 import CertificateContract - from .certificate_create_or_update_parameters_py3 import CertificateCreateOrUpdateParameters - from .resource_sku_py3 import ResourceSku - from .resource_sku_capacity_py3 import ResourceSkuCapacity - from .resource_sku_result_py3 import ResourceSkuResult - from .certificate_information_py3 import CertificateInformation - from .certificate_configuration_py3 import CertificateConfiguration - from .hostname_configuration_py3 import HostnameConfiguration - from .virtual_network_configuration_py3 import VirtualNetworkConfiguration - from .api_management_service_sku_properties_py3 import ApiManagementServiceSkuProperties - from .additional_location_py3 import AdditionalLocation - from .api_management_service_backup_restore_parameters_py3 import ApiManagementServiceBackupRestoreParameters - from .api_management_service_base_properties_py3 import ApiManagementServiceBaseProperties - from .api_management_service_identity_py3 import ApiManagementServiceIdentity - from .api_management_service_resource_py3 import ApiManagementServiceResource - from .apim_resource_py3 import ApimResource - from .api_management_service_update_parameters_py3 import ApiManagementServiceUpdateParameters - from .api_management_service_get_sso_token_result_py3 import ApiManagementServiceGetSsoTokenResult - from .api_management_service_check_name_availability_parameters_py3 import ApiManagementServiceCheckNameAvailabilityParameters - from .api_management_service_name_availability_result_py3 import ApiManagementServiceNameAvailabilityResult - from .api_management_service_apply_network_configuration_parameters_py3 import ApiManagementServiceApplyNetworkConfigurationParameters - from .operation_display_py3 import OperationDisplay - from .operation_py3 import Operation - from .email_template_parameters_contract_properties_py3 import EmailTemplateParametersContractProperties - from .email_template_update_parameters_py3 import EmailTemplateUpdateParameters - from .email_template_contract_py3 import EmailTemplateContract - from .user_identity_contract_py3 import UserIdentityContract - from .user_entity_base_parameters_py3 import UserEntityBaseParameters - from .group_contract_properties_py3 import GroupContractProperties - from .user_contract_py3 import UserContract - from .group_update_parameters_py3 import GroupUpdateParameters - from .group_contract_py3 import GroupContract - from .group_create_parameters_py3 import GroupCreateParameters - from .identity_provider_base_parameters_py3 import IdentityProviderBaseParameters - from .identity_provider_update_parameters_py3 import IdentityProviderUpdateParameters - from .identity_provider_contract_py3 import IdentityProviderContract - from .logger_update_contract_py3 import LoggerUpdateContract - from .logger_contract_py3 import LoggerContract - from .connectivity_status_contract_py3 import ConnectivityStatusContract - from .network_status_contract_py3 import NetworkStatusContract - from .network_status_contract_by_location_py3 import NetworkStatusContractByLocation - from .recipient_email_contract_py3 import RecipientEmailContract - from .recipient_email_collection_py3 import RecipientEmailCollection - from .recipient_user_contract_py3 import RecipientUserContract - from .recipient_user_collection_py3 import RecipientUserCollection - from .recipients_contract_properties_py3 import RecipientsContractProperties - from .notification_contract_py3 import NotificationContract - from .openid_connect_provider_update_contract_py3 import OpenidConnectProviderUpdateContract - from .openid_connect_provider_contract_py3 import OpenidConnectProviderContract - from .policy_snippet_contract_py3 import PolicySnippetContract - from .policy_snippets_collection_py3 import PolicySnippetsCollection - from .registration_delegation_settings_properties_py3 import RegistrationDelegationSettingsProperties - from .subscriptions_delegation_settings_properties_py3 import SubscriptionsDelegationSettingsProperties - from .portal_delegation_settings_py3 import PortalDelegationSettings - from .terms_of_service_properties_py3 import TermsOfServiceProperties - from .portal_signup_settings_py3 import PortalSignupSettings - from .portal_signin_settings_py3 import PortalSigninSettings - from .subscription_contract_py3 import SubscriptionContract - from .product_update_parameters_py3 import ProductUpdateParameters - from .property_entity_base_parameters_py3 import PropertyEntityBaseParameters - from .property_update_parameters_py3 import PropertyUpdateParameters - from .property_contract_py3 import PropertyContract - from .quota_counter_value_contract_properties_py3 import QuotaCounterValueContractProperties - from .quota_counter_contract_py3 import QuotaCounterContract - from .quota_counter_collection_py3 import QuotaCounterCollection - from .request_report_record_contract_py3 import RequestReportRecordContract - from .report_record_contract_py3 import ReportRecordContract - from .subscription_update_parameters_py3 import SubscriptionUpdateParameters - from .subscription_create_parameters_py3 import SubscriptionCreateParameters - from .tag_create_update_parameters_py3 import TagCreateUpdateParameters - from .tenant_configuration_sync_state_contract_py3 import TenantConfigurationSyncStateContract - from .operation_result_log_item_contract_py3 import OperationResultLogItemContract - from .operation_result_contract_py3 import OperationResultContract - from .deploy_configuration_parameters_py3 import DeployConfigurationParameters - from .save_configuration_parameter_py3 import SaveConfigurationParameter - from .access_information_contract_py3 import AccessInformationContract - from .access_information_update_parameters_py3 import AccessInformationUpdateParameters - from .user_token_result_py3 import UserTokenResult - from .user_token_parameters_py3 import UserTokenParameters - from .generate_sso_url_result_py3 import GenerateSsoUrlResult - from .user_update_parameters_py3 import UserUpdateParameters - from .user_create_parameters_py3 import UserCreateParameters - from .api_revision_info_contract_py3 import ApiRevisionInfoContract - from .quota_counter_value_contract_py3 import QuotaCounterValueContract + from ._models_py3 import AccessInformationContract + from ._models_py3 import AccessInformationUpdateParameters + from ._models_py3 import AdditionalLocation + from ._models_py3 import ApiContract + from ._models_py3 import ApiContractProperties + from ._models_py3 import ApiCreateOrUpdateParameter + from ._models_py3 import ApiCreateOrUpdatePropertiesWsdlSelector + from ._models_py3 import ApiEntityBaseContract + from ._models_py3 import ApiExportResult + from ._models_py3 import ApiExportResultValue + from ._models_py3 import ApiManagementServiceApplyNetworkConfigurationParameters + from ._models_py3 import ApiManagementServiceBackupRestoreParameters + from ._models_py3 import ApiManagementServiceBaseProperties + from ._models_py3 import ApiManagementServiceCheckNameAvailabilityParameters + from ._models_py3 import ApiManagementServiceGetSsoTokenResult + from ._models_py3 import ApiManagementServiceIdentity + from ._models_py3 import ApiManagementServiceIdentityUserAssignedIdentitiesValue + from ._models_py3 import ApiManagementServiceNameAvailabilityResult + from ._models_py3 import ApiManagementServiceResource + from ._models_py3 import ApiManagementServiceSkuProperties + from ._models_py3 import ApiManagementServiceUpdateParameters + from ._models_py3 import ApimResource + from ._models_py3 import ApiReleaseContract + from ._models_py3 import ApiRevisionContract + from ._models_py3 import ApiRevisionInfoContract + from ._models_py3 import ApiTagResourceContractProperties + from ._models_py3 import ApiUpdateContract + from ._models_py3 import ApiVersionConstraint + from ._models_py3 import ApiVersionSetContract + from ._models_py3 import ApiVersionSetContractDetails + from ._models_py3 import ApiVersionSetEntityBase + from ._models_py3 import ApiVersionSetUpdateParameters + from ._models_py3 import AuthenticationSettingsContract + from ._models_py3 import AuthorizationServerContract + from ._models_py3 import AuthorizationServerContractBaseProperties + from ._models_py3 import AuthorizationServerUpdateContract + from ._models_py3 import BackendAuthorizationHeaderCredentials + from ._models_py3 import BackendBaseParameters + from ._models_py3 import BackendContract + from ._models_py3 import BackendCredentialsContract + from ._models_py3 import BackendProperties + from ._models_py3 import BackendProxyContract + from ._models_py3 import BackendReconnectContract + from ._models_py3 import BackendServiceFabricClusterProperties + from ._models_py3 import BackendTlsProperties + from ._models_py3 import BackendUpdateParameters + from ._models_py3 import BodyDiagnosticSettings + from ._models_py3 import CacheContract + from ._models_py3 import CacheUpdateParameters + from ._models_py3 import CertificateConfiguration + from ._models_py3 import CertificateContract + from ._models_py3 import CertificateCreateOrUpdateParameters + from ._models_py3 import CertificateInformation + from ._models_py3 import ClientSecretContract + from ._models_py3 import ConnectivityStatusContract + from ._models_py3 import DeployConfigurationParameters + from ._models_py3 import DiagnosticContract + from ._models_py3 import EmailTemplateContract + from ._models_py3 import EmailTemplateParametersContractProperties + from ._models_py3 import EmailTemplateUpdateParameters + from ._models_py3 import ErrorFieldContract + from ._models_py3 import ErrorResponse, ErrorResponseException + from ._models_py3 import ErrorResponseBody + from ._models_py3 import GenerateSsoUrlResult + from ._models_py3 import GroupContract + from ._models_py3 import GroupContractProperties + from ._models_py3 import GroupCreateParameters + from ._models_py3 import GroupUpdateParameters + from ._models_py3 import HostnameConfiguration + from ._models_py3 import HttpMessageDiagnostic + from ._models_py3 import IdentityProviderBaseParameters + from ._models_py3 import IdentityProviderContract + from ._models_py3 import IdentityProviderCreateContract + from ._models_py3 import IdentityProviderUpdateParameters + from ._models_py3 import IssueAttachmentContract + from ._models_py3 import IssueCommentContract + from ._models_py3 import IssueContract + from ._models_py3 import IssueContractBaseProperties + from ._models_py3 import IssueUpdateContract + from ._models_py3 import LoggerContract + from ._models_py3 import LoggerUpdateContract + from ._models_py3 import NamedValueContract + from ._models_py3 import NamedValueCreateContract + from ._models_py3 import NamedValueEntityBaseParameters + from ._models_py3 import NamedValueUpdateParameters + from ._models_py3 import NetworkStatusContract + from ._models_py3 import NetworkStatusContractByLocation + from ._models_py3 import NotificationContract + from ._models_py3 import OAuth2AuthenticationSettingsContract + from ._models_py3 import OpenIdAuthenticationSettingsContract + from ._models_py3 import OpenidConnectProviderContract + from ._models_py3 import OpenidConnectProviderCreateContract + from ._models_py3 import OpenidConnectProviderUpdateContract + from ._models_py3 import Operation + from ._models_py3 import OperationContract + from ._models_py3 import OperationDisplay + from ._models_py3 import OperationEntityBaseContract + from ._models_py3 import OperationResultContract + from ._models_py3 import OperationResultLogItemContract + from ._models_py3 import OperationTagResourceContractProperties + from ._models_py3 import OperationUpdateContract + from ._models_py3 import ParameterContract + from ._models_py3 import PipelineDiagnosticSettings + from ._models_py3 import PolicyCollection + from ._models_py3 import PolicyContract + from ._models_py3 import PolicyDescriptionCollection + from ._models_py3 import PolicyDescriptionContract + from ._models_py3 import PortalDelegationSettings + from ._models_py3 import PortalSettingValidationKeyContract + from ._models_py3 import PortalSigninSettings + from ._models_py3 import PortalSignupSettings + from ._models_py3 import ProductContract + from ._models_py3 import ProductEntityBaseParameters + from ._models_py3 import ProductTagResourceContractProperties + from ._models_py3 import ProductUpdateParameters + from ._models_py3 import PropertyValueContract + from ._models_py3 import QuotaCounterCollection + from ._models_py3 import QuotaCounterContract + from ._models_py3 import QuotaCounterValueContract + from ._models_py3 import QuotaCounterValueContractProperties + from ._models_py3 import RecipientEmailCollection + from ._models_py3 import RecipientEmailContract + from ._models_py3 import RecipientsContractProperties + from ._models_py3 import RecipientUserCollection + from ._models_py3 import RecipientUserContract + from ._models_py3 import RegionContract + from ._models_py3 import RegistrationDelegationSettingsProperties + from ._models_py3 import ReportRecordContract + from ._models_py3 import RepresentationContract + from ._models_py3 import RequestContract + from ._models_py3 import RequestReportRecordContract + from ._models_py3 import Resource + from ._models_py3 import ResourceSku + from ._models_py3 import ResourceSkuCapacity + from ._models_py3 import ResourceSkuResult + from ._models_py3 import ResponseContract + from ._models_py3 import SamplingSettings + from ._models_py3 import SaveConfigurationParameter + from ._models_py3 import SchemaContract + from ._models_py3 import SubscriptionContract + from ._models_py3 import SubscriptionCreateParameters + from ._models_py3 import SubscriptionKeyParameterNamesContract + from ._models_py3 import SubscriptionKeysContract + from ._models_py3 import SubscriptionsDelegationSettingsProperties + from ._models_py3 import SubscriptionUpdateParameters + from ._models_py3 import TagContract + from ._models_py3 import TagCreateUpdateParameters + from ._models_py3 import TagDescriptionContract + from ._models_py3 import TagDescriptionCreateParameters + from ._models_py3 import TagResourceContract + from ._models_py3 import TagTagResourceContractProperties + from ._models_py3 import TenantConfigurationSyncStateContract + from ._models_py3 import TermsOfServiceProperties + from ._models_py3 import TokenBodyParameterContract + from ._models_py3 import UserContract + from ._models_py3 import UserCreateParameters + from ._models_py3 import UserEntityBaseParameters + from ._models_py3 import UserIdentityContract + from ._models_py3 import UserTokenParameters + from ._models_py3 import UserTokenResult + from ._models_py3 import UserUpdateParameters + from ._models_py3 import VirtualNetworkConfiguration + from ._models_py3 import X509CertificateName except (SyntaxError, ImportError): - from .error_field_contract import ErrorFieldContract - from .error_response_body import ErrorResponseBody - from .error_response import ErrorResponse, ErrorResponseException - from .region_contract import RegionContract - from .resource import Resource - from .api_export_result_value import ApiExportResultValue - from .api_export_result import ApiExportResult - from .product_entity_base_parameters import ProductEntityBaseParameters - from .product_tag_resource_contract_properties import ProductTagResourceContractProperties - from .operation_tag_resource_contract_properties import OperationTagResourceContractProperties - from .subscription_key_parameter_names_contract import SubscriptionKeyParameterNamesContract - from .open_id_authentication_settings_contract import OpenIdAuthenticationSettingsContract - from .oauth2_authentication_settings_contract import OAuth2AuthenticationSettingsContract - from .authentication_settings_contract import AuthenticationSettingsContract - from .api_version_set_contract_details import ApiVersionSetContractDetails - from .api_create_or_update_properties_wsdl_selector import ApiCreateOrUpdatePropertiesWsdlSelector - from .api_contract_properties import ApiContractProperties - from .api_entity_base_contract import ApiEntityBaseContract - from .api_tag_resource_contract_properties import ApiTagResourceContractProperties - from .tag_tag_resource_contract_properties import TagTagResourceContractProperties - from .tag_resource_contract import TagResourceContract - from .tag_contract import TagContract - from .tag_description_contract import TagDescriptionContract - from .tag_description_create_parameters import TagDescriptionCreateParameters - from .issue_attachment_contract import IssueAttachmentContract - from .issue_comment_contract import IssueCommentContract - from .issue_contract_base_properties import IssueContractBaseProperties - from .issue_update_contract import IssueUpdateContract - from .issue_contract import IssueContract - from .body_diagnostic_settings import BodyDiagnosticSettings - from .http_message_diagnostic import HttpMessageDiagnostic - from .pipeline_diagnostic_settings import PipelineDiagnosticSettings - from .sampling_settings import SamplingSettings - from .diagnostic_contract import DiagnosticContract - from .schema_contract import SchemaContract - from .schema_create_or_update_contract import SchemaCreateOrUpdateContract - from .policy_contract import PolicyContract - from .policy_collection import PolicyCollection - from .product_contract import ProductContract - from .parameter_contract import ParameterContract - from .representation_contract import RepresentationContract - from .response_contract import ResponseContract - from .request_contract import RequestContract - from .operation_entity_base_contract import OperationEntityBaseContract - from .operation_update_contract import OperationUpdateContract - from .operation_contract import OperationContract - from .api_release_contract import ApiReleaseContract - from .api_revision_contract import ApiRevisionContract - from .api_update_contract import ApiUpdateContract - from .api_contract import ApiContract - from .api_create_or_update_parameter import ApiCreateOrUpdateParameter - from .api_version_set_entity_base import ApiVersionSetEntityBase - from .api_version_set_update_parameters import ApiVersionSetUpdateParameters - from .api_version_set_contract import ApiVersionSetContract - from .token_body_parameter_contract import TokenBodyParameterContract - from .authorization_server_contract_base_properties import AuthorizationServerContractBaseProperties - from .authorization_server_update_contract import AuthorizationServerUpdateContract - from .authorization_server_contract import AuthorizationServerContract - from .backend_reconnect_contract import BackendReconnectContract - from .backend_tls_properties import BackendTlsProperties - from .backend_proxy_contract import BackendProxyContract - from .backend_authorization_header_credentials import BackendAuthorizationHeaderCredentials - from .backend_credentials_contract import BackendCredentialsContract - from .x509_certificate_name import X509CertificateName - from .backend_service_fabric_cluster_properties import BackendServiceFabricClusterProperties - from .backend_properties import BackendProperties - from .backend_base_parameters import BackendBaseParameters - from .backend_update_parameters import BackendUpdateParameters - from .backend_contract import BackendContract - from .cache_update_parameters import CacheUpdateParameters - from .cache_contract import CacheContract - from .certificate_contract import CertificateContract - from .certificate_create_or_update_parameters import CertificateCreateOrUpdateParameters - from .resource_sku import ResourceSku - from .resource_sku_capacity import ResourceSkuCapacity - from .resource_sku_result import ResourceSkuResult - from .certificate_information import CertificateInformation - from .certificate_configuration import CertificateConfiguration - from .hostname_configuration import HostnameConfiguration - from .virtual_network_configuration import VirtualNetworkConfiguration - from .api_management_service_sku_properties import ApiManagementServiceSkuProperties - from .additional_location import AdditionalLocation - from .api_management_service_backup_restore_parameters import ApiManagementServiceBackupRestoreParameters - from .api_management_service_base_properties import ApiManagementServiceBaseProperties - from .api_management_service_identity import ApiManagementServiceIdentity - from .api_management_service_resource import ApiManagementServiceResource - from .apim_resource import ApimResource - from .api_management_service_update_parameters import ApiManagementServiceUpdateParameters - from .api_management_service_get_sso_token_result import ApiManagementServiceGetSsoTokenResult - from .api_management_service_check_name_availability_parameters import ApiManagementServiceCheckNameAvailabilityParameters - from .api_management_service_name_availability_result import ApiManagementServiceNameAvailabilityResult - from .api_management_service_apply_network_configuration_parameters import ApiManagementServiceApplyNetworkConfigurationParameters - from .operation_display import OperationDisplay - from .operation import Operation - from .email_template_parameters_contract_properties import EmailTemplateParametersContractProperties - from .email_template_update_parameters import EmailTemplateUpdateParameters - from .email_template_contract import EmailTemplateContract - from .user_identity_contract import UserIdentityContract - from .user_entity_base_parameters import UserEntityBaseParameters - from .group_contract_properties import GroupContractProperties - from .user_contract import UserContract - from .group_update_parameters import GroupUpdateParameters - from .group_contract import GroupContract - from .group_create_parameters import GroupCreateParameters - from .identity_provider_base_parameters import IdentityProviderBaseParameters - from .identity_provider_update_parameters import IdentityProviderUpdateParameters - from .identity_provider_contract import IdentityProviderContract - from .logger_update_contract import LoggerUpdateContract - from .logger_contract import LoggerContract - from .connectivity_status_contract import ConnectivityStatusContract - from .network_status_contract import NetworkStatusContract - from .network_status_contract_by_location import NetworkStatusContractByLocation - from .recipient_email_contract import RecipientEmailContract - from .recipient_email_collection import RecipientEmailCollection - from .recipient_user_contract import RecipientUserContract - from .recipient_user_collection import RecipientUserCollection - from .recipients_contract_properties import RecipientsContractProperties - from .notification_contract import NotificationContract - from .openid_connect_provider_update_contract import OpenidConnectProviderUpdateContract - from .openid_connect_provider_contract import OpenidConnectProviderContract - from .policy_snippet_contract import PolicySnippetContract - from .policy_snippets_collection import PolicySnippetsCollection - from .registration_delegation_settings_properties import RegistrationDelegationSettingsProperties - from .subscriptions_delegation_settings_properties import SubscriptionsDelegationSettingsProperties - from .portal_delegation_settings import PortalDelegationSettings - from .terms_of_service_properties import TermsOfServiceProperties - from .portal_signup_settings import PortalSignupSettings - from .portal_signin_settings import PortalSigninSettings - from .subscription_contract import SubscriptionContract - from .product_update_parameters import ProductUpdateParameters - from .property_entity_base_parameters import PropertyEntityBaseParameters - from .property_update_parameters import PropertyUpdateParameters - from .property_contract import PropertyContract - from .quota_counter_value_contract_properties import QuotaCounterValueContractProperties - from .quota_counter_contract import QuotaCounterContract - from .quota_counter_collection import QuotaCounterCollection - from .request_report_record_contract import RequestReportRecordContract - from .report_record_contract import ReportRecordContract - from .subscription_update_parameters import SubscriptionUpdateParameters - from .subscription_create_parameters import SubscriptionCreateParameters - from .tag_create_update_parameters import TagCreateUpdateParameters - from .tenant_configuration_sync_state_contract import TenantConfigurationSyncStateContract - from .operation_result_log_item_contract import OperationResultLogItemContract - from .operation_result_contract import OperationResultContract - from .deploy_configuration_parameters import DeployConfigurationParameters - from .save_configuration_parameter import SaveConfigurationParameter - from .access_information_contract import AccessInformationContract - from .access_information_update_parameters import AccessInformationUpdateParameters - from .user_token_result import UserTokenResult - from .user_token_parameters import UserTokenParameters - from .generate_sso_url_result import GenerateSsoUrlResult - from .user_update_parameters import UserUpdateParameters - from .user_create_parameters import UserCreateParameters - from .api_revision_info_contract import ApiRevisionInfoContract - from .quota_counter_value_contract import QuotaCounterValueContract -from .api_contract_paged import ApiContractPaged -from .tag_resource_contract_paged import TagResourceContractPaged -from .api_revision_contract_paged import ApiRevisionContractPaged -from .api_release_contract_paged import ApiReleaseContractPaged -from .operation_contract_paged import OperationContractPaged -from .tag_contract_paged import TagContractPaged -from .product_contract_paged import ProductContractPaged -from .schema_contract_paged import SchemaContractPaged -from .diagnostic_contract_paged import DiagnosticContractPaged -from .issue_contract_paged import IssueContractPaged -from .issue_comment_contract_paged import IssueCommentContractPaged -from .issue_attachment_contract_paged import IssueAttachmentContractPaged -from .tag_description_contract_paged import TagDescriptionContractPaged -from .api_version_set_contract_paged import ApiVersionSetContractPaged -from .authorization_server_contract_paged import AuthorizationServerContractPaged -from .backend_contract_paged import BackendContractPaged -from .cache_contract_paged import CacheContractPaged -from .certificate_contract_paged import CertificateContractPaged -from .operation_paged import OperationPaged -from .resource_sku_result_paged import ResourceSkuResultPaged -from .api_management_service_resource_paged import ApiManagementServiceResourcePaged -from .email_template_contract_paged import EmailTemplateContractPaged -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 -from .property_contract_paged import PropertyContractPaged -from .region_contract_paged import RegionContractPaged -from .report_record_contract_paged import ReportRecordContractPaged -from .request_report_record_contract_paged import RequestReportRecordContractPaged -from .user_identity_contract_paged import UserIdentityContractPaged -from .api_management_client_enums import ( + from ._models import AccessInformationContract + from ._models import AccessInformationUpdateParameters + from ._models import AdditionalLocation + from ._models import ApiContract + from ._models import ApiContractProperties + from ._models import ApiCreateOrUpdateParameter + from ._models import ApiCreateOrUpdatePropertiesWsdlSelector + from ._models import ApiEntityBaseContract + from ._models import ApiExportResult + from ._models import ApiExportResultValue + from ._models import ApiManagementServiceApplyNetworkConfigurationParameters + from ._models import ApiManagementServiceBackupRestoreParameters + from ._models import ApiManagementServiceBaseProperties + from ._models import ApiManagementServiceCheckNameAvailabilityParameters + from ._models import ApiManagementServiceGetSsoTokenResult + from ._models import ApiManagementServiceIdentity + from ._models import ApiManagementServiceIdentityUserAssignedIdentitiesValue + from ._models import ApiManagementServiceNameAvailabilityResult + from ._models import ApiManagementServiceResource + from ._models import ApiManagementServiceSkuProperties + from ._models import ApiManagementServiceUpdateParameters + from ._models import ApimResource + from ._models import ApiReleaseContract + from ._models import ApiRevisionContract + from ._models import ApiRevisionInfoContract + from ._models import ApiTagResourceContractProperties + from ._models import ApiUpdateContract + from ._models import ApiVersionConstraint + from ._models import ApiVersionSetContract + from ._models import ApiVersionSetContractDetails + from ._models import ApiVersionSetEntityBase + from ._models import ApiVersionSetUpdateParameters + from ._models import AuthenticationSettingsContract + from ._models import AuthorizationServerContract + from ._models import AuthorizationServerContractBaseProperties + from ._models import AuthorizationServerUpdateContract + from ._models import BackendAuthorizationHeaderCredentials + from ._models import BackendBaseParameters + from ._models import BackendContract + from ._models import BackendCredentialsContract + from ._models import BackendProperties + from ._models import BackendProxyContract + from ._models import BackendReconnectContract + from ._models import BackendServiceFabricClusterProperties + from ._models import BackendTlsProperties + from ._models import BackendUpdateParameters + from ._models import BodyDiagnosticSettings + from ._models import CacheContract + from ._models import CacheUpdateParameters + from ._models import CertificateConfiguration + from ._models import CertificateContract + from ._models import CertificateCreateOrUpdateParameters + from ._models import CertificateInformation + from ._models import ClientSecretContract + from ._models import ConnectivityStatusContract + from ._models import DeployConfigurationParameters + from ._models import DiagnosticContract + from ._models import EmailTemplateContract + from ._models import EmailTemplateParametersContractProperties + from ._models import EmailTemplateUpdateParameters + from ._models import ErrorFieldContract + from ._models import ErrorResponse, ErrorResponseException + from ._models import ErrorResponseBody + from ._models import GenerateSsoUrlResult + from ._models import GroupContract + from ._models import GroupContractProperties + from ._models import GroupCreateParameters + from ._models import GroupUpdateParameters + from ._models import HostnameConfiguration + from ._models import HttpMessageDiagnostic + from ._models import IdentityProviderBaseParameters + from ._models import IdentityProviderContract + from ._models import IdentityProviderCreateContract + from ._models import IdentityProviderUpdateParameters + from ._models import IssueAttachmentContract + from ._models import IssueCommentContract + from ._models import IssueContract + from ._models import IssueContractBaseProperties + from ._models import IssueUpdateContract + from ._models import LoggerContract + from ._models import LoggerUpdateContract + from ._models import NamedValueContract + from ._models import NamedValueCreateContract + from ._models import NamedValueEntityBaseParameters + from ._models import NamedValueUpdateParameters + from ._models import NetworkStatusContract + from ._models import NetworkStatusContractByLocation + from ._models import NotificationContract + from ._models import OAuth2AuthenticationSettingsContract + from ._models import OpenIdAuthenticationSettingsContract + from ._models import OpenidConnectProviderContract + from ._models import OpenidConnectProviderCreateContract + from ._models import OpenidConnectProviderUpdateContract + from ._models import Operation + from ._models import OperationContract + from ._models import OperationDisplay + from ._models import OperationEntityBaseContract + from ._models import OperationResultContract + from ._models import OperationResultLogItemContract + from ._models import OperationTagResourceContractProperties + from ._models import OperationUpdateContract + from ._models import ParameterContract + from ._models import PipelineDiagnosticSettings + from ._models import PolicyCollection + from ._models import PolicyContract + from ._models import PolicyDescriptionCollection + from ._models import PolicyDescriptionContract + from ._models import PortalDelegationSettings + from ._models import PortalSettingValidationKeyContract + from ._models import PortalSigninSettings + from ._models import PortalSignupSettings + from ._models import ProductContract + from ._models import ProductEntityBaseParameters + from ._models import ProductTagResourceContractProperties + from ._models import ProductUpdateParameters + from ._models import PropertyValueContract + from ._models import QuotaCounterCollection + from ._models import QuotaCounterContract + from ._models import QuotaCounterValueContract + from ._models import QuotaCounterValueContractProperties + from ._models import RecipientEmailCollection + from ._models import RecipientEmailContract + from ._models import RecipientsContractProperties + from ._models import RecipientUserCollection + from ._models import RecipientUserContract + from ._models import RegionContract + from ._models import RegistrationDelegationSettingsProperties + from ._models import ReportRecordContract + from ._models import RepresentationContract + from ._models import RequestContract + from ._models import RequestReportRecordContract + from ._models import Resource + from ._models import ResourceSku + from ._models import ResourceSkuCapacity + from ._models import ResourceSkuResult + from ._models import ResponseContract + from ._models import SamplingSettings + from ._models import SaveConfigurationParameter + from ._models import SchemaContract + from ._models import SubscriptionContract + from ._models import SubscriptionCreateParameters + from ._models import SubscriptionKeyParameterNamesContract + from ._models import SubscriptionKeysContract + from ._models import SubscriptionsDelegationSettingsProperties + from ._models import SubscriptionUpdateParameters + from ._models import TagContract + from ._models import TagCreateUpdateParameters + from ._models import TagDescriptionContract + from ._models import TagDescriptionCreateParameters + from ._models import TagResourceContract + from ._models import TagTagResourceContractProperties + from ._models import TenantConfigurationSyncStateContract + from ._models import TermsOfServiceProperties + from ._models import TokenBodyParameterContract + from ._models import UserContract + from ._models import UserCreateParameters + from ._models import UserEntityBaseParameters + from ._models import UserIdentityContract + from ._models import UserTokenParameters + from ._models import UserTokenResult + from ._models import UserUpdateParameters + from ._models import VirtualNetworkConfiguration + from ._models import X509CertificateName +from ._paged_models import ApiContractPaged +from ._paged_models import ApiManagementServiceResourcePaged +from ._paged_models import ApiReleaseContractPaged +from ._paged_models import ApiRevisionContractPaged +from ._paged_models import ApiVersionSetContractPaged +from ._paged_models import AuthorizationServerContractPaged +from ._paged_models import BackendContractPaged +from ._paged_models import CacheContractPaged +from ._paged_models import CertificateContractPaged +from ._paged_models import DiagnosticContractPaged +from ._paged_models import EmailTemplateContractPaged +from ._paged_models import GroupContractPaged +from ._paged_models import IdentityProviderContractPaged +from ._paged_models import IssueAttachmentContractPaged +from ._paged_models import IssueCommentContractPaged +from ._paged_models import IssueContractPaged +from ._paged_models import LoggerContractPaged +from ._paged_models import NamedValueContractPaged +from ._paged_models import NotificationContractPaged +from ._paged_models import OpenidConnectProviderContractPaged +from ._paged_models import OperationContractPaged +from ._paged_models import OperationPaged +from ._paged_models import ProductContractPaged +from ._paged_models import RegionContractPaged +from ._paged_models import ReportRecordContractPaged +from ._paged_models import RequestReportRecordContractPaged +from ._paged_models import ResourceSkuResultPaged +from ._paged_models import SchemaContractPaged +from ._paged_models import SubscriptionContractPaged +from ._paged_models import TagContractPaged +from ._paged_models import TagDescriptionContractPaged +from ._paged_models import TagResourceContractPaged +from ._paged_models import UserContractPaged +from ._paged_models import UserIdentityContractPaged +from ._api_management_client_enums import ( ExportResultFormat, ProductState, BearerTokenSendingMethods, @@ -366,6 +382,8 @@ State, SamplingType, AlwaysLog, + HttpCorrelationProtocol, + Verbosity, PolicyContentFormat, VersioningScheme, GrantType, @@ -377,6 +395,7 @@ ResourceSkuCapacityScaleType, HostnameType, VirtualNetworkType, + ApimIdentityType, NameAvailabilityReason, Confirmation, UserState, @@ -395,161 +414,169 @@ ) __all__ = [ - 'ErrorFieldContract', - 'ErrorResponseBody', - 'ErrorResponse', 'ErrorResponseException', - 'RegionContract', - 'Resource', - 'ApiExportResultValue', - 'ApiExportResult', - 'ProductEntityBaseParameters', - 'ProductTagResourceContractProperties', - 'OperationTagResourceContractProperties', - 'SubscriptionKeyParameterNamesContract', - 'OpenIdAuthenticationSettingsContract', - 'OAuth2AuthenticationSettingsContract', - 'AuthenticationSettingsContract', - 'ApiVersionSetContractDetails', - 'ApiCreateOrUpdatePropertiesWsdlSelector', + 'AccessInformationContract', + 'AccessInformationUpdateParameters', + 'AdditionalLocation', + 'ApiContract', 'ApiContractProperties', + 'ApiCreateOrUpdateParameter', + 'ApiCreateOrUpdatePropertiesWsdlSelector', 'ApiEntityBaseContract', - 'ApiTagResourceContractProperties', - 'TagTagResourceContractProperties', - 'TagResourceContract', - 'TagContract', - 'TagDescriptionContract', - 'TagDescriptionCreateParameters', - 'IssueAttachmentContract', - 'IssueCommentContract', - 'IssueContractBaseProperties', - 'IssueUpdateContract', - 'IssueContract', - 'BodyDiagnosticSettings', - 'HttpMessageDiagnostic', - 'PipelineDiagnosticSettings', - 'SamplingSettings', - 'DiagnosticContract', - 'SchemaContract', - 'SchemaCreateOrUpdateContract', - 'PolicyContract', - 'PolicyCollection', - 'ProductContract', - 'ParameterContract', - 'RepresentationContract', - 'ResponseContract', - 'RequestContract', - 'OperationEntityBaseContract', - 'OperationUpdateContract', - 'OperationContract', + 'ApiExportResult', + 'ApiExportResultValue', + 'ApiManagementServiceApplyNetworkConfigurationParameters', + 'ApiManagementServiceBackupRestoreParameters', + 'ApiManagementServiceBaseProperties', + 'ApiManagementServiceCheckNameAvailabilityParameters', + 'ApiManagementServiceGetSsoTokenResult', + 'ApiManagementServiceIdentity', + 'ApiManagementServiceIdentityUserAssignedIdentitiesValue', + 'ApiManagementServiceNameAvailabilityResult', + 'ApiManagementServiceResource', + 'ApiManagementServiceSkuProperties', + 'ApiManagementServiceUpdateParameters', + 'ApimResource', 'ApiReleaseContract', 'ApiRevisionContract', + 'ApiRevisionInfoContract', + 'ApiTagResourceContractProperties', 'ApiUpdateContract', - 'ApiContract', - 'ApiCreateOrUpdateParameter', + 'ApiVersionConstraint', + 'ApiVersionSetContract', + 'ApiVersionSetContractDetails', 'ApiVersionSetEntityBase', 'ApiVersionSetUpdateParameters', - 'ApiVersionSetContract', - 'TokenBodyParameterContract', + 'AuthenticationSettingsContract', + 'AuthorizationServerContract', 'AuthorizationServerContractBaseProperties', 'AuthorizationServerUpdateContract', - 'AuthorizationServerContract', - 'BackendReconnectContract', - 'BackendTlsProperties', - 'BackendProxyContract', 'BackendAuthorizationHeaderCredentials', + 'BackendBaseParameters', + 'BackendContract', 'BackendCredentialsContract', - 'X509CertificateName', - 'BackendServiceFabricClusterProperties', 'BackendProperties', - 'BackendBaseParameters', + 'BackendProxyContract', + 'BackendReconnectContract', + 'BackendServiceFabricClusterProperties', + 'BackendTlsProperties', 'BackendUpdateParameters', - 'BackendContract', - 'CacheUpdateParameters', + 'BodyDiagnosticSettings', 'CacheContract', + 'CacheUpdateParameters', + 'CertificateConfiguration', 'CertificateContract', 'CertificateCreateOrUpdateParameters', - 'ResourceSku', - 'ResourceSkuCapacity', - 'ResourceSkuResult', 'CertificateInformation', - 'CertificateConfiguration', - 'HostnameConfiguration', - 'VirtualNetworkConfiguration', - 'ApiManagementServiceSkuProperties', - 'AdditionalLocation', - 'ApiManagementServiceBackupRestoreParameters', - 'ApiManagementServiceBaseProperties', - 'ApiManagementServiceIdentity', - 'ApiManagementServiceResource', - 'ApimResource', - 'ApiManagementServiceUpdateParameters', - 'ApiManagementServiceGetSsoTokenResult', - 'ApiManagementServiceCheckNameAvailabilityParameters', - 'ApiManagementServiceNameAvailabilityResult', - 'ApiManagementServiceApplyNetworkConfigurationParameters', - 'OperationDisplay', - 'Operation', + 'ClientSecretContract', + 'ConnectivityStatusContract', + 'DeployConfigurationParameters', + 'DiagnosticContract', + 'EmailTemplateContract', 'EmailTemplateParametersContractProperties', 'EmailTemplateUpdateParameters', - 'EmailTemplateContract', - 'UserIdentityContract', - 'UserEntityBaseParameters', - 'GroupContractProperties', - 'UserContract', - 'GroupUpdateParameters', + 'ErrorFieldContract', + 'ErrorResponse', 'ErrorResponseException', + 'ErrorResponseBody', + 'GenerateSsoUrlResult', 'GroupContract', + 'GroupContractProperties', 'GroupCreateParameters', + 'GroupUpdateParameters', + 'HostnameConfiguration', + 'HttpMessageDiagnostic', 'IdentityProviderBaseParameters', - 'IdentityProviderUpdateParameters', 'IdentityProviderContract', - 'LoggerUpdateContract', + 'IdentityProviderCreateContract', + 'IdentityProviderUpdateParameters', + 'IssueAttachmentContract', + 'IssueCommentContract', + 'IssueContract', + 'IssueContractBaseProperties', + 'IssueUpdateContract', 'LoggerContract', - 'ConnectivityStatusContract', + 'LoggerUpdateContract', + 'NamedValueContract', + 'NamedValueCreateContract', + 'NamedValueEntityBaseParameters', + 'NamedValueUpdateParameters', 'NetworkStatusContract', 'NetworkStatusContractByLocation', - 'RecipientEmailContract', - 'RecipientEmailCollection', - 'RecipientUserContract', - 'RecipientUserCollection', - 'RecipientsContractProperties', 'NotificationContract', - 'OpenidConnectProviderUpdateContract', + 'OAuth2AuthenticationSettingsContract', + 'OpenIdAuthenticationSettingsContract', 'OpenidConnectProviderContract', - 'PolicySnippetContract', - 'PolicySnippetsCollection', - 'RegistrationDelegationSettingsProperties', - 'SubscriptionsDelegationSettingsProperties', + 'OpenidConnectProviderCreateContract', + 'OpenidConnectProviderUpdateContract', + 'Operation', + 'OperationContract', + 'OperationDisplay', + 'OperationEntityBaseContract', + 'OperationResultContract', + 'OperationResultLogItemContract', + 'OperationTagResourceContractProperties', + 'OperationUpdateContract', + 'ParameterContract', + 'PipelineDiagnosticSettings', + 'PolicyCollection', + 'PolicyContract', + 'PolicyDescriptionCollection', + 'PolicyDescriptionContract', 'PortalDelegationSettings', - 'TermsOfServiceProperties', - 'PortalSignupSettings', + 'PortalSettingValidationKeyContract', 'PortalSigninSettings', - 'SubscriptionContract', + 'PortalSignupSettings', + 'ProductContract', + 'ProductEntityBaseParameters', + 'ProductTagResourceContractProperties', 'ProductUpdateParameters', - 'PropertyEntityBaseParameters', - 'PropertyUpdateParameters', - 'PropertyContract', - 'QuotaCounterValueContractProperties', - 'QuotaCounterContract', + 'PropertyValueContract', 'QuotaCounterCollection', - 'RequestReportRecordContract', + 'QuotaCounterContract', + 'QuotaCounterValueContract', + 'QuotaCounterValueContractProperties', + 'RecipientEmailCollection', + 'RecipientEmailContract', + 'RecipientsContractProperties', + 'RecipientUserCollection', + 'RecipientUserContract', + 'RegionContract', + 'RegistrationDelegationSettingsProperties', 'ReportRecordContract', - 'SubscriptionUpdateParameters', + 'RepresentationContract', + 'RequestContract', + 'RequestReportRecordContract', + 'Resource', + 'ResourceSku', + 'ResourceSkuCapacity', + 'ResourceSkuResult', + 'ResponseContract', + 'SamplingSettings', + 'SaveConfigurationParameter', + 'SchemaContract', + 'SubscriptionContract', 'SubscriptionCreateParameters', + 'SubscriptionKeyParameterNamesContract', + 'SubscriptionKeysContract', + 'SubscriptionsDelegationSettingsProperties', + 'SubscriptionUpdateParameters', + 'TagContract', 'TagCreateUpdateParameters', + 'TagDescriptionContract', + 'TagDescriptionCreateParameters', + 'TagResourceContract', + 'TagTagResourceContractProperties', 'TenantConfigurationSyncStateContract', - 'OperationResultLogItemContract', - 'OperationResultContract', - 'DeployConfigurationParameters', - 'SaveConfigurationParameter', - 'AccessInformationContract', - 'AccessInformationUpdateParameters', - 'UserTokenResult', + 'TermsOfServiceProperties', + 'TokenBodyParameterContract', + 'UserContract', + 'UserCreateParameters', + 'UserEntityBaseParameters', + 'UserIdentityContract', 'UserTokenParameters', - 'GenerateSsoUrlResult', + 'UserTokenResult', 'UserUpdateParameters', - 'UserCreateParameters', - 'ApiRevisionInfoContract', - 'QuotaCounterValueContract', + 'VirtualNetworkConfiguration', + 'X509CertificateName', 'ApiContractPaged', 'TagResourceContractPaged', 'ApiRevisionContractPaged', @@ -579,7 +606,7 @@ 'NotificationContractPaged', 'OpenidConnectProviderContractPaged', 'SubscriptionContractPaged', - 'PropertyContractPaged', + 'NamedValueContractPaged', 'RegionContractPaged', 'ReportRecordContractPaged', 'RequestReportRecordContractPaged', @@ -594,6 +621,8 @@ 'State', 'SamplingType', 'AlwaysLog', + 'HttpCorrelationProtocol', + 'Verbosity', 'PolicyContentFormat', 'VersioningScheme', 'GrantType', @@ -605,6 +634,7 @@ 'ResourceSkuCapacityScaleType', 'HostnameType', 'VirtualNetworkType', + 'ApimIdentityType', 'NameAvailabilityReason', 'Confirmation', 'UserState', diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/api_management_client_enums.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/_api_management_client_enums.py similarity index 89% rename from sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/api_management_client_enums.py rename to sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/_api_management_client_enums.py index 8dd8aae6af1f..2de7c5311dc0 100644 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/api_management_client_enums.py +++ b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/_api_management_client_enums.py @@ -49,6 +49,7 @@ class ContentFormat(str, Enum): openapi = "openapi" #: The contents are inline and Content Type is a OpenApi 3.0 Document in YAML format. openapijson = "openapi+json" #: The contents are inline and Content Type is a OpenApi 3.0 Document in JSON format. openapi_link = "openapi-link" #: The Open Api 3.0 document is hosted on a publicly accessible internet address. + openapijson_link = "openapi+json-link" #: The Open Api 3.0 Json document is hosted on a publicly accessible internet address. class SoapApiType(str, Enum): @@ -82,6 +83,20 @@ class AlwaysLog(str, Enum): all_errors = "allErrors" #: Always log all erroneous request regardless of sampling settings. +class HttpCorrelationProtocol(str, Enum): + + none = "None" #: Do not read and inject correlation headers. + legacy = "Legacy" #: Inject Request-Id and Request-Context headers with request correlation data. See https://github.com/dotnet/corefx/blob/master/src/System.Diagnostics.DiagnosticSource/src/HttpCorrelationProtocol.md. + w3_c = "W3C" #: Inject Trace Context headers. See https://w3c.github.io/trace-context. + + +class Verbosity(str, Enum): + + verbose = "verbose" #: All the traces emitted by trace policies will be sent to the logger attached to this diagnostic instance. + information = "information" #: Traces with 'severity' set to 'information' and 'error' will be sent to the logger attached to this diagnostic instance. + error = "error" #: Only traces with 'severity' set to 'error' will be sent to the logger attached to this diagnostic instance. + + class PolicyContentFormat(str, Enum): xml = "xml" #: The contents are inline and Content type is an XML document. @@ -167,6 +182,14 @@ class VirtualNetworkType(str, Enum): internal = "Internal" #: The service is part of Virtual Network and it is only accessible from within the virtual network. +class ApimIdentityType(str, Enum): + + system_assigned = "SystemAssigned" + user_assigned = "UserAssigned" + system_assigned_user_assigned = "SystemAssigned, UserAssigned" + none = "None" + + class NameAvailabilityReason(str, Enum): valid = "Valid" @@ -292,3 +315,4 @@ class ExportFormat(str, Enum): wsdl = "wsdl-link" #: Export the Api Definition in WSDL Schema to Storage Blob. This is only supported for APIs of Type `soap` wadl = "wadl-link" #: Export the Api Definition in WADL Schema to Storage Blob. openapi = "openapi-link" #: Export the Api Definition in OpenApi Specification 3.0 to Storage Blob. + openapi_json = "openapi+json-link" #: Export the Api Definition in OpenApi Specification 3.0 as JSON document to Storage Blob. diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/_models.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/_models.py new file mode 100644 index 000000000000..a1742efc822f --- /dev/null +++ b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/_models.py @@ -0,0 +1,7689 @@ +# 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 +from msrest.exceptions import HttpOperationError + + +class AccessInformationContract(Model): + """Tenant access information contract of the API Management service. + + :param id: Identifier. + :type id: str + :param primary_key: Primary access key. This property will not be filled + on 'GET' operations! Use '/listSecrets' POST request to get the value. + :type primary_key: str + :param secondary_key: Secondary access key. This property will not be + filled on 'GET' operations! Use '/listSecrets' POST request to get the + value. + :type secondary_key: str + :param enabled: Determines whether direct access is enabled. + :type enabled: bool + """ + + _attribute_map = { + 'id': {'key': 'id', 'type': 'str'}, + 'primary_key': {'key': 'primaryKey', 'type': 'str'}, + 'secondary_key': {'key': 'secondaryKey', 'type': 'str'}, + 'enabled': {'key': 'enabled', 'type': 'bool'}, + } + + def __init__(self, **kwargs): + super(AccessInformationContract, self).__init__(**kwargs) + self.id = kwargs.get('id', None) + self.primary_key = kwargs.get('primary_key', None) + self.secondary_key = kwargs.get('secondary_key', None) + self.enabled = kwargs.get('enabled', None) + + +class AccessInformationUpdateParameters(Model): + """Tenant access information update parameters. + + :param enabled: Determines whether direct access is enabled. + :type enabled: bool + """ + + _attribute_map = { + 'enabled': {'key': 'properties.enabled', 'type': 'bool'}, + } + + def __init__(self, **kwargs): + super(AccessInformationUpdateParameters, self).__init__(**kwargs) + self.enabled = kwargs.get('enabled', None) + + +class AdditionalLocation(Model): + """Description of an additional API Management resource location. + + Variables are only populated by the server, and will be ignored when + sending a request. + + All required parameters must be populated in order to send to Azure. + + :param location: Required. The location name of the additional region + among Azure Data center regions. + :type location: str + :param sku: Required. SKU properties of the API Management service. + :type sku: + ~azure.mgmt.apimanagement.models.ApiManagementServiceSkuProperties + :ivar public_ip_addresses: Public Static Load Balanced IP addresses of the + API Management service in the additional location. Available only for + Basic, Standard and Premium SKU. + :vartype public_ip_addresses: list[str] + :ivar private_ip_addresses: Private Static Load Balanced IP addresses of + the API Management service which is deployed in an Internal Virtual + Network in a particular additional location. Available only for Basic, + Standard and Premium SKU. + :vartype private_ip_addresses: list[str] + :param virtual_network_configuration: Virtual network configuration for + the location. + :type virtual_network_configuration: + ~azure.mgmt.apimanagement.models.VirtualNetworkConfiguration + :ivar gateway_regional_url: Gateway URL of the API Management service in + the Region. + :vartype gateway_regional_url: str + :param disable_gateway: Property only valid for an Api Management service + deployed in multiple locations. This can be used to disable the gateway in + this additional location. Default value: False . + :type disable_gateway: bool + """ + + _validation = { + 'location': {'required': True}, + 'sku': {'required': True}, + 'public_ip_addresses': {'readonly': True}, + 'private_ip_addresses': {'readonly': True}, + 'gateway_regional_url': {'readonly': True}, + } + + _attribute_map = { + 'location': {'key': 'location', 'type': 'str'}, + 'sku': {'key': 'sku', 'type': 'ApiManagementServiceSkuProperties'}, + 'public_ip_addresses': {'key': 'publicIPAddresses', 'type': '[str]'}, + 'private_ip_addresses': {'key': 'privateIPAddresses', 'type': '[str]'}, + 'virtual_network_configuration': {'key': 'virtualNetworkConfiguration', 'type': 'VirtualNetworkConfiguration'}, + 'gateway_regional_url': {'key': 'gatewayRegionalUrl', 'type': 'str'}, + 'disable_gateway': {'key': 'disableGateway', 'type': 'bool'}, + } + + def __init__(self, **kwargs): + super(AdditionalLocation, self).__init__(**kwargs) + self.location = kwargs.get('location', None) + self.sku = kwargs.get('sku', None) + self.public_ip_addresses = None + self.private_ip_addresses = None + self.virtual_network_configuration = kwargs.get('virtual_network_configuration', None) + self.gateway_regional_url = None + self.disable_gateway = kwargs.get('disable_gateway', False) + + +class Resource(Model): + """The Resource definition. + + Variables are only populated by the server, and will be ignored when + sending a request. + + :ivar id: Resource ID. + :vartype id: str + :ivar name: Resource name. + :vartype name: str + :ivar type: Resource type for API Management resource. + :vartype type: str + """ + + _validation = { + 'id': {'readonly': True}, + 'name': {'readonly': True}, + 'type': {'readonly': True}, + } + + _attribute_map = { + 'id': {'key': 'id', 'type': 'str'}, + 'name': {'key': 'name', 'type': 'str'}, + 'type': {'key': 'type', 'type': 'str'}, + } + + def __init__(self, **kwargs): + super(Resource, self).__init__(**kwargs) + self.id = None + self.name = None + self.type = None + + +class ApiContract(Resource): + """Api details. + + Variables are only populated by the server, and will be ignored when + sending a request. + + All required parameters must be populated in order to send to Azure. + + :ivar id: Resource ID. + :vartype id: str + :ivar name: Resource name. + :vartype name: str + :ivar type: Resource type for API Management resource. + :vartype type: str + :param description: Description of the API. May include HTML formatting + tags. + :type description: str + :param authentication_settings: Collection of authentication settings + included into this API. + :type authentication_settings: + ~azure.mgmt.apimanagement.models.AuthenticationSettingsContract + :param subscription_key_parameter_names: Protocols over which API is made + available. + :type subscription_key_parameter_names: + ~azure.mgmt.apimanagement.models.SubscriptionKeyParameterNamesContract + :param api_type: Type of API. Possible values include: 'http', 'soap' + :type api_type: str or ~azure.mgmt.apimanagement.models.ApiType + :param api_revision: Describes the Revision of the Api. If no value is + provided, default revision 1 is created + :type api_revision: str + :param api_version: Indicates the Version identifier of the API if the API + is versioned + :type api_version: str + :param is_current: Indicates if API revision is current api revision. + :type is_current: bool + :ivar is_online: Indicates if API revision is accessible via the gateway. + :vartype is_online: bool + :param api_revision_description: Description of the Api Revision. + :type api_revision_description: str + :param api_version_description: Description of the Api Version. + :type api_version_description: str + :param api_version_set_id: A resource identifier for the related + ApiVersionSet. + :type api_version_set_id: str + :param subscription_required: Specifies whether an API or Product + subscription is required for accessing the API. + :type subscription_required: bool + :param source_api_id: API identifier of the source API. + :type source_api_id: str + :param display_name: API name. Must be 1 to 300 characters long. + :type display_name: str + :param service_url: Absolute URL of the backend service implementing this + API. Cannot be more than 2000 characters long. + :type service_url: str + :param path: Required. Relative URL uniquely identifying this API and all + of its resource paths within the API Management service instance. It is + appended to the API endpoint base URL specified during the service + instance creation to form a public URL for this API. + :type path: str + :param protocols: Describes on which protocols the operations in this API + can be invoked. + :type protocols: list[str or ~azure.mgmt.apimanagement.models.Protocol] + :param api_version_set: Version set details + :type api_version_set: + ~azure.mgmt.apimanagement.models.ApiVersionSetContractDetails + """ + + _validation = { + 'id': {'readonly': True}, + 'name': {'readonly': True}, + 'type': {'readonly': True}, + 'api_revision': {'max_length': 100, 'min_length': 1}, + 'api_version': {'max_length': 100}, + 'is_online': {'readonly': True}, + 'api_revision_description': {'max_length': 256}, + 'api_version_description': {'max_length': 256}, + 'display_name': {'max_length': 300, 'min_length': 1}, + 'service_url': {'max_length': 2000, 'min_length': 0}, + 'path': {'required': True, 'max_length': 400, 'min_length': 0}, + } + + _attribute_map = { + 'id': {'key': 'id', 'type': 'str'}, + 'name': {'key': 'name', 'type': 'str'}, + 'type': {'key': 'type', 'type': 'str'}, + 'description': {'key': 'properties.description', 'type': 'str'}, + 'authentication_settings': {'key': 'properties.authenticationSettings', 'type': 'AuthenticationSettingsContract'}, + 'subscription_key_parameter_names': {'key': 'properties.subscriptionKeyParameterNames', 'type': 'SubscriptionKeyParameterNamesContract'}, + 'api_type': {'key': 'properties.type', 'type': 'str'}, + 'api_revision': {'key': 'properties.apiRevision', 'type': 'str'}, + 'api_version': {'key': 'properties.apiVersion', 'type': 'str'}, + 'is_current': {'key': 'properties.isCurrent', 'type': 'bool'}, + 'is_online': {'key': 'properties.isOnline', 'type': 'bool'}, + 'api_revision_description': {'key': 'properties.apiRevisionDescription', 'type': 'str'}, + 'api_version_description': {'key': 'properties.apiVersionDescription', 'type': 'str'}, + 'api_version_set_id': {'key': 'properties.apiVersionSetId', 'type': 'str'}, + 'subscription_required': {'key': 'properties.subscriptionRequired', 'type': 'bool'}, + 'source_api_id': {'key': 'properties.sourceApiId', 'type': 'str'}, + 'display_name': {'key': 'properties.displayName', 'type': 'str'}, + 'service_url': {'key': 'properties.serviceUrl', 'type': 'str'}, + 'path': {'key': 'properties.path', 'type': 'str'}, + 'protocols': {'key': 'properties.protocols', 'type': '[Protocol]'}, + 'api_version_set': {'key': 'properties.apiVersionSet', 'type': 'ApiVersionSetContractDetails'}, + } + + def __init__(self, **kwargs): + super(ApiContract, self).__init__(**kwargs) + self.description = kwargs.get('description', None) + self.authentication_settings = kwargs.get('authentication_settings', None) + self.subscription_key_parameter_names = kwargs.get('subscription_key_parameter_names', None) + self.api_type = kwargs.get('api_type', None) + self.api_revision = kwargs.get('api_revision', None) + self.api_version = kwargs.get('api_version', None) + self.is_current = kwargs.get('is_current', None) + self.is_online = None + self.api_revision_description = kwargs.get('api_revision_description', None) + self.api_version_description = kwargs.get('api_version_description', None) + self.api_version_set_id = kwargs.get('api_version_set_id', None) + self.subscription_required = kwargs.get('subscription_required', None) + self.source_api_id = kwargs.get('source_api_id', None) + self.display_name = kwargs.get('display_name', None) + self.service_url = kwargs.get('service_url', None) + self.path = kwargs.get('path', None) + self.protocols = kwargs.get('protocols', None) + self.api_version_set = kwargs.get('api_version_set', None) + + +class ApiEntityBaseContract(Model): + """API base contract details. + + Variables are only populated by the server, and will be ignored when + sending a request. + + :param description: Description of the API. May include HTML formatting + tags. + :type description: str + :param authentication_settings: Collection of authentication settings + included into this API. + :type authentication_settings: + ~azure.mgmt.apimanagement.models.AuthenticationSettingsContract + :param subscription_key_parameter_names: Protocols over which API is made + available. + :type subscription_key_parameter_names: + ~azure.mgmt.apimanagement.models.SubscriptionKeyParameterNamesContract + :param api_type: Type of API. Possible values include: 'http', 'soap' + :type api_type: str or ~azure.mgmt.apimanagement.models.ApiType + :param api_revision: Describes the Revision of the Api. If no value is + provided, default revision 1 is created + :type api_revision: str + :param api_version: Indicates the Version identifier of the API if the API + is versioned + :type api_version: str + :param is_current: Indicates if API revision is current api revision. + :type is_current: bool + :ivar is_online: Indicates if API revision is accessible via the gateway. + :vartype is_online: bool + :param api_revision_description: Description of the Api Revision. + :type api_revision_description: str + :param api_version_description: Description of the Api Version. + :type api_version_description: str + :param api_version_set_id: A resource identifier for the related + ApiVersionSet. + :type api_version_set_id: str + :param subscription_required: Specifies whether an API or Product + subscription is required for accessing the API. + :type subscription_required: bool + """ + + _validation = { + 'api_revision': {'max_length': 100, 'min_length': 1}, + 'api_version': {'max_length': 100}, + 'is_online': {'readonly': True}, + 'api_revision_description': {'max_length': 256}, + 'api_version_description': {'max_length': 256}, + } + + _attribute_map = { + 'description': {'key': 'description', 'type': 'str'}, + 'authentication_settings': {'key': 'authenticationSettings', 'type': 'AuthenticationSettingsContract'}, + 'subscription_key_parameter_names': {'key': 'subscriptionKeyParameterNames', 'type': 'SubscriptionKeyParameterNamesContract'}, + 'api_type': {'key': 'type', 'type': 'str'}, + 'api_revision': {'key': 'apiRevision', 'type': 'str'}, + 'api_version': {'key': 'apiVersion', 'type': 'str'}, + 'is_current': {'key': 'isCurrent', 'type': 'bool'}, + 'is_online': {'key': 'isOnline', 'type': 'bool'}, + 'api_revision_description': {'key': 'apiRevisionDescription', 'type': 'str'}, + 'api_version_description': {'key': 'apiVersionDescription', 'type': 'str'}, + 'api_version_set_id': {'key': 'apiVersionSetId', 'type': 'str'}, + 'subscription_required': {'key': 'subscriptionRequired', 'type': 'bool'}, + } + + def __init__(self, **kwargs): + super(ApiEntityBaseContract, self).__init__(**kwargs) + self.description = kwargs.get('description', None) + self.authentication_settings = kwargs.get('authentication_settings', None) + self.subscription_key_parameter_names = kwargs.get('subscription_key_parameter_names', None) + self.api_type = kwargs.get('api_type', None) + self.api_revision = kwargs.get('api_revision', None) + self.api_version = kwargs.get('api_version', None) + self.is_current = kwargs.get('is_current', None) + self.is_online = None + self.api_revision_description = kwargs.get('api_revision_description', None) + self.api_version_description = kwargs.get('api_version_description', None) + self.api_version_set_id = kwargs.get('api_version_set_id', None) + self.subscription_required = kwargs.get('subscription_required', None) + + +class ApiContractProperties(ApiEntityBaseContract): + """Api Entity Properties. + + Variables are only populated by the server, and will be ignored when + sending a request. + + All required parameters must be populated in order to send to Azure. + + :param description: Description of the API. May include HTML formatting + tags. + :type description: str + :param authentication_settings: Collection of authentication settings + included into this API. + :type authentication_settings: + ~azure.mgmt.apimanagement.models.AuthenticationSettingsContract + :param subscription_key_parameter_names: Protocols over which API is made + available. + :type subscription_key_parameter_names: + ~azure.mgmt.apimanagement.models.SubscriptionKeyParameterNamesContract + :param api_type: Type of API. Possible values include: 'http', 'soap' + :type api_type: str or ~azure.mgmt.apimanagement.models.ApiType + :param api_revision: Describes the Revision of the Api. If no value is + provided, default revision 1 is created + :type api_revision: str + :param api_version: Indicates the Version identifier of the API if the API + is versioned + :type api_version: str + :param is_current: Indicates if API revision is current api revision. + :type is_current: bool + :ivar is_online: Indicates if API revision is accessible via the gateway. + :vartype is_online: bool + :param api_revision_description: Description of the Api Revision. + :type api_revision_description: str + :param api_version_description: Description of the Api Version. + :type api_version_description: str + :param api_version_set_id: A resource identifier for the related + ApiVersionSet. + :type api_version_set_id: str + :param subscription_required: Specifies whether an API or Product + subscription is required for accessing the API. + :type subscription_required: bool + :param source_api_id: API identifier of the source API. + :type source_api_id: str + :param display_name: API name. Must be 1 to 300 characters long. + :type display_name: str + :param service_url: Absolute URL of the backend service implementing this + API. Cannot be more than 2000 characters long. + :type service_url: str + :param path: Required. Relative URL uniquely identifying this API and all + of its resource paths within the API Management service instance. It is + appended to the API endpoint base URL specified during the service + instance creation to form a public URL for this API. + :type path: str + :param protocols: Describes on which protocols the operations in this API + can be invoked. + :type protocols: list[str or ~azure.mgmt.apimanagement.models.Protocol] + :param api_version_set: Version set details + :type api_version_set: + ~azure.mgmt.apimanagement.models.ApiVersionSetContractDetails + """ + + _validation = { + 'api_revision': {'max_length': 100, 'min_length': 1}, + 'api_version': {'max_length': 100}, + 'is_online': {'readonly': True}, + 'api_revision_description': {'max_length': 256}, + 'api_version_description': {'max_length': 256}, + 'display_name': {'max_length': 300, 'min_length': 1}, + 'service_url': {'max_length': 2000, 'min_length': 0}, + 'path': {'required': True, 'max_length': 400, 'min_length': 0}, + } + + _attribute_map = { + 'description': {'key': 'description', 'type': 'str'}, + 'authentication_settings': {'key': 'authenticationSettings', 'type': 'AuthenticationSettingsContract'}, + 'subscription_key_parameter_names': {'key': 'subscriptionKeyParameterNames', 'type': 'SubscriptionKeyParameterNamesContract'}, + 'api_type': {'key': 'type', 'type': 'str'}, + 'api_revision': {'key': 'apiRevision', 'type': 'str'}, + 'api_version': {'key': 'apiVersion', 'type': 'str'}, + 'is_current': {'key': 'isCurrent', 'type': 'bool'}, + 'is_online': {'key': 'isOnline', 'type': 'bool'}, + 'api_revision_description': {'key': 'apiRevisionDescription', 'type': 'str'}, + 'api_version_description': {'key': 'apiVersionDescription', 'type': 'str'}, + 'api_version_set_id': {'key': 'apiVersionSetId', 'type': 'str'}, + 'subscription_required': {'key': 'subscriptionRequired', 'type': 'bool'}, + 'source_api_id': {'key': 'sourceApiId', 'type': 'str'}, + 'display_name': {'key': 'displayName', 'type': 'str'}, + 'service_url': {'key': 'serviceUrl', 'type': 'str'}, + 'path': {'key': 'path', 'type': 'str'}, + 'protocols': {'key': 'protocols', 'type': '[Protocol]'}, + 'api_version_set': {'key': 'apiVersionSet', 'type': 'ApiVersionSetContractDetails'}, + } + + def __init__(self, **kwargs): + super(ApiContractProperties, self).__init__(**kwargs) + self.source_api_id = kwargs.get('source_api_id', None) + self.display_name = kwargs.get('display_name', None) + self.service_url = kwargs.get('service_url', None) + self.path = kwargs.get('path', None) + self.protocols = kwargs.get('protocols', None) + self.api_version_set = kwargs.get('api_version_set', None) + + +class ApiCreateOrUpdateParameter(Model): + """API Create or Update Parameters. + + Variables are only populated by the server, and will be ignored when + sending a request. + + All required parameters must be populated in order to send to Azure. + + :param description: Description of the API. May include HTML formatting + tags. + :type description: str + :param authentication_settings: Collection of authentication settings + included into this API. + :type authentication_settings: + ~azure.mgmt.apimanagement.models.AuthenticationSettingsContract + :param subscription_key_parameter_names: Protocols over which API is made + available. + :type subscription_key_parameter_names: + ~azure.mgmt.apimanagement.models.SubscriptionKeyParameterNamesContract + :param api_type: Type of API. Possible values include: 'http', 'soap' + :type api_type: str or ~azure.mgmt.apimanagement.models.ApiType + :param api_revision: Describes the Revision of the Api. If no value is + provided, default revision 1 is created + :type api_revision: str + :param api_version: Indicates the Version identifier of the API if the API + is versioned + :type api_version: str + :param is_current: Indicates if API revision is current api revision. + :type is_current: bool + :ivar is_online: Indicates if API revision is accessible via the gateway. + :vartype is_online: bool + :param api_revision_description: Description of the Api Revision. + :type api_revision_description: str + :param api_version_description: Description of the Api Version. + :type api_version_description: str + :param api_version_set_id: A resource identifier for the related + ApiVersionSet. + :type api_version_set_id: str + :param subscription_required: Specifies whether an API or Product + subscription is required for accessing the API. + :type subscription_required: bool + :param source_api_id: API identifier of the source API. + :type source_api_id: str + :param display_name: API name. Must be 1 to 300 characters long. + :type display_name: str + :param service_url: Absolute URL of the backend service implementing this + API. Cannot be more than 2000 characters long. + :type service_url: str + :param path: Required. Relative URL uniquely identifying this API and all + of its resource paths within the API Management service instance. It is + appended to the API endpoint base URL specified during the service + instance creation to form a public URL for this API. + :type path: str + :param protocols: Describes on which protocols the operations in this API + can be invoked. + :type protocols: list[str or ~azure.mgmt.apimanagement.models.Protocol] + :param api_version_set: Version set details + :type api_version_set: + ~azure.mgmt.apimanagement.models.ApiVersionSetContractDetails + :param value: Content value when Importing an API. + :type value: str + :param format: Format of the Content in which the API is getting imported. + Possible values include: 'wadl-xml', 'wadl-link-json', 'swagger-json', + 'swagger-link-json', 'wsdl', 'wsdl-link', 'openapi', 'openapi+json', + 'openapi-link', 'openapi+json-link' + :type format: str or ~azure.mgmt.apimanagement.models.ContentFormat + :param wsdl_selector: Criteria to limit import of WSDL to a subset of the + document. + :type wsdl_selector: + ~azure.mgmt.apimanagement.models.ApiCreateOrUpdatePropertiesWsdlSelector + :param soap_api_type: Type of Api to create. + * `http` creates a SOAP to REST API + * `soap` creates a SOAP pass-through API. Possible values include: + 'SoapToRest', 'SoapPassThrough' + :type soap_api_type: str or ~azure.mgmt.apimanagement.models.SoapApiType + """ + + _validation = { + 'api_revision': {'max_length': 100, 'min_length': 1}, + 'api_version': {'max_length': 100}, + 'is_online': {'readonly': True}, + 'api_revision_description': {'max_length': 256}, + 'api_version_description': {'max_length': 256}, + 'display_name': {'max_length': 300, 'min_length': 1}, + 'service_url': {'max_length': 2000, 'min_length': 0}, + 'path': {'required': True, 'max_length': 400, 'min_length': 0}, + } + + _attribute_map = { + 'description': {'key': 'properties.description', 'type': 'str'}, + 'authentication_settings': {'key': 'properties.authenticationSettings', 'type': 'AuthenticationSettingsContract'}, + 'subscription_key_parameter_names': {'key': 'properties.subscriptionKeyParameterNames', 'type': 'SubscriptionKeyParameterNamesContract'}, + 'api_type': {'key': 'properties.type', 'type': 'str'}, + 'api_revision': {'key': 'properties.apiRevision', 'type': 'str'}, + 'api_version': {'key': 'properties.apiVersion', 'type': 'str'}, + 'is_current': {'key': 'properties.isCurrent', 'type': 'bool'}, + 'is_online': {'key': 'properties.isOnline', 'type': 'bool'}, + 'api_revision_description': {'key': 'properties.apiRevisionDescription', 'type': 'str'}, + 'api_version_description': {'key': 'properties.apiVersionDescription', 'type': 'str'}, + 'api_version_set_id': {'key': 'properties.apiVersionSetId', 'type': 'str'}, + 'subscription_required': {'key': 'properties.subscriptionRequired', 'type': 'bool'}, + 'source_api_id': {'key': 'properties.sourceApiId', 'type': 'str'}, + 'display_name': {'key': 'properties.displayName', 'type': 'str'}, + 'service_url': {'key': 'properties.serviceUrl', 'type': 'str'}, + 'path': {'key': 'properties.path', 'type': 'str'}, + 'protocols': {'key': 'properties.protocols', 'type': '[Protocol]'}, + 'api_version_set': {'key': 'properties.apiVersionSet', 'type': 'ApiVersionSetContractDetails'}, + 'value': {'key': 'properties.value', 'type': 'str'}, + 'format': {'key': 'properties.format', 'type': 'str'}, + 'wsdl_selector': {'key': 'properties.wsdlSelector', 'type': 'ApiCreateOrUpdatePropertiesWsdlSelector'}, + 'soap_api_type': {'key': 'properties.apiType', 'type': 'str'}, + } + + def __init__(self, **kwargs): + super(ApiCreateOrUpdateParameter, self).__init__(**kwargs) + self.description = kwargs.get('description', None) + self.authentication_settings = kwargs.get('authentication_settings', None) + self.subscription_key_parameter_names = kwargs.get('subscription_key_parameter_names', None) + self.api_type = kwargs.get('api_type', None) + self.api_revision = kwargs.get('api_revision', None) + self.api_version = kwargs.get('api_version', None) + self.is_current = kwargs.get('is_current', None) + self.is_online = None + self.api_revision_description = kwargs.get('api_revision_description', None) + self.api_version_description = kwargs.get('api_version_description', None) + self.api_version_set_id = kwargs.get('api_version_set_id', None) + self.subscription_required = kwargs.get('subscription_required', None) + self.source_api_id = kwargs.get('source_api_id', None) + self.display_name = kwargs.get('display_name', None) + self.service_url = kwargs.get('service_url', None) + self.path = kwargs.get('path', None) + self.protocols = kwargs.get('protocols', None) + self.api_version_set = kwargs.get('api_version_set', None) + self.value = kwargs.get('value', None) + self.format = kwargs.get('format', None) + self.wsdl_selector = kwargs.get('wsdl_selector', None) + self.soap_api_type = kwargs.get('soap_api_type', None) + + +class ApiCreateOrUpdatePropertiesWsdlSelector(Model): + """Criteria to limit import of WSDL to a subset of the document. + + :param wsdl_service_name: Name of service to import from WSDL + :type wsdl_service_name: str + :param wsdl_endpoint_name: Name of endpoint(port) to import from WSDL + :type wsdl_endpoint_name: str + """ + + _attribute_map = { + 'wsdl_service_name': {'key': 'wsdlServiceName', 'type': 'str'}, + 'wsdl_endpoint_name': {'key': 'wsdlEndpointName', 'type': 'str'}, + } + + def __init__(self, **kwargs): + super(ApiCreateOrUpdatePropertiesWsdlSelector, self).__init__(**kwargs) + self.wsdl_service_name = kwargs.get('wsdl_service_name', None) + self.wsdl_endpoint_name = kwargs.get('wsdl_endpoint_name', None) + + +class ApiExportResult(Model): + """API Export result. + + :param id: ResourceId of the API which was exported. + :type id: str + :param export_result_format: Format in which the Api Details are exported + to the Storage Blob with Sas Key valid for 5 minutes. Possible values + include: 'Swagger', 'Wsdl', 'Wadl', 'OpenApi' + :type export_result_format: str or + ~azure.mgmt.apimanagement.models.ExportResultFormat + :param value: The object defining the schema of the exported Api Detail + :type value: ~azure.mgmt.apimanagement.models.ApiExportResultValue + """ + + _attribute_map = { + 'id': {'key': 'id', 'type': 'str'}, + 'export_result_format': {'key': 'format', 'type': 'str'}, + 'value': {'key': 'value', 'type': 'ApiExportResultValue'}, + } + + def __init__(self, **kwargs): + super(ApiExportResult, self).__init__(**kwargs) + self.id = kwargs.get('id', None) + self.export_result_format = kwargs.get('export_result_format', None) + self.value = kwargs.get('value', None) + + +class ApiExportResultValue(Model): + """The object defining the schema of the exported Api Detail. + + :param link: Link to the Storage Blob containing the result of the export + operation. The Blob Uri is only valid for 5 minutes. + :type link: str + """ + + _attribute_map = { + 'link': {'key': 'link', 'type': 'str'}, + } + + def __init__(self, **kwargs): + super(ApiExportResultValue, self).__init__(**kwargs) + self.link = kwargs.get('link', None) + + +class ApiManagementServiceApplyNetworkConfigurationParameters(Model): + """Parameter supplied to the Apply Network configuration operation. + + :param location: Location of the Api Management service to update for a + multi-region service. For a service deployed in a single region, this + parameter is not required. + :type location: str + """ + + _attribute_map = { + 'location': {'key': 'location', 'type': 'str'}, + } + + def __init__(self, **kwargs): + super(ApiManagementServiceApplyNetworkConfigurationParameters, self).__init__(**kwargs) + self.location = kwargs.get('location', None) + + +class ApiManagementServiceBackupRestoreParameters(Model): + """Parameters supplied to the Backup/Restore of an API Management service + operation. + + All required parameters must be populated in order to send to Azure. + + :param storage_account: Required. Azure Cloud Storage account (used to + place/retrieve the backup) name. + :type storage_account: str + :param access_key: Required. Azure Cloud Storage account (used to + place/retrieve the backup) access key. + :type access_key: str + :param container_name: Required. Azure Cloud Storage blob container name + used to place/retrieve the backup. + :type container_name: str + :param backup_name: Required. The name of the backup file to create. + :type backup_name: str + """ + + _validation = { + 'storage_account': {'required': True}, + 'access_key': {'required': True}, + 'container_name': {'required': True}, + 'backup_name': {'required': True}, + } + + _attribute_map = { + 'storage_account': {'key': 'storageAccount', 'type': 'str'}, + 'access_key': {'key': 'accessKey', 'type': 'str'}, + 'container_name': {'key': 'containerName', 'type': 'str'}, + 'backup_name': {'key': 'backupName', 'type': 'str'}, + } + + def __init__(self, **kwargs): + super(ApiManagementServiceBackupRestoreParameters, self).__init__(**kwargs) + self.storage_account = kwargs.get('storage_account', None) + self.access_key = kwargs.get('access_key', None) + self.container_name = kwargs.get('container_name', None) + self.backup_name = kwargs.get('backup_name', None) + + +class ApiManagementServiceBaseProperties(Model): + """Base Properties of an API Management service resource description. + + Variables are only populated by the server, and will be ignored when + sending a request. + + :param notification_sender_email: Email address from which the + notification will be sent. + :type notification_sender_email: str + :ivar provisioning_state: The current provisioning state of the API + Management service which can be one of the following: + Created/Activating/Succeeded/Updating/Failed/Stopped/Terminating/TerminationFailed/Deleted. + :vartype provisioning_state: str + :ivar target_provisioning_state: The provisioning state of the API + Management service, which is targeted by the long running operation + started on the service. + :vartype target_provisioning_state: str + :ivar created_at_utc: Creation UTC date of the API Management service.The + date conforms to the following format: `yyyy-MM-ddTHH:mm:ssZ` as specified + by the ISO 8601 standard. + :vartype created_at_utc: datetime + :ivar gateway_url: Gateway URL of the API Management service. + :vartype gateway_url: str + :ivar gateway_regional_url: Gateway URL of the API Management service in + the Default Region. + :vartype gateway_regional_url: str + :ivar portal_url: Publisher portal endpoint Url of the API Management + service. + :vartype portal_url: str + :ivar management_api_url: Management API endpoint URL of the API + Management service. + :vartype management_api_url: str + :ivar scm_url: SCM endpoint URL of the API Management service. + :vartype scm_url: str + :ivar developer_portal_url: DEveloper Portal endpoint URL of the API + Management service. + :vartype developer_portal_url: str + :param hostname_configurations: Custom hostname configuration of the API + Management service. + :type hostname_configurations: + list[~azure.mgmt.apimanagement.models.HostnameConfiguration] + :ivar public_ip_addresses: Public Static Load Balanced IP addresses of the + API Management service in Primary region. Available only for Basic, + Standard and Premium SKU. + :vartype public_ip_addresses: list[str] + :ivar private_ip_addresses: Private Static Load Balanced IP addresses of + the API Management service in Primary region which is deployed in an + Internal Virtual Network. Available only for Basic, Standard and Premium + SKU. + :vartype private_ip_addresses: list[str] + :param virtual_network_configuration: Virtual network configuration of the + API Management service. + :type virtual_network_configuration: + ~azure.mgmt.apimanagement.models.VirtualNetworkConfiguration + :param additional_locations: Additional datacenter locations of the API + Management service. + :type additional_locations: + list[~azure.mgmt.apimanagement.models.AdditionalLocation] + :param custom_properties: Custom properties of the API Management + service.
Setting + `Microsoft.WindowsAzure.ApiManagement.Gateway.Security.Ciphers.TripleDes168` + will disable the cipher TLS_RSA_WITH_3DES_EDE_CBC_SHA for all TLS(1.0, 1.1 + and 1.2).
Setting + `Microsoft.WindowsAzure.ApiManagement.Gateway.Security.Protocols.Tls11` + can be used to disable just TLS 1.1.
Setting + `Microsoft.WindowsAzure.ApiManagement.Gateway.Security.Protocols.Tls10` + can be used to disable TLS 1.0 on an API Management service.
Setting + `Microsoft.WindowsAzure.ApiManagement.Gateway.Security.Backend.Protocols.Tls11` + can be used to disable just TLS 1.1 for communications with + backends.
Setting + `Microsoft.WindowsAzure.ApiManagement.Gateway.Security.Backend.Protocols.Tls10` + can be used to disable TLS 1.0 for communications with + backends.
Setting + `Microsoft.WindowsAzure.ApiManagement.Gateway.Protocols.Server.Http2` can + be used to enable HTTP2 protocol on an API Management service.
Not + specifying any of these properties on PATCH operation will reset omitted + properties' values to their defaults. For all the settings except Http2 + the default value is `True` if the service was created on or before April + 1st 2018 and `False` otherwise. Http2 setting's default value is + `False`.

You can disable any of next ciphers by using settings + `Microsoft.WindowsAzure.ApiManagement.Gateway.Security.Ciphers.[cipher_name]`: + TLS_ECDHE_ECDSA_WITH_AES_256_CBC_SHA, + TLS_ECDHE_ECDSA_WITH_AES_128_CBC_SHA, TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA, + TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA, TLS_RSA_WITH_AES_128_GCM_SHA256, + TLS_RSA_WITH_AES_256_CBC_SHA256, TLS_RSA_WITH_AES_128_CBC_SHA256, + TLS_RSA_WITH_AES_256_CBC_SHA, TLS_RSA_WITH_AES_128_CBC_SHA. For example, + `Microsoft.WindowsAzure.ApiManagement.Gateway.Security.Ciphers.TLS_RSA_WITH_AES_128_CBC_SHA256`:`false`. + The default value is `true` for them. Note: next ciphers can't be + disabled since they are required by Azure CloudService internal + components: + TLS_ECDHE_ECDSA_WITH_AES_256_GCM_SHA384,TLS_ECDHE_ECDSA_WITH_AES_128_GCM_SHA256,TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384,TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256,TLS_ECDHE_ECDSA_WITH_AES_256_CBC_SHA384,TLS_ECDHE_ECDSA_WITH_AES_128_CBC_SHA256,TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA384,TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256,TLS_RSA_WITH_AES_256_GCM_SHA384 + :type custom_properties: dict[str, str] + :param certificates: List of Certificates that need to be installed in the + API Management service. Max supported certificates that can be installed + is 10. + :type certificates: + list[~azure.mgmt.apimanagement.models.CertificateConfiguration] + :param enable_client_certificate: Property only meant to be used for + Consumption SKU Service. This enforces a client certificate to be + presented on each request to the gateway. This also enables the ability to + authenticate the certificate in the policy on the gateway. Default value: + False . + :type enable_client_certificate: bool + :param disable_gateway: Property only valid for an Api Management service + deployed in multiple locations. This can be used to disable the gateway in + master region. Default value: False . + :type disable_gateway: bool + :param virtual_network_type: The type of VPN in which API Management + service needs to be configured in. None (Default Value) means the API + Management service is not part of any Virtual Network, External means the + API Management deployment is set up inside a Virtual Network having an + Internet Facing Endpoint, and Internal means that API Management + deployment is setup inside a Virtual Network having an Intranet Facing + Endpoint only. Possible values include: 'None', 'External', 'Internal'. + Default value: "None" . + :type virtual_network_type: str or + ~azure.mgmt.apimanagement.models.VirtualNetworkType + :param api_version_constraint: Control Plane Apis version constraint for + the API Management service. + :type api_version_constraint: + ~azure.mgmt.apimanagement.models.ApiVersionConstraint + """ + + _validation = { + 'notification_sender_email': {'max_length': 100}, + 'provisioning_state': {'readonly': True}, + 'target_provisioning_state': {'readonly': True}, + 'created_at_utc': {'readonly': True}, + 'gateway_url': {'readonly': True}, + 'gateway_regional_url': {'readonly': True}, + 'portal_url': {'readonly': True}, + 'management_api_url': {'readonly': True}, + 'scm_url': {'readonly': True}, + 'developer_portal_url': {'readonly': True}, + 'public_ip_addresses': {'readonly': True}, + 'private_ip_addresses': {'readonly': True}, + } + + _attribute_map = { + 'notification_sender_email': {'key': 'notificationSenderEmail', 'type': 'str'}, + 'provisioning_state': {'key': 'provisioningState', 'type': 'str'}, + 'target_provisioning_state': {'key': 'targetProvisioningState', 'type': 'str'}, + 'created_at_utc': {'key': 'createdAtUtc', 'type': 'iso-8601'}, + 'gateway_url': {'key': 'gatewayUrl', 'type': 'str'}, + 'gateway_regional_url': {'key': 'gatewayRegionalUrl', 'type': 'str'}, + 'portal_url': {'key': 'portalUrl', 'type': 'str'}, + 'management_api_url': {'key': 'managementApiUrl', 'type': 'str'}, + 'scm_url': {'key': 'scmUrl', 'type': 'str'}, + 'developer_portal_url': {'key': 'developerPortalUrl', 'type': 'str'}, + 'hostname_configurations': {'key': 'hostnameConfigurations', 'type': '[HostnameConfiguration]'}, + 'public_ip_addresses': {'key': 'publicIPAddresses', 'type': '[str]'}, + 'private_ip_addresses': {'key': 'privateIPAddresses', 'type': '[str]'}, + 'virtual_network_configuration': {'key': 'virtualNetworkConfiguration', 'type': 'VirtualNetworkConfiguration'}, + 'additional_locations': {'key': 'additionalLocations', 'type': '[AdditionalLocation]'}, + 'custom_properties': {'key': 'customProperties', 'type': '{str}'}, + 'certificates': {'key': 'certificates', 'type': '[CertificateConfiguration]'}, + 'enable_client_certificate': {'key': 'enableClientCertificate', 'type': 'bool'}, + 'disable_gateway': {'key': 'disableGateway', 'type': 'bool'}, + 'virtual_network_type': {'key': 'virtualNetworkType', 'type': 'str'}, + 'api_version_constraint': {'key': 'apiVersionConstraint', 'type': 'ApiVersionConstraint'}, + } + + def __init__(self, **kwargs): + super(ApiManagementServiceBaseProperties, self).__init__(**kwargs) + self.notification_sender_email = kwargs.get('notification_sender_email', None) + self.provisioning_state = None + self.target_provisioning_state = None + self.created_at_utc = None + self.gateway_url = None + self.gateway_regional_url = None + self.portal_url = None + self.management_api_url = None + self.scm_url = None + self.developer_portal_url = None + self.hostname_configurations = kwargs.get('hostname_configurations', None) + self.public_ip_addresses = None + self.private_ip_addresses = None + self.virtual_network_configuration = kwargs.get('virtual_network_configuration', None) + self.additional_locations = kwargs.get('additional_locations', None) + self.custom_properties = kwargs.get('custom_properties', None) + self.certificates = kwargs.get('certificates', None) + self.enable_client_certificate = kwargs.get('enable_client_certificate', False) + self.disable_gateway = kwargs.get('disable_gateway', False) + self.virtual_network_type = kwargs.get('virtual_network_type', "None") + self.api_version_constraint = kwargs.get('api_version_constraint', None) + + +class ApiManagementServiceCheckNameAvailabilityParameters(Model): + """Parameters supplied to the CheckNameAvailability operation. + + All required parameters must be populated in order to send to Azure. + + :param name: Required. The name to check for availability. + :type name: str + """ + + _validation = { + 'name': {'required': True}, + } + + _attribute_map = { + 'name': {'key': 'name', 'type': 'str'}, + } + + def __init__(self, **kwargs): + super(ApiManagementServiceCheckNameAvailabilityParameters, self).__init__(**kwargs) + self.name = kwargs.get('name', None) + + +class ApiManagementServiceGetSsoTokenResult(Model): + """The response of the GetSsoToken operation. + + :param redirect_uri: Redirect URL to the Publisher Portal containing the + SSO token. + :type redirect_uri: str + """ + + _attribute_map = { + 'redirect_uri': {'key': 'redirectUri', 'type': 'str'}, + } + + def __init__(self, **kwargs): + super(ApiManagementServiceGetSsoTokenResult, self).__init__(**kwargs) + self.redirect_uri = kwargs.get('redirect_uri', None) + + +class ApiManagementServiceIdentity(Model): + """Identity properties of the Api Management service resource. + + Variables are only populated by the server, and will be ignored when + sending a request. + + All required parameters must be populated in order to send to Azure. + + :param type: Required. The type of identity used for the resource. The + type 'SystemAssigned, UserAssigned' includes both an implicitly created + identity and a set of user assigned identities. The type 'None' will + remove any identities from the service. Possible values include: + 'SystemAssigned', 'UserAssigned', 'SystemAssigned, UserAssigned', 'None' + :type type: str or ~azure.mgmt.apimanagement.models.ApimIdentityType + :ivar principal_id: The principal id of the identity. + :vartype principal_id: str + :ivar tenant_id: The client tenant id of the identity. + :vartype tenant_id: str + :param user_assigned_identities: + :type user_assigned_identities: dict[str, + ~azure.mgmt.apimanagement.models.ApiManagementServiceIdentityUserAssignedIdentitiesValue] + """ + + _validation = { + 'type': {'required': True}, + 'principal_id': {'readonly': True}, + 'tenant_id': {'readonly': True}, + } + + _attribute_map = { + 'type': {'key': 'type', 'type': 'str'}, + 'principal_id': {'key': 'principalId', 'type': 'str'}, + 'tenant_id': {'key': 'tenantId', 'type': 'str'}, + 'user_assigned_identities': {'key': 'userAssignedIdentities', 'type': '{ApiManagementServiceIdentityUserAssignedIdentitiesValue}'}, + } + + def __init__(self, **kwargs): + super(ApiManagementServiceIdentity, self).__init__(**kwargs) + self.type = kwargs.get('type', None) + self.principal_id = None + self.tenant_id = None + self.user_assigned_identities = kwargs.get('user_assigned_identities', None) + + +class ApiManagementServiceIdentityUserAssignedIdentitiesValue(Model): + """ApiManagementServiceIdentityUserAssignedIdentitiesValue. + + Variables are only populated by the server, and will be ignored when + sending a request. + + :ivar principal_id: The principal id of user assigned identity. + :vartype principal_id: str + :ivar client_id: The client id of user assigned identity. + :vartype client_id: str + """ + + _validation = { + 'principal_id': {'readonly': True}, + 'client_id': {'readonly': True}, + } + + _attribute_map = { + 'principal_id': {'key': 'principalId', 'type': 'str'}, + 'client_id': {'key': 'clientId', 'type': 'str'}, + } + + def __init__(self, **kwargs): + super(ApiManagementServiceIdentityUserAssignedIdentitiesValue, self).__init__(**kwargs) + self.principal_id = None + self.client_id = None + + +class ApiManagementServiceNameAvailabilityResult(Model): + """Response of the CheckNameAvailability operation. + + Variables are only populated by the server, and will be ignored when + sending a request. + + :ivar name_available: True if the name is available and can be used to + create a new API Management service; otherwise false. + :vartype name_available: bool + :ivar message: If reason == invalid, provide the user with the reason why + the given name is invalid, and provide the resource naming requirements so + that the user can select a valid name. If reason == AlreadyExists, explain + that is already in use, and direct them to select a + different name. + :vartype message: str + :param reason: Invalid indicates the name provided does not match the + resource provider’s naming requirements (incorrect length, unsupported + characters, etc.) AlreadyExists indicates that the name is already in use + and is therefore unavailable. Possible values include: 'Valid', 'Invalid', + 'AlreadyExists' + :type reason: str or + ~azure.mgmt.apimanagement.models.NameAvailabilityReason + """ + + _validation = { + 'name_available': {'readonly': True}, + 'message': {'readonly': True}, + } + + _attribute_map = { + 'name_available': {'key': 'nameAvailable', 'type': 'bool'}, + 'message': {'key': 'message', 'type': 'str'}, + 'reason': {'key': 'reason', 'type': 'NameAvailabilityReason'}, + } + + def __init__(self, **kwargs): + super(ApiManagementServiceNameAvailabilityResult, self).__init__(**kwargs) + self.name_available = None + self.message = None + self.reason = kwargs.get('reason', None) + + +class ApimResource(Model): + """The Resource definition. + + Variables are only populated by the server, and will be ignored when + sending a request. + + :ivar id: Resource ID. + :vartype id: str + :ivar name: Resource name. + :vartype name: str + :ivar type: Resource type for API Management resource is set to + Microsoft.ApiManagement. + :vartype type: str + :param tags: Resource tags. + :type tags: dict[str, str] + """ + + _validation = { + 'id': {'readonly': True}, + 'name': {'readonly': True}, + 'type': {'readonly': True}, + } + + _attribute_map = { + 'id': {'key': 'id', 'type': 'str'}, + 'name': {'key': 'name', 'type': 'str'}, + 'type': {'key': 'type', 'type': 'str'}, + 'tags': {'key': 'tags', 'type': '{str}'}, + } + + def __init__(self, **kwargs): + super(ApimResource, self).__init__(**kwargs) + self.id = None + self.name = None + self.type = None + self.tags = kwargs.get('tags', None) + + +class ApiManagementServiceResource(ApimResource): + """A single API Management service resource in List or Get response. + + Variables are only populated by the server, and will be ignored when + sending a request. + + All required parameters must be populated in order to send to Azure. + + :ivar id: Resource ID. + :vartype id: str + :ivar name: Resource name. + :vartype name: str + :ivar type: Resource type for API Management resource is set to + Microsoft.ApiManagement. + :vartype type: str + :param tags: Resource tags. + :type tags: dict[str, str] + :param notification_sender_email: Email address from which the + notification will be sent. + :type notification_sender_email: str + :ivar provisioning_state: The current provisioning state of the API + Management service which can be one of the following: + Created/Activating/Succeeded/Updating/Failed/Stopped/Terminating/TerminationFailed/Deleted. + :vartype provisioning_state: str + :ivar target_provisioning_state: The provisioning state of the API + Management service, which is targeted by the long running operation + started on the service. + :vartype target_provisioning_state: str + :ivar created_at_utc: Creation UTC date of the API Management service.The + date conforms to the following format: `yyyy-MM-ddTHH:mm:ssZ` as specified + by the ISO 8601 standard. + :vartype created_at_utc: datetime + :ivar gateway_url: Gateway URL of the API Management service. + :vartype gateway_url: str + :ivar gateway_regional_url: Gateway URL of the API Management service in + the Default Region. + :vartype gateway_regional_url: str + :ivar portal_url: Publisher portal endpoint Url of the API Management + service. + :vartype portal_url: str + :ivar management_api_url: Management API endpoint URL of the API + Management service. + :vartype management_api_url: str + :ivar scm_url: SCM endpoint URL of the API Management service. + :vartype scm_url: str + :ivar developer_portal_url: DEveloper Portal endpoint URL of the API + Management service. + :vartype developer_portal_url: str + :param hostname_configurations: Custom hostname configuration of the API + Management service. + :type hostname_configurations: + list[~azure.mgmt.apimanagement.models.HostnameConfiguration] + :ivar public_ip_addresses: Public Static Load Balanced IP addresses of the + API Management service in Primary region. Available only for Basic, + Standard and Premium SKU. + :vartype public_ip_addresses: list[str] + :ivar private_ip_addresses: Private Static Load Balanced IP addresses of + the API Management service in Primary region which is deployed in an + Internal Virtual Network. Available only for Basic, Standard and Premium + SKU. + :vartype private_ip_addresses: list[str] + :param virtual_network_configuration: Virtual network configuration of the + API Management service. + :type virtual_network_configuration: + ~azure.mgmt.apimanagement.models.VirtualNetworkConfiguration + :param additional_locations: Additional datacenter locations of the API + Management service. + :type additional_locations: + list[~azure.mgmt.apimanagement.models.AdditionalLocation] + :param custom_properties: Custom properties of the API Management + service.
Setting + `Microsoft.WindowsAzure.ApiManagement.Gateway.Security.Ciphers.TripleDes168` + will disable the cipher TLS_RSA_WITH_3DES_EDE_CBC_SHA for all TLS(1.0, 1.1 + and 1.2).
Setting + `Microsoft.WindowsAzure.ApiManagement.Gateway.Security.Protocols.Tls11` + can be used to disable just TLS 1.1.
Setting + `Microsoft.WindowsAzure.ApiManagement.Gateway.Security.Protocols.Tls10` + can be used to disable TLS 1.0 on an API Management service.
Setting + `Microsoft.WindowsAzure.ApiManagement.Gateway.Security.Backend.Protocols.Tls11` + can be used to disable just TLS 1.1 for communications with + backends.
Setting + `Microsoft.WindowsAzure.ApiManagement.Gateway.Security.Backend.Protocols.Tls10` + can be used to disable TLS 1.0 for communications with + backends.
Setting + `Microsoft.WindowsAzure.ApiManagement.Gateway.Protocols.Server.Http2` can + be used to enable HTTP2 protocol on an API Management service.
Not + specifying any of these properties on PATCH operation will reset omitted + properties' values to their defaults. For all the settings except Http2 + the default value is `True` if the service was created on or before April + 1st 2018 and `False` otherwise. Http2 setting's default value is + `False`.

You can disable any of next ciphers by using settings + `Microsoft.WindowsAzure.ApiManagement.Gateway.Security.Ciphers.[cipher_name]`: + TLS_ECDHE_ECDSA_WITH_AES_256_CBC_SHA, + TLS_ECDHE_ECDSA_WITH_AES_128_CBC_SHA, TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA, + TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA, TLS_RSA_WITH_AES_128_GCM_SHA256, + TLS_RSA_WITH_AES_256_CBC_SHA256, TLS_RSA_WITH_AES_128_CBC_SHA256, + TLS_RSA_WITH_AES_256_CBC_SHA, TLS_RSA_WITH_AES_128_CBC_SHA. For example, + `Microsoft.WindowsAzure.ApiManagement.Gateway.Security.Ciphers.TLS_RSA_WITH_AES_128_CBC_SHA256`:`false`. + The default value is `true` for them. Note: next ciphers can't be + disabled since they are required by Azure CloudService internal + components: + TLS_ECDHE_ECDSA_WITH_AES_256_GCM_SHA384,TLS_ECDHE_ECDSA_WITH_AES_128_GCM_SHA256,TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384,TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256,TLS_ECDHE_ECDSA_WITH_AES_256_CBC_SHA384,TLS_ECDHE_ECDSA_WITH_AES_128_CBC_SHA256,TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA384,TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256,TLS_RSA_WITH_AES_256_GCM_SHA384 + :type custom_properties: dict[str, str] + :param certificates: List of Certificates that need to be installed in the + API Management service. Max supported certificates that can be installed + is 10. + :type certificates: + list[~azure.mgmt.apimanagement.models.CertificateConfiguration] + :param enable_client_certificate: Property only meant to be used for + Consumption SKU Service. This enforces a client certificate to be + presented on each request to the gateway. This also enables the ability to + authenticate the certificate in the policy on the gateway. Default value: + False . + :type enable_client_certificate: bool + :param disable_gateway: Property only valid for an Api Management service + deployed in multiple locations. This can be used to disable the gateway in + master region. Default value: False . + :type disable_gateway: bool + :param virtual_network_type: The type of VPN in which API Management + service needs to be configured in. None (Default Value) means the API + Management service is not part of any Virtual Network, External means the + API Management deployment is set up inside a Virtual Network having an + Internet Facing Endpoint, and Internal means that API Management + deployment is setup inside a Virtual Network having an Intranet Facing + Endpoint only. Possible values include: 'None', 'External', 'Internal'. + Default value: "None" . + :type virtual_network_type: str or + ~azure.mgmt.apimanagement.models.VirtualNetworkType + :param api_version_constraint: Control Plane Apis version constraint for + the API Management service. + :type api_version_constraint: + ~azure.mgmt.apimanagement.models.ApiVersionConstraint + :param publisher_email: Required. Publisher email. + :type publisher_email: str + :param publisher_name: Required. Publisher name. + :type publisher_name: str + :param sku: Required. SKU properties of the API Management service. + :type sku: + ~azure.mgmt.apimanagement.models.ApiManagementServiceSkuProperties + :param identity: Managed service identity of the Api Management service. + :type identity: + ~azure.mgmt.apimanagement.models.ApiManagementServiceIdentity + :param location: Required. Resource location. + :type location: str + :ivar etag: ETag of the resource. + :vartype etag: str + """ + + _validation = { + 'id': {'readonly': True}, + 'name': {'readonly': True}, + 'type': {'readonly': True}, + 'notification_sender_email': {'max_length': 100}, + 'provisioning_state': {'readonly': True}, + 'target_provisioning_state': {'readonly': True}, + 'created_at_utc': {'readonly': True}, + 'gateway_url': {'readonly': True}, + 'gateway_regional_url': {'readonly': True}, + 'portal_url': {'readonly': True}, + 'management_api_url': {'readonly': True}, + 'scm_url': {'readonly': True}, + 'developer_portal_url': {'readonly': True}, + 'public_ip_addresses': {'readonly': True}, + 'private_ip_addresses': {'readonly': True}, + 'publisher_email': {'required': True, 'max_length': 100}, + 'publisher_name': {'required': True, 'max_length': 100}, + 'sku': {'required': True}, + 'location': {'required': True}, + 'etag': {'readonly': True}, + } + + _attribute_map = { + 'id': {'key': 'id', 'type': 'str'}, + 'name': {'key': 'name', 'type': 'str'}, + 'type': {'key': 'type', 'type': 'str'}, + 'tags': {'key': 'tags', 'type': '{str}'}, + 'notification_sender_email': {'key': 'properties.notificationSenderEmail', 'type': 'str'}, + 'provisioning_state': {'key': 'properties.provisioningState', 'type': 'str'}, + 'target_provisioning_state': {'key': 'properties.targetProvisioningState', 'type': 'str'}, + 'created_at_utc': {'key': 'properties.createdAtUtc', 'type': 'iso-8601'}, + 'gateway_url': {'key': 'properties.gatewayUrl', 'type': 'str'}, + 'gateway_regional_url': {'key': 'properties.gatewayRegionalUrl', 'type': 'str'}, + 'portal_url': {'key': 'properties.portalUrl', 'type': 'str'}, + 'management_api_url': {'key': 'properties.managementApiUrl', 'type': 'str'}, + 'scm_url': {'key': 'properties.scmUrl', 'type': 'str'}, + 'developer_portal_url': {'key': 'properties.developerPortalUrl', 'type': 'str'}, + 'hostname_configurations': {'key': 'properties.hostnameConfigurations', 'type': '[HostnameConfiguration]'}, + 'public_ip_addresses': {'key': 'properties.publicIPAddresses', 'type': '[str]'}, + 'private_ip_addresses': {'key': 'properties.privateIPAddresses', 'type': '[str]'}, + 'virtual_network_configuration': {'key': 'properties.virtualNetworkConfiguration', 'type': 'VirtualNetworkConfiguration'}, + 'additional_locations': {'key': 'properties.additionalLocations', 'type': '[AdditionalLocation]'}, + 'custom_properties': {'key': 'properties.customProperties', 'type': '{str}'}, + 'certificates': {'key': 'properties.certificates', 'type': '[CertificateConfiguration]'}, + 'enable_client_certificate': {'key': 'properties.enableClientCertificate', 'type': 'bool'}, + 'disable_gateway': {'key': 'properties.disableGateway', 'type': 'bool'}, + 'virtual_network_type': {'key': 'properties.virtualNetworkType', 'type': 'str'}, + 'api_version_constraint': {'key': 'properties.apiVersionConstraint', 'type': 'ApiVersionConstraint'}, + 'publisher_email': {'key': 'properties.publisherEmail', 'type': 'str'}, + 'publisher_name': {'key': 'properties.publisherName', 'type': 'str'}, + 'sku': {'key': 'sku', 'type': 'ApiManagementServiceSkuProperties'}, + 'identity': {'key': 'identity', 'type': 'ApiManagementServiceIdentity'}, + 'location': {'key': 'location', 'type': 'str'}, + 'etag': {'key': 'etag', 'type': 'str'}, + } + + def __init__(self, **kwargs): + super(ApiManagementServiceResource, self).__init__(**kwargs) + self.notification_sender_email = kwargs.get('notification_sender_email', None) + self.provisioning_state = None + self.target_provisioning_state = None + self.created_at_utc = None + self.gateway_url = None + self.gateway_regional_url = None + self.portal_url = None + self.management_api_url = None + self.scm_url = None + self.developer_portal_url = None + self.hostname_configurations = kwargs.get('hostname_configurations', None) + self.public_ip_addresses = None + self.private_ip_addresses = None + self.virtual_network_configuration = kwargs.get('virtual_network_configuration', None) + self.additional_locations = kwargs.get('additional_locations', None) + self.custom_properties = kwargs.get('custom_properties', None) + self.certificates = kwargs.get('certificates', None) + self.enable_client_certificate = kwargs.get('enable_client_certificate', False) + self.disable_gateway = kwargs.get('disable_gateway', False) + self.virtual_network_type = kwargs.get('virtual_network_type', "None") + self.api_version_constraint = kwargs.get('api_version_constraint', None) + self.publisher_email = kwargs.get('publisher_email', None) + self.publisher_name = kwargs.get('publisher_name', None) + self.sku = kwargs.get('sku', None) + self.identity = kwargs.get('identity', None) + self.location = kwargs.get('location', None) + self.etag = None + + +class ApiManagementServiceSkuProperties(Model): + """API Management service resource SKU properties. + + All required parameters must be populated in order to send to Azure. + + :param name: Required. Name of the Sku. Possible values include: + 'Developer', 'Standard', 'Premium', 'Basic', 'Consumption' + :type name: str or ~azure.mgmt.apimanagement.models.SkuType + :param capacity: Capacity of the SKU (number of deployed units of the + SKU). + :type capacity: int + """ + + _validation = { + 'name': {'required': True}, + } + + _attribute_map = { + 'name': {'key': 'name', 'type': 'str'}, + 'capacity': {'key': 'capacity', 'type': 'int'}, + } + + def __init__(self, **kwargs): + super(ApiManagementServiceSkuProperties, self).__init__(**kwargs) + self.name = kwargs.get('name', None) + self.capacity = kwargs.get('capacity', None) + + +class ApiManagementServiceUpdateParameters(ApimResource): + """Parameter supplied to Update Api Management Service. + + Variables are only populated by the server, and will be ignored when + sending a request. + + :ivar id: Resource ID. + :vartype id: str + :ivar name: Resource name. + :vartype name: str + :ivar type: Resource type for API Management resource is set to + Microsoft.ApiManagement. + :vartype type: str + :param tags: Resource tags. + :type tags: dict[str, str] + :param notification_sender_email: Email address from which the + notification will be sent. + :type notification_sender_email: str + :ivar provisioning_state: The current provisioning state of the API + Management service which can be one of the following: + Created/Activating/Succeeded/Updating/Failed/Stopped/Terminating/TerminationFailed/Deleted. + :vartype provisioning_state: str + :ivar target_provisioning_state: The provisioning state of the API + Management service, which is targeted by the long running operation + started on the service. + :vartype target_provisioning_state: str + :ivar created_at_utc: Creation UTC date of the API Management service.The + date conforms to the following format: `yyyy-MM-ddTHH:mm:ssZ` as specified + by the ISO 8601 standard. + :vartype created_at_utc: datetime + :ivar gateway_url: Gateway URL of the API Management service. + :vartype gateway_url: str + :ivar gateway_regional_url: Gateway URL of the API Management service in + the Default Region. + :vartype gateway_regional_url: str + :ivar portal_url: Publisher portal endpoint Url of the API Management + service. + :vartype portal_url: str + :ivar management_api_url: Management API endpoint URL of the API + Management service. + :vartype management_api_url: str + :ivar scm_url: SCM endpoint URL of the API Management service. + :vartype scm_url: str + :ivar developer_portal_url: DEveloper Portal endpoint URL of the API + Management service. + :vartype developer_portal_url: str + :param hostname_configurations: Custom hostname configuration of the API + Management service. + :type hostname_configurations: + list[~azure.mgmt.apimanagement.models.HostnameConfiguration] + :ivar public_ip_addresses: Public Static Load Balanced IP addresses of the + API Management service in Primary region. Available only for Basic, + Standard and Premium SKU. + :vartype public_ip_addresses: list[str] + :ivar private_ip_addresses: Private Static Load Balanced IP addresses of + the API Management service in Primary region which is deployed in an + Internal Virtual Network. Available only for Basic, Standard and Premium + SKU. + :vartype private_ip_addresses: list[str] + :param virtual_network_configuration: Virtual network configuration of the + API Management service. + :type virtual_network_configuration: + ~azure.mgmt.apimanagement.models.VirtualNetworkConfiguration + :param additional_locations: Additional datacenter locations of the API + Management service. + :type additional_locations: + list[~azure.mgmt.apimanagement.models.AdditionalLocation] + :param custom_properties: Custom properties of the API Management + service.
Setting + `Microsoft.WindowsAzure.ApiManagement.Gateway.Security.Ciphers.TripleDes168` + will disable the cipher TLS_RSA_WITH_3DES_EDE_CBC_SHA for all TLS(1.0, 1.1 + and 1.2).
Setting + `Microsoft.WindowsAzure.ApiManagement.Gateway.Security.Protocols.Tls11` + can be used to disable just TLS 1.1.
Setting + `Microsoft.WindowsAzure.ApiManagement.Gateway.Security.Protocols.Tls10` + can be used to disable TLS 1.0 on an API Management service.
Setting + `Microsoft.WindowsAzure.ApiManagement.Gateway.Security.Backend.Protocols.Tls11` + can be used to disable just TLS 1.1 for communications with + backends.
Setting + `Microsoft.WindowsAzure.ApiManagement.Gateway.Security.Backend.Protocols.Tls10` + can be used to disable TLS 1.0 for communications with + backends.
Setting + `Microsoft.WindowsAzure.ApiManagement.Gateway.Protocols.Server.Http2` can + be used to enable HTTP2 protocol on an API Management service.
Not + specifying any of these properties on PATCH operation will reset omitted + properties' values to their defaults. For all the settings except Http2 + the default value is `True` if the service was created on or before April + 1st 2018 and `False` otherwise. Http2 setting's default value is + `False`.

You can disable any of next ciphers by using settings + `Microsoft.WindowsAzure.ApiManagement.Gateway.Security.Ciphers.[cipher_name]`: + TLS_ECDHE_ECDSA_WITH_AES_256_CBC_SHA, + TLS_ECDHE_ECDSA_WITH_AES_128_CBC_SHA, TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA, + TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA, TLS_RSA_WITH_AES_128_GCM_SHA256, + TLS_RSA_WITH_AES_256_CBC_SHA256, TLS_RSA_WITH_AES_128_CBC_SHA256, + TLS_RSA_WITH_AES_256_CBC_SHA, TLS_RSA_WITH_AES_128_CBC_SHA. For example, + `Microsoft.WindowsAzure.ApiManagement.Gateway.Security.Ciphers.TLS_RSA_WITH_AES_128_CBC_SHA256`:`false`. + The default value is `true` for them. Note: next ciphers can't be + disabled since they are required by Azure CloudService internal + components: + TLS_ECDHE_ECDSA_WITH_AES_256_GCM_SHA384,TLS_ECDHE_ECDSA_WITH_AES_128_GCM_SHA256,TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384,TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256,TLS_ECDHE_ECDSA_WITH_AES_256_CBC_SHA384,TLS_ECDHE_ECDSA_WITH_AES_128_CBC_SHA256,TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA384,TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256,TLS_RSA_WITH_AES_256_GCM_SHA384 + :type custom_properties: dict[str, str] + :param certificates: List of Certificates that need to be installed in the + API Management service. Max supported certificates that can be installed + is 10. + :type certificates: + list[~azure.mgmt.apimanagement.models.CertificateConfiguration] + :param enable_client_certificate: Property only meant to be used for + Consumption SKU Service. This enforces a client certificate to be + presented on each request to the gateway. This also enables the ability to + authenticate the certificate in the policy on the gateway. Default value: + False . + :type enable_client_certificate: bool + :param disable_gateway: Property only valid for an Api Management service + deployed in multiple locations. This can be used to disable the gateway in + master region. Default value: False . + :type disable_gateway: bool + :param virtual_network_type: The type of VPN in which API Management + service needs to be configured in. None (Default Value) means the API + Management service is not part of any Virtual Network, External means the + API Management deployment is set up inside a Virtual Network having an + Internet Facing Endpoint, and Internal means that API Management + deployment is setup inside a Virtual Network having an Intranet Facing + Endpoint only. Possible values include: 'None', 'External', 'Internal'. + Default value: "None" . + :type virtual_network_type: str or + ~azure.mgmt.apimanagement.models.VirtualNetworkType + :param api_version_constraint: Control Plane Apis version constraint for + the API Management service. + :type api_version_constraint: + ~azure.mgmt.apimanagement.models.ApiVersionConstraint + :param publisher_email: Publisher email. + :type publisher_email: str + :param publisher_name: Publisher name. + :type publisher_name: str + :param sku: SKU properties of the API Management service. + :type sku: + ~azure.mgmt.apimanagement.models.ApiManagementServiceSkuProperties + :param identity: Managed service identity of the Api Management service. + :type identity: + ~azure.mgmt.apimanagement.models.ApiManagementServiceIdentity + :ivar etag: ETag of the resource. + :vartype etag: str + """ + + _validation = { + 'id': {'readonly': True}, + 'name': {'readonly': True}, + 'type': {'readonly': True}, + 'notification_sender_email': {'max_length': 100}, + 'provisioning_state': {'readonly': True}, + 'target_provisioning_state': {'readonly': True}, + 'created_at_utc': {'readonly': True}, + 'gateway_url': {'readonly': True}, + 'gateway_regional_url': {'readonly': True}, + 'portal_url': {'readonly': True}, + 'management_api_url': {'readonly': True}, + 'scm_url': {'readonly': True}, + 'developer_portal_url': {'readonly': True}, + 'public_ip_addresses': {'readonly': True}, + 'private_ip_addresses': {'readonly': True}, + 'publisher_email': {'max_length': 100}, + 'publisher_name': {'max_length': 100}, + 'etag': {'readonly': True}, + } + + _attribute_map = { + 'id': {'key': 'id', 'type': 'str'}, + 'name': {'key': 'name', 'type': 'str'}, + 'type': {'key': 'type', 'type': 'str'}, + 'tags': {'key': 'tags', 'type': '{str}'}, + 'notification_sender_email': {'key': 'properties.notificationSenderEmail', 'type': 'str'}, + 'provisioning_state': {'key': 'properties.provisioningState', 'type': 'str'}, + 'target_provisioning_state': {'key': 'properties.targetProvisioningState', 'type': 'str'}, + 'created_at_utc': {'key': 'properties.createdAtUtc', 'type': 'iso-8601'}, + 'gateway_url': {'key': 'properties.gatewayUrl', 'type': 'str'}, + 'gateway_regional_url': {'key': 'properties.gatewayRegionalUrl', 'type': 'str'}, + 'portal_url': {'key': 'properties.portalUrl', 'type': 'str'}, + 'management_api_url': {'key': 'properties.managementApiUrl', 'type': 'str'}, + 'scm_url': {'key': 'properties.scmUrl', 'type': 'str'}, + 'developer_portal_url': {'key': 'properties.developerPortalUrl', 'type': 'str'}, + 'hostname_configurations': {'key': 'properties.hostnameConfigurations', 'type': '[HostnameConfiguration]'}, + 'public_ip_addresses': {'key': 'properties.publicIPAddresses', 'type': '[str]'}, + 'private_ip_addresses': {'key': 'properties.privateIPAddresses', 'type': '[str]'}, + 'virtual_network_configuration': {'key': 'properties.virtualNetworkConfiguration', 'type': 'VirtualNetworkConfiguration'}, + 'additional_locations': {'key': 'properties.additionalLocations', 'type': '[AdditionalLocation]'}, + 'custom_properties': {'key': 'properties.customProperties', 'type': '{str}'}, + 'certificates': {'key': 'properties.certificates', 'type': '[CertificateConfiguration]'}, + 'enable_client_certificate': {'key': 'properties.enableClientCertificate', 'type': 'bool'}, + 'disable_gateway': {'key': 'properties.disableGateway', 'type': 'bool'}, + 'virtual_network_type': {'key': 'properties.virtualNetworkType', 'type': 'str'}, + 'api_version_constraint': {'key': 'properties.apiVersionConstraint', 'type': 'ApiVersionConstraint'}, + 'publisher_email': {'key': 'properties.publisherEmail', 'type': 'str'}, + 'publisher_name': {'key': 'properties.publisherName', 'type': 'str'}, + 'sku': {'key': 'sku', 'type': 'ApiManagementServiceSkuProperties'}, + 'identity': {'key': 'identity', 'type': 'ApiManagementServiceIdentity'}, + 'etag': {'key': 'etag', 'type': 'str'}, + } + + def __init__(self, **kwargs): + super(ApiManagementServiceUpdateParameters, self).__init__(**kwargs) + self.notification_sender_email = kwargs.get('notification_sender_email', None) + self.provisioning_state = None + self.target_provisioning_state = None + self.created_at_utc = None + self.gateway_url = None + self.gateway_regional_url = None + self.portal_url = None + self.management_api_url = None + self.scm_url = None + self.developer_portal_url = None + self.hostname_configurations = kwargs.get('hostname_configurations', None) + self.public_ip_addresses = None + self.private_ip_addresses = None + self.virtual_network_configuration = kwargs.get('virtual_network_configuration', None) + self.additional_locations = kwargs.get('additional_locations', None) + self.custom_properties = kwargs.get('custom_properties', None) + self.certificates = kwargs.get('certificates', None) + self.enable_client_certificate = kwargs.get('enable_client_certificate', False) + self.disable_gateway = kwargs.get('disable_gateway', False) + self.virtual_network_type = kwargs.get('virtual_network_type', "None") + self.api_version_constraint = kwargs.get('api_version_constraint', None) + self.publisher_email = kwargs.get('publisher_email', None) + self.publisher_name = kwargs.get('publisher_name', None) + self.sku = kwargs.get('sku', None) + self.identity = kwargs.get('identity', None) + self.etag = None + + +class ApiReleaseContract(Resource): + """ApiRelease details. + + Variables are only populated by the server, and will be ignored when + sending a request. + + :ivar id: Resource ID. + :vartype id: str + :ivar name: Resource name. + :vartype name: str + :ivar type: Resource type for API Management resource. + :vartype type: str + :param api_id: Identifier of the API the release belongs to. + :type api_id: str + :ivar created_date_time: The time the API was released. The date conforms + to the following format: yyyy-MM-ddTHH:mm:ssZ as specified by the ISO 8601 + standard. + :vartype created_date_time: datetime + :ivar updated_date_time: The time the API release was updated. + :vartype updated_date_time: datetime + :param notes: Release Notes + :type notes: str + """ + + _validation = { + 'id': {'readonly': True}, + 'name': {'readonly': True}, + 'type': {'readonly': True}, + 'created_date_time': {'readonly': True}, + 'updated_date_time': {'readonly': True}, + } + + _attribute_map = { + 'id': {'key': 'id', 'type': 'str'}, + 'name': {'key': 'name', 'type': 'str'}, + 'type': {'key': 'type', 'type': 'str'}, + 'api_id': {'key': 'properties.apiId', 'type': 'str'}, + 'created_date_time': {'key': 'properties.createdDateTime', 'type': 'iso-8601'}, + 'updated_date_time': {'key': 'properties.updatedDateTime', 'type': 'iso-8601'}, + 'notes': {'key': 'properties.notes', 'type': 'str'}, + } + + def __init__(self, **kwargs): + super(ApiReleaseContract, self).__init__(**kwargs) + self.api_id = kwargs.get('api_id', None) + self.created_date_time = None + self.updated_date_time = None + self.notes = kwargs.get('notes', None) + + +class ApiRevisionContract(Model): + """Summary of revision metadata. + + Variables are only populated by the server, and will be ignored when + sending a request. + + :ivar api_id: Identifier of the API Revision. + :vartype api_id: str + :ivar api_revision: Revision number of API. + :vartype api_revision: str + :ivar created_date_time: The time the API Revision was created. The date + conforms to the following format: yyyy-MM-ddTHH:mm:ssZ as specified by the + ISO 8601 standard. + :vartype created_date_time: datetime + :ivar updated_date_time: The time the API Revision were updated. The date + conforms to the following format: yyyy-MM-ddTHH:mm:ssZ as specified by the + ISO 8601 standard. + :vartype updated_date_time: datetime + :ivar description: Description of the API Revision. + :vartype description: str + :ivar private_url: Gateway URL for accessing the non-current API Revision. + :vartype private_url: str + :ivar is_online: Indicates if API revision is the current api revision. + :vartype is_online: bool + :ivar is_current: Indicates if API revision is accessible via the gateway. + :vartype is_current: bool + """ + + _validation = { + 'api_id': {'readonly': True}, + 'api_revision': {'readonly': True, 'max_length': 100, 'min_length': 1}, + 'created_date_time': {'readonly': True}, + 'updated_date_time': {'readonly': True}, + 'description': {'readonly': True, 'max_length': 256}, + 'private_url': {'readonly': True}, + 'is_online': {'readonly': True}, + 'is_current': {'readonly': True}, + } + + _attribute_map = { + 'api_id': {'key': 'apiId', 'type': 'str'}, + 'api_revision': {'key': 'apiRevision', 'type': 'str'}, + 'created_date_time': {'key': 'createdDateTime', 'type': 'iso-8601'}, + 'updated_date_time': {'key': 'updatedDateTime', 'type': 'iso-8601'}, + 'description': {'key': 'description', 'type': 'str'}, + 'private_url': {'key': 'privateUrl', 'type': 'str'}, + 'is_online': {'key': 'isOnline', 'type': 'bool'}, + 'is_current': {'key': 'isCurrent', 'type': 'bool'}, + } + + def __init__(self, **kwargs): + super(ApiRevisionContract, self).__init__(**kwargs) + self.api_id = None + self.api_revision = None + self.created_date_time = None + self.updated_date_time = None + self.description = None + self.private_url = None + self.is_online = None + self.is_current = None + + +class ApiRevisionInfoContract(Model): + """Object used to create an API Revision or Version based on an existing API + Revision. + + :param source_api_id: Resource identifier of API to be used to create the + revision from. + :type source_api_id: str + :param api_version_name: Version identifier for the new API Version. + :type api_version_name: str + :param api_revision_description: Description of new API Revision. + :type api_revision_description: str + :param api_version_set: Version set details + :type api_version_set: + ~azure.mgmt.apimanagement.models.ApiVersionSetContractDetails + """ + + _validation = { + 'api_version_name': {'max_length': 100}, + 'api_revision_description': {'max_length': 256}, + } + + _attribute_map = { + 'source_api_id': {'key': 'sourceApiId', 'type': 'str'}, + 'api_version_name': {'key': 'apiVersionName', 'type': 'str'}, + 'api_revision_description': {'key': 'apiRevisionDescription', 'type': 'str'}, + 'api_version_set': {'key': 'apiVersionSet', 'type': 'ApiVersionSetContractDetails'}, + } + + def __init__(self, **kwargs): + super(ApiRevisionInfoContract, self).__init__(**kwargs) + self.source_api_id = kwargs.get('source_api_id', None) + self.api_version_name = kwargs.get('api_version_name', None) + self.api_revision_description = kwargs.get('api_revision_description', None) + self.api_version_set = kwargs.get('api_version_set', None) + + +class ApiTagResourceContractProperties(ApiEntityBaseContract): + """API contract properties for the Tag Resources. + + Variables are only populated by the server, and will be ignored when + sending a request. + + :param description: Description of the API. May include HTML formatting + tags. + :type description: str + :param authentication_settings: Collection of authentication settings + included into this API. + :type authentication_settings: + ~azure.mgmt.apimanagement.models.AuthenticationSettingsContract + :param subscription_key_parameter_names: Protocols over which API is made + available. + :type subscription_key_parameter_names: + ~azure.mgmt.apimanagement.models.SubscriptionKeyParameterNamesContract + :param api_type: Type of API. Possible values include: 'http', 'soap' + :type api_type: str or ~azure.mgmt.apimanagement.models.ApiType + :param api_revision: Describes the Revision of the Api. If no value is + provided, default revision 1 is created + :type api_revision: str + :param api_version: Indicates the Version identifier of the API if the API + is versioned + :type api_version: str + :param is_current: Indicates if API revision is current api revision. + :type is_current: bool + :ivar is_online: Indicates if API revision is accessible via the gateway. + :vartype is_online: bool + :param api_revision_description: Description of the Api Revision. + :type api_revision_description: str + :param api_version_description: Description of the Api Version. + :type api_version_description: str + :param api_version_set_id: A resource identifier for the related + ApiVersionSet. + :type api_version_set_id: str + :param subscription_required: Specifies whether an API or Product + subscription is required for accessing the API. + :type subscription_required: bool + :param id: API identifier in the form /apis/{apiId}. + :type id: str + :param name: API name. + :type name: str + :param service_url: Absolute URL of the backend service implementing this + API. + :type service_url: str + :param path: Relative URL uniquely identifying this API and all of its + resource paths within the API Management service instance. It is appended + to the API endpoint base URL specified during the service instance + creation to form a public URL for this API. + :type path: str + :param protocols: Describes on which protocols the operations in this API + can be invoked. + :type protocols: list[str or ~azure.mgmt.apimanagement.models.Protocol] + """ + + _validation = { + 'api_revision': {'max_length': 100, 'min_length': 1}, + 'api_version': {'max_length': 100}, + 'is_online': {'readonly': True}, + 'api_revision_description': {'max_length': 256}, + 'api_version_description': {'max_length': 256}, + 'name': {'max_length': 300, 'min_length': 1}, + 'service_url': {'max_length': 2000, 'min_length': 1}, + 'path': {'max_length': 400, 'min_length': 0}, + } + + _attribute_map = { + 'description': {'key': 'description', 'type': 'str'}, + 'authentication_settings': {'key': 'authenticationSettings', 'type': 'AuthenticationSettingsContract'}, + 'subscription_key_parameter_names': {'key': 'subscriptionKeyParameterNames', 'type': 'SubscriptionKeyParameterNamesContract'}, + 'api_type': {'key': 'type', 'type': 'str'}, + 'api_revision': {'key': 'apiRevision', 'type': 'str'}, + 'api_version': {'key': 'apiVersion', 'type': 'str'}, + 'is_current': {'key': 'isCurrent', 'type': 'bool'}, + 'is_online': {'key': 'isOnline', 'type': 'bool'}, + 'api_revision_description': {'key': 'apiRevisionDescription', 'type': 'str'}, + 'api_version_description': {'key': 'apiVersionDescription', 'type': 'str'}, + 'api_version_set_id': {'key': 'apiVersionSetId', 'type': 'str'}, + 'subscription_required': {'key': 'subscriptionRequired', 'type': 'bool'}, + 'id': {'key': 'id', 'type': 'str'}, + 'name': {'key': 'name', 'type': 'str'}, + 'service_url': {'key': 'serviceUrl', 'type': 'str'}, + 'path': {'key': 'path', 'type': 'str'}, + 'protocols': {'key': 'protocols', 'type': '[Protocol]'}, + } + + def __init__(self, **kwargs): + super(ApiTagResourceContractProperties, self).__init__(**kwargs) + self.id = kwargs.get('id', None) + self.name = kwargs.get('name', None) + self.service_url = kwargs.get('service_url', None) + self.path = kwargs.get('path', None) + self.protocols = kwargs.get('protocols', None) + + +class ApiUpdateContract(Model): + """API update contract details. + + Variables are only populated by the server, and will be ignored when + sending a request. + + :param description: Description of the API. May include HTML formatting + tags. + :type description: str + :param authentication_settings: Collection of authentication settings + included into this API. + :type authentication_settings: + ~azure.mgmt.apimanagement.models.AuthenticationSettingsContract + :param subscription_key_parameter_names: Protocols over which API is made + available. + :type subscription_key_parameter_names: + ~azure.mgmt.apimanagement.models.SubscriptionKeyParameterNamesContract + :param api_type: Type of API. Possible values include: 'http', 'soap' + :type api_type: str or ~azure.mgmt.apimanagement.models.ApiType + :param api_revision: Describes the Revision of the Api. If no value is + provided, default revision 1 is created + :type api_revision: str + :param api_version: Indicates the Version identifier of the API if the API + is versioned + :type api_version: str + :param is_current: Indicates if API revision is current api revision. + :type is_current: bool + :ivar is_online: Indicates if API revision is accessible via the gateway. + :vartype is_online: bool + :param api_revision_description: Description of the Api Revision. + :type api_revision_description: str + :param api_version_description: Description of the Api Version. + :type api_version_description: str + :param api_version_set_id: A resource identifier for the related + ApiVersionSet. + :type api_version_set_id: str + :param subscription_required: Specifies whether an API or Product + subscription is required for accessing the API. + :type subscription_required: bool + :param display_name: API name. + :type display_name: str + :param service_url: Absolute URL of the backend service implementing this + API. + :type service_url: str + :param path: Relative URL uniquely identifying this API and all of its + resource paths within the API Management service instance. It is appended + to the API endpoint base URL specified during the service instance + creation to form a public URL for this API. + :type path: str + :param protocols: Describes on which protocols the operations in this API + can be invoked. + :type protocols: list[str or ~azure.mgmt.apimanagement.models.Protocol] + """ + + _validation = { + 'api_revision': {'max_length': 100, 'min_length': 1}, + 'api_version': {'max_length': 100}, + 'is_online': {'readonly': True}, + 'api_revision_description': {'max_length': 256}, + 'api_version_description': {'max_length': 256}, + 'display_name': {'max_length': 300, 'min_length': 1}, + 'service_url': {'max_length': 2000, 'min_length': 1}, + 'path': {'max_length': 400, 'min_length': 0}, + } + + _attribute_map = { + 'description': {'key': 'properties.description', 'type': 'str'}, + 'authentication_settings': {'key': 'properties.authenticationSettings', 'type': 'AuthenticationSettingsContract'}, + 'subscription_key_parameter_names': {'key': 'properties.subscriptionKeyParameterNames', 'type': 'SubscriptionKeyParameterNamesContract'}, + 'api_type': {'key': 'properties.type', 'type': 'str'}, + 'api_revision': {'key': 'properties.apiRevision', 'type': 'str'}, + 'api_version': {'key': 'properties.apiVersion', 'type': 'str'}, + 'is_current': {'key': 'properties.isCurrent', 'type': 'bool'}, + 'is_online': {'key': 'properties.isOnline', 'type': 'bool'}, + 'api_revision_description': {'key': 'properties.apiRevisionDescription', 'type': 'str'}, + 'api_version_description': {'key': 'properties.apiVersionDescription', 'type': 'str'}, + 'api_version_set_id': {'key': 'properties.apiVersionSetId', 'type': 'str'}, + 'subscription_required': {'key': 'properties.subscriptionRequired', 'type': 'bool'}, + 'display_name': {'key': 'properties.displayName', 'type': 'str'}, + 'service_url': {'key': 'properties.serviceUrl', 'type': 'str'}, + 'path': {'key': 'properties.path', 'type': 'str'}, + 'protocols': {'key': 'properties.protocols', 'type': '[Protocol]'}, + } + + def __init__(self, **kwargs): + super(ApiUpdateContract, self).__init__(**kwargs) + self.description = kwargs.get('description', None) + self.authentication_settings = kwargs.get('authentication_settings', None) + self.subscription_key_parameter_names = kwargs.get('subscription_key_parameter_names', None) + self.api_type = kwargs.get('api_type', None) + self.api_revision = kwargs.get('api_revision', None) + self.api_version = kwargs.get('api_version', None) + self.is_current = kwargs.get('is_current', None) + self.is_online = None + self.api_revision_description = kwargs.get('api_revision_description', None) + self.api_version_description = kwargs.get('api_version_description', None) + self.api_version_set_id = kwargs.get('api_version_set_id', None) + self.subscription_required = kwargs.get('subscription_required', None) + self.display_name = kwargs.get('display_name', None) + self.service_url = kwargs.get('service_url', None) + self.path = kwargs.get('path', None) + self.protocols = kwargs.get('protocols', None) + + +class ApiVersionConstraint(Model): + """Control Plane Apis version constraint for the API Management service. + + :param min_api_version: Limit control plane API calls to API Management + service with version equal to or newer than this value. + :type min_api_version: str + """ + + _attribute_map = { + 'min_api_version': {'key': 'minApiVersion', 'type': 'str'}, + } + + def __init__(self, **kwargs): + super(ApiVersionConstraint, self).__init__(**kwargs) + self.min_api_version = kwargs.get('min_api_version', None) + + +class ApiVersionSetContract(Resource): + """Api Version Set Contract details. + + Variables are only populated by the server, and will be ignored when + sending a request. + + All required parameters must be populated in order to send to Azure. + + :ivar id: Resource ID. + :vartype id: str + :ivar name: Resource name. + :vartype name: str + :ivar type: Resource type for API Management resource. + :vartype type: str + :param description: Description of API Version Set. + :type description: str + :param version_query_name: Name of query parameter that indicates the API + Version if versioningScheme is set to `query`. + :type version_query_name: str + :param version_header_name: Name of HTTP header parameter that indicates + the API Version if versioningScheme is set to `header`. + :type version_header_name: str + :param display_name: Required. Name of API Version Set + :type display_name: str + :param versioning_scheme: Required. An value that determines where the API + Version identifer will be located in a HTTP request. Possible values + include: 'Segment', 'Query', 'Header' + :type versioning_scheme: str or + ~azure.mgmt.apimanagement.models.VersioningScheme + """ + + _validation = { + 'id': {'readonly': True}, + 'name': {'readonly': True}, + 'type': {'readonly': True}, + 'version_query_name': {'max_length': 100, 'min_length': 1}, + 'version_header_name': {'max_length': 100, 'min_length': 1}, + 'display_name': {'required': True, 'max_length': 100, 'min_length': 1}, + 'versioning_scheme': {'required': True}, + } + + _attribute_map = { + 'id': {'key': 'id', 'type': 'str'}, + 'name': {'key': 'name', 'type': 'str'}, + 'type': {'key': 'type', 'type': 'str'}, + 'description': {'key': 'properties.description', 'type': 'str'}, + 'version_query_name': {'key': 'properties.versionQueryName', 'type': 'str'}, + 'version_header_name': {'key': 'properties.versionHeaderName', 'type': 'str'}, + 'display_name': {'key': 'properties.displayName', 'type': 'str'}, + 'versioning_scheme': {'key': 'properties.versioningScheme', 'type': 'str'}, + } + + def __init__(self, **kwargs): + super(ApiVersionSetContract, self).__init__(**kwargs) + self.description = kwargs.get('description', None) + self.version_query_name = kwargs.get('version_query_name', None) + self.version_header_name = kwargs.get('version_header_name', None) + self.display_name = kwargs.get('display_name', None) + self.versioning_scheme = kwargs.get('versioning_scheme', None) + + +class ApiVersionSetContractDetails(Model): + """An API Version Set contains the common configuration for a set of API + Versions relating . + + :param id: Identifier for existing API Version Set. Omit this value to + create a new Version Set. + :type id: str + :param name: The display Name of the API Version Set. + :type name: str + :param description: Description of API Version Set. + :type description: str + :param versioning_scheme: An value that determines where the API Version + identifer will be located in a HTTP request. Possible values include: + 'Segment', 'Query', 'Header' + :type versioning_scheme: str or ~azure.mgmt.apimanagement.models.enum + :param version_query_name: Name of query parameter that indicates the API + Version if versioningScheme is set to `query`. + :type version_query_name: str + :param version_header_name: Name of HTTP header parameter that indicates + the API Version if versioningScheme is set to `header`. + :type version_header_name: str + """ + + _attribute_map = { + 'id': {'key': 'id', 'type': 'str'}, + 'name': {'key': 'name', 'type': 'str'}, + 'description': {'key': 'description', 'type': 'str'}, + 'versioning_scheme': {'key': 'versioningScheme', 'type': 'str'}, + 'version_query_name': {'key': 'versionQueryName', 'type': 'str'}, + 'version_header_name': {'key': 'versionHeaderName', 'type': 'str'}, + } + + def __init__(self, **kwargs): + super(ApiVersionSetContractDetails, self).__init__(**kwargs) + self.id = kwargs.get('id', None) + self.name = kwargs.get('name', None) + self.description = kwargs.get('description', None) + self.versioning_scheme = kwargs.get('versioning_scheme', None) + self.version_query_name = kwargs.get('version_query_name', None) + self.version_header_name = kwargs.get('version_header_name', None) + + +class ApiVersionSetEntityBase(Model): + """Api Version set base parameters. + + :param description: Description of API Version Set. + :type description: str + :param version_query_name: Name of query parameter that indicates the API + Version if versioningScheme is set to `query`. + :type version_query_name: str + :param version_header_name: Name of HTTP header parameter that indicates + the API Version if versioningScheme is set to `header`. + :type version_header_name: str + """ + + _validation = { + 'version_query_name': {'max_length': 100, 'min_length': 1}, + 'version_header_name': {'max_length': 100, 'min_length': 1}, + } + + _attribute_map = { + 'description': {'key': 'description', 'type': 'str'}, + 'version_query_name': {'key': 'versionQueryName', 'type': 'str'}, + 'version_header_name': {'key': 'versionHeaderName', 'type': 'str'}, + } + + def __init__(self, **kwargs): + super(ApiVersionSetEntityBase, self).__init__(**kwargs) + self.description = kwargs.get('description', None) + self.version_query_name = kwargs.get('version_query_name', None) + self.version_header_name = kwargs.get('version_header_name', None) + + +class ApiVersionSetUpdateParameters(Model): + """Parameters to update or create an Api Version Set Contract. + + :param description: Description of API Version Set. + :type description: str + :param version_query_name: Name of query parameter that indicates the API + Version if versioningScheme is set to `query`. + :type version_query_name: str + :param version_header_name: Name of HTTP header parameter that indicates + the API Version if versioningScheme is set to `header`. + :type version_header_name: str + :param display_name: Name of API Version Set + :type display_name: str + :param versioning_scheme: An value that determines where the API Version + identifer will be located in a HTTP request. Possible values include: + 'Segment', 'Query', 'Header' + :type versioning_scheme: str or + ~azure.mgmt.apimanagement.models.VersioningScheme + """ + + _validation = { + 'version_query_name': {'max_length': 100, 'min_length': 1}, + 'version_header_name': {'max_length': 100, 'min_length': 1}, + 'display_name': {'max_length': 100, 'min_length': 1}, + } + + _attribute_map = { + 'description': {'key': 'properties.description', 'type': 'str'}, + 'version_query_name': {'key': 'properties.versionQueryName', 'type': 'str'}, + 'version_header_name': {'key': 'properties.versionHeaderName', 'type': 'str'}, + 'display_name': {'key': 'properties.displayName', 'type': 'str'}, + 'versioning_scheme': {'key': 'properties.versioningScheme', 'type': 'str'}, + } + + def __init__(self, **kwargs): + super(ApiVersionSetUpdateParameters, self).__init__(**kwargs) + self.description = kwargs.get('description', None) + self.version_query_name = kwargs.get('version_query_name', None) + self.version_header_name = kwargs.get('version_header_name', None) + self.display_name = kwargs.get('display_name', None) + self.versioning_scheme = kwargs.get('versioning_scheme', None) + + +class AuthenticationSettingsContract(Model): + """API Authentication Settings. + + :param o_auth2: OAuth2 Authentication settings + :type o_auth2: + ~azure.mgmt.apimanagement.models.OAuth2AuthenticationSettingsContract + :param openid: OpenID Connect Authentication Settings + :type openid: + ~azure.mgmt.apimanagement.models.OpenIdAuthenticationSettingsContract + """ + + _attribute_map = { + 'o_auth2': {'key': 'oAuth2', 'type': 'OAuth2AuthenticationSettingsContract'}, + 'openid': {'key': 'openid', 'type': 'OpenIdAuthenticationSettingsContract'}, + } + + def __init__(self, **kwargs): + super(AuthenticationSettingsContract, self).__init__(**kwargs) + self.o_auth2 = kwargs.get('o_auth2', None) + self.openid = kwargs.get('openid', None) + + +class AuthorizationServerContract(Resource): + """External OAuth authorization server settings. + + Variables are only populated by the server, and will be ignored when + sending a request. + + All required parameters must be populated in order to send to Azure. + + :ivar id: Resource ID. + :vartype id: str + :ivar name: Resource name. + :vartype name: str + :ivar type: Resource type for API Management resource. + :vartype type: str + :param description: Description of the authorization server. Can contain + HTML formatting tags. + :type description: str + :param authorization_methods: HTTP verbs supported by the authorization + endpoint. GET must be always present. POST is optional. + :type authorization_methods: list[str or + ~azure.mgmt.apimanagement.models.AuthorizationMethod] + :param client_authentication_method: Method of authentication supported by + the token endpoint of this authorization server. Possible values are Basic + and/or Body. When Body is specified, client credentials and other + parameters are passed within the request body in the + application/x-www-form-urlencoded format. + :type client_authentication_method: list[str or + ~azure.mgmt.apimanagement.models.ClientAuthenticationMethod] + :param token_body_parameters: Additional parameters required by the token + endpoint of this authorization server represented as an array of JSON + objects with name and value string properties, i.e. {"name" : "name + value", "value": "a value"}. + :type token_body_parameters: + list[~azure.mgmt.apimanagement.models.TokenBodyParameterContract] + :param token_endpoint: OAuth token endpoint. Contains absolute URI to + entity being referenced. + :type token_endpoint: str + :param support_state: If true, authorization server will include state + parameter from the authorization request to its response. Client may use + state parameter to raise protocol security. + :type support_state: bool + :param default_scope: Access token scope that is going to be requested by + default. Can be overridden at the API level. Should be provided in the + form of a string containing space-delimited values. + :type default_scope: str + :param bearer_token_sending_methods: Specifies the mechanism by which + access token is passed to the API. + :type bearer_token_sending_methods: list[str or + ~azure.mgmt.apimanagement.models.BearerTokenSendingMethod] + :param resource_owner_username: Can be optionally specified when resource + owner password grant type is supported by this authorization server. + Default resource owner username. + :type resource_owner_username: str + :param resource_owner_password: Can be optionally specified when resource + owner password grant type is supported by this authorization server. + Default resource owner password. + :type resource_owner_password: str + :param display_name: Required. User-friendly authorization server name. + :type display_name: str + :param client_registration_endpoint: Required. Optional reference to a + page where client or app registration for this authorization server is + performed. Contains absolute URL to entity being referenced. + :type client_registration_endpoint: str + :param authorization_endpoint: Required. OAuth authorization endpoint. See + http://tools.ietf.org/html/rfc6749#section-3.2. + :type authorization_endpoint: str + :param grant_types: Required. Form of an authorization grant, which the + client uses to request the access token. + :type grant_types: list[str or ~azure.mgmt.apimanagement.models.GrantType] + :param client_id: Required. Client or app id registered with this + authorization server. + :type client_id: str + :param client_secret: Client or app secret registered with this + authorization server. This property will not be filled on 'GET' + operations! Use '/listSecrets' POST request to get the value. + :type client_secret: str + """ + + _validation = { + 'id': {'readonly': True}, + 'name': {'readonly': True}, + 'type': {'readonly': True}, + 'display_name': {'required': True, 'max_length': 50, 'min_length': 1}, + 'client_registration_endpoint': {'required': True}, + 'authorization_endpoint': {'required': True}, + 'grant_types': {'required': True}, + 'client_id': {'required': True}, + } + + _attribute_map = { + 'id': {'key': 'id', 'type': 'str'}, + 'name': {'key': 'name', 'type': 'str'}, + 'type': {'key': 'type', 'type': 'str'}, + 'description': {'key': 'properties.description', 'type': 'str'}, + 'authorization_methods': {'key': 'properties.authorizationMethods', 'type': '[AuthorizationMethod]'}, + 'client_authentication_method': {'key': 'properties.clientAuthenticationMethod', 'type': '[str]'}, + 'token_body_parameters': {'key': 'properties.tokenBodyParameters', 'type': '[TokenBodyParameterContract]'}, + 'token_endpoint': {'key': 'properties.tokenEndpoint', 'type': 'str'}, + 'support_state': {'key': 'properties.supportState', 'type': 'bool'}, + 'default_scope': {'key': 'properties.defaultScope', 'type': 'str'}, + 'bearer_token_sending_methods': {'key': 'properties.bearerTokenSendingMethods', 'type': '[str]'}, + 'resource_owner_username': {'key': 'properties.resourceOwnerUsername', 'type': 'str'}, + 'resource_owner_password': {'key': 'properties.resourceOwnerPassword', 'type': 'str'}, + 'display_name': {'key': 'properties.displayName', 'type': 'str'}, + 'client_registration_endpoint': {'key': 'properties.clientRegistrationEndpoint', 'type': 'str'}, + 'authorization_endpoint': {'key': 'properties.authorizationEndpoint', 'type': 'str'}, + 'grant_types': {'key': 'properties.grantTypes', 'type': '[str]'}, + 'client_id': {'key': 'properties.clientId', 'type': 'str'}, + 'client_secret': {'key': 'properties.clientSecret', 'type': 'str'}, + } + + def __init__(self, **kwargs): + super(AuthorizationServerContract, self).__init__(**kwargs) + self.description = kwargs.get('description', None) + self.authorization_methods = kwargs.get('authorization_methods', None) + self.client_authentication_method = kwargs.get('client_authentication_method', None) + self.token_body_parameters = kwargs.get('token_body_parameters', None) + self.token_endpoint = kwargs.get('token_endpoint', None) + self.support_state = kwargs.get('support_state', None) + self.default_scope = kwargs.get('default_scope', None) + self.bearer_token_sending_methods = kwargs.get('bearer_token_sending_methods', None) + self.resource_owner_username = kwargs.get('resource_owner_username', None) + self.resource_owner_password = kwargs.get('resource_owner_password', None) + self.display_name = kwargs.get('display_name', None) + self.client_registration_endpoint = kwargs.get('client_registration_endpoint', None) + self.authorization_endpoint = kwargs.get('authorization_endpoint', None) + self.grant_types = kwargs.get('grant_types', None) + self.client_id = kwargs.get('client_id', None) + self.client_secret = kwargs.get('client_secret', None) + + +class AuthorizationServerContractBaseProperties(Model): + """External OAuth authorization server Update settings contract. + + :param description: Description of the authorization server. Can contain + HTML formatting tags. + :type description: str + :param authorization_methods: HTTP verbs supported by the authorization + endpoint. GET must be always present. POST is optional. + :type authorization_methods: list[str or + ~azure.mgmt.apimanagement.models.AuthorizationMethod] + :param client_authentication_method: Method of authentication supported by + the token endpoint of this authorization server. Possible values are Basic + and/or Body. When Body is specified, client credentials and other + parameters are passed within the request body in the + application/x-www-form-urlencoded format. + :type client_authentication_method: list[str or + ~azure.mgmt.apimanagement.models.ClientAuthenticationMethod] + :param token_body_parameters: Additional parameters required by the token + endpoint of this authorization server represented as an array of JSON + objects with name and value string properties, i.e. {"name" : "name + value", "value": "a value"}. + :type token_body_parameters: + list[~azure.mgmt.apimanagement.models.TokenBodyParameterContract] + :param token_endpoint: OAuth token endpoint. Contains absolute URI to + entity being referenced. + :type token_endpoint: str + :param support_state: If true, authorization server will include state + parameter from the authorization request to its response. Client may use + state parameter to raise protocol security. + :type support_state: bool + :param default_scope: Access token scope that is going to be requested by + default. Can be overridden at the API level. Should be provided in the + form of a string containing space-delimited values. + :type default_scope: str + :param bearer_token_sending_methods: Specifies the mechanism by which + access token is passed to the API. + :type bearer_token_sending_methods: list[str or + ~azure.mgmt.apimanagement.models.BearerTokenSendingMethod] + :param resource_owner_username: Can be optionally specified when resource + owner password grant type is supported by this authorization server. + Default resource owner username. + :type resource_owner_username: str + :param resource_owner_password: Can be optionally specified when resource + owner password grant type is supported by this authorization server. + Default resource owner password. + :type resource_owner_password: str + """ + + _attribute_map = { + 'description': {'key': 'description', 'type': 'str'}, + 'authorization_methods': {'key': 'authorizationMethods', 'type': '[AuthorizationMethod]'}, + 'client_authentication_method': {'key': 'clientAuthenticationMethod', 'type': '[str]'}, + 'token_body_parameters': {'key': 'tokenBodyParameters', 'type': '[TokenBodyParameterContract]'}, + 'token_endpoint': {'key': 'tokenEndpoint', 'type': 'str'}, + 'support_state': {'key': 'supportState', 'type': 'bool'}, + 'default_scope': {'key': 'defaultScope', 'type': 'str'}, + 'bearer_token_sending_methods': {'key': 'bearerTokenSendingMethods', 'type': '[str]'}, + 'resource_owner_username': {'key': 'resourceOwnerUsername', 'type': 'str'}, + 'resource_owner_password': {'key': 'resourceOwnerPassword', 'type': 'str'}, + } + + def __init__(self, **kwargs): + super(AuthorizationServerContractBaseProperties, self).__init__(**kwargs) + self.description = kwargs.get('description', None) + self.authorization_methods = kwargs.get('authorization_methods', None) + self.client_authentication_method = kwargs.get('client_authentication_method', None) + self.token_body_parameters = kwargs.get('token_body_parameters', None) + self.token_endpoint = kwargs.get('token_endpoint', None) + self.support_state = kwargs.get('support_state', None) + self.default_scope = kwargs.get('default_scope', None) + self.bearer_token_sending_methods = kwargs.get('bearer_token_sending_methods', None) + self.resource_owner_username = kwargs.get('resource_owner_username', None) + self.resource_owner_password = kwargs.get('resource_owner_password', None) + + +class AuthorizationServerUpdateContract(Resource): + """External OAuth authorization server settings. + + Variables are only populated by the server, and will be ignored when + sending a request. + + :ivar id: Resource ID. + :vartype id: str + :ivar name: Resource name. + :vartype name: str + :ivar type: Resource type for API Management resource. + :vartype type: str + :param description: Description of the authorization server. Can contain + HTML formatting tags. + :type description: str + :param authorization_methods: HTTP verbs supported by the authorization + endpoint. GET must be always present. POST is optional. + :type authorization_methods: list[str or + ~azure.mgmt.apimanagement.models.AuthorizationMethod] + :param client_authentication_method: Method of authentication supported by + the token endpoint of this authorization server. Possible values are Basic + and/or Body. When Body is specified, client credentials and other + parameters are passed within the request body in the + application/x-www-form-urlencoded format. + :type client_authentication_method: list[str or + ~azure.mgmt.apimanagement.models.ClientAuthenticationMethod] + :param token_body_parameters: Additional parameters required by the token + endpoint of this authorization server represented as an array of JSON + objects with name and value string properties, i.e. {"name" : "name + value", "value": "a value"}. + :type token_body_parameters: + list[~azure.mgmt.apimanagement.models.TokenBodyParameterContract] + :param token_endpoint: OAuth token endpoint. Contains absolute URI to + entity being referenced. + :type token_endpoint: str + :param support_state: If true, authorization server will include state + parameter from the authorization request to its response. Client may use + state parameter to raise protocol security. + :type support_state: bool + :param default_scope: Access token scope that is going to be requested by + default. Can be overridden at the API level. Should be provided in the + form of a string containing space-delimited values. + :type default_scope: str + :param bearer_token_sending_methods: Specifies the mechanism by which + access token is passed to the API. + :type bearer_token_sending_methods: list[str or + ~azure.mgmt.apimanagement.models.BearerTokenSendingMethod] + :param resource_owner_username: Can be optionally specified when resource + owner password grant type is supported by this authorization server. + Default resource owner username. + :type resource_owner_username: str + :param resource_owner_password: Can be optionally specified when resource + owner password grant type is supported by this authorization server. + Default resource owner password. + :type resource_owner_password: str + :param display_name: User-friendly authorization server name. + :type display_name: str + :param client_registration_endpoint: Optional reference to a page where + client or app registration for this authorization server is performed. + Contains absolute URL to entity being referenced. + :type client_registration_endpoint: str + :param authorization_endpoint: OAuth authorization endpoint. See + http://tools.ietf.org/html/rfc6749#section-3.2. + :type authorization_endpoint: str + :param grant_types: Form of an authorization grant, which the client uses + to request the access token. + :type grant_types: list[str or ~azure.mgmt.apimanagement.models.GrantType] + :param client_id: Client or app id registered with this authorization + server. + :type client_id: str + :param client_secret: Client or app secret registered with this + authorization server. This property will not be filled on 'GET' + operations! Use '/listSecrets' POST request to get the value. + :type client_secret: str + """ + + _validation = { + 'id': {'readonly': True}, + 'name': {'readonly': True}, + 'type': {'readonly': True}, + 'display_name': {'max_length': 50, 'min_length': 1}, + } + + _attribute_map = { + 'id': {'key': 'id', 'type': 'str'}, + 'name': {'key': 'name', 'type': 'str'}, + 'type': {'key': 'type', 'type': 'str'}, + 'description': {'key': 'properties.description', 'type': 'str'}, + 'authorization_methods': {'key': 'properties.authorizationMethods', 'type': '[AuthorizationMethod]'}, + 'client_authentication_method': {'key': 'properties.clientAuthenticationMethod', 'type': '[str]'}, + 'token_body_parameters': {'key': 'properties.tokenBodyParameters', 'type': '[TokenBodyParameterContract]'}, + 'token_endpoint': {'key': 'properties.tokenEndpoint', 'type': 'str'}, + 'support_state': {'key': 'properties.supportState', 'type': 'bool'}, + 'default_scope': {'key': 'properties.defaultScope', 'type': 'str'}, + 'bearer_token_sending_methods': {'key': 'properties.bearerTokenSendingMethods', 'type': '[str]'}, + 'resource_owner_username': {'key': 'properties.resourceOwnerUsername', 'type': 'str'}, + 'resource_owner_password': {'key': 'properties.resourceOwnerPassword', 'type': 'str'}, + 'display_name': {'key': 'properties.displayName', 'type': 'str'}, + 'client_registration_endpoint': {'key': 'properties.clientRegistrationEndpoint', 'type': 'str'}, + 'authorization_endpoint': {'key': 'properties.authorizationEndpoint', 'type': 'str'}, + 'grant_types': {'key': 'properties.grantTypes', 'type': '[str]'}, + 'client_id': {'key': 'properties.clientId', 'type': 'str'}, + 'client_secret': {'key': 'properties.clientSecret', 'type': 'str'}, + } + + def __init__(self, **kwargs): + super(AuthorizationServerUpdateContract, self).__init__(**kwargs) + self.description = kwargs.get('description', None) + self.authorization_methods = kwargs.get('authorization_methods', None) + self.client_authentication_method = kwargs.get('client_authentication_method', None) + self.token_body_parameters = kwargs.get('token_body_parameters', None) + self.token_endpoint = kwargs.get('token_endpoint', None) + self.support_state = kwargs.get('support_state', None) + self.default_scope = kwargs.get('default_scope', None) + self.bearer_token_sending_methods = kwargs.get('bearer_token_sending_methods', None) + self.resource_owner_username = kwargs.get('resource_owner_username', None) + self.resource_owner_password = kwargs.get('resource_owner_password', None) + self.display_name = kwargs.get('display_name', None) + self.client_registration_endpoint = kwargs.get('client_registration_endpoint', None) + self.authorization_endpoint = kwargs.get('authorization_endpoint', None) + self.grant_types = kwargs.get('grant_types', None) + self.client_id = kwargs.get('client_id', None) + self.client_secret = kwargs.get('client_secret', None) + + +class BackendAuthorizationHeaderCredentials(Model): + """Authorization header information. + + All required parameters must be populated in order to send to Azure. + + :param scheme: Required. Authentication Scheme name. + :type scheme: str + :param parameter: Required. Authentication Parameter value. + :type parameter: str + """ + + _validation = { + 'scheme': {'required': True, 'max_length': 100, 'min_length': 1}, + 'parameter': {'required': True, 'max_length': 300, 'min_length': 1}, + } + + _attribute_map = { + 'scheme': {'key': 'scheme', 'type': 'str'}, + 'parameter': {'key': 'parameter', 'type': 'str'}, + } + + def __init__(self, **kwargs): + super(BackendAuthorizationHeaderCredentials, self).__init__(**kwargs) + self.scheme = kwargs.get('scheme', None) + self.parameter = kwargs.get('parameter', None) + + +class BackendBaseParameters(Model): + """Backend entity base Parameter set. + + :param title: Backend Title. + :type title: str + :param description: Backend Description. + :type description: str + :param resource_id: Management Uri of the Resource in External System. + This url can be the Arm Resource Id of Logic Apps, Function Apps or Api + Apps. + :type resource_id: str + :param properties: Backend Properties contract + :type properties: ~azure.mgmt.apimanagement.models.BackendProperties + :param credentials: Backend Credentials Contract Properties + :type credentials: + ~azure.mgmt.apimanagement.models.BackendCredentialsContract + :param proxy: Backend Proxy Contract Properties + :type proxy: ~azure.mgmt.apimanagement.models.BackendProxyContract + :param tls: Backend TLS Properties + :type tls: ~azure.mgmt.apimanagement.models.BackendTlsProperties + """ + + _validation = { + 'title': {'max_length': 300, 'min_length': 1}, + 'description': {'max_length': 2000, 'min_length': 1}, + 'resource_id': {'max_length': 2000, 'min_length': 1}, + } + + _attribute_map = { + 'title': {'key': 'title', 'type': 'str'}, + 'description': {'key': 'description', 'type': 'str'}, + 'resource_id': {'key': 'resourceId', 'type': 'str'}, + 'properties': {'key': 'properties', 'type': 'BackendProperties'}, + 'credentials': {'key': 'credentials', 'type': 'BackendCredentialsContract'}, + 'proxy': {'key': 'proxy', 'type': 'BackendProxyContract'}, + 'tls': {'key': 'tls', 'type': 'BackendTlsProperties'}, + } + + def __init__(self, **kwargs): + super(BackendBaseParameters, self).__init__(**kwargs) + self.title = kwargs.get('title', None) + self.description = kwargs.get('description', None) + self.resource_id = kwargs.get('resource_id', None) + self.properties = kwargs.get('properties', None) + self.credentials = kwargs.get('credentials', None) + self.proxy = kwargs.get('proxy', None) + self.tls = kwargs.get('tls', None) + + +class BackendContract(Resource): + """Backend details. + + Variables are only populated by the server, and will be ignored when + sending a request. + + All required parameters must be populated in order to send to Azure. + + :ivar id: Resource ID. + :vartype id: str + :ivar name: Resource name. + :vartype name: str + :ivar type: Resource type for API Management resource. + :vartype type: str + :param title: Backend Title. + :type title: str + :param description: Backend Description. + :type description: str + :param resource_id: Management Uri of the Resource in External System. + This url can be the Arm Resource Id of Logic Apps, Function Apps or Api + Apps. + :type resource_id: str + :param properties: Backend Properties contract + :type properties: ~azure.mgmt.apimanagement.models.BackendProperties + :param credentials: Backend Credentials Contract Properties + :type credentials: + ~azure.mgmt.apimanagement.models.BackendCredentialsContract + :param proxy: Backend Proxy Contract Properties + :type proxy: ~azure.mgmt.apimanagement.models.BackendProxyContract + :param tls: Backend TLS Properties + :type tls: ~azure.mgmt.apimanagement.models.BackendTlsProperties + :param url: Required. Runtime Url of the Backend. + :type url: str + :param protocol: Required. Backend communication protocol. Possible values + include: 'http', 'soap' + :type protocol: str or ~azure.mgmt.apimanagement.models.BackendProtocol + """ + + _validation = { + 'id': {'readonly': True}, + 'name': {'readonly': True}, + 'type': {'readonly': True}, + 'title': {'max_length': 300, 'min_length': 1}, + 'description': {'max_length': 2000, 'min_length': 1}, + 'resource_id': {'max_length': 2000, 'min_length': 1}, + 'url': {'required': True, 'max_length': 2000, 'min_length': 1}, + 'protocol': {'required': True}, + } + + _attribute_map = { + 'id': {'key': 'id', 'type': 'str'}, + 'name': {'key': 'name', 'type': 'str'}, + 'type': {'key': 'type', 'type': 'str'}, + 'title': {'key': 'properties.title', 'type': 'str'}, + 'description': {'key': 'properties.description', 'type': 'str'}, + 'resource_id': {'key': 'properties.resourceId', 'type': 'str'}, + 'properties': {'key': 'properties.properties', 'type': 'BackendProperties'}, + 'credentials': {'key': 'properties.credentials', 'type': 'BackendCredentialsContract'}, + 'proxy': {'key': 'properties.proxy', 'type': 'BackendProxyContract'}, + 'tls': {'key': 'properties.tls', 'type': 'BackendTlsProperties'}, + 'url': {'key': 'properties.url', 'type': 'str'}, + 'protocol': {'key': 'properties.protocol', 'type': 'str'}, + } + + def __init__(self, **kwargs): + super(BackendContract, self).__init__(**kwargs) + self.title = kwargs.get('title', None) + self.description = kwargs.get('description', None) + self.resource_id = kwargs.get('resource_id', None) + self.properties = kwargs.get('properties', None) + self.credentials = kwargs.get('credentials', None) + self.proxy = kwargs.get('proxy', None) + self.tls = kwargs.get('tls', None) + self.url = kwargs.get('url', None) + self.protocol = kwargs.get('protocol', None) + + +class BackendCredentialsContract(Model): + """Details of the Credentials used to connect to Backend. + + :param certificate: List of Client Certificate Thumbprint. + :type certificate: list[str] + :param query: Query Parameter description. + :type query: dict[str, list[str]] + :param header: Header Parameter description. + :type header: dict[str, list[str]] + :param authorization: Authorization header authentication + :type authorization: + ~azure.mgmt.apimanagement.models.BackendAuthorizationHeaderCredentials + """ + + _validation = { + 'certificate': {'max_items': 32}, + } + + _attribute_map = { + 'certificate': {'key': 'certificate', 'type': '[str]'}, + 'query': {'key': 'query', 'type': '{[str]}'}, + 'header': {'key': 'header', 'type': '{[str]}'}, + 'authorization': {'key': 'authorization', 'type': 'BackendAuthorizationHeaderCredentials'}, + } + + def __init__(self, **kwargs): + super(BackendCredentialsContract, self).__init__(**kwargs) + self.certificate = kwargs.get('certificate', None) + self.query = kwargs.get('query', None) + self.header = kwargs.get('header', None) + self.authorization = kwargs.get('authorization', None) + + +class BackendProperties(Model): + """Properties specific to the Backend Type. + + :param service_fabric_cluster: Backend Service Fabric Cluster Properties + :type service_fabric_cluster: + ~azure.mgmt.apimanagement.models.BackendServiceFabricClusterProperties + """ + + _attribute_map = { + 'service_fabric_cluster': {'key': 'serviceFabricCluster', 'type': 'BackendServiceFabricClusterProperties'}, + } + + def __init__(self, **kwargs): + super(BackendProperties, self).__init__(**kwargs) + self.service_fabric_cluster = kwargs.get('service_fabric_cluster', None) + + +class BackendProxyContract(Model): + """Details of the Backend WebProxy Server to use in the Request to Backend. + + All required parameters must be populated in order to send to Azure. + + :param url: Required. WebProxy Server AbsoluteUri property which includes + the entire URI stored in the Uri instance, including all fragments and + query strings. + :type url: str + :param username: Username to connect to the WebProxy server + :type username: str + :param password: Password to connect to the WebProxy Server + :type password: str + """ + + _validation = { + 'url': {'required': True, 'max_length': 2000, 'min_length': 1}, + } + + _attribute_map = { + 'url': {'key': 'url', 'type': 'str'}, + 'username': {'key': 'username', 'type': 'str'}, + 'password': {'key': 'password', 'type': 'str'}, + } + + def __init__(self, **kwargs): + super(BackendProxyContract, self).__init__(**kwargs) + self.url = kwargs.get('url', None) + self.username = kwargs.get('username', None) + self.password = kwargs.get('password', None) + + +class BackendReconnectContract(Resource): + """Reconnect request parameters. + + Variables are only populated by the server, and will be ignored when + sending a request. + + :ivar id: Resource ID. + :vartype id: str + :ivar name: Resource name. + :vartype name: str + :ivar type: Resource type for API Management resource. + :vartype type: str + :param after: Duration in ISO8601 format after which reconnect will be + initiated. Minimum duration of the Reconnect is PT2M. + :type after: timedelta + """ + + _validation = { + 'id': {'readonly': True}, + 'name': {'readonly': True}, + 'type': {'readonly': True}, + } + + _attribute_map = { + 'id': {'key': 'id', 'type': 'str'}, + 'name': {'key': 'name', 'type': 'str'}, + 'type': {'key': 'type', 'type': 'str'}, + 'after': {'key': 'properties.after', 'type': 'duration'}, + } + + def __init__(self, **kwargs): + super(BackendReconnectContract, self).__init__(**kwargs) + self.after = kwargs.get('after', None) + + +class BackendServiceFabricClusterProperties(Model): + """Properties of the Service Fabric Type Backend. + + All required parameters must be populated in order to send to Azure. + + :param client_certificatethumbprint: Required. The client certificate + thumbprint for the management endpoint. + :type client_certificatethumbprint: str + :param max_partition_resolution_retries: Maximum number of retries while + attempting resolve the partition. + :type max_partition_resolution_retries: int + :param management_endpoints: Required. The cluster management endpoint. + :type management_endpoints: list[str] + :param server_certificate_thumbprints: Thumbprints of certificates cluster + management service uses for tls communication + :type server_certificate_thumbprints: list[str] + :param server_x509_names: Server X509 Certificate Names Collection + :type server_x509_names: + list[~azure.mgmt.apimanagement.models.X509CertificateName] + """ + + _validation = { + 'client_certificatethumbprint': {'required': True}, + 'management_endpoints': {'required': True}, + } + + _attribute_map = { + 'client_certificatethumbprint': {'key': 'clientCertificatethumbprint', 'type': 'str'}, + 'max_partition_resolution_retries': {'key': 'maxPartitionResolutionRetries', 'type': 'int'}, + 'management_endpoints': {'key': 'managementEndpoints', 'type': '[str]'}, + 'server_certificate_thumbprints': {'key': 'serverCertificateThumbprints', 'type': '[str]'}, + 'server_x509_names': {'key': 'serverX509Names', 'type': '[X509CertificateName]'}, + } + + def __init__(self, **kwargs): + super(BackendServiceFabricClusterProperties, self).__init__(**kwargs) + self.client_certificatethumbprint = kwargs.get('client_certificatethumbprint', None) + self.max_partition_resolution_retries = kwargs.get('max_partition_resolution_retries', None) + self.management_endpoints = kwargs.get('management_endpoints', None) + self.server_certificate_thumbprints = kwargs.get('server_certificate_thumbprints', None) + self.server_x509_names = kwargs.get('server_x509_names', None) + + +class BackendTlsProperties(Model): + """Properties controlling TLS Certificate Validation. + + :param validate_certificate_chain: Flag indicating whether SSL certificate + chain validation should be done when using self-signed certificates for + this backend host. Default value: True . + :type validate_certificate_chain: bool + :param validate_certificate_name: Flag indicating whether SSL certificate + name validation should be done when using self-signed certificates for + this backend host. Default value: True . + :type validate_certificate_name: bool + """ + + _attribute_map = { + 'validate_certificate_chain': {'key': 'validateCertificateChain', 'type': 'bool'}, + 'validate_certificate_name': {'key': 'validateCertificateName', 'type': 'bool'}, + } + + def __init__(self, **kwargs): + super(BackendTlsProperties, self).__init__(**kwargs) + self.validate_certificate_chain = kwargs.get('validate_certificate_chain', True) + self.validate_certificate_name = kwargs.get('validate_certificate_name', True) + + +class BackendUpdateParameters(Model): + """Backend update parameters. + + :param title: Backend Title. + :type title: str + :param description: Backend Description. + :type description: str + :param resource_id: Management Uri of the Resource in External System. + This url can be the Arm Resource Id of Logic Apps, Function Apps or Api + Apps. + :type resource_id: str + :param properties: Backend Properties contract + :type properties: ~azure.mgmt.apimanagement.models.BackendProperties + :param credentials: Backend Credentials Contract Properties + :type credentials: + ~azure.mgmt.apimanagement.models.BackendCredentialsContract + :param proxy: Backend Proxy Contract Properties + :type proxy: ~azure.mgmt.apimanagement.models.BackendProxyContract + :param tls: Backend TLS Properties + :type tls: ~azure.mgmt.apimanagement.models.BackendTlsProperties + :param url: Runtime Url of the Backend. + :type url: str + :param protocol: Backend communication protocol. Possible values include: + 'http', 'soap' + :type protocol: str or ~azure.mgmt.apimanagement.models.BackendProtocol + """ + + _validation = { + 'title': {'max_length': 300, 'min_length': 1}, + 'description': {'max_length': 2000, 'min_length': 1}, + 'resource_id': {'max_length': 2000, 'min_length': 1}, + 'url': {'max_length': 2000, 'min_length': 1}, + } + + _attribute_map = { + 'title': {'key': 'properties.title', 'type': 'str'}, + 'description': {'key': 'properties.description', 'type': 'str'}, + 'resource_id': {'key': 'properties.resourceId', 'type': 'str'}, + 'properties': {'key': 'properties.properties', 'type': 'BackendProperties'}, + 'credentials': {'key': 'properties.credentials', 'type': 'BackendCredentialsContract'}, + 'proxy': {'key': 'properties.proxy', 'type': 'BackendProxyContract'}, + 'tls': {'key': 'properties.tls', 'type': 'BackendTlsProperties'}, + 'url': {'key': 'properties.url', 'type': 'str'}, + 'protocol': {'key': 'properties.protocol', 'type': 'str'}, + } + + def __init__(self, **kwargs): + super(BackendUpdateParameters, self).__init__(**kwargs) + self.title = kwargs.get('title', None) + self.description = kwargs.get('description', None) + self.resource_id = kwargs.get('resource_id', None) + self.properties = kwargs.get('properties', None) + self.credentials = kwargs.get('credentials', None) + self.proxy = kwargs.get('proxy', None) + self.tls = kwargs.get('tls', None) + self.url = kwargs.get('url', None) + self.protocol = kwargs.get('protocol', None) + + +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) + + +class CacheContract(Resource): + """Cache details. + + Variables are only populated by the server, and will be ignored when + sending a request. + + All required parameters must be populated in order to send to Azure. + + :ivar id: Resource ID. + :vartype id: str + :ivar name: Resource name. + :vartype name: str + :ivar type: Resource type for API Management resource. + :vartype type: str + :param description: Cache description + :type description: str + :param connection_string: Required. Runtime connection string to cache + :type connection_string: str + :param resource_id: Original uri of entity in external system cache points + to + :type resource_id: str + """ + + _validation = { + 'id': {'readonly': True}, + 'name': {'readonly': True}, + 'type': {'readonly': True}, + 'description': {'max_length': 2000}, + 'connection_string': {'required': True, 'max_length': 300}, + 'resource_id': {'max_length': 2000}, + } + + _attribute_map = { + 'id': {'key': 'id', 'type': 'str'}, + 'name': {'key': 'name', 'type': 'str'}, + 'type': {'key': 'type', 'type': 'str'}, + 'description': {'key': 'properties.description', 'type': 'str'}, + 'connection_string': {'key': 'properties.connectionString', 'type': 'str'}, + 'resource_id': {'key': 'properties.resourceId', 'type': 'str'}, + } + + def __init__(self, **kwargs): + super(CacheContract, self).__init__(**kwargs) + self.description = kwargs.get('description', None) + self.connection_string = kwargs.get('connection_string', None) + self.resource_id = kwargs.get('resource_id', None) + + +class CacheUpdateParameters(Model): + """Cache update details. + + :param description: Cache description + :type description: str + :param connection_string: Runtime connection string to cache + :type connection_string: str + :param resource_id: Original uri of entity in external system cache points + to + :type resource_id: str + """ + + _validation = { + 'description': {'max_length': 2000}, + 'connection_string': {'max_length': 300}, + 'resource_id': {'max_length': 2000}, + } + + _attribute_map = { + 'description': {'key': 'properties.description', 'type': 'str'}, + 'connection_string': {'key': 'properties.connectionString', 'type': 'str'}, + 'resource_id': {'key': 'properties.resourceId', 'type': 'str'}, + } + + def __init__(self, **kwargs): + super(CacheUpdateParameters, self).__init__(**kwargs) + self.description = kwargs.get('description', None) + self.connection_string = kwargs.get('connection_string', None) + self.resource_id = kwargs.get('resource_id', None) + + +class CertificateConfiguration(Model): + """Certificate configuration which consist of non-trusted intermediates and + root certificates. + + All required parameters must be populated in order to send to Azure. + + :param encoded_certificate: Base64 Encoded certificate. + :type encoded_certificate: str + :param certificate_password: Certificate Password. + :type certificate_password: str + :param store_name: Required. The + System.Security.Cryptography.x509certificates.StoreName certificate store + location. Only Root and CertificateAuthority are valid locations. Possible + values include: 'CertificateAuthority', 'Root' + :type store_name: str or ~azure.mgmt.apimanagement.models.enum + :param certificate: Certificate information. + :type certificate: ~azure.mgmt.apimanagement.models.CertificateInformation + """ + + _validation = { + 'store_name': {'required': True}, + } + + _attribute_map = { + 'encoded_certificate': {'key': 'encodedCertificate', 'type': 'str'}, + 'certificate_password': {'key': 'certificatePassword', 'type': 'str'}, + 'store_name': {'key': 'storeName', 'type': 'str'}, + 'certificate': {'key': 'certificate', 'type': 'CertificateInformation'}, + } + + def __init__(self, **kwargs): + super(CertificateConfiguration, self).__init__(**kwargs) + self.encoded_certificate = kwargs.get('encoded_certificate', None) + self.certificate_password = kwargs.get('certificate_password', None) + self.store_name = kwargs.get('store_name', None) + self.certificate = kwargs.get('certificate', None) + + +class CertificateContract(Resource): + """Certificate details. + + Variables are only populated by the server, and will be ignored when + sending a request. + + All required parameters must be populated in order to send to Azure. + + :ivar id: Resource ID. + :vartype id: str + :ivar name: Resource name. + :vartype name: str + :ivar type: Resource type for API Management resource. + :vartype type: str + :param subject: Required. Subject attribute of the certificate. + :type subject: str + :param thumbprint: Required. Thumbprint of the certificate. + :type thumbprint: str + :param expiration_date: Required. Expiration date of the certificate. The + date conforms to the following format: `yyyy-MM-ddTHH:mm:ssZ` as specified + by the ISO 8601 standard. + :type expiration_date: datetime + """ + + _validation = { + 'id': {'readonly': True}, + 'name': {'readonly': True}, + 'type': {'readonly': True}, + 'subject': {'required': True}, + 'thumbprint': {'required': True}, + 'expiration_date': {'required': True}, + } + + _attribute_map = { + 'id': {'key': 'id', 'type': 'str'}, + 'name': {'key': 'name', 'type': 'str'}, + 'type': {'key': 'type', 'type': 'str'}, + 'subject': {'key': 'properties.subject', 'type': 'str'}, + 'thumbprint': {'key': 'properties.thumbprint', 'type': 'str'}, + 'expiration_date': {'key': 'properties.expirationDate', 'type': 'iso-8601'}, + } + + def __init__(self, **kwargs): + super(CertificateContract, self).__init__(**kwargs) + self.subject = kwargs.get('subject', None) + self.thumbprint = kwargs.get('thumbprint', None) + self.expiration_date = kwargs.get('expiration_date', None) + + +class CertificateCreateOrUpdateParameters(Model): + """Certificate create or update details. + + All required parameters must be populated in order to send to Azure. + + :param data: Required. Base 64 encoded certificate using the + application/x-pkcs12 representation. + :type data: str + :param password: Required. Password for the Certificate + :type password: str + """ + + _validation = { + 'data': {'required': True}, + 'password': {'required': True}, + } + + _attribute_map = { + 'data': {'key': 'properties.data', 'type': 'str'}, + 'password': {'key': 'properties.password', 'type': 'str'}, + } + + def __init__(self, **kwargs): + super(CertificateCreateOrUpdateParameters, self).__init__(**kwargs) + self.data = kwargs.get('data', None) + self.password = kwargs.get('password', None) + + +class CertificateInformation(Model): + """SSL certificate information. + + All required parameters must be populated in order to send to Azure. + + :param expiry: Required. Expiration date of the certificate. The date + conforms to the following format: `yyyy-MM-ddTHH:mm:ssZ` as specified by + the ISO 8601 standard. + :type expiry: datetime + :param thumbprint: Required. Thumbprint of the certificate. + :type thumbprint: str + :param subject: Required. Subject of the certificate. + :type subject: str + """ + + _validation = { + 'expiry': {'required': True}, + 'thumbprint': {'required': True}, + 'subject': {'required': True}, + } + + _attribute_map = { + 'expiry': {'key': 'expiry', 'type': 'iso-8601'}, + 'thumbprint': {'key': 'thumbprint', 'type': 'str'}, + 'subject': {'key': 'subject', 'type': 'str'}, + } + + def __init__(self, **kwargs): + super(CertificateInformation, self).__init__(**kwargs) + self.expiry = kwargs.get('expiry', None) + self.thumbprint = kwargs.get('thumbprint', None) + self.subject = kwargs.get('subject', None) + + +class ClientSecretContract(Model): + """Client or app secret used in IdentityProviders, Aad, OpenID or OAuth. + + :param client_secret: Client or app secret used in IdentityProviders, Aad, + OpenID or OAuth. + :type client_secret: str + """ + + _attribute_map = { + 'client_secret': {'key': 'clientSecret', 'type': 'str'}, + } + + def __init__(self, **kwargs): + super(ClientSecretContract, self).__init__(**kwargs) + self.client_secret = kwargs.get('client_secret', None) + + +class CloudError(Model): + """CloudError. + """ + + _attribute_map = { + } + + +class ConnectivityStatusContract(Model): + """Details about connectivity to a resource. + + All required parameters must be populated in order to send to Azure. + + :param name: Required. The hostname of the resource which the service + depends on. This can be the database, storage or any other azure resource + on which the service depends upon. + :type name: str + :param status: Required. Resource Connectivity Status Type identifier. + Possible values include: 'initializing', 'success', 'failure' + :type status: str or + ~azure.mgmt.apimanagement.models.ConnectivityStatusType + :param error: Error details of the connectivity to the resource. + :type error: str + :param last_updated: Required. The date when the resource connectivity + status was last updated. This status should be updated every 15 minutes. + If this status has not been updated, then it means that the service has + lost network connectivity to the resource, from inside the Virtual + Network.The date conforms to the following format: `yyyy-MM-ddTHH:mm:ssZ` + as specified by the ISO 8601 standard. + :type last_updated: datetime + :param last_status_change: Required. The date when the resource + connectivity status last Changed from success to failure or vice-versa. + The date conforms to the following format: `yyyy-MM-ddTHH:mm:ssZ` as + specified by the ISO 8601 standard. + :type last_status_change: datetime + """ + + _validation = { + 'name': {'required': True, 'min_length': 1}, + 'status': {'required': True}, + 'last_updated': {'required': True}, + 'last_status_change': {'required': True}, + } + + _attribute_map = { + 'name': {'key': 'name', 'type': 'str'}, + 'status': {'key': 'status', 'type': 'str'}, + 'error': {'key': 'error', 'type': 'str'}, + 'last_updated': {'key': 'lastUpdated', 'type': 'iso-8601'}, + 'last_status_change': {'key': 'lastStatusChange', 'type': 'iso-8601'}, + } + + def __init__(self, **kwargs): + super(ConnectivityStatusContract, self).__init__(**kwargs) + self.name = kwargs.get('name', None) + self.status = kwargs.get('status', None) + self.error = kwargs.get('error', None) + self.last_updated = kwargs.get('last_updated', None) + self.last_status_change = kwargs.get('last_status_change', None) + + +class DeployConfigurationParameters(Model): + """Deploy Tenant Configuration Contract. + + All required parameters must be populated in order to send to Azure. + + :param branch: Required. The name of the Git branch from which the + configuration is to be deployed to the configuration database. + :type branch: str + :param force: The value enforcing deleting subscriptions to products that + are deleted in this update. + :type force: bool + """ + + _validation = { + 'branch': {'required': True}, + } + + _attribute_map = { + 'branch': {'key': 'properties.branch', 'type': 'str'}, + 'force': {'key': 'properties.force', 'type': 'bool'}, + } + + def __init__(self, **kwargs): + super(DeployConfigurationParameters, self).__init__(**kwargs) + self.branch = kwargs.get('branch', None) + self.force = kwargs.get('force', None) + + +class DiagnosticContract(Resource): + """Diagnostic details. + + Variables are only populated by the server, and will be ignored when + sending a request. + + All required parameters must be populated in order to send to Azure. + + :ivar id: Resource ID. + :vartype id: str + :ivar name: Resource name. + :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/outgoing HTTP messages + to the Gateway. + :type frontend: + ~azure.mgmt.apimanagement.models.PipelineDiagnosticSettings + :param backend: Diagnostic settings for incoming/outgoing HTTP messages to + the Backend + :type backend: ~azure.mgmt.apimanagement.models.PipelineDiagnosticSettings + :param log_client_ip: Log the ClientIP. Default is false. + :type log_client_ip: bool + :param http_correlation_protocol: Sets correlation protocol to use for + Application Insights diagnostics. Possible values include: 'None', + 'Legacy', 'W3C' + :type http_correlation_protocol: str or + ~azure.mgmt.apimanagement.models.HttpCorrelationProtocol + :param verbosity: The verbosity level applied to traces emitted by trace + policies. Possible values include: 'verbose', 'information', 'error' + :type verbosity: str or ~azure.mgmt.apimanagement.models.Verbosity + """ + + _validation = { + 'id': {'readonly': True}, + 'name': {'readonly': True}, + 'type': {'readonly': True}, + 'logger_id': {'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'}, + 'log_client_ip': {'key': 'properties.logClientIp', 'type': 'bool'}, + 'http_correlation_protocol': {'key': 'properties.httpCorrelationProtocol', 'type': 'str'}, + 'verbosity': {'key': 'properties.verbosity', 'type': 'str'}, + } + + 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.log_client_ip = kwargs.get('log_client_ip', None) + self.http_correlation_protocol = kwargs.get('http_correlation_protocol', None) + self.verbosity = kwargs.get('verbosity', None) + + +class EmailTemplateContract(Resource): + """Email Template details. + + Variables are only populated by the server, and will be ignored when + sending a request. + + All required parameters must be populated in order to send to Azure. + + :ivar id: Resource ID. + :vartype id: str + :ivar name: Resource name. + :vartype name: str + :ivar type: Resource type for API Management resource. + :vartype type: str + :param subject: Required. Subject of the Template. + :type subject: str + :param body: Required. Email Template Body. This should be a valid + XDocument + :type body: str + :param title: Title of the Template. + :type title: str + :param description: Description of the Email Template. + :type description: str + :ivar is_default: Whether the template is the default template provided by + Api Management or has been edited. + :vartype is_default: bool + :param parameters: Email Template Parameter values. + :type parameters: + list[~azure.mgmt.apimanagement.models.EmailTemplateParametersContractProperties] + """ + + _validation = { + 'id': {'readonly': True}, + 'name': {'readonly': True}, + 'type': {'readonly': True}, + 'subject': {'required': True, 'max_length': 1000, 'min_length': 1}, + 'body': {'required': True, 'min_length': 1}, + 'is_default': {'readonly': True}, + } + + _attribute_map = { + 'id': {'key': 'id', 'type': 'str'}, + 'name': {'key': 'name', 'type': 'str'}, + 'type': {'key': 'type', 'type': 'str'}, + 'subject': {'key': 'properties.subject', 'type': 'str'}, + 'body': {'key': 'properties.body', 'type': 'str'}, + 'title': {'key': 'properties.title', 'type': 'str'}, + 'description': {'key': 'properties.description', 'type': 'str'}, + 'is_default': {'key': 'properties.isDefault', 'type': 'bool'}, + 'parameters': {'key': 'properties.parameters', 'type': '[EmailTemplateParametersContractProperties]'}, + } + + def __init__(self, **kwargs): + super(EmailTemplateContract, self).__init__(**kwargs) + self.subject = kwargs.get('subject', None) + self.body = kwargs.get('body', None) + self.title = kwargs.get('title', None) + self.description = kwargs.get('description', None) + self.is_default = None + self.parameters = kwargs.get('parameters', None) + + +class EmailTemplateParametersContractProperties(Model): + """Email Template Parameter contract. + + :param name: Template parameter name. + :type name: str + :param title: Template parameter title. + :type title: str + :param description: Template parameter description. + :type description: str + """ + + _validation = { + 'name': {'max_length': 256, 'min_length': 1, 'pattern': r'^[A-Za-z0-9-._]+$'}, + 'title': {'max_length': 4096, 'min_length': 1}, + 'description': {'max_length': 256, 'min_length': 1, 'pattern': r'^[A-Za-z0-9-._]+$'}, + } + + _attribute_map = { + 'name': {'key': 'name', 'type': 'str'}, + 'title': {'key': 'title', 'type': 'str'}, + 'description': {'key': 'description', 'type': 'str'}, + } + + def __init__(self, **kwargs): + super(EmailTemplateParametersContractProperties, self).__init__(**kwargs) + self.name = kwargs.get('name', None) + self.title = kwargs.get('title', None) + self.description = kwargs.get('description', None) + + +class EmailTemplateUpdateParameters(Model): + """Email Template update Parameters. + + :param subject: Subject of the Template. + :type subject: str + :param title: Title of the Template. + :type title: str + :param description: Description of the Email Template. + :type description: str + :param body: Email Template Body. This should be a valid XDocument + :type body: str + :param parameters: Email Template Parameter values. + :type parameters: + list[~azure.mgmt.apimanagement.models.EmailTemplateParametersContractProperties] + """ + + _validation = { + 'subject': {'max_length': 1000, 'min_length': 1}, + 'body': {'min_length': 1}, + } + + _attribute_map = { + 'subject': {'key': 'properties.subject', 'type': 'str'}, + 'title': {'key': 'properties.title', 'type': 'str'}, + 'description': {'key': 'properties.description', 'type': 'str'}, + 'body': {'key': 'properties.body', 'type': 'str'}, + 'parameters': {'key': 'properties.parameters', 'type': '[EmailTemplateParametersContractProperties]'}, + } + + def __init__(self, **kwargs): + super(EmailTemplateUpdateParameters, self).__init__(**kwargs) + self.subject = kwargs.get('subject', None) + self.title = kwargs.get('title', None) + self.description = kwargs.get('description', None) + self.body = kwargs.get('body', None) + self.parameters = kwargs.get('parameters', None) + + +class ErrorFieldContract(Model): + """Error Field contract. + + :param code: Property level error code. + :type code: str + :param message: Human-readable representation of property-level error. + :type message: str + :param target: Property name. + :type target: str + """ + + _attribute_map = { + 'code': {'key': 'code', 'type': 'str'}, + 'message': {'key': 'message', 'type': 'str'}, + 'target': {'key': 'target', 'type': 'str'}, + } + + def __init__(self, **kwargs): + super(ErrorFieldContract, self).__init__(**kwargs) + self.code = kwargs.get('code', None) + self.message = kwargs.get('message', None) + self.target = kwargs.get('target', None) + + +class ErrorResponse(Model): + """Error Response. + + :param code: Service-defined error code. This code serves as a sub-status + for the HTTP error code specified in the response. + :type code: str + :param message: Human-readable representation of the error. + :type message: str + :param details: The list of invalid fields send in request, in case of + validation error. + :type details: list[~azure.mgmt.apimanagement.models.ErrorFieldContract] + """ + + _attribute_map = { + 'code': {'key': 'error.code', 'type': 'str'}, + 'message': {'key': 'error.message', 'type': 'str'}, + 'details': {'key': 'error.details', 'type': '[ErrorFieldContract]'}, + } + + def __init__(self, **kwargs): + super(ErrorResponse, self).__init__(**kwargs) + self.code = kwargs.get('code', None) + self.message = kwargs.get('message', None) + self.details = kwargs.get('details', None) + + +class ErrorResponseException(HttpOperationError): + """Server responsed with exception of type: 'ErrorResponse'. + + :param deserialize: A deserializer + :param response: Server response to be deserialized. + """ + + def __init__(self, deserialize, response, *args): + + super(ErrorResponseException, self).__init__(deserialize, response, 'ErrorResponse', *args) + + +class ErrorResponseBody(Model): + """Error Body contract. + + :param code: Service-defined error code. This code serves as a sub-status + for the HTTP error code specified in the response. + :type code: str + :param message: Human-readable representation of the error. + :type message: str + :param details: The list of invalid fields send in request, in case of + validation error. + :type details: list[~azure.mgmt.apimanagement.models.ErrorFieldContract] + """ + + _attribute_map = { + 'code': {'key': 'code', 'type': 'str'}, + 'message': {'key': 'message', 'type': 'str'}, + 'details': {'key': 'details', 'type': '[ErrorFieldContract]'}, + } + + def __init__(self, **kwargs): + super(ErrorResponseBody, self).__init__(**kwargs) + self.code = kwargs.get('code', None) + self.message = kwargs.get('message', None) + self.details = kwargs.get('details', None) + + +class GenerateSsoUrlResult(Model): + """Generate SSO Url operations response details. + + :param value: Redirect Url containing the SSO URL value. + :type value: str + """ + + _attribute_map = { + 'value': {'key': 'value', 'type': 'str'}, + } + + def __init__(self, **kwargs): + super(GenerateSsoUrlResult, self).__init__(**kwargs) + self.value = kwargs.get('value', None) + + +class GroupContract(Resource): + """Contract details. + + Variables are only populated by the server, and will be ignored when + sending a request. + + All required parameters must be populated in order to send to Azure. + + :ivar id: Resource ID. + :vartype id: str + :ivar name: Resource name. + :vartype name: str + :ivar type: Resource type for API Management resource. + :vartype type: str + :param display_name: Required. Group name. + :type display_name: str + :param description: Group description. Can contain HTML formatting tags. + :type description: str + :ivar built_in: true if the group is one of the three system groups + (Administrators, Developers, or Guests); otherwise false. + :vartype built_in: bool + :param group_contract_type: Group type. Possible values include: 'custom', + 'system', 'external' + :type group_contract_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/`; + otherwise the value is null. + :type external_id: str + """ + + _validation = { + 'id': {'readonly': True}, + 'name': {'readonly': True}, + 'type': {'readonly': True}, + 'display_name': {'required': True, 'max_length': 300, 'min_length': 1}, + 'description': {'max_length': 1000}, + 'built_in': {'readonly': True}, + } + + _attribute_map = { + 'id': {'key': 'id', 'type': 'str'}, + 'name': {'key': 'name', 'type': 'str'}, + 'type': {'key': 'type', 'type': 'str'}, + 'display_name': {'key': 'properties.displayName', 'type': 'str'}, + 'description': {'key': 'properties.description', 'type': 'str'}, + 'built_in': {'key': 'properties.builtIn', 'type': 'bool'}, + 'group_contract_type': {'key': 'properties.type', 'type': 'GroupType'}, + 'external_id': {'key': 'properties.externalId', 'type': 'str'}, + } + + def __init__(self, **kwargs): + super(GroupContract, self).__init__(**kwargs) + self.display_name = kwargs.get('display_name', None) + self.description = kwargs.get('description', None) + self.built_in = None + self.group_contract_type = kwargs.get('group_contract_type', None) + self.external_id = kwargs.get('external_id', None) + + +class GroupContractProperties(Model): + """Group contract Properties. + + Variables are only populated by the server, and will be ignored when + sending a request. + + All required parameters must be populated in order to send to Azure. + + :param display_name: Required. Group name. + :type display_name: str + :param description: Group description. Can contain HTML formatting tags. + :type description: str + :ivar built_in: true if the group is one of the three system groups + (Administrators, Developers, or Guests); otherwise false. + :vartype built_in: bool + :param type: Group type. Possible values include: 'custom', 'system', + 'external' + :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/`; + otherwise the value is null. + :type external_id: str + """ + + _validation = { + 'display_name': {'required': True, 'max_length': 300, 'min_length': 1}, + 'description': {'max_length': 1000}, + 'built_in': {'readonly': True}, + } + + _attribute_map = { + 'display_name': {'key': 'displayName', 'type': 'str'}, + 'description': {'key': 'description', 'type': 'str'}, + 'built_in': {'key': 'builtIn', 'type': 'bool'}, + 'type': {'key': 'type', 'type': 'GroupType'}, + 'external_id': {'key': 'externalId', 'type': 'str'}, + } + + def __init__(self, **kwargs): + super(GroupContractProperties, self).__init__(**kwargs) + self.display_name = kwargs.get('display_name', None) + self.description = kwargs.get('description', None) + self.built_in = None + self.type = kwargs.get('type', None) + self.external_id = kwargs.get('external_id', None) + + +class GroupCreateParameters(Model): + """Parameters supplied to the Create Group operation. + + All required parameters must be populated in order to send to Azure. + + :param display_name: Required. Group name. + :type display_name: str + :param description: Group description. + :type description: str + :param type: Group type. Possible values include: 'custom', 'system', + 'external' + :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. + :type external_id: str + """ + + _validation = { + 'display_name': {'required': True, 'max_length': 300, 'min_length': 1}, + } + + _attribute_map = { + 'display_name': {'key': 'properties.displayName', 'type': 'str'}, + 'description': {'key': 'properties.description', 'type': 'str'}, + 'type': {'key': 'properties.type', 'type': 'GroupType'}, + 'external_id': {'key': 'properties.externalId', 'type': 'str'}, + } + + def __init__(self, **kwargs): + super(GroupCreateParameters, self).__init__(**kwargs) + self.display_name = kwargs.get('display_name', None) + self.description = kwargs.get('description', None) + self.type = kwargs.get('type', None) + self.external_id = kwargs.get('external_id', None) + + +class GroupUpdateParameters(Model): + """Parameters supplied to the Update Group operation. + + :param display_name: Group name. + :type display_name: str + :param description: Group description. + :type description: str + :param type: Group type. Possible values include: 'custom', 'system', + 'external' + :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. + :type external_id: str + """ + + _validation = { + 'display_name': {'max_length': 300, 'min_length': 1}, + } + + _attribute_map = { + 'display_name': {'key': 'properties.displayName', 'type': 'str'}, + 'description': {'key': 'properties.description', 'type': 'str'}, + 'type': {'key': 'properties.type', 'type': 'GroupType'}, + 'external_id': {'key': 'properties.externalId', 'type': 'str'}, + } + + def __init__(self, **kwargs): + super(GroupUpdateParameters, self).__init__(**kwargs) + self.display_name = kwargs.get('display_name', None) + self.description = kwargs.get('description', None) + self.type = kwargs.get('type', None) + self.external_id = kwargs.get('external_id', None) + + +class HostnameConfiguration(Model): + """Custom hostname configuration. + + All required parameters must be populated in order to send to Azure. + + :param type: Required. Hostname type. Possible values include: 'Proxy', + 'Portal', 'Management', 'Scm', 'DeveloperPortal' + :type type: str or ~azure.mgmt.apimanagement.models.HostnameType + :param host_name: Required. Hostname to configure on the Api Management + service. + :type host_name: str + :param key_vault_id: Url to the KeyVault Secret containing the Ssl + Certificate. If absolute Url containing version is provided, auto-update + of ssl certificate will not work. This requires Api Management service to + be configured with MSI. The secret should be of type + *application/x-pkcs12* + :type key_vault_id: str + :param encoded_certificate: Base64 Encoded certificate. + :type encoded_certificate: str + :param certificate_password: Certificate Password. + :type certificate_password: str + :param default_ssl_binding: Specify true to setup the certificate + associated with this Hostname as the Default SSL Certificate. If a client + does not send the SNI header, then this will be the certificate that will + be challenged. The property is useful if a service has multiple custom + hostname enabled and it needs to decide on the default ssl certificate. + The setting only applied to Proxy Hostname Type. Default value: False . + :type default_ssl_binding: bool + :param negotiate_client_certificate: Specify true to always negotiate + client certificate on the hostname. Default Value is false. Default value: + False . + :type negotiate_client_certificate: bool + :param certificate: Certificate information. + :type certificate: ~azure.mgmt.apimanagement.models.CertificateInformation + """ + + _validation = { + 'type': {'required': True}, + 'host_name': {'required': True}, + } + + _attribute_map = { + 'type': {'key': 'type', 'type': 'str'}, + 'host_name': {'key': 'hostName', 'type': 'str'}, + 'key_vault_id': {'key': 'keyVaultId', 'type': 'str'}, + 'encoded_certificate': {'key': 'encodedCertificate', 'type': 'str'}, + 'certificate_password': {'key': 'certificatePassword', 'type': 'str'}, + 'default_ssl_binding': {'key': 'defaultSslBinding', 'type': 'bool'}, + 'negotiate_client_certificate': {'key': 'negotiateClientCertificate', 'type': 'bool'}, + 'certificate': {'key': 'certificate', 'type': 'CertificateInformation'}, + } + + def __init__(self, **kwargs): + super(HostnameConfiguration, self).__init__(**kwargs) + self.type = kwargs.get('type', None) + self.host_name = kwargs.get('host_name', None) + self.key_vault_id = kwargs.get('key_vault_id', None) + self.encoded_certificate = kwargs.get('encoded_certificate', None) + self.certificate_password = kwargs.get('certificate_password', None) + self.default_ssl_binding = kwargs.get('default_ssl_binding', False) + self.negotiate_client_certificate = kwargs.get('negotiate_client_certificate', False) + self.certificate = kwargs.get('certificate', None) + + +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) + + +class IdentityProviderBaseParameters(Model): + """Identity Provider Base Parameter Properties. + + :param type: Identity Provider Type identifier. Possible values include: + 'facebook', 'google', 'microsoft', 'twitter', 'aad', 'aadB2C' + :type type: str or ~azure.mgmt.apimanagement.models.IdentityProviderType + :param signin_tenant: The TenantId to use instead of Common when logging + into Active Directory + :type signin_tenant: str + :param allowed_tenants: List of Allowed Tenants when configuring Azure + Active Directory login. + :type allowed_tenants: list[str] + :param authority: OpenID Connect discovery endpoint hostname for AAD or + AAD B2C. + :type authority: str + :param signup_policy_name: Signup Policy Name. Only applies to AAD B2C + Identity Provider. + :type signup_policy_name: str + :param signin_policy_name: Signin Policy Name. Only applies to AAD B2C + Identity Provider. + :type signin_policy_name: str + :param profile_editing_policy_name: Profile Editing Policy Name. Only + applies to AAD B2C Identity Provider. + :type profile_editing_policy_name: str + :param password_reset_policy_name: Password Reset Policy Name. Only + applies to AAD B2C Identity Provider. + :type password_reset_policy_name: str + """ + + _validation = { + 'allowed_tenants': {'max_items': 32}, + 'signup_policy_name': {'min_length': 1}, + 'signin_policy_name': {'min_length': 1}, + 'profile_editing_policy_name': {'min_length': 1}, + 'password_reset_policy_name': {'min_length': 1}, + } + + _attribute_map = { + 'type': {'key': 'type', 'type': 'str'}, + 'signin_tenant': {'key': 'signinTenant', 'type': 'str'}, + 'allowed_tenants': {'key': 'allowedTenants', 'type': '[str]'}, + 'authority': {'key': 'authority', 'type': 'str'}, + 'signup_policy_name': {'key': 'signupPolicyName', 'type': 'str'}, + 'signin_policy_name': {'key': 'signinPolicyName', 'type': 'str'}, + 'profile_editing_policy_name': {'key': 'profileEditingPolicyName', 'type': 'str'}, + 'password_reset_policy_name': {'key': 'passwordResetPolicyName', 'type': 'str'}, + } + + def __init__(self, **kwargs): + super(IdentityProviderBaseParameters, self).__init__(**kwargs) + self.type = kwargs.get('type', None) + self.signin_tenant = kwargs.get('signin_tenant', None) + self.allowed_tenants = kwargs.get('allowed_tenants', None) + self.authority = kwargs.get('authority', None) + self.signup_policy_name = kwargs.get('signup_policy_name', None) + self.signin_policy_name = kwargs.get('signin_policy_name', None) + self.profile_editing_policy_name = kwargs.get('profile_editing_policy_name', None) + self.password_reset_policy_name = kwargs.get('password_reset_policy_name', None) + + +class IdentityProviderContract(Resource): + """Identity Provider details. + + Variables are only populated by the server, and will be ignored when + sending a request. + + All required parameters must be populated in order to send to Azure. + + :ivar id: Resource ID. + :vartype id: str + :ivar name: Resource name. + :vartype name: str + :ivar type: Resource type for API Management resource. + :vartype type: str + :param identity_provider_contract_type: Identity Provider Type identifier. + Possible values include: 'facebook', 'google', 'microsoft', 'twitter', + 'aad', 'aadB2C' + :type identity_provider_contract_type: str or + ~azure.mgmt.apimanagement.models.IdentityProviderType + :param signin_tenant: The TenantId to use instead of Common when logging + into Active Directory + :type signin_tenant: str + :param allowed_tenants: List of Allowed Tenants when configuring Azure + Active Directory login. + :type allowed_tenants: list[str] + :param authority: OpenID Connect discovery endpoint hostname for AAD or + AAD B2C. + :type authority: str + :param signup_policy_name: Signup Policy Name. Only applies to AAD B2C + Identity Provider. + :type signup_policy_name: str + :param signin_policy_name: Signin Policy Name. Only applies to AAD B2C + Identity Provider. + :type signin_policy_name: str + :param profile_editing_policy_name: Profile Editing Policy Name. Only + applies to AAD B2C Identity Provider. + :type profile_editing_policy_name: str + :param password_reset_policy_name: Password Reset Policy Name. Only + applies to AAD B2C Identity Provider. + :type password_reset_policy_name: str + :param client_id: Required. Client Id of the Application in the external + Identity Provider. It is App ID for Facebook login, Client ID for Google + login, App ID for Microsoft. + :type client_id: str + :param client_secret: Client secret of the Application in external + Identity Provider, used to authenticate login request. For example, it is + App Secret for Facebook login, API Key for Google login, Public Key for + Microsoft. This property will not be filled on 'GET' operations! Use + '/listSecrets' POST request to get the value. + :type client_secret: str + """ + + _validation = { + 'id': {'readonly': True}, + 'name': {'readonly': True}, + 'type': {'readonly': True}, + 'allowed_tenants': {'max_items': 32}, + 'signup_policy_name': {'min_length': 1}, + 'signin_policy_name': {'min_length': 1}, + 'profile_editing_policy_name': {'min_length': 1}, + 'password_reset_policy_name': {'min_length': 1}, + 'client_id': {'required': True, 'min_length': 1}, + 'client_secret': {'min_length': 1}, + } + + _attribute_map = { + 'id': {'key': 'id', 'type': 'str'}, + 'name': {'key': 'name', 'type': 'str'}, + 'type': {'key': 'type', 'type': 'str'}, + 'identity_provider_contract_type': {'key': 'properties.type', 'type': 'str'}, + 'signin_tenant': {'key': 'properties.signinTenant', 'type': 'str'}, + 'allowed_tenants': {'key': 'properties.allowedTenants', 'type': '[str]'}, + 'authority': {'key': 'properties.authority', 'type': 'str'}, + 'signup_policy_name': {'key': 'properties.signupPolicyName', 'type': 'str'}, + 'signin_policy_name': {'key': 'properties.signinPolicyName', 'type': 'str'}, + 'profile_editing_policy_name': {'key': 'properties.profileEditingPolicyName', 'type': 'str'}, + 'password_reset_policy_name': {'key': 'properties.passwordResetPolicyName', 'type': 'str'}, + 'client_id': {'key': 'properties.clientId', 'type': 'str'}, + 'client_secret': {'key': 'properties.clientSecret', 'type': 'str'}, + } + + def __init__(self, **kwargs): + super(IdentityProviderContract, self).__init__(**kwargs) + self.identity_provider_contract_type = kwargs.get('identity_provider_contract_type', None) + self.signin_tenant = kwargs.get('signin_tenant', None) + self.allowed_tenants = kwargs.get('allowed_tenants', None) + self.authority = kwargs.get('authority', None) + self.signup_policy_name = kwargs.get('signup_policy_name', None) + self.signin_policy_name = kwargs.get('signin_policy_name', None) + self.profile_editing_policy_name = kwargs.get('profile_editing_policy_name', None) + self.password_reset_policy_name = kwargs.get('password_reset_policy_name', None) + self.client_id = kwargs.get('client_id', None) + self.client_secret = kwargs.get('client_secret', None) + + +class IdentityProviderCreateContract(Resource): + """Identity Provider details. + + Variables are only populated by the server, and will be ignored when + sending a request. + + All required parameters must be populated in order to send to Azure. + + :ivar id: Resource ID. + :vartype id: str + :ivar name: Resource name. + :vartype name: str + :ivar type: Resource type for API Management resource. + :vartype type: str + :param identity_provider_create_contract_type: Identity Provider Type + identifier. Possible values include: 'facebook', 'google', 'microsoft', + 'twitter', 'aad', 'aadB2C' + :type identity_provider_create_contract_type: str or + ~azure.mgmt.apimanagement.models.IdentityProviderType + :param signin_tenant: The TenantId to use instead of Common when logging + into Active Directory + :type signin_tenant: str + :param allowed_tenants: List of Allowed Tenants when configuring Azure + Active Directory login. + :type allowed_tenants: list[str] + :param authority: OpenID Connect discovery endpoint hostname for AAD or + AAD B2C. + :type authority: str + :param signup_policy_name: Signup Policy Name. Only applies to AAD B2C + Identity Provider. + :type signup_policy_name: str + :param signin_policy_name: Signin Policy Name. Only applies to AAD B2C + Identity Provider. + :type signin_policy_name: str + :param profile_editing_policy_name: Profile Editing Policy Name. Only + applies to AAD B2C Identity Provider. + :type profile_editing_policy_name: str + :param password_reset_policy_name: Password Reset Policy Name. Only + applies to AAD B2C Identity Provider. + :type password_reset_policy_name: str + :param client_id: Required. Client Id of the Application in the external + Identity Provider. It is App ID for Facebook login, Client ID for Google + login, App ID for Microsoft. + :type client_id: str + :param client_secret: Required. Client secret of the Application in + external Identity Provider, used to authenticate login request. For + example, it is App Secret for Facebook login, API Key for Google login, + Public Key for Microsoft. This property will not be filled on 'GET' + operations! Use '/listSecrets' POST request to get the value. + :type client_secret: str + """ + + _validation = { + 'id': {'readonly': True}, + 'name': {'readonly': True}, + 'type': {'readonly': True}, + 'allowed_tenants': {'max_items': 32}, + 'signup_policy_name': {'min_length': 1}, + 'signin_policy_name': {'min_length': 1}, + 'profile_editing_policy_name': {'min_length': 1}, + 'password_reset_policy_name': {'min_length': 1}, + 'client_id': {'required': True, 'min_length': 1}, + 'client_secret': {'required': True, 'min_length': 1}, + } + + _attribute_map = { + 'id': {'key': 'id', 'type': 'str'}, + 'name': {'key': 'name', 'type': 'str'}, + 'type': {'key': 'type', 'type': 'str'}, + 'identity_provider_create_contract_type': {'key': 'properties.type', 'type': 'str'}, + 'signin_tenant': {'key': 'properties.signinTenant', 'type': 'str'}, + 'allowed_tenants': {'key': 'properties.allowedTenants', 'type': '[str]'}, + 'authority': {'key': 'properties.authority', 'type': 'str'}, + 'signup_policy_name': {'key': 'properties.signupPolicyName', 'type': 'str'}, + 'signin_policy_name': {'key': 'properties.signinPolicyName', 'type': 'str'}, + 'profile_editing_policy_name': {'key': 'properties.profileEditingPolicyName', 'type': 'str'}, + 'password_reset_policy_name': {'key': 'properties.passwordResetPolicyName', 'type': 'str'}, + 'client_id': {'key': 'properties.clientId', 'type': 'str'}, + 'client_secret': {'key': 'properties.clientSecret', 'type': 'str'}, + } + + def __init__(self, **kwargs): + super(IdentityProviderCreateContract, self).__init__(**kwargs) + self.identity_provider_create_contract_type = kwargs.get('identity_provider_create_contract_type', None) + self.signin_tenant = kwargs.get('signin_tenant', None) + self.allowed_tenants = kwargs.get('allowed_tenants', None) + self.authority = kwargs.get('authority', None) + self.signup_policy_name = kwargs.get('signup_policy_name', None) + self.signin_policy_name = kwargs.get('signin_policy_name', None) + self.profile_editing_policy_name = kwargs.get('profile_editing_policy_name', None) + self.password_reset_policy_name = kwargs.get('password_reset_policy_name', None) + self.client_id = kwargs.get('client_id', None) + self.client_secret = kwargs.get('client_secret', None) + + +class IdentityProviderUpdateParameters(Model): + """Parameters supplied to update Identity Provider. + + :param type: Identity Provider Type identifier. Possible values include: + 'facebook', 'google', 'microsoft', 'twitter', 'aad', 'aadB2C' + :type type: str or ~azure.mgmt.apimanagement.models.IdentityProviderType + :param signin_tenant: The TenantId to use instead of Common when logging + into Active Directory + :type signin_tenant: str + :param allowed_tenants: List of Allowed Tenants when configuring Azure + Active Directory login. + :type allowed_tenants: list[str] + :param authority: OpenID Connect discovery endpoint hostname for AAD or + AAD B2C. + :type authority: str + :param signup_policy_name: Signup Policy Name. Only applies to AAD B2C + Identity Provider. + :type signup_policy_name: str + :param signin_policy_name: Signin Policy Name. Only applies to AAD B2C + Identity Provider. + :type signin_policy_name: str + :param profile_editing_policy_name: Profile Editing Policy Name. Only + applies to AAD B2C Identity Provider. + :type profile_editing_policy_name: str + :param password_reset_policy_name: Password Reset Policy Name. Only + applies to AAD B2C Identity Provider. + :type password_reset_policy_name: str + :param client_id: Client Id of the Application in the external Identity + Provider. It is App ID for Facebook login, Client ID for Google login, App + ID for Microsoft. + :type client_id: str + :param client_secret: Client secret of the Application in external + Identity Provider, used to authenticate login request. For example, it is + App Secret for Facebook login, API Key for Google login, Public Key for + Microsoft. + :type client_secret: str + """ + + _validation = { + 'allowed_tenants': {'max_items': 32}, + 'signup_policy_name': {'min_length': 1}, + 'signin_policy_name': {'min_length': 1}, + 'profile_editing_policy_name': {'min_length': 1}, + 'password_reset_policy_name': {'min_length': 1}, + 'client_id': {'min_length': 1}, + 'client_secret': {'min_length': 1}, + } + + _attribute_map = { + 'type': {'key': 'properties.type', 'type': 'str'}, + 'signin_tenant': {'key': 'properties.signinTenant', 'type': 'str'}, + 'allowed_tenants': {'key': 'properties.allowedTenants', 'type': '[str]'}, + 'authority': {'key': 'properties.authority', 'type': 'str'}, + 'signup_policy_name': {'key': 'properties.signupPolicyName', 'type': 'str'}, + 'signin_policy_name': {'key': 'properties.signinPolicyName', 'type': 'str'}, + 'profile_editing_policy_name': {'key': 'properties.profileEditingPolicyName', 'type': 'str'}, + 'password_reset_policy_name': {'key': 'properties.passwordResetPolicyName', 'type': 'str'}, + 'client_id': {'key': 'properties.clientId', 'type': 'str'}, + 'client_secret': {'key': 'properties.clientSecret', 'type': 'str'}, + } + + def __init__(self, **kwargs): + super(IdentityProviderUpdateParameters, self).__init__(**kwargs) + self.type = kwargs.get('type', None) + self.signin_tenant = kwargs.get('signin_tenant', None) + self.allowed_tenants = kwargs.get('allowed_tenants', None) + self.authority = kwargs.get('authority', None) + self.signup_policy_name = kwargs.get('signup_policy_name', None) + self.signin_policy_name = kwargs.get('signin_policy_name', None) + self.profile_editing_policy_name = kwargs.get('profile_editing_policy_name', None) + self.password_reset_policy_name = kwargs.get('password_reset_policy_name', None) + self.client_id = kwargs.get('client_id', None) + self.client_secret = kwargs.get('client_secret', None) + + +class IssueAttachmentContract(Resource): + """Issue Attachment Contract details. + + Variables are only populated by the server, and will be ignored when + sending a request. + + All required parameters must be populated in order to send to Azure. + + :ivar id: Resource ID. + :vartype id: str + :ivar name: Resource name. + :vartype name: str + :ivar type: Resource type for API Management resource. + :vartype type: str + :param title: Required. Filename by which the binary data will be saved. + :type title: str + :param content_format: Required. Either 'link' if content is provided via + an HTTP link or the MIME type of the Base64-encoded binary data provided + in the 'content' property. + :type content_format: str + :param content: Required. An HTTP link or Base64-encoded binary data. + :type content: str + """ + + _validation = { + 'id': {'readonly': True}, + 'name': {'readonly': True}, + 'type': {'readonly': True}, + 'title': {'required': True}, + 'content_format': {'required': True}, + 'content': {'required': True}, + } + + _attribute_map = { + 'id': {'key': 'id', 'type': 'str'}, + 'name': {'key': 'name', 'type': 'str'}, + 'type': {'key': 'type', 'type': 'str'}, + 'title': {'key': 'properties.title', 'type': 'str'}, + 'content_format': {'key': 'properties.contentFormat', 'type': 'str'}, + 'content': {'key': 'properties.content', 'type': 'str'}, + } + + def __init__(self, **kwargs): + super(IssueAttachmentContract, self).__init__(**kwargs) + self.title = kwargs.get('title', None) + self.content_format = kwargs.get('content_format', None) + self.content = kwargs.get('content', None) + + +class IssueCommentContract(Resource): + """Issue Comment Contract details. + + Variables are only populated by the server, and will be ignored when + sending a request. + + All required parameters must be populated in order to send to Azure. + + :ivar id: Resource ID. + :vartype id: str + :ivar name: Resource name. + :vartype name: str + :ivar type: Resource type for API Management resource. + :vartype type: str + :param text: Required. Comment text. + :type text: str + :param created_date: Date and time when the comment was created. + :type created_date: datetime + :param user_id: Required. A resource identifier for the user who left the + comment. + :type user_id: str + """ + + _validation = { + 'id': {'readonly': True}, + 'name': {'readonly': True}, + 'type': {'readonly': True}, + 'text': {'required': True}, + 'user_id': {'required': True}, + } + + _attribute_map = { + 'id': {'key': 'id', 'type': 'str'}, + 'name': {'key': 'name', 'type': 'str'}, + 'type': {'key': 'type', 'type': 'str'}, + 'text': {'key': 'properties.text', 'type': 'str'}, + 'created_date': {'key': 'properties.createdDate', 'type': 'iso-8601'}, + 'user_id': {'key': 'properties.userId', 'type': 'str'}, + } + + def __init__(self, **kwargs): + super(IssueCommentContract, self).__init__(**kwargs) + self.text = kwargs.get('text', None) + self.created_date = kwargs.get('created_date', None) + self.user_id = kwargs.get('user_id', None) + + +class IssueContract(Resource): + """Issue Contract details. + + Variables are only populated by the server, and will be ignored when + sending a request. + + All required parameters must be populated in order to send to Azure. + + :ivar id: Resource ID. + :vartype id: str + :ivar name: Resource name. + :vartype name: str + :ivar type: Resource type for API Management resource. + :vartype type: str + :param created_date: Date and time when the issue was created. + :type created_date: datetime + :param state: Status of the issue. Possible values include: 'proposed', + 'open', 'removed', 'resolved', 'closed' + :type state: str or ~azure.mgmt.apimanagement.models.State + :param api_id: A resource identifier for the API the issue was created + for. + :type api_id: str + :param title: Required. The issue title. + :type title: str + :param description: Required. Text describing the issue. + :type description: str + :param user_id: Required. A resource identifier for the user created the + issue. + :type user_id: str + """ + + _validation = { + 'id': {'readonly': True}, + 'name': {'readonly': True}, + 'type': {'readonly': True}, + 'title': {'required': True}, + 'description': {'required': True}, + 'user_id': {'required': True}, + } + + _attribute_map = { + 'id': {'key': 'id', 'type': 'str'}, + 'name': {'key': 'name', 'type': 'str'}, + 'type': {'key': 'type', 'type': 'str'}, + 'created_date': {'key': 'properties.createdDate', 'type': 'iso-8601'}, + 'state': {'key': 'properties.state', 'type': 'str'}, + 'api_id': {'key': 'properties.apiId', 'type': 'str'}, + 'title': {'key': 'properties.title', 'type': 'str'}, + 'description': {'key': 'properties.description', 'type': 'str'}, + 'user_id': {'key': 'properties.userId', 'type': 'str'}, + } + + def __init__(self, **kwargs): + super(IssueContract, self).__init__(**kwargs) + self.created_date = kwargs.get('created_date', None) + self.state = kwargs.get('state', None) + self.api_id = kwargs.get('api_id', None) + self.title = kwargs.get('title', None) + self.description = kwargs.get('description', None) + self.user_id = kwargs.get('user_id', None) + + +class IssueContractBaseProperties(Model): + """Issue contract Base Properties. + + :param created_date: Date and time when the issue was created. + :type created_date: datetime + :param state: Status of the issue. Possible values include: 'proposed', + 'open', 'removed', 'resolved', 'closed' + :type state: str or ~azure.mgmt.apimanagement.models.State + :param api_id: A resource identifier for the API the issue was created + for. + :type api_id: str + """ + + _attribute_map = { + 'created_date': {'key': 'createdDate', 'type': 'iso-8601'}, + 'state': {'key': 'state', 'type': 'str'}, + 'api_id': {'key': 'apiId', 'type': 'str'}, + } + + def __init__(self, **kwargs): + super(IssueContractBaseProperties, self).__init__(**kwargs) + self.created_date = kwargs.get('created_date', None) + self.state = kwargs.get('state', None) + self.api_id = kwargs.get('api_id', None) + + +class IssueUpdateContract(Model): + """Issue update Parameters. + + :param created_date: Date and time when the issue was created. + :type created_date: datetime + :param state: Status of the issue. Possible values include: 'proposed', + 'open', 'removed', 'resolved', 'closed' + :type state: str or ~azure.mgmt.apimanagement.models.State + :param api_id: A resource identifier for the API the issue was created + for. + :type api_id: str + :param title: The issue title. + :type title: str + :param description: Text describing the issue. + :type description: str + :param user_id: A resource identifier for the user created the issue. + :type user_id: str + """ + + _attribute_map = { + 'created_date': {'key': 'properties.createdDate', 'type': 'iso-8601'}, + 'state': {'key': 'properties.state', 'type': 'str'}, + 'api_id': {'key': 'properties.apiId', 'type': 'str'}, + 'title': {'key': 'properties.title', 'type': 'str'}, + 'description': {'key': 'properties.description', 'type': 'str'}, + 'user_id': {'key': 'properties.userId', 'type': 'str'}, + } + + def __init__(self, **kwargs): + super(IssueUpdateContract, self).__init__(**kwargs) + self.created_date = kwargs.get('created_date', None) + self.state = kwargs.get('state', None) + self.api_id = kwargs.get('api_id', None) + self.title = kwargs.get('title', None) + self.description = kwargs.get('description', None) + self.user_id = kwargs.get('user_id', None) + + +class LoggerContract(Resource): + """Logger details. + + Variables are only populated by the server, and will be ignored when + sending a request. + + All required parameters must be populated in order to send to Azure. + + :ivar id: Resource ID. + :vartype id: str + :ivar name: Resource name. + :vartype name: str + :ivar type: Resource type for API Management resource. + :vartype type: str + :param logger_type: Required. Logger type. Possible values include: + 'azureEventHub', 'applicationInsights' + :type logger_type: str or ~azure.mgmt.apimanagement.models.LoggerType + :param description: Logger description. + :type description: str + :param credentials: Required. The name and SendRule connection string of + the event hub for azureEventHub logger. + Instrumentation key for applicationInsights logger. + :type credentials: dict[str, str] + :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 = { + 'id': {'readonly': True}, + 'name': {'readonly': True}, + 'type': {'readonly': True}, + 'logger_type': {'required': True}, + 'description': {'max_length': 256}, + 'credentials': {'required': True}, + } + + _attribute_map = { + 'id': {'key': 'id', 'type': 'str'}, + 'name': {'key': 'name', 'type': 'str'}, + 'type': {'key': 'type', 'type': 'str'}, + 'logger_type': {'key': 'properties.loggerType', 'type': 'str'}, + '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): + super(LoggerContract, self).__init__(**kwargs) + self.logger_type = kwargs.get('logger_type', None) + 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) + + +class LoggerUpdateContract(Model): + """Logger update contract. + + :param logger_type: Logger type. Possible values include: 'azureEventHub', + 'applicationInsights' + :type logger_type: str or ~azure.mgmt.apimanagement.models.LoggerType + :param description: Logger description. + :type description: str + :param credentials: Logger credentials. + :type credentials: dict[str, str] + :param is_buffered: Whether records are buffered in the logger before + publishing. Default is assumed to be true. + :type is_buffered: bool + """ + + _attribute_map = { + 'logger_type': {'key': 'properties.loggerType', 'type': 'str'}, + 'description': {'key': 'properties.description', 'type': 'str'}, + 'credentials': {'key': 'properties.credentials', 'type': '{str}'}, + 'is_buffered': {'key': 'properties.isBuffered', 'type': 'bool'}, + } + + def __init__(self, **kwargs): + super(LoggerUpdateContract, self).__init__(**kwargs) + self.logger_type = kwargs.get('logger_type', None) + self.description = kwargs.get('description', None) + self.credentials = kwargs.get('credentials', None) + self.is_buffered = kwargs.get('is_buffered', None) + + +class NamedValueContract(Resource): + """NamedValue details. + + Variables are only populated by the server, and will be ignored when + sending a request. + + All required parameters must be populated in order to send to Azure. + + :ivar id: Resource ID. + :vartype id: str + :ivar name: Resource name. + :vartype name: str + :ivar type: Resource type for API Management resource. + :vartype type: str + :param tags: Optional tags that when provided can be used to filter the + NamedValue list. + :type tags: list[str] + :param secret: Determines whether the value is a secret and should be + encrypted or not. Default value is false. + :type secret: bool + :param display_name: Required. Unique name of NamedValue. It may contain + only letters, digits, period, dash, and underscore characters. + :type display_name: str + :param value: Value of the NamedValue. Can contain policy expressions. It + may not be empty or consist only of whitespace. This property will not be + filled on 'GET' operations! Use '/listSecrets' POST request to get the + value. + :type value: str + """ + + _validation = { + 'id': {'readonly': True}, + 'name': {'readonly': True}, + 'type': {'readonly': True}, + 'tags': {'max_items': 32}, + 'display_name': {'required': True, 'max_length': 256, 'min_length': 1, 'pattern': r'^[A-Za-z0-9-._]+$'}, + 'value': {'max_length': 4096, 'min_length': 1}, + } + + _attribute_map = { + 'id': {'key': 'id', 'type': 'str'}, + 'name': {'key': 'name', 'type': 'str'}, + 'type': {'key': 'type', 'type': 'str'}, + 'tags': {'key': 'properties.tags', 'type': '[str]'}, + 'secret': {'key': 'properties.secret', 'type': 'bool'}, + 'display_name': {'key': 'properties.displayName', 'type': 'str'}, + 'value': {'key': 'properties.value', 'type': 'str'}, + } + + def __init__(self, **kwargs): + super(NamedValueContract, self).__init__(**kwargs) + self.tags = kwargs.get('tags', None) + self.secret = kwargs.get('secret', None) + self.display_name = kwargs.get('display_name', None) + self.value = kwargs.get('value', None) + + +class NamedValueCreateContract(Resource): + """NamedValue details. + + Variables are only populated by the server, and will be ignored when + sending a request. + + All required parameters must be populated in order to send to Azure. + + :ivar id: Resource ID. + :vartype id: str + :ivar name: Resource name. + :vartype name: str + :ivar type: Resource type for API Management resource. + :vartype type: str + :param tags: Optional tags that when provided can be used to filter the + NamedValue list. + :type tags: list[str] + :param secret: Determines whether the value is a secret and should be + encrypted or not. Default value is false. + :type secret: bool + :param display_name: Required. Unique name of NamedValue. It may contain + only letters, digits, period, dash, and underscore characters. + :type display_name: str + :param value: Required. Value of the NamedValue. Can contain policy + expressions. It may not be empty or consist only of whitespace. This + property will not be filled on 'GET' operations! Use '/listSecrets' POST + request to get the value. + :type value: str + """ + + _validation = { + 'id': {'readonly': True}, + 'name': {'readonly': True}, + 'type': {'readonly': True}, + 'tags': {'max_items': 32}, + 'display_name': {'required': True, 'max_length': 256, 'min_length': 1, 'pattern': r'^[A-Za-z0-9-._]+$'}, + 'value': {'required': True, 'max_length': 4096, 'min_length': 1}, + } + + _attribute_map = { + 'id': {'key': 'id', 'type': 'str'}, + 'name': {'key': 'name', 'type': 'str'}, + 'type': {'key': 'type', 'type': 'str'}, + 'tags': {'key': 'properties.tags', 'type': '[str]'}, + 'secret': {'key': 'properties.secret', 'type': 'bool'}, + 'display_name': {'key': 'properties.displayName', 'type': 'str'}, + 'value': {'key': 'properties.value', 'type': 'str'}, + } + + def __init__(self, **kwargs): + super(NamedValueCreateContract, self).__init__(**kwargs) + self.tags = kwargs.get('tags', None) + self.secret = kwargs.get('secret', None) + self.display_name = kwargs.get('display_name', None) + self.value = kwargs.get('value', None) + + +class NamedValueEntityBaseParameters(Model): + """NamedValue Entity Base Parameters set. + + :param tags: Optional tags that when provided can be used to filter the + NamedValue list. + :type tags: list[str] + :param secret: Determines whether the value is a secret and should be + encrypted or not. Default value is false. + :type secret: bool + """ + + _validation = { + 'tags': {'max_items': 32}, + } + + _attribute_map = { + 'tags': {'key': 'tags', 'type': '[str]'}, + 'secret': {'key': 'secret', 'type': 'bool'}, + } + + def __init__(self, **kwargs): + super(NamedValueEntityBaseParameters, self).__init__(**kwargs) + self.tags = kwargs.get('tags', None) + self.secret = kwargs.get('secret', None) + + +class NamedValueUpdateParameters(Model): + """NamedValue update Parameters. + + :param tags: Optional tags that when provided can be used to filter the + NamedValue list. + :type tags: list[str] + :param secret: Determines whether the value is a secret and should be + encrypted or not. Default value is false. + :type secret: bool + :param display_name: Unique name of NamedValue. It may contain only + letters, digits, period, dash, and underscore characters. + :type display_name: str + :param value: Value of the NamedValue. Can contain policy expressions. It + may not be empty or consist only of whitespace. + :type value: str + """ + + _validation = { + 'tags': {'max_items': 32}, + 'display_name': {'max_length': 256, 'min_length': 1, 'pattern': r'^[A-Za-z0-9-._]+$'}, + 'value': {'max_length': 4096, 'min_length': 1}, + } + + _attribute_map = { + 'tags': {'key': 'properties.tags', 'type': '[str]'}, + 'secret': {'key': 'properties.secret', 'type': 'bool'}, + 'display_name': {'key': 'properties.displayName', 'type': 'str'}, + 'value': {'key': 'properties.value', 'type': 'str'}, + } + + def __init__(self, **kwargs): + super(NamedValueUpdateParameters, self).__init__(**kwargs) + self.tags = kwargs.get('tags', None) + self.secret = kwargs.get('secret', None) + self.display_name = kwargs.get('display_name', None) + self.value = kwargs.get('value', None) + + +class NetworkStatusContract(Model): + """Network Status details. + + All required parameters must be populated in order to send to Azure. + + :param dns_servers: Required. Gets the list of DNS servers IPV4 addresses. + :type dns_servers: list[str] + :param connectivity_status: Required. Gets the list of Connectivity Status + to the Resources on which the service depends upon. + :type connectivity_status: + list[~azure.mgmt.apimanagement.models.ConnectivityStatusContract] + """ + + _validation = { + 'dns_servers': {'required': True}, + 'connectivity_status': {'required': True}, + } + + _attribute_map = { + 'dns_servers': {'key': 'dnsServers', 'type': '[str]'}, + 'connectivity_status': {'key': 'connectivityStatus', 'type': '[ConnectivityStatusContract]'}, + } + + def __init__(self, **kwargs): + super(NetworkStatusContract, self).__init__(**kwargs) + self.dns_servers = kwargs.get('dns_servers', None) + self.connectivity_status = kwargs.get('connectivity_status', None) + + +class NetworkStatusContractByLocation(Model): + """Network Status in the Location. + + :param location: Location of service + :type location: str + :param network_status: Network status in Location + :type network_status: + ~azure.mgmt.apimanagement.models.NetworkStatusContract + """ + + _validation = { + 'location': {'min_length': 1}, + } + + _attribute_map = { + 'location': {'key': 'location', 'type': 'str'}, + 'network_status': {'key': 'networkStatus', 'type': 'NetworkStatusContract'}, + } + + def __init__(self, **kwargs): + super(NetworkStatusContractByLocation, self).__init__(**kwargs) + self.location = kwargs.get('location', None) + self.network_status = kwargs.get('network_status', None) + + +class NotificationContract(Resource): + """Notification details. + + Variables are only populated by the server, and will be ignored when + sending a request. + + All required parameters must be populated in order to send to Azure. + + :ivar id: Resource ID. + :vartype id: str + :ivar name: Resource name. + :vartype name: str + :ivar type: Resource type for API Management resource. + :vartype type: str + :param title: Required. Title of the Notification. + :type title: str + :param description: Description of the Notification. + :type description: str + :param recipients: Recipient Parameter values. + :type recipients: + ~azure.mgmt.apimanagement.models.RecipientsContractProperties + """ + + _validation = { + 'id': {'readonly': True}, + 'name': {'readonly': True}, + 'type': {'readonly': True}, + 'title': {'required': True, 'max_length': 1000, 'min_length': 1}, + } + + _attribute_map = { + 'id': {'key': 'id', 'type': 'str'}, + 'name': {'key': 'name', 'type': 'str'}, + 'type': {'key': 'type', 'type': 'str'}, + 'title': {'key': 'properties.title', 'type': 'str'}, + 'description': {'key': 'properties.description', 'type': 'str'}, + 'recipients': {'key': 'properties.recipients', 'type': 'RecipientsContractProperties'}, + } + + def __init__(self, **kwargs): + super(NotificationContract, self).__init__(**kwargs) + self.title = kwargs.get('title', None) + self.description = kwargs.get('description', None) + self.recipients = kwargs.get('recipients', None) + + +class OAuth2AuthenticationSettingsContract(Model): + """API OAuth2 Authentication settings details. + + :param authorization_server_id: OAuth authorization server identifier. + :type authorization_server_id: str + :param scope: operations scope. + :type scope: str + """ + + _attribute_map = { + 'authorization_server_id': {'key': 'authorizationServerId', 'type': 'str'}, + 'scope': {'key': 'scope', 'type': 'str'}, + } + + def __init__(self, **kwargs): + super(OAuth2AuthenticationSettingsContract, self).__init__(**kwargs) + self.authorization_server_id = kwargs.get('authorization_server_id', None) + self.scope = kwargs.get('scope', None) + + +class OpenIdAuthenticationSettingsContract(Model): + """API OAuth2 Authentication settings details. + + :param openid_provider_id: OAuth authorization server identifier. + :type openid_provider_id: str + :param bearer_token_sending_methods: How to send token to the server. + :type bearer_token_sending_methods: list[str or + ~azure.mgmt.apimanagement.models.BearerTokenSendingMethods] + """ + + _attribute_map = { + 'openid_provider_id': {'key': 'openidProviderId', 'type': 'str'}, + 'bearer_token_sending_methods': {'key': 'bearerTokenSendingMethods', 'type': '[str]'}, + } + + def __init__(self, **kwargs): + super(OpenIdAuthenticationSettingsContract, self).__init__(**kwargs) + self.openid_provider_id = kwargs.get('openid_provider_id', None) + self.bearer_token_sending_methods = kwargs.get('bearer_token_sending_methods', None) + + +class OpenidConnectProviderContract(Resource): + """OpenId Connect Provider details. + + Variables are only populated by the server, and will be ignored when + sending a request. + + All required parameters must be populated in order to send to Azure. + + :ivar id: Resource ID. + :vartype id: str + :ivar name: Resource name. + :vartype name: str + :ivar type: Resource type for API Management resource. + :vartype type: str + :param display_name: Required. User-friendly OpenID Connect Provider name. + :type display_name: str + :param description: User-friendly description of OpenID Connect Provider. + :type description: str + :param metadata_endpoint: Required. Metadata endpoint URI. + :type metadata_endpoint: str + :param client_id: Required. Client ID of developer console which is the + client application. + :type client_id: str + :param client_secret: Client Secret of developer console which is the + client application. + :type client_secret: str + """ + + _validation = { + 'id': {'readonly': True}, + 'name': {'readonly': True}, + 'type': {'readonly': True}, + 'display_name': {'required': True, 'max_length': 50}, + 'metadata_endpoint': {'required': True}, + 'client_id': {'required': True}, + } + + _attribute_map = { + 'id': {'key': 'id', 'type': 'str'}, + 'name': {'key': 'name', 'type': 'str'}, + 'type': {'key': 'type', 'type': 'str'}, + 'display_name': {'key': 'properties.displayName', 'type': 'str'}, + 'description': {'key': 'properties.description', 'type': 'str'}, + 'metadata_endpoint': {'key': 'properties.metadataEndpoint', 'type': 'str'}, + 'client_id': {'key': 'properties.clientId', 'type': 'str'}, + 'client_secret': {'key': 'properties.clientSecret', 'type': 'str'}, + } + + def __init__(self, **kwargs): + super(OpenidConnectProviderContract, self).__init__(**kwargs) + self.display_name = kwargs.get('display_name', None) + self.description = kwargs.get('description', None) + self.metadata_endpoint = kwargs.get('metadata_endpoint', None) + self.client_id = kwargs.get('client_id', None) + self.client_secret = kwargs.get('client_secret', None) + + +class OpenidConnectProviderCreateContract(Resource): + """OpenId Connect Provider details. + + Variables are only populated by the server, and will be ignored when + sending a request. + + All required parameters must be populated in order to send to Azure. + + :ivar id: Resource ID. + :vartype id: str + :ivar name: Resource name. + :vartype name: str + :ivar type: Resource type for API Management resource. + :vartype type: str + :param display_name: Required. User-friendly OpenID Connect Provider name. + :type display_name: str + :param description: User-friendly description of OpenID Connect Provider. + :type description: str + :param metadata_endpoint: Required. Metadata endpoint URI. + :type metadata_endpoint: str + :param client_id: Required. Client ID of developer console which is the + client application. + :type client_id: str + :param client_secret: Required. Client Secret of developer console which + is the client application. + :type client_secret: str + """ + + _validation = { + 'id': {'readonly': True}, + 'name': {'readonly': True}, + 'type': {'readonly': True}, + 'display_name': {'required': True, 'max_length': 50}, + 'metadata_endpoint': {'required': True}, + 'client_id': {'required': True}, + 'client_secret': {'required': True}, + } + + _attribute_map = { + 'id': {'key': 'id', 'type': 'str'}, + 'name': {'key': 'name', 'type': 'str'}, + 'type': {'key': 'type', 'type': 'str'}, + 'display_name': {'key': 'properties.displayName', 'type': 'str'}, + 'description': {'key': 'properties.description', 'type': 'str'}, + 'metadata_endpoint': {'key': 'properties.metadataEndpoint', 'type': 'str'}, + 'client_id': {'key': 'properties.clientId', 'type': 'str'}, + 'client_secret': {'key': 'properties.clientSecret', 'type': 'str'}, + } + + def __init__(self, **kwargs): + super(OpenidConnectProviderCreateContract, self).__init__(**kwargs) + self.display_name = kwargs.get('display_name', None) + self.description = kwargs.get('description', None) + self.metadata_endpoint = kwargs.get('metadata_endpoint', None) + self.client_id = kwargs.get('client_id', None) + self.client_secret = kwargs.get('client_secret', None) + + +class OpenidConnectProviderUpdateContract(Model): + """Parameters supplied to the Update OpenID Connect Provider operation. + + :param display_name: User-friendly OpenID Connect Provider name. + :type display_name: str + :param description: User-friendly description of OpenID Connect Provider. + :type description: str + :param metadata_endpoint: Metadata endpoint URI. + :type metadata_endpoint: str + :param client_id: Client ID of developer console which is the client + application. + :type client_id: str + :param client_secret: Client Secret of developer console which is the + client application. + :type client_secret: str + """ + + _validation = { + 'display_name': {'max_length': 50}, + } + + _attribute_map = { + 'display_name': {'key': 'properties.displayName', 'type': 'str'}, + 'description': {'key': 'properties.description', 'type': 'str'}, + 'metadata_endpoint': {'key': 'properties.metadataEndpoint', 'type': 'str'}, + 'client_id': {'key': 'properties.clientId', 'type': 'str'}, + 'client_secret': {'key': 'properties.clientSecret', 'type': 'str'}, + } + + def __init__(self, **kwargs): + super(OpenidConnectProviderUpdateContract, self).__init__(**kwargs) + self.display_name = kwargs.get('display_name', None) + self.description = kwargs.get('description', None) + self.metadata_endpoint = kwargs.get('metadata_endpoint', None) + self.client_id = kwargs.get('client_id', None) + self.client_secret = kwargs.get('client_secret', None) + + +class Operation(Model): + """REST API operation. + + :param name: Operation name: {provider}/{resource}/{operation} + :type name: str + :param display: The object that describes the operation. + :type display: ~azure.mgmt.apimanagement.models.OperationDisplay + :param origin: The operation origin. + :type origin: str + :param properties: The operation properties. + :type properties: object + """ + + _attribute_map = { + 'name': {'key': 'name', 'type': 'str'}, + 'display': {'key': 'display', 'type': 'OperationDisplay'}, + 'origin': {'key': 'origin', 'type': 'str'}, + 'properties': {'key': 'properties', 'type': 'object'}, + } + + def __init__(self, **kwargs): + super(Operation, self).__init__(**kwargs) + self.name = kwargs.get('name', None) + self.display = kwargs.get('display', None) + self.origin = kwargs.get('origin', None) + self.properties = kwargs.get('properties', None) + + +class OperationContract(Resource): + """Api Operation details. + + Variables are only populated by the server, and will be ignored when + sending a request. + + All required parameters must be populated in order to send to Azure. + + :ivar id: Resource ID. + :vartype id: str + :ivar name: Resource name. + :vartype name: str + :ivar type: Resource type for API Management resource. + :vartype type: str + :param template_parameters: Collection of URL template parameters. + :type template_parameters: + list[~azure.mgmt.apimanagement.models.ParameterContract] + :param description: Description of the operation. May include HTML + formatting tags. + :type description: str + :param request: An entity containing request details. + :type request: ~azure.mgmt.apimanagement.models.RequestContract + :param responses: Array of Operation responses. + :type responses: list[~azure.mgmt.apimanagement.models.ResponseContract] + :param policies: Operation Policies + :type policies: str + :param display_name: Required. Operation Name. + :type display_name: str + :param method: Required. A Valid HTTP Operation Method. Typical Http + Methods like GET, PUT, POST but not limited by only them. + :type method: str + :param url_template: Required. Relative URL template identifying the + target resource for this operation. May include parameters. Example: + /customers/{cid}/orders/{oid}/?date={date} + :type url_template: str + """ + + _validation = { + 'id': {'readonly': True}, + 'name': {'readonly': True}, + 'type': {'readonly': True}, + 'description': {'max_length': 1000}, + 'display_name': {'required': True, 'max_length': 300, 'min_length': 1}, + 'method': {'required': True}, + 'url_template': {'required': True, 'max_length': 1000, 'min_length': 1}, + } + + _attribute_map = { + 'id': {'key': 'id', 'type': 'str'}, + 'name': {'key': 'name', 'type': 'str'}, + 'type': {'key': 'type', 'type': 'str'}, + 'template_parameters': {'key': 'properties.templateParameters', 'type': '[ParameterContract]'}, + 'description': {'key': 'properties.description', 'type': 'str'}, + 'request': {'key': 'properties.request', 'type': 'RequestContract'}, + 'responses': {'key': 'properties.responses', 'type': '[ResponseContract]'}, + 'policies': {'key': 'properties.policies', 'type': 'str'}, + 'display_name': {'key': 'properties.displayName', 'type': 'str'}, + 'method': {'key': 'properties.method', 'type': 'str'}, + 'url_template': {'key': 'properties.urlTemplate', 'type': 'str'}, + } + + def __init__(self, **kwargs): + super(OperationContract, self).__init__(**kwargs) + self.template_parameters = kwargs.get('template_parameters', None) + self.description = kwargs.get('description', None) + self.request = kwargs.get('request', None) + self.responses = kwargs.get('responses', None) + self.policies = kwargs.get('policies', None) + self.display_name = kwargs.get('display_name', None) + self.method = kwargs.get('method', None) + self.url_template = kwargs.get('url_template', None) + + +class OperationDisplay(Model): + """The object that describes the operation. + + :param provider: Friendly name of the resource provider + :type provider: str + :param operation: Operation type: read, write, delete, listKeys/action, + etc. + :type operation: str + :param resource: Resource type on which the operation is performed. + :type resource: str + :param description: Friendly name of the operation + :type description: str + """ + + _attribute_map = { + 'provider': {'key': 'provider', 'type': 'str'}, + 'operation': {'key': 'operation', 'type': 'str'}, + 'resource': {'key': 'resource', 'type': 'str'}, + 'description': {'key': 'description', 'type': 'str'}, + } + + def __init__(self, **kwargs): + super(OperationDisplay, self).__init__(**kwargs) + self.provider = kwargs.get('provider', None) + self.operation = kwargs.get('operation', None) + self.resource = kwargs.get('resource', None) + self.description = kwargs.get('description', None) + + +class OperationEntityBaseContract(Model): + """Api Operation Entity Base Contract details. + + :param template_parameters: Collection of URL template parameters. + :type template_parameters: + list[~azure.mgmt.apimanagement.models.ParameterContract] + :param description: Description of the operation. May include HTML + formatting tags. + :type description: str + :param request: An entity containing request details. + :type request: ~azure.mgmt.apimanagement.models.RequestContract + :param responses: Array of Operation responses. + :type responses: list[~azure.mgmt.apimanagement.models.ResponseContract] + :param policies: Operation Policies + :type policies: str + """ + + _validation = { + 'description': {'max_length': 1000}, + } + + _attribute_map = { + 'template_parameters': {'key': 'templateParameters', 'type': '[ParameterContract]'}, + 'description': {'key': 'description', 'type': 'str'}, + 'request': {'key': 'request', 'type': 'RequestContract'}, + 'responses': {'key': 'responses', 'type': '[ResponseContract]'}, + 'policies': {'key': 'policies', 'type': 'str'}, + } + + def __init__(self, **kwargs): + super(OperationEntityBaseContract, self).__init__(**kwargs) + self.template_parameters = kwargs.get('template_parameters', None) + self.description = kwargs.get('description', None) + self.request = kwargs.get('request', None) + self.responses = kwargs.get('responses', None) + self.policies = kwargs.get('policies', None) + + +class OperationResultContract(Model): + """Operation Result. + + Variables are only populated by the server, and will be ignored when + sending a request. + + :param id: Operation result identifier. + :type id: str + :param status: Status of an async operation. Possible values include: + 'Started', 'InProgress', 'Succeeded', 'Failed' + :type status: str or ~azure.mgmt.apimanagement.models.AsyncOperationStatus + :param started: Start time of an async operation. The date conforms to the + following format: `yyyy-MM-ddTHH:mm:ssZ` as specified by the ISO 8601 + standard. + :type started: datetime + :param updated: Last update time of an async operation. The date conforms + to the following format: `yyyy-MM-ddTHH:mm:ssZ` as specified by the ISO + 8601 standard. + :type updated: datetime + :param result_info: Optional result info. + :type result_info: str + :param error: Error Body Contract + :type error: ~azure.mgmt.apimanagement.models.ErrorResponseBody + :ivar action_log: This property if only provided as part of the + TenantConfiguration_Validate operation. It contains the log the entities + which will be updated/created/deleted as part of the + TenantConfiguration_Deploy operation. + :vartype action_log: + list[~azure.mgmt.apimanagement.models.OperationResultLogItemContract] + """ + + _validation = { + 'action_log': {'readonly': True}, + } + + _attribute_map = { + 'id': {'key': 'id', 'type': 'str'}, + 'status': {'key': 'status', 'type': 'AsyncOperationStatus'}, + 'started': {'key': 'started', 'type': 'iso-8601'}, + 'updated': {'key': 'updated', 'type': 'iso-8601'}, + 'result_info': {'key': 'resultInfo', 'type': 'str'}, + 'error': {'key': 'error', 'type': 'ErrorResponseBody'}, + 'action_log': {'key': 'actionLog', 'type': '[OperationResultLogItemContract]'}, + } + + def __init__(self, **kwargs): + super(OperationResultContract, self).__init__(**kwargs) + self.id = kwargs.get('id', None) + self.status = kwargs.get('status', None) + self.started = kwargs.get('started', None) + self.updated = kwargs.get('updated', None) + self.result_info = kwargs.get('result_info', None) + self.error = kwargs.get('error', None) + self.action_log = None + + +class OperationResultLogItemContract(Model): + """Log of the entity being created, updated or deleted. + + :param object_type: The type of entity contract. + :type object_type: str + :param action: Action like create/update/delete. + :type action: str + :param object_key: Identifier of the entity being created/updated/deleted. + :type object_key: str + """ + + _attribute_map = { + 'object_type': {'key': 'objectType', 'type': 'str'}, + 'action': {'key': 'action', 'type': 'str'}, + 'object_key': {'key': 'objectKey', 'type': 'str'}, + } + + def __init__(self, **kwargs): + super(OperationResultLogItemContract, self).__init__(**kwargs) + self.object_type = kwargs.get('object_type', None) + self.action = kwargs.get('action', None) + self.object_key = kwargs.get('object_key', None) + + +class OperationTagResourceContractProperties(Model): + """Operation Entity contract Properties. + + Variables are only populated by the server, and will be ignored when + sending a request. + + :param id: Identifier of the operation in form /operations/{operationId}. + :type id: str + :ivar name: Operation name. + :vartype name: str + :ivar api_name: Api Name. + :vartype api_name: str + :ivar api_revision: Api Revision. + :vartype api_revision: str + :ivar api_version: Api Version. + :vartype api_version: str + :ivar description: Operation Description. + :vartype description: str + :ivar method: A Valid HTTP Operation Method. Typical Http Methods like + GET, PUT, POST but not limited by only them. + :vartype method: str + :ivar url_template: Relative URL template identifying the target resource + for this operation. May include parameters. Example: + /customers/{cid}/orders/{oid}/?date={date} + :vartype url_template: str + """ + + _validation = { + 'name': {'readonly': True}, + 'api_name': {'readonly': True}, + 'api_revision': {'readonly': True}, + 'api_version': {'readonly': True}, + 'description': {'readonly': True}, + 'method': {'readonly': True}, + 'url_template': {'readonly': True}, + } + + _attribute_map = { + 'id': {'key': 'id', 'type': 'str'}, + 'name': {'key': 'name', 'type': 'str'}, + 'api_name': {'key': 'apiName', 'type': 'str'}, + 'api_revision': {'key': 'apiRevision', 'type': 'str'}, + 'api_version': {'key': 'apiVersion', 'type': 'str'}, + 'description': {'key': 'description', 'type': 'str'}, + 'method': {'key': 'method', 'type': 'str'}, + 'url_template': {'key': 'urlTemplate', 'type': 'str'}, + } + + def __init__(self, **kwargs): + super(OperationTagResourceContractProperties, self).__init__(**kwargs) + self.id = kwargs.get('id', None) + self.name = None + self.api_name = None + self.api_revision = None + self.api_version = None + self.description = None + self.method = None + self.url_template = None + + +class OperationUpdateContract(Model): + """Api Operation Update Contract details. + + :param template_parameters: Collection of URL template parameters. + :type template_parameters: + list[~azure.mgmt.apimanagement.models.ParameterContract] + :param description: Description of the operation. May include HTML + formatting tags. + :type description: str + :param request: An entity containing request details. + :type request: ~azure.mgmt.apimanagement.models.RequestContract + :param responses: Array of Operation responses. + :type responses: list[~azure.mgmt.apimanagement.models.ResponseContract] + :param policies: Operation Policies + :type policies: str + :param display_name: Operation Name. + :type display_name: str + :param method: A Valid HTTP Operation Method. Typical Http Methods like + GET, PUT, POST but not limited by only them. + :type method: str + :param url_template: Relative URL template identifying the target resource + for this operation. May include parameters. Example: + /customers/{cid}/orders/{oid}/?date={date} + :type url_template: str + """ + + _validation = { + 'description': {'max_length': 1000}, + 'display_name': {'max_length': 300, 'min_length': 1}, + 'url_template': {'max_length': 1000, 'min_length': 1}, + } + + _attribute_map = { + 'template_parameters': {'key': 'properties.templateParameters', 'type': '[ParameterContract]'}, + 'description': {'key': 'properties.description', 'type': 'str'}, + 'request': {'key': 'properties.request', 'type': 'RequestContract'}, + 'responses': {'key': 'properties.responses', 'type': '[ResponseContract]'}, + 'policies': {'key': 'properties.policies', 'type': 'str'}, + 'display_name': {'key': 'properties.displayName', 'type': 'str'}, + 'method': {'key': 'properties.method', 'type': 'str'}, + 'url_template': {'key': 'properties.urlTemplate', 'type': 'str'}, + } + + def __init__(self, **kwargs): + super(OperationUpdateContract, self).__init__(**kwargs) + self.template_parameters = kwargs.get('template_parameters', None) + self.description = kwargs.get('description', None) + self.request = kwargs.get('request', None) + self.responses = kwargs.get('responses', None) + self.policies = kwargs.get('policies', None) + self.display_name = kwargs.get('display_name', None) + self.method = kwargs.get('method', None) + self.url_template = kwargs.get('url_template', None) + + +class ParameterContract(Model): + """Operation parameters details. + + All required parameters must be populated in order to send to Azure. + + :param name: Required. Parameter name. + :type name: str + :param description: Parameter description. + :type description: str + :param type: Required. Parameter type. + :type type: str + :param default_value: Default parameter value. + :type default_value: str + :param required: Specifies whether parameter is required or not. + :type required: bool + :param values: Parameter values. + :type values: list[str] + """ + + _validation = { + 'name': {'required': True}, + 'type': {'required': True}, + } + + _attribute_map = { + 'name': {'key': 'name', 'type': 'str'}, + 'description': {'key': 'description', 'type': 'str'}, + 'type': {'key': 'type', 'type': 'str'}, + 'default_value': {'key': 'defaultValue', 'type': 'str'}, + 'required': {'key': 'required', 'type': 'bool'}, + 'values': {'key': 'values', 'type': '[str]'}, + } + + def __init__(self, **kwargs): + super(ParameterContract, self).__init__(**kwargs) + self.name = kwargs.get('name', None) + self.description = kwargs.get('description', None) + self.type = kwargs.get('type', None) + self.default_value = kwargs.get('default_value', None) + self.required = kwargs.get('required', None) + self.values = kwargs.get('values', None) + + +class PipelineDiagnosticSettings(Model): + """Diagnostic settings for incoming/outgoing 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) + + +class PolicyCollection(Model): + """The response of the list policy operation. + + :param value: Policy Contract value. + :type value: list[~azure.mgmt.apimanagement.models.PolicyContract] + :param next_link: Next page link if any. + :type next_link: str + """ + + _attribute_map = { + 'value': {'key': 'value', 'type': '[PolicyContract]'}, + 'next_link': {'key': 'nextLink', 'type': 'str'}, + } + + def __init__(self, **kwargs): + super(PolicyCollection, self).__init__(**kwargs) + self.value = kwargs.get('value', None) + self.next_link = kwargs.get('next_link', None) + + +class PolicyContract(Resource): + """Policy Contract details. + + Variables are only populated by the server, and will be ignored when + sending a request. + + All required parameters must be populated in order to send to Azure. + + :ivar id: Resource ID. + :vartype id: str + :ivar name: Resource name. + :vartype name: str + :ivar type: Resource type for API Management resource. + :vartype type: str + :param value: Required. Contents of the Policy as defined by the format. + :type value: str + :param format: Format of the policyContent. Possible values include: + 'xml', 'xml-link', 'rawxml', 'rawxml-link'. Default value: "xml" . + :type format: str or ~azure.mgmt.apimanagement.models.PolicyContentFormat + """ + + _validation = { + 'id': {'readonly': True}, + 'name': {'readonly': True}, + 'type': {'readonly': True}, + 'value': {'required': True}, + } + + _attribute_map = { + 'id': {'key': 'id', 'type': 'str'}, + 'name': {'key': 'name', 'type': 'str'}, + 'type': {'key': 'type', 'type': 'str'}, + 'value': {'key': 'properties.value', 'type': 'str'}, + 'format': {'key': 'properties.format', 'type': 'str'}, + } + + def __init__(self, **kwargs): + super(PolicyContract, self).__init__(**kwargs) + self.value = kwargs.get('value', None) + self.format = kwargs.get('format', "xml") + + +class PolicyDescriptionCollection(Model): + """Descriptions of APIM policies. + + :param value: Descriptions of APIM policies. + :type value: + list[~azure.mgmt.apimanagement.models.PolicyDescriptionContract] + :param count: Total record count number. + :type count: long + """ + + _attribute_map = { + 'value': {'key': 'value', 'type': '[PolicyDescriptionContract]'}, + 'count': {'key': 'count', 'type': 'long'}, + } + + def __init__(self, **kwargs): + super(PolicyDescriptionCollection, self).__init__(**kwargs) + self.value = kwargs.get('value', None) + self.count = kwargs.get('count', None) + + +class PolicyDescriptionContract(Resource): + """Policy description details. + + Variables are only populated by the server, and will be ignored when + sending a request. + + :ivar id: Resource ID. + :vartype id: str + :ivar name: Resource name. + :vartype name: str + :ivar type: Resource type for API Management resource. + :vartype type: str + :ivar description: Policy description. + :vartype description: str + :ivar scope: Binary OR value of the Snippet scope. + :vartype scope: int + """ + + _validation = { + 'id': {'readonly': True}, + 'name': {'readonly': True}, + 'type': {'readonly': True}, + 'description': {'readonly': True}, + 'scope': {'readonly': True}, + } + + _attribute_map = { + 'id': {'key': 'id', 'type': 'str'}, + 'name': {'key': 'name', 'type': 'str'}, + 'type': {'key': 'type', 'type': 'str'}, + 'description': {'key': 'properties.description', 'type': 'str'}, + 'scope': {'key': 'properties.scope', 'type': 'int'}, + } + + def __init__(self, **kwargs): + super(PolicyDescriptionContract, self).__init__(**kwargs) + self.description = None + self.scope = None + + +class PortalDelegationSettings(Resource): + """Delegation settings for a developer portal. + + Variables are only populated by the server, and will be ignored when + sending a request. + + :ivar id: Resource ID. + :vartype id: str + :ivar name: Resource name. + :vartype name: str + :ivar type: Resource type for API Management resource. + :vartype type: str + :param url: A delegation Url. + :type url: str + :param validation_key: A base64-encoded validation key to validate, that a + request is coming from Azure API Management. + :type validation_key: str + :param subscriptions: Subscriptions delegation settings. + :type subscriptions: + ~azure.mgmt.apimanagement.models.SubscriptionsDelegationSettingsProperties + :param user_registration: User registration delegation settings. + :type user_registration: + ~azure.mgmt.apimanagement.models.RegistrationDelegationSettingsProperties + """ + + _validation = { + 'id': {'readonly': True}, + 'name': {'readonly': True}, + 'type': {'readonly': True}, + } + + _attribute_map = { + 'id': {'key': 'id', 'type': 'str'}, + 'name': {'key': 'name', 'type': 'str'}, + 'type': {'key': 'type', 'type': 'str'}, + 'url': {'key': 'properties.url', 'type': 'str'}, + 'validation_key': {'key': 'properties.validationKey', 'type': 'str'}, + 'subscriptions': {'key': 'properties.subscriptions', 'type': 'SubscriptionsDelegationSettingsProperties'}, + 'user_registration': {'key': 'properties.userRegistration', 'type': 'RegistrationDelegationSettingsProperties'}, + } + + def __init__(self, **kwargs): + super(PortalDelegationSettings, self).__init__(**kwargs) + self.url = kwargs.get('url', None) + self.validation_key = kwargs.get('validation_key', None) + self.subscriptions = kwargs.get('subscriptions', None) + self.user_registration = kwargs.get('user_registration', None) + + +class PortalSettingValidationKeyContract(Model): + """Client or app secret used in IdentityProviders, Aad, OpenID or OAuth. + + :param validation_key: This is secret value of the validation key in + portal settings. + :type validation_key: str + """ + + _attribute_map = { + 'validation_key': {'key': 'validationKey', 'type': 'str'}, + } + + def __init__(self, **kwargs): + super(PortalSettingValidationKeyContract, self).__init__(**kwargs) + self.validation_key = kwargs.get('validation_key', None) + + +class PortalSigninSettings(Resource): + """Sign-In settings for the Developer Portal. + + Variables are only populated by the server, and will be ignored when + sending a request. + + :ivar id: Resource ID. + :vartype id: str + :ivar name: Resource name. + :vartype name: str + :ivar type: Resource type for API Management resource. + :vartype type: str + :param enabled: Redirect Anonymous users to the Sign-In page. + :type enabled: bool + """ + + _validation = { + 'id': {'readonly': True}, + 'name': {'readonly': True}, + 'type': {'readonly': True}, + } + + _attribute_map = { + 'id': {'key': 'id', 'type': 'str'}, + 'name': {'key': 'name', 'type': 'str'}, + 'type': {'key': 'type', 'type': 'str'}, + 'enabled': {'key': 'properties.enabled', 'type': 'bool'}, + } + + def __init__(self, **kwargs): + super(PortalSigninSettings, self).__init__(**kwargs) + self.enabled = kwargs.get('enabled', None) + + +class PortalSignupSettings(Resource): + """Sign-Up settings for a developer portal. + + Variables are only populated by the server, and will be ignored when + sending a request. + + :ivar id: Resource ID. + :vartype id: str + :ivar name: Resource name. + :vartype name: str + :ivar type: Resource type for API Management resource. + :vartype type: str + :param enabled: Allow users to sign up on a developer portal. + :type enabled: bool + :param terms_of_service: Terms of service contract properties. + :type terms_of_service: + ~azure.mgmt.apimanagement.models.TermsOfServiceProperties + """ + + _validation = { + 'id': {'readonly': True}, + 'name': {'readonly': True}, + 'type': {'readonly': True}, + } + + _attribute_map = { + 'id': {'key': 'id', 'type': 'str'}, + 'name': {'key': 'name', 'type': 'str'}, + 'type': {'key': 'type', 'type': 'str'}, + 'enabled': {'key': 'properties.enabled', 'type': 'bool'}, + 'terms_of_service': {'key': 'properties.termsOfService', 'type': 'TermsOfServiceProperties'}, + } + + def __init__(self, **kwargs): + super(PortalSignupSettings, self).__init__(**kwargs) + self.enabled = kwargs.get('enabled', None) + self.terms_of_service = kwargs.get('terms_of_service', None) + + +class ProductContract(Resource): + """Product details. + + Variables are only populated by the server, and will be ignored when + sending a request. + + All required parameters must be populated in order to send to Azure. + + :ivar id: Resource ID. + :vartype id: str + :ivar name: Resource name. + :vartype name: str + :ivar type: Resource type for API Management resource. + :vartype type: str + :param description: Product description. May include HTML formatting tags. + :type description: str + :param terms: Product terms of use. Developers trying to subscribe to the + product will be presented and required to accept these terms before they + can complete the subscription process. + :type terms: str + :param subscription_required: Whether a product subscription is required + for accessing APIs included in this product. If true, the product is + referred to as "protected" and a valid subscription key is required for a + request to an API included in the product to succeed. If false, the + product is referred to as "open" and requests to an API included in the + product can be made without a subscription key. If property is omitted + when creating a new product it's value is assumed to be true. + :type subscription_required: bool + :param approval_required: whether subscription approval is required. If + false, new subscriptions will be approved automatically enabling + developers to call the product’s APIs immediately after subscribing. If + true, administrators must manually approve the subscription before the + developer can any of the product’s APIs. Can be present only if + 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 + unlimited per user subscriptions. Can be present only if + subscriptionRequired property is present and has a value of false. + :type subscriptions_limit: int + :param state: whether product is published or not. Published products are + discoverable by users of developer portal. Non published products are + visible only to administrators. Default state of Product is notPublished. + Possible values include: 'notPublished', 'published' + :type state: str or ~azure.mgmt.apimanagement.models.ProductState + :param display_name: Required. Product name. + :type display_name: str + """ + + _validation = { + 'id': {'readonly': True}, + 'name': {'readonly': True}, + 'type': {'readonly': True}, + 'description': {'max_length': 1000, 'min_length': 1}, + 'display_name': {'required': True, 'max_length': 300, 'min_length': 1}, + } + + _attribute_map = { + 'id': {'key': 'id', 'type': 'str'}, + 'name': {'key': 'name', 'type': 'str'}, + 'type': {'key': 'type', 'type': 'str'}, + 'description': {'key': 'properties.description', 'type': 'str'}, + 'terms': {'key': 'properties.terms', 'type': 'str'}, + 'subscription_required': {'key': 'properties.subscriptionRequired', 'type': 'bool'}, + 'approval_required': {'key': 'properties.approvalRequired', 'type': 'bool'}, + 'subscriptions_limit': {'key': 'properties.subscriptionsLimit', 'type': 'int'}, + 'state': {'key': 'properties.state', 'type': 'ProductState'}, + 'display_name': {'key': 'properties.displayName', 'type': 'str'}, + } + + def __init__(self, **kwargs): + super(ProductContract, self).__init__(**kwargs) + self.description = kwargs.get('description', None) + self.terms = kwargs.get('terms', None) + self.subscription_required = kwargs.get('subscription_required', None) + self.approval_required = kwargs.get('approval_required', None) + self.subscriptions_limit = kwargs.get('subscriptions_limit', None) + self.state = kwargs.get('state', None) + self.display_name = kwargs.get('display_name', None) + + +class ProductEntityBaseParameters(Model): + """Product Entity Base Parameters. + + :param description: Product description. May include HTML formatting tags. + :type description: str + :param terms: Product terms of use. Developers trying to subscribe to the + product will be presented and required to accept these terms before they + can complete the subscription process. + :type terms: str + :param subscription_required: Whether a product subscription is required + for accessing APIs included in this product. If true, the product is + referred to as "protected" and a valid subscription key is required for a + request to an API included in the product to succeed. If false, the + product is referred to as "open" and requests to an API included in the + product can be made without a subscription key. If property is omitted + when creating a new product it's value is assumed to be true. + :type subscription_required: bool + :param approval_required: whether subscription approval is required. If + false, new subscriptions will be approved automatically enabling + developers to call the product’s APIs immediately after subscribing. If + true, administrators must manually approve the subscription before the + developer can any of the product’s APIs. Can be present only if + 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 + unlimited per user subscriptions. Can be present only if + subscriptionRequired property is present and has a value of false. + :type subscriptions_limit: int + :param state: whether product is published or not. Published products are + discoverable by users of developer portal. Non published products are + visible only to administrators. Default state of Product is notPublished. + Possible values include: 'notPublished', 'published' + :type state: str or ~azure.mgmt.apimanagement.models.ProductState + """ + + _validation = { + 'description': {'max_length': 1000, 'min_length': 1}, + } + + _attribute_map = { + 'description': {'key': 'description', 'type': 'str'}, + 'terms': {'key': 'terms', 'type': 'str'}, + 'subscription_required': {'key': 'subscriptionRequired', 'type': 'bool'}, + 'approval_required': {'key': 'approvalRequired', 'type': 'bool'}, + 'subscriptions_limit': {'key': 'subscriptionsLimit', 'type': 'int'}, + 'state': {'key': 'state', 'type': 'ProductState'}, + } + + def __init__(self, **kwargs): + super(ProductEntityBaseParameters, self).__init__(**kwargs) + self.description = kwargs.get('description', None) + self.terms = kwargs.get('terms', None) + self.subscription_required = kwargs.get('subscription_required', None) + self.approval_required = kwargs.get('approval_required', None) + self.subscriptions_limit = kwargs.get('subscriptions_limit', None) + self.state = kwargs.get('state', None) + + +class ProductTagResourceContractProperties(ProductEntityBaseParameters): + """Product profile. + + All required parameters must be populated in order to send to Azure. + + :param description: Product description. May include HTML formatting tags. + :type description: str + :param terms: Product terms of use. Developers trying to subscribe to the + product will be presented and required to accept these terms before they + can complete the subscription process. + :type terms: str + :param subscription_required: Whether a product subscription is required + for accessing APIs included in this product. If true, the product is + referred to as "protected" and a valid subscription key is required for a + request to an API included in the product to succeed. If false, the + product is referred to as "open" and requests to an API included in the + product can be made without a subscription key. If property is omitted + when creating a new product it's value is assumed to be true. + :type subscription_required: bool + :param approval_required: whether subscription approval is required. If + false, new subscriptions will be approved automatically enabling + developers to call the product’s APIs immediately after subscribing. If + true, administrators must manually approve the subscription before the + developer can any of the product’s APIs. Can be present only if + 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 + unlimited per user subscriptions. Can be present only if + subscriptionRequired property is present and has a value of false. + :type subscriptions_limit: int + :param state: whether product is published or not. Published products are + discoverable by users of developer portal. Non published products are + visible only to administrators. Default state of Product is notPublished. + Possible values include: 'notPublished', 'published' + :type state: str or ~azure.mgmt.apimanagement.models.ProductState + :param id: Identifier of the product in the form of /products/{productId} + :type id: str + :param name: Required. Product name. + :type name: str + """ + + _validation = { + 'description': {'max_length': 1000, 'min_length': 1}, + 'name': {'required': True, 'max_length': 300, 'min_length': 1}, + } + + _attribute_map = { + 'description': {'key': 'description', 'type': 'str'}, + 'terms': {'key': 'terms', 'type': 'str'}, + 'subscription_required': {'key': 'subscriptionRequired', 'type': 'bool'}, + 'approval_required': {'key': 'approvalRequired', 'type': 'bool'}, + 'subscriptions_limit': {'key': 'subscriptionsLimit', 'type': 'int'}, + 'state': {'key': 'state', 'type': 'ProductState'}, + 'id': {'key': 'id', 'type': 'str'}, + 'name': {'key': 'name', 'type': 'str'}, + } + + def __init__(self, **kwargs): + super(ProductTagResourceContractProperties, self).__init__(**kwargs) + self.id = kwargs.get('id', None) + self.name = kwargs.get('name', None) + + +class ProductUpdateParameters(Model): + """Product Update parameters. + + :param description: Product description. May include HTML formatting tags. + :type description: str + :param terms: Product terms of use. Developers trying to subscribe to the + product will be presented and required to accept these terms before they + can complete the subscription process. + :type terms: str + :param subscription_required: Whether a product subscription is required + for accessing APIs included in this product. If true, the product is + referred to as "protected" and a valid subscription key is required for a + request to an API included in the product to succeed. If false, the + product is referred to as "open" and requests to an API included in the + product can be made without a subscription key. If property is omitted + when creating a new product it's value is assumed to be true. + :type subscription_required: bool + :param approval_required: whether subscription approval is required. If + false, new subscriptions will be approved automatically enabling + developers to call the product’s APIs immediately after subscribing. If + true, administrators must manually approve the subscription before the + developer can any of the product’s APIs. Can be present only if + 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 + unlimited per user subscriptions. Can be present only if + subscriptionRequired property is present and has a value of false. + :type subscriptions_limit: int + :param state: whether product is published or not. Published products are + discoverable by users of developer portal. Non published products are + visible only to administrators. Default state of Product is notPublished. + Possible values include: 'notPublished', 'published' + :type state: str or ~azure.mgmt.apimanagement.models.ProductState + :param display_name: Product name. + :type display_name: str + """ + + _validation = { + 'description': {'max_length': 1000, 'min_length': 1}, + 'display_name': {'max_length': 300, 'min_length': 1}, + } + + _attribute_map = { + 'description': {'key': 'properties.description', 'type': 'str'}, + 'terms': {'key': 'properties.terms', 'type': 'str'}, + 'subscription_required': {'key': 'properties.subscriptionRequired', 'type': 'bool'}, + 'approval_required': {'key': 'properties.approvalRequired', 'type': 'bool'}, + 'subscriptions_limit': {'key': 'properties.subscriptionsLimit', 'type': 'int'}, + 'state': {'key': 'properties.state', 'type': 'ProductState'}, + 'display_name': {'key': 'properties.displayName', 'type': 'str'}, + } + + def __init__(self, **kwargs): + super(ProductUpdateParameters, self).__init__(**kwargs) + self.description = kwargs.get('description', None) + self.terms = kwargs.get('terms', None) + self.subscription_required = kwargs.get('subscription_required', None) + self.approval_required = kwargs.get('approval_required', None) + self.subscriptions_limit = kwargs.get('subscriptions_limit', None) + self.state = kwargs.get('state', None) + self.display_name = kwargs.get('display_name', None) + + +class PropertyValueContract(Model): + """Client or app secret used in IdentityProviders, Aad, OpenID or OAuth. + + :param value: This is secret value of the NamedValue entity. + :type value: str + """ + + _attribute_map = { + 'value': {'key': 'value', 'type': 'str'}, + } + + def __init__(self, **kwargs): + super(PropertyValueContract, self).__init__(**kwargs) + self.value = kwargs.get('value', None) + + +class QuotaCounterCollection(Model): + """Paged Quota Counter list representation. + + :param value: Quota counter values. + :type value: list[~azure.mgmt.apimanagement.models.QuotaCounterContract] + :param count: Total record count number across all pages. + :type count: long + :param next_link: Next page link if any. + :type next_link: str + """ + + _attribute_map = { + 'value': {'key': 'value', 'type': '[QuotaCounterContract]'}, + 'count': {'key': 'count', 'type': 'long'}, + 'next_link': {'key': 'nextLink', 'type': 'str'}, + } + + def __init__(self, **kwargs): + super(QuotaCounterCollection, self).__init__(**kwargs) + self.value = kwargs.get('value', None) + self.count = kwargs.get('count', None) + self.next_link = kwargs.get('next_link', None) + + +class QuotaCounterContract(Model): + """Quota counter details. + + All required parameters must be populated in order to send to Azure. + + :param counter_key: Required. The Key value of the Counter. Must not be + empty. + :type counter_key: str + :param period_key: Required. Identifier of the Period for which the + counter was collected. Must not be empty. + :type period_key: str + :param period_start_time: Required. The date of the start of Counter + Period. The date conforms to the following format: `yyyy-MM-ddTHH:mm:ssZ` + as specified by the ISO 8601 standard. + :type period_start_time: datetime + :param period_end_time: Required. The date of the end of Counter Period. + The date conforms to the following format: `yyyy-MM-ddTHH:mm:ssZ` as + specified by the ISO 8601 standard. + :type period_end_time: datetime + :param value: Quota Value Properties + :type value: + ~azure.mgmt.apimanagement.models.QuotaCounterValueContractProperties + """ + + _validation = { + 'counter_key': {'required': True, 'min_length': 1}, + 'period_key': {'required': True, 'min_length': 1}, + 'period_start_time': {'required': True}, + 'period_end_time': {'required': True}, + } + + _attribute_map = { + 'counter_key': {'key': 'counterKey', 'type': 'str'}, + 'period_key': {'key': 'periodKey', 'type': 'str'}, + 'period_start_time': {'key': 'periodStartTime', 'type': 'iso-8601'}, + 'period_end_time': {'key': 'periodEndTime', 'type': 'iso-8601'}, + 'value': {'key': 'value', 'type': 'QuotaCounterValueContractProperties'}, + } + + def __init__(self, **kwargs): + super(QuotaCounterContract, self).__init__(**kwargs) + self.counter_key = kwargs.get('counter_key', None) + self.period_key = kwargs.get('period_key', None) + self.period_start_time = kwargs.get('period_start_time', None) + self.period_end_time = kwargs.get('period_end_time', None) + self.value = kwargs.get('value', None) + + +class QuotaCounterValueContract(Model): + """Quota counter value details. + + :param calls_count: Number of times Counter was called. + :type calls_count: int + :param kb_transferred: Data Transferred in KiloBytes. + :type kb_transferred: float + """ + + _attribute_map = { + 'calls_count': {'key': 'value.callsCount', 'type': 'int'}, + 'kb_transferred': {'key': 'value.kbTransferred', 'type': 'float'}, + } + + def __init__(self, **kwargs): + super(QuotaCounterValueContract, self).__init__(**kwargs) + self.calls_count = kwargs.get('calls_count', None) + self.kb_transferred = kwargs.get('kb_transferred', None) + + +class QuotaCounterValueContractProperties(Model): + """Quota counter value details. + + :param calls_count: Number of times Counter was called. + :type calls_count: int + :param kb_transferred: Data Transferred in KiloBytes. + :type kb_transferred: float + """ + + _attribute_map = { + 'calls_count': {'key': 'callsCount', 'type': 'int'}, + 'kb_transferred': {'key': 'kbTransferred', 'type': 'float'}, + } + + def __init__(self, **kwargs): + super(QuotaCounterValueContractProperties, self).__init__(**kwargs) + self.calls_count = kwargs.get('calls_count', None) + self.kb_transferred = kwargs.get('kb_transferred', None) + + +class RecipientEmailCollection(Model): + """Paged Recipient User list representation. + + :param value: Page values. + :type value: list[~azure.mgmt.apimanagement.models.RecipientEmailContract] + :param next_link: Next page link if any. + :type next_link: str + """ + + _attribute_map = { + 'value': {'key': 'value', 'type': '[RecipientEmailContract]'}, + 'next_link': {'key': 'nextLink', 'type': 'str'}, + } + + def __init__(self, **kwargs): + super(RecipientEmailCollection, self).__init__(**kwargs) + self.value = kwargs.get('value', None) + self.next_link = kwargs.get('next_link', None) + + +class RecipientEmailContract(Resource): + """Recipient Email details. + + Variables are only populated by the server, and will be ignored when + sending a request. + + :ivar id: Resource ID. + :vartype id: str + :ivar name: Resource name. + :vartype name: str + :ivar type: Resource type for API Management resource. + :vartype type: str + :param email: User Email subscribed to notification. + :type email: str + """ + + _validation = { + 'id': {'readonly': True}, + 'name': {'readonly': True}, + 'type': {'readonly': True}, + } + + _attribute_map = { + 'id': {'key': 'id', 'type': 'str'}, + 'name': {'key': 'name', 'type': 'str'}, + 'type': {'key': 'type', 'type': 'str'}, + 'email': {'key': 'properties.email', 'type': 'str'}, + } + + def __init__(self, **kwargs): + super(RecipientEmailContract, self).__init__(**kwargs) + self.email = kwargs.get('email', None) + + +class RecipientsContractProperties(Model): + """Notification Parameter contract. + + :param emails: List of Emails subscribed for the notification. + :type emails: list[str] + :param users: List of Users subscribed for the notification. + :type users: list[str] + """ + + _attribute_map = { + 'emails': {'key': 'emails', 'type': '[str]'}, + 'users': {'key': 'users', 'type': '[str]'}, + } + + def __init__(self, **kwargs): + super(RecipientsContractProperties, self).__init__(**kwargs) + self.emails = kwargs.get('emails', None) + self.users = kwargs.get('users', None) + + +class RecipientUserCollection(Model): + """Paged Recipient User list representation. + + :param value: Page values. + :type value: list[~azure.mgmt.apimanagement.models.RecipientUserContract] + :param next_link: Next page link if any. + :type next_link: str + """ + + _attribute_map = { + 'value': {'key': 'value', 'type': '[RecipientUserContract]'}, + 'next_link': {'key': 'nextLink', 'type': 'str'}, + } + + def __init__(self, **kwargs): + super(RecipientUserCollection, self).__init__(**kwargs) + self.value = kwargs.get('value', None) + self.next_link = kwargs.get('next_link', None) + + +class RecipientUserContract(Resource): + """Recipient User details. + + Variables are only populated by the server, and will be ignored when + sending a request. + + :ivar id: Resource ID. + :vartype id: str + :ivar name: Resource name. + :vartype name: str + :ivar type: Resource type for API Management resource. + :vartype type: str + :param user_id: API Management UserId subscribed to notification. + :type user_id: str + """ + + _validation = { + 'id': {'readonly': True}, + 'name': {'readonly': True}, + 'type': {'readonly': True}, + } + + _attribute_map = { + 'id': {'key': 'id', 'type': 'str'}, + 'name': {'key': 'name', 'type': 'str'}, + 'type': {'key': 'type', 'type': 'str'}, + 'user_id': {'key': 'properties.userId', 'type': 'str'}, + } + + def __init__(self, **kwargs): + super(RecipientUserContract, self).__init__(**kwargs) + self.user_id = kwargs.get('user_id', None) + + +class RegionContract(Model): + """Region profile. + + Variables are only populated by the server, and will be ignored when + sending a request. + + :ivar name: Region name. + :vartype name: str + :param is_master_region: whether Region is the master region. + :type is_master_region: bool + :param is_deleted: whether Region is deleted. + :type is_deleted: bool + """ + + _validation = { + 'name': {'readonly': True}, + } + + _attribute_map = { + 'name': {'key': 'name', 'type': 'str'}, + 'is_master_region': {'key': 'isMasterRegion', 'type': 'bool'}, + 'is_deleted': {'key': 'isDeleted', 'type': 'bool'}, + } + + def __init__(self, **kwargs): + super(RegionContract, self).__init__(**kwargs) + self.name = None + self.is_master_region = kwargs.get('is_master_region', None) + self.is_deleted = kwargs.get('is_deleted', None) + + +class RegistrationDelegationSettingsProperties(Model): + """User registration delegation settings properties. + + :param enabled: Enable or disable delegation for user registration. + :type enabled: bool + """ + + _attribute_map = { + 'enabled': {'key': 'enabled', 'type': 'bool'}, + } + + def __init__(self, **kwargs): + super(RegistrationDelegationSettingsProperties, self).__init__(**kwargs) + self.enabled = kwargs.get('enabled', None) + + +class ReportRecordContract(Model): + """Report data. + + Variables are only populated by the server, and will be ignored when + sending a request. + + :param name: Name depending on report endpoint specifies product, API, + operation or developer name. + :type name: str + :param timestamp: Start of aggregation period. The date conforms to the + following format: `yyyy-MM-ddTHH:mm:ssZ` as specified by the ISO 8601 + standard. + :type timestamp: datetime + :param interval: Length of aggregation period. Interval must be multiple + of 15 minutes and may not be zero. The value should be in ISO 8601 format + (http://en.wikipedia.org/wiki/ISO_8601#Durations). + :type interval: str + :param country: Country to which this record data is related. + :type country: str + :param region: Country region to which this record data is related. + :type region: str + :param zip: Zip code to which this record data is related. + :type zip: str + :ivar user_id: User identifier path. /users/{userId} + :vartype user_id: str + :ivar product_id: Product identifier path. /products/{productId} + :vartype product_id: str + :param api_id: API identifier path. /apis/{apiId} + :type api_id: str + :param operation_id: Operation identifier path. + /apis/{apiId}/operations/{operationId} + :type operation_id: str + :param api_region: API region identifier. + :type api_region: str + :param subscription_id: Subscription identifier path. + /subscriptions/{subscriptionId} + :type subscription_id: str + :param call_count_success: Number of successful calls. This includes calls + returning HttpStatusCode <= 301 and HttpStatusCode.NotModified and + HttpStatusCode.TemporaryRedirect + :type call_count_success: int + :param call_count_blocked: Number of calls blocked due to invalid + credentials. This includes calls returning HttpStatusCode.Unauthorized and + HttpStatusCode.Forbidden and HttpStatusCode.TooManyRequests + :type call_count_blocked: int + :param call_count_failed: Number of calls failed due to proxy or backend + errors. This includes calls returning HttpStatusCode.BadRequest(400) and + any Code between HttpStatusCode.InternalServerError (500) and 600 + :type call_count_failed: int + :param call_count_other: Number of other calls. + :type call_count_other: int + :param call_count_total: Total number of calls. + :type call_count_total: int + :param bandwidth: Bandwidth consumed. + :type bandwidth: long + :param cache_hit_count: Number of times when content was served from cache + policy. + :type cache_hit_count: int + :param cache_miss_count: Number of times content was fetched from backend. + :type cache_miss_count: int + :param api_time_avg: Average time it took to process request. + :type api_time_avg: float + :param api_time_min: Minimum time it took to process request. + :type api_time_min: float + :param api_time_max: Maximum time it took to process request. + :type api_time_max: float + :param service_time_avg: Average time it took to process request on + backend. + :type service_time_avg: float + :param service_time_min: Minimum time it took to process request on + backend. + :type service_time_min: float + :param service_time_max: Maximum time it took to process request on + backend. + :type service_time_max: float + """ + + _validation = { + 'user_id': {'readonly': True}, + 'product_id': {'readonly': True}, + } + + _attribute_map = { + 'name': {'key': 'name', 'type': 'str'}, + 'timestamp': {'key': 'timestamp', 'type': 'iso-8601'}, + 'interval': {'key': 'interval', 'type': 'str'}, + 'country': {'key': 'country', 'type': 'str'}, + 'region': {'key': 'region', 'type': 'str'}, + 'zip': {'key': 'zip', 'type': 'str'}, + 'user_id': {'key': 'userId', 'type': 'str'}, + 'product_id': {'key': 'productId', 'type': 'str'}, + 'api_id': {'key': 'apiId', 'type': 'str'}, + 'operation_id': {'key': 'operationId', 'type': 'str'}, + 'api_region': {'key': 'apiRegion', 'type': 'str'}, + 'subscription_id': {'key': 'subscriptionId', 'type': 'str'}, + 'call_count_success': {'key': 'callCountSuccess', 'type': 'int'}, + 'call_count_blocked': {'key': 'callCountBlocked', 'type': 'int'}, + 'call_count_failed': {'key': 'callCountFailed', 'type': 'int'}, + 'call_count_other': {'key': 'callCountOther', 'type': 'int'}, + 'call_count_total': {'key': 'callCountTotal', 'type': 'int'}, + 'bandwidth': {'key': 'bandwidth', 'type': 'long'}, + 'cache_hit_count': {'key': 'cacheHitCount', 'type': 'int'}, + 'cache_miss_count': {'key': 'cacheMissCount', 'type': 'int'}, + 'api_time_avg': {'key': 'apiTimeAvg', 'type': 'float'}, + 'api_time_min': {'key': 'apiTimeMin', 'type': 'float'}, + 'api_time_max': {'key': 'apiTimeMax', 'type': 'float'}, + 'service_time_avg': {'key': 'serviceTimeAvg', 'type': 'float'}, + 'service_time_min': {'key': 'serviceTimeMin', 'type': 'float'}, + 'service_time_max': {'key': 'serviceTimeMax', 'type': 'float'}, + } + + def __init__(self, **kwargs): + super(ReportRecordContract, self).__init__(**kwargs) + self.name = kwargs.get('name', None) + self.timestamp = kwargs.get('timestamp', None) + self.interval = kwargs.get('interval', None) + self.country = kwargs.get('country', None) + self.region = kwargs.get('region', None) + self.zip = kwargs.get('zip', None) + self.user_id = None + self.product_id = None + self.api_id = kwargs.get('api_id', None) + self.operation_id = kwargs.get('operation_id', None) + self.api_region = kwargs.get('api_region', None) + self.subscription_id = kwargs.get('subscription_id', None) + self.call_count_success = kwargs.get('call_count_success', None) + self.call_count_blocked = kwargs.get('call_count_blocked', None) + self.call_count_failed = kwargs.get('call_count_failed', None) + self.call_count_other = kwargs.get('call_count_other', None) + self.call_count_total = kwargs.get('call_count_total', None) + self.bandwidth = kwargs.get('bandwidth', None) + self.cache_hit_count = kwargs.get('cache_hit_count', None) + self.cache_miss_count = kwargs.get('cache_miss_count', None) + self.api_time_avg = kwargs.get('api_time_avg', None) + self.api_time_min = kwargs.get('api_time_min', None) + self.api_time_max = kwargs.get('api_time_max', None) + self.service_time_avg = kwargs.get('service_time_avg', None) + self.service_time_min = kwargs.get('service_time_min', None) + self.service_time_max = kwargs.get('service_time_max', None) + + +class RepresentationContract(Model): + """Operation request/response representation details. + + All required parameters must be populated in order to send to Azure. + + :param content_type: Required. Specifies a registered or custom content + type for this representation, e.g. application/xml. + :type content_type: str + :param sample: An example of the representation. + :type sample: str + :param schema_id: Schema identifier. Applicable only if 'contentType' + value is neither 'application/x-www-form-urlencoded' nor + 'multipart/form-data'. + :type schema_id: str + :param type_name: Type name defined by the schema. Applicable only if + 'contentType' value is neither 'application/x-www-form-urlencoded' nor + 'multipart/form-data'. + :type type_name: str + :param form_parameters: Collection of form parameters. Required if + 'contentType' value is either 'application/x-www-form-urlencoded' or + 'multipart/form-data'.. + :type form_parameters: + list[~azure.mgmt.apimanagement.models.ParameterContract] + """ + + _validation = { + 'content_type': {'required': True}, + } + + _attribute_map = { + 'content_type': {'key': 'contentType', 'type': 'str'}, + 'sample': {'key': 'sample', 'type': 'str'}, + 'schema_id': {'key': 'schemaId', 'type': 'str'}, + 'type_name': {'key': 'typeName', 'type': 'str'}, + 'form_parameters': {'key': 'formParameters', 'type': '[ParameterContract]'}, + } + + def __init__(self, **kwargs): + super(RepresentationContract, self).__init__(**kwargs) + self.content_type = kwargs.get('content_type', None) + self.sample = kwargs.get('sample', None) + self.schema_id = kwargs.get('schema_id', None) + self.type_name = kwargs.get('type_name', None) + self.form_parameters = kwargs.get('form_parameters', None) + + +class RequestContract(Model): + """Operation request details. + + :param description: Operation request description. + :type description: str + :param query_parameters: Collection of operation request query parameters. + :type query_parameters: + list[~azure.mgmt.apimanagement.models.ParameterContract] + :param headers: Collection of operation request headers. + :type headers: list[~azure.mgmt.apimanagement.models.ParameterContract] + :param representations: Collection of operation request representations. + :type representations: + list[~azure.mgmt.apimanagement.models.RepresentationContract] + """ + + _attribute_map = { + 'description': {'key': 'description', 'type': 'str'}, + 'query_parameters': {'key': 'queryParameters', 'type': '[ParameterContract]'}, + 'headers': {'key': 'headers', 'type': '[ParameterContract]'}, + 'representations': {'key': 'representations', 'type': '[RepresentationContract]'}, + } + + def __init__(self, **kwargs): + super(RequestContract, self).__init__(**kwargs) + self.description = kwargs.get('description', None) + self.query_parameters = kwargs.get('query_parameters', None) + self.headers = kwargs.get('headers', None) + self.representations = kwargs.get('representations', None) + + +class RequestReportRecordContract(Model): + """Request Report data. + + Variables are only populated by the server, and will be ignored when + sending a request. + + :param api_id: API identifier path. /apis/{apiId} + :type api_id: str + :param operation_id: Operation identifier path. + /apis/{apiId}/operations/{operationId} + :type operation_id: str + :ivar product_id: Product identifier path. /products/{productId} + :vartype product_id: str + :ivar user_id: User identifier path. /users/{userId} + :vartype user_id: str + :param method: The HTTP method associated with this request.. + :type method: str + :param url: The full URL associated with this request. + :type url: str + :param ip_address: The client IP address associated with this request. + :type ip_address: str + :param backend_response_code: The HTTP status code received by the gateway + as a result of forwarding this request to the backend. + :type backend_response_code: str + :param response_code: The HTTP status code returned by the gateway. + :type response_code: int + :param response_size: The size of the response returned by the gateway. + :type response_size: int + :param timestamp: The date and time when this request was received by the + gateway in ISO 8601 format. + :type timestamp: datetime + :param cache: Specifies if response cache was involved in generating the + response. If the value is none, the cache was not used. If the value is + hit, cached response was returned. If the value is miss, the cache was + used but lookup resulted in a miss and request was fulfilled by the + backend. + :type cache: str + :param api_time: The total time it took to process this request. + :type api_time: float + :param service_time: he time it took to forward this request to the + backend and get the response back. + :type service_time: float + :param api_region: Azure region where the gateway that processed this + request is located. + :type api_region: str + :param subscription_id: Subscription identifier path. + /subscriptions/{subscriptionId} + :type subscription_id: str + :param request_id: Request Identifier. + :type request_id: str + :param request_size: The size of this request.. + :type request_size: int + """ + + _validation = { + 'product_id': {'readonly': True}, + 'user_id': {'readonly': True}, + } + + _attribute_map = { + 'api_id': {'key': 'apiId', 'type': 'str'}, + 'operation_id': {'key': 'operationId', 'type': 'str'}, + 'product_id': {'key': 'productId', 'type': 'str'}, + 'user_id': {'key': 'userId', 'type': 'str'}, + 'method': {'key': 'method', 'type': 'str'}, + 'url': {'key': 'url', 'type': 'str'}, + 'ip_address': {'key': 'ipAddress', 'type': 'str'}, + 'backend_response_code': {'key': 'backendResponseCode', 'type': 'str'}, + 'response_code': {'key': 'responseCode', 'type': 'int'}, + 'response_size': {'key': 'responseSize', 'type': 'int'}, + 'timestamp': {'key': 'timestamp', 'type': 'iso-8601'}, + 'cache': {'key': 'cache', 'type': 'str'}, + 'api_time': {'key': 'apiTime', 'type': 'float'}, + 'service_time': {'key': 'serviceTime', 'type': 'float'}, + 'api_region': {'key': 'apiRegion', 'type': 'str'}, + 'subscription_id': {'key': 'subscriptionId', 'type': 'str'}, + 'request_id': {'key': 'requestId', 'type': 'str'}, + 'request_size': {'key': 'requestSize', 'type': 'int'}, + } + + def __init__(self, **kwargs): + super(RequestReportRecordContract, self).__init__(**kwargs) + self.api_id = kwargs.get('api_id', None) + self.operation_id = kwargs.get('operation_id', None) + self.product_id = None + self.user_id = None + self.method = kwargs.get('method', None) + self.url = kwargs.get('url', None) + self.ip_address = kwargs.get('ip_address', None) + self.backend_response_code = kwargs.get('backend_response_code', None) + self.response_code = kwargs.get('response_code', None) + self.response_size = kwargs.get('response_size', None) + self.timestamp = kwargs.get('timestamp', None) + self.cache = kwargs.get('cache', None) + self.api_time = kwargs.get('api_time', None) + self.service_time = kwargs.get('service_time', None) + self.api_region = kwargs.get('api_region', None) + self.subscription_id = kwargs.get('subscription_id', None) + self.request_id = kwargs.get('request_id', None) + self.request_size = kwargs.get('request_size', None) + + +class ResourceSku(Model): + """Describes an available API Management SKU. + + :param name: Name of the Sku. Possible values include: 'Developer', + 'Standard', 'Premium', 'Basic', 'Consumption' + :type name: str or ~azure.mgmt.apimanagement.models.SkuType + """ + + _attribute_map = { + 'name': {'key': 'name', 'type': 'str'}, + } + + def __init__(self, **kwargs): + super(ResourceSku, self).__init__(**kwargs) + self.name = kwargs.get('name', None) + + +class ResourceSkuCapacity(Model): + """Describes scaling information of a SKU. + + Variables are only populated by the server, and will be ignored when + sending a request. + + :ivar minimum: The minimum capacity. + :vartype minimum: int + :ivar maximum: The maximum capacity that can be set. + :vartype maximum: int + :ivar default: The default capacity. + :vartype default: int + :ivar scale_type: The scale type applicable to the sku. Possible values + include: 'automatic', 'manual', 'none' + :vartype scale_type: str or + ~azure.mgmt.apimanagement.models.ResourceSkuCapacityScaleType + """ + + _validation = { + 'minimum': {'readonly': True}, + 'maximum': {'readonly': True}, + 'default': {'readonly': True}, + 'scale_type': {'readonly': True}, + } + + _attribute_map = { + 'minimum': {'key': 'minimum', 'type': 'int'}, + 'maximum': {'key': 'maximum', 'type': 'int'}, + 'default': {'key': 'default', 'type': 'int'}, + 'scale_type': {'key': 'scaleType', 'type': 'str'}, + } + + def __init__(self, **kwargs): + super(ResourceSkuCapacity, self).__init__(**kwargs) + self.minimum = None + self.maximum = None + self.default = None + self.scale_type = None + + +class ResourceSkuResult(Model): + """Describes an available API Management service SKU. + + Variables are only populated by the server, and will be ignored when + sending a request. + + :ivar resource_type: The type of resource the SKU applies to. + :vartype resource_type: str + :ivar sku: Specifies API Management SKU. + :vartype sku: ~azure.mgmt.apimanagement.models.ResourceSku + :ivar capacity: Specifies the number of API Management units. + :vartype capacity: ~azure.mgmt.apimanagement.models.ResourceSkuCapacity + """ + + _validation = { + 'resource_type': {'readonly': True}, + 'sku': {'readonly': True}, + 'capacity': {'readonly': True}, + } + + _attribute_map = { + 'resource_type': {'key': 'resourceType', 'type': 'str'}, + 'sku': {'key': 'sku', 'type': 'ResourceSku'}, + 'capacity': {'key': 'capacity', 'type': 'ResourceSkuCapacity'}, + } + + def __init__(self, **kwargs): + super(ResourceSkuResult, self).__init__(**kwargs) + self.resource_type = None + self.sku = None + self.capacity = None + + +class ResponseContract(Model): + """Operation response details. + + All required parameters must be populated in order to send to Azure. + + :param status_code: Required. Operation response HTTP status code. + :type status_code: int + :param description: Operation response description. + :type description: str + :param representations: Collection of operation response representations. + :type representations: + list[~azure.mgmt.apimanagement.models.RepresentationContract] + :param headers: Collection of operation response headers. + :type headers: list[~azure.mgmt.apimanagement.models.ParameterContract] + """ + + _validation = { + 'status_code': {'required': True}, + } + + _attribute_map = { + 'status_code': {'key': 'statusCode', 'type': 'int'}, + 'description': {'key': 'description', 'type': 'str'}, + 'representations': {'key': 'representations', 'type': '[RepresentationContract]'}, + 'headers': {'key': 'headers', 'type': '[ParameterContract]'}, + } + + def __init__(self, **kwargs): + super(ResponseContract, self).__init__(**kwargs) + self.status_code = kwargs.get('status_code', None) + self.description = kwargs.get('description', None) + self.representations = kwargs.get('representations', None) + self.headers = kwargs.get('headers', None) + + +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) + + +class SaveConfigurationParameter(Model): + """Save Tenant Configuration Contract details. + + All required parameters must be populated in order to send to Azure. + + :param branch: Required. The name of the Git branch in which to commit the + current configuration snapshot. + :type branch: str + :param force: The value if true, the current configuration database is + committed to the Git repository, even if the Git repository has newer + changes that would be overwritten. + :type force: bool + """ + + _validation = { + 'branch': {'required': True}, + } + + _attribute_map = { + 'branch': {'key': 'properties.branch', 'type': 'str'}, + 'force': {'key': 'properties.force', 'type': 'bool'}, + } + + def __init__(self, **kwargs): + super(SaveConfigurationParameter, self).__init__(**kwargs) + self.branch = kwargs.get('branch', None) + self.force = kwargs.get('force', None) + + +class SchemaContract(Resource): + """Schema Contract details. + + Variables are only populated by the server, and will be ignored when + sending a request. + + All required parameters must be populated in order to send to Azure. + + :ivar id: Resource ID. + :vartype id: str + :ivar name: Resource name. + :vartype name: str + :ivar type: Resource type for API Management resource. + :vartype type: str + :param content_type: Required. Must be a valid a media type used in a + Content-Type header as defined in the RFC 2616. Media type of the schema + document (e.g. application/json, application/xml).
- `Swagger` + Schema use `application/vnd.ms-azure-apim.swagger.definitions+json`
+ - `WSDL` Schema use `application/vnd.ms-azure-apim.xsd+xml`
- + `OpenApi` Schema use `application/vnd.oai.openapi.components+json`
- + `WADL Schema` use `application/vnd.ms-azure-apim.wadl.grammars+xml`. + :type content_type: str + :param value: Json escaped string defining the document representing the + Schema. Used for schemas other than Swagger/OpenAPI. + :type value: str + :param definitions: Types definitions. Used for Swagger/OpenAPI schemas + only, null otherwise. + :type definitions: object + """ + + _validation = { + 'id': {'readonly': True}, + 'name': {'readonly': True}, + 'type': {'readonly': True}, + 'content_type': {'required': True}, + } + + _attribute_map = { + 'id': {'key': 'id', 'type': 'str'}, + 'name': {'key': 'name', 'type': 'str'}, + 'type': {'key': 'type', 'type': 'str'}, + 'content_type': {'key': 'properties.contentType', 'type': 'str'}, + 'value': {'key': 'properties.document.value', 'type': 'str'}, + 'definitions': {'key': 'properties.document.definitions', 'type': 'object'}, + } + + def __init__(self, **kwargs): + super(SchemaContract, self).__init__(**kwargs) + self.content_type = kwargs.get('content_type', None) + self.value = kwargs.get('value', None) + self.definitions = kwargs.get('definitions', None) + + +class SubscriptionContract(Resource): + """Subscription details. + + Variables are only populated by the server, and will be ignored when + sending a request. + + All required parameters must be populated in order to send to Azure. + + :ivar id: Resource ID. + :vartype id: str + :ivar name: Resource name. + :vartype name: str + :ivar type: Resource type for API Management resource. + :vartype type: str + :param owner_id: The user resource identifier of the subscription owner. + The value is a valid relative URL in the format of /users/{userId} where + {userId} is a user identifier. + :type owner_id: str + :param scope: Required. Scope like /products/{productId} or /apis or + /apis/{apiId}. + :type scope: str + :param display_name: The name of the subscription, or null if the + subscription has no name. + :type display_name: str + :param state: Required. Subscription state. Possible states are * active – + the subscription is active, * suspended – the subscription is blocked, and + the subscriber cannot call any APIs of the product, * submitted – the + subscription request has been made by the developer, but has not yet been + approved or rejected, * rejected – the subscription request has been + denied by an administrator, * cancelled – the subscription has been + cancelled by the developer or administrator, * expired – the subscription + reached its expiration date and was deactivated. Possible values include: + 'suspended', 'active', 'expired', 'submitted', 'rejected', 'cancelled' + :type state: str or ~azure.mgmt.apimanagement.models.SubscriptionState + :ivar created_date: Subscription creation date. The date conforms to the + following format: `yyyy-MM-ddTHH:mm:ssZ` as specified by the ISO 8601 + standard. + :vartype created_date: datetime + :param start_date: Subscription activation date. The setting is for audit + purposes only and the subscription is not automatically activated. The + subscription lifecycle can be managed by using the `state` property. The + date conforms to the following format: `yyyy-MM-ddTHH:mm:ssZ` as specified + by the ISO 8601 standard. + :type start_date: datetime + :param expiration_date: Subscription expiration date. The setting is for + audit purposes only and the subscription is not automatically expired. The + subscription lifecycle can be managed by using the `state` property. The + date conforms to the following format: `yyyy-MM-ddTHH:mm:ssZ` as specified + by the ISO 8601 standard. + :type expiration_date: datetime + :param end_date: Date when subscription was cancelled or expired. The + setting is for audit purposes only and the subscription is not + automatically cancelled. The subscription lifecycle can be managed by + using the `state` property. The date conforms to the following format: + `yyyy-MM-ddTHH:mm:ssZ` as specified by the ISO 8601 standard. + :type end_date: datetime + :param notification_date: Upcoming subscription expiration notification + date. The date conforms to the following format: `yyyy-MM-ddTHH:mm:ssZ` as + specified by the ISO 8601 standard. + :type notification_date: datetime + :param primary_key: Subscription primary key. This property will not be + filled on 'GET' operations! Use '/listSecrets' POST request to get the + value. + :type primary_key: str + :param secondary_key: Subscription secondary key. This property will not + be filled on 'GET' operations! Use '/listSecrets' POST request to get the + value. + :type secondary_key: str + :param state_comment: Optional subscription comment added by an + administrator. + :type state_comment: str + :param allow_tracing: Determines whether tracing is enabled + :type allow_tracing: bool + """ + + _validation = { + 'id': {'readonly': True}, + 'name': {'readonly': True}, + 'type': {'readonly': True}, + 'scope': {'required': True}, + 'display_name': {'max_length': 100, 'min_length': 0}, + 'state': {'required': True}, + 'created_date': {'readonly': True}, + 'primary_key': {'max_length': 256, 'min_length': 1}, + 'secondary_key': {'max_length': 256, 'min_length': 1}, + } + + _attribute_map = { + 'id': {'key': 'id', 'type': 'str'}, + 'name': {'key': 'name', 'type': 'str'}, + 'type': {'key': 'type', 'type': 'str'}, + 'owner_id': {'key': 'properties.ownerId', 'type': 'str'}, + 'scope': {'key': 'properties.scope', 'type': 'str'}, + 'display_name': {'key': 'properties.displayName', 'type': 'str'}, + 'state': {'key': 'properties.state', 'type': 'SubscriptionState'}, + 'created_date': {'key': 'properties.createdDate', 'type': 'iso-8601'}, + 'start_date': {'key': 'properties.startDate', 'type': 'iso-8601'}, + 'expiration_date': {'key': 'properties.expirationDate', 'type': 'iso-8601'}, + 'end_date': {'key': 'properties.endDate', 'type': 'iso-8601'}, + 'notification_date': {'key': 'properties.notificationDate', 'type': 'iso-8601'}, + 'primary_key': {'key': 'properties.primaryKey', 'type': 'str'}, + 'secondary_key': {'key': 'properties.secondaryKey', 'type': 'str'}, + 'state_comment': {'key': 'properties.stateComment', 'type': 'str'}, + 'allow_tracing': {'key': 'properties.allowTracing', 'type': 'bool'}, + } + + def __init__(self, **kwargs): + super(SubscriptionContract, self).__init__(**kwargs) + self.owner_id = kwargs.get('owner_id', None) + self.scope = kwargs.get('scope', None) + self.display_name = kwargs.get('display_name', None) + self.state = kwargs.get('state', None) + self.created_date = None + self.start_date = kwargs.get('start_date', None) + self.expiration_date = kwargs.get('expiration_date', None) + self.end_date = kwargs.get('end_date', None) + self.notification_date = kwargs.get('notification_date', None) + self.primary_key = kwargs.get('primary_key', None) + self.secondary_key = kwargs.get('secondary_key', None) + self.state_comment = kwargs.get('state_comment', None) + self.allow_tracing = kwargs.get('allow_tracing', None) + + +class SubscriptionCreateParameters(Model): + """Subscription create details. + + All required parameters must be populated in order to send to Azure. + + :param owner_id: User (user id path) for whom subscription is being + created in form /users/{userId} + :type owner_id: str + :param scope: Required. Scope like /products/{productId} or /apis or + /apis/{apiId}. + :type scope: str + :param display_name: Required. Subscription name. + :type display_name: str + :param primary_key: Primary subscription key. If not specified during + request key will be generated automatically. + :type primary_key: str + :param secondary_key: Secondary subscription key. If not specified during + request key will be generated automatically. + :type secondary_key: str + :param state: Initial subscription state. If no value is specified, + subscription is created with Submitted state. Possible states are * active + – the subscription is active, * suspended – the subscription is blocked, + and the subscriber cannot call any APIs of the product, * submitted – the + subscription request has been made by the developer, but has not yet been + approved or rejected, * rejected – the subscription request has been + denied by an administrator, * cancelled – the subscription has been + cancelled by the developer or administrator, * expired – the subscription + reached its expiration date and was deactivated. Possible values include: + 'suspended', 'active', 'expired', 'submitted', 'rejected', 'cancelled' + :type state: str or ~azure.mgmt.apimanagement.models.SubscriptionState + :param allow_tracing: Determines whether tracing can be enabled + :type allow_tracing: bool + """ + + _validation = { + 'scope': {'required': True}, + 'display_name': {'required': True, 'max_length': 100, 'min_length': 1}, + 'primary_key': {'max_length': 256, 'min_length': 1}, + 'secondary_key': {'max_length': 256, 'min_length': 1}, + } + + _attribute_map = { + 'owner_id': {'key': 'properties.ownerId', 'type': 'str'}, + 'scope': {'key': 'properties.scope', 'type': 'str'}, + 'display_name': {'key': 'properties.displayName', 'type': 'str'}, + 'primary_key': {'key': 'properties.primaryKey', 'type': 'str'}, + 'secondary_key': {'key': 'properties.secondaryKey', 'type': 'str'}, + 'state': {'key': 'properties.state', 'type': 'SubscriptionState'}, + 'allow_tracing': {'key': 'properties.allowTracing', 'type': 'bool'}, + } + + def __init__(self, **kwargs): + super(SubscriptionCreateParameters, self).__init__(**kwargs) + self.owner_id = kwargs.get('owner_id', None) + self.scope = kwargs.get('scope', None) + self.display_name = kwargs.get('display_name', None) + self.primary_key = kwargs.get('primary_key', None) + self.secondary_key = kwargs.get('secondary_key', None) + self.state = kwargs.get('state', None) + self.allow_tracing = kwargs.get('allow_tracing', None) + + +class SubscriptionKeyParameterNamesContract(Model): + """Subscription key parameter names details. + + :param header: Subscription key header name. + :type header: str + :param query: Subscription key query string parameter name. + :type query: str + """ + + _attribute_map = { + 'header': {'key': 'header', 'type': 'str'}, + 'query': {'key': 'query', 'type': 'str'}, + } + + def __init__(self, **kwargs): + super(SubscriptionKeyParameterNamesContract, self).__init__(**kwargs) + self.header = kwargs.get('header', None) + self.query = kwargs.get('query', None) + + +class SubscriptionKeysContract(Model): + """Subscription keys. + + :param primary_key: Subscription primary key. + :type primary_key: str + :param secondary_key: Subscription secondary key. + :type secondary_key: str + """ + + _validation = { + 'primary_key': {'max_length': 256, 'min_length': 1}, + 'secondary_key': {'max_length': 256, 'min_length': 1}, + } + + _attribute_map = { + 'primary_key': {'key': 'primaryKey', 'type': 'str'}, + 'secondary_key': {'key': 'secondaryKey', 'type': 'str'}, + } + + def __init__(self, **kwargs): + super(SubscriptionKeysContract, self).__init__(**kwargs) + self.primary_key = kwargs.get('primary_key', None) + self.secondary_key = kwargs.get('secondary_key', None) + + +class SubscriptionsDelegationSettingsProperties(Model): + """Subscriptions delegation settings properties. + + :param enabled: Enable or disable delegation for subscriptions. + :type enabled: bool + """ + + _attribute_map = { + 'enabled': {'key': 'enabled', 'type': 'bool'}, + } + + def __init__(self, **kwargs): + super(SubscriptionsDelegationSettingsProperties, self).__init__(**kwargs) + self.enabled = kwargs.get('enabled', None) + + +class SubscriptionUpdateParameters(Model): + """Subscription update details. + + :param owner_id: User identifier path: /users/{userId} + :type owner_id: str + :param scope: Scope like /products/{productId} or /apis or /apis/{apiId} + :type scope: str + :param expiration_date: Subscription expiration date. The setting is for + audit purposes only and the subscription is not automatically expired. The + subscription lifecycle can be managed by using the `state` property. The + date conforms to the following format: `yyyy-MM-ddTHH:mm:ssZ` as specified + by the ISO 8601 standard. + :type expiration_date: datetime + :param display_name: Subscription name. + :type display_name: str + :param primary_key: Primary subscription key. + :type primary_key: str + :param secondary_key: Secondary subscription key. + :type secondary_key: str + :param state: Subscription state. Possible states are * active – the + subscription is active, * suspended – the subscription is blocked, and the + subscriber cannot call any APIs of the product, * submitted – the + subscription request has been made by the developer, but has not yet been + approved or rejected, * rejected – the subscription request has been + denied by an administrator, * cancelled – the subscription has been + cancelled by the developer or administrator, * expired – the subscription + reached its expiration date and was deactivated. Possible values include: + 'suspended', 'active', 'expired', 'submitted', 'rejected', 'cancelled' + :type state: str or ~azure.mgmt.apimanagement.models.SubscriptionState + :param state_comment: Comments describing subscription state change by the + administrator. + :type state_comment: str + :param allow_tracing: Determines whether tracing can be enabled + :type allow_tracing: bool + """ + + _validation = { + 'primary_key': {'max_length': 256, 'min_length': 1}, + 'secondary_key': {'max_length': 256, 'min_length': 1}, + } + + _attribute_map = { + 'owner_id': {'key': 'properties.ownerId', 'type': 'str'}, + 'scope': {'key': 'properties.scope', 'type': 'str'}, + 'expiration_date': {'key': 'properties.expirationDate', 'type': 'iso-8601'}, + 'display_name': {'key': 'properties.displayName', 'type': 'str'}, + 'primary_key': {'key': 'properties.primaryKey', 'type': 'str'}, + 'secondary_key': {'key': 'properties.secondaryKey', 'type': 'str'}, + 'state': {'key': 'properties.state', 'type': 'SubscriptionState'}, + 'state_comment': {'key': 'properties.stateComment', 'type': 'str'}, + 'allow_tracing': {'key': 'properties.allowTracing', 'type': 'bool'}, + } + + def __init__(self, **kwargs): + super(SubscriptionUpdateParameters, self).__init__(**kwargs) + self.owner_id = kwargs.get('owner_id', None) + self.scope = kwargs.get('scope', None) + self.expiration_date = kwargs.get('expiration_date', None) + self.display_name = kwargs.get('display_name', None) + self.primary_key = kwargs.get('primary_key', None) + self.secondary_key = kwargs.get('secondary_key', None) + self.state = kwargs.get('state', None) + self.state_comment = kwargs.get('state_comment', None) + self.allow_tracing = kwargs.get('allow_tracing', None) + + +class TagContract(Resource): + """Tag Contract details. + + Variables are only populated by the server, and will be ignored when + sending a request. + + All required parameters must be populated in order to send to Azure. + + :ivar id: Resource ID. + :vartype id: str + :ivar name: Resource name. + :vartype name: str + :ivar type: Resource type for API Management resource. + :vartype type: str + :param display_name: Required. Tag name. + :type display_name: str + """ + + _validation = { + 'id': {'readonly': True}, + 'name': {'readonly': True}, + 'type': {'readonly': True}, + 'display_name': {'required': True, 'max_length': 160, 'min_length': 1}, + } + + _attribute_map = { + 'id': {'key': 'id', 'type': 'str'}, + 'name': {'key': 'name', 'type': 'str'}, + 'type': {'key': 'type', 'type': 'str'}, + 'display_name': {'key': 'properties.displayName', 'type': 'str'}, + } + + def __init__(self, **kwargs): + super(TagContract, self).__init__(**kwargs) + self.display_name = kwargs.get('display_name', None) + + +class TagCreateUpdateParameters(Model): + """Parameters supplied to Create/Update Tag operations. + + All required parameters must be populated in order to send to Azure. + + :param display_name: Required. Tag name. + :type display_name: str + """ + + _validation = { + 'display_name': {'required': True, 'max_length': 160, 'min_length': 1}, + } + + _attribute_map = { + 'display_name': {'key': 'properties.displayName', 'type': 'str'}, + } + + def __init__(self, **kwargs): + super(TagCreateUpdateParameters, self).__init__(**kwargs) + self.display_name = kwargs.get('display_name', None) + + +class TagDescriptionContract(Resource): + """Contract details. + + Variables are only populated by the server, and will be ignored when + sending a request. + + :ivar id: Resource ID. + :vartype id: str + :ivar name: Resource name. + :vartype name: str + :ivar type: Resource type for API Management resource. + :vartype type: str + :param description: Description of the Tag. + :type description: str + :param external_docs_url: Absolute URL of external resources describing + the tag. + :type external_docs_url: str + :param external_docs_description: Description of the external resources + describing the tag. + :type external_docs_description: str + :param tag_id: Identifier of the tag in the form of /tags/{tagId} + :type tag_id: str + :param display_name: Tag name. + :type display_name: str + """ + + _validation = { + 'id': {'readonly': True}, + 'name': {'readonly': True}, + 'type': {'readonly': True}, + 'external_docs_url': {'max_length': 2000}, + 'display_name': {'max_length': 160, 'min_length': 1}, + } + + _attribute_map = { + 'id': {'key': 'id', 'type': 'str'}, + 'name': {'key': 'name', 'type': 'str'}, + 'type': {'key': 'type', 'type': 'str'}, + 'description': {'key': 'properties.description', 'type': 'str'}, + 'external_docs_url': {'key': 'properties.externalDocsUrl', 'type': 'str'}, + 'external_docs_description': {'key': 'properties.externalDocsDescription', 'type': 'str'}, + 'tag_id': {'key': 'properties.tagId', 'type': 'str'}, + 'display_name': {'key': 'properties.displayName', 'type': 'str'}, + } + + def __init__(self, **kwargs): + super(TagDescriptionContract, self).__init__(**kwargs) + self.description = kwargs.get('description', None) + self.external_docs_url = kwargs.get('external_docs_url', None) + self.external_docs_description = kwargs.get('external_docs_description', None) + self.tag_id = kwargs.get('tag_id', None) + self.display_name = kwargs.get('display_name', None) + + +class TagDescriptionCreateParameters(Model): + """Parameters supplied to the Create TagDescription operation. + + :param description: Description of the Tag. + :type description: str + :param external_docs_url: Absolute URL of external resources describing + the tag. + :type external_docs_url: str + :param external_docs_description: Description of the external resources + describing the tag. + :type external_docs_description: str + """ + + _validation = { + 'external_docs_url': {'max_length': 2000}, + } + + _attribute_map = { + 'description': {'key': 'properties.description', 'type': 'str'}, + 'external_docs_url': {'key': 'properties.externalDocsUrl', 'type': 'str'}, + 'external_docs_description': {'key': 'properties.externalDocsDescription', 'type': 'str'}, + } + + def __init__(self, **kwargs): + super(TagDescriptionCreateParameters, self).__init__(**kwargs) + self.description = kwargs.get('description', None) + self.external_docs_url = kwargs.get('external_docs_url', None) + self.external_docs_description = kwargs.get('external_docs_description', None) + + +class TagResourceContract(Model): + """TagResource contract properties. + + All required parameters must be populated in order to send to Azure. + + :param tag: Required. Tag associated with the resource. + :type tag: + ~azure.mgmt.apimanagement.models.TagTagResourceContractProperties + :param api: Api associated with the tag. + :type api: + ~azure.mgmt.apimanagement.models.ApiTagResourceContractProperties + :param operation: Operation associated with the tag. + :type operation: + ~azure.mgmt.apimanagement.models.OperationTagResourceContractProperties + :param product: Product associated with the tag. + :type product: + ~azure.mgmt.apimanagement.models.ProductTagResourceContractProperties + """ + + _validation = { + 'tag': {'required': True}, + } + + _attribute_map = { + 'tag': {'key': 'tag', 'type': 'TagTagResourceContractProperties'}, + 'api': {'key': 'api', 'type': 'ApiTagResourceContractProperties'}, + 'operation': {'key': 'operation', 'type': 'OperationTagResourceContractProperties'}, + 'product': {'key': 'product', 'type': 'ProductTagResourceContractProperties'}, + } + + def __init__(self, **kwargs): + super(TagResourceContract, self).__init__(**kwargs) + self.tag = kwargs.get('tag', None) + self.api = kwargs.get('api', None) + self.operation = kwargs.get('operation', None) + self.product = kwargs.get('product', None) + + +class TagTagResourceContractProperties(Model): + """Contract defining the Tag property in the Tag Resource Contract. + + :param id: Tag identifier + :type id: str + :param name: Tag Name + :type name: str + """ + + _validation = { + 'name': {'max_length': 160, 'min_length': 1}, + } + + _attribute_map = { + 'id': {'key': 'id', 'type': 'str'}, + 'name': {'key': 'name', 'type': 'str'}, + } + + def __init__(self, **kwargs): + super(TagTagResourceContractProperties, self).__init__(**kwargs) + self.id = kwargs.get('id', None) + self.name = kwargs.get('name', None) + + +class TenantConfigurationSyncStateContract(Model): + """Tenant Configuration Synchronization State. + + :param branch: The name of Git branch. + :type branch: str + :param commit_id: The latest commit Id. + :type commit_id: str + :param is_export: value indicating if last sync was save (true) or deploy + (false) operation. + :type is_export: bool + :param is_synced: value indicating if last synchronization was later than + the configuration change. + :type is_synced: bool + :param is_git_enabled: value indicating whether Git configuration access + is enabled. + :type is_git_enabled: bool + :param sync_date: The date of the latest synchronization. The date + conforms to the following format: `yyyy-MM-ddTHH:mm:ssZ` as specified by + the ISO 8601 standard. + :type sync_date: datetime + :param configuration_change_date: The date of the latest configuration + change. The date conforms to the following format: `yyyy-MM-ddTHH:mm:ssZ` + as specified by the ISO 8601 standard. + :type configuration_change_date: datetime + """ + + _attribute_map = { + 'branch': {'key': 'branch', 'type': 'str'}, + 'commit_id': {'key': 'commitId', 'type': 'str'}, + 'is_export': {'key': 'isExport', 'type': 'bool'}, + 'is_synced': {'key': 'isSynced', 'type': 'bool'}, + 'is_git_enabled': {'key': 'isGitEnabled', 'type': 'bool'}, + 'sync_date': {'key': 'syncDate', 'type': 'iso-8601'}, + 'configuration_change_date': {'key': 'configurationChangeDate', 'type': 'iso-8601'}, + } + + def __init__(self, **kwargs): + super(TenantConfigurationSyncStateContract, self).__init__(**kwargs) + self.branch = kwargs.get('branch', None) + self.commit_id = kwargs.get('commit_id', None) + self.is_export = kwargs.get('is_export', None) + self.is_synced = kwargs.get('is_synced', None) + self.is_git_enabled = kwargs.get('is_git_enabled', None) + self.sync_date = kwargs.get('sync_date', None) + self.configuration_change_date = kwargs.get('configuration_change_date', None) + + +class TermsOfServiceProperties(Model): + """Terms of service contract properties. + + :param text: A terms of service text. + :type text: str + :param enabled: Display terms of service during a sign-up process. + :type enabled: bool + :param consent_required: Ask user for consent to the terms of service. + :type consent_required: bool + """ + + _attribute_map = { + 'text': {'key': 'text', 'type': 'str'}, + 'enabled': {'key': 'enabled', 'type': 'bool'}, + 'consent_required': {'key': 'consentRequired', 'type': 'bool'}, + } + + def __init__(self, **kwargs): + super(TermsOfServiceProperties, self).__init__(**kwargs) + self.text = kwargs.get('text', None) + self.enabled = kwargs.get('enabled', None) + self.consent_required = kwargs.get('consent_required', None) + + +class TokenBodyParameterContract(Model): + """OAuth acquire token request body parameter (www-url-form-encoded). + + All required parameters must be populated in order to send to Azure. + + :param name: Required. body parameter name. + :type name: str + :param value: Required. body parameter value. + :type value: str + """ + + _validation = { + 'name': {'required': True}, + 'value': {'required': True}, + } + + _attribute_map = { + 'name': {'key': 'name', 'type': 'str'}, + 'value': {'key': 'value', 'type': 'str'}, + } + + def __init__(self, **kwargs): + super(TokenBodyParameterContract, self).__init__(**kwargs) + self.name = kwargs.get('name', None) + self.value = kwargs.get('value', None) + + +class UserContract(Resource): + """User details. + + Variables are only populated by the server, and will be ignored when + sending a request. + + :ivar id: Resource ID. + :vartype id: str + :ivar name: Resource name. + :vartype name: str + :ivar type: Resource type for API Management resource. + :vartype type: str + :param state: Account state. Specifies whether the user is active or not. + Blocked users are unable to sign into the developer portal or call any + APIs of subscribed products. Default state is Active. Possible values + include: 'active', 'blocked', 'pending', 'deleted'. Default value: + "active" . + :type state: str or ~azure.mgmt.apimanagement.models.UserState + :param note: Optional note about a user set by the administrator. + :type note: str + :param identities: Collection of user identities. + :type identities: + list[~azure.mgmt.apimanagement.models.UserIdentityContract] + :param first_name: First name. + :type first_name: str + :param last_name: Last name. + :type last_name: str + :param email: Email address. + :type email: str + :param registration_date: Date of user registration. The date conforms to + the following format: `yyyy-MM-ddTHH:mm:ssZ` as specified by the ISO 8601 + standard. + :type registration_date: datetime + :ivar groups: Collection of groups user is part of. + :vartype groups: + list[~azure.mgmt.apimanagement.models.GroupContractProperties] + """ + + _validation = { + 'id': {'readonly': True}, + 'name': {'readonly': True}, + 'type': {'readonly': True}, + 'groups': {'readonly': True}, + } + + _attribute_map = { + 'id': {'key': 'id', 'type': 'str'}, + 'name': {'key': 'name', 'type': 'str'}, + 'type': {'key': 'type', 'type': 'str'}, + 'state': {'key': 'properties.state', 'type': 'str'}, + 'note': {'key': 'properties.note', 'type': 'str'}, + 'identities': {'key': 'properties.identities', 'type': '[UserIdentityContract]'}, + 'first_name': {'key': 'properties.firstName', 'type': 'str'}, + 'last_name': {'key': 'properties.lastName', 'type': 'str'}, + 'email': {'key': 'properties.email', 'type': 'str'}, + 'registration_date': {'key': 'properties.registrationDate', 'type': 'iso-8601'}, + 'groups': {'key': 'properties.groups', 'type': '[GroupContractProperties]'}, + } + + def __init__(self, **kwargs): + super(UserContract, self).__init__(**kwargs) + self.state = kwargs.get('state', "active") + self.note = kwargs.get('note', None) + self.identities = kwargs.get('identities', None) + self.first_name = kwargs.get('first_name', None) + self.last_name = kwargs.get('last_name', None) + self.email = kwargs.get('email', None) + self.registration_date = kwargs.get('registration_date', None) + self.groups = None + + +class UserCreateParameters(Model): + """User create details. + + All required parameters must be populated in order to send to Azure. + + :param state: Account state. Specifies whether the user is active or not. + Blocked users are unable to sign into the developer portal or call any + APIs of subscribed products. Default state is Active. Possible values + include: 'active', 'blocked', 'pending', 'deleted'. Default value: + "active" . + :type state: str or ~azure.mgmt.apimanagement.models.UserState + :param note: Optional note about a user set by the administrator. + :type note: str + :param identities: Collection of user identities. + :type identities: + list[~azure.mgmt.apimanagement.models.UserIdentityContract] + :param email: Required. Email address. Must not be empty and must be + unique within the service instance. + :type email: str + :param first_name: Required. First name. + :type first_name: str + :param last_name: Required. Last name. + :type last_name: str + :param password: User Password. If no value is provided, a default + password is generated. + :type password: str + :param confirmation: Determines the type of confirmation e-mail that will + be sent to the newly created user. Possible values include: 'signup', + 'invite' + :type confirmation: str or ~azure.mgmt.apimanagement.models.Confirmation + """ + + _validation = { + 'email': {'required': True, 'max_length': 254, 'min_length': 1}, + 'first_name': {'required': True, 'max_length': 100, 'min_length': 1}, + 'last_name': {'required': True, 'max_length': 100, 'min_length': 1}, + } + + _attribute_map = { + 'state': {'key': 'properties.state', 'type': 'str'}, + 'note': {'key': 'properties.note', 'type': 'str'}, + 'identities': {'key': 'properties.identities', 'type': '[UserIdentityContract]'}, + 'email': {'key': 'properties.email', 'type': 'str'}, + 'first_name': {'key': 'properties.firstName', 'type': 'str'}, + 'last_name': {'key': 'properties.lastName', 'type': 'str'}, + 'password': {'key': 'properties.password', 'type': 'str'}, + 'confirmation': {'key': 'properties.confirmation', 'type': 'str'}, + } + + def __init__(self, **kwargs): + super(UserCreateParameters, self).__init__(**kwargs) + self.state = kwargs.get('state', "active") + self.note = kwargs.get('note', None) + self.identities = kwargs.get('identities', None) + self.email = kwargs.get('email', None) + self.first_name = kwargs.get('first_name', None) + self.last_name = kwargs.get('last_name', None) + self.password = kwargs.get('password', None) + self.confirmation = kwargs.get('confirmation', None) + + +class UserEntityBaseParameters(Model): + """User Entity Base Parameters set. + + :param state: Account state. Specifies whether the user is active or not. + Blocked users are unable to sign into the developer portal or call any + APIs of subscribed products. Default state is Active. Possible values + include: 'active', 'blocked', 'pending', 'deleted'. Default value: + "active" . + :type state: str or ~azure.mgmt.apimanagement.models.UserState + :param note: Optional note about a user set by the administrator. + :type note: str + :param identities: Collection of user identities. + :type identities: + list[~azure.mgmt.apimanagement.models.UserIdentityContract] + """ + + _attribute_map = { + 'state': {'key': 'state', 'type': 'str'}, + 'note': {'key': 'note', 'type': 'str'}, + 'identities': {'key': 'identities', 'type': '[UserIdentityContract]'}, + } + + def __init__(self, **kwargs): + super(UserEntityBaseParameters, self).__init__(**kwargs) + self.state = kwargs.get('state', "active") + self.note = kwargs.get('note', None) + self.identities = kwargs.get('identities', None) + + +class UserIdentityContract(Model): + """User identity details. + + :param provider: Identity provider name. + :type provider: str + :param id: Identifier value within provider. + :type id: str + """ + + _attribute_map = { + 'provider': {'key': 'provider', 'type': 'str'}, + 'id': {'key': 'id', 'type': 'str'}, + } + + def __init__(self, **kwargs): + super(UserIdentityContract, self).__init__(**kwargs) + self.provider = kwargs.get('provider', None) + self.id = kwargs.get('id', None) + + +class UserTokenParameters(Model): + """Get User Token parameters. + + All required parameters must be populated in order to send to Azure. + + :param key_type: Required. The Key to be used to generate token for user. + Possible values include: 'primary', 'secondary'. Default value: "primary" + . + :type key_type: str or ~azure.mgmt.apimanagement.models.KeyType + :param expiry: Required. The Expiry time of the Token. Maximum token + expiry time is set to 30 days. The date conforms to the following format: + `yyyy-MM-ddTHH:mm:ssZ` as specified by the ISO 8601 standard. + :type expiry: datetime + """ + + _validation = { + 'key_type': {'required': True}, + 'expiry': {'required': True}, + } + + _attribute_map = { + 'key_type': {'key': 'properties.keyType', 'type': 'KeyType'}, + 'expiry': {'key': 'properties.expiry', 'type': 'iso-8601'}, + } + + def __init__(self, **kwargs): + super(UserTokenParameters, self).__init__(**kwargs) + self.key_type = kwargs.get('key_type', "primary") + self.expiry = kwargs.get('expiry', None) + + +class UserTokenResult(Model): + """Get User Token response details. + + :param value: Shared Access Authorization token for the User. + :type value: str + """ + + _attribute_map = { + 'value': {'key': 'value', 'type': 'str'}, + } + + def __init__(self, **kwargs): + super(UserTokenResult, self).__init__(**kwargs) + self.value = kwargs.get('value', None) + + +class UserUpdateParameters(Model): + """User update parameters. + + :param state: Account state. Specifies whether the user is active or not. + Blocked users are unable to sign into the developer portal or call any + APIs of subscribed products. Default state is Active. Possible values + include: 'active', 'blocked', 'pending', 'deleted'. Default value: + "active" . + :type state: str or ~azure.mgmt.apimanagement.models.UserState + :param note: Optional note about a user set by the administrator. + :type note: str + :param identities: Collection of user identities. + :type identities: + list[~azure.mgmt.apimanagement.models.UserIdentityContract] + :param email: Email address. Must not be empty and must be unique within + the service instance. + :type email: str + :param password: User Password. + :type password: str + :param first_name: First name. + :type first_name: str + :param last_name: Last name. + :type last_name: str + """ + + _validation = { + 'email': {'max_length': 254, 'min_length': 1}, + 'first_name': {'max_length': 100, 'min_length': 1}, + 'last_name': {'max_length': 100, 'min_length': 1}, + } + + _attribute_map = { + 'state': {'key': 'properties.state', 'type': 'str'}, + 'note': {'key': 'properties.note', 'type': 'str'}, + 'identities': {'key': 'properties.identities', 'type': '[UserIdentityContract]'}, + 'email': {'key': 'properties.email', 'type': 'str'}, + 'password': {'key': 'properties.password', 'type': 'str'}, + 'first_name': {'key': 'properties.firstName', 'type': 'str'}, + 'last_name': {'key': 'properties.lastName', 'type': 'str'}, + } + + def __init__(self, **kwargs): + super(UserUpdateParameters, self).__init__(**kwargs) + self.state = kwargs.get('state', "active") + self.note = kwargs.get('note', None) + self.identities = kwargs.get('identities', None) + self.email = kwargs.get('email', None) + self.password = kwargs.get('password', None) + self.first_name = kwargs.get('first_name', None) + self.last_name = kwargs.get('last_name', None) + + +class VirtualNetworkConfiguration(Model): + """Configuration of a virtual network to which API Management service is + deployed. + + Variables are only populated by the server, and will be ignored when + sending a request. + + :ivar vnetid: The virtual network ID. This is typically a GUID. Expect a + null GUID by default. + :vartype vnetid: str + :ivar subnetname: The name of the subnet. + :vartype subnetname: str + :param subnet_resource_id: The full resource ID of a subnet in a virtual + network to deploy the API Management service in. + :type subnet_resource_id: str + """ + + _validation = { + 'vnetid': {'readonly': True}, + 'subnetname': {'readonly': True}, + 'subnet_resource_id': {'pattern': r'^/subscriptions/[^/]*/resourceGroups/[^/]*/providers/Microsoft.(ClassicNetwork|Network)/virtualNetworks/[^/]*/subnets/[^/]*$'}, + } + + _attribute_map = { + 'vnetid': {'key': 'vnetid', 'type': 'str'}, + 'subnetname': {'key': 'subnetname', 'type': 'str'}, + 'subnet_resource_id': {'key': 'subnetResourceId', 'type': 'str'}, + } + + def __init__(self, **kwargs): + super(VirtualNetworkConfiguration, self).__init__(**kwargs) + self.vnetid = None + self.subnetname = None + self.subnet_resource_id = kwargs.get('subnet_resource_id', None) + + +class X509CertificateName(Model): + """Properties of server X509Names. + + :param name: Common Name of the Certificate. + :type name: str + :param issuer_certificate_thumbprint: Thumbprint for the Issuer of the + Certificate. + :type issuer_certificate_thumbprint: str + """ + + _attribute_map = { + 'name': {'key': 'name', 'type': 'str'}, + 'issuer_certificate_thumbprint': {'key': 'issuerCertificateThumbprint', 'type': 'str'}, + } + + def __init__(self, **kwargs): + super(X509CertificateName, self).__init__(**kwargs) + self.name = kwargs.get('name', None) + self.issuer_certificate_thumbprint = kwargs.get('issuer_certificate_thumbprint', None) diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/_models_py3.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/_models_py3.py new file mode 100644 index 000000000000..e1c0edbcb4ee --- /dev/null +++ b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/_models_py3.py @@ -0,0 +1,7689 @@ +# 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 +from msrest.exceptions import HttpOperationError + + +class AccessInformationContract(Model): + """Tenant access information contract of the API Management service. + + :param id: Identifier. + :type id: str + :param primary_key: Primary access key. This property will not be filled + on 'GET' operations! Use '/listSecrets' POST request to get the value. + :type primary_key: str + :param secondary_key: Secondary access key. This property will not be + filled on 'GET' operations! Use '/listSecrets' POST request to get the + value. + :type secondary_key: str + :param enabled: Determines whether direct access is enabled. + :type enabled: bool + """ + + _attribute_map = { + 'id': {'key': 'id', 'type': 'str'}, + 'primary_key': {'key': 'primaryKey', 'type': 'str'}, + 'secondary_key': {'key': 'secondaryKey', 'type': 'str'}, + 'enabled': {'key': 'enabled', 'type': 'bool'}, + } + + def __init__(self, *, id: str=None, primary_key: str=None, secondary_key: str=None, enabled: bool=None, **kwargs) -> None: + super(AccessInformationContract, self).__init__(**kwargs) + self.id = id + self.primary_key = primary_key + self.secondary_key = secondary_key + self.enabled = enabled + + +class AccessInformationUpdateParameters(Model): + """Tenant access information update parameters. + + :param enabled: Determines whether direct access is enabled. + :type enabled: bool + """ + + _attribute_map = { + 'enabled': {'key': 'properties.enabled', 'type': 'bool'}, + } + + def __init__(self, *, enabled: bool=None, **kwargs) -> None: + super(AccessInformationUpdateParameters, self).__init__(**kwargs) + self.enabled = enabled + + +class AdditionalLocation(Model): + """Description of an additional API Management resource location. + + Variables are only populated by the server, and will be ignored when + sending a request. + + All required parameters must be populated in order to send to Azure. + + :param location: Required. The location name of the additional region + among Azure Data center regions. + :type location: str + :param sku: Required. SKU properties of the API Management service. + :type sku: + ~azure.mgmt.apimanagement.models.ApiManagementServiceSkuProperties + :ivar public_ip_addresses: Public Static Load Balanced IP addresses of the + API Management service in the additional location. Available only for + Basic, Standard and Premium SKU. + :vartype public_ip_addresses: list[str] + :ivar private_ip_addresses: Private Static Load Balanced IP addresses of + the API Management service which is deployed in an Internal Virtual + Network in a particular additional location. Available only for Basic, + Standard and Premium SKU. + :vartype private_ip_addresses: list[str] + :param virtual_network_configuration: Virtual network configuration for + the location. + :type virtual_network_configuration: + ~azure.mgmt.apimanagement.models.VirtualNetworkConfiguration + :ivar gateway_regional_url: Gateway URL of the API Management service in + the Region. + :vartype gateway_regional_url: str + :param disable_gateway: Property only valid for an Api Management service + deployed in multiple locations. This can be used to disable the gateway in + this additional location. Default value: False . + :type disable_gateway: bool + """ + + _validation = { + 'location': {'required': True}, + 'sku': {'required': True}, + 'public_ip_addresses': {'readonly': True}, + 'private_ip_addresses': {'readonly': True}, + 'gateway_regional_url': {'readonly': True}, + } + + _attribute_map = { + 'location': {'key': 'location', 'type': 'str'}, + 'sku': {'key': 'sku', 'type': 'ApiManagementServiceSkuProperties'}, + 'public_ip_addresses': {'key': 'publicIPAddresses', 'type': '[str]'}, + 'private_ip_addresses': {'key': 'privateIPAddresses', 'type': '[str]'}, + 'virtual_network_configuration': {'key': 'virtualNetworkConfiguration', 'type': 'VirtualNetworkConfiguration'}, + 'gateway_regional_url': {'key': 'gatewayRegionalUrl', 'type': 'str'}, + 'disable_gateway': {'key': 'disableGateway', 'type': 'bool'}, + } + + def __init__(self, *, location: str, sku, virtual_network_configuration=None, disable_gateway: bool=False, **kwargs) -> None: + super(AdditionalLocation, self).__init__(**kwargs) + self.location = location + self.sku = sku + self.public_ip_addresses = None + self.private_ip_addresses = None + self.virtual_network_configuration = virtual_network_configuration + self.gateway_regional_url = None + self.disable_gateway = disable_gateway + + +class Resource(Model): + """The Resource definition. + + Variables are only populated by the server, and will be ignored when + sending a request. + + :ivar id: Resource ID. + :vartype id: str + :ivar name: Resource name. + :vartype name: str + :ivar type: Resource type for API Management resource. + :vartype type: str + """ + + _validation = { + 'id': {'readonly': True}, + 'name': {'readonly': True}, + 'type': {'readonly': True}, + } + + _attribute_map = { + 'id': {'key': 'id', 'type': 'str'}, + 'name': {'key': 'name', 'type': 'str'}, + 'type': {'key': 'type', 'type': 'str'}, + } + + def __init__(self, **kwargs) -> None: + super(Resource, self).__init__(**kwargs) + self.id = None + self.name = None + self.type = None + + +class ApiContract(Resource): + """Api details. + + Variables are only populated by the server, and will be ignored when + sending a request. + + All required parameters must be populated in order to send to Azure. + + :ivar id: Resource ID. + :vartype id: str + :ivar name: Resource name. + :vartype name: str + :ivar type: Resource type for API Management resource. + :vartype type: str + :param description: Description of the API. May include HTML formatting + tags. + :type description: str + :param authentication_settings: Collection of authentication settings + included into this API. + :type authentication_settings: + ~azure.mgmt.apimanagement.models.AuthenticationSettingsContract + :param subscription_key_parameter_names: Protocols over which API is made + available. + :type subscription_key_parameter_names: + ~azure.mgmt.apimanagement.models.SubscriptionKeyParameterNamesContract + :param api_type: Type of API. Possible values include: 'http', 'soap' + :type api_type: str or ~azure.mgmt.apimanagement.models.ApiType + :param api_revision: Describes the Revision of the Api. If no value is + provided, default revision 1 is created + :type api_revision: str + :param api_version: Indicates the Version identifier of the API if the API + is versioned + :type api_version: str + :param is_current: Indicates if API revision is current api revision. + :type is_current: bool + :ivar is_online: Indicates if API revision is accessible via the gateway. + :vartype is_online: bool + :param api_revision_description: Description of the Api Revision. + :type api_revision_description: str + :param api_version_description: Description of the Api Version. + :type api_version_description: str + :param api_version_set_id: A resource identifier for the related + ApiVersionSet. + :type api_version_set_id: str + :param subscription_required: Specifies whether an API or Product + subscription is required for accessing the API. + :type subscription_required: bool + :param source_api_id: API identifier of the source API. + :type source_api_id: str + :param display_name: API name. Must be 1 to 300 characters long. + :type display_name: str + :param service_url: Absolute URL of the backend service implementing this + API. Cannot be more than 2000 characters long. + :type service_url: str + :param path: Required. Relative URL uniquely identifying this API and all + of its resource paths within the API Management service instance. It is + appended to the API endpoint base URL specified during the service + instance creation to form a public URL for this API. + :type path: str + :param protocols: Describes on which protocols the operations in this API + can be invoked. + :type protocols: list[str or ~azure.mgmt.apimanagement.models.Protocol] + :param api_version_set: Version set details + :type api_version_set: + ~azure.mgmt.apimanagement.models.ApiVersionSetContractDetails + """ + + _validation = { + 'id': {'readonly': True}, + 'name': {'readonly': True}, + 'type': {'readonly': True}, + 'api_revision': {'max_length': 100, 'min_length': 1}, + 'api_version': {'max_length': 100}, + 'is_online': {'readonly': True}, + 'api_revision_description': {'max_length': 256}, + 'api_version_description': {'max_length': 256}, + 'display_name': {'max_length': 300, 'min_length': 1}, + 'service_url': {'max_length': 2000, 'min_length': 0}, + 'path': {'required': True, 'max_length': 400, 'min_length': 0}, + } + + _attribute_map = { + 'id': {'key': 'id', 'type': 'str'}, + 'name': {'key': 'name', 'type': 'str'}, + 'type': {'key': 'type', 'type': 'str'}, + 'description': {'key': 'properties.description', 'type': 'str'}, + 'authentication_settings': {'key': 'properties.authenticationSettings', 'type': 'AuthenticationSettingsContract'}, + 'subscription_key_parameter_names': {'key': 'properties.subscriptionKeyParameterNames', 'type': 'SubscriptionKeyParameterNamesContract'}, + 'api_type': {'key': 'properties.type', 'type': 'str'}, + 'api_revision': {'key': 'properties.apiRevision', 'type': 'str'}, + 'api_version': {'key': 'properties.apiVersion', 'type': 'str'}, + 'is_current': {'key': 'properties.isCurrent', 'type': 'bool'}, + 'is_online': {'key': 'properties.isOnline', 'type': 'bool'}, + 'api_revision_description': {'key': 'properties.apiRevisionDescription', 'type': 'str'}, + 'api_version_description': {'key': 'properties.apiVersionDescription', 'type': 'str'}, + 'api_version_set_id': {'key': 'properties.apiVersionSetId', 'type': 'str'}, + 'subscription_required': {'key': 'properties.subscriptionRequired', 'type': 'bool'}, + 'source_api_id': {'key': 'properties.sourceApiId', 'type': 'str'}, + 'display_name': {'key': 'properties.displayName', 'type': 'str'}, + 'service_url': {'key': 'properties.serviceUrl', 'type': 'str'}, + 'path': {'key': 'properties.path', 'type': 'str'}, + 'protocols': {'key': 'properties.protocols', 'type': '[Protocol]'}, + 'api_version_set': {'key': 'properties.apiVersionSet', 'type': 'ApiVersionSetContractDetails'}, + } + + def __init__(self, *, path: str, description: str=None, authentication_settings=None, subscription_key_parameter_names=None, api_type=None, api_revision: str=None, api_version: str=None, is_current: bool=None, api_revision_description: str=None, api_version_description: str=None, api_version_set_id: str=None, subscription_required: bool=None, source_api_id: str=None, display_name: str=None, service_url: str=None, protocols=None, api_version_set=None, **kwargs) -> None: + super(ApiContract, self).__init__(**kwargs) + self.description = description + self.authentication_settings = authentication_settings + self.subscription_key_parameter_names = subscription_key_parameter_names + self.api_type = api_type + self.api_revision = api_revision + self.api_version = api_version + self.is_current = is_current + self.is_online = None + self.api_revision_description = api_revision_description + self.api_version_description = api_version_description + self.api_version_set_id = api_version_set_id + self.subscription_required = subscription_required + self.source_api_id = source_api_id + self.display_name = display_name + self.service_url = service_url + self.path = path + self.protocols = protocols + self.api_version_set = api_version_set + + +class ApiEntityBaseContract(Model): + """API base contract details. + + Variables are only populated by the server, and will be ignored when + sending a request. + + :param description: Description of the API. May include HTML formatting + tags. + :type description: str + :param authentication_settings: Collection of authentication settings + included into this API. + :type authentication_settings: + ~azure.mgmt.apimanagement.models.AuthenticationSettingsContract + :param subscription_key_parameter_names: Protocols over which API is made + available. + :type subscription_key_parameter_names: + ~azure.mgmt.apimanagement.models.SubscriptionKeyParameterNamesContract + :param api_type: Type of API. Possible values include: 'http', 'soap' + :type api_type: str or ~azure.mgmt.apimanagement.models.ApiType + :param api_revision: Describes the Revision of the Api. If no value is + provided, default revision 1 is created + :type api_revision: str + :param api_version: Indicates the Version identifier of the API if the API + is versioned + :type api_version: str + :param is_current: Indicates if API revision is current api revision. + :type is_current: bool + :ivar is_online: Indicates if API revision is accessible via the gateway. + :vartype is_online: bool + :param api_revision_description: Description of the Api Revision. + :type api_revision_description: str + :param api_version_description: Description of the Api Version. + :type api_version_description: str + :param api_version_set_id: A resource identifier for the related + ApiVersionSet. + :type api_version_set_id: str + :param subscription_required: Specifies whether an API or Product + subscription is required for accessing the API. + :type subscription_required: bool + """ + + _validation = { + 'api_revision': {'max_length': 100, 'min_length': 1}, + 'api_version': {'max_length': 100}, + 'is_online': {'readonly': True}, + 'api_revision_description': {'max_length': 256}, + 'api_version_description': {'max_length': 256}, + } + + _attribute_map = { + 'description': {'key': 'description', 'type': 'str'}, + 'authentication_settings': {'key': 'authenticationSettings', 'type': 'AuthenticationSettingsContract'}, + 'subscription_key_parameter_names': {'key': 'subscriptionKeyParameterNames', 'type': 'SubscriptionKeyParameterNamesContract'}, + 'api_type': {'key': 'type', 'type': 'str'}, + 'api_revision': {'key': 'apiRevision', 'type': 'str'}, + 'api_version': {'key': 'apiVersion', 'type': 'str'}, + 'is_current': {'key': 'isCurrent', 'type': 'bool'}, + 'is_online': {'key': 'isOnline', 'type': 'bool'}, + 'api_revision_description': {'key': 'apiRevisionDescription', 'type': 'str'}, + 'api_version_description': {'key': 'apiVersionDescription', 'type': 'str'}, + 'api_version_set_id': {'key': 'apiVersionSetId', 'type': 'str'}, + 'subscription_required': {'key': 'subscriptionRequired', 'type': 'bool'}, + } + + def __init__(self, *, description: str=None, authentication_settings=None, subscription_key_parameter_names=None, api_type=None, api_revision: str=None, api_version: str=None, is_current: bool=None, api_revision_description: str=None, api_version_description: str=None, api_version_set_id: str=None, subscription_required: bool=None, **kwargs) -> None: + super(ApiEntityBaseContract, self).__init__(**kwargs) + self.description = description + self.authentication_settings = authentication_settings + self.subscription_key_parameter_names = subscription_key_parameter_names + self.api_type = api_type + self.api_revision = api_revision + self.api_version = api_version + self.is_current = is_current + self.is_online = None + self.api_revision_description = api_revision_description + self.api_version_description = api_version_description + self.api_version_set_id = api_version_set_id + self.subscription_required = subscription_required + + +class ApiContractProperties(ApiEntityBaseContract): + """Api Entity Properties. + + Variables are only populated by the server, and will be ignored when + sending a request. + + All required parameters must be populated in order to send to Azure. + + :param description: Description of the API. May include HTML formatting + tags. + :type description: str + :param authentication_settings: Collection of authentication settings + included into this API. + :type authentication_settings: + ~azure.mgmt.apimanagement.models.AuthenticationSettingsContract + :param subscription_key_parameter_names: Protocols over which API is made + available. + :type subscription_key_parameter_names: + ~azure.mgmt.apimanagement.models.SubscriptionKeyParameterNamesContract + :param api_type: Type of API. Possible values include: 'http', 'soap' + :type api_type: str or ~azure.mgmt.apimanagement.models.ApiType + :param api_revision: Describes the Revision of the Api. If no value is + provided, default revision 1 is created + :type api_revision: str + :param api_version: Indicates the Version identifier of the API if the API + is versioned + :type api_version: str + :param is_current: Indicates if API revision is current api revision. + :type is_current: bool + :ivar is_online: Indicates if API revision is accessible via the gateway. + :vartype is_online: bool + :param api_revision_description: Description of the Api Revision. + :type api_revision_description: str + :param api_version_description: Description of the Api Version. + :type api_version_description: str + :param api_version_set_id: A resource identifier for the related + ApiVersionSet. + :type api_version_set_id: str + :param subscription_required: Specifies whether an API or Product + subscription is required for accessing the API. + :type subscription_required: bool + :param source_api_id: API identifier of the source API. + :type source_api_id: str + :param display_name: API name. Must be 1 to 300 characters long. + :type display_name: str + :param service_url: Absolute URL of the backend service implementing this + API. Cannot be more than 2000 characters long. + :type service_url: str + :param path: Required. Relative URL uniquely identifying this API and all + of its resource paths within the API Management service instance. It is + appended to the API endpoint base URL specified during the service + instance creation to form a public URL for this API. + :type path: str + :param protocols: Describes on which protocols the operations in this API + can be invoked. + :type protocols: list[str or ~azure.mgmt.apimanagement.models.Protocol] + :param api_version_set: Version set details + :type api_version_set: + ~azure.mgmt.apimanagement.models.ApiVersionSetContractDetails + """ + + _validation = { + 'api_revision': {'max_length': 100, 'min_length': 1}, + 'api_version': {'max_length': 100}, + 'is_online': {'readonly': True}, + 'api_revision_description': {'max_length': 256}, + 'api_version_description': {'max_length': 256}, + 'display_name': {'max_length': 300, 'min_length': 1}, + 'service_url': {'max_length': 2000, 'min_length': 0}, + 'path': {'required': True, 'max_length': 400, 'min_length': 0}, + } + + _attribute_map = { + 'description': {'key': 'description', 'type': 'str'}, + 'authentication_settings': {'key': 'authenticationSettings', 'type': 'AuthenticationSettingsContract'}, + 'subscription_key_parameter_names': {'key': 'subscriptionKeyParameterNames', 'type': 'SubscriptionKeyParameterNamesContract'}, + 'api_type': {'key': 'type', 'type': 'str'}, + 'api_revision': {'key': 'apiRevision', 'type': 'str'}, + 'api_version': {'key': 'apiVersion', 'type': 'str'}, + 'is_current': {'key': 'isCurrent', 'type': 'bool'}, + 'is_online': {'key': 'isOnline', 'type': 'bool'}, + 'api_revision_description': {'key': 'apiRevisionDescription', 'type': 'str'}, + 'api_version_description': {'key': 'apiVersionDescription', 'type': 'str'}, + 'api_version_set_id': {'key': 'apiVersionSetId', 'type': 'str'}, + 'subscription_required': {'key': 'subscriptionRequired', 'type': 'bool'}, + 'source_api_id': {'key': 'sourceApiId', 'type': 'str'}, + 'display_name': {'key': 'displayName', 'type': 'str'}, + 'service_url': {'key': 'serviceUrl', 'type': 'str'}, + 'path': {'key': 'path', 'type': 'str'}, + 'protocols': {'key': 'protocols', 'type': '[Protocol]'}, + 'api_version_set': {'key': 'apiVersionSet', 'type': 'ApiVersionSetContractDetails'}, + } + + def __init__(self, *, path: str, description: str=None, authentication_settings=None, subscription_key_parameter_names=None, api_type=None, api_revision: str=None, api_version: str=None, is_current: bool=None, api_revision_description: str=None, api_version_description: str=None, api_version_set_id: str=None, subscription_required: bool=None, source_api_id: str=None, display_name: str=None, service_url: str=None, protocols=None, api_version_set=None, **kwargs) -> None: + super(ApiContractProperties, self).__init__(description=description, authentication_settings=authentication_settings, subscription_key_parameter_names=subscription_key_parameter_names, api_type=api_type, api_revision=api_revision, api_version=api_version, is_current=is_current, api_revision_description=api_revision_description, api_version_description=api_version_description, api_version_set_id=api_version_set_id, subscription_required=subscription_required, **kwargs) + self.source_api_id = source_api_id + self.display_name = display_name + self.service_url = service_url + self.path = path + self.protocols = protocols + self.api_version_set = api_version_set + + +class ApiCreateOrUpdateParameter(Model): + """API Create or Update Parameters. + + Variables are only populated by the server, and will be ignored when + sending a request. + + All required parameters must be populated in order to send to Azure. + + :param description: Description of the API. May include HTML formatting + tags. + :type description: str + :param authentication_settings: Collection of authentication settings + included into this API. + :type authentication_settings: + ~azure.mgmt.apimanagement.models.AuthenticationSettingsContract + :param subscription_key_parameter_names: Protocols over which API is made + available. + :type subscription_key_parameter_names: + ~azure.mgmt.apimanagement.models.SubscriptionKeyParameterNamesContract + :param api_type: Type of API. Possible values include: 'http', 'soap' + :type api_type: str or ~azure.mgmt.apimanagement.models.ApiType + :param api_revision: Describes the Revision of the Api. If no value is + provided, default revision 1 is created + :type api_revision: str + :param api_version: Indicates the Version identifier of the API if the API + is versioned + :type api_version: str + :param is_current: Indicates if API revision is current api revision. + :type is_current: bool + :ivar is_online: Indicates if API revision is accessible via the gateway. + :vartype is_online: bool + :param api_revision_description: Description of the Api Revision. + :type api_revision_description: str + :param api_version_description: Description of the Api Version. + :type api_version_description: str + :param api_version_set_id: A resource identifier for the related + ApiVersionSet. + :type api_version_set_id: str + :param subscription_required: Specifies whether an API or Product + subscription is required for accessing the API. + :type subscription_required: bool + :param source_api_id: API identifier of the source API. + :type source_api_id: str + :param display_name: API name. Must be 1 to 300 characters long. + :type display_name: str + :param service_url: Absolute URL of the backend service implementing this + API. Cannot be more than 2000 characters long. + :type service_url: str + :param path: Required. Relative URL uniquely identifying this API and all + of its resource paths within the API Management service instance. It is + appended to the API endpoint base URL specified during the service + instance creation to form a public URL for this API. + :type path: str + :param protocols: Describes on which protocols the operations in this API + can be invoked. + :type protocols: list[str or ~azure.mgmt.apimanagement.models.Protocol] + :param api_version_set: Version set details + :type api_version_set: + ~azure.mgmt.apimanagement.models.ApiVersionSetContractDetails + :param value: Content value when Importing an API. + :type value: str + :param format: Format of the Content in which the API is getting imported. + Possible values include: 'wadl-xml', 'wadl-link-json', 'swagger-json', + 'swagger-link-json', 'wsdl', 'wsdl-link', 'openapi', 'openapi+json', + 'openapi-link', 'openapi+json-link' + :type format: str or ~azure.mgmt.apimanagement.models.ContentFormat + :param wsdl_selector: Criteria to limit import of WSDL to a subset of the + document. + :type wsdl_selector: + ~azure.mgmt.apimanagement.models.ApiCreateOrUpdatePropertiesWsdlSelector + :param soap_api_type: Type of Api to create. + * `http` creates a SOAP to REST API + * `soap` creates a SOAP pass-through API. Possible values include: + 'SoapToRest', 'SoapPassThrough' + :type soap_api_type: str or ~azure.mgmt.apimanagement.models.SoapApiType + """ + + _validation = { + 'api_revision': {'max_length': 100, 'min_length': 1}, + 'api_version': {'max_length': 100}, + 'is_online': {'readonly': True}, + 'api_revision_description': {'max_length': 256}, + 'api_version_description': {'max_length': 256}, + 'display_name': {'max_length': 300, 'min_length': 1}, + 'service_url': {'max_length': 2000, 'min_length': 0}, + 'path': {'required': True, 'max_length': 400, 'min_length': 0}, + } + + _attribute_map = { + 'description': {'key': 'properties.description', 'type': 'str'}, + 'authentication_settings': {'key': 'properties.authenticationSettings', 'type': 'AuthenticationSettingsContract'}, + 'subscription_key_parameter_names': {'key': 'properties.subscriptionKeyParameterNames', 'type': 'SubscriptionKeyParameterNamesContract'}, + 'api_type': {'key': 'properties.type', 'type': 'str'}, + 'api_revision': {'key': 'properties.apiRevision', 'type': 'str'}, + 'api_version': {'key': 'properties.apiVersion', 'type': 'str'}, + 'is_current': {'key': 'properties.isCurrent', 'type': 'bool'}, + 'is_online': {'key': 'properties.isOnline', 'type': 'bool'}, + 'api_revision_description': {'key': 'properties.apiRevisionDescription', 'type': 'str'}, + 'api_version_description': {'key': 'properties.apiVersionDescription', 'type': 'str'}, + 'api_version_set_id': {'key': 'properties.apiVersionSetId', 'type': 'str'}, + 'subscription_required': {'key': 'properties.subscriptionRequired', 'type': 'bool'}, + 'source_api_id': {'key': 'properties.sourceApiId', 'type': 'str'}, + 'display_name': {'key': 'properties.displayName', 'type': 'str'}, + 'service_url': {'key': 'properties.serviceUrl', 'type': 'str'}, + 'path': {'key': 'properties.path', 'type': 'str'}, + 'protocols': {'key': 'properties.protocols', 'type': '[Protocol]'}, + 'api_version_set': {'key': 'properties.apiVersionSet', 'type': 'ApiVersionSetContractDetails'}, + 'value': {'key': 'properties.value', 'type': 'str'}, + 'format': {'key': 'properties.format', 'type': 'str'}, + 'wsdl_selector': {'key': 'properties.wsdlSelector', 'type': 'ApiCreateOrUpdatePropertiesWsdlSelector'}, + 'soap_api_type': {'key': 'properties.apiType', 'type': 'str'}, + } + + def __init__(self, *, path: str, description: str=None, authentication_settings=None, subscription_key_parameter_names=None, api_type=None, api_revision: str=None, api_version: str=None, is_current: bool=None, api_revision_description: str=None, api_version_description: str=None, api_version_set_id: str=None, subscription_required: bool=None, source_api_id: str=None, display_name: str=None, service_url: str=None, protocols=None, api_version_set=None, value: str=None, format=None, wsdl_selector=None, soap_api_type=None, **kwargs) -> None: + super(ApiCreateOrUpdateParameter, self).__init__(**kwargs) + self.description = description + self.authentication_settings = authentication_settings + self.subscription_key_parameter_names = subscription_key_parameter_names + self.api_type = api_type + self.api_revision = api_revision + self.api_version = api_version + self.is_current = is_current + self.is_online = None + self.api_revision_description = api_revision_description + self.api_version_description = api_version_description + self.api_version_set_id = api_version_set_id + self.subscription_required = subscription_required + self.source_api_id = source_api_id + self.display_name = display_name + self.service_url = service_url + self.path = path + self.protocols = protocols + self.api_version_set = api_version_set + self.value = value + self.format = format + self.wsdl_selector = wsdl_selector + self.soap_api_type = soap_api_type + + +class ApiCreateOrUpdatePropertiesWsdlSelector(Model): + """Criteria to limit import of WSDL to a subset of the document. + + :param wsdl_service_name: Name of service to import from WSDL + :type wsdl_service_name: str + :param wsdl_endpoint_name: Name of endpoint(port) to import from WSDL + :type wsdl_endpoint_name: str + """ + + _attribute_map = { + 'wsdl_service_name': {'key': 'wsdlServiceName', 'type': 'str'}, + 'wsdl_endpoint_name': {'key': 'wsdlEndpointName', 'type': 'str'}, + } + + def __init__(self, *, wsdl_service_name: str=None, wsdl_endpoint_name: str=None, **kwargs) -> None: + super(ApiCreateOrUpdatePropertiesWsdlSelector, self).__init__(**kwargs) + self.wsdl_service_name = wsdl_service_name + self.wsdl_endpoint_name = wsdl_endpoint_name + + +class ApiExportResult(Model): + """API Export result. + + :param id: ResourceId of the API which was exported. + :type id: str + :param export_result_format: Format in which the Api Details are exported + to the Storage Blob with Sas Key valid for 5 minutes. Possible values + include: 'Swagger', 'Wsdl', 'Wadl', 'OpenApi' + :type export_result_format: str or + ~azure.mgmt.apimanagement.models.ExportResultFormat + :param value: The object defining the schema of the exported Api Detail + :type value: ~azure.mgmt.apimanagement.models.ApiExportResultValue + """ + + _attribute_map = { + 'id': {'key': 'id', 'type': 'str'}, + 'export_result_format': {'key': 'format', 'type': 'str'}, + 'value': {'key': 'value', 'type': 'ApiExportResultValue'}, + } + + def __init__(self, *, id: str=None, export_result_format=None, value=None, **kwargs) -> None: + super(ApiExportResult, self).__init__(**kwargs) + self.id = id + self.export_result_format = export_result_format + self.value = value + + +class ApiExportResultValue(Model): + """The object defining the schema of the exported Api Detail. + + :param link: Link to the Storage Blob containing the result of the export + operation. The Blob Uri is only valid for 5 minutes. + :type link: str + """ + + _attribute_map = { + 'link': {'key': 'link', 'type': 'str'}, + } + + def __init__(self, *, link: str=None, **kwargs) -> None: + super(ApiExportResultValue, self).__init__(**kwargs) + self.link = link + + +class ApiManagementServiceApplyNetworkConfigurationParameters(Model): + """Parameter supplied to the Apply Network configuration operation. + + :param location: Location of the Api Management service to update for a + multi-region service. For a service deployed in a single region, this + parameter is not required. + :type location: str + """ + + _attribute_map = { + 'location': {'key': 'location', 'type': 'str'}, + } + + def __init__(self, *, location: str=None, **kwargs) -> None: + super(ApiManagementServiceApplyNetworkConfigurationParameters, self).__init__(**kwargs) + self.location = location + + +class ApiManagementServiceBackupRestoreParameters(Model): + """Parameters supplied to the Backup/Restore of an API Management service + operation. + + All required parameters must be populated in order to send to Azure. + + :param storage_account: Required. Azure Cloud Storage account (used to + place/retrieve the backup) name. + :type storage_account: str + :param access_key: Required. Azure Cloud Storage account (used to + place/retrieve the backup) access key. + :type access_key: str + :param container_name: Required. Azure Cloud Storage blob container name + used to place/retrieve the backup. + :type container_name: str + :param backup_name: Required. The name of the backup file to create. + :type backup_name: str + """ + + _validation = { + 'storage_account': {'required': True}, + 'access_key': {'required': True}, + 'container_name': {'required': True}, + 'backup_name': {'required': True}, + } + + _attribute_map = { + 'storage_account': {'key': 'storageAccount', 'type': 'str'}, + 'access_key': {'key': 'accessKey', 'type': 'str'}, + 'container_name': {'key': 'containerName', 'type': 'str'}, + 'backup_name': {'key': 'backupName', 'type': 'str'}, + } + + def __init__(self, *, storage_account: str, access_key: str, container_name: str, backup_name: str, **kwargs) -> None: + super(ApiManagementServiceBackupRestoreParameters, self).__init__(**kwargs) + self.storage_account = storage_account + self.access_key = access_key + self.container_name = container_name + self.backup_name = backup_name + + +class ApiManagementServiceBaseProperties(Model): + """Base Properties of an API Management service resource description. + + Variables are only populated by the server, and will be ignored when + sending a request. + + :param notification_sender_email: Email address from which the + notification will be sent. + :type notification_sender_email: str + :ivar provisioning_state: The current provisioning state of the API + Management service which can be one of the following: + Created/Activating/Succeeded/Updating/Failed/Stopped/Terminating/TerminationFailed/Deleted. + :vartype provisioning_state: str + :ivar target_provisioning_state: The provisioning state of the API + Management service, which is targeted by the long running operation + started on the service. + :vartype target_provisioning_state: str + :ivar created_at_utc: Creation UTC date of the API Management service.The + date conforms to the following format: `yyyy-MM-ddTHH:mm:ssZ` as specified + by the ISO 8601 standard. + :vartype created_at_utc: datetime + :ivar gateway_url: Gateway URL of the API Management service. + :vartype gateway_url: str + :ivar gateway_regional_url: Gateway URL of the API Management service in + the Default Region. + :vartype gateway_regional_url: str + :ivar portal_url: Publisher portal endpoint Url of the API Management + service. + :vartype portal_url: str + :ivar management_api_url: Management API endpoint URL of the API + Management service. + :vartype management_api_url: str + :ivar scm_url: SCM endpoint URL of the API Management service. + :vartype scm_url: str + :ivar developer_portal_url: DEveloper Portal endpoint URL of the API + Management service. + :vartype developer_portal_url: str + :param hostname_configurations: Custom hostname configuration of the API + Management service. + :type hostname_configurations: + list[~azure.mgmt.apimanagement.models.HostnameConfiguration] + :ivar public_ip_addresses: Public Static Load Balanced IP addresses of the + API Management service in Primary region. Available only for Basic, + Standard and Premium SKU. + :vartype public_ip_addresses: list[str] + :ivar private_ip_addresses: Private Static Load Balanced IP addresses of + the API Management service in Primary region which is deployed in an + Internal Virtual Network. Available only for Basic, Standard and Premium + SKU. + :vartype private_ip_addresses: list[str] + :param virtual_network_configuration: Virtual network configuration of the + API Management service. + :type virtual_network_configuration: + ~azure.mgmt.apimanagement.models.VirtualNetworkConfiguration + :param additional_locations: Additional datacenter locations of the API + Management service. + :type additional_locations: + list[~azure.mgmt.apimanagement.models.AdditionalLocation] + :param custom_properties: Custom properties of the API Management + service.
Setting + `Microsoft.WindowsAzure.ApiManagement.Gateway.Security.Ciphers.TripleDes168` + will disable the cipher TLS_RSA_WITH_3DES_EDE_CBC_SHA for all TLS(1.0, 1.1 + and 1.2).
Setting + `Microsoft.WindowsAzure.ApiManagement.Gateway.Security.Protocols.Tls11` + can be used to disable just TLS 1.1.
Setting + `Microsoft.WindowsAzure.ApiManagement.Gateway.Security.Protocols.Tls10` + can be used to disable TLS 1.0 on an API Management service.
Setting + `Microsoft.WindowsAzure.ApiManagement.Gateway.Security.Backend.Protocols.Tls11` + can be used to disable just TLS 1.1 for communications with + backends.
Setting + `Microsoft.WindowsAzure.ApiManagement.Gateway.Security.Backend.Protocols.Tls10` + can be used to disable TLS 1.0 for communications with + backends.
Setting + `Microsoft.WindowsAzure.ApiManagement.Gateway.Protocols.Server.Http2` can + be used to enable HTTP2 protocol on an API Management service.
Not + specifying any of these properties on PATCH operation will reset omitted + properties' values to their defaults. For all the settings except Http2 + the default value is `True` if the service was created on or before April + 1st 2018 and `False` otherwise. Http2 setting's default value is + `False`.

You can disable any of next ciphers by using settings + `Microsoft.WindowsAzure.ApiManagement.Gateway.Security.Ciphers.[cipher_name]`: + TLS_ECDHE_ECDSA_WITH_AES_256_CBC_SHA, + TLS_ECDHE_ECDSA_WITH_AES_128_CBC_SHA, TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA, + TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA, TLS_RSA_WITH_AES_128_GCM_SHA256, + TLS_RSA_WITH_AES_256_CBC_SHA256, TLS_RSA_WITH_AES_128_CBC_SHA256, + TLS_RSA_WITH_AES_256_CBC_SHA, TLS_RSA_WITH_AES_128_CBC_SHA. For example, + `Microsoft.WindowsAzure.ApiManagement.Gateway.Security.Ciphers.TLS_RSA_WITH_AES_128_CBC_SHA256`:`false`. + The default value is `true` for them. Note: next ciphers can't be + disabled since they are required by Azure CloudService internal + components: + TLS_ECDHE_ECDSA_WITH_AES_256_GCM_SHA384,TLS_ECDHE_ECDSA_WITH_AES_128_GCM_SHA256,TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384,TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256,TLS_ECDHE_ECDSA_WITH_AES_256_CBC_SHA384,TLS_ECDHE_ECDSA_WITH_AES_128_CBC_SHA256,TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA384,TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256,TLS_RSA_WITH_AES_256_GCM_SHA384 + :type custom_properties: dict[str, str] + :param certificates: List of Certificates that need to be installed in the + API Management service. Max supported certificates that can be installed + is 10. + :type certificates: + list[~azure.mgmt.apimanagement.models.CertificateConfiguration] + :param enable_client_certificate: Property only meant to be used for + Consumption SKU Service. This enforces a client certificate to be + presented on each request to the gateway. This also enables the ability to + authenticate the certificate in the policy on the gateway. Default value: + False . + :type enable_client_certificate: bool + :param disable_gateway: Property only valid for an Api Management service + deployed in multiple locations. This can be used to disable the gateway in + master region. Default value: False . + :type disable_gateway: bool + :param virtual_network_type: The type of VPN in which API Management + service needs to be configured in. None (Default Value) means the API + Management service is not part of any Virtual Network, External means the + API Management deployment is set up inside a Virtual Network having an + Internet Facing Endpoint, and Internal means that API Management + deployment is setup inside a Virtual Network having an Intranet Facing + Endpoint only. Possible values include: 'None', 'External', 'Internal'. + Default value: "None" . + :type virtual_network_type: str or + ~azure.mgmt.apimanagement.models.VirtualNetworkType + :param api_version_constraint: Control Plane Apis version constraint for + the API Management service. + :type api_version_constraint: + ~azure.mgmt.apimanagement.models.ApiVersionConstraint + """ + + _validation = { + 'notification_sender_email': {'max_length': 100}, + 'provisioning_state': {'readonly': True}, + 'target_provisioning_state': {'readonly': True}, + 'created_at_utc': {'readonly': True}, + 'gateway_url': {'readonly': True}, + 'gateway_regional_url': {'readonly': True}, + 'portal_url': {'readonly': True}, + 'management_api_url': {'readonly': True}, + 'scm_url': {'readonly': True}, + 'developer_portal_url': {'readonly': True}, + 'public_ip_addresses': {'readonly': True}, + 'private_ip_addresses': {'readonly': True}, + } + + _attribute_map = { + 'notification_sender_email': {'key': 'notificationSenderEmail', 'type': 'str'}, + 'provisioning_state': {'key': 'provisioningState', 'type': 'str'}, + 'target_provisioning_state': {'key': 'targetProvisioningState', 'type': 'str'}, + 'created_at_utc': {'key': 'createdAtUtc', 'type': 'iso-8601'}, + 'gateway_url': {'key': 'gatewayUrl', 'type': 'str'}, + 'gateway_regional_url': {'key': 'gatewayRegionalUrl', 'type': 'str'}, + 'portal_url': {'key': 'portalUrl', 'type': 'str'}, + 'management_api_url': {'key': 'managementApiUrl', 'type': 'str'}, + 'scm_url': {'key': 'scmUrl', 'type': 'str'}, + 'developer_portal_url': {'key': 'developerPortalUrl', 'type': 'str'}, + 'hostname_configurations': {'key': 'hostnameConfigurations', 'type': '[HostnameConfiguration]'}, + 'public_ip_addresses': {'key': 'publicIPAddresses', 'type': '[str]'}, + 'private_ip_addresses': {'key': 'privateIPAddresses', 'type': '[str]'}, + 'virtual_network_configuration': {'key': 'virtualNetworkConfiguration', 'type': 'VirtualNetworkConfiguration'}, + 'additional_locations': {'key': 'additionalLocations', 'type': '[AdditionalLocation]'}, + 'custom_properties': {'key': 'customProperties', 'type': '{str}'}, + 'certificates': {'key': 'certificates', 'type': '[CertificateConfiguration]'}, + 'enable_client_certificate': {'key': 'enableClientCertificate', 'type': 'bool'}, + 'disable_gateway': {'key': 'disableGateway', 'type': 'bool'}, + 'virtual_network_type': {'key': 'virtualNetworkType', 'type': 'str'}, + 'api_version_constraint': {'key': 'apiVersionConstraint', 'type': 'ApiVersionConstraint'}, + } + + def __init__(self, *, notification_sender_email: str=None, hostname_configurations=None, virtual_network_configuration=None, additional_locations=None, custom_properties=None, certificates=None, enable_client_certificate: bool=False, disable_gateway: bool=False, virtual_network_type="None", api_version_constraint=None, **kwargs) -> None: + super(ApiManagementServiceBaseProperties, self).__init__(**kwargs) + self.notification_sender_email = notification_sender_email + self.provisioning_state = None + self.target_provisioning_state = None + self.created_at_utc = None + self.gateway_url = None + self.gateway_regional_url = None + self.portal_url = None + self.management_api_url = None + self.scm_url = None + self.developer_portal_url = None + self.hostname_configurations = hostname_configurations + self.public_ip_addresses = None + self.private_ip_addresses = None + self.virtual_network_configuration = virtual_network_configuration + self.additional_locations = additional_locations + self.custom_properties = custom_properties + self.certificates = certificates + self.enable_client_certificate = enable_client_certificate + self.disable_gateway = disable_gateway + self.virtual_network_type = virtual_network_type + self.api_version_constraint = api_version_constraint + + +class ApiManagementServiceCheckNameAvailabilityParameters(Model): + """Parameters supplied to the CheckNameAvailability operation. + + All required parameters must be populated in order to send to Azure. + + :param name: Required. The name to check for availability. + :type name: str + """ + + _validation = { + 'name': {'required': True}, + } + + _attribute_map = { + 'name': {'key': 'name', 'type': 'str'}, + } + + def __init__(self, *, name: str, **kwargs) -> None: + super(ApiManagementServiceCheckNameAvailabilityParameters, self).__init__(**kwargs) + self.name = name + + +class ApiManagementServiceGetSsoTokenResult(Model): + """The response of the GetSsoToken operation. + + :param redirect_uri: Redirect URL to the Publisher Portal containing the + SSO token. + :type redirect_uri: str + """ + + _attribute_map = { + 'redirect_uri': {'key': 'redirectUri', 'type': 'str'}, + } + + def __init__(self, *, redirect_uri: str=None, **kwargs) -> None: + super(ApiManagementServiceGetSsoTokenResult, self).__init__(**kwargs) + self.redirect_uri = redirect_uri + + +class ApiManagementServiceIdentity(Model): + """Identity properties of the Api Management service resource. + + Variables are only populated by the server, and will be ignored when + sending a request. + + All required parameters must be populated in order to send to Azure. + + :param type: Required. The type of identity used for the resource. The + type 'SystemAssigned, UserAssigned' includes both an implicitly created + identity and a set of user assigned identities. The type 'None' will + remove any identities from the service. Possible values include: + 'SystemAssigned', 'UserAssigned', 'SystemAssigned, UserAssigned', 'None' + :type type: str or ~azure.mgmt.apimanagement.models.ApimIdentityType + :ivar principal_id: The principal id of the identity. + :vartype principal_id: str + :ivar tenant_id: The client tenant id of the identity. + :vartype tenant_id: str + :param user_assigned_identities: + :type user_assigned_identities: dict[str, + ~azure.mgmt.apimanagement.models.ApiManagementServiceIdentityUserAssignedIdentitiesValue] + """ + + _validation = { + 'type': {'required': True}, + 'principal_id': {'readonly': True}, + 'tenant_id': {'readonly': True}, + } + + _attribute_map = { + 'type': {'key': 'type', 'type': 'str'}, + 'principal_id': {'key': 'principalId', 'type': 'str'}, + 'tenant_id': {'key': 'tenantId', 'type': 'str'}, + 'user_assigned_identities': {'key': 'userAssignedIdentities', 'type': '{ApiManagementServiceIdentityUserAssignedIdentitiesValue}'}, + } + + def __init__(self, *, type, user_assigned_identities=None, **kwargs) -> None: + super(ApiManagementServiceIdentity, self).__init__(**kwargs) + self.type = type + self.principal_id = None + self.tenant_id = None + self.user_assigned_identities = user_assigned_identities + + +class ApiManagementServiceIdentityUserAssignedIdentitiesValue(Model): + """ApiManagementServiceIdentityUserAssignedIdentitiesValue. + + Variables are only populated by the server, and will be ignored when + sending a request. + + :ivar principal_id: The principal id of user assigned identity. + :vartype principal_id: str + :ivar client_id: The client id of user assigned identity. + :vartype client_id: str + """ + + _validation = { + 'principal_id': {'readonly': True}, + 'client_id': {'readonly': True}, + } + + _attribute_map = { + 'principal_id': {'key': 'principalId', 'type': 'str'}, + 'client_id': {'key': 'clientId', 'type': 'str'}, + } + + def __init__(self, **kwargs) -> None: + super(ApiManagementServiceIdentityUserAssignedIdentitiesValue, self).__init__(**kwargs) + self.principal_id = None + self.client_id = None + + +class ApiManagementServiceNameAvailabilityResult(Model): + """Response of the CheckNameAvailability operation. + + Variables are only populated by the server, and will be ignored when + sending a request. + + :ivar name_available: True if the name is available and can be used to + create a new API Management service; otherwise false. + :vartype name_available: bool + :ivar message: If reason == invalid, provide the user with the reason why + the given name is invalid, and provide the resource naming requirements so + that the user can select a valid name. If reason == AlreadyExists, explain + that is already in use, and direct them to select a + different name. + :vartype message: str + :param reason: Invalid indicates the name provided does not match the + resource provider’s naming requirements (incorrect length, unsupported + characters, etc.) AlreadyExists indicates that the name is already in use + and is therefore unavailable. Possible values include: 'Valid', 'Invalid', + 'AlreadyExists' + :type reason: str or + ~azure.mgmt.apimanagement.models.NameAvailabilityReason + """ + + _validation = { + 'name_available': {'readonly': True}, + 'message': {'readonly': True}, + } + + _attribute_map = { + 'name_available': {'key': 'nameAvailable', 'type': 'bool'}, + 'message': {'key': 'message', 'type': 'str'}, + 'reason': {'key': 'reason', 'type': 'NameAvailabilityReason'}, + } + + def __init__(self, *, reason=None, **kwargs) -> None: + super(ApiManagementServiceNameAvailabilityResult, self).__init__(**kwargs) + self.name_available = None + self.message = None + self.reason = reason + + +class ApimResource(Model): + """The Resource definition. + + Variables are only populated by the server, and will be ignored when + sending a request. + + :ivar id: Resource ID. + :vartype id: str + :ivar name: Resource name. + :vartype name: str + :ivar type: Resource type for API Management resource is set to + Microsoft.ApiManagement. + :vartype type: str + :param tags: Resource tags. + :type tags: dict[str, str] + """ + + _validation = { + 'id': {'readonly': True}, + 'name': {'readonly': True}, + 'type': {'readonly': True}, + } + + _attribute_map = { + 'id': {'key': 'id', 'type': 'str'}, + 'name': {'key': 'name', 'type': 'str'}, + 'type': {'key': 'type', 'type': 'str'}, + 'tags': {'key': 'tags', 'type': '{str}'}, + } + + def __init__(self, *, tags=None, **kwargs) -> None: + super(ApimResource, self).__init__(**kwargs) + self.id = None + self.name = None + self.type = None + self.tags = tags + + +class ApiManagementServiceResource(ApimResource): + """A single API Management service resource in List or Get response. + + Variables are only populated by the server, and will be ignored when + sending a request. + + All required parameters must be populated in order to send to Azure. + + :ivar id: Resource ID. + :vartype id: str + :ivar name: Resource name. + :vartype name: str + :ivar type: Resource type for API Management resource is set to + Microsoft.ApiManagement. + :vartype type: str + :param tags: Resource tags. + :type tags: dict[str, str] + :param notification_sender_email: Email address from which the + notification will be sent. + :type notification_sender_email: str + :ivar provisioning_state: The current provisioning state of the API + Management service which can be one of the following: + Created/Activating/Succeeded/Updating/Failed/Stopped/Terminating/TerminationFailed/Deleted. + :vartype provisioning_state: str + :ivar target_provisioning_state: The provisioning state of the API + Management service, which is targeted by the long running operation + started on the service. + :vartype target_provisioning_state: str + :ivar created_at_utc: Creation UTC date of the API Management service.The + date conforms to the following format: `yyyy-MM-ddTHH:mm:ssZ` as specified + by the ISO 8601 standard. + :vartype created_at_utc: datetime + :ivar gateway_url: Gateway URL of the API Management service. + :vartype gateway_url: str + :ivar gateway_regional_url: Gateway URL of the API Management service in + the Default Region. + :vartype gateway_regional_url: str + :ivar portal_url: Publisher portal endpoint Url of the API Management + service. + :vartype portal_url: str + :ivar management_api_url: Management API endpoint URL of the API + Management service. + :vartype management_api_url: str + :ivar scm_url: SCM endpoint URL of the API Management service. + :vartype scm_url: str + :ivar developer_portal_url: DEveloper Portal endpoint URL of the API + Management service. + :vartype developer_portal_url: str + :param hostname_configurations: Custom hostname configuration of the API + Management service. + :type hostname_configurations: + list[~azure.mgmt.apimanagement.models.HostnameConfiguration] + :ivar public_ip_addresses: Public Static Load Balanced IP addresses of the + API Management service in Primary region. Available only for Basic, + Standard and Premium SKU. + :vartype public_ip_addresses: list[str] + :ivar private_ip_addresses: Private Static Load Balanced IP addresses of + the API Management service in Primary region which is deployed in an + Internal Virtual Network. Available only for Basic, Standard and Premium + SKU. + :vartype private_ip_addresses: list[str] + :param virtual_network_configuration: Virtual network configuration of the + API Management service. + :type virtual_network_configuration: + ~azure.mgmt.apimanagement.models.VirtualNetworkConfiguration + :param additional_locations: Additional datacenter locations of the API + Management service. + :type additional_locations: + list[~azure.mgmt.apimanagement.models.AdditionalLocation] + :param custom_properties: Custom properties of the API Management + service.
Setting + `Microsoft.WindowsAzure.ApiManagement.Gateway.Security.Ciphers.TripleDes168` + will disable the cipher TLS_RSA_WITH_3DES_EDE_CBC_SHA for all TLS(1.0, 1.1 + and 1.2).
Setting + `Microsoft.WindowsAzure.ApiManagement.Gateway.Security.Protocols.Tls11` + can be used to disable just TLS 1.1.
Setting + `Microsoft.WindowsAzure.ApiManagement.Gateway.Security.Protocols.Tls10` + can be used to disable TLS 1.0 on an API Management service.
Setting + `Microsoft.WindowsAzure.ApiManagement.Gateway.Security.Backend.Protocols.Tls11` + can be used to disable just TLS 1.1 for communications with + backends.
Setting + `Microsoft.WindowsAzure.ApiManagement.Gateway.Security.Backend.Protocols.Tls10` + can be used to disable TLS 1.0 for communications with + backends.
Setting + `Microsoft.WindowsAzure.ApiManagement.Gateway.Protocols.Server.Http2` can + be used to enable HTTP2 protocol on an API Management service.
Not + specifying any of these properties on PATCH operation will reset omitted + properties' values to their defaults. For all the settings except Http2 + the default value is `True` if the service was created on or before April + 1st 2018 and `False` otherwise. Http2 setting's default value is + `False`.

You can disable any of next ciphers by using settings + `Microsoft.WindowsAzure.ApiManagement.Gateway.Security.Ciphers.[cipher_name]`: + TLS_ECDHE_ECDSA_WITH_AES_256_CBC_SHA, + TLS_ECDHE_ECDSA_WITH_AES_128_CBC_SHA, TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA, + TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA, TLS_RSA_WITH_AES_128_GCM_SHA256, + TLS_RSA_WITH_AES_256_CBC_SHA256, TLS_RSA_WITH_AES_128_CBC_SHA256, + TLS_RSA_WITH_AES_256_CBC_SHA, TLS_RSA_WITH_AES_128_CBC_SHA. For example, + `Microsoft.WindowsAzure.ApiManagement.Gateway.Security.Ciphers.TLS_RSA_WITH_AES_128_CBC_SHA256`:`false`. + The default value is `true` for them. Note: next ciphers can't be + disabled since they are required by Azure CloudService internal + components: + TLS_ECDHE_ECDSA_WITH_AES_256_GCM_SHA384,TLS_ECDHE_ECDSA_WITH_AES_128_GCM_SHA256,TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384,TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256,TLS_ECDHE_ECDSA_WITH_AES_256_CBC_SHA384,TLS_ECDHE_ECDSA_WITH_AES_128_CBC_SHA256,TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA384,TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256,TLS_RSA_WITH_AES_256_GCM_SHA384 + :type custom_properties: dict[str, str] + :param certificates: List of Certificates that need to be installed in the + API Management service. Max supported certificates that can be installed + is 10. + :type certificates: + list[~azure.mgmt.apimanagement.models.CertificateConfiguration] + :param enable_client_certificate: Property only meant to be used for + Consumption SKU Service. This enforces a client certificate to be + presented on each request to the gateway. This also enables the ability to + authenticate the certificate in the policy on the gateway. Default value: + False . + :type enable_client_certificate: bool + :param disable_gateway: Property only valid for an Api Management service + deployed in multiple locations. This can be used to disable the gateway in + master region. Default value: False . + :type disable_gateway: bool + :param virtual_network_type: The type of VPN in which API Management + service needs to be configured in. None (Default Value) means the API + Management service is not part of any Virtual Network, External means the + API Management deployment is set up inside a Virtual Network having an + Internet Facing Endpoint, and Internal means that API Management + deployment is setup inside a Virtual Network having an Intranet Facing + Endpoint only. Possible values include: 'None', 'External', 'Internal'. + Default value: "None" . + :type virtual_network_type: str or + ~azure.mgmt.apimanagement.models.VirtualNetworkType + :param api_version_constraint: Control Plane Apis version constraint for + the API Management service. + :type api_version_constraint: + ~azure.mgmt.apimanagement.models.ApiVersionConstraint + :param publisher_email: Required. Publisher email. + :type publisher_email: str + :param publisher_name: Required. Publisher name. + :type publisher_name: str + :param sku: Required. SKU properties of the API Management service. + :type sku: + ~azure.mgmt.apimanagement.models.ApiManagementServiceSkuProperties + :param identity: Managed service identity of the Api Management service. + :type identity: + ~azure.mgmt.apimanagement.models.ApiManagementServiceIdentity + :param location: Required. Resource location. + :type location: str + :ivar etag: ETag of the resource. + :vartype etag: str + """ + + _validation = { + 'id': {'readonly': True}, + 'name': {'readonly': True}, + 'type': {'readonly': True}, + 'notification_sender_email': {'max_length': 100}, + 'provisioning_state': {'readonly': True}, + 'target_provisioning_state': {'readonly': True}, + 'created_at_utc': {'readonly': True}, + 'gateway_url': {'readonly': True}, + 'gateway_regional_url': {'readonly': True}, + 'portal_url': {'readonly': True}, + 'management_api_url': {'readonly': True}, + 'scm_url': {'readonly': True}, + 'developer_portal_url': {'readonly': True}, + 'public_ip_addresses': {'readonly': True}, + 'private_ip_addresses': {'readonly': True}, + 'publisher_email': {'required': True, 'max_length': 100}, + 'publisher_name': {'required': True, 'max_length': 100}, + 'sku': {'required': True}, + 'location': {'required': True}, + 'etag': {'readonly': True}, + } + + _attribute_map = { + 'id': {'key': 'id', 'type': 'str'}, + 'name': {'key': 'name', 'type': 'str'}, + 'type': {'key': 'type', 'type': 'str'}, + 'tags': {'key': 'tags', 'type': '{str}'}, + 'notification_sender_email': {'key': 'properties.notificationSenderEmail', 'type': 'str'}, + 'provisioning_state': {'key': 'properties.provisioningState', 'type': 'str'}, + 'target_provisioning_state': {'key': 'properties.targetProvisioningState', 'type': 'str'}, + 'created_at_utc': {'key': 'properties.createdAtUtc', 'type': 'iso-8601'}, + 'gateway_url': {'key': 'properties.gatewayUrl', 'type': 'str'}, + 'gateway_regional_url': {'key': 'properties.gatewayRegionalUrl', 'type': 'str'}, + 'portal_url': {'key': 'properties.portalUrl', 'type': 'str'}, + 'management_api_url': {'key': 'properties.managementApiUrl', 'type': 'str'}, + 'scm_url': {'key': 'properties.scmUrl', 'type': 'str'}, + 'developer_portal_url': {'key': 'properties.developerPortalUrl', 'type': 'str'}, + 'hostname_configurations': {'key': 'properties.hostnameConfigurations', 'type': '[HostnameConfiguration]'}, + 'public_ip_addresses': {'key': 'properties.publicIPAddresses', 'type': '[str]'}, + 'private_ip_addresses': {'key': 'properties.privateIPAddresses', 'type': '[str]'}, + 'virtual_network_configuration': {'key': 'properties.virtualNetworkConfiguration', 'type': 'VirtualNetworkConfiguration'}, + 'additional_locations': {'key': 'properties.additionalLocations', 'type': '[AdditionalLocation]'}, + 'custom_properties': {'key': 'properties.customProperties', 'type': '{str}'}, + 'certificates': {'key': 'properties.certificates', 'type': '[CertificateConfiguration]'}, + 'enable_client_certificate': {'key': 'properties.enableClientCertificate', 'type': 'bool'}, + 'disable_gateway': {'key': 'properties.disableGateway', 'type': 'bool'}, + 'virtual_network_type': {'key': 'properties.virtualNetworkType', 'type': 'str'}, + 'api_version_constraint': {'key': 'properties.apiVersionConstraint', 'type': 'ApiVersionConstraint'}, + 'publisher_email': {'key': 'properties.publisherEmail', 'type': 'str'}, + 'publisher_name': {'key': 'properties.publisherName', 'type': 'str'}, + 'sku': {'key': 'sku', 'type': 'ApiManagementServiceSkuProperties'}, + 'identity': {'key': 'identity', 'type': 'ApiManagementServiceIdentity'}, + 'location': {'key': 'location', 'type': 'str'}, + 'etag': {'key': 'etag', 'type': 'str'}, + } + + def __init__(self, *, publisher_email: str, publisher_name: str, sku, location: str, tags=None, notification_sender_email: str=None, hostname_configurations=None, virtual_network_configuration=None, additional_locations=None, custom_properties=None, certificates=None, enable_client_certificate: bool=False, disable_gateway: bool=False, virtual_network_type="None", api_version_constraint=None, identity=None, **kwargs) -> None: + super(ApiManagementServiceResource, self).__init__(tags=tags, **kwargs) + self.notification_sender_email = notification_sender_email + self.provisioning_state = None + self.target_provisioning_state = None + self.created_at_utc = None + self.gateway_url = None + self.gateway_regional_url = None + self.portal_url = None + self.management_api_url = None + self.scm_url = None + self.developer_portal_url = None + self.hostname_configurations = hostname_configurations + self.public_ip_addresses = None + self.private_ip_addresses = None + self.virtual_network_configuration = virtual_network_configuration + self.additional_locations = additional_locations + self.custom_properties = custom_properties + self.certificates = certificates + self.enable_client_certificate = enable_client_certificate + self.disable_gateway = disable_gateway + self.virtual_network_type = virtual_network_type + self.api_version_constraint = api_version_constraint + self.publisher_email = publisher_email + self.publisher_name = publisher_name + self.sku = sku + self.identity = identity + self.location = location + self.etag = None + + +class ApiManagementServiceSkuProperties(Model): + """API Management service resource SKU properties. + + All required parameters must be populated in order to send to Azure. + + :param name: Required. Name of the Sku. Possible values include: + 'Developer', 'Standard', 'Premium', 'Basic', 'Consumption' + :type name: str or ~azure.mgmt.apimanagement.models.SkuType + :param capacity: Capacity of the SKU (number of deployed units of the + SKU). + :type capacity: int + """ + + _validation = { + 'name': {'required': True}, + } + + _attribute_map = { + 'name': {'key': 'name', 'type': 'str'}, + 'capacity': {'key': 'capacity', 'type': 'int'}, + } + + def __init__(self, *, name, capacity: int=None, **kwargs) -> None: + super(ApiManagementServiceSkuProperties, self).__init__(**kwargs) + self.name = name + self.capacity = capacity + + +class ApiManagementServiceUpdateParameters(ApimResource): + """Parameter supplied to Update Api Management Service. + + Variables are only populated by the server, and will be ignored when + sending a request. + + :ivar id: Resource ID. + :vartype id: str + :ivar name: Resource name. + :vartype name: str + :ivar type: Resource type for API Management resource is set to + Microsoft.ApiManagement. + :vartype type: str + :param tags: Resource tags. + :type tags: dict[str, str] + :param notification_sender_email: Email address from which the + notification will be sent. + :type notification_sender_email: str + :ivar provisioning_state: The current provisioning state of the API + Management service which can be one of the following: + Created/Activating/Succeeded/Updating/Failed/Stopped/Terminating/TerminationFailed/Deleted. + :vartype provisioning_state: str + :ivar target_provisioning_state: The provisioning state of the API + Management service, which is targeted by the long running operation + started on the service. + :vartype target_provisioning_state: str + :ivar created_at_utc: Creation UTC date of the API Management service.The + date conforms to the following format: `yyyy-MM-ddTHH:mm:ssZ` as specified + by the ISO 8601 standard. + :vartype created_at_utc: datetime + :ivar gateway_url: Gateway URL of the API Management service. + :vartype gateway_url: str + :ivar gateway_regional_url: Gateway URL of the API Management service in + the Default Region. + :vartype gateway_regional_url: str + :ivar portal_url: Publisher portal endpoint Url of the API Management + service. + :vartype portal_url: str + :ivar management_api_url: Management API endpoint URL of the API + Management service. + :vartype management_api_url: str + :ivar scm_url: SCM endpoint URL of the API Management service. + :vartype scm_url: str + :ivar developer_portal_url: DEveloper Portal endpoint URL of the API + Management service. + :vartype developer_portal_url: str + :param hostname_configurations: Custom hostname configuration of the API + Management service. + :type hostname_configurations: + list[~azure.mgmt.apimanagement.models.HostnameConfiguration] + :ivar public_ip_addresses: Public Static Load Balanced IP addresses of the + API Management service in Primary region. Available only for Basic, + Standard and Premium SKU. + :vartype public_ip_addresses: list[str] + :ivar private_ip_addresses: Private Static Load Balanced IP addresses of + the API Management service in Primary region which is deployed in an + Internal Virtual Network. Available only for Basic, Standard and Premium + SKU. + :vartype private_ip_addresses: list[str] + :param virtual_network_configuration: Virtual network configuration of the + API Management service. + :type virtual_network_configuration: + ~azure.mgmt.apimanagement.models.VirtualNetworkConfiguration + :param additional_locations: Additional datacenter locations of the API + Management service. + :type additional_locations: + list[~azure.mgmt.apimanagement.models.AdditionalLocation] + :param custom_properties: Custom properties of the API Management + service.
Setting + `Microsoft.WindowsAzure.ApiManagement.Gateway.Security.Ciphers.TripleDes168` + will disable the cipher TLS_RSA_WITH_3DES_EDE_CBC_SHA for all TLS(1.0, 1.1 + and 1.2).
Setting + `Microsoft.WindowsAzure.ApiManagement.Gateway.Security.Protocols.Tls11` + can be used to disable just TLS 1.1.
Setting + `Microsoft.WindowsAzure.ApiManagement.Gateway.Security.Protocols.Tls10` + can be used to disable TLS 1.0 on an API Management service.
Setting + `Microsoft.WindowsAzure.ApiManagement.Gateway.Security.Backend.Protocols.Tls11` + can be used to disable just TLS 1.1 for communications with + backends.
Setting + `Microsoft.WindowsAzure.ApiManagement.Gateway.Security.Backend.Protocols.Tls10` + can be used to disable TLS 1.0 for communications with + backends.
Setting + `Microsoft.WindowsAzure.ApiManagement.Gateway.Protocols.Server.Http2` can + be used to enable HTTP2 protocol on an API Management service.
Not + specifying any of these properties on PATCH operation will reset omitted + properties' values to their defaults. For all the settings except Http2 + the default value is `True` if the service was created on or before April + 1st 2018 and `False` otherwise. Http2 setting's default value is + `False`.

You can disable any of next ciphers by using settings + `Microsoft.WindowsAzure.ApiManagement.Gateway.Security.Ciphers.[cipher_name]`: + TLS_ECDHE_ECDSA_WITH_AES_256_CBC_SHA, + TLS_ECDHE_ECDSA_WITH_AES_128_CBC_SHA, TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA, + TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA, TLS_RSA_WITH_AES_128_GCM_SHA256, + TLS_RSA_WITH_AES_256_CBC_SHA256, TLS_RSA_WITH_AES_128_CBC_SHA256, + TLS_RSA_WITH_AES_256_CBC_SHA, TLS_RSA_WITH_AES_128_CBC_SHA. For example, + `Microsoft.WindowsAzure.ApiManagement.Gateway.Security.Ciphers.TLS_RSA_WITH_AES_128_CBC_SHA256`:`false`. + The default value is `true` for them. Note: next ciphers can't be + disabled since they are required by Azure CloudService internal + components: + TLS_ECDHE_ECDSA_WITH_AES_256_GCM_SHA384,TLS_ECDHE_ECDSA_WITH_AES_128_GCM_SHA256,TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384,TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256,TLS_ECDHE_ECDSA_WITH_AES_256_CBC_SHA384,TLS_ECDHE_ECDSA_WITH_AES_128_CBC_SHA256,TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA384,TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256,TLS_RSA_WITH_AES_256_GCM_SHA384 + :type custom_properties: dict[str, str] + :param certificates: List of Certificates that need to be installed in the + API Management service. Max supported certificates that can be installed + is 10. + :type certificates: + list[~azure.mgmt.apimanagement.models.CertificateConfiguration] + :param enable_client_certificate: Property only meant to be used for + Consumption SKU Service. This enforces a client certificate to be + presented on each request to the gateway. This also enables the ability to + authenticate the certificate in the policy on the gateway. Default value: + False . + :type enable_client_certificate: bool + :param disable_gateway: Property only valid for an Api Management service + deployed in multiple locations. This can be used to disable the gateway in + master region. Default value: False . + :type disable_gateway: bool + :param virtual_network_type: The type of VPN in which API Management + service needs to be configured in. None (Default Value) means the API + Management service is not part of any Virtual Network, External means the + API Management deployment is set up inside a Virtual Network having an + Internet Facing Endpoint, and Internal means that API Management + deployment is setup inside a Virtual Network having an Intranet Facing + Endpoint only. Possible values include: 'None', 'External', 'Internal'. + Default value: "None" . + :type virtual_network_type: str or + ~azure.mgmt.apimanagement.models.VirtualNetworkType + :param api_version_constraint: Control Plane Apis version constraint for + the API Management service. + :type api_version_constraint: + ~azure.mgmt.apimanagement.models.ApiVersionConstraint + :param publisher_email: Publisher email. + :type publisher_email: str + :param publisher_name: Publisher name. + :type publisher_name: str + :param sku: SKU properties of the API Management service. + :type sku: + ~azure.mgmt.apimanagement.models.ApiManagementServiceSkuProperties + :param identity: Managed service identity of the Api Management service. + :type identity: + ~azure.mgmt.apimanagement.models.ApiManagementServiceIdentity + :ivar etag: ETag of the resource. + :vartype etag: str + """ + + _validation = { + 'id': {'readonly': True}, + 'name': {'readonly': True}, + 'type': {'readonly': True}, + 'notification_sender_email': {'max_length': 100}, + 'provisioning_state': {'readonly': True}, + 'target_provisioning_state': {'readonly': True}, + 'created_at_utc': {'readonly': True}, + 'gateway_url': {'readonly': True}, + 'gateway_regional_url': {'readonly': True}, + 'portal_url': {'readonly': True}, + 'management_api_url': {'readonly': True}, + 'scm_url': {'readonly': True}, + 'developer_portal_url': {'readonly': True}, + 'public_ip_addresses': {'readonly': True}, + 'private_ip_addresses': {'readonly': True}, + 'publisher_email': {'max_length': 100}, + 'publisher_name': {'max_length': 100}, + 'etag': {'readonly': True}, + } + + _attribute_map = { + 'id': {'key': 'id', 'type': 'str'}, + 'name': {'key': 'name', 'type': 'str'}, + 'type': {'key': 'type', 'type': 'str'}, + 'tags': {'key': 'tags', 'type': '{str}'}, + 'notification_sender_email': {'key': 'properties.notificationSenderEmail', 'type': 'str'}, + 'provisioning_state': {'key': 'properties.provisioningState', 'type': 'str'}, + 'target_provisioning_state': {'key': 'properties.targetProvisioningState', 'type': 'str'}, + 'created_at_utc': {'key': 'properties.createdAtUtc', 'type': 'iso-8601'}, + 'gateway_url': {'key': 'properties.gatewayUrl', 'type': 'str'}, + 'gateway_regional_url': {'key': 'properties.gatewayRegionalUrl', 'type': 'str'}, + 'portal_url': {'key': 'properties.portalUrl', 'type': 'str'}, + 'management_api_url': {'key': 'properties.managementApiUrl', 'type': 'str'}, + 'scm_url': {'key': 'properties.scmUrl', 'type': 'str'}, + 'developer_portal_url': {'key': 'properties.developerPortalUrl', 'type': 'str'}, + 'hostname_configurations': {'key': 'properties.hostnameConfigurations', 'type': '[HostnameConfiguration]'}, + 'public_ip_addresses': {'key': 'properties.publicIPAddresses', 'type': '[str]'}, + 'private_ip_addresses': {'key': 'properties.privateIPAddresses', 'type': '[str]'}, + 'virtual_network_configuration': {'key': 'properties.virtualNetworkConfiguration', 'type': 'VirtualNetworkConfiguration'}, + 'additional_locations': {'key': 'properties.additionalLocations', 'type': '[AdditionalLocation]'}, + 'custom_properties': {'key': 'properties.customProperties', 'type': '{str}'}, + 'certificates': {'key': 'properties.certificates', 'type': '[CertificateConfiguration]'}, + 'enable_client_certificate': {'key': 'properties.enableClientCertificate', 'type': 'bool'}, + 'disable_gateway': {'key': 'properties.disableGateway', 'type': 'bool'}, + 'virtual_network_type': {'key': 'properties.virtualNetworkType', 'type': 'str'}, + 'api_version_constraint': {'key': 'properties.apiVersionConstraint', 'type': 'ApiVersionConstraint'}, + 'publisher_email': {'key': 'properties.publisherEmail', 'type': 'str'}, + 'publisher_name': {'key': 'properties.publisherName', 'type': 'str'}, + 'sku': {'key': 'sku', 'type': 'ApiManagementServiceSkuProperties'}, + 'identity': {'key': 'identity', 'type': 'ApiManagementServiceIdentity'}, + 'etag': {'key': 'etag', 'type': 'str'}, + } + + def __init__(self, *, tags=None, notification_sender_email: str=None, hostname_configurations=None, virtual_network_configuration=None, additional_locations=None, custom_properties=None, certificates=None, enable_client_certificate: bool=False, disable_gateway: bool=False, virtual_network_type="None", api_version_constraint=None, publisher_email: str=None, publisher_name: str=None, sku=None, identity=None, **kwargs) -> None: + super(ApiManagementServiceUpdateParameters, self).__init__(tags=tags, **kwargs) + self.notification_sender_email = notification_sender_email + self.provisioning_state = None + self.target_provisioning_state = None + self.created_at_utc = None + self.gateway_url = None + self.gateway_regional_url = None + self.portal_url = None + self.management_api_url = None + self.scm_url = None + self.developer_portal_url = None + self.hostname_configurations = hostname_configurations + self.public_ip_addresses = None + self.private_ip_addresses = None + self.virtual_network_configuration = virtual_network_configuration + self.additional_locations = additional_locations + self.custom_properties = custom_properties + self.certificates = certificates + self.enable_client_certificate = enable_client_certificate + self.disable_gateway = disable_gateway + self.virtual_network_type = virtual_network_type + self.api_version_constraint = api_version_constraint + self.publisher_email = publisher_email + self.publisher_name = publisher_name + self.sku = sku + self.identity = identity + self.etag = None + + +class ApiReleaseContract(Resource): + """ApiRelease details. + + Variables are only populated by the server, and will be ignored when + sending a request. + + :ivar id: Resource ID. + :vartype id: str + :ivar name: Resource name. + :vartype name: str + :ivar type: Resource type for API Management resource. + :vartype type: str + :param api_id: Identifier of the API the release belongs to. + :type api_id: str + :ivar created_date_time: The time the API was released. The date conforms + to the following format: yyyy-MM-ddTHH:mm:ssZ as specified by the ISO 8601 + standard. + :vartype created_date_time: datetime + :ivar updated_date_time: The time the API release was updated. + :vartype updated_date_time: datetime + :param notes: Release Notes + :type notes: str + """ + + _validation = { + 'id': {'readonly': True}, + 'name': {'readonly': True}, + 'type': {'readonly': True}, + 'created_date_time': {'readonly': True}, + 'updated_date_time': {'readonly': True}, + } + + _attribute_map = { + 'id': {'key': 'id', 'type': 'str'}, + 'name': {'key': 'name', 'type': 'str'}, + 'type': {'key': 'type', 'type': 'str'}, + 'api_id': {'key': 'properties.apiId', 'type': 'str'}, + 'created_date_time': {'key': 'properties.createdDateTime', 'type': 'iso-8601'}, + 'updated_date_time': {'key': 'properties.updatedDateTime', 'type': 'iso-8601'}, + 'notes': {'key': 'properties.notes', 'type': 'str'}, + } + + def __init__(self, *, api_id: str=None, notes: str=None, **kwargs) -> None: + super(ApiReleaseContract, self).__init__(**kwargs) + self.api_id = api_id + self.created_date_time = None + self.updated_date_time = None + self.notes = notes + + +class ApiRevisionContract(Model): + """Summary of revision metadata. + + Variables are only populated by the server, and will be ignored when + sending a request. + + :ivar api_id: Identifier of the API Revision. + :vartype api_id: str + :ivar api_revision: Revision number of API. + :vartype api_revision: str + :ivar created_date_time: The time the API Revision was created. The date + conforms to the following format: yyyy-MM-ddTHH:mm:ssZ as specified by the + ISO 8601 standard. + :vartype created_date_time: datetime + :ivar updated_date_time: The time the API Revision were updated. The date + conforms to the following format: yyyy-MM-ddTHH:mm:ssZ as specified by the + ISO 8601 standard. + :vartype updated_date_time: datetime + :ivar description: Description of the API Revision. + :vartype description: str + :ivar private_url: Gateway URL for accessing the non-current API Revision. + :vartype private_url: str + :ivar is_online: Indicates if API revision is the current api revision. + :vartype is_online: bool + :ivar is_current: Indicates if API revision is accessible via the gateway. + :vartype is_current: bool + """ + + _validation = { + 'api_id': {'readonly': True}, + 'api_revision': {'readonly': True, 'max_length': 100, 'min_length': 1}, + 'created_date_time': {'readonly': True}, + 'updated_date_time': {'readonly': True}, + 'description': {'readonly': True, 'max_length': 256}, + 'private_url': {'readonly': True}, + 'is_online': {'readonly': True}, + 'is_current': {'readonly': True}, + } + + _attribute_map = { + 'api_id': {'key': 'apiId', 'type': 'str'}, + 'api_revision': {'key': 'apiRevision', 'type': 'str'}, + 'created_date_time': {'key': 'createdDateTime', 'type': 'iso-8601'}, + 'updated_date_time': {'key': 'updatedDateTime', 'type': 'iso-8601'}, + 'description': {'key': 'description', 'type': 'str'}, + 'private_url': {'key': 'privateUrl', 'type': 'str'}, + 'is_online': {'key': 'isOnline', 'type': 'bool'}, + 'is_current': {'key': 'isCurrent', 'type': 'bool'}, + } + + def __init__(self, **kwargs) -> None: + super(ApiRevisionContract, self).__init__(**kwargs) + self.api_id = None + self.api_revision = None + self.created_date_time = None + self.updated_date_time = None + self.description = None + self.private_url = None + self.is_online = None + self.is_current = None + + +class ApiRevisionInfoContract(Model): + """Object used to create an API Revision or Version based on an existing API + Revision. + + :param source_api_id: Resource identifier of API to be used to create the + revision from. + :type source_api_id: str + :param api_version_name: Version identifier for the new API Version. + :type api_version_name: str + :param api_revision_description: Description of new API Revision. + :type api_revision_description: str + :param api_version_set: Version set details + :type api_version_set: + ~azure.mgmt.apimanagement.models.ApiVersionSetContractDetails + """ + + _validation = { + 'api_version_name': {'max_length': 100}, + 'api_revision_description': {'max_length': 256}, + } + + _attribute_map = { + 'source_api_id': {'key': 'sourceApiId', 'type': 'str'}, + 'api_version_name': {'key': 'apiVersionName', 'type': 'str'}, + 'api_revision_description': {'key': 'apiRevisionDescription', 'type': 'str'}, + 'api_version_set': {'key': 'apiVersionSet', 'type': 'ApiVersionSetContractDetails'}, + } + + def __init__(self, *, source_api_id: str=None, api_version_name: str=None, api_revision_description: str=None, api_version_set=None, **kwargs) -> None: + super(ApiRevisionInfoContract, self).__init__(**kwargs) + self.source_api_id = source_api_id + self.api_version_name = api_version_name + self.api_revision_description = api_revision_description + self.api_version_set = api_version_set + + +class ApiTagResourceContractProperties(ApiEntityBaseContract): + """API contract properties for the Tag Resources. + + Variables are only populated by the server, and will be ignored when + sending a request. + + :param description: Description of the API. May include HTML formatting + tags. + :type description: str + :param authentication_settings: Collection of authentication settings + included into this API. + :type authentication_settings: + ~azure.mgmt.apimanagement.models.AuthenticationSettingsContract + :param subscription_key_parameter_names: Protocols over which API is made + available. + :type subscription_key_parameter_names: + ~azure.mgmt.apimanagement.models.SubscriptionKeyParameterNamesContract + :param api_type: Type of API. Possible values include: 'http', 'soap' + :type api_type: str or ~azure.mgmt.apimanagement.models.ApiType + :param api_revision: Describes the Revision of the Api. If no value is + provided, default revision 1 is created + :type api_revision: str + :param api_version: Indicates the Version identifier of the API if the API + is versioned + :type api_version: str + :param is_current: Indicates if API revision is current api revision. + :type is_current: bool + :ivar is_online: Indicates if API revision is accessible via the gateway. + :vartype is_online: bool + :param api_revision_description: Description of the Api Revision. + :type api_revision_description: str + :param api_version_description: Description of the Api Version. + :type api_version_description: str + :param api_version_set_id: A resource identifier for the related + ApiVersionSet. + :type api_version_set_id: str + :param subscription_required: Specifies whether an API or Product + subscription is required for accessing the API. + :type subscription_required: bool + :param id: API identifier in the form /apis/{apiId}. + :type id: str + :param name: API name. + :type name: str + :param service_url: Absolute URL of the backend service implementing this + API. + :type service_url: str + :param path: Relative URL uniquely identifying this API and all of its + resource paths within the API Management service instance. It is appended + to the API endpoint base URL specified during the service instance + creation to form a public URL for this API. + :type path: str + :param protocols: Describes on which protocols the operations in this API + can be invoked. + :type protocols: list[str or ~azure.mgmt.apimanagement.models.Protocol] + """ + + _validation = { + 'api_revision': {'max_length': 100, 'min_length': 1}, + 'api_version': {'max_length': 100}, + 'is_online': {'readonly': True}, + 'api_revision_description': {'max_length': 256}, + 'api_version_description': {'max_length': 256}, + 'name': {'max_length': 300, 'min_length': 1}, + 'service_url': {'max_length': 2000, 'min_length': 1}, + 'path': {'max_length': 400, 'min_length': 0}, + } + + _attribute_map = { + 'description': {'key': 'description', 'type': 'str'}, + 'authentication_settings': {'key': 'authenticationSettings', 'type': 'AuthenticationSettingsContract'}, + 'subscription_key_parameter_names': {'key': 'subscriptionKeyParameterNames', 'type': 'SubscriptionKeyParameterNamesContract'}, + 'api_type': {'key': 'type', 'type': 'str'}, + 'api_revision': {'key': 'apiRevision', 'type': 'str'}, + 'api_version': {'key': 'apiVersion', 'type': 'str'}, + 'is_current': {'key': 'isCurrent', 'type': 'bool'}, + 'is_online': {'key': 'isOnline', 'type': 'bool'}, + 'api_revision_description': {'key': 'apiRevisionDescription', 'type': 'str'}, + 'api_version_description': {'key': 'apiVersionDescription', 'type': 'str'}, + 'api_version_set_id': {'key': 'apiVersionSetId', 'type': 'str'}, + 'subscription_required': {'key': 'subscriptionRequired', 'type': 'bool'}, + 'id': {'key': 'id', 'type': 'str'}, + 'name': {'key': 'name', 'type': 'str'}, + 'service_url': {'key': 'serviceUrl', 'type': 'str'}, + 'path': {'key': 'path', 'type': 'str'}, + 'protocols': {'key': 'protocols', 'type': '[Protocol]'}, + } + + def __init__(self, *, description: str=None, authentication_settings=None, subscription_key_parameter_names=None, api_type=None, api_revision: str=None, api_version: str=None, is_current: bool=None, api_revision_description: str=None, api_version_description: str=None, api_version_set_id: str=None, subscription_required: bool=None, id: str=None, name: str=None, service_url: str=None, path: str=None, protocols=None, **kwargs) -> None: + super(ApiTagResourceContractProperties, self).__init__(description=description, authentication_settings=authentication_settings, subscription_key_parameter_names=subscription_key_parameter_names, api_type=api_type, api_revision=api_revision, api_version=api_version, is_current=is_current, api_revision_description=api_revision_description, api_version_description=api_version_description, api_version_set_id=api_version_set_id, subscription_required=subscription_required, **kwargs) + self.id = id + self.name = name + self.service_url = service_url + self.path = path + self.protocols = protocols + + +class ApiUpdateContract(Model): + """API update contract details. + + Variables are only populated by the server, and will be ignored when + sending a request. + + :param description: Description of the API. May include HTML formatting + tags. + :type description: str + :param authentication_settings: Collection of authentication settings + included into this API. + :type authentication_settings: + ~azure.mgmt.apimanagement.models.AuthenticationSettingsContract + :param subscription_key_parameter_names: Protocols over which API is made + available. + :type subscription_key_parameter_names: + ~azure.mgmt.apimanagement.models.SubscriptionKeyParameterNamesContract + :param api_type: Type of API. Possible values include: 'http', 'soap' + :type api_type: str or ~azure.mgmt.apimanagement.models.ApiType + :param api_revision: Describes the Revision of the Api. If no value is + provided, default revision 1 is created + :type api_revision: str + :param api_version: Indicates the Version identifier of the API if the API + is versioned + :type api_version: str + :param is_current: Indicates if API revision is current api revision. + :type is_current: bool + :ivar is_online: Indicates if API revision is accessible via the gateway. + :vartype is_online: bool + :param api_revision_description: Description of the Api Revision. + :type api_revision_description: str + :param api_version_description: Description of the Api Version. + :type api_version_description: str + :param api_version_set_id: A resource identifier for the related + ApiVersionSet. + :type api_version_set_id: str + :param subscription_required: Specifies whether an API or Product + subscription is required for accessing the API. + :type subscription_required: bool + :param display_name: API name. + :type display_name: str + :param service_url: Absolute URL of the backend service implementing this + API. + :type service_url: str + :param path: Relative URL uniquely identifying this API and all of its + resource paths within the API Management service instance. It is appended + to the API endpoint base URL specified during the service instance + creation to form a public URL for this API. + :type path: str + :param protocols: Describes on which protocols the operations in this API + can be invoked. + :type protocols: list[str or ~azure.mgmt.apimanagement.models.Protocol] + """ + + _validation = { + 'api_revision': {'max_length': 100, 'min_length': 1}, + 'api_version': {'max_length': 100}, + 'is_online': {'readonly': True}, + 'api_revision_description': {'max_length': 256}, + 'api_version_description': {'max_length': 256}, + 'display_name': {'max_length': 300, 'min_length': 1}, + 'service_url': {'max_length': 2000, 'min_length': 1}, + 'path': {'max_length': 400, 'min_length': 0}, + } + + _attribute_map = { + 'description': {'key': 'properties.description', 'type': 'str'}, + 'authentication_settings': {'key': 'properties.authenticationSettings', 'type': 'AuthenticationSettingsContract'}, + 'subscription_key_parameter_names': {'key': 'properties.subscriptionKeyParameterNames', 'type': 'SubscriptionKeyParameterNamesContract'}, + 'api_type': {'key': 'properties.type', 'type': 'str'}, + 'api_revision': {'key': 'properties.apiRevision', 'type': 'str'}, + 'api_version': {'key': 'properties.apiVersion', 'type': 'str'}, + 'is_current': {'key': 'properties.isCurrent', 'type': 'bool'}, + 'is_online': {'key': 'properties.isOnline', 'type': 'bool'}, + 'api_revision_description': {'key': 'properties.apiRevisionDescription', 'type': 'str'}, + 'api_version_description': {'key': 'properties.apiVersionDescription', 'type': 'str'}, + 'api_version_set_id': {'key': 'properties.apiVersionSetId', 'type': 'str'}, + 'subscription_required': {'key': 'properties.subscriptionRequired', 'type': 'bool'}, + 'display_name': {'key': 'properties.displayName', 'type': 'str'}, + 'service_url': {'key': 'properties.serviceUrl', 'type': 'str'}, + 'path': {'key': 'properties.path', 'type': 'str'}, + 'protocols': {'key': 'properties.protocols', 'type': '[Protocol]'}, + } + + def __init__(self, *, description: str=None, authentication_settings=None, subscription_key_parameter_names=None, api_type=None, api_revision: str=None, api_version: str=None, is_current: bool=None, api_revision_description: str=None, api_version_description: str=None, api_version_set_id: str=None, subscription_required: bool=None, display_name: str=None, service_url: str=None, path: str=None, protocols=None, **kwargs) -> None: + super(ApiUpdateContract, self).__init__(**kwargs) + self.description = description + self.authentication_settings = authentication_settings + self.subscription_key_parameter_names = subscription_key_parameter_names + self.api_type = api_type + self.api_revision = api_revision + self.api_version = api_version + self.is_current = is_current + self.is_online = None + self.api_revision_description = api_revision_description + self.api_version_description = api_version_description + self.api_version_set_id = api_version_set_id + self.subscription_required = subscription_required + self.display_name = display_name + self.service_url = service_url + self.path = path + self.protocols = protocols + + +class ApiVersionConstraint(Model): + """Control Plane Apis version constraint for the API Management service. + + :param min_api_version: Limit control plane API calls to API Management + service with version equal to or newer than this value. + :type min_api_version: str + """ + + _attribute_map = { + 'min_api_version': {'key': 'minApiVersion', 'type': 'str'}, + } + + def __init__(self, *, min_api_version: str=None, **kwargs) -> None: + super(ApiVersionConstraint, self).__init__(**kwargs) + self.min_api_version = min_api_version + + +class ApiVersionSetContract(Resource): + """Api Version Set Contract details. + + Variables are only populated by the server, and will be ignored when + sending a request. + + All required parameters must be populated in order to send to Azure. + + :ivar id: Resource ID. + :vartype id: str + :ivar name: Resource name. + :vartype name: str + :ivar type: Resource type for API Management resource. + :vartype type: str + :param description: Description of API Version Set. + :type description: str + :param version_query_name: Name of query parameter that indicates the API + Version if versioningScheme is set to `query`. + :type version_query_name: str + :param version_header_name: Name of HTTP header parameter that indicates + the API Version if versioningScheme is set to `header`. + :type version_header_name: str + :param display_name: Required. Name of API Version Set + :type display_name: str + :param versioning_scheme: Required. An value that determines where the API + Version identifer will be located in a HTTP request. Possible values + include: 'Segment', 'Query', 'Header' + :type versioning_scheme: str or + ~azure.mgmt.apimanagement.models.VersioningScheme + """ + + _validation = { + 'id': {'readonly': True}, + 'name': {'readonly': True}, + 'type': {'readonly': True}, + 'version_query_name': {'max_length': 100, 'min_length': 1}, + 'version_header_name': {'max_length': 100, 'min_length': 1}, + 'display_name': {'required': True, 'max_length': 100, 'min_length': 1}, + 'versioning_scheme': {'required': True}, + } + + _attribute_map = { + 'id': {'key': 'id', 'type': 'str'}, + 'name': {'key': 'name', 'type': 'str'}, + 'type': {'key': 'type', 'type': 'str'}, + 'description': {'key': 'properties.description', 'type': 'str'}, + 'version_query_name': {'key': 'properties.versionQueryName', 'type': 'str'}, + 'version_header_name': {'key': 'properties.versionHeaderName', 'type': 'str'}, + 'display_name': {'key': 'properties.displayName', 'type': 'str'}, + 'versioning_scheme': {'key': 'properties.versioningScheme', 'type': 'str'}, + } + + def __init__(self, *, display_name: str, versioning_scheme, description: str=None, version_query_name: str=None, version_header_name: str=None, **kwargs) -> None: + super(ApiVersionSetContract, self).__init__(**kwargs) + self.description = description + self.version_query_name = version_query_name + self.version_header_name = version_header_name + self.display_name = display_name + self.versioning_scheme = versioning_scheme + + +class ApiVersionSetContractDetails(Model): + """An API Version Set contains the common configuration for a set of API + Versions relating . + + :param id: Identifier for existing API Version Set. Omit this value to + create a new Version Set. + :type id: str + :param name: The display Name of the API Version Set. + :type name: str + :param description: Description of API Version Set. + :type description: str + :param versioning_scheme: An value that determines where the API Version + identifer will be located in a HTTP request. Possible values include: + 'Segment', 'Query', 'Header' + :type versioning_scheme: str or ~azure.mgmt.apimanagement.models.enum + :param version_query_name: Name of query parameter that indicates the API + Version if versioningScheme is set to `query`. + :type version_query_name: str + :param version_header_name: Name of HTTP header parameter that indicates + the API Version if versioningScheme is set to `header`. + :type version_header_name: str + """ + + _attribute_map = { + 'id': {'key': 'id', 'type': 'str'}, + 'name': {'key': 'name', 'type': 'str'}, + 'description': {'key': 'description', 'type': 'str'}, + 'versioning_scheme': {'key': 'versioningScheme', 'type': 'str'}, + 'version_query_name': {'key': 'versionQueryName', 'type': 'str'}, + 'version_header_name': {'key': 'versionHeaderName', 'type': 'str'}, + } + + def __init__(self, *, id: str=None, name: str=None, description: str=None, versioning_scheme=None, version_query_name: str=None, version_header_name: str=None, **kwargs) -> None: + super(ApiVersionSetContractDetails, self).__init__(**kwargs) + self.id = id + self.name = name + self.description = description + self.versioning_scheme = versioning_scheme + self.version_query_name = version_query_name + self.version_header_name = version_header_name + + +class ApiVersionSetEntityBase(Model): + """Api Version set base parameters. + + :param description: Description of API Version Set. + :type description: str + :param version_query_name: Name of query parameter that indicates the API + Version if versioningScheme is set to `query`. + :type version_query_name: str + :param version_header_name: Name of HTTP header parameter that indicates + the API Version if versioningScheme is set to `header`. + :type version_header_name: str + """ + + _validation = { + 'version_query_name': {'max_length': 100, 'min_length': 1}, + 'version_header_name': {'max_length': 100, 'min_length': 1}, + } + + _attribute_map = { + 'description': {'key': 'description', 'type': 'str'}, + 'version_query_name': {'key': 'versionQueryName', 'type': 'str'}, + 'version_header_name': {'key': 'versionHeaderName', 'type': 'str'}, + } + + def __init__(self, *, description: str=None, version_query_name: str=None, version_header_name: str=None, **kwargs) -> None: + super(ApiVersionSetEntityBase, self).__init__(**kwargs) + self.description = description + self.version_query_name = version_query_name + self.version_header_name = version_header_name + + +class ApiVersionSetUpdateParameters(Model): + """Parameters to update or create an Api Version Set Contract. + + :param description: Description of API Version Set. + :type description: str + :param version_query_name: Name of query parameter that indicates the API + Version if versioningScheme is set to `query`. + :type version_query_name: str + :param version_header_name: Name of HTTP header parameter that indicates + the API Version if versioningScheme is set to `header`. + :type version_header_name: str + :param display_name: Name of API Version Set + :type display_name: str + :param versioning_scheme: An value that determines where the API Version + identifer will be located in a HTTP request. Possible values include: + 'Segment', 'Query', 'Header' + :type versioning_scheme: str or + ~azure.mgmt.apimanagement.models.VersioningScheme + """ + + _validation = { + 'version_query_name': {'max_length': 100, 'min_length': 1}, + 'version_header_name': {'max_length': 100, 'min_length': 1}, + 'display_name': {'max_length': 100, 'min_length': 1}, + } + + _attribute_map = { + 'description': {'key': 'properties.description', 'type': 'str'}, + 'version_query_name': {'key': 'properties.versionQueryName', 'type': 'str'}, + 'version_header_name': {'key': 'properties.versionHeaderName', 'type': 'str'}, + 'display_name': {'key': 'properties.displayName', 'type': 'str'}, + 'versioning_scheme': {'key': 'properties.versioningScheme', 'type': 'str'}, + } + + def __init__(self, *, description: str=None, version_query_name: str=None, version_header_name: str=None, display_name: str=None, versioning_scheme=None, **kwargs) -> None: + super(ApiVersionSetUpdateParameters, self).__init__(**kwargs) + self.description = description + self.version_query_name = version_query_name + self.version_header_name = version_header_name + self.display_name = display_name + self.versioning_scheme = versioning_scheme + + +class AuthenticationSettingsContract(Model): + """API Authentication Settings. + + :param o_auth2: OAuth2 Authentication settings + :type o_auth2: + ~azure.mgmt.apimanagement.models.OAuth2AuthenticationSettingsContract + :param openid: OpenID Connect Authentication Settings + :type openid: + ~azure.mgmt.apimanagement.models.OpenIdAuthenticationSettingsContract + """ + + _attribute_map = { + 'o_auth2': {'key': 'oAuth2', 'type': 'OAuth2AuthenticationSettingsContract'}, + 'openid': {'key': 'openid', 'type': 'OpenIdAuthenticationSettingsContract'}, + } + + def __init__(self, *, o_auth2=None, openid=None, **kwargs) -> None: + super(AuthenticationSettingsContract, self).__init__(**kwargs) + self.o_auth2 = o_auth2 + self.openid = openid + + +class AuthorizationServerContract(Resource): + """External OAuth authorization server settings. + + Variables are only populated by the server, and will be ignored when + sending a request. + + All required parameters must be populated in order to send to Azure. + + :ivar id: Resource ID. + :vartype id: str + :ivar name: Resource name. + :vartype name: str + :ivar type: Resource type for API Management resource. + :vartype type: str + :param description: Description of the authorization server. Can contain + HTML formatting tags. + :type description: str + :param authorization_methods: HTTP verbs supported by the authorization + endpoint. GET must be always present. POST is optional. + :type authorization_methods: list[str or + ~azure.mgmt.apimanagement.models.AuthorizationMethod] + :param client_authentication_method: Method of authentication supported by + the token endpoint of this authorization server. Possible values are Basic + and/or Body. When Body is specified, client credentials and other + parameters are passed within the request body in the + application/x-www-form-urlencoded format. + :type client_authentication_method: list[str or + ~azure.mgmt.apimanagement.models.ClientAuthenticationMethod] + :param token_body_parameters: Additional parameters required by the token + endpoint of this authorization server represented as an array of JSON + objects with name and value string properties, i.e. {"name" : "name + value", "value": "a value"}. + :type token_body_parameters: + list[~azure.mgmt.apimanagement.models.TokenBodyParameterContract] + :param token_endpoint: OAuth token endpoint. Contains absolute URI to + entity being referenced. + :type token_endpoint: str + :param support_state: If true, authorization server will include state + parameter from the authorization request to its response. Client may use + state parameter to raise protocol security. + :type support_state: bool + :param default_scope: Access token scope that is going to be requested by + default. Can be overridden at the API level. Should be provided in the + form of a string containing space-delimited values. + :type default_scope: str + :param bearer_token_sending_methods: Specifies the mechanism by which + access token is passed to the API. + :type bearer_token_sending_methods: list[str or + ~azure.mgmt.apimanagement.models.BearerTokenSendingMethod] + :param resource_owner_username: Can be optionally specified when resource + owner password grant type is supported by this authorization server. + Default resource owner username. + :type resource_owner_username: str + :param resource_owner_password: Can be optionally specified when resource + owner password grant type is supported by this authorization server. + Default resource owner password. + :type resource_owner_password: str + :param display_name: Required. User-friendly authorization server name. + :type display_name: str + :param client_registration_endpoint: Required. Optional reference to a + page where client or app registration for this authorization server is + performed. Contains absolute URL to entity being referenced. + :type client_registration_endpoint: str + :param authorization_endpoint: Required. OAuth authorization endpoint. See + http://tools.ietf.org/html/rfc6749#section-3.2. + :type authorization_endpoint: str + :param grant_types: Required. Form of an authorization grant, which the + client uses to request the access token. + :type grant_types: list[str or ~azure.mgmt.apimanagement.models.GrantType] + :param client_id: Required. Client or app id registered with this + authorization server. + :type client_id: str + :param client_secret: Client or app secret registered with this + authorization server. This property will not be filled on 'GET' + operations! Use '/listSecrets' POST request to get the value. + :type client_secret: str + """ + + _validation = { + 'id': {'readonly': True}, + 'name': {'readonly': True}, + 'type': {'readonly': True}, + 'display_name': {'required': True, 'max_length': 50, 'min_length': 1}, + 'client_registration_endpoint': {'required': True}, + 'authorization_endpoint': {'required': True}, + 'grant_types': {'required': True}, + 'client_id': {'required': True}, + } + + _attribute_map = { + 'id': {'key': 'id', 'type': 'str'}, + 'name': {'key': 'name', 'type': 'str'}, + 'type': {'key': 'type', 'type': 'str'}, + 'description': {'key': 'properties.description', 'type': 'str'}, + 'authorization_methods': {'key': 'properties.authorizationMethods', 'type': '[AuthorizationMethod]'}, + 'client_authentication_method': {'key': 'properties.clientAuthenticationMethod', 'type': '[str]'}, + 'token_body_parameters': {'key': 'properties.tokenBodyParameters', 'type': '[TokenBodyParameterContract]'}, + 'token_endpoint': {'key': 'properties.tokenEndpoint', 'type': 'str'}, + 'support_state': {'key': 'properties.supportState', 'type': 'bool'}, + 'default_scope': {'key': 'properties.defaultScope', 'type': 'str'}, + 'bearer_token_sending_methods': {'key': 'properties.bearerTokenSendingMethods', 'type': '[str]'}, + 'resource_owner_username': {'key': 'properties.resourceOwnerUsername', 'type': 'str'}, + 'resource_owner_password': {'key': 'properties.resourceOwnerPassword', 'type': 'str'}, + 'display_name': {'key': 'properties.displayName', 'type': 'str'}, + 'client_registration_endpoint': {'key': 'properties.clientRegistrationEndpoint', 'type': 'str'}, + 'authorization_endpoint': {'key': 'properties.authorizationEndpoint', 'type': 'str'}, + 'grant_types': {'key': 'properties.grantTypes', 'type': '[str]'}, + 'client_id': {'key': 'properties.clientId', 'type': 'str'}, + 'client_secret': {'key': 'properties.clientSecret', 'type': 'str'}, + } + + def __init__(self, *, display_name: str, client_registration_endpoint: str, authorization_endpoint: str, grant_types, client_id: str, description: str=None, authorization_methods=None, client_authentication_method=None, token_body_parameters=None, token_endpoint: str=None, support_state: bool=None, default_scope: str=None, bearer_token_sending_methods=None, resource_owner_username: str=None, resource_owner_password: str=None, client_secret: str=None, **kwargs) -> None: + super(AuthorizationServerContract, self).__init__(**kwargs) + self.description = description + self.authorization_methods = authorization_methods + self.client_authentication_method = client_authentication_method + self.token_body_parameters = token_body_parameters + self.token_endpoint = token_endpoint + self.support_state = support_state + self.default_scope = default_scope + self.bearer_token_sending_methods = bearer_token_sending_methods + self.resource_owner_username = resource_owner_username + self.resource_owner_password = resource_owner_password + self.display_name = display_name + self.client_registration_endpoint = client_registration_endpoint + self.authorization_endpoint = authorization_endpoint + self.grant_types = grant_types + self.client_id = client_id + self.client_secret = client_secret + + +class AuthorizationServerContractBaseProperties(Model): + """External OAuth authorization server Update settings contract. + + :param description: Description of the authorization server. Can contain + HTML formatting tags. + :type description: str + :param authorization_methods: HTTP verbs supported by the authorization + endpoint. GET must be always present. POST is optional. + :type authorization_methods: list[str or + ~azure.mgmt.apimanagement.models.AuthorizationMethod] + :param client_authentication_method: Method of authentication supported by + the token endpoint of this authorization server. Possible values are Basic + and/or Body. When Body is specified, client credentials and other + parameters are passed within the request body in the + application/x-www-form-urlencoded format. + :type client_authentication_method: list[str or + ~azure.mgmt.apimanagement.models.ClientAuthenticationMethod] + :param token_body_parameters: Additional parameters required by the token + endpoint of this authorization server represented as an array of JSON + objects with name and value string properties, i.e. {"name" : "name + value", "value": "a value"}. + :type token_body_parameters: + list[~azure.mgmt.apimanagement.models.TokenBodyParameterContract] + :param token_endpoint: OAuth token endpoint. Contains absolute URI to + entity being referenced. + :type token_endpoint: str + :param support_state: If true, authorization server will include state + parameter from the authorization request to its response. Client may use + state parameter to raise protocol security. + :type support_state: bool + :param default_scope: Access token scope that is going to be requested by + default. Can be overridden at the API level. Should be provided in the + form of a string containing space-delimited values. + :type default_scope: str + :param bearer_token_sending_methods: Specifies the mechanism by which + access token is passed to the API. + :type bearer_token_sending_methods: list[str or + ~azure.mgmt.apimanagement.models.BearerTokenSendingMethod] + :param resource_owner_username: Can be optionally specified when resource + owner password grant type is supported by this authorization server. + Default resource owner username. + :type resource_owner_username: str + :param resource_owner_password: Can be optionally specified when resource + owner password grant type is supported by this authorization server. + Default resource owner password. + :type resource_owner_password: str + """ + + _attribute_map = { + 'description': {'key': 'description', 'type': 'str'}, + 'authorization_methods': {'key': 'authorizationMethods', 'type': '[AuthorizationMethod]'}, + 'client_authentication_method': {'key': 'clientAuthenticationMethod', 'type': '[str]'}, + 'token_body_parameters': {'key': 'tokenBodyParameters', 'type': '[TokenBodyParameterContract]'}, + 'token_endpoint': {'key': 'tokenEndpoint', 'type': 'str'}, + 'support_state': {'key': 'supportState', 'type': 'bool'}, + 'default_scope': {'key': 'defaultScope', 'type': 'str'}, + 'bearer_token_sending_methods': {'key': 'bearerTokenSendingMethods', 'type': '[str]'}, + 'resource_owner_username': {'key': 'resourceOwnerUsername', 'type': 'str'}, + 'resource_owner_password': {'key': 'resourceOwnerPassword', 'type': 'str'}, + } + + def __init__(self, *, description: str=None, authorization_methods=None, client_authentication_method=None, token_body_parameters=None, token_endpoint: str=None, support_state: bool=None, default_scope: str=None, bearer_token_sending_methods=None, resource_owner_username: str=None, resource_owner_password: str=None, **kwargs) -> None: + super(AuthorizationServerContractBaseProperties, self).__init__(**kwargs) + self.description = description + self.authorization_methods = authorization_methods + self.client_authentication_method = client_authentication_method + self.token_body_parameters = token_body_parameters + self.token_endpoint = token_endpoint + self.support_state = support_state + self.default_scope = default_scope + self.bearer_token_sending_methods = bearer_token_sending_methods + self.resource_owner_username = resource_owner_username + self.resource_owner_password = resource_owner_password + + +class AuthorizationServerUpdateContract(Resource): + """External OAuth authorization server settings. + + Variables are only populated by the server, and will be ignored when + sending a request. + + :ivar id: Resource ID. + :vartype id: str + :ivar name: Resource name. + :vartype name: str + :ivar type: Resource type for API Management resource. + :vartype type: str + :param description: Description of the authorization server. Can contain + HTML formatting tags. + :type description: str + :param authorization_methods: HTTP verbs supported by the authorization + endpoint. GET must be always present. POST is optional. + :type authorization_methods: list[str or + ~azure.mgmt.apimanagement.models.AuthorizationMethod] + :param client_authentication_method: Method of authentication supported by + the token endpoint of this authorization server. Possible values are Basic + and/or Body. When Body is specified, client credentials and other + parameters are passed within the request body in the + application/x-www-form-urlencoded format. + :type client_authentication_method: list[str or + ~azure.mgmt.apimanagement.models.ClientAuthenticationMethod] + :param token_body_parameters: Additional parameters required by the token + endpoint of this authorization server represented as an array of JSON + objects with name and value string properties, i.e. {"name" : "name + value", "value": "a value"}. + :type token_body_parameters: + list[~azure.mgmt.apimanagement.models.TokenBodyParameterContract] + :param token_endpoint: OAuth token endpoint. Contains absolute URI to + entity being referenced. + :type token_endpoint: str + :param support_state: If true, authorization server will include state + parameter from the authorization request to its response. Client may use + state parameter to raise protocol security. + :type support_state: bool + :param default_scope: Access token scope that is going to be requested by + default. Can be overridden at the API level. Should be provided in the + form of a string containing space-delimited values. + :type default_scope: str + :param bearer_token_sending_methods: Specifies the mechanism by which + access token is passed to the API. + :type bearer_token_sending_methods: list[str or + ~azure.mgmt.apimanagement.models.BearerTokenSendingMethod] + :param resource_owner_username: Can be optionally specified when resource + owner password grant type is supported by this authorization server. + Default resource owner username. + :type resource_owner_username: str + :param resource_owner_password: Can be optionally specified when resource + owner password grant type is supported by this authorization server. + Default resource owner password. + :type resource_owner_password: str + :param display_name: User-friendly authorization server name. + :type display_name: str + :param client_registration_endpoint: Optional reference to a page where + client or app registration for this authorization server is performed. + Contains absolute URL to entity being referenced. + :type client_registration_endpoint: str + :param authorization_endpoint: OAuth authorization endpoint. See + http://tools.ietf.org/html/rfc6749#section-3.2. + :type authorization_endpoint: str + :param grant_types: Form of an authorization grant, which the client uses + to request the access token. + :type grant_types: list[str or ~azure.mgmt.apimanagement.models.GrantType] + :param client_id: Client or app id registered with this authorization + server. + :type client_id: str + :param client_secret: Client or app secret registered with this + authorization server. This property will not be filled on 'GET' + operations! Use '/listSecrets' POST request to get the value. + :type client_secret: str + """ + + _validation = { + 'id': {'readonly': True}, + 'name': {'readonly': True}, + 'type': {'readonly': True}, + 'display_name': {'max_length': 50, 'min_length': 1}, + } + + _attribute_map = { + 'id': {'key': 'id', 'type': 'str'}, + 'name': {'key': 'name', 'type': 'str'}, + 'type': {'key': 'type', 'type': 'str'}, + 'description': {'key': 'properties.description', 'type': 'str'}, + 'authorization_methods': {'key': 'properties.authorizationMethods', 'type': '[AuthorizationMethod]'}, + 'client_authentication_method': {'key': 'properties.clientAuthenticationMethod', 'type': '[str]'}, + 'token_body_parameters': {'key': 'properties.tokenBodyParameters', 'type': '[TokenBodyParameterContract]'}, + 'token_endpoint': {'key': 'properties.tokenEndpoint', 'type': 'str'}, + 'support_state': {'key': 'properties.supportState', 'type': 'bool'}, + 'default_scope': {'key': 'properties.defaultScope', 'type': 'str'}, + 'bearer_token_sending_methods': {'key': 'properties.bearerTokenSendingMethods', 'type': '[str]'}, + 'resource_owner_username': {'key': 'properties.resourceOwnerUsername', 'type': 'str'}, + 'resource_owner_password': {'key': 'properties.resourceOwnerPassword', 'type': 'str'}, + 'display_name': {'key': 'properties.displayName', 'type': 'str'}, + 'client_registration_endpoint': {'key': 'properties.clientRegistrationEndpoint', 'type': 'str'}, + 'authorization_endpoint': {'key': 'properties.authorizationEndpoint', 'type': 'str'}, + 'grant_types': {'key': 'properties.grantTypes', 'type': '[str]'}, + 'client_id': {'key': 'properties.clientId', 'type': 'str'}, + 'client_secret': {'key': 'properties.clientSecret', 'type': 'str'}, + } + + def __init__(self, *, description: str=None, authorization_methods=None, client_authentication_method=None, token_body_parameters=None, token_endpoint: str=None, support_state: bool=None, default_scope: str=None, bearer_token_sending_methods=None, resource_owner_username: str=None, resource_owner_password: str=None, display_name: str=None, client_registration_endpoint: str=None, authorization_endpoint: str=None, grant_types=None, client_id: str=None, client_secret: str=None, **kwargs) -> None: + super(AuthorizationServerUpdateContract, self).__init__(**kwargs) + self.description = description + self.authorization_methods = authorization_methods + self.client_authentication_method = client_authentication_method + self.token_body_parameters = token_body_parameters + self.token_endpoint = token_endpoint + self.support_state = support_state + self.default_scope = default_scope + self.bearer_token_sending_methods = bearer_token_sending_methods + self.resource_owner_username = resource_owner_username + self.resource_owner_password = resource_owner_password + self.display_name = display_name + self.client_registration_endpoint = client_registration_endpoint + self.authorization_endpoint = authorization_endpoint + self.grant_types = grant_types + self.client_id = client_id + self.client_secret = client_secret + + +class BackendAuthorizationHeaderCredentials(Model): + """Authorization header information. + + All required parameters must be populated in order to send to Azure. + + :param scheme: Required. Authentication Scheme name. + :type scheme: str + :param parameter: Required. Authentication Parameter value. + :type parameter: str + """ + + _validation = { + 'scheme': {'required': True, 'max_length': 100, 'min_length': 1}, + 'parameter': {'required': True, 'max_length': 300, 'min_length': 1}, + } + + _attribute_map = { + 'scheme': {'key': 'scheme', 'type': 'str'}, + 'parameter': {'key': 'parameter', 'type': 'str'}, + } + + def __init__(self, *, scheme: str, parameter: str, **kwargs) -> None: + super(BackendAuthorizationHeaderCredentials, self).__init__(**kwargs) + self.scheme = scheme + self.parameter = parameter + + +class BackendBaseParameters(Model): + """Backend entity base Parameter set. + + :param title: Backend Title. + :type title: str + :param description: Backend Description. + :type description: str + :param resource_id: Management Uri of the Resource in External System. + This url can be the Arm Resource Id of Logic Apps, Function Apps or Api + Apps. + :type resource_id: str + :param properties: Backend Properties contract + :type properties: ~azure.mgmt.apimanagement.models.BackendProperties + :param credentials: Backend Credentials Contract Properties + :type credentials: + ~azure.mgmt.apimanagement.models.BackendCredentialsContract + :param proxy: Backend Proxy Contract Properties + :type proxy: ~azure.mgmt.apimanagement.models.BackendProxyContract + :param tls: Backend TLS Properties + :type tls: ~azure.mgmt.apimanagement.models.BackendTlsProperties + """ + + _validation = { + 'title': {'max_length': 300, 'min_length': 1}, + 'description': {'max_length': 2000, 'min_length': 1}, + 'resource_id': {'max_length': 2000, 'min_length': 1}, + } + + _attribute_map = { + 'title': {'key': 'title', 'type': 'str'}, + 'description': {'key': 'description', 'type': 'str'}, + 'resource_id': {'key': 'resourceId', 'type': 'str'}, + 'properties': {'key': 'properties', 'type': 'BackendProperties'}, + 'credentials': {'key': 'credentials', 'type': 'BackendCredentialsContract'}, + 'proxy': {'key': 'proxy', 'type': 'BackendProxyContract'}, + 'tls': {'key': 'tls', 'type': 'BackendTlsProperties'}, + } + + def __init__(self, *, title: str=None, description: str=None, resource_id: str=None, properties=None, credentials=None, proxy=None, tls=None, **kwargs) -> None: + super(BackendBaseParameters, self).__init__(**kwargs) + self.title = title + self.description = description + self.resource_id = resource_id + self.properties = properties + self.credentials = credentials + self.proxy = proxy + self.tls = tls + + +class BackendContract(Resource): + """Backend details. + + Variables are only populated by the server, and will be ignored when + sending a request. + + All required parameters must be populated in order to send to Azure. + + :ivar id: Resource ID. + :vartype id: str + :ivar name: Resource name. + :vartype name: str + :ivar type: Resource type for API Management resource. + :vartype type: str + :param title: Backend Title. + :type title: str + :param description: Backend Description. + :type description: str + :param resource_id: Management Uri of the Resource in External System. + This url can be the Arm Resource Id of Logic Apps, Function Apps or Api + Apps. + :type resource_id: str + :param properties: Backend Properties contract + :type properties: ~azure.mgmt.apimanagement.models.BackendProperties + :param credentials: Backend Credentials Contract Properties + :type credentials: + ~azure.mgmt.apimanagement.models.BackendCredentialsContract + :param proxy: Backend Proxy Contract Properties + :type proxy: ~azure.mgmt.apimanagement.models.BackendProxyContract + :param tls: Backend TLS Properties + :type tls: ~azure.mgmt.apimanagement.models.BackendTlsProperties + :param url: Required. Runtime Url of the Backend. + :type url: str + :param protocol: Required. Backend communication protocol. Possible values + include: 'http', 'soap' + :type protocol: str or ~azure.mgmt.apimanagement.models.BackendProtocol + """ + + _validation = { + 'id': {'readonly': True}, + 'name': {'readonly': True}, + 'type': {'readonly': True}, + 'title': {'max_length': 300, 'min_length': 1}, + 'description': {'max_length': 2000, 'min_length': 1}, + 'resource_id': {'max_length': 2000, 'min_length': 1}, + 'url': {'required': True, 'max_length': 2000, 'min_length': 1}, + 'protocol': {'required': True}, + } + + _attribute_map = { + 'id': {'key': 'id', 'type': 'str'}, + 'name': {'key': 'name', 'type': 'str'}, + 'type': {'key': 'type', 'type': 'str'}, + 'title': {'key': 'properties.title', 'type': 'str'}, + 'description': {'key': 'properties.description', 'type': 'str'}, + 'resource_id': {'key': 'properties.resourceId', 'type': 'str'}, + 'properties': {'key': 'properties.properties', 'type': 'BackendProperties'}, + 'credentials': {'key': 'properties.credentials', 'type': 'BackendCredentialsContract'}, + 'proxy': {'key': 'properties.proxy', 'type': 'BackendProxyContract'}, + 'tls': {'key': 'properties.tls', 'type': 'BackendTlsProperties'}, + 'url': {'key': 'properties.url', 'type': 'str'}, + 'protocol': {'key': 'properties.protocol', 'type': 'str'}, + } + + def __init__(self, *, url: str, protocol, title: str=None, description: str=None, resource_id: str=None, properties=None, credentials=None, proxy=None, tls=None, **kwargs) -> None: + super(BackendContract, self).__init__(**kwargs) + self.title = title + self.description = description + self.resource_id = resource_id + self.properties = properties + self.credentials = credentials + self.proxy = proxy + self.tls = tls + self.url = url + self.protocol = protocol + + +class BackendCredentialsContract(Model): + """Details of the Credentials used to connect to Backend. + + :param certificate: List of Client Certificate Thumbprint. + :type certificate: list[str] + :param query: Query Parameter description. + :type query: dict[str, list[str]] + :param header: Header Parameter description. + :type header: dict[str, list[str]] + :param authorization: Authorization header authentication + :type authorization: + ~azure.mgmt.apimanagement.models.BackendAuthorizationHeaderCredentials + """ + + _validation = { + 'certificate': {'max_items': 32}, + } + + _attribute_map = { + 'certificate': {'key': 'certificate', 'type': '[str]'}, + 'query': {'key': 'query', 'type': '{[str]}'}, + 'header': {'key': 'header', 'type': '{[str]}'}, + 'authorization': {'key': 'authorization', 'type': 'BackendAuthorizationHeaderCredentials'}, + } + + def __init__(self, *, certificate=None, query=None, header=None, authorization=None, **kwargs) -> None: + super(BackendCredentialsContract, self).__init__(**kwargs) + self.certificate = certificate + self.query = query + self.header = header + self.authorization = authorization + + +class BackendProperties(Model): + """Properties specific to the Backend Type. + + :param service_fabric_cluster: Backend Service Fabric Cluster Properties + :type service_fabric_cluster: + ~azure.mgmt.apimanagement.models.BackendServiceFabricClusterProperties + """ + + _attribute_map = { + 'service_fabric_cluster': {'key': 'serviceFabricCluster', 'type': 'BackendServiceFabricClusterProperties'}, + } + + def __init__(self, *, service_fabric_cluster=None, **kwargs) -> None: + super(BackendProperties, self).__init__(**kwargs) + self.service_fabric_cluster = service_fabric_cluster + + +class BackendProxyContract(Model): + """Details of the Backend WebProxy Server to use in the Request to Backend. + + All required parameters must be populated in order to send to Azure. + + :param url: Required. WebProxy Server AbsoluteUri property which includes + the entire URI stored in the Uri instance, including all fragments and + query strings. + :type url: str + :param username: Username to connect to the WebProxy server + :type username: str + :param password: Password to connect to the WebProxy Server + :type password: str + """ + + _validation = { + 'url': {'required': True, 'max_length': 2000, 'min_length': 1}, + } + + _attribute_map = { + 'url': {'key': 'url', 'type': 'str'}, + 'username': {'key': 'username', 'type': 'str'}, + 'password': {'key': 'password', 'type': 'str'}, + } + + def __init__(self, *, url: str, username: str=None, password: str=None, **kwargs) -> None: + super(BackendProxyContract, self).__init__(**kwargs) + self.url = url + self.username = username + self.password = password + + +class BackendReconnectContract(Resource): + """Reconnect request parameters. + + Variables are only populated by the server, and will be ignored when + sending a request. + + :ivar id: Resource ID. + :vartype id: str + :ivar name: Resource name. + :vartype name: str + :ivar type: Resource type for API Management resource. + :vartype type: str + :param after: Duration in ISO8601 format after which reconnect will be + initiated. Minimum duration of the Reconnect is PT2M. + :type after: timedelta + """ + + _validation = { + 'id': {'readonly': True}, + 'name': {'readonly': True}, + 'type': {'readonly': True}, + } + + _attribute_map = { + 'id': {'key': 'id', 'type': 'str'}, + 'name': {'key': 'name', 'type': 'str'}, + 'type': {'key': 'type', 'type': 'str'}, + 'after': {'key': 'properties.after', 'type': 'duration'}, + } + + def __init__(self, *, after=None, **kwargs) -> None: + super(BackendReconnectContract, self).__init__(**kwargs) + self.after = after + + +class BackendServiceFabricClusterProperties(Model): + """Properties of the Service Fabric Type Backend. + + All required parameters must be populated in order to send to Azure. + + :param client_certificatethumbprint: Required. The client certificate + thumbprint for the management endpoint. + :type client_certificatethumbprint: str + :param max_partition_resolution_retries: Maximum number of retries while + attempting resolve the partition. + :type max_partition_resolution_retries: int + :param management_endpoints: Required. The cluster management endpoint. + :type management_endpoints: list[str] + :param server_certificate_thumbprints: Thumbprints of certificates cluster + management service uses for tls communication + :type server_certificate_thumbprints: list[str] + :param server_x509_names: Server X509 Certificate Names Collection + :type server_x509_names: + list[~azure.mgmt.apimanagement.models.X509CertificateName] + """ + + _validation = { + 'client_certificatethumbprint': {'required': True}, + 'management_endpoints': {'required': True}, + } + + _attribute_map = { + 'client_certificatethumbprint': {'key': 'clientCertificatethumbprint', 'type': 'str'}, + 'max_partition_resolution_retries': {'key': 'maxPartitionResolutionRetries', 'type': 'int'}, + 'management_endpoints': {'key': 'managementEndpoints', 'type': '[str]'}, + 'server_certificate_thumbprints': {'key': 'serverCertificateThumbprints', 'type': '[str]'}, + 'server_x509_names': {'key': 'serverX509Names', 'type': '[X509CertificateName]'}, + } + + def __init__(self, *, client_certificatethumbprint: str, management_endpoints, max_partition_resolution_retries: int=None, server_certificate_thumbprints=None, server_x509_names=None, **kwargs) -> None: + super(BackendServiceFabricClusterProperties, self).__init__(**kwargs) + self.client_certificatethumbprint = client_certificatethumbprint + self.max_partition_resolution_retries = max_partition_resolution_retries + self.management_endpoints = management_endpoints + self.server_certificate_thumbprints = server_certificate_thumbprints + self.server_x509_names = server_x509_names + + +class BackendTlsProperties(Model): + """Properties controlling TLS Certificate Validation. + + :param validate_certificate_chain: Flag indicating whether SSL certificate + chain validation should be done when using self-signed certificates for + this backend host. Default value: True . + :type validate_certificate_chain: bool + :param validate_certificate_name: Flag indicating whether SSL certificate + name validation should be done when using self-signed certificates for + this backend host. Default value: True . + :type validate_certificate_name: bool + """ + + _attribute_map = { + 'validate_certificate_chain': {'key': 'validateCertificateChain', 'type': 'bool'}, + 'validate_certificate_name': {'key': 'validateCertificateName', 'type': 'bool'}, + } + + def __init__(self, *, validate_certificate_chain: bool=True, validate_certificate_name: bool=True, **kwargs) -> None: + super(BackendTlsProperties, self).__init__(**kwargs) + self.validate_certificate_chain = validate_certificate_chain + self.validate_certificate_name = validate_certificate_name + + +class BackendUpdateParameters(Model): + """Backend update parameters. + + :param title: Backend Title. + :type title: str + :param description: Backend Description. + :type description: str + :param resource_id: Management Uri of the Resource in External System. + This url can be the Arm Resource Id of Logic Apps, Function Apps or Api + Apps. + :type resource_id: str + :param properties: Backend Properties contract + :type properties: ~azure.mgmt.apimanagement.models.BackendProperties + :param credentials: Backend Credentials Contract Properties + :type credentials: + ~azure.mgmt.apimanagement.models.BackendCredentialsContract + :param proxy: Backend Proxy Contract Properties + :type proxy: ~azure.mgmt.apimanagement.models.BackendProxyContract + :param tls: Backend TLS Properties + :type tls: ~azure.mgmt.apimanagement.models.BackendTlsProperties + :param url: Runtime Url of the Backend. + :type url: str + :param protocol: Backend communication protocol. Possible values include: + 'http', 'soap' + :type protocol: str or ~azure.mgmt.apimanagement.models.BackendProtocol + """ + + _validation = { + 'title': {'max_length': 300, 'min_length': 1}, + 'description': {'max_length': 2000, 'min_length': 1}, + 'resource_id': {'max_length': 2000, 'min_length': 1}, + 'url': {'max_length': 2000, 'min_length': 1}, + } + + _attribute_map = { + 'title': {'key': 'properties.title', 'type': 'str'}, + 'description': {'key': 'properties.description', 'type': 'str'}, + 'resource_id': {'key': 'properties.resourceId', 'type': 'str'}, + 'properties': {'key': 'properties.properties', 'type': 'BackendProperties'}, + 'credentials': {'key': 'properties.credentials', 'type': 'BackendCredentialsContract'}, + 'proxy': {'key': 'properties.proxy', 'type': 'BackendProxyContract'}, + 'tls': {'key': 'properties.tls', 'type': 'BackendTlsProperties'}, + 'url': {'key': 'properties.url', 'type': 'str'}, + 'protocol': {'key': 'properties.protocol', 'type': 'str'}, + } + + def __init__(self, *, title: str=None, description: str=None, resource_id: str=None, properties=None, credentials=None, proxy=None, tls=None, url: str=None, protocol=None, **kwargs) -> None: + super(BackendUpdateParameters, self).__init__(**kwargs) + self.title = title + self.description = description + self.resource_id = resource_id + self.properties = properties + self.credentials = credentials + self.proxy = proxy + self.tls = tls + self.url = url + self.protocol = protocol + + +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 + + +class CacheContract(Resource): + """Cache details. + + Variables are only populated by the server, and will be ignored when + sending a request. + + All required parameters must be populated in order to send to Azure. + + :ivar id: Resource ID. + :vartype id: str + :ivar name: Resource name. + :vartype name: str + :ivar type: Resource type for API Management resource. + :vartype type: str + :param description: Cache description + :type description: str + :param connection_string: Required. Runtime connection string to cache + :type connection_string: str + :param resource_id: Original uri of entity in external system cache points + to + :type resource_id: str + """ + + _validation = { + 'id': {'readonly': True}, + 'name': {'readonly': True}, + 'type': {'readonly': True}, + 'description': {'max_length': 2000}, + 'connection_string': {'required': True, 'max_length': 300}, + 'resource_id': {'max_length': 2000}, + } + + _attribute_map = { + 'id': {'key': 'id', 'type': 'str'}, + 'name': {'key': 'name', 'type': 'str'}, + 'type': {'key': 'type', 'type': 'str'}, + 'description': {'key': 'properties.description', 'type': 'str'}, + 'connection_string': {'key': 'properties.connectionString', 'type': 'str'}, + 'resource_id': {'key': 'properties.resourceId', 'type': 'str'}, + } + + def __init__(self, *, connection_string: str, description: str=None, resource_id: str=None, **kwargs) -> None: + super(CacheContract, self).__init__(**kwargs) + self.description = description + self.connection_string = connection_string + self.resource_id = resource_id + + +class CacheUpdateParameters(Model): + """Cache update details. + + :param description: Cache description + :type description: str + :param connection_string: Runtime connection string to cache + :type connection_string: str + :param resource_id: Original uri of entity in external system cache points + to + :type resource_id: str + """ + + _validation = { + 'description': {'max_length': 2000}, + 'connection_string': {'max_length': 300}, + 'resource_id': {'max_length': 2000}, + } + + _attribute_map = { + 'description': {'key': 'properties.description', 'type': 'str'}, + 'connection_string': {'key': 'properties.connectionString', 'type': 'str'}, + 'resource_id': {'key': 'properties.resourceId', 'type': 'str'}, + } + + def __init__(self, *, description: str=None, connection_string: str=None, resource_id: str=None, **kwargs) -> None: + super(CacheUpdateParameters, self).__init__(**kwargs) + self.description = description + self.connection_string = connection_string + self.resource_id = resource_id + + +class CertificateConfiguration(Model): + """Certificate configuration which consist of non-trusted intermediates and + root certificates. + + All required parameters must be populated in order to send to Azure. + + :param encoded_certificate: Base64 Encoded certificate. + :type encoded_certificate: str + :param certificate_password: Certificate Password. + :type certificate_password: str + :param store_name: Required. The + System.Security.Cryptography.x509certificates.StoreName certificate store + location. Only Root and CertificateAuthority are valid locations. Possible + values include: 'CertificateAuthority', 'Root' + :type store_name: str or ~azure.mgmt.apimanagement.models.enum + :param certificate: Certificate information. + :type certificate: ~azure.mgmt.apimanagement.models.CertificateInformation + """ + + _validation = { + 'store_name': {'required': True}, + } + + _attribute_map = { + 'encoded_certificate': {'key': 'encodedCertificate', 'type': 'str'}, + 'certificate_password': {'key': 'certificatePassword', 'type': 'str'}, + 'store_name': {'key': 'storeName', 'type': 'str'}, + 'certificate': {'key': 'certificate', 'type': 'CertificateInformation'}, + } + + def __init__(self, *, store_name, encoded_certificate: str=None, certificate_password: str=None, certificate=None, **kwargs) -> None: + super(CertificateConfiguration, self).__init__(**kwargs) + self.encoded_certificate = encoded_certificate + self.certificate_password = certificate_password + self.store_name = store_name + self.certificate = certificate + + +class CertificateContract(Resource): + """Certificate details. + + Variables are only populated by the server, and will be ignored when + sending a request. + + All required parameters must be populated in order to send to Azure. + + :ivar id: Resource ID. + :vartype id: str + :ivar name: Resource name. + :vartype name: str + :ivar type: Resource type for API Management resource. + :vartype type: str + :param subject: Required. Subject attribute of the certificate. + :type subject: str + :param thumbprint: Required. Thumbprint of the certificate. + :type thumbprint: str + :param expiration_date: Required. Expiration date of the certificate. The + date conforms to the following format: `yyyy-MM-ddTHH:mm:ssZ` as specified + by the ISO 8601 standard. + :type expiration_date: datetime + """ + + _validation = { + 'id': {'readonly': True}, + 'name': {'readonly': True}, + 'type': {'readonly': True}, + 'subject': {'required': True}, + 'thumbprint': {'required': True}, + 'expiration_date': {'required': True}, + } + + _attribute_map = { + 'id': {'key': 'id', 'type': 'str'}, + 'name': {'key': 'name', 'type': 'str'}, + 'type': {'key': 'type', 'type': 'str'}, + 'subject': {'key': 'properties.subject', 'type': 'str'}, + 'thumbprint': {'key': 'properties.thumbprint', 'type': 'str'}, + 'expiration_date': {'key': 'properties.expirationDate', 'type': 'iso-8601'}, + } + + def __init__(self, *, subject: str, thumbprint: str, expiration_date, **kwargs) -> None: + super(CertificateContract, self).__init__(**kwargs) + self.subject = subject + self.thumbprint = thumbprint + self.expiration_date = expiration_date + + +class CertificateCreateOrUpdateParameters(Model): + """Certificate create or update details. + + All required parameters must be populated in order to send to Azure. + + :param data: Required. Base 64 encoded certificate using the + application/x-pkcs12 representation. + :type data: str + :param password: Required. Password for the Certificate + :type password: str + """ + + _validation = { + 'data': {'required': True}, + 'password': {'required': True}, + } + + _attribute_map = { + 'data': {'key': 'properties.data', 'type': 'str'}, + 'password': {'key': 'properties.password', 'type': 'str'}, + } + + def __init__(self, *, data: str, password: str, **kwargs) -> None: + super(CertificateCreateOrUpdateParameters, self).__init__(**kwargs) + self.data = data + self.password = password + + +class CertificateInformation(Model): + """SSL certificate information. + + All required parameters must be populated in order to send to Azure. + + :param expiry: Required. Expiration date of the certificate. The date + conforms to the following format: `yyyy-MM-ddTHH:mm:ssZ` as specified by + the ISO 8601 standard. + :type expiry: datetime + :param thumbprint: Required. Thumbprint of the certificate. + :type thumbprint: str + :param subject: Required. Subject of the certificate. + :type subject: str + """ + + _validation = { + 'expiry': {'required': True}, + 'thumbprint': {'required': True}, + 'subject': {'required': True}, + } + + _attribute_map = { + 'expiry': {'key': 'expiry', 'type': 'iso-8601'}, + 'thumbprint': {'key': 'thumbprint', 'type': 'str'}, + 'subject': {'key': 'subject', 'type': 'str'}, + } + + def __init__(self, *, expiry, thumbprint: str, subject: str, **kwargs) -> None: + super(CertificateInformation, self).__init__(**kwargs) + self.expiry = expiry + self.thumbprint = thumbprint + self.subject = subject + + +class ClientSecretContract(Model): + """Client or app secret used in IdentityProviders, Aad, OpenID or OAuth. + + :param client_secret: Client or app secret used in IdentityProviders, Aad, + OpenID or OAuth. + :type client_secret: str + """ + + _attribute_map = { + 'client_secret': {'key': 'clientSecret', 'type': 'str'}, + } + + def __init__(self, *, client_secret: str=None, **kwargs) -> None: + super(ClientSecretContract, self).__init__(**kwargs) + self.client_secret = client_secret + + +class CloudError(Model): + """CloudError. + """ + + _attribute_map = { + } + + +class ConnectivityStatusContract(Model): + """Details about connectivity to a resource. + + All required parameters must be populated in order to send to Azure. + + :param name: Required. The hostname of the resource which the service + depends on. This can be the database, storage or any other azure resource + on which the service depends upon. + :type name: str + :param status: Required. Resource Connectivity Status Type identifier. + Possible values include: 'initializing', 'success', 'failure' + :type status: str or + ~azure.mgmt.apimanagement.models.ConnectivityStatusType + :param error: Error details of the connectivity to the resource. + :type error: str + :param last_updated: Required. The date when the resource connectivity + status was last updated. This status should be updated every 15 minutes. + If this status has not been updated, then it means that the service has + lost network connectivity to the resource, from inside the Virtual + Network.The date conforms to the following format: `yyyy-MM-ddTHH:mm:ssZ` + as specified by the ISO 8601 standard. + :type last_updated: datetime + :param last_status_change: Required. The date when the resource + connectivity status last Changed from success to failure or vice-versa. + The date conforms to the following format: `yyyy-MM-ddTHH:mm:ssZ` as + specified by the ISO 8601 standard. + :type last_status_change: datetime + """ + + _validation = { + 'name': {'required': True, 'min_length': 1}, + 'status': {'required': True}, + 'last_updated': {'required': True}, + 'last_status_change': {'required': True}, + } + + _attribute_map = { + 'name': {'key': 'name', 'type': 'str'}, + 'status': {'key': 'status', 'type': 'str'}, + 'error': {'key': 'error', 'type': 'str'}, + 'last_updated': {'key': 'lastUpdated', 'type': 'iso-8601'}, + 'last_status_change': {'key': 'lastStatusChange', 'type': 'iso-8601'}, + } + + def __init__(self, *, name: str, status, last_updated, last_status_change, error: str=None, **kwargs) -> None: + super(ConnectivityStatusContract, self).__init__(**kwargs) + self.name = name + self.status = status + self.error = error + self.last_updated = last_updated + self.last_status_change = last_status_change + + +class DeployConfigurationParameters(Model): + """Deploy Tenant Configuration Contract. + + All required parameters must be populated in order to send to Azure. + + :param branch: Required. The name of the Git branch from which the + configuration is to be deployed to the configuration database. + :type branch: str + :param force: The value enforcing deleting subscriptions to products that + are deleted in this update. + :type force: bool + """ + + _validation = { + 'branch': {'required': True}, + } + + _attribute_map = { + 'branch': {'key': 'properties.branch', 'type': 'str'}, + 'force': {'key': 'properties.force', 'type': 'bool'}, + } + + def __init__(self, *, branch: str, force: bool=None, **kwargs) -> None: + super(DeployConfigurationParameters, self).__init__(**kwargs) + self.branch = branch + self.force = force + + +class DiagnosticContract(Resource): + """Diagnostic details. + + Variables are only populated by the server, and will be ignored when + sending a request. + + All required parameters must be populated in order to send to Azure. + + :ivar id: Resource ID. + :vartype id: str + :ivar name: Resource name. + :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/outgoing HTTP messages + to the Gateway. + :type frontend: + ~azure.mgmt.apimanagement.models.PipelineDiagnosticSettings + :param backend: Diagnostic settings for incoming/outgoing HTTP messages to + the Backend + :type backend: ~azure.mgmt.apimanagement.models.PipelineDiagnosticSettings + :param log_client_ip: Log the ClientIP. Default is false. + :type log_client_ip: bool + :param http_correlation_protocol: Sets correlation protocol to use for + Application Insights diagnostics. Possible values include: 'None', + 'Legacy', 'W3C' + :type http_correlation_protocol: str or + ~azure.mgmt.apimanagement.models.HttpCorrelationProtocol + :param verbosity: The verbosity level applied to traces emitted by trace + policies. Possible values include: 'verbose', 'information', 'error' + :type verbosity: str or ~azure.mgmt.apimanagement.models.Verbosity + """ + + _validation = { + 'id': {'readonly': True}, + 'name': {'readonly': True}, + 'type': {'readonly': True}, + 'logger_id': {'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'}, + 'log_client_ip': {'key': 'properties.logClientIp', 'type': 'bool'}, + 'http_correlation_protocol': {'key': 'properties.httpCorrelationProtocol', 'type': 'str'}, + 'verbosity': {'key': 'properties.verbosity', 'type': 'str'}, + } + + def __init__(self, *, logger_id: str, always_log=None, sampling=None, frontend=None, backend=None, log_client_ip: bool=None, http_correlation_protocol=None, verbosity=None, **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.log_client_ip = log_client_ip + self.http_correlation_protocol = http_correlation_protocol + self.verbosity = verbosity + + +class EmailTemplateContract(Resource): + """Email Template details. + + Variables are only populated by the server, and will be ignored when + sending a request. + + All required parameters must be populated in order to send to Azure. + + :ivar id: Resource ID. + :vartype id: str + :ivar name: Resource name. + :vartype name: str + :ivar type: Resource type for API Management resource. + :vartype type: str + :param subject: Required. Subject of the Template. + :type subject: str + :param body: Required. Email Template Body. This should be a valid + XDocument + :type body: str + :param title: Title of the Template. + :type title: str + :param description: Description of the Email Template. + :type description: str + :ivar is_default: Whether the template is the default template provided by + Api Management or has been edited. + :vartype is_default: bool + :param parameters: Email Template Parameter values. + :type parameters: + list[~azure.mgmt.apimanagement.models.EmailTemplateParametersContractProperties] + """ + + _validation = { + 'id': {'readonly': True}, + 'name': {'readonly': True}, + 'type': {'readonly': True}, + 'subject': {'required': True, 'max_length': 1000, 'min_length': 1}, + 'body': {'required': True, 'min_length': 1}, + 'is_default': {'readonly': True}, + } + + _attribute_map = { + 'id': {'key': 'id', 'type': 'str'}, + 'name': {'key': 'name', 'type': 'str'}, + 'type': {'key': 'type', 'type': 'str'}, + 'subject': {'key': 'properties.subject', 'type': 'str'}, + 'body': {'key': 'properties.body', 'type': 'str'}, + 'title': {'key': 'properties.title', 'type': 'str'}, + 'description': {'key': 'properties.description', 'type': 'str'}, + 'is_default': {'key': 'properties.isDefault', 'type': 'bool'}, + 'parameters': {'key': 'properties.parameters', 'type': '[EmailTemplateParametersContractProperties]'}, + } + + def __init__(self, *, subject: str, body: str, title: str=None, description: str=None, parameters=None, **kwargs) -> None: + super(EmailTemplateContract, self).__init__(**kwargs) + self.subject = subject + self.body = body + self.title = title + self.description = description + self.is_default = None + self.parameters = parameters + + +class EmailTemplateParametersContractProperties(Model): + """Email Template Parameter contract. + + :param name: Template parameter name. + :type name: str + :param title: Template parameter title. + :type title: str + :param description: Template parameter description. + :type description: str + """ + + _validation = { + 'name': {'max_length': 256, 'min_length': 1, 'pattern': r'^[A-Za-z0-9-._]+$'}, + 'title': {'max_length': 4096, 'min_length': 1}, + 'description': {'max_length': 256, 'min_length': 1, 'pattern': r'^[A-Za-z0-9-._]+$'}, + } + + _attribute_map = { + 'name': {'key': 'name', 'type': 'str'}, + 'title': {'key': 'title', 'type': 'str'}, + 'description': {'key': 'description', 'type': 'str'}, + } + + def __init__(self, *, name: str=None, title: str=None, description: str=None, **kwargs) -> None: + super(EmailTemplateParametersContractProperties, self).__init__(**kwargs) + self.name = name + self.title = title + self.description = description + + +class EmailTemplateUpdateParameters(Model): + """Email Template update Parameters. + + :param subject: Subject of the Template. + :type subject: str + :param title: Title of the Template. + :type title: str + :param description: Description of the Email Template. + :type description: str + :param body: Email Template Body. This should be a valid XDocument + :type body: str + :param parameters: Email Template Parameter values. + :type parameters: + list[~azure.mgmt.apimanagement.models.EmailTemplateParametersContractProperties] + """ + + _validation = { + 'subject': {'max_length': 1000, 'min_length': 1}, + 'body': {'min_length': 1}, + } + + _attribute_map = { + 'subject': {'key': 'properties.subject', 'type': 'str'}, + 'title': {'key': 'properties.title', 'type': 'str'}, + 'description': {'key': 'properties.description', 'type': 'str'}, + 'body': {'key': 'properties.body', 'type': 'str'}, + 'parameters': {'key': 'properties.parameters', 'type': '[EmailTemplateParametersContractProperties]'}, + } + + def __init__(self, *, subject: str=None, title: str=None, description: str=None, body: str=None, parameters=None, **kwargs) -> None: + super(EmailTemplateUpdateParameters, self).__init__(**kwargs) + self.subject = subject + self.title = title + self.description = description + self.body = body + self.parameters = parameters + + +class ErrorFieldContract(Model): + """Error Field contract. + + :param code: Property level error code. + :type code: str + :param message: Human-readable representation of property-level error. + :type message: str + :param target: Property name. + :type target: str + """ + + _attribute_map = { + 'code': {'key': 'code', 'type': 'str'}, + 'message': {'key': 'message', 'type': 'str'}, + 'target': {'key': 'target', 'type': 'str'}, + } + + def __init__(self, *, code: str=None, message: str=None, target: str=None, **kwargs) -> None: + super(ErrorFieldContract, self).__init__(**kwargs) + self.code = code + self.message = message + self.target = target + + +class ErrorResponse(Model): + """Error Response. + + :param code: Service-defined error code. This code serves as a sub-status + for the HTTP error code specified in the response. + :type code: str + :param message: Human-readable representation of the error. + :type message: str + :param details: The list of invalid fields send in request, in case of + validation error. + :type details: list[~azure.mgmt.apimanagement.models.ErrorFieldContract] + """ + + _attribute_map = { + 'code': {'key': 'error.code', 'type': 'str'}, + 'message': {'key': 'error.message', 'type': 'str'}, + 'details': {'key': 'error.details', 'type': '[ErrorFieldContract]'}, + } + + def __init__(self, *, code: str=None, message: str=None, details=None, **kwargs) -> None: + super(ErrorResponse, self).__init__(**kwargs) + self.code = code + self.message = message + self.details = details + + +class ErrorResponseException(HttpOperationError): + """Server responsed with exception of type: 'ErrorResponse'. + + :param deserialize: A deserializer + :param response: Server response to be deserialized. + """ + + def __init__(self, deserialize, response, *args): + + super(ErrorResponseException, self).__init__(deserialize, response, 'ErrorResponse', *args) + + +class ErrorResponseBody(Model): + """Error Body contract. + + :param code: Service-defined error code. This code serves as a sub-status + for the HTTP error code specified in the response. + :type code: str + :param message: Human-readable representation of the error. + :type message: str + :param details: The list of invalid fields send in request, in case of + validation error. + :type details: list[~azure.mgmt.apimanagement.models.ErrorFieldContract] + """ + + _attribute_map = { + 'code': {'key': 'code', 'type': 'str'}, + 'message': {'key': 'message', 'type': 'str'}, + 'details': {'key': 'details', 'type': '[ErrorFieldContract]'}, + } + + def __init__(self, *, code: str=None, message: str=None, details=None, **kwargs) -> None: + super(ErrorResponseBody, self).__init__(**kwargs) + self.code = code + self.message = message + self.details = details + + +class GenerateSsoUrlResult(Model): + """Generate SSO Url operations response details. + + :param value: Redirect Url containing the SSO URL value. + :type value: str + """ + + _attribute_map = { + 'value': {'key': 'value', 'type': 'str'}, + } + + def __init__(self, *, value: str=None, **kwargs) -> None: + super(GenerateSsoUrlResult, self).__init__(**kwargs) + self.value = value + + +class GroupContract(Resource): + """Contract details. + + Variables are only populated by the server, and will be ignored when + sending a request. + + All required parameters must be populated in order to send to Azure. + + :ivar id: Resource ID. + :vartype id: str + :ivar name: Resource name. + :vartype name: str + :ivar type: Resource type for API Management resource. + :vartype type: str + :param display_name: Required. Group name. + :type display_name: str + :param description: Group description. Can contain HTML formatting tags. + :type description: str + :ivar built_in: true if the group is one of the three system groups + (Administrators, Developers, or Guests); otherwise false. + :vartype built_in: bool + :param group_contract_type: Group type. Possible values include: 'custom', + 'system', 'external' + :type group_contract_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/`; + otherwise the value is null. + :type external_id: str + """ + + _validation = { + 'id': {'readonly': True}, + 'name': {'readonly': True}, + 'type': {'readonly': True}, + 'display_name': {'required': True, 'max_length': 300, 'min_length': 1}, + 'description': {'max_length': 1000}, + 'built_in': {'readonly': True}, + } + + _attribute_map = { + 'id': {'key': 'id', 'type': 'str'}, + 'name': {'key': 'name', 'type': 'str'}, + 'type': {'key': 'type', 'type': 'str'}, + 'display_name': {'key': 'properties.displayName', 'type': 'str'}, + 'description': {'key': 'properties.description', 'type': 'str'}, + 'built_in': {'key': 'properties.builtIn', 'type': 'bool'}, + 'group_contract_type': {'key': 'properties.type', 'type': 'GroupType'}, + 'external_id': {'key': 'properties.externalId', 'type': 'str'}, + } + + def __init__(self, *, display_name: str, description: str=None, group_contract_type=None, external_id: str=None, **kwargs) -> None: + super(GroupContract, self).__init__(**kwargs) + self.display_name = display_name + self.description = description + self.built_in = None + self.group_contract_type = group_contract_type + self.external_id = external_id + + +class GroupContractProperties(Model): + """Group contract Properties. + + Variables are only populated by the server, and will be ignored when + sending a request. + + All required parameters must be populated in order to send to Azure. + + :param display_name: Required. Group name. + :type display_name: str + :param description: Group description. Can contain HTML formatting tags. + :type description: str + :ivar built_in: true if the group is one of the three system groups + (Administrators, Developers, or Guests); otherwise false. + :vartype built_in: bool + :param type: Group type. Possible values include: 'custom', 'system', + 'external' + :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/`; + otherwise the value is null. + :type external_id: str + """ + + _validation = { + 'display_name': {'required': True, 'max_length': 300, 'min_length': 1}, + 'description': {'max_length': 1000}, + 'built_in': {'readonly': True}, + } + + _attribute_map = { + 'display_name': {'key': 'displayName', 'type': 'str'}, + 'description': {'key': 'description', 'type': 'str'}, + 'built_in': {'key': 'builtIn', 'type': 'bool'}, + 'type': {'key': 'type', 'type': 'GroupType'}, + 'external_id': {'key': 'externalId', 'type': 'str'}, + } + + def __init__(self, *, display_name: str, description: str=None, type=None, external_id: str=None, **kwargs) -> None: + super(GroupContractProperties, self).__init__(**kwargs) + self.display_name = display_name + self.description = description + self.built_in = None + self.type = type + self.external_id = external_id + + +class GroupCreateParameters(Model): + """Parameters supplied to the Create Group operation. + + All required parameters must be populated in order to send to Azure. + + :param display_name: Required. Group name. + :type display_name: str + :param description: Group description. + :type description: str + :param type: Group type. Possible values include: 'custom', 'system', + 'external' + :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. + :type external_id: str + """ + + _validation = { + 'display_name': {'required': True, 'max_length': 300, 'min_length': 1}, + } + + _attribute_map = { + 'display_name': {'key': 'properties.displayName', 'type': 'str'}, + 'description': {'key': 'properties.description', 'type': 'str'}, + 'type': {'key': 'properties.type', 'type': 'GroupType'}, + 'external_id': {'key': 'properties.externalId', 'type': 'str'}, + } + + def __init__(self, *, display_name: str, description: str=None, type=None, external_id: str=None, **kwargs) -> None: + super(GroupCreateParameters, self).__init__(**kwargs) + self.display_name = display_name + self.description = description + self.type = type + self.external_id = external_id + + +class GroupUpdateParameters(Model): + """Parameters supplied to the Update Group operation. + + :param display_name: Group name. + :type display_name: str + :param description: Group description. + :type description: str + :param type: Group type. Possible values include: 'custom', 'system', + 'external' + :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. + :type external_id: str + """ + + _validation = { + 'display_name': {'max_length': 300, 'min_length': 1}, + } + + _attribute_map = { + 'display_name': {'key': 'properties.displayName', 'type': 'str'}, + 'description': {'key': 'properties.description', 'type': 'str'}, + 'type': {'key': 'properties.type', 'type': 'GroupType'}, + 'external_id': {'key': 'properties.externalId', 'type': 'str'}, + } + + def __init__(self, *, display_name: str=None, description: str=None, type=None, external_id: str=None, **kwargs) -> None: + super(GroupUpdateParameters, self).__init__(**kwargs) + self.display_name = display_name + self.description = description + self.type = type + self.external_id = external_id + + +class HostnameConfiguration(Model): + """Custom hostname configuration. + + All required parameters must be populated in order to send to Azure. + + :param type: Required. Hostname type. Possible values include: 'Proxy', + 'Portal', 'Management', 'Scm', 'DeveloperPortal' + :type type: str or ~azure.mgmt.apimanagement.models.HostnameType + :param host_name: Required. Hostname to configure on the Api Management + service. + :type host_name: str + :param key_vault_id: Url to the KeyVault Secret containing the Ssl + Certificate. If absolute Url containing version is provided, auto-update + of ssl certificate will not work. This requires Api Management service to + be configured with MSI. The secret should be of type + *application/x-pkcs12* + :type key_vault_id: str + :param encoded_certificate: Base64 Encoded certificate. + :type encoded_certificate: str + :param certificate_password: Certificate Password. + :type certificate_password: str + :param default_ssl_binding: Specify true to setup the certificate + associated with this Hostname as the Default SSL Certificate. If a client + does not send the SNI header, then this will be the certificate that will + be challenged. The property is useful if a service has multiple custom + hostname enabled and it needs to decide on the default ssl certificate. + The setting only applied to Proxy Hostname Type. Default value: False . + :type default_ssl_binding: bool + :param negotiate_client_certificate: Specify true to always negotiate + client certificate on the hostname. Default Value is false. Default value: + False . + :type negotiate_client_certificate: bool + :param certificate: Certificate information. + :type certificate: ~azure.mgmt.apimanagement.models.CertificateInformation + """ + + _validation = { + 'type': {'required': True}, + 'host_name': {'required': True}, + } + + _attribute_map = { + 'type': {'key': 'type', 'type': 'str'}, + 'host_name': {'key': 'hostName', 'type': 'str'}, + 'key_vault_id': {'key': 'keyVaultId', 'type': 'str'}, + 'encoded_certificate': {'key': 'encodedCertificate', 'type': 'str'}, + 'certificate_password': {'key': 'certificatePassword', 'type': 'str'}, + 'default_ssl_binding': {'key': 'defaultSslBinding', 'type': 'bool'}, + 'negotiate_client_certificate': {'key': 'negotiateClientCertificate', 'type': 'bool'}, + 'certificate': {'key': 'certificate', 'type': 'CertificateInformation'}, + } + + def __init__(self, *, type, host_name: str, key_vault_id: str=None, encoded_certificate: str=None, certificate_password: str=None, default_ssl_binding: bool=False, negotiate_client_certificate: bool=False, certificate=None, **kwargs) -> None: + super(HostnameConfiguration, self).__init__(**kwargs) + self.type = type + self.host_name = host_name + self.key_vault_id = key_vault_id + self.encoded_certificate = encoded_certificate + self.certificate_password = certificate_password + self.default_ssl_binding = default_ssl_binding + self.negotiate_client_certificate = negotiate_client_certificate + self.certificate = certificate + + +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 + + +class IdentityProviderBaseParameters(Model): + """Identity Provider Base Parameter Properties. + + :param type: Identity Provider Type identifier. Possible values include: + 'facebook', 'google', 'microsoft', 'twitter', 'aad', 'aadB2C' + :type type: str or ~azure.mgmt.apimanagement.models.IdentityProviderType + :param signin_tenant: The TenantId to use instead of Common when logging + into Active Directory + :type signin_tenant: str + :param allowed_tenants: List of Allowed Tenants when configuring Azure + Active Directory login. + :type allowed_tenants: list[str] + :param authority: OpenID Connect discovery endpoint hostname for AAD or + AAD B2C. + :type authority: str + :param signup_policy_name: Signup Policy Name. Only applies to AAD B2C + Identity Provider. + :type signup_policy_name: str + :param signin_policy_name: Signin Policy Name. Only applies to AAD B2C + Identity Provider. + :type signin_policy_name: str + :param profile_editing_policy_name: Profile Editing Policy Name. Only + applies to AAD B2C Identity Provider. + :type profile_editing_policy_name: str + :param password_reset_policy_name: Password Reset Policy Name. Only + applies to AAD B2C Identity Provider. + :type password_reset_policy_name: str + """ + + _validation = { + 'allowed_tenants': {'max_items': 32}, + 'signup_policy_name': {'min_length': 1}, + 'signin_policy_name': {'min_length': 1}, + 'profile_editing_policy_name': {'min_length': 1}, + 'password_reset_policy_name': {'min_length': 1}, + } + + _attribute_map = { + 'type': {'key': 'type', 'type': 'str'}, + 'signin_tenant': {'key': 'signinTenant', 'type': 'str'}, + 'allowed_tenants': {'key': 'allowedTenants', 'type': '[str]'}, + 'authority': {'key': 'authority', 'type': 'str'}, + 'signup_policy_name': {'key': 'signupPolicyName', 'type': 'str'}, + 'signin_policy_name': {'key': 'signinPolicyName', 'type': 'str'}, + 'profile_editing_policy_name': {'key': 'profileEditingPolicyName', 'type': 'str'}, + 'password_reset_policy_name': {'key': 'passwordResetPolicyName', 'type': 'str'}, + } + + def __init__(self, *, type=None, signin_tenant: str=None, allowed_tenants=None, authority: str=None, signup_policy_name: str=None, signin_policy_name: str=None, profile_editing_policy_name: str=None, password_reset_policy_name: str=None, **kwargs) -> None: + super(IdentityProviderBaseParameters, self).__init__(**kwargs) + self.type = type + self.signin_tenant = signin_tenant + self.allowed_tenants = allowed_tenants + self.authority = authority + self.signup_policy_name = signup_policy_name + self.signin_policy_name = signin_policy_name + self.profile_editing_policy_name = profile_editing_policy_name + self.password_reset_policy_name = password_reset_policy_name + + +class IdentityProviderContract(Resource): + """Identity Provider details. + + Variables are only populated by the server, and will be ignored when + sending a request. + + All required parameters must be populated in order to send to Azure. + + :ivar id: Resource ID. + :vartype id: str + :ivar name: Resource name. + :vartype name: str + :ivar type: Resource type for API Management resource. + :vartype type: str + :param identity_provider_contract_type: Identity Provider Type identifier. + Possible values include: 'facebook', 'google', 'microsoft', 'twitter', + 'aad', 'aadB2C' + :type identity_provider_contract_type: str or + ~azure.mgmt.apimanagement.models.IdentityProviderType + :param signin_tenant: The TenantId to use instead of Common when logging + into Active Directory + :type signin_tenant: str + :param allowed_tenants: List of Allowed Tenants when configuring Azure + Active Directory login. + :type allowed_tenants: list[str] + :param authority: OpenID Connect discovery endpoint hostname for AAD or + AAD B2C. + :type authority: str + :param signup_policy_name: Signup Policy Name. Only applies to AAD B2C + Identity Provider. + :type signup_policy_name: str + :param signin_policy_name: Signin Policy Name. Only applies to AAD B2C + Identity Provider. + :type signin_policy_name: str + :param profile_editing_policy_name: Profile Editing Policy Name. Only + applies to AAD B2C Identity Provider. + :type profile_editing_policy_name: str + :param password_reset_policy_name: Password Reset Policy Name. Only + applies to AAD B2C Identity Provider. + :type password_reset_policy_name: str + :param client_id: Required. Client Id of the Application in the external + Identity Provider. It is App ID for Facebook login, Client ID for Google + login, App ID for Microsoft. + :type client_id: str + :param client_secret: Client secret of the Application in external + Identity Provider, used to authenticate login request. For example, it is + App Secret for Facebook login, API Key for Google login, Public Key for + Microsoft. This property will not be filled on 'GET' operations! Use + '/listSecrets' POST request to get the value. + :type client_secret: str + """ + + _validation = { + 'id': {'readonly': True}, + 'name': {'readonly': True}, + 'type': {'readonly': True}, + 'allowed_tenants': {'max_items': 32}, + 'signup_policy_name': {'min_length': 1}, + 'signin_policy_name': {'min_length': 1}, + 'profile_editing_policy_name': {'min_length': 1}, + 'password_reset_policy_name': {'min_length': 1}, + 'client_id': {'required': True, 'min_length': 1}, + 'client_secret': {'min_length': 1}, + } + + _attribute_map = { + 'id': {'key': 'id', 'type': 'str'}, + 'name': {'key': 'name', 'type': 'str'}, + 'type': {'key': 'type', 'type': 'str'}, + 'identity_provider_contract_type': {'key': 'properties.type', 'type': 'str'}, + 'signin_tenant': {'key': 'properties.signinTenant', 'type': 'str'}, + 'allowed_tenants': {'key': 'properties.allowedTenants', 'type': '[str]'}, + 'authority': {'key': 'properties.authority', 'type': 'str'}, + 'signup_policy_name': {'key': 'properties.signupPolicyName', 'type': 'str'}, + 'signin_policy_name': {'key': 'properties.signinPolicyName', 'type': 'str'}, + 'profile_editing_policy_name': {'key': 'properties.profileEditingPolicyName', 'type': 'str'}, + 'password_reset_policy_name': {'key': 'properties.passwordResetPolicyName', 'type': 'str'}, + 'client_id': {'key': 'properties.clientId', 'type': 'str'}, + 'client_secret': {'key': 'properties.clientSecret', 'type': 'str'}, + } + + def __init__(self, *, client_id: str, identity_provider_contract_type=None, signin_tenant: str=None, allowed_tenants=None, authority: str=None, signup_policy_name: str=None, signin_policy_name: str=None, profile_editing_policy_name: str=None, password_reset_policy_name: str=None, client_secret: str=None, **kwargs) -> None: + super(IdentityProviderContract, self).__init__(**kwargs) + self.identity_provider_contract_type = identity_provider_contract_type + self.signin_tenant = signin_tenant + self.allowed_tenants = allowed_tenants + self.authority = authority + self.signup_policy_name = signup_policy_name + self.signin_policy_name = signin_policy_name + self.profile_editing_policy_name = profile_editing_policy_name + self.password_reset_policy_name = password_reset_policy_name + self.client_id = client_id + self.client_secret = client_secret + + +class IdentityProviderCreateContract(Resource): + """Identity Provider details. + + Variables are only populated by the server, and will be ignored when + sending a request. + + All required parameters must be populated in order to send to Azure. + + :ivar id: Resource ID. + :vartype id: str + :ivar name: Resource name. + :vartype name: str + :ivar type: Resource type for API Management resource. + :vartype type: str + :param identity_provider_create_contract_type: Identity Provider Type + identifier. Possible values include: 'facebook', 'google', 'microsoft', + 'twitter', 'aad', 'aadB2C' + :type identity_provider_create_contract_type: str or + ~azure.mgmt.apimanagement.models.IdentityProviderType + :param signin_tenant: The TenantId to use instead of Common when logging + into Active Directory + :type signin_tenant: str + :param allowed_tenants: List of Allowed Tenants when configuring Azure + Active Directory login. + :type allowed_tenants: list[str] + :param authority: OpenID Connect discovery endpoint hostname for AAD or + AAD B2C. + :type authority: str + :param signup_policy_name: Signup Policy Name. Only applies to AAD B2C + Identity Provider. + :type signup_policy_name: str + :param signin_policy_name: Signin Policy Name. Only applies to AAD B2C + Identity Provider. + :type signin_policy_name: str + :param profile_editing_policy_name: Profile Editing Policy Name. Only + applies to AAD B2C Identity Provider. + :type profile_editing_policy_name: str + :param password_reset_policy_name: Password Reset Policy Name. Only + applies to AAD B2C Identity Provider. + :type password_reset_policy_name: str + :param client_id: Required. Client Id of the Application in the external + Identity Provider. It is App ID for Facebook login, Client ID for Google + login, App ID for Microsoft. + :type client_id: str + :param client_secret: Required. Client secret of the Application in + external Identity Provider, used to authenticate login request. For + example, it is App Secret for Facebook login, API Key for Google login, + Public Key for Microsoft. This property will not be filled on 'GET' + operations! Use '/listSecrets' POST request to get the value. + :type client_secret: str + """ + + _validation = { + 'id': {'readonly': True}, + 'name': {'readonly': True}, + 'type': {'readonly': True}, + 'allowed_tenants': {'max_items': 32}, + 'signup_policy_name': {'min_length': 1}, + 'signin_policy_name': {'min_length': 1}, + 'profile_editing_policy_name': {'min_length': 1}, + 'password_reset_policy_name': {'min_length': 1}, + 'client_id': {'required': True, 'min_length': 1}, + 'client_secret': {'required': True, 'min_length': 1}, + } + + _attribute_map = { + 'id': {'key': 'id', 'type': 'str'}, + 'name': {'key': 'name', 'type': 'str'}, + 'type': {'key': 'type', 'type': 'str'}, + 'identity_provider_create_contract_type': {'key': 'properties.type', 'type': 'str'}, + 'signin_tenant': {'key': 'properties.signinTenant', 'type': 'str'}, + 'allowed_tenants': {'key': 'properties.allowedTenants', 'type': '[str]'}, + 'authority': {'key': 'properties.authority', 'type': 'str'}, + 'signup_policy_name': {'key': 'properties.signupPolicyName', 'type': 'str'}, + 'signin_policy_name': {'key': 'properties.signinPolicyName', 'type': 'str'}, + 'profile_editing_policy_name': {'key': 'properties.profileEditingPolicyName', 'type': 'str'}, + 'password_reset_policy_name': {'key': 'properties.passwordResetPolicyName', 'type': 'str'}, + 'client_id': {'key': 'properties.clientId', 'type': 'str'}, + 'client_secret': {'key': 'properties.clientSecret', 'type': 'str'}, + } + + def __init__(self, *, client_id: str, client_secret: str, identity_provider_create_contract_type=None, signin_tenant: str=None, allowed_tenants=None, authority: str=None, signup_policy_name: str=None, signin_policy_name: str=None, profile_editing_policy_name: str=None, password_reset_policy_name: str=None, **kwargs) -> None: + super(IdentityProviderCreateContract, self).__init__(**kwargs) + self.identity_provider_create_contract_type = identity_provider_create_contract_type + self.signin_tenant = signin_tenant + self.allowed_tenants = allowed_tenants + self.authority = authority + self.signup_policy_name = signup_policy_name + self.signin_policy_name = signin_policy_name + self.profile_editing_policy_name = profile_editing_policy_name + self.password_reset_policy_name = password_reset_policy_name + self.client_id = client_id + self.client_secret = client_secret + + +class IdentityProviderUpdateParameters(Model): + """Parameters supplied to update Identity Provider. + + :param type: Identity Provider Type identifier. Possible values include: + 'facebook', 'google', 'microsoft', 'twitter', 'aad', 'aadB2C' + :type type: str or ~azure.mgmt.apimanagement.models.IdentityProviderType + :param signin_tenant: The TenantId to use instead of Common when logging + into Active Directory + :type signin_tenant: str + :param allowed_tenants: List of Allowed Tenants when configuring Azure + Active Directory login. + :type allowed_tenants: list[str] + :param authority: OpenID Connect discovery endpoint hostname for AAD or + AAD B2C. + :type authority: str + :param signup_policy_name: Signup Policy Name. Only applies to AAD B2C + Identity Provider. + :type signup_policy_name: str + :param signin_policy_name: Signin Policy Name. Only applies to AAD B2C + Identity Provider. + :type signin_policy_name: str + :param profile_editing_policy_name: Profile Editing Policy Name. Only + applies to AAD B2C Identity Provider. + :type profile_editing_policy_name: str + :param password_reset_policy_name: Password Reset Policy Name. Only + applies to AAD B2C Identity Provider. + :type password_reset_policy_name: str + :param client_id: Client Id of the Application in the external Identity + Provider. It is App ID for Facebook login, Client ID for Google login, App + ID for Microsoft. + :type client_id: str + :param client_secret: Client secret of the Application in external + Identity Provider, used to authenticate login request. For example, it is + App Secret for Facebook login, API Key for Google login, Public Key for + Microsoft. + :type client_secret: str + """ + + _validation = { + 'allowed_tenants': {'max_items': 32}, + 'signup_policy_name': {'min_length': 1}, + 'signin_policy_name': {'min_length': 1}, + 'profile_editing_policy_name': {'min_length': 1}, + 'password_reset_policy_name': {'min_length': 1}, + 'client_id': {'min_length': 1}, + 'client_secret': {'min_length': 1}, + } + + _attribute_map = { + 'type': {'key': 'properties.type', 'type': 'str'}, + 'signin_tenant': {'key': 'properties.signinTenant', 'type': 'str'}, + 'allowed_tenants': {'key': 'properties.allowedTenants', 'type': '[str]'}, + 'authority': {'key': 'properties.authority', 'type': 'str'}, + 'signup_policy_name': {'key': 'properties.signupPolicyName', 'type': 'str'}, + 'signin_policy_name': {'key': 'properties.signinPolicyName', 'type': 'str'}, + 'profile_editing_policy_name': {'key': 'properties.profileEditingPolicyName', 'type': 'str'}, + 'password_reset_policy_name': {'key': 'properties.passwordResetPolicyName', 'type': 'str'}, + 'client_id': {'key': 'properties.clientId', 'type': 'str'}, + 'client_secret': {'key': 'properties.clientSecret', 'type': 'str'}, + } + + def __init__(self, *, type=None, signin_tenant: str=None, allowed_tenants=None, authority: str=None, signup_policy_name: str=None, signin_policy_name: str=None, profile_editing_policy_name: str=None, password_reset_policy_name: str=None, client_id: str=None, client_secret: str=None, **kwargs) -> None: + super(IdentityProviderUpdateParameters, self).__init__(**kwargs) + self.type = type + self.signin_tenant = signin_tenant + self.allowed_tenants = allowed_tenants + self.authority = authority + self.signup_policy_name = signup_policy_name + self.signin_policy_name = signin_policy_name + self.profile_editing_policy_name = profile_editing_policy_name + self.password_reset_policy_name = password_reset_policy_name + self.client_id = client_id + self.client_secret = client_secret + + +class IssueAttachmentContract(Resource): + """Issue Attachment Contract details. + + Variables are only populated by the server, and will be ignored when + sending a request. + + All required parameters must be populated in order to send to Azure. + + :ivar id: Resource ID. + :vartype id: str + :ivar name: Resource name. + :vartype name: str + :ivar type: Resource type for API Management resource. + :vartype type: str + :param title: Required. Filename by which the binary data will be saved. + :type title: str + :param content_format: Required. Either 'link' if content is provided via + an HTTP link or the MIME type of the Base64-encoded binary data provided + in the 'content' property. + :type content_format: str + :param content: Required. An HTTP link or Base64-encoded binary data. + :type content: str + """ + + _validation = { + 'id': {'readonly': True}, + 'name': {'readonly': True}, + 'type': {'readonly': True}, + 'title': {'required': True}, + 'content_format': {'required': True}, + 'content': {'required': True}, + } + + _attribute_map = { + 'id': {'key': 'id', 'type': 'str'}, + 'name': {'key': 'name', 'type': 'str'}, + 'type': {'key': 'type', 'type': 'str'}, + 'title': {'key': 'properties.title', 'type': 'str'}, + 'content_format': {'key': 'properties.contentFormat', 'type': 'str'}, + 'content': {'key': 'properties.content', 'type': 'str'}, + } + + def __init__(self, *, title: str, content_format: str, content: str, **kwargs) -> None: + super(IssueAttachmentContract, self).__init__(**kwargs) + self.title = title + self.content_format = content_format + self.content = content + + +class IssueCommentContract(Resource): + """Issue Comment Contract details. + + Variables are only populated by the server, and will be ignored when + sending a request. + + All required parameters must be populated in order to send to Azure. + + :ivar id: Resource ID. + :vartype id: str + :ivar name: Resource name. + :vartype name: str + :ivar type: Resource type for API Management resource. + :vartype type: str + :param text: Required. Comment text. + :type text: str + :param created_date: Date and time when the comment was created. + :type created_date: datetime + :param user_id: Required. A resource identifier for the user who left the + comment. + :type user_id: str + """ + + _validation = { + 'id': {'readonly': True}, + 'name': {'readonly': True}, + 'type': {'readonly': True}, + 'text': {'required': True}, + 'user_id': {'required': True}, + } + + _attribute_map = { + 'id': {'key': 'id', 'type': 'str'}, + 'name': {'key': 'name', 'type': 'str'}, + 'type': {'key': 'type', 'type': 'str'}, + 'text': {'key': 'properties.text', 'type': 'str'}, + 'created_date': {'key': 'properties.createdDate', 'type': 'iso-8601'}, + 'user_id': {'key': 'properties.userId', 'type': 'str'}, + } + + def __init__(self, *, text: str, user_id: str, created_date=None, **kwargs) -> None: + super(IssueCommentContract, self).__init__(**kwargs) + self.text = text + self.created_date = created_date + self.user_id = user_id + + +class IssueContract(Resource): + """Issue Contract details. + + Variables are only populated by the server, and will be ignored when + sending a request. + + All required parameters must be populated in order to send to Azure. + + :ivar id: Resource ID. + :vartype id: str + :ivar name: Resource name. + :vartype name: str + :ivar type: Resource type for API Management resource. + :vartype type: str + :param created_date: Date and time when the issue was created. + :type created_date: datetime + :param state: Status of the issue. Possible values include: 'proposed', + 'open', 'removed', 'resolved', 'closed' + :type state: str or ~azure.mgmt.apimanagement.models.State + :param api_id: A resource identifier for the API the issue was created + for. + :type api_id: str + :param title: Required. The issue title. + :type title: str + :param description: Required. Text describing the issue. + :type description: str + :param user_id: Required. A resource identifier for the user created the + issue. + :type user_id: str + """ + + _validation = { + 'id': {'readonly': True}, + 'name': {'readonly': True}, + 'type': {'readonly': True}, + 'title': {'required': True}, + 'description': {'required': True}, + 'user_id': {'required': True}, + } + + _attribute_map = { + 'id': {'key': 'id', 'type': 'str'}, + 'name': {'key': 'name', 'type': 'str'}, + 'type': {'key': 'type', 'type': 'str'}, + 'created_date': {'key': 'properties.createdDate', 'type': 'iso-8601'}, + 'state': {'key': 'properties.state', 'type': 'str'}, + 'api_id': {'key': 'properties.apiId', 'type': 'str'}, + 'title': {'key': 'properties.title', 'type': 'str'}, + 'description': {'key': 'properties.description', 'type': 'str'}, + 'user_id': {'key': 'properties.userId', 'type': 'str'}, + } + + def __init__(self, *, title: str, description: str, user_id: str, created_date=None, state=None, api_id: str=None, **kwargs) -> None: + super(IssueContract, self).__init__(**kwargs) + self.created_date = created_date + self.state = state + self.api_id = api_id + self.title = title + self.description = description + self.user_id = user_id + + +class IssueContractBaseProperties(Model): + """Issue contract Base Properties. + + :param created_date: Date and time when the issue was created. + :type created_date: datetime + :param state: Status of the issue. Possible values include: 'proposed', + 'open', 'removed', 'resolved', 'closed' + :type state: str or ~azure.mgmt.apimanagement.models.State + :param api_id: A resource identifier for the API the issue was created + for. + :type api_id: str + """ + + _attribute_map = { + 'created_date': {'key': 'createdDate', 'type': 'iso-8601'}, + 'state': {'key': 'state', 'type': 'str'}, + 'api_id': {'key': 'apiId', 'type': 'str'}, + } + + def __init__(self, *, created_date=None, state=None, api_id: str=None, **kwargs) -> None: + super(IssueContractBaseProperties, self).__init__(**kwargs) + self.created_date = created_date + self.state = state + self.api_id = api_id + + +class IssueUpdateContract(Model): + """Issue update Parameters. + + :param created_date: Date and time when the issue was created. + :type created_date: datetime + :param state: Status of the issue. Possible values include: 'proposed', + 'open', 'removed', 'resolved', 'closed' + :type state: str or ~azure.mgmt.apimanagement.models.State + :param api_id: A resource identifier for the API the issue was created + for. + :type api_id: str + :param title: The issue title. + :type title: str + :param description: Text describing the issue. + :type description: str + :param user_id: A resource identifier for the user created the issue. + :type user_id: str + """ + + _attribute_map = { + 'created_date': {'key': 'properties.createdDate', 'type': 'iso-8601'}, + 'state': {'key': 'properties.state', 'type': 'str'}, + 'api_id': {'key': 'properties.apiId', 'type': 'str'}, + 'title': {'key': 'properties.title', 'type': 'str'}, + 'description': {'key': 'properties.description', 'type': 'str'}, + 'user_id': {'key': 'properties.userId', 'type': 'str'}, + } + + def __init__(self, *, created_date=None, state=None, api_id: str=None, title: str=None, description: str=None, user_id: str=None, **kwargs) -> None: + super(IssueUpdateContract, self).__init__(**kwargs) + self.created_date = created_date + self.state = state + self.api_id = api_id + self.title = title + self.description = description + self.user_id = user_id + + +class LoggerContract(Resource): + """Logger details. + + Variables are only populated by the server, and will be ignored when + sending a request. + + All required parameters must be populated in order to send to Azure. + + :ivar id: Resource ID. + :vartype id: str + :ivar name: Resource name. + :vartype name: str + :ivar type: Resource type for API Management resource. + :vartype type: str + :param logger_type: Required. Logger type. Possible values include: + 'azureEventHub', 'applicationInsights' + :type logger_type: str or ~azure.mgmt.apimanagement.models.LoggerType + :param description: Logger description. + :type description: str + :param credentials: Required. The name and SendRule connection string of + the event hub for azureEventHub logger. + Instrumentation key for applicationInsights logger. + :type credentials: dict[str, str] + :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 = { + 'id': {'readonly': True}, + 'name': {'readonly': True}, + 'type': {'readonly': True}, + 'logger_type': {'required': True}, + 'description': {'max_length': 256}, + 'credentials': {'required': True}, + } + + _attribute_map = { + 'id': {'key': 'id', 'type': 'str'}, + 'name': {'key': 'name', 'type': 'str'}, + 'type': {'key': 'type', 'type': 'str'}, + 'logger_type': {'key': 'properties.loggerType', 'type': 'str'}, + '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: + 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 + + +class LoggerUpdateContract(Model): + """Logger update contract. + + :param logger_type: Logger type. Possible values include: 'azureEventHub', + 'applicationInsights' + :type logger_type: str or ~azure.mgmt.apimanagement.models.LoggerType + :param description: Logger description. + :type description: str + :param credentials: Logger credentials. + :type credentials: dict[str, str] + :param is_buffered: Whether records are buffered in the logger before + publishing. Default is assumed to be true. + :type is_buffered: bool + """ + + _attribute_map = { + 'logger_type': {'key': 'properties.loggerType', 'type': 'str'}, + 'description': {'key': 'properties.description', 'type': 'str'}, + 'credentials': {'key': 'properties.credentials', 'type': '{str}'}, + 'is_buffered': {'key': 'properties.isBuffered', 'type': 'bool'}, + } + + def __init__(self, *, logger_type=None, description: str=None, credentials=None, is_buffered: bool=None, **kwargs) -> None: + super(LoggerUpdateContract, self).__init__(**kwargs) + self.logger_type = logger_type + self.description = description + self.credentials = credentials + self.is_buffered = is_buffered + + +class NamedValueContract(Resource): + """NamedValue details. + + Variables are only populated by the server, and will be ignored when + sending a request. + + All required parameters must be populated in order to send to Azure. + + :ivar id: Resource ID. + :vartype id: str + :ivar name: Resource name. + :vartype name: str + :ivar type: Resource type for API Management resource. + :vartype type: str + :param tags: Optional tags that when provided can be used to filter the + NamedValue list. + :type tags: list[str] + :param secret: Determines whether the value is a secret and should be + encrypted or not. Default value is false. + :type secret: bool + :param display_name: Required. Unique name of NamedValue. It may contain + only letters, digits, period, dash, and underscore characters. + :type display_name: str + :param value: Value of the NamedValue. Can contain policy expressions. It + may not be empty or consist only of whitespace. This property will not be + filled on 'GET' operations! Use '/listSecrets' POST request to get the + value. + :type value: str + """ + + _validation = { + 'id': {'readonly': True}, + 'name': {'readonly': True}, + 'type': {'readonly': True}, + 'tags': {'max_items': 32}, + 'display_name': {'required': True, 'max_length': 256, 'min_length': 1, 'pattern': r'^[A-Za-z0-9-._]+$'}, + 'value': {'max_length': 4096, 'min_length': 1}, + } + + _attribute_map = { + 'id': {'key': 'id', 'type': 'str'}, + 'name': {'key': 'name', 'type': 'str'}, + 'type': {'key': 'type', 'type': 'str'}, + 'tags': {'key': 'properties.tags', 'type': '[str]'}, + 'secret': {'key': 'properties.secret', 'type': 'bool'}, + 'display_name': {'key': 'properties.displayName', 'type': 'str'}, + 'value': {'key': 'properties.value', 'type': 'str'}, + } + + def __init__(self, *, display_name: str, tags=None, secret: bool=None, value: str=None, **kwargs) -> None: + super(NamedValueContract, self).__init__(**kwargs) + self.tags = tags + self.secret = secret + self.display_name = display_name + self.value = value + + +class NamedValueCreateContract(Resource): + """NamedValue details. + + Variables are only populated by the server, and will be ignored when + sending a request. + + All required parameters must be populated in order to send to Azure. + + :ivar id: Resource ID. + :vartype id: str + :ivar name: Resource name. + :vartype name: str + :ivar type: Resource type for API Management resource. + :vartype type: str + :param tags: Optional tags that when provided can be used to filter the + NamedValue list. + :type tags: list[str] + :param secret: Determines whether the value is a secret and should be + encrypted or not. Default value is false. + :type secret: bool + :param display_name: Required. Unique name of NamedValue. It may contain + only letters, digits, period, dash, and underscore characters. + :type display_name: str + :param value: Required. Value of the NamedValue. Can contain policy + expressions. It may not be empty or consist only of whitespace. This + property will not be filled on 'GET' operations! Use '/listSecrets' POST + request to get the value. + :type value: str + """ + + _validation = { + 'id': {'readonly': True}, + 'name': {'readonly': True}, + 'type': {'readonly': True}, + 'tags': {'max_items': 32}, + 'display_name': {'required': True, 'max_length': 256, 'min_length': 1, 'pattern': r'^[A-Za-z0-9-._]+$'}, + 'value': {'required': True, 'max_length': 4096, 'min_length': 1}, + } + + _attribute_map = { + 'id': {'key': 'id', 'type': 'str'}, + 'name': {'key': 'name', 'type': 'str'}, + 'type': {'key': 'type', 'type': 'str'}, + 'tags': {'key': 'properties.tags', 'type': '[str]'}, + 'secret': {'key': 'properties.secret', 'type': 'bool'}, + 'display_name': {'key': 'properties.displayName', 'type': 'str'}, + 'value': {'key': 'properties.value', 'type': 'str'}, + } + + def __init__(self, *, display_name: str, value: str, tags=None, secret: bool=None, **kwargs) -> None: + super(NamedValueCreateContract, self).__init__(**kwargs) + self.tags = tags + self.secret = secret + self.display_name = display_name + self.value = value + + +class NamedValueEntityBaseParameters(Model): + """NamedValue Entity Base Parameters set. + + :param tags: Optional tags that when provided can be used to filter the + NamedValue list. + :type tags: list[str] + :param secret: Determines whether the value is a secret and should be + encrypted or not. Default value is false. + :type secret: bool + """ + + _validation = { + 'tags': {'max_items': 32}, + } + + _attribute_map = { + 'tags': {'key': 'tags', 'type': '[str]'}, + 'secret': {'key': 'secret', 'type': 'bool'}, + } + + def __init__(self, *, tags=None, secret: bool=None, **kwargs) -> None: + super(NamedValueEntityBaseParameters, self).__init__(**kwargs) + self.tags = tags + self.secret = secret + + +class NamedValueUpdateParameters(Model): + """NamedValue update Parameters. + + :param tags: Optional tags that when provided can be used to filter the + NamedValue list. + :type tags: list[str] + :param secret: Determines whether the value is a secret and should be + encrypted or not. Default value is false. + :type secret: bool + :param display_name: Unique name of NamedValue. It may contain only + letters, digits, period, dash, and underscore characters. + :type display_name: str + :param value: Value of the NamedValue. Can contain policy expressions. It + may not be empty or consist only of whitespace. + :type value: str + """ + + _validation = { + 'tags': {'max_items': 32}, + 'display_name': {'max_length': 256, 'min_length': 1, 'pattern': r'^[A-Za-z0-9-._]+$'}, + 'value': {'max_length': 4096, 'min_length': 1}, + } + + _attribute_map = { + 'tags': {'key': 'properties.tags', 'type': '[str]'}, + 'secret': {'key': 'properties.secret', 'type': 'bool'}, + 'display_name': {'key': 'properties.displayName', 'type': 'str'}, + 'value': {'key': 'properties.value', 'type': 'str'}, + } + + def __init__(self, *, tags=None, secret: bool=None, display_name: str=None, value: str=None, **kwargs) -> None: + super(NamedValueUpdateParameters, self).__init__(**kwargs) + self.tags = tags + self.secret = secret + self.display_name = display_name + self.value = value + + +class NetworkStatusContract(Model): + """Network Status details. + + All required parameters must be populated in order to send to Azure. + + :param dns_servers: Required. Gets the list of DNS servers IPV4 addresses. + :type dns_servers: list[str] + :param connectivity_status: Required. Gets the list of Connectivity Status + to the Resources on which the service depends upon. + :type connectivity_status: + list[~azure.mgmt.apimanagement.models.ConnectivityStatusContract] + """ + + _validation = { + 'dns_servers': {'required': True}, + 'connectivity_status': {'required': True}, + } + + _attribute_map = { + 'dns_servers': {'key': 'dnsServers', 'type': '[str]'}, + 'connectivity_status': {'key': 'connectivityStatus', 'type': '[ConnectivityStatusContract]'}, + } + + def __init__(self, *, dns_servers, connectivity_status, **kwargs) -> None: + super(NetworkStatusContract, self).__init__(**kwargs) + self.dns_servers = dns_servers + self.connectivity_status = connectivity_status + + +class NetworkStatusContractByLocation(Model): + """Network Status in the Location. + + :param location: Location of service + :type location: str + :param network_status: Network status in Location + :type network_status: + ~azure.mgmt.apimanagement.models.NetworkStatusContract + """ + + _validation = { + 'location': {'min_length': 1}, + } + + _attribute_map = { + 'location': {'key': 'location', 'type': 'str'}, + 'network_status': {'key': 'networkStatus', 'type': 'NetworkStatusContract'}, + } + + def __init__(self, *, location: str=None, network_status=None, **kwargs) -> None: + super(NetworkStatusContractByLocation, self).__init__(**kwargs) + self.location = location + self.network_status = network_status + + +class NotificationContract(Resource): + """Notification details. + + Variables are only populated by the server, and will be ignored when + sending a request. + + All required parameters must be populated in order to send to Azure. + + :ivar id: Resource ID. + :vartype id: str + :ivar name: Resource name. + :vartype name: str + :ivar type: Resource type for API Management resource. + :vartype type: str + :param title: Required. Title of the Notification. + :type title: str + :param description: Description of the Notification. + :type description: str + :param recipients: Recipient Parameter values. + :type recipients: + ~azure.mgmt.apimanagement.models.RecipientsContractProperties + """ + + _validation = { + 'id': {'readonly': True}, + 'name': {'readonly': True}, + 'type': {'readonly': True}, + 'title': {'required': True, 'max_length': 1000, 'min_length': 1}, + } + + _attribute_map = { + 'id': {'key': 'id', 'type': 'str'}, + 'name': {'key': 'name', 'type': 'str'}, + 'type': {'key': 'type', 'type': 'str'}, + 'title': {'key': 'properties.title', 'type': 'str'}, + 'description': {'key': 'properties.description', 'type': 'str'}, + 'recipients': {'key': 'properties.recipients', 'type': 'RecipientsContractProperties'}, + } + + def __init__(self, *, title: str, description: str=None, recipients=None, **kwargs) -> None: + super(NotificationContract, self).__init__(**kwargs) + self.title = title + self.description = description + self.recipients = recipients + + +class OAuth2AuthenticationSettingsContract(Model): + """API OAuth2 Authentication settings details. + + :param authorization_server_id: OAuth authorization server identifier. + :type authorization_server_id: str + :param scope: operations scope. + :type scope: str + """ + + _attribute_map = { + 'authorization_server_id': {'key': 'authorizationServerId', 'type': 'str'}, + 'scope': {'key': 'scope', 'type': 'str'}, + } + + def __init__(self, *, authorization_server_id: str=None, scope: str=None, **kwargs) -> None: + super(OAuth2AuthenticationSettingsContract, self).__init__(**kwargs) + self.authorization_server_id = authorization_server_id + self.scope = scope + + +class OpenIdAuthenticationSettingsContract(Model): + """API OAuth2 Authentication settings details. + + :param openid_provider_id: OAuth authorization server identifier. + :type openid_provider_id: str + :param bearer_token_sending_methods: How to send token to the server. + :type bearer_token_sending_methods: list[str or + ~azure.mgmt.apimanagement.models.BearerTokenSendingMethods] + """ + + _attribute_map = { + 'openid_provider_id': {'key': 'openidProviderId', 'type': 'str'}, + 'bearer_token_sending_methods': {'key': 'bearerTokenSendingMethods', 'type': '[str]'}, + } + + def __init__(self, *, openid_provider_id: str=None, bearer_token_sending_methods=None, **kwargs) -> None: + super(OpenIdAuthenticationSettingsContract, self).__init__(**kwargs) + self.openid_provider_id = openid_provider_id + self.bearer_token_sending_methods = bearer_token_sending_methods + + +class OpenidConnectProviderContract(Resource): + """OpenId Connect Provider details. + + Variables are only populated by the server, and will be ignored when + sending a request. + + All required parameters must be populated in order to send to Azure. + + :ivar id: Resource ID. + :vartype id: str + :ivar name: Resource name. + :vartype name: str + :ivar type: Resource type for API Management resource. + :vartype type: str + :param display_name: Required. User-friendly OpenID Connect Provider name. + :type display_name: str + :param description: User-friendly description of OpenID Connect Provider. + :type description: str + :param metadata_endpoint: Required. Metadata endpoint URI. + :type metadata_endpoint: str + :param client_id: Required. Client ID of developer console which is the + client application. + :type client_id: str + :param client_secret: Client Secret of developer console which is the + client application. + :type client_secret: str + """ + + _validation = { + 'id': {'readonly': True}, + 'name': {'readonly': True}, + 'type': {'readonly': True}, + 'display_name': {'required': True, 'max_length': 50}, + 'metadata_endpoint': {'required': True}, + 'client_id': {'required': True}, + } + + _attribute_map = { + 'id': {'key': 'id', 'type': 'str'}, + 'name': {'key': 'name', 'type': 'str'}, + 'type': {'key': 'type', 'type': 'str'}, + 'display_name': {'key': 'properties.displayName', 'type': 'str'}, + 'description': {'key': 'properties.description', 'type': 'str'}, + 'metadata_endpoint': {'key': 'properties.metadataEndpoint', 'type': 'str'}, + 'client_id': {'key': 'properties.clientId', 'type': 'str'}, + 'client_secret': {'key': 'properties.clientSecret', 'type': 'str'}, + } + + def __init__(self, *, display_name: str, metadata_endpoint: str, client_id: str, description: str=None, client_secret: str=None, **kwargs) -> None: + super(OpenidConnectProviderContract, self).__init__(**kwargs) + self.display_name = display_name + self.description = description + self.metadata_endpoint = metadata_endpoint + self.client_id = client_id + self.client_secret = client_secret + + +class OpenidConnectProviderCreateContract(Resource): + """OpenId Connect Provider details. + + Variables are only populated by the server, and will be ignored when + sending a request. + + All required parameters must be populated in order to send to Azure. + + :ivar id: Resource ID. + :vartype id: str + :ivar name: Resource name. + :vartype name: str + :ivar type: Resource type for API Management resource. + :vartype type: str + :param display_name: Required. User-friendly OpenID Connect Provider name. + :type display_name: str + :param description: User-friendly description of OpenID Connect Provider. + :type description: str + :param metadata_endpoint: Required. Metadata endpoint URI. + :type metadata_endpoint: str + :param client_id: Required. Client ID of developer console which is the + client application. + :type client_id: str + :param client_secret: Required. Client Secret of developer console which + is the client application. + :type client_secret: str + """ + + _validation = { + 'id': {'readonly': True}, + 'name': {'readonly': True}, + 'type': {'readonly': True}, + 'display_name': {'required': True, 'max_length': 50}, + 'metadata_endpoint': {'required': True}, + 'client_id': {'required': True}, + 'client_secret': {'required': True}, + } + + _attribute_map = { + 'id': {'key': 'id', 'type': 'str'}, + 'name': {'key': 'name', 'type': 'str'}, + 'type': {'key': 'type', 'type': 'str'}, + 'display_name': {'key': 'properties.displayName', 'type': 'str'}, + 'description': {'key': 'properties.description', 'type': 'str'}, + 'metadata_endpoint': {'key': 'properties.metadataEndpoint', 'type': 'str'}, + 'client_id': {'key': 'properties.clientId', 'type': 'str'}, + 'client_secret': {'key': 'properties.clientSecret', 'type': 'str'}, + } + + def __init__(self, *, display_name: str, metadata_endpoint: str, client_id: str, client_secret: str, description: str=None, **kwargs) -> None: + super(OpenidConnectProviderCreateContract, self).__init__(**kwargs) + self.display_name = display_name + self.description = description + self.metadata_endpoint = metadata_endpoint + self.client_id = client_id + self.client_secret = client_secret + + +class OpenidConnectProviderUpdateContract(Model): + """Parameters supplied to the Update OpenID Connect Provider operation. + + :param display_name: User-friendly OpenID Connect Provider name. + :type display_name: str + :param description: User-friendly description of OpenID Connect Provider. + :type description: str + :param metadata_endpoint: Metadata endpoint URI. + :type metadata_endpoint: str + :param client_id: Client ID of developer console which is the client + application. + :type client_id: str + :param client_secret: Client Secret of developer console which is the + client application. + :type client_secret: str + """ + + _validation = { + 'display_name': {'max_length': 50}, + } + + _attribute_map = { + 'display_name': {'key': 'properties.displayName', 'type': 'str'}, + 'description': {'key': 'properties.description', 'type': 'str'}, + 'metadata_endpoint': {'key': 'properties.metadataEndpoint', 'type': 'str'}, + 'client_id': {'key': 'properties.clientId', 'type': 'str'}, + 'client_secret': {'key': 'properties.clientSecret', 'type': 'str'}, + } + + def __init__(self, *, display_name: str=None, description: str=None, metadata_endpoint: str=None, client_id: str=None, client_secret: str=None, **kwargs) -> None: + super(OpenidConnectProviderUpdateContract, self).__init__(**kwargs) + self.display_name = display_name + self.description = description + self.metadata_endpoint = metadata_endpoint + self.client_id = client_id + self.client_secret = client_secret + + +class Operation(Model): + """REST API operation. + + :param name: Operation name: {provider}/{resource}/{operation} + :type name: str + :param display: The object that describes the operation. + :type display: ~azure.mgmt.apimanagement.models.OperationDisplay + :param origin: The operation origin. + :type origin: str + :param properties: The operation properties. + :type properties: object + """ + + _attribute_map = { + 'name': {'key': 'name', 'type': 'str'}, + 'display': {'key': 'display', 'type': 'OperationDisplay'}, + 'origin': {'key': 'origin', 'type': 'str'}, + 'properties': {'key': 'properties', 'type': 'object'}, + } + + def __init__(self, *, name: str=None, display=None, origin: str=None, properties=None, **kwargs) -> None: + super(Operation, self).__init__(**kwargs) + self.name = name + self.display = display + self.origin = origin + self.properties = properties + + +class OperationContract(Resource): + """Api Operation details. + + Variables are only populated by the server, and will be ignored when + sending a request. + + All required parameters must be populated in order to send to Azure. + + :ivar id: Resource ID. + :vartype id: str + :ivar name: Resource name. + :vartype name: str + :ivar type: Resource type for API Management resource. + :vartype type: str + :param template_parameters: Collection of URL template parameters. + :type template_parameters: + list[~azure.mgmt.apimanagement.models.ParameterContract] + :param description: Description of the operation. May include HTML + formatting tags. + :type description: str + :param request: An entity containing request details. + :type request: ~azure.mgmt.apimanagement.models.RequestContract + :param responses: Array of Operation responses. + :type responses: list[~azure.mgmt.apimanagement.models.ResponseContract] + :param policies: Operation Policies + :type policies: str + :param display_name: Required. Operation Name. + :type display_name: str + :param method: Required. A Valid HTTP Operation Method. Typical Http + Methods like GET, PUT, POST but not limited by only them. + :type method: str + :param url_template: Required. Relative URL template identifying the + target resource for this operation. May include parameters. Example: + /customers/{cid}/orders/{oid}/?date={date} + :type url_template: str + """ + + _validation = { + 'id': {'readonly': True}, + 'name': {'readonly': True}, + 'type': {'readonly': True}, + 'description': {'max_length': 1000}, + 'display_name': {'required': True, 'max_length': 300, 'min_length': 1}, + 'method': {'required': True}, + 'url_template': {'required': True, 'max_length': 1000, 'min_length': 1}, + } + + _attribute_map = { + 'id': {'key': 'id', 'type': 'str'}, + 'name': {'key': 'name', 'type': 'str'}, + 'type': {'key': 'type', 'type': 'str'}, + 'template_parameters': {'key': 'properties.templateParameters', 'type': '[ParameterContract]'}, + 'description': {'key': 'properties.description', 'type': 'str'}, + 'request': {'key': 'properties.request', 'type': 'RequestContract'}, + 'responses': {'key': 'properties.responses', 'type': '[ResponseContract]'}, + 'policies': {'key': 'properties.policies', 'type': 'str'}, + 'display_name': {'key': 'properties.displayName', 'type': 'str'}, + 'method': {'key': 'properties.method', 'type': 'str'}, + 'url_template': {'key': 'properties.urlTemplate', 'type': 'str'}, + } + + def __init__(self, *, display_name: str, method: str, url_template: str, template_parameters=None, description: str=None, request=None, responses=None, policies: str=None, **kwargs) -> None: + super(OperationContract, self).__init__(**kwargs) + self.template_parameters = template_parameters + self.description = description + self.request = request + self.responses = responses + self.policies = policies + self.display_name = display_name + self.method = method + self.url_template = url_template + + +class OperationDisplay(Model): + """The object that describes the operation. + + :param provider: Friendly name of the resource provider + :type provider: str + :param operation: Operation type: read, write, delete, listKeys/action, + etc. + :type operation: str + :param resource: Resource type on which the operation is performed. + :type resource: str + :param description: Friendly name of the operation + :type description: str + """ + + _attribute_map = { + 'provider': {'key': 'provider', 'type': 'str'}, + 'operation': {'key': 'operation', 'type': 'str'}, + 'resource': {'key': 'resource', 'type': 'str'}, + 'description': {'key': 'description', 'type': 'str'}, + } + + def __init__(self, *, provider: str=None, operation: str=None, resource: str=None, description: str=None, **kwargs) -> None: + super(OperationDisplay, self).__init__(**kwargs) + self.provider = provider + self.operation = operation + self.resource = resource + self.description = description + + +class OperationEntityBaseContract(Model): + """Api Operation Entity Base Contract details. + + :param template_parameters: Collection of URL template parameters. + :type template_parameters: + list[~azure.mgmt.apimanagement.models.ParameterContract] + :param description: Description of the operation. May include HTML + formatting tags. + :type description: str + :param request: An entity containing request details. + :type request: ~azure.mgmt.apimanagement.models.RequestContract + :param responses: Array of Operation responses. + :type responses: list[~azure.mgmt.apimanagement.models.ResponseContract] + :param policies: Operation Policies + :type policies: str + """ + + _validation = { + 'description': {'max_length': 1000}, + } + + _attribute_map = { + 'template_parameters': {'key': 'templateParameters', 'type': '[ParameterContract]'}, + 'description': {'key': 'description', 'type': 'str'}, + 'request': {'key': 'request', 'type': 'RequestContract'}, + 'responses': {'key': 'responses', 'type': '[ResponseContract]'}, + 'policies': {'key': 'policies', 'type': 'str'}, + } + + def __init__(self, *, template_parameters=None, description: str=None, request=None, responses=None, policies: str=None, **kwargs) -> None: + super(OperationEntityBaseContract, self).__init__(**kwargs) + self.template_parameters = template_parameters + self.description = description + self.request = request + self.responses = responses + self.policies = policies + + +class OperationResultContract(Model): + """Operation Result. + + Variables are only populated by the server, and will be ignored when + sending a request. + + :param id: Operation result identifier. + :type id: str + :param status: Status of an async operation. Possible values include: + 'Started', 'InProgress', 'Succeeded', 'Failed' + :type status: str or ~azure.mgmt.apimanagement.models.AsyncOperationStatus + :param started: Start time of an async operation. The date conforms to the + following format: `yyyy-MM-ddTHH:mm:ssZ` as specified by the ISO 8601 + standard. + :type started: datetime + :param updated: Last update time of an async operation. The date conforms + to the following format: `yyyy-MM-ddTHH:mm:ssZ` as specified by the ISO + 8601 standard. + :type updated: datetime + :param result_info: Optional result info. + :type result_info: str + :param error: Error Body Contract + :type error: ~azure.mgmt.apimanagement.models.ErrorResponseBody + :ivar action_log: This property if only provided as part of the + TenantConfiguration_Validate operation. It contains the log the entities + which will be updated/created/deleted as part of the + TenantConfiguration_Deploy operation. + :vartype action_log: + list[~azure.mgmt.apimanagement.models.OperationResultLogItemContract] + """ + + _validation = { + 'action_log': {'readonly': True}, + } + + _attribute_map = { + 'id': {'key': 'id', 'type': 'str'}, + 'status': {'key': 'status', 'type': 'AsyncOperationStatus'}, + 'started': {'key': 'started', 'type': 'iso-8601'}, + 'updated': {'key': 'updated', 'type': 'iso-8601'}, + 'result_info': {'key': 'resultInfo', 'type': 'str'}, + 'error': {'key': 'error', 'type': 'ErrorResponseBody'}, + 'action_log': {'key': 'actionLog', 'type': '[OperationResultLogItemContract]'}, + } + + def __init__(self, *, id: str=None, status=None, started=None, updated=None, result_info: str=None, error=None, **kwargs) -> None: + super(OperationResultContract, self).__init__(**kwargs) + self.id = id + self.status = status + self.started = started + self.updated = updated + self.result_info = result_info + self.error = error + self.action_log = None + + +class OperationResultLogItemContract(Model): + """Log of the entity being created, updated or deleted. + + :param object_type: The type of entity contract. + :type object_type: str + :param action: Action like create/update/delete. + :type action: str + :param object_key: Identifier of the entity being created/updated/deleted. + :type object_key: str + """ + + _attribute_map = { + 'object_type': {'key': 'objectType', 'type': 'str'}, + 'action': {'key': 'action', 'type': 'str'}, + 'object_key': {'key': 'objectKey', 'type': 'str'}, + } + + def __init__(self, *, object_type: str=None, action: str=None, object_key: str=None, **kwargs) -> None: + super(OperationResultLogItemContract, self).__init__(**kwargs) + self.object_type = object_type + self.action = action + self.object_key = object_key + + +class OperationTagResourceContractProperties(Model): + """Operation Entity contract Properties. + + Variables are only populated by the server, and will be ignored when + sending a request. + + :param id: Identifier of the operation in form /operations/{operationId}. + :type id: str + :ivar name: Operation name. + :vartype name: str + :ivar api_name: Api Name. + :vartype api_name: str + :ivar api_revision: Api Revision. + :vartype api_revision: str + :ivar api_version: Api Version. + :vartype api_version: str + :ivar description: Operation Description. + :vartype description: str + :ivar method: A Valid HTTP Operation Method. Typical Http Methods like + GET, PUT, POST but not limited by only them. + :vartype method: str + :ivar url_template: Relative URL template identifying the target resource + for this operation. May include parameters. Example: + /customers/{cid}/orders/{oid}/?date={date} + :vartype url_template: str + """ + + _validation = { + 'name': {'readonly': True}, + 'api_name': {'readonly': True}, + 'api_revision': {'readonly': True}, + 'api_version': {'readonly': True}, + 'description': {'readonly': True}, + 'method': {'readonly': True}, + 'url_template': {'readonly': True}, + } + + _attribute_map = { + 'id': {'key': 'id', 'type': 'str'}, + 'name': {'key': 'name', 'type': 'str'}, + 'api_name': {'key': 'apiName', 'type': 'str'}, + 'api_revision': {'key': 'apiRevision', 'type': 'str'}, + 'api_version': {'key': 'apiVersion', 'type': 'str'}, + 'description': {'key': 'description', 'type': 'str'}, + 'method': {'key': 'method', 'type': 'str'}, + 'url_template': {'key': 'urlTemplate', 'type': 'str'}, + } + + def __init__(self, *, id: str=None, **kwargs) -> None: + super(OperationTagResourceContractProperties, self).__init__(**kwargs) + self.id = id + self.name = None + self.api_name = None + self.api_revision = None + self.api_version = None + self.description = None + self.method = None + self.url_template = None + + +class OperationUpdateContract(Model): + """Api Operation Update Contract details. + + :param template_parameters: Collection of URL template parameters. + :type template_parameters: + list[~azure.mgmt.apimanagement.models.ParameterContract] + :param description: Description of the operation. May include HTML + formatting tags. + :type description: str + :param request: An entity containing request details. + :type request: ~azure.mgmt.apimanagement.models.RequestContract + :param responses: Array of Operation responses. + :type responses: list[~azure.mgmt.apimanagement.models.ResponseContract] + :param policies: Operation Policies + :type policies: str + :param display_name: Operation Name. + :type display_name: str + :param method: A Valid HTTP Operation Method. Typical Http Methods like + GET, PUT, POST but not limited by only them. + :type method: str + :param url_template: Relative URL template identifying the target resource + for this operation. May include parameters. Example: + /customers/{cid}/orders/{oid}/?date={date} + :type url_template: str + """ + + _validation = { + 'description': {'max_length': 1000}, + 'display_name': {'max_length': 300, 'min_length': 1}, + 'url_template': {'max_length': 1000, 'min_length': 1}, + } + + _attribute_map = { + 'template_parameters': {'key': 'properties.templateParameters', 'type': '[ParameterContract]'}, + 'description': {'key': 'properties.description', 'type': 'str'}, + 'request': {'key': 'properties.request', 'type': 'RequestContract'}, + 'responses': {'key': 'properties.responses', 'type': '[ResponseContract]'}, + 'policies': {'key': 'properties.policies', 'type': 'str'}, + 'display_name': {'key': 'properties.displayName', 'type': 'str'}, + 'method': {'key': 'properties.method', 'type': 'str'}, + 'url_template': {'key': 'properties.urlTemplate', 'type': 'str'}, + } + + def __init__(self, *, template_parameters=None, description: str=None, request=None, responses=None, policies: str=None, display_name: str=None, method: str=None, url_template: str=None, **kwargs) -> None: + super(OperationUpdateContract, self).__init__(**kwargs) + self.template_parameters = template_parameters + self.description = description + self.request = request + self.responses = responses + self.policies = policies + self.display_name = display_name + self.method = method + self.url_template = url_template + + +class ParameterContract(Model): + """Operation parameters details. + + All required parameters must be populated in order to send to Azure. + + :param name: Required. Parameter name. + :type name: str + :param description: Parameter description. + :type description: str + :param type: Required. Parameter type. + :type type: str + :param default_value: Default parameter value. + :type default_value: str + :param required: Specifies whether parameter is required or not. + :type required: bool + :param values: Parameter values. + :type values: list[str] + """ + + _validation = { + 'name': {'required': True}, + 'type': {'required': True}, + } + + _attribute_map = { + 'name': {'key': 'name', 'type': 'str'}, + 'description': {'key': 'description', 'type': 'str'}, + 'type': {'key': 'type', 'type': 'str'}, + 'default_value': {'key': 'defaultValue', 'type': 'str'}, + 'required': {'key': 'required', 'type': 'bool'}, + 'values': {'key': 'values', 'type': '[str]'}, + } + + def __init__(self, *, name: str, type: str, description: str=None, default_value: str=None, required: bool=None, values=None, **kwargs) -> None: + super(ParameterContract, self).__init__(**kwargs) + self.name = name + self.description = description + self.type = type + self.default_value = default_value + self.required = required + self.values = values + + +class PipelineDiagnosticSettings(Model): + """Diagnostic settings for incoming/outgoing 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 + + +class PolicyCollection(Model): + """The response of the list policy operation. + + :param value: Policy Contract value. + :type value: list[~azure.mgmt.apimanagement.models.PolicyContract] + :param next_link: Next page link if any. + :type next_link: str + """ + + _attribute_map = { + 'value': {'key': 'value', 'type': '[PolicyContract]'}, + 'next_link': {'key': 'nextLink', 'type': 'str'}, + } + + def __init__(self, *, value=None, next_link: str=None, **kwargs) -> None: + super(PolicyCollection, self).__init__(**kwargs) + self.value = value + self.next_link = next_link + + +class PolicyContract(Resource): + """Policy Contract details. + + Variables are only populated by the server, and will be ignored when + sending a request. + + All required parameters must be populated in order to send to Azure. + + :ivar id: Resource ID. + :vartype id: str + :ivar name: Resource name. + :vartype name: str + :ivar type: Resource type for API Management resource. + :vartype type: str + :param value: Required. Contents of the Policy as defined by the format. + :type value: str + :param format: Format of the policyContent. Possible values include: + 'xml', 'xml-link', 'rawxml', 'rawxml-link'. Default value: "xml" . + :type format: str or ~azure.mgmt.apimanagement.models.PolicyContentFormat + """ + + _validation = { + 'id': {'readonly': True}, + 'name': {'readonly': True}, + 'type': {'readonly': True}, + 'value': {'required': True}, + } + + _attribute_map = { + 'id': {'key': 'id', 'type': 'str'}, + 'name': {'key': 'name', 'type': 'str'}, + 'type': {'key': 'type', 'type': 'str'}, + 'value': {'key': 'properties.value', 'type': 'str'}, + 'format': {'key': 'properties.format', 'type': 'str'}, + } + + def __init__(self, *, value: str, format="xml", **kwargs) -> None: + super(PolicyContract, self).__init__(**kwargs) + self.value = value + self.format = format + + +class PolicyDescriptionCollection(Model): + """Descriptions of APIM policies. + + :param value: Descriptions of APIM policies. + :type value: + list[~azure.mgmt.apimanagement.models.PolicyDescriptionContract] + :param count: Total record count number. + :type count: long + """ + + _attribute_map = { + 'value': {'key': 'value', 'type': '[PolicyDescriptionContract]'}, + 'count': {'key': 'count', 'type': 'long'}, + } + + def __init__(self, *, value=None, count: int=None, **kwargs) -> None: + super(PolicyDescriptionCollection, self).__init__(**kwargs) + self.value = value + self.count = count + + +class PolicyDescriptionContract(Resource): + """Policy description details. + + Variables are only populated by the server, and will be ignored when + sending a request. + + :ivar id: Resource ID. + :vartype id: str + :ivar name: Resource name. + :vartype name: str + :ivar type: Resource type for API Management resource. + :vartype type: str + :ivar description: Policy description. + :vartype description: str + :ivar scope: Binary OR value of the Snippet scope. + :vartype scope: int + """ + + _validation = { + 'id': {'readonly': True}, + 'name': {'readonly': True}, + 'type': {'readonly': True}, + 'description': {'readonly': True}, + 'scope': {'readonly': True}, + } + + _attribute_map = { + 'id': {'key': 'id', 'type': 'str'}, + 'name': {'key': 'name', 'type': 'str'}, + 'type': {'key': 'type', 'type': 'str'}, + 'description': {'key': 'properties.description', 'type': 'str'}, + 'scope': {'key': 'properties.scope', 'type': 'int'}, + } + + def __init__(self, **kwargs) -> None: + super(PolicyDescriptionContract, self).__init__(**kwargs) + self.description = None + self.scope = None + + +class PortalDelegationSettings(Resource): + """Delegation settings for a developer portal. + + Variables are only populated by the server, and will be ignored when + sending a request. + + :ivar id: Resource ID. + :vartype id: str + :ivar name: Resource name. + :vartype name: str + :ivar type: Resource type for API Management resource. + :vartype type: str + :param url: A delegation Url. + :type url: str + :param validation_key: A base64-encoded validation key to validate, that a + request is coming from Azure API Management. + :type validation_key: str + :param subscriptions: Subscriptions delegation settings. + :type subscriptions: + ~azure.mgmt.apimanagement.models.SubscriptionsDelegationSettingsProperties + :param user_registration: User registration delegation settings. + :type user_registration: + ~azure.mgmt.apimanagement.models.RegistrationDelegationSettingsProperties + """ + + _validation = { + 'id': {'readonly': True}, + 'name': {'readonly': True}, + 'type': {'readonly': True}, + } + + _attribute_map = { + 'id': {'key': 'id', 'type': 'str'}, + 'name': {'key': 'name', 'type': 'str'}, + 'type': {'key': 'type', 'type': 'str'}, + 'url': {'key': 'properties.url', 'type': 'str'}, + 'validation_key': {'key': 'properties.validationKey', 'type': 'str'}, + 'subscriptions': {'key': 'properties.subscriptions', 'type': 'SubscriptionsDelegationSettingsProperties'}, + 'user_registration': {'key': 'properties.userRegistration', 'type': 'RegistrationDelegationSettingsProperties'}, + } + + def __init__(self, *, url: str=None, validation_key: str=None, subscriptions=None, user_registration=None, **kwargs) -> None: + super(PortalDelegationSettings, self).__init__(**kwargs) + self.url = url + self.validation_key = validation_key + self.subscriptions = subscriptions + self.user_registration = user_registration + + +class PortalSettingValidationKeyContract(Model): + """Client or app secret used in IdentityProviders, Aad, OpenID or OAuth. + + :param validation_key: This is secret value of the validation key in + portal settings. + :type validation_key: str + """ + + _attribute_map = { + 'validation_key': {'key': 'validationKey', 'type': 'str'}, + } + + def __init__(self, *, validation_key: str=None, **kwargs) -> None: + super(PortalSettingValidationKeyContract, self).__init__(**kwargs) + self.validation_key = validation_key + + +class PortalSigninSettings(Resource): + """Sign-In settings for the Developer Portal. + + Variables are only populated by the server, and will be ignored when + sending a request. + + :ivar id: Resource ID. + :vartype id: str + :ivar name: Resource name. + :vartype name: str + :ivar type: Resource type for API Management resource. + :vartype type: str + :param enabled: Redirect Anonymous users to the Sign-In page. + :type enabled: bool + """ + + _validation = { + 'id': {'readonly': True}, + 'name': {'readonly': True}, + 'type': {'readonly': True}, + } + + _attribute_map = { + 'id': {'key': 'id', 'type': 'str'}, + 'name': {'key': 'name', 'type': 'str'}, + 'type': {'key': 'type', 'type': 'str'}, + 'enabled': {'key': 'properties.enabled', 'type': 'bool'}, + } + + def __init__(self, *, enabled: bool=None, **kwargs) -> None: + super(PortalSigninSettings, self).__init__(**kwargs) + self.enabled = enabled + + +class PortalSignupSettings(Resource): + """Sign-Up settings for a developer portal. + + Variables are only populated by the server, and will be ignored when + sending a request. + + :ivar id: Resource ID. + :vartype id: str + :ivar name: Resource name. + :vartype name: str + :ivar type: Resource type for API Management resource. + :vartype type: str + :param enabled: Allow users to sign up on a developer portal. + :type enabled: bool + :param terms_of_service: Terms of service contract properties. + :type terms_of_service: + ~azure.mgmt.apimanagement.models.TermsOfServiceProperties + """ + + _validation = { + 'id': {'readonly': True}, + 'name': {'readonly': True}, + 'type': {'readonly': True}, + } + + _attribute_map = { + 'id': {'key': 'id', 'type': 'str'}, + 'name': {'key': 'name', 'type': 'str'}, + 'type': {'key': 'type', 'type': 'str'}, + 'enabled': {'key': 'properties.enabled', 'type': 'bool'}, + 'terms_of_service': {'key': 'properties.termsOfService', 'type': 'TermsOfServiceProperties'}, + } + + def __init__(self, *, enabled: bool=None, terms_of_service=None, **kwargs) -> None: + super(PortalSignupSettings, self).__init__(**kwargs) + self.enabled = enabled + self.terms_of_service = terms_of_service + + +class ProductContract(Resource): + """Product details. + + Variables are only populated by the server, and will be ignored when + sending a request. + + All required parameters must be populated in order to send to Azure. + + :ivar id: Resource ID. + :vartype id: str + :ivar name: Resource name. + :vartype name: str + :ivar type: Resource type for API Management resource. + :vartype type: str + :param description: Product description. May include HTML formatting tags. + :type description: str + :param terms: Product terms of use. Developers trying to subscribe to the + product will be presented and required to accept these terms before they + can complete the subscription process. + :type terms: str + :param subscription_required: Whether a product subscription is required + for accessing APIs included in this product. If true, the product is + referred to as "protected" and a valid subscription key is required for a + request to an API included in the product to succeed. If false, the + product is referred to as "open" and requests to an API included in the + product can be made without a subscription key. If property is omitted + when creating a new product it's value is assumed to be true. + :type subscription_required: bool + :param approval_required: whether subscription approval is required. If + false, new subscriptions will be approved automatically enabling + developers to call the product’s APIs immediately after subscribing. If + true, administrators must manually approve the subscription before the + developer can any of the product’s APIs. Can be present only if + 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 + unlimited per user subscriptions. Can be present only if + subscriptionRequired property is present and has a value of false. + :type subscriptions_limit: int + :param state: whether product is published or not. Published products are + discoverable by users of developer portal. Non published products are + visible only to administrators. Default state of Product is notPublished. + Possible values include: 'notPublished', 'published' + :type state: str or ~azure.mgmt.apimanagement.models.ProductState + :param display_name: Required. Product name. + :type display_name: str + """ + + _validation = { + 'id': {'readonly': True}, + 'name': {'readonly': True}, + 'type': {'readonly': True}, + 'description': {'max_length': 1000, 'min_length': 1}, + 'display_name': {'required': True, 'max_length': 300, 'min_length': 1}, + } + + _attribute_map = { + 'id': {'key': 'id', 'type': 'str'}, + 'name': {'key': 'name', 'type': 'str'}, + 'type': {'key': 'type', 'type': 'str'}, + 'description': {'key': 'properties.description', 'type': 'str'}, + 'terms': {'key': 'properties.terms', 'type': 'str'}, + 'subscription_required': {'key': 'properties.subscriptionRequired', 'type': 'bool'}, + 'approval_required': {'key': 'properties.approvalRequired', 'type': 'bool'}, + 'subscriptions_limit': {'key': 'properties.subscriptionsLimit', 'type': 'int'}, + 'state': {'key': 'properties.state', 'type': 'ProductState'}, + 'display_name': {'key': 'properties.displayName', 'type': 'str'}, + } + + def __init__(self, *, display_name: str, description: str=None, terms: str=None, subscription_required: bool=None, approval_required: bool=None, subscriptions_limit: int=None, state=None, **kwargs) -> None: + super(ProductContract, self).__init__(**kwargs) + self.description = description + self.terms = terms + self.subscription_required = subscription_required + self.approval_required = approval_required + self.subscriptions_limit = subscriptions_limit + self.state = state + self.display_name = display_name + + +class ProductEntityBaseParameters(Model): + """Product Entity Base Parameters. + + :param description: Product description. May include HTML formatting tags. + :type description: str + :param terms: Product terms of use. Developers trying to subscribe to the + product will be presented and required to accept these terms before they + can complete the subscription process. + :type terms: str + :param subscription_required: Whether a product subscription is required + for accessing APIs included in this product. If true, the product is + referred to as "protected" and a valid subscription key is required for a + request to an API included in the product to succeed. If false, the + product is referred to as "open" and requests to an API included in the + product can be made without a subscription key. If property is omitted + when creating a new product it's value is assumed to be true. + :type subscription_required: bool + :param approval_required: whether subscription approval is required. If + false, new subscriptions will be approved automatically enabling + developers to call the product’s APIs immediately after subscribing. If + true, administrators must manually approve the subscription before the + developer can any of the product’s APIs. Can be present only if + 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 + unlimited per user subscriptions. Can be present only if + subscriptionRequired property is present and has a value of false. + :type subscriptions_limit: int + :param state: whether product is published or not. Published products are + discoverable by users of developer portal. Non published products are + visible only to administrators. Default state of Product is notPublished. + Possible values include: 'notPublished', 'published' + :type state: str or ~azure.mgmt.apimanagement.models.ProductState + """ + + _validation = { + 'description': {'max_length': 1000, 'min_length': 1}, + } + + _attribute_map = { + 'description': {'key': 'description', 'type': 'str'}, + 'terms': {'key': 'terms', 'type': 'str'}, + 'subscription_required': {'key': 'subscriptionRequired', 'type': 'bool'}, + 'approval_required': {'key': 'approvalRequired', 'type': 'bool'}, + 'subscriptions_limit': {'key': 'subscriptionsLimit', 'type': 'int'}, + 'state': {'key': 'state', 'type': 'ProductState'}, + } + + def __init__(self, *, description: str=None, terms: str=None, subscription_required: bool=None, approval_required: bool=None, subscriptions_limit: int=None, state=None, **kwargs) -> None: + super(ProductEntityBaseParameters, self).__init__(**kwargs) + self.description = description + self.terms = terms + self.subscription_required = subscription_required + self.approval_required = approval_required + self.subscriptions_limit = subscriptions_limit + self.state = state + + +class ProductTagResourceContractProperties(ProductEntityBaseParameters): + """Product profile. + + All required parameters must be populated in order to send to Azure. + + :param description: Product description. May include HTML formatting tags. + :type description: str + :param terms: Product terms of use. Developers trying to subscribe to the + product will be presented and required to accept these terms before they + can complete the subscription process. + :type terms: str + :param subscription_required: Whether a product subscription is required + for accessing APIs included in this product. If true, the product is + referred to as "protected" and a valid subscription key is required for a + request to an API included in the product to succeed. If false, the + product is referred to as "open" and requests to an API included in the + product can be made without a subscription key. If property is omitted + when creating a new product it's value is assumed to be true. + :type subscription_required: bool + :param approval_required: whether subscription approval is required. If + false, new subscriptions will be approved automatically enabling + developers to call the product’s APIs immediately after subscribing. If + true, administrators must manually approve the subscription before the + developer can any of the product’s APIs. Can be present only if + 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 + unlimited per user subscriptions. Can be present only if + subscriptionRequired property is present and has a value of false. + :type subscriptions_limit: int + :param state: whether product is published or not. Published products are + discoverable by users of developer portal. Non published products are + visible only to administrators. Default state of Product is notPublished. + Possible values include: 'notPublished', 'published' + :type state: str or ~azure.mgmt.apimanagement.models.ProductState + :param id: Identifier of the product in the form of /products/{productId} + :type id: str + :param name: Required. Product name. + :type name: str + """ + + _validation = { + 'description': {'max_length': 1000, 'min_length': 1}, + 'name': {'required': True, 'max_length': 300, 'min_length': 1}, + } + + _attribute_map = { + 'description': {'key': 'description', 'type': 'str'}, + 'terms': {'key': 'terms', 'type': 'str'}, + 'subscription_required': {'key': 'subscriptionRequired', 'type': 'bool'}, + 'approval_required': {'key': 'approvalRequired', 'type': 'bool'}, + 'subscriptions_limit': {'key': 'subscriptionsLimit', 'type': 'int'}, + 'state': {'key': 'state', 'type': 'ProductState'}, + 'id': {'key': 'id', 'type': 'str'}, + 'name': {'key': 'name', 'type': 'str'}, + } + + def __init__(self, *, name: str, description: str=None, terms: str=None, subscription_required: bool=None, approval_required: bool=None, subscriptions_limit: int=None, state=None, id: str=None, **kwargs) -> None: + super(ProductTagResourceContractProperties, self).__init__(description=description, terms=terms, subscription_required=subscription_required, approval_required=approval_required, subscriptions_limit=subscriptions_limit, state=state, **kwargs) + self.id = id + self.name = name + + +class ProductUpdateParameters(Model): + """Product Update parameters. + + :param description: Product description. May include HTML formatting tags. + :type description: str + :param terms: Product terms of use. Developers trying to subscribe to the + product will be presented and required to accept these terms before they + can complete the subscription process. + :type terms: str + :param subscription_required: Whether a product subscription is required + for accessing APIs included in this product. If true, the product is + referred to as "protected" and a valid subscription key is required for a + request to an API included in the product to succeed. If false, the + product is referred to as "open" and requests to an API included in the + product can be made without a subscription key. If property is omitted + when creating a new product it's value is assumed to be true. + :type subscription_required: bool + :param approval_required: whether subscription approval is required. If + false, new subscriptions will be approved automatically enabling + developers to call the product’s APIs immediately after subscribing. If + true, administrators must manually approve the subscription before the + developer can any of the product’s APIs. Can be present only if + 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 + unlimited per user subscriptions. Can be present only if + subscriptionRequired property is present and has a value of false. + :type subscriptions_limit: int + :param state: whether product is published or not. Published products are + discoverable by users of developer portal. Non published products are + visible only to administrators. Default state of Product is notPublished. + Possible values include: 'notPublished', 'published' + :type state: str or ~azure.mgmt.apimanagement.models.ProductState + :param display_name: Product name. + :type display_name: str + """ + + _validation = { + 'description': {'max_length': 1000, 'min_length': 1}, + 'display_name': {'max_length': 300, 'min_length': 1}, + } + + _attribute_map = { + 'description': {'key': 'properties.description', 'type': 'str'}, + 'terms': {'key': 'properties.terms', 'type': 'str'}, + 'subscription_required': {'key': 'properties.subscriptionRequired', 'type': 'bool'}, + 'approval_required': {'key': 'properties.approvalRequired', 'type': 'bool'}, + 'subscriptions_limit': {'key': 'properties.subscriptionsLimit', 'type': 'int'}, + 'state': {'key': 'properties.state', 'type': 'ProductState'}, + 'display_name': {'key': 'properties.displayName', 'type': 'str'}, + } + + def __init__(self, *, description: str=None, terms: str=None, subscription_required: bool=None, approval_required: bool=None, subscriptions_limit: int=None, state=None, display_name: str=None, **kwargs) -> None: + super(ProductUpdateParameters, self).__init__(**kwargs) + self.description = description + self.terms = terms + self.subscription_required = subscription_required + self.approval_required = approval_required + self.subscriptions_limit = subscriptions_limit + self.state = state + self.display_name = display_name + + +class PropertyValueContract(Model): + """Client or app secret used in IdentityProviders, Aad, OpenID or OAuth. + + :param value: This is secret value of the NamedValue entity. + :type value: str + """ + + _attribute_map = { + 'value': {'key': 'value', 'type': 'str'}, + } + + def __init__(self, *, value: str=None, **kwargs) -> None: + super(PropertyValueContract, self).__init__(**kwargs) + self.value = value + + +class QuotaCounterCollection(Model): + """Paged Quota Counter list representation. + + :param value: Quota counter values. + :type value: list[~azure.mgmt.apimanagement.models.QuotaCounterContract] + :param count: Total record count number across all pages. + :type count: long + :param next_link: Next page link if any. + :type next_link: str + """ + + _attribute_map = { + 'value': {'key': 'value', 'type': '[QuotaCounterContract]'}, + 'count': {'key': 'count', 'type': 'long'}, + 'next_link': {'key': 'nextLink', 'type': 'str'}, + } + + def __init__(self, *, value=None, count: int=None, next_link: str=None, **kwargs) -> None: + super(QuotaCounterCollection, self).__init__(**kwargs) + self.value = value + self.count = count + self.next_link = next_link + + +class QuotaCounterContract(Model): + """Quota counter details. + + All required parameters must be populated in order to send to Azure. + + :param counter_key: Required. The Key value of the Counter. Must not be + empty. + :type counter_key: str + :param period_key: Required. Identifier of the Period for which the + counter was collected. Must not be empty. + :type period_key: str + :param period_start_time: Required. The date of the start of Counter + Period. The date conforms to the following format: `yyyy-MM-ddTHH:mm:ssZ` + as specified by the ISO 8601 standard. + :type period_start_time: datetime + :param period_end_time: Required. The date of the end of Counter Period. + The date conforms to the following format: `yyyy-MM-ddTHH:mm:ssZ` as + specified by the ISO 8601 standard. + :type period_end_time: datetime + :param value: Quota Value Properties + :type value: + ~azure.mgmt.apimanagement.models.QuotaCounterValueContractProperties + """ + + _validation = { + 'counter_key': {'required': True, 'min_length': 1}, + 'period_key': {'required': True, 'min_length': 1}, + 'period_start_time': {'required': True}, + 'period_end_time': {'required': True}, + } + + _attribute_map = { + 'counter_key': {'key': 'counterKey', 'type': 'str'}, + 'period_key': {'key': 'periodKey', 'type': 'str'}, + 'period_start_time': {'key': 'periodStartTime', 'type': 'iso-8601'}, + 'period_end_time': {'key': 'periodEndTime', 'type': 'iso-8601'}, + 'value': {'key': 'value', 'type': 'QuotaCounterValueContractProperties'}, + } + + def __init__(self, *, counter_key: str, period_key: str, period_start_time, period_end_time, value=None, **kwargs) -> None: + super(QuotaCounterContract, self).__init__(**kwargs) + self.counter_key = counter_key + self.period_key = period_key + self.period_start_time = period_start_time + self.period_end_time = period_end_time + self.value = value + + +class QuotaCounterValueContract(Model): + """Quota counter value details. + + :param calls_count: Number of times Counter was called. + :type calls_count: int + :param kb_transferred: Data Transferred in KiloBytes. + :type kb_transferred: float + """ + + _attribute_map = { + 'calls_count': {'key': 'value.callsCount', 'type': 'int'}, + 'kb_transferred': {'key': 'value.kbTransferred', 'type': 'float'}, + } + + def __init__(self, *, calls_count: int=None, kb_transferred: float=None, **kwargs) -> None: + super(QuotaCounterValueContract, self).__init__(**kwargs) + self.calls_count = calls_count + self.kb_transferred = kb_transferred + + +class QuotaCounterValueContractProperties(Model): + """Quota counter value details. + + :param calls_count: Number of times Counter was called. + :type calls_count: int + :param kb_transferred: Data Transferred in KiloBytes. + :type kb_transferred: float + """ + + _attribute_map = { + 'calls_count': {'key': 'callsCount', 'type': 'int'}, + 'kb_transferred': {'key': 'kbTransferred', 'type': 'float'}, + } + + def __init__(self, *, calls_count: int=None, kb_transferred: float=None, **kwargs) -> None: + super(QuotaCounterValueContractProperties, self).__init__(**kwargs) + self.calls_count = calls_count + self.kb_transferred = kb_transferred + + +class RecipientEmailCollection(Model): + """Paged Recipient User list representation. + + :param value: Page values. + :type value: list[~azure.mgmt.apimanagement.models.RecipientEmailContract] + :param next_link: Next page link if any. + :type next_link: str + """ + + _attribute_map = { + 'value': {'key': 'value', 'type': '[RecipientEmailContract]'}, + 'next_link': {'key': 'nextLink', 'type': 'str'}, + } + + def __init__(self, *, value=None, next_link: str=None, **kwargs) -> None: + super(RecipientEmailCollection, self).__init__(**kwargs) + self.value = value + self.next_link = next_link + + +class RecipientEmailContract(Resource): + """Recipient Email details. + + Variables are only populated by the server, and will be ignored when + sending a request. + + :ivar id: Resource ID. + :vartype id: str + :ivar name: Resource name. + :vartype name: str + :ivar type: Resource type for API Management resource. + :vartype type: str + :param email: User Email subscribed to notification. + :type email: str + """ + + _validation = { + 'id': {'readonly': True}, + 'name': {'readonly': True}, + 'type': {'readonly': True}, + } + + _attribute_map = { + 'id': {'key': 'id', 'type': 'str'}, + 'name': {'key': 'name', 'type': 'str'}, + 'type': {'key': 'type', 'type': 'str'}, + 'email': {'key': 'properties.email', 'type': 'str'}, + } + + def __init__(self, *, email: str=None, **kwargs) -> None: + super(RecipientEmailContract, self).__init__(**kwargs) + self.email = email + + +class RecipientsContractProperties(Model): + """Notification Parameter contract. + + :param emails: List of Emails subscribed for the notification. + :type emails: list[str] + :param users: List of Users subscribed for the notification. + :type users: list[str] + """ + + _attribute_map = { + 'emails': {'key': 'emails', 'type': '[str]'}, + 'users': {'key': 'users', 'type': '[str]'}, + } + + def __init__(self, *, emails=None, users=None, **kwargs) -> None: + super(RecipientsContractProperties, self).__init__(**kwargs) + self.emails = emails + self.users = users + + +class RecipientUserCollection(Model): + """Paged Recipient User list representation. + + :param value: Page values. + :type value: list[~azure.mgmt.apimanagement.models.RecipientUserContract] + :param next_link: Next page link if any. + :type next_link: str + """ + + _attribute_map = { + 'value': {'key': 'value', 'type': '[RecipientUserContract]'}, + 'next_link': {'key': 'nextLink', 'type': 'str'}, + } + + def __init__(self, *, value=None, next_link: str=None, **kwargs) -> None: + super(RecipientUserCollection, self).__init__(**kwargs) + self.value = value + self.next_link = next_link + + +class RecipientUserContract(Resource): + """Recipient User details. + + Variables are only populated by the server, and will be ignored when + sending a request. + + :ivar id: Resource ID. + :vartype id: str + :ivar name: Resource name. + :vartype name: str + :ivar type: Resource type for API Management resource. + :vartype type: str + :param user_id: API Management UserId subscribed to notification. + :type user_id: str + """ + + _validation = { + 'id': {'readonly': True}, + 'name': {'readonly': True}, + 'type': {'readonly': True}, + } + + _attribute_map = { + 'id': {'key': 'id', 'type': 'str'}, + 'name': {'key': 'name', 'type': 'str'}, + 'type': {'key': 'type', 'type': 'str'}, + 'user_id': {'key': 'properties.userId', 'type': 'str'}, + } + + def __init__(self, *, user_id: str=None, **kwargs) -> None: + super(RecipientUserContract, self).__init__(**kwargs) + self.user_id = user_id + + +class RegionContract(Model): + """Region profile. + + Variables are only populated by the server, and will be ignored when + sending a request. + + :ivar name: Region name. + :vartype name: str + :param is_master_region: whether Region is the master region. + :type is_master_region: bool + :param is_deleted: whether Region is deleted. + :type is_deleted: bool + """ + + _validation = { + 'name': {'readonly': True}, + } + + _attribute_map = { + 'name': {'key': 'name', 'type': 'str'}, + 'is_master_region': {'key': 'isMasterRegion', 'type': 'bool'}, + 'is_deleted': {'key': 'isDeleted', 'type': 'bool'}, + } + + def __init__(self, *, is_master_region: bool=None, is_deleted: bool=None, **kwargs) -> None: + super(RegionContract, self).__init__(**kwargs) + self.name = None + self.is_master_region = is_master_region + self.is_deleted = is_deleted + + +class RegistrationDelegationSettingsProperties(Model): + """User registration delegation settings properties. + + :param enabled: Enable or disable delegation for user registration. + :type enabled: bool + """ + + _attribute_map = { + 'enabled': {'key': 'enabled', 'type': 'bool'}, + } + + def __init__(self, *, enabled: bool=None, **kwargs) -> None: + super(RegistrationDelegationSettingsProperties, self).__init__(**kwargs) + self.enabled = enabled + + +class ReportRecordContract(Model): + """Report data. + + Variables are only populated by the server, and will be ignored when + sending a request. + + :param name: Name depending on report endpoint specifies product, API, + operation or developer name. + :type name: str + :param timestamp: Start of aggregation period. The date conforms to the + following format: `yyyy-MM-ddTHH:mm:ssZ` as specified by the ISO 8601 + standard. + :type timestamp: datetime + :param interval: Length of aggregation period. Interval must be multiple + of 15 minutes and may not be zero. The value should be in ISO 8601 format + (http://en.wikipedia.org/wiki/ISO_8601#Durations). + :type interval: str + :param country: Country to which this record data is related. + :type country: str + :param region: Country region to which this record data is related. + :type region: str + :param zip: Zip code to which this record data is related. + :type zip: str + :ivar user_id: User identifier path. /users/{userId} + :vartype user_id: str + :ivar product_id: Product identifier path. /products/{productId} + :vartype product_id: str + :param api_id: API identifier path. /apis/{apiId} + :type api_id: str + :param operation_id: Operation identifier path. + /apis/{apiId}/operations/{operationId} + :type operation_id: str + :param api_region: API region identifier. + :type api_region: str + :param subscription_id: Subscription identifier path. + /subscriptions/{subscriptionId} + :type subscription_id: str + :param call_count_success: Number of successful calls. This includes calls + returning HttpStatusCode <= 301 and HttpStatusCode.NotModified and + HttpStatusCode.TemporaryRedirect + :type call_count_success: int + :param call_count_blocked: Number of calls blocked due to invalid + credentials. This includes calls returning HttpStatusCode.Unauthorized and + HttpStatusCode.Forbidden and HttpStatusCode.TooManyRequests + :type call_count_blocked: int + :param call_count_failed: Number of calls failed due to proxy or backend + errors. This includes calls returning HttpStatusCode.BadRequest(400) and + any Code between HttpStatusCode.InternalServerError (500) and 600 + :type call_count_failed: int + :param call_count_other: Number of other calls. + :type call_count_other: int + :param call_count_total: Total number of calls. + :type call_count_total: int + :param bandwidth: Bandwidth consumed. + :type bandwidth: long + :param cache_hit_count: Number of times when content was served from cache + policy. + :type cache_hit_count: int + :param cache_miss_count: Number of times content was fetched from backend. + :type cache_miss_count: int + :param api_time_avg: Average time it took to process request. + :type api_time_avg: float + :param api_time_min: Minimum time it took to process request. + :type api_time_min: float + :param api_time_max: Maximum time it took to process request. + :type api_time_max: float + :param service_time_avg: Average time it took to process request on + backend. + :type service_time_avg: float + :param service_time_min: Minimum time it took to process request on + backend. + :type service_time_min: float + :param service_time_max: Maximum time it took to process request on + backend. + :type service_time_max: float + """ + + _validation = { + 'user_id': {'readonly': True}, + 'product_id': {'readonly': True}, + } + + _attribute_map = { + 'name': {'key': 'name', 'type': 'str'}, + 'timestamp': {'key': 'timestamp', 'type': 'iso-8601'}, + 'interval': {'key': 'interval', 'type': 'str'}, + 'country': {'key': 'country', 'type': 'str'}, + 'region': {'key': 'region', 'type': 'str'}, + 'zip': {'key': 'zip', 'type': 'str'}, + 'user_id': {'key': 'userId', 'type': 'str'}, + 'product_id': {'key': 'productId', 'type': 'str'}, + 'api_id': {'key': 'apiId', 'type': 'str'}, + 'operation_id': {'key': 'operationId', 'type': 'str'}, + 'api_region': {'key': 'apiRegion', 'type': 'str'}, + 'subscription_id': {'key': 'subscriptionId', 'type': 'str'}, + 'call_count_success': {'key': 'callCountSuccess', 'type': 'int'}, + 'call_count_blocked': {'key': 'callCountBlocked', 'type': 'int'}, + 'call_count_failed': {'key': 'callCountFailed', 'type': 'int'}, + 'call_count_other': {'key': 'callCountOther', 'type': 'int'}, + 'call_count_total': {'key': 'callCountTotal', 'type': 'int'}, + 'bandwidth': {'key': 'bandwidth', 'type': 'long'}, + 'cache_hit_count': {'key': 'cacheHitCount', 'type': 'int'}, + 'cache_miss_count': {'key': 'cacheMissCount', 'type': 'int'}, + 'api_time_avg': {'key': 'apiTimeAvg', 'type': 'float'}, + 'api_time_min': {'key': 'apiTimeMin', 'type': 'float'}, + 'api_time_max': {'key': 'apiTimeMax', 'type': 'float'}, + 'service_time_avg': {'key': 'serviceTimeAvg', 'type': 'float'}, + 'service_time_min': {'key': 'serviceTimeMin', 'type': 'float'}, + 'service_time_max': {'key': 'serviceTimeMax', 'type': 'float'}, + } + + def __init__(self, *, name: str=None, timestamp=None, interval: str=None, country: str=None, region: str=None, zip: str=None, api_id: str=None, operation_id: str=None, api_region: str=None, subscription_id: str=None, call_count_success: int=None, call_count_blocked: int=None, call_count_failed: int=None, call_count_other: int=None, call_count_total: int=None, bandwidth: int=None, cache_hit_count: int=None, cache_miss_count: int=None, api_time_avg: float=None, api_time_min: float=None, api_time_max: float=None, service_time_avg: float=None, service_time_min: float=None, service_time_max: float=None, **kwargs) -> None: + super(ReportRecordContract, self).__init__(**kwargs) + self.name = name + self.timestamp = timestamp + self.interval = interval + self.country = country + self.region = region + self.zip = zip + self.user_id = None + self.product_id = None + self.api_id = api_id + self.operation_id = operation_id + self.api_region = api_region + self.subscription_id = subscription_id + self.call_count_success = call_count_success + self.call_count_blocked = call_count_blocked + self.call_count_failed = call_count_failed + self.call_count_other = call_count_other + self.call_count_total = call_count_total + self.bandwidth = bandwidth + self.cache_hit_count = cache_hit_count + self.cache_miss_count = cache_miss_count + self.api_time_avg = api_time_avg + self.api_time_min = api_time_min + self.api_time_max = api_time_max + self.service_time_avg = service_time_avg + self.service_time_min = service_time_min + self.service_time_max = service_time_max + + +class RepresentationContract(Model): + """Operation request/response representation details. + + All required parameters must be populated in order to send to Azure. + + :param content_type: Required. Specifies a registered or custom content + type for this representation, e.g. application/xml. + :type content_type: str + :param sample: An example of the representation. + :type sample: str + :param schema_id: Schema identifier. Applicable only if 'contentType' + value is neither 'application/x-www-form-urlencoded' nor + 'multipart/form-data'. + :type schema_id: str + :param type_name: Type name defined by the schema. Applicable only if + 'contentType' value is neither 'application/x-www-form-urlencoded' nor + 'multipart/form-data'. + :type type_name: str + :param form_parameters: Collection of form parameters. Required if + 'contentType' value is either 'application/x-www-form-urlencoded' or + 'multipart/form-data'.. + :type form_parameters: + list[~azure.mgmt.apimanagement.models.ParameterContract] + """ + + _validation = { + 'content_type': {'required': True}, + } + + _attribute_map = { + 'content_type': {'key': 'contentType', 'type': 'str'}, + 'sample': {'key': 'sample', 'type': 'str'}, + 'schema_id': {'key': 'schemaId', 'type': 'str'}, + 'type_name': {'key': 'typeName', 'type': 'str'}, + 'form_parameters': {'key': 'formParameters', 'type': '[ParameterContract]'}, + } + + def __init__(self, *, content_type: str, sample: str=None, schema_id: str=None, type_name: str=None, form_parameters=None, **kwargs) -> None: + super(RepresentationContract, self).__init__(**kwargs) + self.content_type = content_type + self.sample = sample + self.schema_id = schema_id + self.type_name = type_name + self.form_parameters = form_parameters + + +class RequestContract(Model): + """Operation request details. + + :param description: Operation request description. + :type description: str + :param query_parameters: Collection of operation request query parameters. + :type query_parameters: + list[~azure.mgmt.apimanagement.models.ParameterContract] + :param headers: Collection of operation request headers. + :type headers: list[~azure.mgmt.apimanagement.models.ParameterContract] + :param representations: Collection of operation request representations. + :type representations: + list[~azure.mgmt.apimanagement.models.RepresentationContract] + """ + + _attribute_map = { + 'description': {'key': 'description', 'type': 'str'}, + 'query_parameters': {'key': 'queryParameters', 'type': '[ParameterContract]'}, + 'headers': {'key': 'headers', 'type': '[ParameterContract]'}, + 'representations': {'key': 'representations', 'type': '[RepresentationContract]'}, + } + + def __init__(self, *, description: str=None, query_parameters=None, headers=None, representations=None, **kwargs) -> None: + super(RequestContract, self).__init__(**kwargs) + self.description = description + self.query_parameters = query_parameters + self.headers = headers + self.representations = representations + + +class RequestReportRecordContract(Model): + """Request Report data. + + Variables are only populated by the server, and will be ignored when + sending a request. + + :param api_id: API identifier path. /apis/{apiId} + :type api_id: str + :param operation_id: Operation identifier path. + /apis/{apiId}/operations/{operationId} + :type operation_id: str + :ivar product_id: Product identifier path. /products/{productId} + :vartype product_id: str + :ivar user_id: User identifier path. /users/{userId} + :vartype user_id: str + :param method: The HTTP method associated with this request.. + :type method: str + :param url: The full URL associated with this request. + :type url: str + :param ip_address: The client IP address associated with this request. + :type ip_address: str + :param backend_response_code: The HTTP status code received by the gateway + as a result of forwarding this request to the backend. + :type backend_response_code: str + :param response_code: The HTTP status code returned by the gateway. + :type response_code: int + :param response_size: The size of the response returned by the gateway. + :type response_size: int + :param timestamp: The date and time when this request was received by the + gateway in ISO 8601 format. + :type timestamp: datetime + :param cache: Specifies if response cache was involved in generating the + response. If the value is none, the cache was not used. If the value is + hit, cached response was returned. If the value is miss, the cache was + used but lookup resulted in a miss and request was fulfilled by the + backend. + :type cache: str + :param api_time: The total time it took to process this request. + :type api_time: float + :param service_time: he time it took to forward this request to the + backend and get the response back. + :type service_time: float + :param api_region: Azure region where the gateway that processed this + request is located. + :type api_region: str + :param subscription_id: Subscription identifier path. + /subscriptions/{subscriptionId} + :type subscription_id: str + :param request_id: Request Identifier. + :type request_id: str + :param request_size: The size of this request.. + :type request_size: int + """ + + _validation = { + 'product_id': {'readonly': True}, + 'user_id': {'readonly': True}, + } + + _attribute_map = { + 'api_id': {'key': 'apiId', 'type': 'str'}, + 'operation_id': {'key': 'operationId', 'type': 'str'}, + 'product_id': {'key': 'productId', 'type': 'str'}, + 'user_id': {'key': 'userId', 'type': 'str'}, + 'method': {'key': 'method', 'type': 'str'}, + 'url': {'key': 'url', 'type': 'str'}, + 'ip_address': {'key': 'ipAddress', 'type': 'str'}, + 'backend_response_code': {'key': 'backendResponseCode', 'type': 'str'}, + 'response_code': {'key': 'responseCode', 'type': 'int'}, + 'response_size': {'key': 'responseSize', 'type': 'int'}, + 'timestamp': {'key': 'timestamp', 'type': 'iso-8601'}, + 'cache': {'key': 'cache', 'type': 'str'}, + 'api_time': {'key': 'apiTime', 'type': 'float'}, + 'service_time': {'key': 'serviceTime', 'type': 'float'}, + 'api_region': {'key': 'apiRegion', 'type': 'str'}, + 'subscription_id': {'key': 'subscriptionId', 'type': 'str'}, + 'request_id': {'key': 'requestId', 'type': 'str'}, + 'request_size': {'key': 'requestSize', 'type': 'int'}, + } + + def __init__(self, *, api_id: str=None, operation_id: str=None, method: str=None, url: str=None, ip_address: str=None, backend_response_code: str=None, response_code: int=None, response_size: int=None, timestamp=None, cache: str=None, api_time: float=None, service_time: float=None, api_region: str=None, subscription_id: str=None, request_id: str=None, request_size: int=None, **kwargs) -> None: + super(RequestReportRecordContract, self).__init__(**kwargs) + self.api_id = api_id + self.operation_id = operation_id + self.product_id = None + self.user_id = None + self.method = method + self.url = url + self.ip_address = ip_address + self.backend_response_code = backend_response_code + self.response_code = response_code + self.response_size = response_size + self.timestamp = timestamp + self.cache = cache + self.api_time = api_time + self.service_time = service_time + self.api_region = api_region + self.subscription_id = subscription_id + self.request_id = request_id + self.request_size = request_size + + +class ResourceSku(Model): + """Describes an available API Management SKU. + + :param name: Name of the Sku. Possible values include: 'Developer', + 'Standard', 'Premium', 'Basic', 'Consumption' + :type name: str or ~azure.mgmt.apimanagement.models.SkuType + """ + + _attribute_map = { + 'name': {'key': 'name', 'type': 'str'}, + } + + def __init__(self, *, name=None, **kwargs) -> None: + super(ResourceSku, self).__init__(**kwargs) + self.name = name + + +class ResourceSkuCapacity(Model): + """Describes scaling information of a SKU. + + Variables are only populated by the server, and will be ignored when + sending a request. + + :ivar minimum: The minimum capacity. + :vartype minimum: int + :ivar maximum: The maximum capacity that can be set. + :vartype maximum: int + :ivar default: The default capacity. + :vartype default: int + :ivar scale_type: The scale type applicable to the sku. Possible values + include: 'automatic', 'manual', 'none' + :vartype scale_type: str or + ~azure.mgmt.apimanagement.models.ResourceSkuCapacityScaleType + """ + + _validation = { + 'minimum': {'readonly': True}, + 'maximum': {'readonly': True}, + 'default': {'readonly': True}, + 'scale_type': {'readonly': True}, + } + + _attribute_map = { + 'minimum': {'key': 'minimum', 'type': 'int'}, + 'maximum': {'key': 'maximum', 'type': 'int'}, + 'default': {'key': 'default', 'type': 'int'}, + 'scale_type': {'key': 'scaleType', 'type': 'str'}, + } + + def __init__(self, **kwargs) -> None: + super(ResourceSkuCapacity, self).__init__(**kwargs) + self.minimum = None + self.maximum = None + self.default = None + self.scale_type = None + + +class ResourceSkuResult(Model): + """Describes an available API Management service SKU. + + Variables are only populated by the server, and will be ignored when + sending a request. + + :ivar resource_type: The type of resource the SKU applies to. + :vartype resource_type: str + :ivar sku: Specifies API Management SKU. + :vartype sku: ~azure.mgmt.apimanagement.models.ResourceSku + :ivar capacity: Specifies the number of API Management units. + :vartype capacity: ~azure.mgmt.apimanagement.models.ResourceSkuCapacity + """ + + _validation = { + 'resource_type': {'readonly': True}, + 'sku': {'readonly': True}, + 'capacity': {'readonly': True}, + } + + _attribute_map = { + 'resource_type': {'key': 'resourceType', 'type': 'str'}, + 'sku': {'key': 'sku', 'type': 'ResourceSku'}, + 'capacity': {'key': 'capacity', 'type': 'ResourceSkuCapacity'}, + } + + def __init__(self, **kwargs) -> None: + super(ResourceSkuResult, self).__init__(**kwargs) + self.resource_type = None + self.sku = None + self.capacity = None + + +class ResponseContract(Model): + """Operation response details. + + All required parameters must be populated in order to send to Azure. + + :param status_code: Required. Operation response HTTP status code. + :type status_code: int + :param description: Operation response description. + :type description: str + :param representations: Collection of operation response representations. + :type representations: + list[~azure.mgmt.apimanagement.models.RepresentationContract] + :param headers: Collection of operation response headers. + :type headers: list[~azure.mgmt.apimanagement.models.ParameterContract] + """ + + _validation = { + 'status_code': {'required': True}, + } + + _attribute_map = { + 'status_code': {'key': 'statusCode', 'type': 'int'}, + 'description': {'key': 'description', 'type': 'str'}, + 'representations': {'key': 'representations', 'type': '[RepresentationContract]'}, + 'headers': {'key': 'headers', 'type': '[ParameterContract]'}, + } + + def __init__(self, *, status_code: int, description: str=None, representations=None, headers=None, **kwargs) -> None: + super(ResponseContract, self).__init__(**kwargs) + self.status_code = status_code + self.description = description + self.representations = representations + self.headers = headers + + +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 + + +class SaveConfigurationParameter(Model): + """Save Tenant Configuration Contract details. + + All required parameters must be populated in order to send to Azure. + + :param branch: Required. The name of the Git branch in which to commit the + current configuration snapshot. + :type branch: str + :param force: The value if true, the current configuration database is + committed to the Git repository, even if the Git repository has newer + changes that would be overwritten. + :type force: bool + """ + + _validation = { + 'branch': {'required': True}, + } + + _attribute_map = { + 'branch': {'key': 'properties.branch', 'type': 'str'}, + 'force': {'key': 'properties.force', 'type': 'bool'}, + } + + def __init__(self, *, branch: str, force: bool=None, **kwargs) -> None: + super(SaveConfigurationParameter, self).__init__(**kwargs) + self.branch = branch + self.force = force + + +class SchemaContract(Resource): + """Schema Contract details. + + Variables are only populated by the server, and will be ignored when + sending a request. + + All required parameters must be populated in order to send to Azure. + + :ivar id: Resource ID. + :vartype id: str + :ivar name: Resource name. + :vartype name: str + :ivar type: Resource type for API Management resource. + :vartype type: str + :param content_type: Required. Must be a valid a media type used in a + Content-Type header as defined in the RFC 2616. Media type of the schema + document (e.g. application/json, application/xml).
- `Swagger` + Schema use `application/vnd.ms-azure-apim.swagger.definitions+json`
+ - `WSDL` Schema use `application/vnd.ms-azure-apim.xsd+xml`
- + `OpenApi` Schema use `application/vnd.oai.openapi.components+json`
- + `WADL Schema` use `application/vnd.ms-azure-apim.wadl.grammars+xml`. + :type content_type: str + :param value: Json escaped string defining the document representing the + Schema. Used for schemas other than Swagger/OpenAPI. + :type value: str + :param definitions: Types definitions. Used for Swagger/OpenAPI schemas + only, null otherwise. + :type definitions: object + """ + + _validation = { + 'id': {'readonly': True}, + 'name': {'readonly': True}, + 'type': {'readonly': True}, + 'content_type': {'required': True}, + } + + _attribute_map = { + 'id': {'key': 'id', 'type': 'str'}, + 'name': {'key': 'name', 'type': 'str'}, + 'type': {'key': 'type', 'type': 'str'}, + 'content_type': {'key': 'properties.contentType', 'type': 'str'}, + 'value': {'key': 'properties.document.value', 'type': 'str'}, + 'definitions': {'key': 'properties.document.definitions', 'type': 'object'}, + } + + def __init__(self, *, content_type: str, value: str=None, definitions=None, **kwargs) -> None: + super(SchemaContract, self).__init__(**kwargs) + self.content_type = content_type + self.value = value + self.definitions = definitions + + +class SubscriptionContract(Resource): + """Subscription details. + + Variables are only populated by the server, and will be ignored when + sending a request. + + All required parameters must be populated in order to send to Azure. + + :ivar id: Resource ID. + :vartype id: str + :ivar name: Resource name. + :vartype name: str + :ivar type: Resource type for API Management resource. + :vartype type: str + :param owner_id: The user resource identifier of the subscription owner. + The value is a valid relative URL in the format of /users/{userId} where + {userId} is a user identifier. + :type owner_id: str + :param scope: Required. Scope like /products/{productId} or /apis or + /apis/{apiId}. + :type scope: str + :param display_name: The name of the subscription, or null if the + subscription has no name. + :type display_name: str + :param state: Required. Subscription state. Possible states are * active – + the subscription is active, * suspended – the subscription is blocked, and + the subscriber cannot call any APIs of the product, * submitted – the + subscription request has been made by the developer, but has not yet been + approved or rejected, * rejected – the subscription request has been + denied by an administrator, * cancelled – the subscription has been + cancelled by the developer or administrator, * expired – the subscription + reached its expiration date and was deactivated. Possible values include: + 'suspended', 'active', 'expired', 'submitted', 'rejected', 'cancelled' + :type state: str or ~azure.mgmt.apimanagement.models.SubscriptionState + :ivar created_date: Subscription creation date. The date conforms to the + following format: `yyyy-MM-ddTHH:mm:ssZ` as specified by the ISO 8601 + standard. + :vartype created_date: datetime + :param start_date: Subscription activation date. The setting is for audit + purposes only and the subscription is not automatically activated. The + subscription lifecycle can be managed by using the `state` property. The + date conforms to the following format: `yyyy-MM-ddTHH:mm:ssZ` as specified + by the ISO 8601 standard. + :type start_date: datetime + :param expiration_date: Subscription expiration date. The setting is for + audit purposes only and the subscription is not automatically expired. The + subscription lifecycle can be managed by using the `state` property. The + date conforms to the following format: `yyyy-MM-ddTHH:mm:ssZ` as specified + by the ISO 8601 standard. + :type expiration_date: datetime + :param end_date: Date when subscription was cancelled or expired. The + setting is for audit purposes only and the subscription is not + automatically cancelled. The subscription lifecycle can be managed by + using the `state` property. The date conforms to the following format: + `yyyy-MM-ddTHH:mm:ssZ` as specified by the ISO 8601 standard. + :type end_date: datetime + :param notification_date: Upcoming subscription expiration notification + date. The date conforms to the following format: `yyyy-MM-ddTHH:mm:ssZ` as + specified by the ISO 8601 standard. + :type notification_date: datetime + :param primary_key: Subscription primary key. This property will not be + filled on 'GET' operations! Use '/listSecrets' POST request to get the + value. + :type primary_key: str + :param secondary_key: Subscription secondary key. This property will not + be filled on 'GET' operations! Use '/listSecrets' POST request to get the + value. + :type secondary_key: str + :param state_comment: Optional subscription comment added by an + administrator. + :type state_comment: str + :param allow_tracing: Determines whether tracing is enabled + :type allow_tracing: bool + """ + + _validation = { + 'id': {'readonly': True}, + 'name': {'readonly': True}, + 'type': {'readonly': True}, + 'scope': {'required': True}, + 'display_name': {'max_length': 100, 'min_length': 0}, + 'state': {'required': True}, + 'created_date': {'readonly': True}, + 'primary_key': {'max_length': 256, 'min_length': 1}, + 'secondary_key': {'max_length': 256, 'min_length': 1}, + } + + _attribute_map = { + 'id': {'key': 'id', 'type': 'str'}, + 'name': {'key': 'name', 'type': 'str'}, + 'type': {'key': 'type', 'type': 'str'}, + 'owner_id': {'key': 'properties.ownerId', 'type': 'str'}, + 'scope': {'key': 'properties.scope', 'type': 'str'}, + 'display_name': {'key': 'properties.displayName', 'type': 'str'}, + 'state': {'key': 'properties.state', 'type': 'SubscriptionState'}, + 'created_date': {'key': 'properties.createdDate', 'type': 'iso-8601'}, + 'start_date': {'key': 'properties.startDate', 'type': 'iso-8601'}, + 'expiration_date': {'key': 'properties.expirationDate', 'type': 'iso-8601'}, + 'end_date': {'key': 'properties.endDate', 'type': 'iso-8601'}, + 'notification_date': {'key': 'properties.notificationDate', 'type': 'iso-8601'}, + 'primary_key': {'key': 'properties.primaryKey', 'type': 'str'}, + 'secondary_key': {'key': 'properties.secondaryKey', 'type': 'str'}, + 'state_comment': {'key': 'properties.stateComment', 'type': 'str'}, + 'allow_tracing': {'key': 'properties.allowTracing', 'type': 'bool'}, + } + + def __init__(self, *, scope: str, state, owner_id: str=None, display_name: str=None, start_date=None, expiration_date=None, end_date=None, notification_date=None, primary_key: str=None, secondary_key: str=None, state_comment: str=None, allow_tracing: bool=None, **kwargs) -> None: + super(SubscriptionContract, self).__init__(**kwargs) + self.owner_id = owner_id + self.scope = scope + self.display_name = display_name + self.state = state + self.created_date = None + self.start_date = start_date + self.expiration_date = expiration_date + self.end_date = end_date + self.notification_date = notification_date + self.primary_key = primary_key + self.secondary_key = secondary_key + self.state_comment = state_comment + self.allow_tracing = allow_tracing + + +class SubscriptionCreateParameters(Model): + """Subscription create details. + + All required parameters must be populated in order to send to Azure. + + :param owner_id: User (user id path) for whom subscription is being + created in form /users/{userId} + :type owner_id: str + :param scope: Required. Scope like /products/{productId} or /apis or + /apis/{apiId}. + :type scope: str + :param display_name: Required. Subscription name. + :type display_name: str + :param primary_key: Primary subscription key. If not specified during + request key will be generated automatically. + :type primary_key: str + :param secondary_key: Secondary subscription key. If not specified during + request key will be generated automatically. + :type secondary_key: str + :param state: Initial subscription state. If no value is specified, + subscription is created with Submitted state. Possible states are * active + – the subscription is active, * suspended – the subscription is blocked, + and the subscriber cannot call any APIs of the product, * submitted – the + subscription request has been made by the developer, but has not yet been + approved or rejected, * rejected – the subscription request has been + denied by an administrator, * cancelled – the subscription has been + cancelled by the developer or administrator, * expired – the subscription + reached its expiration date and was deactivated. Possible values include: + 'suspended', 'active', 'expired', 'submitted', 'rejected', 'cancelled' + :type state: str or ~azure.mgmt.apimanagement.models.SubscriptionState + :param allow_tracing: Determines whether tracing can be enabled + :type allow_tracing: bool + """ + + _validation = { + 'scope': {'required': True}, + 'display_name': {'required': True, 'max_length': 100, 'min_length': 1}, + 'primary_key': {'max_length': 256, 'min_length': 1}, + 'secondary_key': {'max_length': 256, 'min_length': 1}, + } + + _attribute_map = { + 'owner_id': {'key': 'properties.ownerId', 'type': 'str'}, + 'scope': {'key': 'properties.scope', 'type': 'str'}, + 'display_name': {'key': 'properties.displayName', 'type': 'str'}, + 'primary_key': {'key': 'properties.primaryKey', 'type': 'str'}, + 'secondary_key': {'key': 'properties.secondaryKey', 'type': 'str'}, + 'state': {'key': 'properties.state', 'type': 'SubscriptionState'}, + 'allow_tracing': {'key': 'properties.allowTracing', 'type': 'bool'}, + } + + def __init__(self, *, scope: str, display_name: str, owner_id: str=None, primary_key: str=None, secondary_key: str=None, state=None, allow_tracing: bool=None, **kwargs) -> None: + super(SubscriptionCreateParameters, self).__init__(**kwargs) + self.owner_id = owner_id + self.scope = scope + self.display_name = display_name + self.primary_key = primary_key + self.secondary_key = secondary_key + self.state = state + self.allow_tracing = allow_tracing + + +class SubscriptionKeyParameterNamesContract(Model): + """Subscription key parameter names details. + + :param header: Subscription key header name. + :type header: str + :param query: Subscription key query string parameter name. + :type query: str + """ + + _attribute_map = { + 'header': {'key': 'header', 'type': 'str'}, + 'query': {'key': 'query', 'type': 'str'}, + } + + def __init__(self, *, header: str=None, query: str=None, **kwargs) -> None: + super(SubscriptionKeyParameterNamesContract, self).__init__(**kwargs) + self.header = header + self.query = query + + +class SubscriptionKeysContract(Model): + """Subscription keys. + + :param primary_key: Subscription primary key. + :type primary_key: str + :param secondary_key: Subscription secondary key. + :type secondary_key: str + """ + + _validation = { + 'primary_key': {'max_length': 256, 'min_length': 1}, + 'secondary_key': {'max_length': 256, 'min_length': 1}, + } + + _attribute_map = { + 'primary_key': {'key': 'primaryKey', 'type': 'str'}, + 'secondary_key': {'key': 'secondaryKey', 'type': 'str'}, + } + + def __init__(self, *, primary_key: str=None, secondary_key: str=None, **kwargs) -> None: + super(SubscriptionKeysContract, self).__init__(**kwargs) + self.primary_key = primary_key + self.secondary_key = secondary_key + + +class SubscriptionsDelegationSettingsProperties(Model): + """Subscriptions delegation settings properties. + + :param enabled: Enable or disable delegation for subscriptions. + :type enabled: bool + """ + + _attribute_map = { + 'enabled': {'key': 'enabled', 'type': 'bool'}, + } + + def __init__(self, *, enabled: bool=None, **kwargs) -> None: + super(SubscriptionsDelegationSettingsProperties, self).__init__(**kwargs) + self.enabled = enabled + + +class SubscriptionUpdateParameters(Model): + """Subscription update details. + + :param owner_id: User identifier path: /users/{userId} + :type owner_id: str + :param scope: Scope like /products/{productId} or /apis or /apis/{apiId} + :type scope: str + :param expiration_date: Subscription expiration date. The setting is for + audit purposes only and the subscription is not automatically expired. The + subscription lifecycle can be managed by using the `state` property. The + date conforms to the following format: `yyyy-MM-ddTHH:mm:ssZ` as specified + by the ISO 8601 standard. + :type expiration_date: datetime + :param display_name: Subscription name. + :type display_name: str + :param primary_key: Primary subscription key. + :type primary_key: str + :param secondary_key: Secondary subscription key. + :type secondary_key: str + :param state: Subscription state. Possible states are * active – the + subscription is active, * suspended – the subscription is blocked, and the + subscriber cannot call any APIs of the product, * submitted – the + subscription request has been made by the developer, but has not yet been + approved or rejected, * rejected – the subscription request has been + denied by an administrator, * cancelled – the subscription has been + cancelled by the developer or administrator, * expired – the subscription + reached its expiration date and was deactivated. Possible values include: + 'suspended', 'active', 'expired', 'submitted', 'rejected', 'cancelled' + :type state: str or ~azure.mgmt.apimanagement.models.SubscriptionState + :param state_comment: Comments describing subscription state change by the + administrator. + :type state_comment: str + :param allow_tracing: Determines whether tracing can be enabled + :type allow_tracing: bool + """ + + _validation = { + 'primary_key': {'max_length': 256, 'min_length': 1}, + 'secondary_key': {'max_length': 256, 'min_length': 1}, + } + + _attribute_map = { + 'owner_id': {'key': 'properties.ownerId', 'type': 'str'}, + 'scope': {'key': 'properties.scope', 'type': 'str'}, + 'expiration_date': {'key': 'properties.expirationDate', 'type': 'iso-8601'}, + 'display_name': {'key': 'properties.displayName', 'type': 'str'}, + 'primary_key': {'key': 'properties.primaryKey', 'type': 'str'}, + 'secondary_key': {'key': 'properties.secondaryKey', 'type': 'str'}, + 'state': {'key': 'properties.state', 'type': 'SubscriptionState'}, + 'state_comment': {'key': 'properties.stateComment', 'type': 'str'}, + 'allow_tracing': {'key': 'properties.allowTracing', 'type': 'bool'}, + } + + def __init__(self, *, owner_id: str=None, scope: str=None, expiration_date=None, display_name: str=None, primary_key: str=None, secondary_key: str=None, state=None, state_comment: str=None, allow_tracing: bool=None, **kwargs) -> None: + super(SubscriptionUpdateParameters, self).__init__(**kwargs) + self.owner_id = owner_id + self.scope = scope + self.expiration_date = expiration_date + self.display_name = display_name + self.primary_key = primary_key + self.secondary_key = secondary_key + self.state = state + self.state_comment = state_comment + self.allow_tracing = allow_tracing + + +class TagContract(Resource): + """Tag Contract details. + + Variables are only populated by the server, and will be ignored when + sending a request. + + All required parameters must be populated in order to send to Azure. + + :ivar id: Resource ID. + :vartype id: str + :ivar name: Resource name. + :vartype name: str + :ivar type: Resource type for API Management resource. + :vartype type: str + :param display_name: Required. Tag name. + :type display_name: str + """ + + _validation = { + 'id': {'readonly': True}, + 'name': {'readonly': True}, + 'type': {'readonly': True}, + 'display_name': {'required': True, 'max_length': 160, 'min_length': 1}, + } + + _attribute_map = { + 'id': {'key': 'id', 'type': 'str'}, + 'name': {'key': 'name', 'type': 'str'}, + 'type': {'key': 'type', 'type': 'str'}, + 'display_name': {'key': 'properties.displayName', 'type': 'str'}, + } + + def __init__(self, *, display_name: str, **kwargs) -> None: + super(TagContract, self).__init__(**kwargs) + self.display_name = display_name + + +class TagCreateUpdateParameters(Model): + """Parameters supplied to Create/Update Tag operations. + + All required parameters must be populated in order to send to Azure. + + :param display_name: Required. Tag name. + :type display_name: str + """ + + _validation = { + 'display_name': {'required': True, 'max_length': 160, 'min_length': 1}, + } + + _attribute_map = { + 'display_name': {'key': 'properties.displayName', 'type': 'str'}, + } + + def __init__(self, *, display_name: str, **kwargs) -> None: + super(TagCreateUpdateParameters, self).__init__(**kwargs) + self.display_name = display_name + + +class TagDescriptionContract(Resource): + """Contract details. + + Variables are only populated by the server, and will be ignored when + sending a request. + + :ivar id: Resource ID. + :vartype id: str + :ivar name: Resource name. + :vartype name: str + :ivar type: Resource type for API Management resource. + :vartype type: str + :param description: Description of the Tag. + :type description: str + :param external_docs_url: Absolute URL of external resources describing + the tag. + :type external_docs_url: str + :param external_docs_description: Description of the external resources + describing the tag. + :type external_docs_description: str + :param tag_id: Identifier of the tag in the form of /tags/{tagId} + :type tag_id: str + :param display_name: Tag name. + :type display_name: str + """ + + _validation = { + 'id': {'readonly': True}, + 'name': {'readonly': True}, + 'type': {'readonly': True}, + 'external_docs_url': {'max_length': 2000}, + 'display_name': {'max_length': 160, 'min_length': 1}, + } + + _attribute_map = { + 'id': {'key': 'id', 'type': 'str'}, + 'name': {'key': 'name', 'type': 'str'}, + 'type': {'key': 'type', 'type': 'str'}, + 'description': {'key': 'properties.description', 'type': 'str'}, + 'external_docs_url': {'key': 'properties.externalDocsUrl', 'type': 'str'}, + 'external_docs_description': {'key': 'properties.externalDocsDescription', 'type': 'str'}, + 'tag_id': {'key': 'properties.tagId', 'type': 'str'}, + 'display_name': {'key': 'properties.displayName', 'type': 'str'}, + } + + def __init__(self, *, description: str=None, external_docs_url: str=None, external_docs_description: str=None, tag_id: str=None, display_name: str=None, **kwargs) -> None: + super(TagDescriptionContract, self).__init__(**kwargs) + self.description = description + self.external_docs_url = external_docs_url + self.external_docs_description = external_docs_description + self.tag_id = tag_id + self.display_name = display_name + + +class TagDescriptionCreateParameters(Model): + """Parameters supplied to the Create TagDescription operation. + + :param description: Description of the Tag. + :type description: str + :param external_docs_url: Absolute URL of external resources describing + the tag. + :type external_docs_url: str + :param external_docs_description: Description of the external resources + describing the tag. + :type external_docs_description: str + """ + + _validation = { + 'external_docs_url': {'max_length': 2000}, + } + + _attribute_map = { + 'description': {'key': 'properties.description', 'type': 'str'}, + 'external_docs_url': {'key': 'properties.externalDocsUrl', 'type': 'str'}, + 'external_docs_description': {'key': 'properties.externalDocsDescription', 'type': 'str'}, + } + + def __init__(self, *, description: str=None, external_docs_url: str=None, external_docs_description: str=None, **kwargs) -> None: + super(TagDescriptionCreateParameters, self).__init__(**kwargs) + self.description = description + self.external_docs_url = external_docs_url + self.external_docs_description = external_docs_description + + +class TagResourceContract(Model): + """TagResource contract properties. + + All required parameters must be populated in order to send to Azure. + + :param tag: Required. Tag associated with the resource. + :type tag: + ~azure.mgmt.apimanagement.models.TagTagResourceContractProperties + :param api: Api associated with the tag. + :type api: + ~azure.mgmt.apimanagement.models.ApiTagResourceContractProperties + :param operation: Operation associated with the tag. + :type operation: + ~azure.mgmt.apimanagement.models.OperationTagResourceContractProperties + :param product: Product associated with the tag. + :type product: + ~azure.mgmt.apimanagement.models.ProductTagResourceContractProperties + """ + + _validation = { + 'tag': {'required': True}, + } + + _attribute_map = { + 'tag': {'key': 'tag', 'type': 'TagTagResourceContractProperties'}, + 'api': {'key': 'api', 'type': 'ApiTagResourceContractProperties'}, + 'operation': {'key': 'operation', 'type': 'OperationTagResourceContractProperties'}, + 'product': {'key': 'product', 'type': 'ProductTagResourceContractProperties'}, + } + + def __init__(self, *, tag, api=None, operation=None, product=None, **kwargs) -> None: + super(TagResourceContract, self).__init__(**kwargs) + self.tag = tag + self.api = api + self.operation = operation + self.product = product + + +class TagTagResourceContractProperties(Model): + """Contract defining the Tag property in the Tag Resource Contract. + + :param id: Tag identifier + :type id: str + :param name: Tag Name + :type name: str + """ + + _validation = { + 'name': {'max_length': 160, 'min_length': 1}, + } + + _attribute_map = { + 'id': {'key': 'id', 'type': 'str'}, + 'name': {'key': 'name', 'type': 'str'}, + } + + def __init__(self, *, id: str=None, name: str=None, **kwargs) -> None: + super(TagTagResourceContractProperties, self).__init__(**kwargs) + self.id = id + self.name = name + + +class TenantConfigurationSyncStateContract(Model): + """Tenant Configuration Synchronization State. + + :param branch: The name of Git branch. + :type branch: str + :param commit_id: The latest commit Id. + :type commit_id: str + :param is_export: value indicating if last sync was save (true) or deploy + (false) operation. + :type is_export: bool + :param is_synced: value indicating if last synchronization was later than + the configuration change. + :type is_synced: bool + :param is_git_enabled: value indicating whether Git configuration access + is enabled. + :type is_git_enabled: bool + :param sync_date: The date of the latest synchronization. The date + conforms to the following format: `yyyy-MM-ddTHH:mm:ssZ` as specified by + the ISO 8601 standard. + :type sync_date: datetime + :param configuration_change_date: The date of the latest configuration + change. The date conforms to the following format: `yyyy-MM-ddTHH:mm:ssZ` + as specified by the ISO 8601 standard. + :type configuration_change_date: datetime + """ + + _attribute_map = { + 'branch': {'key': 'branch', 'type': 'str'}, + 'commit_id': {'key': 'commitId', 'type': 'str'}, + 'is_export': {'key': 'isExport', 'type': 'bool'}, + 'is_synced': {'key': 'isSynced', 'type': 'bool'}, + 'is_git_enabled': {'key': 'isGitEnabled', 'type': 'bool'}, + 'sync_date': {'key': 'syncDate', 'type': 'iso-8601'}, + 'configuration_change_date': {'key': 'configurationChangeDate', 'type': 'iso-8601'}, + } + + def __init__(self, *, branch: str=None, commit_id: str=None, is_export: bool=None, is_synced: bool=None, is_git_enabled: bool=None, sync_date=None, configuration_change_date=None, **kwargs) -> None: + super(TenantConfigurationSyncStateContract, self).__init__(**kwargs) + self.branch = branch + self.commit_id = commit_id + self.is_export = is_export + self.is_synced = is_synced + self.is_git_enabled = is_git_enabled + self.sync_date = sync_date + self.configuration_change_date = configuration_change_date + + +class TermsOfServiceProperties(Model): + """Terms of service contract properties. + + :param text: A terms of service text. + :type text: str + :param enabled: Display terms of service during a sign-up process. + :type enabled: bool + :param consent_required: Ask user for consent to the terms of service. + :type consent_required: bool + """ + + _attribute_map = { + 'text': {'key': 'text', 'type': 'str'}, + 'enabled': {'key': 'enabled', 'type': 'bool'}, + 'consent_required': {'key': 'consentRequired', 'type': 'bool'}, + } + + def __init__(self, *, text: str=None, enabled: bool=None, consent_required: bool=None, **kwargs) -> None: + super(TermsOfServiceProperties, self).__init__(**kwargs) + self.text = text + self.enabled = enabled + self.consent_required = consent_required + + +class TokenBodyParameterContract(Model): + """OAuth acquire token request body parameter (www-url-form-encoded). + + All required parameters must be populated in order to send to Azure. + + :param name: Required. body parameter name. + :type name: str + :param value: Required. body parameter value. + :type value: str + """ + + _validation = { + 'name': {'required': True}, + 'value': {'required': True}, + } + + _attribute_map = { + 'name': {'key': 'name', 'type': 'str'}, + 'value': {'key': 'value', 'type': 'str'}, + } + + def __init__(self, *, name: str, value: str, **kwargs) -> None: + super(TokenBodyParameterContract, self).__init__(**kwargs) + self.name = name + self.value = value + + +class UserContract(Resource): + """User details. + + Variables are only populated by the server, and will be ignored when + sending a request. + + :ivar id: Resource ID. + :vartype id: str + :ivar name: Resource name. + :vartype name: str + :ivar type: Resource type for API Management resource. + :vartype type: str + :param state: Account state. Specifies whether the user is active or not. + Blocked users are unable to sign into the developer portal or call any + APIs of subscribed products. Default state is Active. Possible values + include: 'active', 'blocked', 'pending', 'deleted'. Default value: + "active" . + :type state: str or ~azure.mgmt.apimanagement.models.UserState + :param note: Optional note about a user set by the administrator. + :type note: str + :param identities: Collection of user identities. + :type identities: + list[~azure.mgmt.apimanagement.models.UserIdentityContract] + :param first_name: First name. + :type first_name: str + :param last_name: Last name. + :type last_name: str + :param email: Email address. + :type email: str + :param registration_date: Date of user registration. The date conforms to + the following format: `yyyy-MM-ddTHH:mm:ssZ` as specified by the ISO 8601 + standard. + :type registration_date: datetime + :ivar groups: Collection of groups user is part of. + :vartype groups: + list[~azure.mgmt.apimanagement.models.GroupContractProperties] + """ + + _validation = { + 'id': {'readonly': True}, + 'name': {'readonly': True}, + 'type': {'readonly': True}, + 'groups': {'readonly': True}, + } + + _attribute_map = { + 'id': {'key': 'id', 'type': 'str'}, + 'name': {'key': 'name', 'type': 'str'}, + 'type': {'key': 'type', 'type': 'str'}, + 'state': {'key': 'properties.state', 'type': 'str'}, + 'note': {'key': 'properties.note', 'type': 'str'}, + 'identities': {'key': 'properties.identities', 'type': '[UserIdentityContract]'}, + 'first_name': {'key': 'properties.firstName', 'type': 'str'}, + 'last_name': {'key': 'properties.lastName', 'type': 'str'}, + 'email': {'key': 'properties.email', 'type': 'str'}, + 'registration_date': {'key': 'properties.registrationDate', 'type': 'iso-8601'}, + 'groups': {'key': 'properties.groups', 'type': '[GroupContractProperties]'}, + } + + def __init__(self, *, state="active", note: str=None, identities=None, first_name: str=None, last_name: str=None, email: str=None, registration_date=None, **kwargs) -> None: + super(UserContract, self).__init__(**kwargs) + self.state = state + self.note = note + self.identities = identities + self.first_name = first_name + self.last_name = last_name + self.email = email + self.registration_date = registration_date + self.groups = None + + +class UserCreateParameters(Model): + """User create details. + + All required parameters must be populated in order to send to Azure. + + :param state: Account state. Specifies whether the user is active or not. + Blocked users are unable to sign into the developer portal or call any + APIs of subscribed products. Default state is Active. Possible values + include: 'active', 'blocked', 'pending', 'deleted'. Default value: + "active" . + :type state: str or ~azure.mgmt.apimanagement.models.UserState + :param note: Optional note about a user set by the administrator. + :type note: str + :param identities: Collection of user identities. + :type identities: + list[~azure.mgmt.apimanagement.models.UserIdentityContract] + :param email: Required. Email address. Must not be empty and must be + unique within the service instance. + :type email: str + :param first_name: Required. First name. + :type first_name: str + :param last_name: Required. Last name. + :type last_name: str + :param password: User Password. If no value is provided, a default + password is generated. + :type password: str + :param confirmation: Determines the type of confirmation e-mail that will + be sent to the newly created user. Possible values include: 'signup', + 'invite' + :type confirmation: str or ~azure.mgmt.apimanagement.models.Confirmation + """ + + _validation = { + 'email': {'required': True, 'max_length': 254, 'min_length': 1}, + 'first_name': {'required': True, 'max_length': 100, 'min_length': 1}, + 'last_name': {'required': True, 'max_length': 100, 'min_length': 1}, + } + + _attribute_map = { + 'state': {'key': 'properties.state', 'type': 'str'}, + 'note': {'key': 'properties.note', 'type': 'str'}, + 'identities': {'key': 'properties.identities', 'type': '[UserIdentityContract]'}, + 'email': {'key': 'properties.email', 'type': 'str'}, + 'first_name': {'key': 'properties.firstName', 'type': 'str'}, + 'last_name': {'key': 'properties.lastName', 'type': 'str'}, + 'password': {'key': 'properties.password', 'type': 'str'}, + 'confirmation': {'key': 'properties.confirmation', 'type': 'str'}, + } + + def __init__(self, *, email: str, first_name: str, last_name: str, state="active", note: str=None, identities=None, password: str=None, confirmation=None, **kwargs) -> None: + super(UserCreateParameters, self).__init__(**kwargs) + self.state = state + self.note = note + self.identities = identities + self.email = email + self.first_name = first_name + self.last_name = last_name + self.password = password + self.confirmation = confirmation + + +class UserEntityBaseParameters(Model): + """User Entity Base Parameters set. + + :param state: Account state. Specifies whether the user is active or not. + Blocked users are unable to sign into the developer portal or call any + APIs of subscribed products. Default state is Active. Possible values + include: 'active', 'blocked', 'pending', 'deleted'. Default value: + "active" . + :type state: str or ~azure.mgmt.apimanagement.models.UserState + :param note: Optional note about a user set by the administrator. + :type note: str + :param identities: Collection of user identities. + :type identities: + list[~azure.mgmt.apimanagement.models.UserIdentityContract] + """ + + _attribute_map = { + 'state': {'key': 'state', 'type': 'str'}, + 'note': {'key': 'note', 'type': 'str'}, + 'identities': {'key': 'identities', 'type': '[UserIdentityContract]'}, + } + + def __init__(self, *, state="active", note: str=None, identities=None, **kwargs) -> None: + super(UserEntityBaseParameters, self).__init__(**kwargs) + self.state = state + self.note = note + self.identities = identities + + +class UserIdentityContract(Model): + """User identity details. + + :param provider: Identity provider name. + :type provider: str + :param id: Identifier value within provider. + :type id: str + """ + + _attribute_map = { + 'provider': {'key': 'provider', 'type': 'str'}, + 'id': {'key': 'id', 'type': 'str'}, + } + + def __init__(self, *, provider: str=None, id: str=None, **kwargs) -> None: + super(UserIdentityContract, self).__init__(**kwargs) + self.provider = provider + self.id = id + + +class UserTokenParameters(Model): + """Get User Token parameters. + + All required parameters must be populated in order to send to Azure. + + :param key_type: Required. The Key to be used to generate token for user. + Possible values include: 'primary', 'secondary'. Default value: "primary" + . + :type key_type: str or ~azure.mgmt.apimanagement.models.KeyType + :param expiry: Required. The Expiry time of the Token. Maximum token + expiry time is set to 30 days. The date conforms to the following format: + `yyyy-MM-ddTHH:mm:ssZ` as specified by the ISO 8601 standard. + :type expiry: datetime + """ + + _validation = { + 'key_type': {'required': True}, + 'expiry': {'required': True}, + } + + _attribute_map = { + 'key_type': {'key': 'properties.keyType', 'type': 'KeyType'}, + 'expiry': {'key': 'properties.expiry', 'type': 'iso-8601'}, + } + + def __init__(self, *, expiry, key_type="primary", **kwargs) -> None: + super(UserTokenParameters, self).__init__(**kwargs) + self.key_type = key_type + self.expiry = expiry + + +class UserTokenResult(Model): + """Get User Token response details. + + :param value: Shared Access Authorization token for the User. + :type value: str + """ + + _attribute_map = { + 'value': {'key': 'value', 'type': 'str'}, + } + + def __init__(self, *, value: str=None, **kwargs) -> None: + super(UserTokenResult, self).__init__(**kwargs) + self.value = value + + +class UserUpdateParameters(Model): + """User update parameters. + + :param state: Account state. Specifies whether the user is active or not. + Blocked users are unable to sign into the developer portal or call any + APIs of subscribed products. Default state is Active. Possible values + include: 'active', 'blocked', 'pending', 'deleted'. Default value: + "active" . + :type state: str or ~azure.mgmt.apimanagement.models.UserState + :param note: Optional note about a user set by the administrator. + :type note: str + :param identities: Collection of user identities. + :type identities: + list[~azure.mgmt.apimanagement.models.UserIdentityContract] + :param email: Email address. Must not be empty and must be unique within + the service instance. + :type email: str + :param password: User Password. + :type password: str + :param first_name: First name. + :type first_name: str + :param last_name: Last name. + :type last_name: str + """ + + _validation = { + 'email': {'max_length': 254, 'min_length': 1}, + 'first_name': {'max_length': 100, 'min_length': 1}, + 'last_name': {'max_length': 100, 'min_length': 1}, + } + + _attribute_map = { + 'state': {'key': 'properties.state', 'type': 'str'}, + 'note': {'key': 'properties.note', 'type': 'str'}, + 'identities': {'key': 'properties.identities', 'type': '[UserIdentityContract]'}, + 'email': {'key': 'properties.email', 'type': 'str'}, + 'password': {'key': 'properties.password', 'type': 'str'}, + 'first_name': {'key': 'properties.firstName', 'type': 'str'}, + 'last_name': {'key': 'properties.lastName', 'type': 'str'}, + } + + def __init__(self, *, state="active", note: str=None, identities=None, email: str=None, password: str=None, first_name: str=None, last_name: str=None, **kwargs) -> None: + super(UserUpdateParameters, self).__init__(**kwargs) + self.state = state + self.note = note + self.identities = identities + self.email = email + self.password = password + self.first_name = first_name + self.last_name = last_name + + +class VirtualNetworkConfiguration(Model): + """Configuration of a virtual network to which API Management service is + deployed. + + Variables are only populated by the server, and will be ignored when + sending a request. + + :ivar vnetid: The virtual network ID. This is typically a GUID. Expect a + null GUID by default. + :vartype vnetid: str + :ivar subnetname: The name of the subnet. + :vartype subnetname: str + :param subnet_resource_id: The full resource ID of a subnet in a virtual + network to deploy the API Management service in. + :type subnet_resource_id: str + """ + + _validation = { + 'vnetid': {'readonly': True}, + 'subnetname': {'readonly': True}, + 'subnet_resource_id': {'pattern': r'^/subscriptions/[^/]*/resourceGroups/[^/]*/providers/Microsoft.(ClassicNetwork|Network)/virtualNetworks/[^/]*/subnets/[^/]*$'}, + } + + _attribute_map = { + 'vnetid': {'key': 'vnetid', 'type': 'str'}, + 'subnetname': {'key': 'subnetname', 'type': 'str'}, + 'subnet_resource_id': {'key': 'subnetResourceId', 'type': 'str'}, + } + + def __init__(self, *, subnet_resource_id: str=None, **kwargs) -> None: + super(VirtualNetworkConfiguration, self).__init__(**kwargs) + self.vnetid = None + self.subnetname = None + self.subnet_resource_id = subnet_resource_id + + +class X509CertificateName(Model): + """Properties of server X509Names. + + :param name: Common Name of the Certificate. + :type name: str + :param issuer_certificate_thumbprint: Thumbprint for the Issuer of the + Certificate. + :type issuer_certificate_thumbprint: str + """ + + _attribute_map = { + 'name': {'key': 'name', 'type': 'str'}, + 'issuer_certificate_thumbprint': {'key': 'issuerCertificateThumbprint', 'type': 'str'}, + } + + def __init__(self, *, name: str=None, issuer_certificate_thumbprint: str=None, **kwargs) -> None: + super(X509CertificateName, self).__init__(**kwargs) + self.name = name + self.issuer_certificate_thumbprint = issuer_certificate_thumbprint diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/_paged_models.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/_paged_models.py new file mode 100644 index 000000000000..49405cae5c07 --- /dev/null +++ b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/_paged_models.py @@ -0,0 +1,456 @@ +# 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.paging import Paged + + +class ApiContractPaged(Paged): + """ + A paging container for iterating over a list of :class:`ApiContract ` object + """ + + _attribute_map = { + 'next_link': {'key': 'nextLink', 'type': 'str'}, + 'current_page': {'key': 'value', 'type': '[ApiContract]'} + } + + def __init__(self, *args, **kwargs): + + super(ApiContractPaged, self).__init__(*args, **kwargs) +class TagResourceContractPaged(Paged): + """ + A paging container for iterating over a list of :class:`TagResourceContract ` object + """ + + _attribute_map = { + 'next_link': {'key': 'nextLink', 'type': 'str'}, + 'current_page': {'key': 'value', 'type': '[TagResourceContract]'} + } + + def __init__(self, *args, **kwargs): + + super(TagResourceContractPaged, self).__init__(*args, **kwargs) +class ApiRevisionContractPaged(Paged): + """ + A paging container for iterating over a list of :class:`ApiRevisionContract ` object + """ + + _attribute_map = { + 'next_link': {'key': 'nextLink', 'type': 'str'}, + 'current_page': {'key': 'value', 'type': '[ApiRevisionContract]'} + } + + def __init__(self, *args, **kwargs): + + super(ApiRevisionContractPaged, self).__init__(*args, **kwargs) +class ApiReleaseContractPaged(Paged): + """ + A paging container for iterating over a list of :class:`ApiReleaseContract ` object + """ + + _attribute_map = { + 'next_link': {'key': 'nextLink', 'type': 'str'}, + 'current_page': {'key': 'value', 'type': '[ApiReleaseContract]'} + } + + def __init__(self, *args, **kwargs): + + super(ApiReleaseContractPaged, self).__init__(*args, **kwargs) +class OperationContractPaged(Paged): + """ + A paging container for iterating over a list of :class:`OperationContract ` object + """ + + _attribute_map = { + 'next_link': {'key': 'nextLink', 'type': 'str'}, + 'current_page': {'key': 'value', 'type': '[OperationContract]'} + } + + def __init__(self, *args, **kwargs): + + super(OperationContractPaged, self).__init__(*args, **kwargs) +class TagContractPaged(Paged): + """ + A paging container for iterating over a list of :class:`TagContract ` object + """ + + _attribute_map = { + 'next_link': {'key': 'nextLink', 'type': 'str'}, + 'current_page': {'key': 'value', 'type': '[TagContract]'} + } + + def __init__(self, *args, **kwargs): + + super(TagContractPaged, self).__init__(*args, **kwargs) +class ProductContractPaged(Paged): + """ + A paging container for iterating over a list of :class:`ProductContract ` object + """ + + _attribute_map = { + 'next_link': {'key': 'nextLink', 'type': 'str'}, + 'current_page': {'key': 'value', 'type': '[ProductContract]'} + } + + def __init__(self, *args, **kwargs): + + super(ProductContractPaged, self).__init__(*args, **kwargs) +class SchemaContractPaged(Paged): + """ + A paging container for iterating over a list of :class:`SchemaContract ` object + """ + + _attribute_map = { + 'next_link': {'key': 'nextLink', 'type': 'str'}, + 'current_page': {'key': 'value', 'type': '[SchemaContract]'} + } + + def __init__(self, *args, **kwargs): + + super(SchemaContractPaged, self).__init__(*args, **kwargs) +class DiagnosticContractPaged(Paged): + """ + A paging container for iterating over a list of :class:`DiagnosticContract ` object + """ + + _attribute_map = { + 'next_link': {'key': 'nextLink', 'type': 'str'}, + 'current_page': {'key': 'value', 'type': '[DiagnosticContract]'} + } + + def __init__(self, *args, **kwargs): + + super(DiagnosticContractPaged, self).__init__(*args, **kwargs) +class IssueContractPaged(Paged): + """ + A paging container for iterating over a list of :class:`IssueContract ` object + """ + + _attribute_map = { + 'next_link': {'key': 'nextLink', 'type': 'str'}, + 'current_page': {'key': 'value', 'type': '[IssueContract]'} + } + + def __init__(self, *args, **kwargs): + + super(IssueContractPaged, self).__init__(*args, **kwargs) +class IssueCommentContractPaged(Paged): + """ + A paging container for iterating over a list of :class:`IssueCommentContract ` object + """ + + _attribute_map = { + 'next_link': {'key': 'nextLink', 'type': 'str'}, + 'current_page': {'key': 'value', 'type': '[IssueCommentContract]'} + } + + def __init__(self, *args, **kwargs): + + super(IssueCommentContractPaged, self).__init__(*args, **kwargs) +class IssueAttachmentContractPaged(Paged): + """ + A paging container for iterating over a list of :class:`IssueAttachmentContract ` object + """ + + _attribute_map = { + 'next_link': {'key': 'nextLink', 'type': 'str'}, + 'current_page': {'key': 'value', 'type': '[IssueAttachmentContract]'} + } + + def __init__(self, *args, **kwargs): + + super(IssueAttachmentContractPaged, self).__init__(*args, **kwargs) +class TagDescriptionContractPaged(Paged): + """ + A paging container for iterating over a list of :class:`TagDescriptionContract ` object + """ + + _attribute_map = { + 'next_link': {'key': 'nextLink', 'type': 'str'}, + 'current_page': {'key': 'value', 'type': '[TagDescriptionContract]'} + } + + def __init__(self, *args, **kwargs): + + super(TagDescriptionContractPaged, self).__init__(*args, **kwargs) +class ApiVersionSetContractPaged(Paged): + """ + A paging container for iterating over a list of :class:`ApiVersionSetContract ` object + """ + + _attribute_map = { + 'next_link': {'key': 'nextLink', 'type': 'str'}, + 'current_page': {'key': 'value', 'type': '[ApiVersionSetContract]'} + } + + def __init__(self, *args, **kwargs): + + super(ApiVersionSetContractPaged, self).__init__(*args, **kwargs) +class AuthorizationServerContractPaged(Paged): + """ + A paging container for iterating over a list of :class:`AuthorizationServerContract ` object + """ + + _attribute_map = { + 'next_link': {'key': 'nextLink', 'type': 'str'}, + 'current_page': {'key': 'value', 'type': '[AuthorizationServerContract]'} + } + + def __init__(self, *args, **kwargs): + + super(AuthorizationServerContractPaged, self).__init__(*args, **kwargs) +class BackendContractPaged(Paged): + """ + A paging container for iterating over a list of :class:`BackendContract ` object + """ + + _attribute_map = { + 'next_link': {'key': 'nextLink', 'type': 'str'}, + 'current_page': {'key': 'value', 'type': '[BackendContract]'} + } + + def __init__(self, *args, **kwargs): + + super(BackendContractPaged, self).__init__(*args, **kwargs) +class CacheContractPaged(Paged): + """ + A paging container for iterating over a list of :class:`CacheContract ` object + """ + + _attribute_map = { + 'next_link': {'key': 'nextLink', 'type': 'str'}, + 'current_page': {'key': 'value', 'type': '[CacheContract]'} + } + + def __init__(self, *args, **kwargs): + + super(CacheContractPaged, self).__init__(*args, **kwargs) +class CertificateContractPaged(Paged): + """ + A paging container for iterating over a list of :class:`CertificateContract ` object + """ + + _attribute_map = { + 'next_link': {'key': 'nextLink', 'type': 'str'}, + 'current_page': {'key': 'value', 'type': '[CertificateContract]'} + } + + def __init__(self, *args, **kwargs): + + super(CertificateContractPaged, self).__init__(*args, **kwargs) +class OperationPaged(Paged): + """ + A paging container for iterating over a list of :class:`Operation ` object + """ + + _attribute_map = { + 'next_link': {'key': 'nextLink', 'type': 'str'}, + 'current_page': {'key': 'value', 'type': '[Operation]'} + } + + def __init__(self, *args, **kwargs): + + super(OperationPaged, self).__init__(*args, **kwargs) +class ResourceSkuResultPaged(Paged): + """ + A paging container for iterating over a list of :class:`ResourceSkuResult ` object + """ + + _attribute_map = { + 'next_link': {'key': 'nextLink', 'type': 'str'}, + 'current_page': {'key': 'value', 'type': '[ResourceSkuResult]'} + } + + def __init__(self, *args, **kwargs): + + super(ResourceSkuResultPaged, self).__init__(*args, **kwargs) +class ApiManagementServiceResourcePaged(Paged): + """ + A paging container for iterating over a list of :class:`ApiManagementServiceResource ` object + """ + + _attribute_map = { + 'next_link': {'key': 'nextLink', 'type': 'str'}, + 'current_page': {'key': 'value', 'type': '[ApiManagementServiceResource]'} + } + + def __init__(self, *args, **kwargs): + + super(ApiManagementServiceResourcePaged, self).__init__(*args, **kwargs) +class EmailTemplateContractPaged(Paged): + """ + A paging container for iterating over a list of :class:`EmailTemplateContract ` object + """ + + _attribute_map = { + 'next_link': {'key': 'nextLink', 'type': 'str'}, + 'current_page': {'key': 'value', 'type': '[EmailTemplateContract]'} + } + + def __init__(self, *args, **kwargs): + + super(EmailTemplateContractPaged, self).__init__(*args, **kwargs) +class GroupContractPaged(Paged): + """ + A paging container for iterating over a list of :class:`GroupContract ` object + """ + + _attribute_map = { + 'next_link': {'key': 'nextLink', 'type': 'str'}, + 'current_page': {'key': 'value', 'type': '[GroupContract]'} + } + + def __init__(self, *args, **kwargs): + + super(GroupContractPaged, self).__init__(*args, **kwargs) +class UserContractPaged(Paged): + """ + A paging container for iterating over a list of :class:`UserContract ` object + """ + + _attribute_map = { + 'next_link': {'key': 'nextLink', 'type': 'str'}, + 'current_page': {'key': 'value', 'type': '[UserContract]'} + } + + def __init__(self, *args, **kwargs): + + super(UserContractPaged, self).__init__(*args, **kwargs) +class IdentityProviderContractPaged(Paged): + """ + A paging container for iterating over a list of :class:`IdentityProviderContract ` object + """ + + _attribute_map = { + 'next_link': {'key': 'nextLink', 'type': 'str'}, + 'current_page': {'key': 'value', 'type': '[IdentityProviderContract]'} + } + + def __init__(self, *args, **kwargs): + + super(IdentityProviderContractPaged, self).__init__(*args, **kwargs) +class LoggerContractPaged(Paged): + """ + A paging container for iterating over a list of :class:`LoggerContract ` object + """ + + _attribute_map = { + 'next_link': {'key': 'nextLink', 'type': 'str'}, + 'current_page': {'key': 'value', 'type': '[LoggerContract]'} + } + + def __init__(self, *args, **kwargs): + + super(LoggerContractPaged, self).__init__(*args, **kwargs) +class NotificationContractPaged(Paged): + """ + A paging container for iterating over a list of :class:`NotificationContract ` object + """ + + _attribute_map = { + 'next_link': {'key': 'nextLink', 'type': 'str'}, + 'current_page': {'key': 'value', 'type': '[NotificationContract]'} + } + + def __init__(self, *args, **kwargs): + + super(NotificationContractPaged, self).__init__(*args, **kwargs) +class OpenidConnectProviderContractPaged(Paged): + """ + A paging container for iterating over a list of :class:`OpenidConnectProviderContract ` object + """ + + _attribute_map = { + 'next_link': {'key': 'nextLink', 'type': 'str'}, + 'current_page': {'key': 'value', 'type': '[OpenidConnectProviderContract]'} + } + + def __init__(self, *args, **kwargs): + + super(OpenidConnectProviderContractPaged, self).__init__(*args, **kwargs) +class SubscriptionContractPaged(Paged): + """ + A paging container for iterating over a list of :class:`SubscriptionContract ` object + """ + + _attribute_map = { + 'next_link': {'key': 'nextLink', 'type': 'str'}, + 'current_page': {'key': 'value', 'type': '[SubscriptionContract]'} + } + + def __init__(self, *args, **kwargs): + + super(SubscriptionContractPaged, self).__init__(*args, **kwargs) +class NamedValueContractPaged(Paged): + """ + A paging container for iterating over a list of :class:`NamedValueContract ` object + """ + + _attribute_map = { + 'next_link': {'key': 'nextLink', 'type': 'str'}, + 'current_page': {'key': 'value', 'type': '[NamedValueContract]'} + } + + def __init__(self, *args, **kwargs): + + super(NamedValueContractPaged, self).__init__(*args, **kwargs) +class RegionContractPaged(Paged): + """ + A paging container for iterating over a list of :class:`RegionContract ` object + """ + + _attribute_map = { + 'next_link': {'key': 'nextLink', 'type': 'str'}, + 'current_page': {'key': 'value', 'type': '[RegionContract]'} + } + + def __init__(self, *args, **kwargs): + + super(RegionContractPaged, self).__init__(*args, **kwargs) +class ReportRecordContractPaged(Paged): + """ + A paging container for iterating over a list of :class:`ReportRecordContract ` object + """ + + _attribute_map = { + 'next_link': {'key': 'nextLink', 'type': 'str'}, + 'current_page': {'key': 'value', 'type': '[ReportRecordContract]'} + } + + def __init__(self, *args, **kwargs): + + super(ReportRecordContractPaged, self).__init__(*args, **kwargs) +class RequestReportRecordContractPaged(Paged): + """ + A paging container for iterating over a list of :class:`RequestReportRecordContract ` object + """ + + _attribute_map = { + 'next_link': {'key': 'nextLink', 'type': 'str'}, + 'current_page': {'key': 'value', 'type': '[RequestReportRecordContract]'} + } + + def __init__(self, *args, **kwargs): + + super(RequestReportRecordContractPaged, self).__init__(*args, **kwargs) +class UserIdentityContractPaged(Paged): + """ + A paging container for iterating over a list of :class:`UserIdentityContract ` object + """ + + _attribute_map = { + 'next_link': {'key': 'nextLink', 'type': 'str'}, + 'current_page': {'key': 'value', 'type': '[UserIdentityContract]'} + } + + def __init__(self, *args, **kwargs): + + super(UserIdentityContractPaged, self).__init__(*args, **kwargs) diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/access_information_contract.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/access_information_contract.py deleted file mode 100644 index 702ae821078a..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/access_information_contract.py +++ /dev/null @@ -1,40 +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 AccessInformationContract(Model): - """Tenant access information contract of the API Management service. - - :param id: Identifier. - :type id: str - :param primary_key: Primary access key. - :type primary_key: str - :param secondary_key: Secondary access key. - :type secondary_key: str - :param enabled: Determines whether direct access is enabled. - :type enabled: bool - """ - - _attribute_map = { - 'id': {'key': 'id', 'type': 'str'}, - 'primary_key': {'key': 'primaryKey', 'type': 'str'}, - 'secondary_key': {'key': 'secondaryKey', 'type': 'str'}, - 'enabled': {'key': 'enabled', 'type': 'bool'}, - } - - def __init__(self, **kwargs): - super(AccessInformationContract, self).__init__(**kwargs) - self.id = kwargs.get('id', None) - self.primary_key = kwargs.get('primary_key', None) - self.secondary_key = kwargs.get('secondary_key', None) - self.enabled = kwargs.get('enabled', None) diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/access_information_contract_py3.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/access_information_contract_py3.py deleted file mode 100644 index 6d184b50f02f..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/access_information_contract_py3.py +++ /dev/null @@ -1,40 +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 AccessInformationContract(Model): - """Tenant access information contract of the API Management service. - - :param id: Identifier. - :type id: str - :param primary_key: Primary access key. - :type primary_key: str - :param secondary_key: Secondary access key. - :type secondary_key: str - :param enabled: Determines whether direct access is enabled. - :type enabled: bool - """ - - _attribute_map = { - 'id': {'key': 'id', 'type': 'str'}, - 'primary_key': {'key': 'primaryKey', 'type': 'str'}, - 'secondary_key': {'key': 'secondaryKey', 'type': 'str'}, - 'enabled': {'key': 'enabled', 'type': 'bool'}, - } - - def __init__(self, *, id: str=None, primary_key: str=None, secondary_key: str=None, enabled: bool=None, **kwargs) -> None: - super(AccessInformationContract, self).__init__(**kwargs) - self.id = id - self.primary_key = primary_key - self.secondary_key = secondary_key - self.enabled = enabled diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/access_information_update_parameters.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/access_information_update_parameters.py deleted file mode 100644 index 89d3de07c5ae..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/access_information_update_parameters.py +++ /dev/null @@ -1,28 +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 AccessInformationUpdateParameters(Model): - """Tenant access information update parameters. - - :param enabled: Determines whether direct access is enabled. - :type enabled: bool - """ - - _attribute_map = { - 'enabled': {'key': 'properties.enabled', 'type': 'bool'}, - } - - def __init__(self, **kwargs): - super(AccessInformationUpdateParameters, self).__init__(**kwargs) - self.enabled = kwargs.get('enabled', None) diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/access_information_update_parameters_py3.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/access_information_update_parameters_py3.py deleted file mode 100644 index de481d924392..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/access_information_update_parameters_py3.py +++ /dev/null @@ -1,28 +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 AccessInformationUpdateParameters(Model): - """Tenant access information update parameters. - - :param enabled: Determines whether direct access is enabled. - :type enabled: bool - """ - - _attribute_map = { - 'enabled': {'key': 'properties.enabled', 'type': 'bool'}, - } - - def __init__(self, *, enabled: bool=None, **kwargs) -> None: - super(AccessInformationUpdateParameters, self).__init__(**kwargs) - self.enabled = enabled diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/additional_location.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/additional_location.py deleted file mode 100644 index 430ac1bf55d6..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/additional_location.py +++ /dev/null @@ -1,71 +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 AdditionalLocation(Model): - """Description of an additional API Management resource location. - - Variables are only populated by the server, and will be ignored when - sending a request. - - All required parameters must be populated in order to send to Azure. - - :param location: Required. The location name of the additional region - among Azure Data center regions. - :type location: str - :param sku: Required. SKU properties of the API Management service. - :type sku: - ~azure.mgmt.apimanagement.models.ApiManagementServiceSkuProperties - :ivar public_ip_addresses: Public Static Load Balanced IP addresses of the - API Management service in the additional location. Available only for - Basic, Standard and Premium SKU. - :vartype public_ip_addresses: list[str] - :ivar private_ip_addresses: Private Static Load Balanced IP addresses of - the API Management service which is deployed in an Internal Virtual - Network in a particular additional location. Available only for Basic, - Standard and Premium SKU. - :vartype private_ip_addresses: list[str] - :param virtual_network_configuration: Virtual network configuration for - the location. - :type virtual_network_configuration: - ~azure.mgmt.apimanagement.models.VirtualNetworkConfiguration - :ivar gateway_regional_url: Gateway URL of the API Management service in - the Region. - :vartype gateway_regional_url: str - """ - - _validation = { - 'location': {'required': True}, - 'sku': {'required': True}, - 'public_ip_addresses': {'readonly': True}, - 'private_ip_addresses': {'readonly': True}, - 'gateway_regional_url': {'readonly': True}, - } - - _attribute_map = { - 'location': {'key': 'location', 'type': 'str'}, - 'sku': {'key': 'sku', 'type': 'ApiManagementServiceSkuProperties'}, - 'public_ip_addresses': {'key': 'publicIPAddresses', 'type': '[str]'}, - 'private_ip_addresses': {'key': 'privateIPAddresses', 'type': '[str]'}, - 'virtual_network_configuration': {'key': 'virtualNetworkConfiguration', 'type': 'VirtualNetworkConfiguration'}, - 'gateway_regional_url': {'key': 'gatewayRegionalUrl', 'type': 'str'}, - } - - def __init__(self, **kwargs): - super(AdditionalLocation, self).__init__(**kwargs) - self.location = kwargs.get('location', None) - self.sku = kwargs.get('sku', None) - self.public_ip_addresses = None - self.private_ip_addresses = None - self.virtual_network_configuration = kwargs.get('virtual_network_configuration', None) - self.gateway_regional_url = None diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/additional_location_py3.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/additional_location_py3.py deleted file mode 100644 index 8f03d06fa71c..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/additional_location_py3.py +++ /dev/null @@ -1,71 +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 AdditionalLocation(Model): - """Description of an additional API Management resource location. - - Variables are only populated by the server, and will be ignored when - sending a request. - - All required parameters must be populated in order to send to Azure. - - :param location: Required. The location name of the additional region - among Azure Data center regions. - :type location: str - :param sku: Required. SKU properties of the API Management service. - :type sku: - ~azure.mgmt.apimanagement.models.ApiManagementServiceSkuProperties - :ivar public_ip_addresses: Public Static Load Balanced IP addresses of the - API Management service in the additional location. Available only for - Basic, Standard and Premium SKU. - :vartype public_ip_addresses: list[str] - :ivar private_ip_addresses: Private Static Load Balanced IP addresses of - the API Management service which is deployed in an Internal Virtual - Network in a particular additional location. Available only for Basic, - Standard and Premium SKU. - :vartype private_ip_addresses: list[str] - :param virtual_network_configuration: Virtual network configuration for - the location. - :type virtual_network_configuration: - ~azure.mgmt.apimanagement.models.VirtualNetworkConfiguration - :ivar gateway_regional_url: Gateway URL of the API Management service in - the Region. - :vartype gateway_regional_url: str - """ - - _validation = { - 'location': {'required': True}, - 'sku': {'required': True}, - 'public_ip_addresses': {'readonly': True}, - 'private_ip_addresses': {'readonly': True}, - 'gateway_regional_url': {'readonly': True}, - } - - _attribute_map = { - 'location': {'key': 'location', 'type': 'str'}, - 'sku': {'key': 'sku', 'type': 'ApiManagementServiceSkuProperties'}, - 'public_ip_addresses': {'key': 'publicIPAddresses', 'type': '[str]'}, - 'private_ip_addresses': {'key': 'privateIPAddresses', 'type': '[str]'}, - 'virtual_network_configuration': {'key': 'virtualNetworkConfiguration', 'type': 'VirtualNetworkConfiguration'}, - 'gateway_regional_url': {'key': 'gatewayRegionalUrl', 'type': 'str'}, - } - - def __init__(self, *, location: str, sku, virtual_network_configuration=None, **kwargs) -> None: - super(AdditionalLocation, self).__init__(**kwargs) - self.location = location - self.sku = sku - self.public_ip_addresses = None - self.private_ip_addresses = None - self.virtual_network_configuration = virtual_network_configuration - self.gateway_regional_url = None diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/api_contract.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/api_contract.py deleted file mode 100644 index 8323712967c1..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/api_contract.py +++ /dev/null @@ -1,139 +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 .resource import Resource - - -class ApiContract(Resource): - """Api details. - - Variables are only populated by the server, and will be ignored when - sending a request. - - All required parameters must be populated in order to send to Azure. - - :ivar id: Resource ID. - :vartype id: str - :ivar name: Resource name. - :vartype name: str - :ivar type: Resource type for API Management resource. - :vartype type: str - :param description: Description of the API. May include HTML formatting - tags. - :type description: str - :param authentication_settings: Collection of authentication settings - included into this API. - :type authentication_settings: - ~azure.mgmt.apimanagement.models.AuthenticationSettingsContract - :param subscription_key_parameter_names: Protocols over which API is made - available. - :type subscription_key_parameter_names: - ~azure.mgmt.apimanagement.models.SubscriptionKeyParameterNamesContract - :param api_type: Type of API. Possible values include: 'http', 'soap' - :type api_type: str or ~azure.mgmt.apimanagement.models.ApiType - :param api_revision: Describes the Revision of the Api. If no value is - provided, default revision 1 is created - :type api_revision: str - :param api_version: Indicates the Version identifier of the API if the API - is versioned - :type api_version: str - :param is_current: Indicates if API revision is current api revision. - :type is_current: bool - :ivar is_online: Indicates if API revision is accessible via the gateway. - :vartype is_online: bool - :param api_revision_description: Description of the Api Revision. - :type api_revision_description: str - :param api_version_description: Description of the Api Version. - :type api_version_description: str - :param api_version_set_id: A resource identifier for the related - ApiVersionSet. - :type api_version_set_id: str - :param subscription_required: Specifies whether an API or Product - subscription is required for accessing the API. - :type subscription_required: bool - :param source_api_id: API identifier of the source API. - :type source_api_id: str - :param display_name: API name. Must be 1 to 300 characters long. - :type display_name: str - :param service_url: Absolute URL of the backend service implementing this - API. Cannot be more than 2000 characters long. - :type service_url: str - :param path: Required. Relative URL uniquely identifying this API and all - of its resource paths within the API Management service instance. It is - appended to the API endpoint base URL specified during the service - instance creation to form a public URL for this API. - :type path: str - :param protocols: Describes on which protocols the operations in this API - can be invoked. - :type protocols: list[str or ~azure.mgmt.apimanagement.models.Protocol] - :param api_version_set: Version set details - :type api_version_set: - ~azure.mgmt.apimanagement.models.ApiVersionSetContractDetails - """ - - _validation = { - 'id': {'readonly': True}, - 'name': {'readonly': True}, - 'type': {'readonly': True}, - 'api_revision': {'max_length': 100, 'min_length': 1}, - 'api_version': {'max_length': 100}, - 'is_online': {'readonly': True}, - 'api_revision_description': {'max_length': 256}, - 'api_version_description': {'max_length': 256}, - 'display_name': {'max_length': 300, 'min_length': 1}, - 'service_url': {'max_length': 2000, 'min_length': 0}, - 'path': {'required': True, 'max_length': 400, 'min_length': 0}, - } - - _attribute_map = { - 'id': {'key': 'id', 'type': 'str'}, - 'name': {'key': 'name', 'type': 'str'}, - 'type': {'key': 'type', 'type': 'str'}, - 'description': {'key': 'properties.description', 'type': 'str'}, - 'authentication_settings': {'key': 'properties.authenticationSettings', 'type': 'AuthenticationSettingsContract'}, - 'subscription_key_parameter_names': {'key': 'properties.subscriptionKeyParameterNames', 'type': 'SubscriptionKeyParameterNamesContract'}, - 'api_type': {'key': 'properties.type', 'type': 'str'}, - 'api_revision': {'key': 'properties.apiRevision', 'type': 'str'}, - 'api_version': {'key': 'properties.apiVersion', 'type': 'str'}, - 'is_current': {'key': 'properties.isCurrent', 'type': 'bool'}, - 'is_online': {'key': 'properties.isOnline', 'type': 'bool'}, - 'api_revision_description': {'key': 'properties.apiRevisionDescription', 'type': 'str'}, - 'api_version_description': {'key': 'properties.apiVersionDescription', 'type': 'str'}, - 'api_version_set_id': {'key': 'properties.apiVersionSetId', 'type': 'str'}, - 'subscription_required': {'key': 'properties.subscriptionRequired', 'type': 'bool'}, - 'source_api_id': {'key': 'properties.sourceApiId', 'type': 'str'}, - 'display_name': {'key': 'properties.displayName', 'type': 'str'}, - 'service_url': {'key': 'properties.serviceUrl', 'type': 'str'}, - 'path': {'key': 'properties.path', 'type': 'str'}, - 'protocols': {'key': 'properties.protocols', 'type': '[Protocol]'}, - 'api_version_set': {'key': 'properties.apiVersionSet', 'type': 'ApiVersionSetContractDetails'}, - } - - def __init__(self, **kwargs): - super(ApiContract, self).__init__(**kwargs) - self.description = kwargs.get('description', None) - self.authentication_settings = kwargs.get('authentication_settings', None) - self.subscription_key_parameter_names = kwargs.get('subscription_key_parameter_names', None) - self.api_type = kwargs.get('api_type', None) - self.api_revision = kwargs.get('api_revision', None) - self.api_version = kwargs.get('api_version', None) - self.is_current = kwargs.get('is_current', None) - self.is_online = None - self.api_revision_description = kwargs.get('api_revision_description', None) - self.api_version_description = kwargs.get('api_version_description', None) - self.api_version_set_id = kwargs.get('api_version_set_id', None) - self.subscription_required = kwargs.get('subscription_required', None) - self.source_api_id = kwargs.get('source_api_id', None) - self.display_name = kwargs.get('display_name', None) - self.service_url = kwargs.get('service_url', None) - self.path = kwargs.get('path', None) - self.protocols = kwargs.get('protocols', None) - self.api_version_set = kwargs.get('api_version_set', None) diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/api_contract_paged.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/api_contract_paged.py deleted file mode 100644 index 35e5c717faa9..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/api_contract_paged.py +++ /dev/null @@ -1,27 +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.paging import Paged - - -class ApiContractPaged(Paged): - """ - A paging container for iterating over a list of :class:`ApiContract ` object - """ - - _attribute_map = { - 'next_link': {'key': 'nextLink', 'type': 'str'}, - 'current_page': {'key': 'value', 'type': '[ApiContract]'} - } - - def __init__(self, *args, **kwargs): - - super(ApiContractPaged, self).__init__(*args, **kwargs) diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/api_contract_properties.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/api_contract_properties.py deleted file mode 100644 index eb5407d260bc..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/api_contract_properties.py +++ /dev/null @@ -1,115 +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 .api_entity_base_contract import ApiEntityBaseContract - - -class ApiContractProperties(ApiEntityBaseContract): - """Api Entity Properties. - - Variables are only populated by the server, and will be ignored when - sending a request. - - All required parameters must be populated in order to send to Azure. - - :param description: Description of the API. May include HTML formatting - tags. - :type description: str - :param authentication_settings: Collection of authentication settings - included into this API. - :type authentication_settings: - ~azure.mgmt.apimanagement.models.AuthenticationSettingsContract - :param subscription_key_parameter_names: Protocols over which API is made - available. - :type subscription_key_parameter_names: - ~azure.mgmt.apimanagement.models.SubscriptionKeyParameterNamesContract - :param api_type: Type of API. Possible values include: 'http', 'soap' - :type api_type: str or ~azure.mgmt.apimanagement.models.ApiType - :param api_revision: Describes the Revision of the Api. If no value is - provided, default revision 1 is created - :type api_revision: str - :param api_version: Indicates the Version identifier of the API if the API - is versioned - :type api_version: str - :param is_current: Indicates if API revision is current api revision. - :type is_current: bool - :ivar is_online: Indicates if API revision is accessible via the gateway. - :vartype is_online: bool - :param api_revision_description: Description of the Api Revision. - :type api_revision_description: str - :param api_version_description: Description of the Api Version. - :type api_version_description: str - :param api_version_set_id: A resource identifier for the related - ApiVersionSet. - :type api_version_set_id: str - :param subscription_required: Specifies whether an API or Product - subscription is required for accessing the API. - :type subscription_required: bool - :param source_api_id: API identifier of the source API. - :type source_api_id: str - :param display_name: API name. Must be 1 to 300 characters long. - :type display_name: str - :param service_url: Absolute URL of the backend service implementing this - API. Cannot be more than 2000 characters long. - :type service_url: str - :param path: Required. Relative URL uniquely identifying this API and all - of its resource paths within the API Management service instance. It is - appended to the API endpoint base URL specified during the service - instance creation to form a public URL for this API. - :type path: str - :param protocols: Describes on which protocols the operations in this API - can be invoked. - :type protocols: list[str or ~azure.mgmt.apimanagement.models.Protocol] - :param api_version_set: Version set details - :type api_version_set: - ~azure.mgmt.apimanagement.models.ApiVersionSetContractDetails - """ - - _validation = { - 'api_revision': {'max_length': 100, 'min_length': 1}, - 'api_version': {'max_length': 100}, - 'is_online': {'readonly': True}, - 'api_revision_description': {'max_length': 256}, - 'api_version_description': {'max_length': 256}, - 'display_name': {'max_length': 300, 'min_length': 1}, - 'service_url': {'max_length': 2000, 'min_length': 0}, - 'path': {'required': True, 'max_length': 400, 'min_length': 0}, - } - - _attribute_map = { - 'description': {'key': 'description', 'type': 'str'}, - 'authentication_settings': {'key': 'authenticationSettings', 'type': 'AuthenticationSettingsContract'}, - 'subscription_key_parameter_names': {'key': 'subscriptionKeyParameterNames', 'type': 'SubscriptionKeyParameterNamesContract'}, - 'api_type': {'key': 'type', 'type': 'str'}, - 'api_revision': {'key': 'apiRevision', 'type': 'str'}, - 'api_version': {'key': 'apiVersion', 'type': 'str'}, - 'is_current': {'key': 'isCurrent', 'type': 'bool'}, - 'is_online': {'key': 'isOnline', 'type': 'bool'}, - 'api_revision_description': {'key': 'apiRevisionDescription', 'type': 'str'}, - 'api_version_description': {'key': 'apiVersionDescription', 'type': 'str'}, - 'api_version_set_id': {'key': 'apiVersionSetId', 'type': 'str'}, - 'subscription_required': {'key': 'subscriptionRequired', 'type': 'bool'}, - 'source_api_id': {'key': 'sourceApiId', 'type': 'str'}, - 'display_name': {'key': 'displayName', 'type': 'str'}, - 'service_url': {'key': 'serviceUrl', 'type': 'str'}, - 'path': {'key': 'path', 'type': 'str'}, - 'protocols': {'key': 'protocols', 'type': '[Protocol]'}, - 'api_version_set': {'key': 'apiVersionSet', 'type': 'ApiVersionSetContractDetails'}, - } - - def __init__(self, **kwargs): - super(ApiContractProperties, self).__init__(**kwargs) - self.source_api_id = kwargs.get('source_api_id', None) - self.display_name = kwargs.get('display_name', None) - self.service_url = kwargs.get('service_url', None) - self.path = kwargs.get('path', None) - self.protocols = kwargs.get('protocols', None) - self.api_version_set = kwargs.get('api_version_set', None) diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/api_contract_properties_py3.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/api_contract_properties_py3.py deleted file mode 100644 index 5349453ac542..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/api_contract_properties_py3.py +++ /dev/null @@ -1,115 +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 .api_entity_base_contract_py3 import ApiEntityBaseContract - - -class ApiContractProperties(ApiEntityBaseContract): - """Api Entity Properties. - - Variables are only populated by the server, and will be ignored when - sending a request. - - All required parameters must be populated in order to send to Azure. - - :param description: Description of the API. May include HTML formatting - tags. - :type description: str - :param authentication_settings: Collection of authentication settings - included into this API. - :type authentication_settings: - ~azure.mgmt.apimanagement.models.AuthenticationSettingsContract - :param subscription_key_parameter_names: Protocols over which API is made - available. - :type subscription_key_parameter_names: - ~azure.mgmt.apimanagement.models.SubscriptionKeyParameterNamesContract - :param api_type: Type of API. Possible values include: 'http', 'soap' - :type api_type: str or ~azure.mgmt.apimanagement.models.ApiType - :param api_revision: Describes the Revision of the Api. If no value is - provided, default revision 1 is created - :type api_revision: str - :param api_version: Indicates the Version identifier of the API if the API - is versioned - :type api_version: str - :param is_current: Indicates if API revision is current api revision. - :type is_current: bool - :ivar is_online: Indicates if API revision is accessible via the gateway. - :vartype is_online: bool - :param api_revision_description: Description of the Api Revision. - :type api_revision_description: str - :param api_version_description: Description of the Api Version. - :type api_version_description: str - :param api_version_set_id: A resource identifier for the related - ApiVersionSet. - :type api_version_set_id: str - :param subscription_required: Specifies whether an API or Product - subscription is required for accessing the API. - :type subscription_required: bool - :param source_api_id: API identifier of the source API. - :type source_api_id: str - :param display_name: API name. Must be 1 to 300 characters long. - :type display_name: str - :param service_url: Absolute URL of the backend service implementing this - API. Cannot be more than 2000 characters long. - :type service_url: str - :param path: Required. Relative URL uniquely identifying this API and all - of its resource paths within the API Management service instance. It is - appended to the API endpoint base URL specified during the service - instance creation to form a public URL for this API. - :type path: str - :param protocols: Describes on which protocols the operations in this API - can be invoked. - :type protocols: list[str or ~azure.mgmt.apimanagement.models.Protocol] - :param api_version_set: Version set details - :type api_version_set: - ~azure.mgmt.apimanagement.models.ApiVersionSetContractDetails - """ - - _validation = { - 'api_revision': {'max_length': 100, 'min_length': 1}, - 'api_version': {'max_length': 100}, - 'is_online': {'readonly': True}, - 'api_revision_description': {'max_length': 256}, - 'api_version_description': {'max_length': 256}, - 'display_name': {'max_length': 300, 'min_length': 1}, - 'service_url': {'max_length': 2000, 'min_length': 0}, - 'path': {'required': True, 'max_length': 400, 'min_length': 0}, - } - - _attribute_map = { - 'description': {'key': 'description', 'type': 'str'}, - 'authentication_settings': {'key': 'authenticationSettings', 'type': 'AuthenticationSettingsContract'}, - 'subscription_key_parameter_names': {'key': 'subscriptionKeyParameterNames', 'type': 'SubscriptionKeyParameterNamesContract'}, - 'api_type': {'key': 'type', 'type': 'str'}, - 'api_revision': {'key': 'apiRevision', 'type': 'str'}, - 'api_version': {'key': 'apiVersion', 'type': 'str'}, - 'is_current': {'key': 'isCurrent', 'type': 'bool'}, - 'is_online': {'key': 'isOnline', 'type': 'bool'}, - 'api_revision_description': {'key': 'apiRevisionDescription', 'type': 'str'}, - 'api_version_description': {'key': 'apiVersionDescription', 'type': 'str'}, - 'api_version_set_id': {'key': 'apiVersionSetId', 'type': 'str'}, - 'subscription_required': {'key': 'subscriptionRequired', 'type': 'bool'}, - 'source_api_id': {'key': 'sourceApiId', 'type': 'str'}, - 'display_name': {'key': 'displayName', 'type': 'str'}, - 'service_url': {'key': 'serviceUrl', 'type': 'str'}, - 'path': {'key': 'path', 'type': 'str'}, - 'protocols': {'key': 'protocols', 'type': '[Protocol]'}, - 'api_version_set': {'key': 'apiVersionSet', 'type': 'ApiVersionSetContractDetails'}, - } - - def __init__(self, *, path: str, description: str=None, authentication_settings=None, subscription_key_parameter_names=None, api_type=None, api_revision: str=None, api_version: str=None, is_current: bool=None, api_revision_description: str=None, api_version_description: str=None, api_version_set_id: str=None, subscription_required: bool=None, source_api_id: str=None, display_name: str=None, service_url: str=None, protocols=None, api_version_set=None, **kwargs) -> None: - super(ApiContractProperties, self).__init__(description=description, authentication_settings=authentication_settings, subscription_key_parameter_names=subscription_key_parameter_names, api_type=api_type, api_revision=api_revision, api_version=api_version, is_current=is_current, api_revision_description=api_revision_description, api_version_description=api_version_description, api_version_set_id=api_version_set_id, subscription_required=subscription_required, **kwargs) - self.source_api_id = source_api_id - self.display_name = display_name - self.service_url = service_url - self.path = path - self.protocols = protocols - self.api_version_set = api_version_set diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/api_contract_py3.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/api_contract_py3.py deleted file mode 100644 index 561df1ff8548..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/api_contract_py3.py +++ /dev/null @@ -1,139 +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 .resource_py3 import Resource - - -class ApiContract(Resource): - """Api details. - - Variables are only populated by the server, and will be ignored when - sending a request. - - All required parameters must be populated in order to send to Azure. - - :ivar id: Resource ID. - :vartype id: str - :ivar name: Resource name. - :vartype name: str - :ivar type: Resource type for API Management resource. - :vartype type: str - :param description: Description of the API. May include HTML formatting - tags. - :type description: str - :param authentication_settings: Collection of authentication settings - included into this API. - :type authentication_settings: - ~azure.mgmt.apimanagement.models.AuthenticationSettingsContract - :param subscription_key_parameter_names: Protocols over which API is made - available. - :type subscription_key_parameter_names: - ~azure.mgmt.apimanagement.models.SubscriptionKeyParameterNamesContract - :param api_type: Type of API. Possible values include: 'http', 'soap' - :type api_type: str or ~azure.mgmt.apimanagement.models.ApiType - :param api_revision: Describes the Revision of the Api. If no value is - provided, default revision 1 is created - :type api_revision: str - :param api_version: Indicates the Version identifier of the API if the API - is versioned - :type api_version: str - :param is_current: Indicates if API revision is current api revision. - :type is_current: bool - :ivar is_online: Indicates if API revision is accessible via the gateway. - :vartype is_online: bool - :param api_revision_description: Description of the Api Revision. - :type api_revision_description: str - :param api_version_description: Description of the Api Version. - :type api_version_description: str - :param api_version_set_id: A resource identifier for the related - ApiVersionSet. - :type api_version_set_id: str - :param subscription_required: Specifies whether an API or Product - subscription is required for accessing the API. - :type subscription_required: bool - :param source_api_id: API identifier of the source API. - :type source_api_id: str - :param display_name: API name. Must be 1 to 300 characters long. - :type display_name: str - :param service_url: Absolute URL of the backend service implementing this - API. Cannot be more than 2000 characters long. - :type service_url: str - :param path: Required. Relative URL uniquely identifying this API and all - of its resource paths within the API Management service instance. It is - appended to the API endpoint base URL specified during the service - instance creation to form a public URL for this API. - :type path: str - :param protocols: Describes on which protocols the operations in this API - can be invoked. - :type protocols: list[str or ~azure.mgmt.apimanagement.models.Protocol] - :param api_version_set: Version set details - :type api_version_set: - ~azure.mgmt.apimanagement.models.ApiVersionSetContractDetails - """ - - _validation = { - 'id': {'readonly': True}, - 'name': {'readonly': True}, - 'type': {'readonly': True}, - 'api_revision': {'max_length': 100, 'min_length': 1}, - 'api_version': {'max_length': 100}, - 'is_online': {'readonly': True}, - 'api_revision_description': {'max_length': 256}, - 'api_version_description': {'max_length': 256}, - 'display_name': {'max_length': 300, 'min_length': 1}, - 'service_url': {'max_length': 2000, 'min_length': 0}, - 'path': {'required': True, 'max_length': 400, 'min_length': 0}, - } - - _attribute_map = { - 'id': {'key': 'id', 'type': 'str'}, - 'name': {'key': 'name', 'type': 'str'}, - 'type': {'key': 'type', 'type': 'str'}, - 'description': {'key': 'properties.description', 'type': 'str'}, - 'authentication_settings': {'key': 'properties.authenticationSettings', 'type': 'AuthenticationSettingsContract'}, - 'subscription_key_parameter_names': {'key': 'properties.subscriptionKeyParameterNames', 'type': 'SubscriptionKeyParameterNamesContract'}, - 'api_type': {'key': 'properties.type', 'type': 'str'}, - 'api_revision': {'key': 'properties.apiRevision', 'type': 'str'}, - 'api_version': {'key': 'properties.apiVersion', 'type': 'str'}, - 'is_current': {'key': 'properties.isCurrent', 'type': 'bool'}, - 'is_online': {'key': 'properties.isOnline', 'type': 'bool'}, - 'api_revision_description': {'key': 'properties.apiRevisionDescription', 'type': 'str'}, - 'api_version_description': {'key': 'properties.apiVersionDescription', 'type': 'str'}, - 'api_version_set_id': {'key': 'properties.apiVersionSetId', 'type': 'str'}, - 'subscription_required': {'key': 'properties.subscriptionRequired', 'type': 'bool'}, - 'source_api_id': {'key': 'properties.sourceApiId', 'type': 'str'}, - 'display_name': {'key': 'properties.displayName', 'type': 'str'}, - 'service_url': {'key': 'properties.serviceUrl', 'type': 'str'}, - 'path': {'key': 'properties.path', 'type': 'str'}, - 'protocols': {'key': 'properties.protocols', 'type': '[Protocol]'}, - 'api_version_set': {'key': 'properties.apiVersionSet', 'type': 'ApiVersionSetContractDetails'}, - } - - def __init__(self, *, path: str, description: str=None, authentication_settings=None, subscription_key_parameter_names=None, api_type=None, api_revision: str=None, api_version: str=None, is_current: bool=None, api_revision_description: str=None, api_version_description: str=None, api_version_set_id: str=None, subscription_required: bool=None, source_api_id: str=None, display_name: str=None, service_url: str=None, protocols=None, api_version_set=None, **kwargs) -> None: - super(ApiContract, self).__init__(**kwargs) - self.description = description - self.authentication_settings = authentication_settings - self.subscription_key_parameter_names = subscription_key_parameter_names - self.api_type = api_type - self.api_revision = api_revision - self.api_version = api_version - self.is_current = is_current - self.is_online = None - self.api_revision_description = api_revision_description - self.api_version_description = api_version_description - self.api_version_set_id = api_version_set_id - self.subscription_required = subscription_required - self.source_api_id = source_api_id - self.display_name = display_name - self.service_url = service_url - self.path = path - self.protocols = protocols - self.api_version_set = api_version_set diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/api_create_or_update_parameter.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/api_create_or_update_parameter.py deleted file mode 100644 index bd9f1969a5ab..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/api_create_or_update_parameter.py +++ /dev/null @@ -1,151 +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 ApiCreateOrUpdateParameter(Model): - """API Create or Update Parameters. - - Variables are only populated by the server, and will be ignored when - sending a request. - - All required parameters must be populated in order to send to Azure. - - :param description: Description of the API. May include HTML formatting - tags. - :type description: str - :param authentication_settings: Collection of authentication settings - included into this API. - :type authentication_settings: - ~azure.mgmt.apimanagement.models.AuthenticationSettingsContract - :param subscription_key_parameter_names: Protocols over which API is made - available. - :type subscription_key_parameter_names: - ~azure.mgmt.apimanagement.models.SubscriptionKeyParameterNamesContract - :param api_type: Type of API. Possible values include: 'http', 'soap' - :type api_type: str or ~azure.mgmt.apimanagement.models.ApiType - :param api_revision: Describes the Revision of the Api. If no value is - provided, default revision 1 is created - :type api_revision: str - :param api_version: Indicates the Version identifier of the API if the API - is versioned - :type api_version: str - :param is_current: Indicates if API revision is current api revision. - :type is_current: bool - :ivar is_online: Indicates if API revision is accessible via the gateway. - :vartype is_online: bool - :param api_revision_description: Description of the Api Revision. - :type api_revision_description: str - :param api_version_description: Description of the Api Version. - :type api_version_description: str - :param api_version_set_id: A resource identifier for the related - ApiVersionSet. - :type api_version_set_id: str - :param subscription_required: Specifies whether an API or Product - subscription is required for accessing the API. - :type subscription_required: bool - :param source_api_id: API identifier of the source API. - :type source_api_id: str - :param display_name: API name. Must be 1 to 300 characters long. - :type display_name: str - :param service_url: Absolute URL of the backend service implementing this - API. Cannot be more than 2000 characters long. - :type service_url: str - :param path: Required. Relative URL uniquely identifying this API and all - of its resource paths within the API Management service instance. It is - appended to the API endpoint base URL specified during the service - instance creation to form a public URL for this API. - :type path: str - :param protocols: Describes on which protocols the operations in this API - can be invoked. - :type protocols: list[str or ~azure.mgmt.apimanagement.models.Protocol] - :param api_version_set: Version set details - :type api_version_set: - ~azure.mgmt.apimanagement.models.ApiVersionSetContractDetails - :param value: Content value when Importing an API. - :type value: str - :param format: Format of the Content in which the API is getting imported. - Possible values include: 'wadl-xml', 'wadl-link-json', 'swagger-json', - 'swagger-link-json', 'wsdl', 'wsdl-link', 'openapi', 'openapi+json', - 'openapi-link' - :type format: str or ~azure.mgmt.apimanagement.models.ContentFormat - :param wsdl_selector: Criteria to limit import of WSDL to a subset of the - document. - :type wsdl_selector: - ~azure.mgmt.apimanagement.models.ApiCreateOrUpdatePropertiesWsdlSelector - :param soap_api_type: Type of Api to create. - * `http` creates a SOAP to REST API - * `soap` creates a SOAP pass-through API. Possible values include: - 'SoapToRest', 'SoapPassThrough' - :type soap_api_type: str or ~azure.mgmt.apimanagement.models.SoapApiType - """ - - _validation = { - 'api_revision': {'max_length': 100, 'min_length': 1}, - 'api_version': {'max_length': 100}, - 'is_online': {'readonly': True}, - 'api_revision_description': {'max_length': 256}, - 'api_version_description': {'max_length': 256}, - 'display_name': {'max_length': 300, 'min_length': 1}, - 'service_url': {'max_length': 2000, 'min_length': 0}, - 'path': {'required': True, 'max_length': 400, 'min_length': 0}, - } - - _attribute_map = { - 'description': {'key': 'properties.description', 'type': 'str'}, - 'authentication_settings': {'key': 'properties.authenticationSettings', 'type': 'AuthenticationSettingsContract'}, - 'subscription_key_parameter_names': {'key': 'properties.subscriptionKeyParameterNames', 'type': 'SubscriptionKeyParameterNamesContract'}, - 'api_type': {'key': 'properties.type', 'type': 'str'}, - 'api_revision': {'key': 'properties.apiRevision', 'type': 'str'}, - 'api_version': {'key': 'properties.apiVersion', 'type': 'str'}, - 'is_current': {'key': 'properties.isCurrent', 'type': 'bool'}, - 'is_online': {'key': 'properties.isOnline', 'type': 'bool'}, - 'api_revision_description': {'key': 'properties.apiRevisionDescription', 'type': 'str'}, - 'api_version_description': {'key': 'properties.apiVersionDescription', 'type': 'str'}, - 'api_version_set_id': {'key': 'properties.apiVersionSetId', 'type': 'str'}, - 'subscription_required': {'key': 'properties.subscriptionRequired', 'type': 'bool'}, - 'source_api_id': {'key': 'properties.sourceApiId', 'type': 'str'}, - 'display_name': {'key': 'properties.displayName', 'type': 'str'}, - 'service_url': {'key': 'properties.serviceUrl', 'type': 'str'}, - 'path': {'key': 'properties.path', 'type': 'str'}, - 'protocols': {'key': 'properties.protocols', 'type': '[Protocol]'}, - 'api_version_set': {'key': 'properties.apiVersionSet', 'type': 'ApiVersionSetContractDetails'}, - 'value': {'key': 'properties.value', 'type': 'str'}, - 'format': {'key': 'properties.format', 'type': 'str'}, - 'wsdl_selector': {'key': 'properties.wsdlSelector', 'type': 'ApiCreateOrUpdatePropertiesWsdlSelector'}, - 'soap_api_type': {'key': 'properties.apiType', 'type': 'str'}, - } - - def __init__(self, **kwargs): - super(ApiCreateOrUpdateParameter, self).__init__(**kwargs) - self.description = kwargs.get('description', None) - self.authentication_settings = kwargs.get('authentication_settings', None) - self.subscription_key_parameter_names = kwargs.get('subscription_key_parameter_names', None) - self.api_type = kwargs.get('api_type', None) - self.api_revision = kwargs.get('api_revision', None) - self.api_version = kwargs.get('api_version', None) - self.is_current = kwargs.get('is_current', None) - self.is_online = None - self.api_revision_description = kwargs.get('api_revision_description', None) - self.api_version_description = kwargs.get('api_version_description', None) - self.api_version_set_id = kwargs.get('api_version_set_id', None) - self.subscription_required = kwargs.get('subscription_required', None) - self.source_api_id = kwargs.get('source_api_id', None) - self.display_name = kwargs.get('display_name', None) - self.service_url = kwargs.get('service_url', None) - self.path = kwargs.get('path', None) - self.protocols = kwargs.get('protocols', None) - self.api_version_set = kwargs.get('api_version_set', None) - self.value = kwargs.get('value', None) - self.format = kwargs.get('format', None) - self.wsdl_selector = kwargs.get('wsdl_selector', None) - self.soap_api_type = kwargs.get('soap_api_type', None) diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/api_create_or_update_parameter_py3.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/api_create_or_update_parameter_py3.py deleted file mode 100644 index a9a326b69906..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/api_create_or_update_parameter_py3.py +++ /dev/null @@ -1,151 +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 ApiCreateOrUpdateParameter(Model): - """API Create or Update Parameters. - - Variables are only populated by the server, and will be ignored when - sending a request. - - All required parameters must be populated in order to send to Azure. - - :param description: Description of the API. May include HTML formatting - tags. - :type description: str - :param authentication_settings: Collection of authentication settings - included into this API. - :type authentication_settings: - ~azure.mgmt.apimanagement.models.AuthenticationSettingsContract - :param subscription_key_parameter_names: Protocols over which API is made - available. - :type subscription_key_parameter_names: - ~azure.mgmt.apimanagement.models.SubscriptionKeyParameterNamesContract - :param api_type: Type of API. Possible values include: 'http', 'soap' - :type api_type: str or ~azure.mgmt.apimanagement.models.ApiType - :param api_revision: Describes the Revision of the Api. If no value is - provided, default revision 1 is created - :type api_revision: str - :param api_version: Indicates the Version identifier of the API if the API - is versioned - :type api_version: str - :param is_current: Indicates if API revision is current api revision. - :type is_current: bool - :ivar is_online: Indicates if API revision is accessible via the gateway. - :vartype is_online: bool - :param api_revision_description: Description of the Api Revision. - :type api_revision_description: str - :param api_version_description: Description of the Api Version. - :type api_version_description: str - :param api_version_set_id: A resource identifier for the related - ApiVersionSet. - :type api_version_set_id: str - :param subscription_required: Specifies whether an API or Product - subscription is required for accessing the API. - :type subscription_required: bool - :param source_api_id: API identifier of the source API. - :type source_api_id: str - :param display_name: API name. Must be 1 to 300 characters long. - :type display_name: str - :param service_url: Absolute URL of the backend service implementing this - API. Cannot be more than 2000 characters long. - :type service_url: str - :param path: Required. Relative URL uniquely identifying this API and all - of its resource paths within the API Management service instance. It is - appended to the API endpoint base URL specified during the service - instance creation to form a public URL for this API. - :type path: str - :param protocols: Describes on which protocols the operations in this API - can be invoked. - :type protocols: list[str or ~azure.mgmt.apimanagement.models.Protocol] - :param api_version_set: Version set details - :type api_version_set: - ~azure.mgmt.apimanagement.models.ApiVersionSetContractDetails - :param value: Content value when Importing an API. - :type value: str - :param format: Format of the Content in which the API is getting imported. - Possible values include: 'wadl-xml', 'wadl-link-json', 'swagger-json', - 'swagger-link-json', 'wsdl', 'wsdl-link', 'openapi', 'openapi+json', - 'openapi-link' - :type format: str or ~azure.mgmt.apimanagement.models.ContentFormat - :param wsdl_selector: Criteria to limit import of WSDL to a subset of the - document. - :type wsdl_selector: - ~azure.mgmt.apimanagement.models.ApiCreateOrUpdatePropertiesWsdlSelector - :param soap_api_type: Type of Api to create. - * `http` creates a SOAP to REST API - * `soap` creates a SOAP pass-through API. Possible values include: - 'SoapToRest', 'SoapPassThrough' - :type soap_api_type: str or ~azure.mgmt.apimanagement.models.SoapApiType - """ - - _validation = { - 'api_revision': {'max_length': 100, 'min_length': 1}, - 'api_version': {'max_length': 100}, - 'is_online': {'readonly': True}, - 'api_revision_description': {'max_length': 256}, - 'api_version_description': {'max_length': 256}, - 'display_name': {'max_length': 300, 'min_length': 1}, - 'service_url': {'max_length': 2000, 'min_length': 0}, - 'path': {'required': True, 'max_length': 400, 'min_length': 0}, - } - - _attribute_map = { - 'description': {'key': 'properties.description', 'type': 'str'}, - 'authentication_settings': {'key': 'properties.authenticationSettings', 'type': 'AuthenticationSettingsContract'}, - 'subscription_key_parameter_names': {'key': 'properties.subscriptionKeyParameterNames', 'type': 'SubscriptionKeyParameterNamesContract'}, - 'api_type': {'key': 'properties.type', 'type': 'str'}, - 'api_revision': {'key': 'properties.apiRevision', 'type': 'str'}, - 'api_version': {'key': 'properties.apiVersion', 'type': 'str'}, - 'is_current': {'key': 'properties.isCurrent', 'type': 'bool'}, - 'is_online': {'key': 'properties.isOnline', 'type': 'bool'}, - 'api_revision_description': {'key': 'properties.apiRevisionDescription', 'type': 'str'}, - 'api_version_description': {'key': 'properties.apiVersionDescription', 'type': 'str'}, - 'api_version_set_id': {'key': 'properties.apiVersionSetId', 'type': 'str'}, - 'subscription_required': {'key': 'properties.subscriptionRequired', 'type': 'bool'}, - 'source_api_id': {'key': 'properties.sourceApiId', 'type': 'str'}, - 'display_name': {'key': 'properties.displayName', 'type': 'str'}, - 'service_url': {'key': 'properties.serviceUrl', 'type': 'str'}, - 'path': {'key': 'properties.path', 'type': 'str'}, - 'protocols': {'key': 'properties.protocols', 'type': '[Protocol]'}, - 'api_version_set': {'key': 'properties.apiVersionSet', 'type': 'ApiVersionSetContractDetails'}, - 'value': {'key': 'properties.value', 'type': 'str'}, - 'format': {'key': 'properties.format', 'type': 'str'}, - 'wsdl_selector': {'key': 'properties.wsdlSelector', 'type': 'ApiCreateOrUpdatePropertiesWsdlSelector'}, - 'soap_api_type': {'key': 'properties.apiType', 'type': 'str'}, - } - - def __init__(self, *, path: str, description: str=None, authentication_settings=None, subscription_key_parameter_names=None, api_type=None, api_revision: str=None, api_version: str=None, is_current: bool=None, api_revision_description: str=None, api_version_description: str=None, api_version_set_id: str=None, subscription_required: bool=None, source_api_id: str=None, display_name: str=None, service_url: str=None, protocols=None, api_version_set=None, value: str=None, format=None, wsdl_selector=None, soap_api_type=None, **kwargs) -> None: - super(ApiCreateOrUpdateParameter, self).__init__(**kwargs) - self.description = description - self.authentication_settings = authentication_settings - self.subscription_key_parameter_names = subscription_key_parameter_names - self.api_type = api_type - self.api_revision = api_revision - self.api_version = api_version - self.is_current = is_current - self.is_online = None - self.api_revision_description = api_revision_description - self.api_version_description = api_version_description - self.api_version_set_id = api_version_set_id - self.subscription_required = subscription_required - self.source_api_id = source_api_id - self.display_name = display_name - self.service_url = service_url - self.path = path - self.protocols = protocols - self.api_version_set = api_version_set - self.value = value - self.format = format - self.wsdl_selector = wsdl_selector - self.soap_api_type = soap_api_type diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/api_create_or_update_properties_wsdl_selector.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/api_create_or_update_properties_wsdl_selector.py deleted file mode 100644 index f94026f29f08..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/api_create_or_update_properties_wsdl_selector.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 ApiCreateOrUpdatePropertiesWsdlSelector(Model): - """Criteria to limit import of WSDL to a subset of the document. - - :param wsdl_service_name: Name of service to import from WSDL - :type wsdl_service_name: str - :param wsdl_endpoint_name: Name of endpoint(port) to import from WSDL - :type wsdl_endpoint_name: str - """ - - _attribute_map = { - 'wsdl_service_name': {'key': 'wsdlServiceName', 'type': 'str'}, - 'wsdl_endpoint_name': {'key': 'wsdlEndpointName', 'type': 'str'}, - } - - def __init__(self, **kwargs): - super(ApiCreateOrUpdatePropertiesWsdlSelector, self).__init__(**kwargs) - self.wsdl_service_name = kwargs.get('wsdl_service_name', None) - self.wsdl_endpoint_name = kwargs.get('wsdl_endpoint_name', None) diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/api_create_or_update_properties_wsdl_selector_py3.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/api_create_or_update_properties_wsdl_selector_py3.py deleted file mode 100644 index cd7249f0e0ba..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/api_create_or_update_properties_wsdl_selector_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 ApiCreateOrUpdatePropertiesWsdlSelector(Model): - """Criteria to limit import of WSDL to a subset of the document. - - :param wsdl_service_name: Name of service to import from WSDL - :type wsdl_service_name: str - :param wsdl_endpoint_name: Name of endpoint(port) to import from WSDL - :type wsdl_endpoint_name: str - """ - - _attribute_map = { - 'wsdl_service_name': {'key': 'wsdlServiceName', 'type': 'str'}, - 'wsdl_endpoint_name': {'key': 'wsdlEndpointName', 'type': 'str'}, - } - - def __init__(self, *, wsdl_service_name: str=None, wsdl_endpoint_name: str=None, **kwargs) -> None: - super(ApiCreateOrUpdatePropertiesWsdlSelector, self).__init__(**kwargs) - self.wsdl_service_name = wsdl_service_name - self.wsdl_endpoint_name = wsdl_endpoint_name diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/api_entity_base_contract.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/api_entity_base_contract.py deleted file mode 100644 index 502a877256df..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/api_entity_base_contract.py +++ /dev/null @@ -1,92 +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 ApiEntityBaseContract(Model): - """API base contract details. - - Variables are only populated by the server, and will be ignored when - sending a request. - - :param description: Description of the API. May include HTML formatting - tags. - :type description: str - :param authentication_settings: Collection of authentication settings - included into this API. - :type authentication_settings: - ~azure.mgmt.apimanagement.models.AuthenticationSettingsContract - :param subscription_key_parameter_names: Protocols over which API is made - available. - :type subscription_key_parameter_names: - ~azure.mgmt.apimanagement.models.SubscriptionKeyParameterNamesContract - :param api_type: Type of API. Possible values include: 'http', 'soap' - :type api_type: str or ~azure.mgmt.apimanagement.models.ApiType - :param api_revision: Describes the Revision of the Api. If no value is - provided, default revision 1 is created - :type api_revision: str - :param api_version: Indicates the Version identifier of the API if the API - is versioned - :type api_version: str - :param is_current: Indicates if API revision is current api revision. - :type is_current: bool - :ivar is_online: Indicates if API revision is accessible via the gateway. - :vartype is_online: bool - :param api_revision_description: Description of the Api Revision. - :type api_revision_description: str - :param api_version_description: Description of the Api Version. - :type api_version_description: str - :param api_version_set_id: A resource identifier for the related - ApiVersionSet. - :type api_version_set_id: str - :param subscription_required: Specifies whether an API or Product - subscription is required for accessing the API. - :type subscription_required: bool - """ - - _validation = { - 'api_revision': {'max_length': 100, 'min_length': 1}, - 'api_version': {'max_length': 100}, - 'is_online': {'readonly': True}, - 'api_revision_description': {'max_length': 256}, - 'api_version_description': {'max_length': 256}, - } - - _attribute_map = { - 'description': {'key': 'description', 'type': 'str'}, - 'authentication_settings': {'key': 'authenticationSettings', 'type': 'AuthenticationSettingsContract'}, - 'subscription_key_parameter_names': {'key': 'subscriptionKeyParameterNames', 'type': 'SubscriptionKeyParameterNamesContract'}, - 'api_type': {'key': 'type', 'type': 'str'}, - 'api_revision': {'key': 'apiRevision', 'type': 'str'}, - 'api_version': {'key': 'apiVersion', 'type': 'str'}, - 'is_current': {'key': 'isCurrent', 'type': 'bool'}, - 'is_online': {'key': 'isOnline', 'type': 'bool'}, - 'api_revision_description': {'key': 'apiRevisionDescription', 'type': 'str'}, - 'api_version_description': {'key': 'apiVersionDescription', 'type': 'str'}, - 'api_version_set_id': {'key': 'apiVersionSetId', 'type': 'str'}, - 'subscription_required': {'key': 'subscriptionRequired', 'type': 'bool'}, - } - - def __init__(self, **kwargs): - super(ApiEntityBaseContract, self).__init__(**kwargs) - self.description = kwargs.get('description', None) - self.authentication_settings = kwargs.get('authentication_settings', None) - self.subscription_key_parameter_names = kwargs.get('subscription_key_parameter_names', None) - self.api_type = kwargs.get('api_type', None) - self.api_revision = kwargs.get('api_revision', None) - self.api_version = kwargs.get('api_version', None) - self.is_current = kwargs.get('is_current', None) - self.is_online = None - self.api_revision_description = kwargs.get('api_revision_description', None) - self.api_version_description = kwargs.get('api_version_description', None) - self.api_version_set_id = kwargs.get('api_version_set_id', None) - self.subscription_required = kwargs.get('subscription_required', None) diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/api_entity_base_contract_py3.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/api_entity_base_contract_py3.py deleted file mode 100644 index d64875b6de90..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/api_entity_base_contract_py3.py +++ /dev/null @@ -1,92 +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 ApiEntityBaseContract(Model): - """API base contract details. - - Variables are only populated by the server, and will be ignored when - sending a request. - - :param description: Description of the API. May include HTML formatting - tags. - :type description: str - :param authentication_settings: Collection of authentication settings - included into this API. - :type authentication_settings: - ~azure.mgmt.apimanagement.models.AuthenticationSettingsContract - :param subscription_key_parameter_names: Protocols over which API is made - available. - :type subscription_key_parameter_names: - ~azure.mgmt.apimanagement.models.SubscriptionKeyParameterNamesContract - :param api_type: Type of API. Possible values include: 'http', 'soap' - :type api_type: str or ~azure.mgmt.apimanagement.models.ApiType - :param api_revision: Describes the Revision of the Api. If no value is - provided, default revision 1 is created - :type api_revision: str - :param api_version: Indicates the Version identifier of the API if the API - is versioned - :type api_version: str - :param is_current: Indicates if API revision is current api revision. - :type is_current: bool - :ivar is_online: Indicates if API revision is accessible via the gateway. - :vartype is_online: bool - :param api_revision_description: Description of the Api Revision. - :type api_revision_description: str - :param api_version_description: Description of the Api Version. - :type api_version_description: str - :param api_version_set_id: A resource identifier for the related - ApiVersionSet. - :type api_version_set_id: str - :param subscription_required: Specifies whether an API or Product - subscription is required for accessing the API. - :type subscription_required: bool - """ - - _validation = { - 'api_revision': {'max_length': 100, 'min_length': 1}, - 'api_version': {'max_length': 100}, - 'is_online': {'readonly': True}, - 'api_revision_description': {'max_length': 256}, - 'api_version_description': {'max_length': 256}, - } - - _attribute_map = { - 'description': {'key': 'description', 'type': 'str'}, - 'authentication_settings': {'key': 'authenticationSettings', 'type': 'AuthenticationSettingsContract'}, - 'subscription_key_parameter_names': {'key': 'subscriptionKeyParameterNames', 'type': 'SubscriptionKeyParameterNamesContract'}, - 'api_type': {'key': 'type', 'type': 'str'}, - 'api_revision': {'key': 'apiRevision', 'type': 'str'}, - 'api_version': {'key': 'apiVersion', 'type': 'str'}, - 'is_current': {'key': 'isCurrent', 'type': 'bool'}, - 'is_online': {'key': 'isOnline', 'type': 'bool'}, - 'api_revision_description': {'key': 'apiRevisionDescription', 'type': 'str'}, - 'api_version_description': {'key': 'apiVersionDescription', 'type': 'str'}, - 'api_version_set_id': {'key': 'apiVersionSetId', 'type': 'str'}, - 'subscription_required': {'key': 'subscriptionRequired', 'type': 'bool'}, - } - - def __init__(self, *, description: str=None, authentication_settings=None, subscription_key_parameter_names=None, api_type=None, api_revision: str=None, api_version: str=None, is_current: bool=None, api_revision_description: str=None, api_version_description: str=None, api_version_set_id: str=None, subscription_required: bool=None, **kwargs) -> None: - super(ApiEntityBaseContract, self).__init__(**kwargs) - self.description = description - self.authentication_settings = authentication_settings - self.subscription_key_parameter_names = subscription_key_parameter_names - self.api_type = api_type - self.api_revision = api_revision - self.api_version = api_version - self.is_current = is_current - self.is_online = None - self.api_revision_description = api_revision_description - self.api_version_description = api_version_description - self.api_version_set_id = api_version_set_id - self.subscription_required = subscription_required diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/api_export_result.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/api_export_result.py deleted file mode 100644 index 46f85d9a27af..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/api_export_result.py +++ /dev/null @@ -1,39 +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 ApiExportResult(Model): - """API Export result. - - :param id: ResourceId of the API which was exported. - :type id: str - :param export_result_format: Format in which the Api Details are exported - to the Storage Blob with Sas Key valid for 5 minutes. Possible values - include: 'Swagger', 'Wsdl', 'Wadl', 'OpenApi' - :type export_result_format: str or - ~azure.mgmt.apimanagement.models.ExportResultFormat - :param value: The object defining the schema of the exported Api Detail - :type value: ~azure.mgmt.apimanagement.models.ApiExportResultValue - """ - - _attribute_map = { - 'id': {'key': 'id', 'type': 'str'}, - 'export_result_format': {'key': 'format', 'type': 'str'}, - 'value': {'key': 'value', 'type': 'ApiExportResultValue'}, - } - - def __init__(self, **kwargs): - super(ApiExportResult, self).__init__(**kwargs) - self.id = kwargs.get('id', None) - self.export_result_format = kwargs.get('export_result_format', None) - self.value = kwargs.get('value', None) diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/api_export_result_py3.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/api_export_result_py3.py deleted file mode 100644 index ac710fddacbd..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/api_export_result_py3.py +++ /dev/null @@ -1,39 +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 ApiExportResult(Model): - """API Export result. - - :param id: ResourceId of the API which was exported. - :type id: str - :param export_result_format: Format in which the Api Details are exported - to the Storage Blob with Sas Key valid for 5 minutes. Possible values - include: 'Swagger', 'Wsdl', 'Wadl', 'OpenApi' - :type export_result_format: str or - ~azure.mgmt.apimanagement.models.ExportResultFormat - :param value: The object defining the schema of the exported Api Detail - :type value: ~azure.mgmt.apimanagement.models.ApiExportResultValue - """ - - _attribute_map = { - 'id': {'key': 'id', 'type': 'str'}, - 'export_result_format': {'key': 'format', 'type': 'str'}, - 'value': {'key': 'value', 'type': 'ApiExportResultValue'}, - } - - def __init__(self, *, id: str=None, export_result_format=None, value=None, **kwargs) -> None: - super(ApiExportResult, self).__init__(**kwargs) - self.id = id - self.export_result_format = export_result_format - self.value = value diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/api_export_result_value.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/api_export_result_value.py deleted file mode 100644 index e0554a63b849..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/api_export_result_value.py +++ /dev/null @@ -1,29 +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 ApiExportResultValue(Model): - """The object defining the schema of the exported Api Detail. - - :param link: Link to the Storage Blob containing the result of the export - operation. The Blob Uri is only valid for 5 minutes. - :type link: str - """ - - _attribute_map = { - 'link': {'key': 'link', 'type': 'str'}, - } - - def __init__(self, **kwargs): - super(ApiExportResultValue, self).__init__(**kwargs) - self.link = kwargs.get('link', None) diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/api_export_result_value_py3.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/api_export_result_value_py3.py deleted file mode 100644 index 521bd611cb33..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/api_export_result_value_py3.py +++ /dev/null @@ -1,29 +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 ApiExportResultValue(Model): - """The object defining the schema of the exported Api Detail. - - :param link: Link to the Storage Blob containing the result of the export - operation. The Blob Uri is only valid for 5 minutes. - :type link: str - """ - - _attribute_map = { - 'link': {'key': 'link', 'type': 'str'}, - } - - def __init__(self, *, link: str=None, **kwargs) -> None: - super(ApiExportResultValue, self).__init__(**kwargs) - self.link = link diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/api_management_service_apply_network_configuration_parameters.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/api_management_service_apply_network_configuration_parameters.py deleted file mode 100644 index 7de08f790795..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/api_management_service_apply_network_configuration_parameters.py +++ /dev/null @@ -1,30 +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 ApiManagementServiceApplyNetworkConfigurationParameters(Model): - """Parameter supplied to the Apply Network configuration operation. - - :param location: Location of the Api Management service to update for a - multi-region service. For a service deployed in a single region, this - parameter is not required. - :type location: str - """ - - _attribute_map = { - 'location': {'key': 'location', 'type': 'str'}, - } - - def __init__(self, **kwargs): - super(ApiManagementServiceApplyNetworkConfigurationParameters, self).__init__(**kwargs) - self.location = kwargs.get('location', None) diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/api_management_service_apply_network_configuration_parameters_py3.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/api_management_service_apply_network_configuration_parameters_py3.py deleted file mode 100644 index 315f5e2859ca..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/api_management_service_apply_network_configuration_parameters_py3.py +++ /dev/null @@ -1,30 +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 ApiManagementServiceApplyNetworkConfigurationParameters(Model): - """Parameter supplied to the Apply Network configuration operation. - - :param location: Location of the Api Management service to update for a - multi-region service. For a service deployed in a single region, this - parameter is not required. - :type location: str - """ - - _attribute_map = { - 'location': {'key': 'location', 'type': 'str'}, - } - - def __init__(self, *, location: str=None, **kwargs) -> None: - super(ApiManagementServiceApplyNetworkConfigurationParameters, self).__init__(**kwargs) - self.location = location diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/api_management_service_backup_restore_parameters.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/api_management_service_backup_restore_parameters.py deleted file mode 100644 index 9cde1269f3f7..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/api_management_service_backup_restore_parameters.py +++ /dev/null @@ -1,53 +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 ApiManagementServiceBackupRestoreParameters(Model): - """Parameters supplied to the Backup/Restore of an API Management service - operation. - - All required parameters must be populated in order to send to Azure. - - :param storage_account: Required. Azure Cloud Storage account (used to - place/retrieve the backup) name. - :type storage_account: str - :param access_key: Required. Azure Cloud Storage account (used to - place/retrieve the backup) access key. - :type access_key: str - :param container_name: Required. Azure Cloud Storage blob container name - used to place/retrieve the backup. - :type container_name: str - :param backup_name: Required. The name of the backup file to create. - :type backup_name: str - """ - - _validation = { - 'storage_account': {'required': True}, - 'access_key': {'required': True}, - 'container_name': {'required': True}, - 'backup_name': {'required': True}, - } - - _attribute_map = { - 'storage_account': {'key': 'storageAccount', 'type': 'str'}, - 'access_key': {'key': 'accessKey', 'type': 'str'}, - 'container_name': {'key': 'containerName', 'type': 'str'}, - 'backup_name': {'key': 'backupName', 'type': 'str'}, - } - - def __init__(self, **kwargs): - super(ApiManagementServiceBackupRestoreParameters, self).__init__(**kwargs) - self.storage_account = kwargs.get('storage_account', None) - self.access_key = kwargs.get('access_key', None) - self.container_name = kwargs.get('container_name', None) - self.backup_name = kwargs.get('backup_name', None) diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/api_management_service_backup_restore_parameters_py3.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/api_management_service_backup_restore_parameters_py3.py deleted file mode 100644 index e6cba95e6129..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/api_management_service_backup_restore_parameters_py3.py +++ /dev/null @@ -1,53 +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 ApiManagementServiceBackupRestoreParameters(Model): - """Parameters supplied to the Backup/Restore of an API Management service - operation. - - All required parameters must be populated in order to send to Azure. - - :param storage_account: Required. Azure Cloud Storage account (used to - place/retrieve the backup) name. - :type storage_account: str - :param access_key: Required. Azure Cloud Storage account (used to - place/retrieve the backup) access key. - :type access_key: str - :param container_name: Required. Azure Cloud Storage blob container name - used to place/retrieve the backup. - :type container_name: str - :param backup_name: Required. The name of the backup file to create. - :type backup_name: str - """ - - _validation = { - 'storage_account': {'required': True}, - 'access_key': {'required': True}, - 'container_name': {'required': True}, - 'backup_name': {'required': True}, - } - - _attribute_map = { - 'storage_account': {'key': 'storageAccount', 'type': 'str'}, - 'access_key': {'key': 'accessKey', 'type': 'str'}, - 'container_name': {'key': 'containerName', 'type': 'str'}, - 'backup_name': {'key': 'backupName', 'type': 'str'}, - } - - def __init__(self, *, storage_account: str, access_key: str, container_name: str, backup_name: str, **kwargs) -> None: - super(ApiManagementServiceBackupRestoreParameters, self).__init__(**kwargs) - self.storage_account = storage_account - self.access_key = access_key - self.container_name = container_name - self.backup_name = backup_name diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/api_management_service_base_properties.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/api_management_service_base_properties.py deleted file mode 100644 index 7cf72fd0ab20..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/api_management_service_base_properties.py +++ /dev/null @@ -1,157 +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 ApiManagementServiceBaseProperties(Model): - """Base Properties of an API Management service resource description. - - Variables are only populated by the server, and will be ignored when - sending a request. - - :param notification_sender_email: Email address from which the - notification will be sent. - :type notification_sender_email: str - :ivar provisioning_state: The current provisioning state of the API - Management service which can be one of the following: - Created/Activating/Succeeded/Updating/Failed/Stopped/Terminating/TerminationFailed/Deleted. - :vartype provisioning_state: str - :ivar target_provisioning_state: The provisioning state of the API - Management service, which is targeted by the long running operation - started on the service. - :vartype target_provisioning_state: str - :ivar created_at_utc: Creation UTC date of the API Management service.The - date conforms to the following format: `yyyy-MM-ddTHH:mm:ssZ` as specified - by the ISO 8601 standard. - :vartype created_at_utc: datetime - :ivar gateway_url: Gateway URL of the API Management service. - :vartype gateway_url: str - :ivar gateway_regional_url: Gateway URL of the API Management service in - the Default Region. - :vartype gateway_regional_url: str - :ivar portal_url: Publisher portal endpoint Url of the API Management - service. - :vartype portal_url: str - :ivar management_api_url: Management API endpoint URL of the API - Management service. - :vartype management_api_url: str - :ivar scm_url: SCM endpoint URL of the API Management service. - :vartype scm_url: str - :param hostname_configurations: Custom hostname configuration of the API - Management service. - :type hostname_configurations: - list[~azure.mgmt.apimanagement.models.HostnameConfiguration] - :ivar public_ip_addresses: Public Static Load Balanced IP addresses of the - API Management service in Primary region. Available only for Basic, - Standard and Premium SKU. - :vartype public_ip_addresses: list[str] - :ivar private_ip_addresses: Private Static Load Balanced IP addresses of - the API Management service in Primary region which is deployed in an - Internal Virtual Network. Available only for Basic, Standard and Premium - SKU. - :vartype private_ip_addresses: list[str] - :param virtual_network_configuration: Virtual network configuration of the - API Management service. - :type virtual_network_configuration: - ~azure.mgmt.apimanagement.models.VirtualNetworkConfiguration - :param additional_locations: Additional datacenter locations of the API - Management service. - :type additional_locations: - list[~azure.mgmt.apimanagement.models.AdditionalLocation] - :param custom_properties: Custom properties of the API Management service. - Setting - `Microsoft.WindowsAzure.ApiManagement.Gateway.Security.Ciphers.TripleDes168` - will disable the cipher TLS_RSA_WITH_3DES_EDE_CBC_SHA for all TLS(1.0, 1.1 - and 1.2). Setting - `Microsoft.WindowsAzure.ApiManagement.Gateway.Security.Protocols.Tls11` - can be used to disable just TLS 1.1 and setting - `Microsoft.WindowsAzure.ApiManagement.Gateway.Security.Protocols.Tls10` - can be used to disable TLS 1.0 on an API Management service. - :type custom_properties: dict[str, str] - :param certificates: List of Certificates that need to be installed in the - API Management service. Max supported certificates that can be installed - is 10. - :type certificates: - list[~azure.mgmt.apimanagement.models.CertificateConfiguration] - :param enable_client_certificate: Property only meant to be used for - Consumption SKU Service. This enforces a client certificate to be - presented on each request to the gateway. This also enables the ability to - authenticate the certificate in the policy on the gateway. Default value: - False . - :type enable_client_certificate: bool - :param virtual_network_type: The type of VPN in which API Management - service needs to be configured in. None (Default Value) means the API - Management service is not part of any Virtual Network, External means the - API Management deployment is set up inside a Virtual Network having an - Internet Facing Endpoint, and Internal means that API Management - deployment is setup inside a Virtual Network having an Intranet Facing - Endpoint only. Possible values include: 'None', 'External', 'Internal'. - Default value: "None" . - :type virtual_network_type: str or - ~azure.mgmt.apimanagement.models.VirtualNetworkType - """ - - _validation = { - 'notification_sender_email': {'max_length': 100}, - 'provisioning_state': {'readonly': True}, - 'target_provisioning_state': {'readonly': True}, - 'created_at_utc': {'readonly': True}, - 'gateway_url': {'readonly': True}, - 'gateway_regional_url': {'readonly': True}, - 'portal_url': {'readonly': True}, - 'management_api_url': {'readonly': True}, - 'scm_url': {'readonly': True}, - 'public_ip_addresses': {'readonly': True}, - 'private_ip_addresses': {'readonly': True}, - } - - _attribute_map = { - 'notification_sender_email': {'key': 'notificationSenderEmail', 'type': 'str'}, - 'provisioning_state': {'key': 'provisioningState', 'type': 'str'}, - 'target_provisioning_state': {'key': 'targetProvisioningState', 'type': 'str'}, - 'created_at_utc': {'key': 'createdAtUtc', 'type': 'iso-8601'}, - 'gateway_url': {'key': 'gatewayUrl', 'type': 'str'}, - 'gateway_regional_url': {'key': 'gatewayRegionalUrl', 'type': 'str'}, - 'portal_url': {'key': 'portalUrl', 'type': 'str'}, - 'management_api_url': {'key': 'managementApiUrl', 'type': 'str'}, - 'scm_url': {'key': 'scmUrl', 'type': 'str'}, - 'hostname_configurations': {'key': 'hostnameConfigurations', 'type': '[HostnameConfiguration]'}, - 'public_ip_addresses': {'key': 'publicIPAddresses', 'type': '[str]'}, - 'private_ip_addresses': {'key': 'privateIPAddresses', 'type': '[str]'}, - 'virtual_network_configuration': {'key': 'virtualNetworkConfiguration', 'type': 'VirtualNetworkConfiguration'}, - 'additional_locations': {'key': 'additionalLocations', 'type': '[AdditionalLocation]'}, - 'custom_properties': {'key': 'customProperties', 'type': '{str}'}, - 'certificates': {'key': 'certificates', 'type': '[CertificateConfiguration]'}, - 'enable_client_certificate': {'key': 'enableClientCertificate', 'type': 'bool'}, - 'virtual_network_type': {'key': 'virtualNetworkType', 'type': 'str'}, - } - - def __init__(self, **kwargs): - super(ApiManagementServiceBaseProperties, self).__init__(**kwargs) - self.notification_sender_email = kwargs.get('notification_sender_email', None) - self.provisioning_state = None - self.target_provisioning_state = None - self.created_at_utc = None - self.gateway_url = None - self.gateway_regional_url = None - self.portal_url = None - self.management_api_url = None - self.scm_url = None - self.hostname_configurations = kwargs.get('hostname_configurations', None) - self.public_ip_addresses = None - self.private_ip_addresses = None - self.virtual_network_configuration = kwargs.get('virtual_network_configuration', None) - self.additional_locations = kwargs.get('additional_locations', None) - self.custom_properties = kwargs.get('custom_properties', None) - self.certificates = kwargs.get('certificates', None) - self.enable_client_certificate = kwargs.get('enable_client_certificate', False) - self.virtual_network_type = kwargs.get('virtual_network_type', "None") diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/api_management_service_base_properties_py3.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/api_management_service_base_properties_py3.py deleted file mode 100644 index cadc56f88b6b..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/api_management_service_base_properties_py3.py +++ /dev/null @@ -1,157 +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 ApiManagementServiceBaseProperties(Model): - """Base Properties of an API Management service resource description. - - Variables are only populated by the server, and will be ignored when - sending a request. - - :param notification_sender_email: Email address from which the - notification will be sent. - :type notification_sender_email: str - :ivar provisioning_state: The current provisioning state of the API - Management service which can be one of the following: - Created/Activating/Succeeded/Updating/Failed/Stopped/Terminating/TerminationFailed/Deleted. - :vartype provisioning_state: str - :ivar target_provisioning_state: The provisioning state of the API - Management service, which is targeted by the long running operation - started on the service. - :vartype target_provisioning_state: str - :ivar created_at_utc: Creation UTC date of the API Management service.The - date conforms to the following format: `yyyy-MM-ddTHH:mm:ssZ` as specified - by the ISO 8601 standard. - :vartype created_at_utc: datetime - :ivar gateway_url: Gateway URL of the API Management service. - :vartype gateway_url: str - :ivar gateway_regional_url: Gateway URL of the API Management service in - the Default Region. - :vartype gateway_regional_url: str - :ivar portal_url: Publisher portal endpoint Url of the API Management - service. - :vartype portal_url: str - :ivar management_api_url: Management API endpoint URL of the API - Management service. - :vartype management_api_url: str - :ivar scm_url: SCM endpoint URL of the API Management service. - :vartype scm_url: str - :param hostname_configurations: Custom hostname configuration of the API - Management service. - :type hostname_configurations: - list[~azure.mgmt.apimanagement.models.HostnameConfiguration] - :ivar public_ip_addresses: Public Static Load Balanced IP addresses of the - API Management service in Primary region. Available only for Basic, - Standard and Premium SKU. - :vartype public_ip_addresses: list[str] - :ivar private_ip_addresses: Private Static Load Balanced IP addresses of - the API Management service in Primary region which is deployed in an - Internal Virtual Network. Available only for Basic, Standard and Premium - SKU. - :vartype private_ip_addresses: list[str] - :param virtual_network_configuration: Virtual network configuration of the - API Management service. - :type virtual_network_configuration: - ~azure.mgmt.apimanagement.models.VirtualNetworkConfiguration - :param additional_locations: Additional datacenter locations of the API - Management service. - :type additional_locations: - list[~azure.mgmt.apimanagement.models.AdditionalLocation] - :param custom_properties: Custom properties of the API Management service. - Setting - `Microsoft.WindowsAzure.ApiManagement.Gateway.Security.Ciphers.TripleDes168` - will disable the cipher TLS_RSA_WITH_3DES_EDE_CBC_SHA for all TLS(1.0, 1.1 - and 1.2). Setting - `Microsoft.WindowsAzure.ApiManagement.Gateway.Security.Protocols.Tls11` - can be used to disable just TLS 1.1 and setting - `Microsoft.WindowsAzure.ApiManagement.Gateway.Security.Protocols.Tls10` - can be used to disable TLS 1.0 on an API Management service. - :type custom_properties: dict[str, str] - :param certificates: List of Certificates that need to be installed in the - API Management service. Max supported certificates that can be installed - is 10. - :type certificates: - list[~azure.mgmt.apimanagement.models.CertificateConfiguration] - :param enable_client_certificate: Property only meant to be used for - Consumption SKU Service. This enforces a client certificate to be - presented on each request to the gateway. This also enables the ability to - authenticate the certificate in the policy on the gateway. Default value: - False . - :type enable_client_certificate: bool - :param virtual_network_type: The type of VPN in which API Management - service needs to be configured in. None (Default Value) means the API - Management service is not part of any Virtual Network, External means the - API Management deployment is set up inside a Virtual Network having an - Internet Facing Endpoint, and Internal means that API Management - deployment is setup inside a Virtual Network having an Intranet Facing - Endpoint only. Possible values include: 'None', 'External', 'Internal'. - Default value: "None" . - :type virtual_network_type: str or - ~azure.mgmt.apimanagement.models.VirtualNetworkType - """ - - _validation = { - 'notification_sender_email': {'max_length': 100}, - 'provisioning_state': {'readonly': True}, - 'target_provisioning_state': {'readonly': True}, - 'created_at_utc': {'readonly': True}, - 'gateway_url': {'readonly': True}, - 'gateway_regional_url': {'readonly': True}, - 'portal_url': {'readonly': True}, - 'management_api_url': {'readonly': True}, - 'scm_url': {'readonly': True}, - 'public_ip_addresses': {'readonly': True}, - 'private_ip_addresses': {'readonly': True}, - } - - _attribute_map = { - 'notification_sender_email': {'key': 'notificationSenderEmail', 'type': 'str'}, - 'provisioning_state': {'key': 'provisioningState', 'type': 'str'}, - 'target_provisioning_state': {'key': 'targetProvisioningState', 'type': 'str'}, - 'created_at_utc': {'key': 'createdAtUtc', 'type': 'iso-8601'}, - 'gateway_url': {'key': 'gatewayUrl', 'type': 'str'}, - 'gateway_regional_url': {'key': 'gatewayRegionalUrl', 'type': 'str'}, - 'portal_url': {'key': 'portalUrl', 'type': 'str'}, - 'management_api_url': {'key': 'managementApiUrl', 'type': 'str'}, - 'scm_url': {'key': 'scmUrl', 'type': 'str'}, - 'hostname_configurations': {'key': 'hostnameConfigurations', 'type': '[HostnameConfiguration]'}, - 'public_ip_addresses': {'key': 'publicIPAddresses', 'type': '[str]'}, - 'private_ip_addresses': {'key': 'privateIPAddresses', 'type': '[str]'}, - 'virtual_network_configuration': {'key': 'virtualNetworkConfiguration', 'type': 'VirtualNetworkConfiguration'}, - 'additional_locations': {'key': 'additionalLocations', 'type': '[AdditionalLocation]'}, - 'custom_properties': {'key': 'customProperties', 'type': '{str}'}, - 'certificates': {'key': 'certificates', 'type': '[CertificateConfiguration]'}, - 'enable_client_certificate': {'key': 'enableClientCertificate', 'type': 'bool'}, - 'virtual_network_type': {'key': 'virtualNetworkType', 'type': 'str'}, - } - - def __init__(self, *, notification_sender_email: str=None, hostname_configurations=None, virtual_network_configuration=None, additional_locations=None, custom_properties=None, certificates=None, enable_client_certificate: bool=False, virtual_network_type="None", **kwargs) -> None: - super(ApiManagementServiceBaseProperties, self).__init__(**kwargs) - self.notification_sender_email = notification_sender_email - self.provisioning_state = None - self.target_provisioning_state = None - self.created_at_utc = None - self.gateway_url = None - self.gateway_regional_url = None - self.portal_url = None - self.management_api_url = None - self.scm_url = None - self.hostname_configurations = hostname_configurations - self.public_ip_addresses = None - self.private_ip_addresses = None - self.virtual_network_configuration = virtual_network_configuration - self.additional_locations = additional_locations - self.custom_properties = custom_properties - self.certificates = certificates - self.enable_client_certificate = enable_client_certificate - self.virtual_network_type = virtual_network_type diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/api_management_service_check_name_availability_parameters.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/api_management_service_check_name_availability_parameters.py deleted file mode 100644 index 621a58f23110..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/api_management_service_check_name_availability_parameters.py +++ /dev/null @@ -1,34 +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 ApiManagementServiceCheckNameAvailabilityParameters(Model): - """Parameters supplied to the CheckNameAvailability operation. - - All required parameters must be populated in order to send to Azure. - - :param name: Required. The name to check for availability. - :type name: str - """ - - _validation = { - 'name': {'required': True}, - } - - _attribute_map = { - 'name': {'key': 'name', 'type': 'str'}, - } - - def __init__(self, **kwargs): - super(ApiManagementServiceCheckNameAvailabilityParameters, self).__init__(**kwargs) - self.name = kwargs.get('name', None) diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/api_management_service_check_name_availability_parameters_py3.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/api_management_service_check_name_availability_parameters_py3.py deleted file mode 100644 index 8025048f1cb7..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/api_management_service_check_name_availability_parameters_py3.py +++ /dev/null @@ -1,34 +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 ApiManagementServiceCheckNameAvailabilityParameters(Model): - """Parameters supplied to the CheckNameAvailability operation. - - All required parameters must be populated in order to send to Azure. - - :param name: Required. The name to check for availability. - :type name: str - """ - - _validation = { - 'name': {'required': True}, - } - - _attribute_map = { - 'name': {'key': 'name', 'type': 'str'}, - } - - def __init__(self, *, name: str, **kwargs) -> None: - super(ApiManagementServiceCheckNameAvailabilityParameters, self).__init__(**kwargs) - self.name = name diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/api_management_service_get_sso_token_result.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/api_management_service_get_sso_token_result.py deleted file mode 100644 index 34e758843486..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/api_management_service_get_sso_token_result.py +++ /dev/null @@ -1,29 +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 ApiManagementServiceGetSsoTokenResult(Model): - """The response of the GetSsoToken operation. - - :param redirect_uri: Redirect URL to the Publisher Portal containing the - SSO token. - :type redirect_uri: str - """ - - _attribute_map = { - 'redirect_uri': {'key': 'redirectUri', 'type': 'str'}, - } - - def __init__(self, **kwargs): - super(ApiManagementServiceGetSsoTokenResult, self).__init__(**kwargs) - self.redirect_uri = kwargs.get('redirect_uri', None) diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/api_management_service_get_sso_token_result_py3.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/api_management_service_get_sso_token_result_py3.py deleted file mode 100644 index 607491621d49..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/api_management_service_get_sso_token_result_py3.py +++ /dev/null @@ -1,29 +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 ApiManagementServiceGetSsoTokenResult(Model): - """The response of the GetSsoToken operation. - - :param redirect_uri: Redirect URL to the Publisher Portal containing the - SSO token. - :type redirect_uri: str - """ - - _attribute_map = { - 'redirect_uri': {'key': 'redirectUri', 'type': 'str'}, - } - - def __init__(self, *, redirect_uri: str=None, **kwargs) -> None: - super(ApiManagementServiceGetSsoTokenResult, self).__init__(**kwargs) - self.redirect_uri = redirect_uri diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/api_management_service_identity.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/api_management_service_identity.py deleted file mode 100644 index 784c8854358d..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/api_management_service_identity.py +++ /dev/null @@ -1,49 +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 ApiManagementServiceIdentity(Model): - """Identity properties of the Api Management service resource. - - Variables are only populated by the server, and will be ignored when - sending a request. - - All required parameters must be populated in order to send to Azure. - - :ivar type: Required. The identity type. Currently the only supported type - is 'SystemAssigned'. Default value: "SystemAssigned" . - :vartype type: str - :ivar principal_id: The principal id of the identity. - :vartype principal_id: str - :ivar tenant_id: The client tenant id of the identity. - :vartype tenant_id: str - """ - - _validation = { - 'type': {'required': True, 'constant': True}, - 'principal_id': {'readonly': True}, - 'tenant_id': {'readonly': True}, - } - - _attribute_map = { - 'type': {'key': 'type', 'type': 'str'}, - 'principal_id': {'key': 'principalId', 'type': 'str'}, - 'tenant_id': {'key': 'tenantId', 'type': 'str'}, - } - - type = "SystemAssigned" - - def __init__(self, **kwargs): - super(ApiManagementServiceIdentity, self).__init__(**kwargs) - self.principal_id = None - self.tenant_id = None diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/api_management_service_identity_py3.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/api_management_service_identity_py3.py deleted file mode 100644 index 2ef5954875ef..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/api_management_service_identity_py3.py +++ /dev/null @@ -1,49 +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 ApiManagementServiceIdentity(Model): - """Identity properties of the Api Management service resource. - - Variables are only populated by the server, and will be ignored when - sending a request. - - All required parameters must be populated in order to send to Azure. - - :ivar type: Required. The identity type. Currently the only supported type - is 'SystemAssigned'. Default value: "SystemAssigned" . - :vartype type: str - :ivar principal_id: The principal id of the identity. - :vartype principal_id: str - :ivar tenant_id: The client tenant id of the identity. - :vartype tenant_id: str - """ - - _validation = { - 'type': {'required': True, 'constant': True}, - 'principal_id': {'readonly': True}, - 'tenant_id': {'readonly': True}, - } - - _attribute_map = { - 'type': {'key': 'type', 'type': 'str'}, - 'principal_id': {'key': 'principalId', 'type': 'str'}, - 'tenant_id': {'key': 'tenantId', 'type': 'str'}, - } - - type = "SystemAssigned" - - def __init__(self, **kwargs) -> None: - super(ApiManagementServiceIdentity, self).__init__(**kwargs) - self.principal_id = None - self.tenant_id = None diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/api_management_service_name_availability_result.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/api_management_service_name_availability_result.py deleted file mode 100644 index dd5eda6bdb95..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/api_management_service_name_availability_result.py +++ /dev/null @@ -1,54 +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 ApiManagementServiceNameAvailabilityResult(Model): - """Response of the CheckNameAvailability operation. - - Variables are only populated by the server, and will be ignored when - sending a request. - - :ivar name_available: True if the name is available and can be used to - create a new API Management service; otherwise false. - :vartype name_available: bool - :ivar message: If reason == invalid, provide the user with the reason why - the given name is invalid, and provide the resource naming requirements so - that the user can select a valid name. If reason == AlreadyExists, explain - that is already in use, and direct them to select a - different name. - :vartype message: str - :param reason: Invalid indicates the name provided does not match the - resource provider’s naming requirements (incorrect length, unsupported - characters, etc.) AlreadyExists indicates that the name is already in use - and is therefore unavailable. Possible values include: 'Valid', 'Invalid', - 'AlreadyExists' - :type reason: str or - ~azure.mgmt.apimanagement.models.NameAvailabilityReason - """ - - _validation = { - 'name_available': {'readonly': True}, - 'message': {'readonly': True}, - } - - _attribute_map = { - 'name_available': {'key': 'nameAvailable', 'type': 'bool'}, - 'message': {'key': 'message', 'type': 'str'}, - 'reason': {'key': 'reason', 'type': 'NameAvailabilityReason'}, - } - - def __init__(self, **kwargs): - super(ApiManagementServiceNameAvailabilityResult, self).__init__(**kwargs) - self.name_available = None - self.message = None - self.reason = kwargs.get('reason', None) diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/api_management_service_name_availability_result_py3.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/api_management_service_name_availability_result_py3.py deleted file mode 100644 index 3bae91346b47..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/api_management_service_name_availability_result_py3.py +++ /dev/null @@ -1,54 +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 ApiManagementServiceNameAvailabilityResult(Model): - """Response of the CheckNameAvailability operation. - - Variables are only populated by the server, and will be ignored when - sending a request. - - :ivar name_available: True if the name is available and can be used to - create a new API Management service; otherwise false. - :vartype name_available: bool - :ivar message: If reason == invalid, provide the user with the reason why - the given name is invalid, and provide the resource naming requirements so - that the user can select a valid name. If reason == AlreadyExists, explain - that is already in use, and direct them to select a - different name. - :vartype message: str - :param reason: Invalid indicates the name provided does not match the - resource provider’s naming requirements (incorrect length, unsupported - characters, etc.) AlreadyExists indicates that the name is already in use - and is therefore unavailable. Possible values include: 'Valid', 'Invalid', - 'AlreadyExists' - :type reason: str or - ~azure.mgmt.apimanagement.models.NameAvailabilityReason - """ - - _validation = { - 'name_available': {'readonly': True}, - 'message': {'readonly': True}, - } - - _attribute_map = { - 'name_available': {'key': 'nameAvailable', 'type': 'bool'}, - 'message': {'key': 'message', 'type': 'str'}, - 'reason': {'key': 'reason', 'type': 'NameAvailabilityReason'}, - } - - def __init__(self, *, reason=None, **kwargs) -> None: - super(ApiManagementServiceNameAvailabilityResult, self).__init__(**kwargs) - self.name_available = None - self.message = None - self.reason = reason diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/api_management_service_resource.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/api_management_service_resource.py deleted file mode 100644 index 23867d44ffdf..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/api_management_service_resource.py +++ /dev/null @@ -1,206 +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 .apim_resource import ApimResource - - -class ApiManagementServiceResource(ApimResource): - """A single API Management service resource in List or Get response. - - Variables are only populated by the server, and will be ignored when - sending a request. - - All required parameters must be populated in order to send to Azure. - - :ivar id: Resource ID. - :vartype id: str - :ivar name: Resource name. - :vartype name: str - :ivar type: Resource type for API Management resource is set to - Microsoft.ApiManagement. - :vartype type: str - :param tags: Resource tags. - :type tags: dict[str, str] - :param notification_sender_email: Email address from which the - notification will be sent. - :type notification_sender_email: str - :ivar provisioning_state: The current provisioning state of the API - Management service which can be one of the following: - Created/Activating/Succeeded/Updating/Failed/Stopped/Terminating/TerminationFailed/Deleted. - :vartype provisioning_state: str - :ivar target_provisioning_state: The provisioning state of the API - Management service, which is targeted by the long running operation - started on the service. - :vartype target_provisioning_state: str - :ivar created_at_utc: Creation UTC date of the API Management service.The - date conforms to the following format: `yyyy-MM-ddTHH:mm:ssZ` as specified - by the ISO 8601 standard. - :vartype created_at_utc: datetime - :ivar gateway_url: Gateway URL of the API Management service. - :vartype gateway_url: str - :ivar gateway_regional_url: Gateway URL of the API Management service in - the Default Region. - :vartype gateway_regional_url: str - :ivar portal_url: Publisher portal endpoint Url of the API Management - service. - :vartype portal_url: str - :ivar management_api_url: Management API endpoint URL of the API - Management service. - :vartype management_api_url: str - :ivar scm_url: SCM endpoint URL of the API Management service. - :vartype scm_url: str - :param hostname_configurations: Custom hostname configuration of the API - Management service. - :type hostname_configurations: - list[~azure.mgmt.apimanagement.models.HostnameConfiguration] - :ivar public_ip_addresses: Public Static Load Balanced IP addresses of the - API Management service in Primary region. Available only for Basic, - Standard and Premium SKU. - :vartype public_ip_addresses: list[str] - :ivar private_ip_addresses: Private Static Load Balanced IP addresses of - the API Management service in Primary region which is deployed in an - Internal Virtual Network. Available only for Basic, Standard and Premium - SKU. - :vartype private_ip_addresses: list[str] - :param virtual_network_configuration: Virtual network configuration of the - API Management service. - :type virtual_network_configuration: - ~azure.mgmt.apimanagement.models.VirtualNetworkConfiguration - :param additional_locations: Additional datacenter locations of the API - Management service. - :type additional_locations: - list[~azure.mgmt.apimanagement.models.AdditionalLocation] - :param custom_properties: Custom properties of the API Management service. - Setting - `Microsoft.WindowsAzure.ApiManagement.Gateway.Security.Ciphers.TripleDes168` - will disable the cipher TLS_RSA_WITH_3DES_EDE_CBC_SHA for all TLS(1.0, 1.1 - and 1.2). Setting - `Microsoft.WindowsAzure.ApiManagement.Gateway.Security.Protocols.Tls11` - can be used to disable just TLS 1.1 and setting - `Microsoft.WindowsAzure.ApiManagement.Gateway.Security.Protocols.Tls10` - can be used to disable TLS 1.0 on an API Management service. - :type custom_properties: dict[str, str] - :param certificates: List of Certificates that need to be installed in the - API Management service. Max supported certificates that can be installed - is 10. - :type certificates: - list[~azure.mgmt.apimanagement.models.CertificateConfiguration] - :param enable_client_certificate: Property only meant to be used for - Consumption SKU Service. This enforces a client certificate to be - presented on each request to the gateway. This also enables the ability to - authenticate the certificate in the policy on the gateway. Default value: - False . - :type enable_client_certificate: bool - :param virtual_network_type: The type of VPN in which API Management - service needs to be configured in. None (Default Value) means the API - Management service is not part of any Virtual Network, External means the - API Management deployment is set up inside a Virtual Network having an - Internet Facing Endpoint, and Internal means that API Management - deployment is setup inside a Virtual Network having an Intranet Facing - Endpoint only. Possible values include: 'None', 'External', 'Internal'. - Default value: "None" . - :type virtual_network_type: str or - ~azure.mgmt.apimanagement.models.VirtualNetworkType - :param publisher_email: Required. Publisher email. - :type publisher_email: str - :param publisher_name: Required. Publisher name. - :type publisher_name: str - :param sku: Required. SKU properties of the API Management service. - :type sku: - ~azure.mgmt.apimanagement.models.ApiManagementServiceSkuProperties - :param identity: Managed service identity of the Api Management service. - :type identity: - ~azure.mgmt.apimanagement.models.ApiManagementServiceIdentity - :param location: Required. Resource location. - :type location: str - :ivar etag: ETag of the resource. - :vartype etag: str - """ - - _validation = { - 'id': {'readonly': True}, - 'name': {'readonly': True}, - 'type': {'readonly': True}, - 'notification_sender_email': {'max_length': 100}, - 'provisioning_state': {'readonly': True}, - 'target_provisioning_state': {'readonly': True}, - 'created_at_utc': {'readonly': True}, - 'gateway_url': {'readonly': True}, - 'gateway_regional_url': {'readonly': True}, - 'portal_url': {'readonly': True}, - 'management_api_url': {'readonly': True}, - 'scm_url': {'readonly': True}, - 'public_ip_addresses': {'readonly': True}, - 'private_ip_addresses': {'readonly': True}, - 'publisher_email': {'required': True, 'max_length': 100}, - 'publisher_name': {'required': True, 'max_length': 100}, - 'sku': {'required': True}, - 'location': {'required': True}, - 'etag': {'readonly': True}, - } - - _attribute_map = { - 'id': {'key': 'id', 'type': 'str'}, - 'name': {'key': 'name', 'type': 'str'}, - 'type': {'key': 'type', 'type': 'str'}, - 'tags': {'key': 'tags', 'type': '{str}'}, - 'notification_sender_email': {'key': 'properties.notificationSenderEmail', 'type': 'str'}, - 'provisioning_state': {'key': 'properties.provisioningState', 'type': 'str'}, - 'target_provisioning_state': {'key': 'properties.targetProvisioningState', 'type': 'str'}, - 'created_at_utc': {'key': 'properties.createdAtUtc', 'type': 'iso-8601'}, - 'gateway_url': {'key': 'properties.gatewayUrl', 'type': 'str'}, - 'gateway_regional_url': {'key': 'properties.gatewayRegionalUrl', 'type': 'str'}, - 'portal_url': {'key': 'properties.portalUrl', 'type': 'str'}, - 'management_api_url': {'key': 'properties.managementApiUrl', 'type': 'str'}, - 'scm_url': {'key': 'properties.scmUrl', 'type': 'str'}, - 'hostname_configurations': {'key': 'properties.hostnameConfigurations', 'type': '[HostnameConfiguration]'}, - 'public_ip_addresses': {'key': 'properties.publicIPAddresses', 'type': '[str]'}, - 'private_ip_addresses': {'key': 'properties.privateIPAddresses', 'type': '[str]'}, - 'virtual_network_configuration': {'key': 'properties.virtualNetworkConfiguration', 'type': 'VirtualNetworkConfiguration'}, - 'additional_locations': {'key': 'properties.additionalLocations', 'type': '[AdditionalLocation]'}, - 'custom_properties': {'key': 'properties.customProperties', 'type': '{str}'}, - 'certificates': {'key': 'properties.certificates', 'type': '[CertificateConfiguration]'}, - 'enable_client_certificate': {'key': 'properties.enableClientCertificate', 'type': 'bool'}, - 'virtual_network_type': {'key': 'properties.virtualNetworkType', 'type': 'str'}, - 'publisher_email': {'key': 'properties.publisherEmail', 'type': 'str'}, - 'publisher_name': {'key': 'properties.publisherName', 'type': 'str'}, - 'sku': {'key': 'sku', 'type': 'ApiManagementServiceSkuProperties'}, - 'identity': {'key': 'identity', 'type': 'ApiManagementServiceIdentity'}, - 'location': {'key': 'location', 'type': 'str'}, - 'etag': {'key': 'etag', 'type': 'str'}, - } - - def __init__(self, **kwargs): - super(ApiManagementServiceResource, self).__init__(**kwargs) - self.notification_sender_email = kwargs.get('notification_sender_email', None) - self.provisioning_state = None - self.target_provisioning_state = None - self.created_at_utc = None - self.gateway_url = None - self.gateway_regional_url = None - self.portal_url = None - self.management_api_url = None - self.scm_url = None - self.hostname_configurations = kwargs.get('hostname_configurations', None) - self.public_ip_addresses = None - self.private_ip_addresses = None - self.virtual_network_configuration = kwargs.get('virtual_network_configuration', None) - self.additional_locations = kwargs.get('additional_locations', None) - self.custom_properties = kwargs.get('custom_properties', None) - self.certificates = kwargs.get('certificates', None) - self.enable_client_certificate = kwargs.get('enable_client_certificate', False) - self.virtual_network_type = kwargs.get('virtual_network_type', "None") - self.publisher_email = kwargs.get('publisher_email', None) - self.publisher_name = kwargs.get('publisher_name', None) - self.sku = kwargs.get('sku', None) - self.identity = kwargs.get('identity', None) - self.location = kwargs.get('location', None) - self.etag = None diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/api_management_service_resource_paged.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/api_management_service_resource_paged.py deleted file mode 100644 index 3f5ff2743b15..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/api_management_service_resource_paged.py +++ /dev/null @@ -1,27 +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.paging import Paged - - -class ApiManagementServiceResourcePaged(Paged): - """ - A paging container for iterating over a list of :class:`ApiManagementServiceResource ` object - """ - - _attribute_map = { - 'next_link': {'key': 'nextLink', 'type': 'str'}, - 'current_page': {'key': 'value', 'type': '[ApiManagementServiceResource]'} - } - - def __init__(self, *args, **kwargs): - - super(ApiManagementServiceResourcePaged, self).__init__(*args, **kwargs) diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/api_management_service_resource_py3.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/api_management_service_resource_py3.py deleted file mode 100644 index 8e2213108bd0..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/api_management_service_resource_py3.py +++ /dev/null @@ -1,206 +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 .apim_resource_py3 import ApimResource - - -class ApiManagementServiceResource(ApimResource): - """A single API Management service resource in List or Get response. - - Variables are only populated by the server, and will be ignored when - sending a request. - - All required parameters must be populated in order to send to Azure. - - :ivar id: Resource ID. - :vartype id: str - :ivar name: Resource name. - :vartype name: str - :ivar type: Resource type for API Management resource is set to - Microsoft.ApiManagement. - :vartype type: str - :param tags: Resource tags. - :type tags: dict[str, str] - :param notification_sender_email: Email address from which the - notification will be sent. - :type notification_sender_email: str - :ivar provisioning_state: The current provisioning state of the API - Management service which can be one of the following: - Created/Activating/Succeeded/Updating/Failed/Stopped/Terminating/TerminationFailed/Deleted. - :vartype provisioning_state: str - :ivar target_provisioning_state: The provisioning state of the API - Management service, which is targeted by the long running operation - started on the service. - :vartype target_provisioning_state: str - :ivar created_at_utc: Creation UTC date of the API Management service.The - date conforms to the following format: `yyyy-MM-ddTHH:mm:ssZ` as specified - by the ISO 8601 standard. - :vartype created_at_utc: datetime - :ivar gateway_url: Gateway URL of the API Management service. - :vartype gateway_url: str - :ivar gateway_regional_url: Gateway URL of the API Management service in - the Default Region. - :vartype gateway_regional_url: str - :ivar portal_url: Publisher portal endpoint Url of the API Management - service. - :vartype portal_url: str - :ivar management_api_url: Management API endpoint URL of the API - Management service. - :vartype management_api_url: str - :ivar scm_url: SCM endpoint URL of the API Management service. - :vartype scm_url: str - :param hostname_configurations: Custom hostname configuration of the API - Management service. - :type hostname_configurations: - list[~azure.mgmt.apimanagement.models.HostnameConfiguration] - :ivar public_ip_addresses: Public Static Load Balanced IP addresses of the - API Management service in Primary region. Available only for Basic, - Standard and Premium SKU. - :vartype public_ip_addresses: list[str] - :ivar private_ip_addresses: Private Static Load Balanced IP addresses of - the API Management service in Primary region which is deployed in an - Internal Virtual Network. Available only for Basic, Standard and Premium - SKU. - :vartype private_ip_addresses: list[str] - :param virtual_network_configuration: Virtual network configuration of the - API Management service. - :type virtual_network_configuration: - ~azure.mgmt.apimanagement.models.VirtualNetworkConfiguration - :param additional_locations: Additional datacenter locations of the API - Management service. - :type additional_locations: - list[~azure.mgmt.apimanagement.models.AdditionalLocation] - :param custom_properties: Custom properties of the API Management service. - Setting - `Microsoft.WindowsAzure.ApiManagement.Gateway.Security.Ciphers.TripleDes168` - will disable the cipher TLS_RSA_WITH_3DES_EDE_CBC_SHA for all TLS(1.0, 1.1 - and 1.2). Setting - `Microsoft.WindowsAzure.ApiManagement.Gateway.Security.Protocols.Tls11` - can be used to disable just TLS 1.1 and setting - `Microsoft.WindowsAzure.ApiManagement.Gateway.Security.Protocols.Tls10` - can be used to disable TLS 1.0 on an API Management service. - :type custom_properties: dict[str, str] - :param certificates: List of Certificates that need to be installed in the - API Management service. Max supported certificates that can be installed - is 10. - :type certificates: - list[~azure.mgmt.apimanagement.models.CertificateConfiguration] - :param enable_client_certificate: Property only meant to be used for - Consumption SKU Service. This enforces a client certificate to be - presented on each request to the gateway. This also enables the ability to - authenticate the certificate in the policy on the gateway. Default value: - False . - :type enable_client_certificate: bool - :param virtual_network_type: The type of VPN in which API Management - service needs to be configured in. None (Default Value) means the API - Management service is not part of any Virtual Network, External means the - API Management deployment is set up inside a Virtual Network having an - Internet Facing Endpoint, and Internal means that API Management - deployment is setup inside a Virtual Network having an Intranet Facing - Endpoint only. Possible values include: 'None', 'External', 'Internal'. - Default value: "None" . - :type virtual_network_type: str or - ~azure.mgmt.apimanagement.models.VirtualNetworkType - :param publisher_email: Required. Publisher email. - :type publisher_email: str - :param publisher_name: Required. Publisher name. - :type publisher_name: str - :param sku: Required. SKU properties of the API Management service. - :type sku: - ~azure.mgmt.apimanagement.models.ApiManagementServiceSkuProperties - :param identity: Managed service identity of the Api Management service. - :type identity: - ~azure.mgmt.apimanagement.models.ApiManagementServiceIdentity - :param location: Required. Resource location. - :type location: str - :ivar etag: ETag of the resource. - :vartype etag: str - """ - - _validation = { - 'id': {'readonly': True}, - 'name': {'readonly': True}, - 'type': {'readonly': True}, - 'notification_sender_email': {'max_length': 100}, - 'provisioning_state': {'readonly': True}, - 'target_provisioning_state': {'readonly': True}, - 'created_at_utc': {'readonly': True}, - 'gateway_url': {'readonly': True}, - 'gateway_regional_url': {'readonly': True}, - 'portal_url': {'readonly': True}, - 'management_api_url': {'readonly': True}, - 'scm_url': {'readonly': True}, - 'public_ip_addresses': {'readonly': True}, - 'private_ip_addresses': {'readonly': True}, - 'publisher_email': {'required': True, 'max_length': 100}, - 'publisher_name': {'required': True, 'max_length': 100}, - 'sku': {'required': True}, - 'location': {'required': True}, - 'etag': {'readonly': True}, - } - - _attribute_map = { - 'id': {'key': 'id', 'type': 'str'}, - 'name': {'key': 'name', 'type': 'str'}, - 'type': {'key': 'type', 'type': 'str'}, - 'tags': {'key': 'tags', 'type': '{str}'}, - 'notification_sender_email': {'key': 'properties.notificationSenderEmail', 'type': 'str'}, - 'provisioning_state': {'key': 'properties.provisioningState', 'type': 'str'}, - 'target_provisioning_state': {'key': 'properties.targetProvisioningState', 'type': 'str'}, - 'created_at_utc': {'key': 'properties.createdAtUtc', 'type': 'iso-8601'}, - 'gateway_url': {'key': 'properties.gatewayUrl', 'type': 'str'}, - 'gateway_regional_url': {'key': 'properties.gatewayRegionalUrl', 'type': 'str'}, - 'portal_url': {'key': 'properties.portalUrl', 'type': 'str'}, - 'management_api_url': {'key': 'properties.managementApiUrl', 'type': 'str'}, - 'scm_url': {'key': 'properties.scmUrl', 'type': 'str'}, - 'hostname_configurations': {'key': 'properties.hostnameConfigurations', 'type': '[HostnameConfiguration]'}, - 'public_ip_addresses': {'key': 'properties.publicIPAddresses', 'type': '[str]'}, - 'private_ip_addresses': {'key': 'properties.privateIPAddresses', 'type': '[str]'}, - 'virtual_network_configuration': {'key': 'properties.virtualNetworkConfiguration', 'type': 'VirtualNetworkConfiguration'}, - 'additional_locations': {'key': 'properties.additionalLocations', 'type': '[AdditionalLocation]'}, - 'custom_properties': {'key': 'properties.customProperties', 'type': '{str}'}, - 'certificates': {'key': 'properties.certificates', 'type': '[CertificateConfiguration]'}, - 'enable_client_certificate': {'key': 'properties.enableClientCertificate', 'type': 'bool'}, - 'virtual_network_type': {'key': 'properties.virtualNetworkType', 'type': 'str'}, - 'publisher_email': {'key': 'properties.publisherEmail', 'type': 'str'}, - 'publisher_name': {'key': 'properties.publisherName', 'type': 'str'}, - 'sku': {'key': 'sku', 'type': 'ApiManagementServiceSkuProperties'}, - 'identity': {'key': 'identity', 'type': 'ApiManagementServiceIdentity'}, - 'location': {'key': 'location', 'type': 'str'}, - 'etag': {'key': 'etag', 'type': 'str'}, - } - - def __init__(self, *, publisher_email: str, publisher_name: str, sku, location: str, tags=None, notification_sender_email: str=None, hostname_configurations=None, virtual_network_configuration=None, additional_locations=None, custom_properties=None, certificates=None, enable_client_certificate: bool=False, virtual_network_type="None", identity=None, **kwargs) -> None: - super(ApiManagementServiceResource, self).__init__(tags=tags, **kwargs) - self.notification_sender_email = notification_sender_email - self.provisioning_state = None - self.target_provisioning_state = None - self.created_at_utc = None - self.gateway_url = None - self.gateway_regional_url = None - self.portal_url = None - self.management_api_url = None - self.scm_url = None - self.hostname_configurations = hostname_configurations - self.public_ip_addresses = None - self.private_ip_addresses = None - self.virtual_network_configuration = virtual_network_configuration - self.additional_locations = additional_locations - self.custom_properties = custom_properties - self.certificates = certificates - self.enable_client_certificate = enable_client_certificate - self.virtual_network_type = virtual_network_type - self.publisher_email = publisher_email - self.publisher_name = publisher_name - self.sku = sku - self.identity = identity - self.location = location - self.etag = None diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/api_management_service_sku_properties.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/api_management_service_sku_properties.py deleted file mode 100644 index 1ccc258b22e6..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/api_management_service_sku_properties.py +++ /dev/null @@ -1,40 +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 ApiManagementServiceSkuProperties(Model): - """API Management service resource SKU properties. - - All required parameters must be populated in order to send to Azure. - - :param name: Required. Name of the Sku. Possible values include: - 'Developer', 'Standard', 'Premium', 'Basic', 'Consumption' - :type name: str or ~azure.mgmt.apimanagement.models.SkuType - :param capacity: Capacity of the SKU (number of deployed units of the - SKU). - :type capacity: int - """ - - _validation = { - 'name': {'required': True}, - } - - _attribute_map = { - 'name': {'key': 'name', 'type': 'str'}, - 'capacity': {'key': 'capacity', 'type': 'int'}, - } - - def __init__(self, **kwargs): - super(ApiManagementServiceSkuProperties, self).__init__(**kwargs) - self.name = kwargs.get('name', None) - self.capacity = kwargs.get('capacity', None) diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/api_management_service_sku_properties_py3.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/api_management_service_sku_properties_py3.py deleted file mode 100644 index d9a425f3986f..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/api_management_service_sku_properties_py3.py +++ /dev/null @@ -1,40 +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 ApiManagementServiceSkuProperties(Model): - """API Management service resource SKU properties. - - All required parameters must be populated in order to send to Azure. - - :param name: Required. Name of the Sku. Possible values include: - 'Developer', 'Standard', 'Premium', 'Basic', 'Consumption' - :type name: str or ~azure.mgmt.apimanagement.models.SkuType - :param capacity: Capacity of the SKU (number of deployed units of the - SKU). - :type capacity: int - """ - - _validation = { - 'name': {'required': True}, - } - - _attribute_map = { - 'name': {'key': 'name', 'type': 'str'}, - 'capacity': {'key': 'capacity', 'type': 'int'}, - } - - def __init__(self, *, name, capacity: int=None, **kwargs) -> None: - super(ApiManagementServiceSkuProperties, self).__init__(**kwargs) - self.name = name - self.capacity = capacity diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/api_management_service_update_parameters.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/api_management_service_update_parameters.py deleted file mode 100644 index aca59f821f77..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/api_management_service_update_parameters.py +++ /dev/null @@ -1,198 +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 .apim_resource import ApimResource - - -class ApiManagementServiceUpdateParameters(ApimResource): - """Parameter supplied to Update Api Management Service. - - Variables are only populated by the server, and will be ignored when - sending a request. - - :ivar id: Resource ID. - :vartype id: str - :ivar name: Resource name. - :vartype name: str - :ivar type: Resource type for API Management resource is set to - Microsoft.ApiManagement. - :vartype type: str - :param tags: Resource tags. - :type tags: dict[str, str] - :param notification_sender_email: Email address from which the - notification will be sent. - :type notification_sender_email: str - :ivar provisioning_state: The current provisioning state of the API - Management service which can be one of the following: - Created/Activating/Succeeded/Updating/Failed/Stopped/Terminating/TerminationFailed/Deleted. - :vartype provisioning_state: str - :ivar target_provisioning_state: The provisioning state of the API - Management service, which is targeted by the long running operation - started on the service. - :vartype target_provisioning_state: str - :ivar created_at_utc: Creation UTC date of the API Management service.The - date conforms to the following format: `yyyy-MM-ddTHH:mm:ssZ` as specified - by the ISO 8601 standard. - :vartype created_at_utc: datetime - :ivar gateway_url: Gateway URL of the API Management service. - :vartype gateway_url: str - :ivar gateway_regional_url: Gateway URL of the API Management service in - the Default Region. - :vartype gateway_regional_url: str - :ivar portal_url: Publisher portal endpoint Url of the API Management - service. - :vartype portal_url: str - :ivar management_api_url: Management API endpoint URL of the API - Management service. - :vartype management_api_url: str - :ivar scm_url: SCM endpoint URL of the API Management service. - :vartype scm_url: str - :param hostname_configurations: Custom hostname configuration of the API - Management service. - :type hostname_configurations: - list[~azure.mgmt.apimanagement.models.HostnameConfiguration] - :ivar public_ip_addresses: Public Static Load Balanced IP addresses of the - API Management service in Primary region. Available only for Basic, - Standard and Premium SKU. - :vartype public_ip_addresses: list[str] - :ivar private_ip_addresses: Private Static Load Balanced IP addresses of - the API Management service in Primary region which is deployed in an - Internal Virtual Network. Available only for Basic, Standard and Premium - SKU. - :vartype private_ip_addresses: list[str] - :param virtual_network_configuration: Virtual network configuration of the - API Management service. - :type virtual_network_configuration: - ~azure.mgmt.apimanagement.models.VirtualNetworkConfiguration - :param additional_locations: Additional datacenter locations of the API - Management service. - :type additional_locations: - list[~azure.mgmt.apimanagement.models.AdditionalLocation] - :param custom_properties: Custom properties of the API Management service. - Setting - `Microsoft.WindowsAzure.ApiManagement.Gateway.Security.Ciphers.TripleDes168` - will disable the cipher TLS_RSA_WITH_3DES_EDE_CBC_SHA for all TLS(1.0, 1.1 - and 1.2). Setting - `Microsoft.WindowsAzure.ApiManagement.Gateway.Security.Protocols.Tls11` - can be used to disable just TLS 1.1 and setting - `Microsoft.WindowsAzure.ApiManagement.Gateway.Security.Protocols.Tls10` - can be used to disable TLS 1.0 on an API Management service. - :type custom_properties: dict[str, str] - :param certificates: List of Certificates that need to be installed in the - API Management service. Max supported certificates that can be installed - is 10. - :type certificates: - list[~azure.mgmt.apimanagement.models.CertificateConfiguration] - :param enable_client_certificate: Property only meant to be used for - Consumption SKU Service. This enforces a client certificate to be - presented on each request to the gateway. This also enables the ability to - authenticate the certificate in the policy on the gateway. Default value: - False . - :type enable_client_certificate: bool - :param virtual_network_type: The type of VPN in which API Management - service needs to be configured in. None (Default Value) means the API - Management service is not part of any Virtual Network, External means the - API Management deployment is set up inside a Virtual Network having an - Internet Facing Endpoint, and Internal means that API Management - deployment is setup inside a Virtual Network having an Intranet Facing - Endpoint only. Possible values include: 'None', 'External', 'Internal'. - Default value: "None" . - :type virtual_network_type: str or - ~azure.mgmt.apimanagement.models.VirtualNetworkType - :param publisher_email: Publisher email. - :type publisher_email: str - :param publisher_name: Publisher name. - :type publisher_name: str - :param sku: SKU properties of the API Management service. - :type sku: - ~azure.mgmt.apimanagement.models.ApiManagementServiceSkuProperties - :param identity: Managed service identity of the Api Management service. - :type identity: - ~azure.mgmt.apimanagement.models.ApiManagementServiceIdentity - :ivar etag: ETag of the resource. - :vartype etag: str - """ - - _validation = { - 'id': {'readonly': True}, - 'name': {'readonly': True}, - 'type': {'readonly': True}, - 'notification_sender_email': {'max_length': 100}, - 'provisioning_state': {'readonly': True}, - 'target_provisioning_state': {'readonly': True}, - 'created_at_utc': {'readonly': True}, - 'gateway_url': {'readonly': True}, - 'gateway_regional_url': {'readonly': True}, - 'portal_url': {'readonly': True}, - 'management_api_url': {'readonly': True}, - 'scm_url': {'readonly': True}, - 'public_ip_addresses': {'readonly': True}, - 'private_ip_addresses': {'readonly': True}, - 'publisher_email': {'max_length': 100}, - 'publisher_name': {'max_length': 100}, - 'etag': {'readonly': True}, - } - - _attribute_map = { - 'id': {'key': 'id', 'type': 'str'}, - 'name': {'key': 'name', 'type': 'str'}, - 'type': {'key': 'type', 'type': 'str'}, - 'tags': {'key': 'tags', 'type': '{str}'}, - 'notification_sender_email': {'key': 'properties.notificationSenderEmail', 'type': 'str'}, - 'provisioning_state': {'key': 'properties.provisioningState', 'type': 'str'}, - 'target_provisioning_state': {'key': 'properties.targetProvisioningState', 'type': 'str'}, - 'created_at_utc': {'key': 'properties.createdAtUtc', 'type': 'iso-8601'}, - 'gateway_url': {'key': 'properties.gatewayUrl', 'type': 'str'}, - 'gateway_regional_url': {'key': 'properties.gatewayRegionalUrl', 'type': 'str'}, - 'portal_url': {'key': 'properties.portalUrl', 'type': 'str'}, - 'management_api_url': {'key': 'properties.managementApiUrl', 'type': 'str'}, - 'scm_url': {'key': 'properties.scmUrl', 'type': 'str'}, - 'hostname_configurations': {'key': 'properties.hostnameConfigurations', 'type': '[HostnameConfiguration]'}, - 'public_ip_addresses': {'key': 'properties.publicIPAddresses', 'type': '[str]'}, - 'private_ip_addresses': {'key': 'properties.privateIPAddresses', 'type': '[str]'}, - 'virtual_network_configuration': {'key': 'properties.virtualNetworkConfiguration', 'type': 'VirtualNetworkConfiguration'}, - 'additional_locations': {'key': 'properties.additionalLocations', 'type': '[AdditionalLocation]'}, - 'custom_properties': {'key': 'properties.customProperties', 'type': '{str}'}, - 'certificates': {'key': 'properties.certificates', 'type': '[CertificateConfiguration]'}, - 'enable_client_certificate': {'key': 'properties.enableClientCertificate', 'type': 'bool'}, - 'virtual_network_type': {'key': 'properties.virtualNetworkType', 'type': 'str'}, - 'publisher_email': {'key': 'properties.publisherEmail', 'type': 'str'}, - 'publisher_name': {'key': 'properties.publisherName', 'type': 'str'}, - 'sku': {'key': 'sku', 'type': 'ApiManagementServiceSkuProperties'}, - 'identity': {'key': 'identity', 'type': 'ApiManagementServiceIdentity'}, - 'etag': {'key': 'etag', 'type': 'str'}, - } - - def __init__(self, **kwargs): - super(ApiManagementServiceUpdateParameters, self).__init__(**kwargs) - self.notification_sender_email = kwargs.get('notification_sender_email', None) - self.provisioning_state = None - self.target_provisioning_state = None - self.created_at_utc = None - self.gateway_url = None - self.gateway_regional_url = None - self.portal_url = None - self.management_api_url = None - self.scm_url = None - self.hostname_configurations = kwargs.get('hostname_configurations', None) - self.public_ip_addresses = None - self.private_ip_addresses = None - self.virtual_network_configuration = kwargs.get('virtual_network_configuration', None) - self.additional_locations = kwargs.get('additional_locations', None) - self.custom_properties = kwargs.get('custom_properties', None) - self.certificates = kwargs.get('certificates', None) - self.enable_client_certificate = kwargs.get('enable_client_certificate', False) - self.virtual_network_type = kwargs.get('virtual_network_type', "None") - self.publisher_email = kwargs.get('publisher_email', None) - self.publisher_name = kwargs.get('publisher_name', None) - self.sku = kwargs.get('sku', None) - self.identity = kwargs.get('identity', None) - self.etag = None diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/api_management_service_update_parameters_py3.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/api_management_service_update_parameters_py3.py deleted file mode 100644 index 76a51b033344..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/api_management_service_update_parameters_py3.py +++ /dev/null @@ -1,198 +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 .apim_resource_py3 import ApimResource - - -class ApiManagementServiceUpdateParameters(ApimResource): - """Parameter supplied to Update Api Management Service. - - Variables are only populated by the server, and will be ignored when - sending a request. - - :ivar id: Resource ID. - :vartype id: str - :ivar name: Resource name. - :vartype name: str - :ivar type: Resource type for API Management resource is set to - Microsoft.ApiManagement. - :vartype type: str - :param tags: Resource tags. - :type tags: dict[str, str] - :param notification_sender_email: Email address from which the - notification will be sent. - :type notification_sender_email: str - :ivar provisioning_state: The current provisioning state of the API - Management service which can be one of the following: - Created/Activating/Succeeded/Updating/Failed/Stopped/Terminating/TerminationFailed/Deleted. - :vartype provisioning_state: str - :ivar target_provisioning_state: The provisioning state of the API - Management service, which is targeted by the long running operation - started on the service. - :vartype target_provisioning_state: str - :ivar created_at_utc: Creation UTC date of the API Management service.The - date conforms to the following format: `yyyy-MM-ddTHH:mm:ssZ` as specified - by the ISO 8601 standard. - :vartype created_at_utc: datetime - :ivar gateway_url: Gateway URL of the API Management service. - :vartype gateway_url: str - :ivar gateway_regional_url: Gateway URL of the API Management service in - the Default Region. - :vartype gateway_regional_url: str - :ivar portal_url: Publisher portal endpoint Url of the API Management - service. - :vartype portal_url: str - :ivar management_api_url: Management API endpoint URL of the API - Management service. - :vartype management_api_url: str - :ivar scm_url: SCM endpoint URL of the API Management service. - :vartype scm_url: str - :param hostname_configurations: Custom hostname configuration of the API - Management service. - :type hostname_configurations: - list[~azure.mgmt.apimanagement.models.HostnameConfiguration] - :ivar public_ip_addresses: Public Static Load Balanced IP addresses of the - API Management service in Primary region. Available only for Basic, - Standard and Premium SKU. - :vartype public_ip_addresses: list[str] - :ivar private_ip_addresses: Private Static Load Balanced IP addresses of - the API Management service in Primary region which is deployed in an - Internal Virtual Network. Available only for Basic, Standard and Premium - SKU. - :vartype private_ip_addresses: list[str] - :param virtual_network_configuration: Virtual network configuration of the - API Management service. - :type virtual_network_configuration: - ~azure.mgmt.apimanagement.models.VirtualNetworkConfiguration - :param additional_locations: Additional datacenter locations of the API - Management service. - :type additional_locations: - list[~azure.mgmt.apimanagement.models.AdditionalLocation] - :param custom_properties: Custom properties of the API Management service. - Setting - `Microsoft.WindowsAzure.ApiManagement.Gateway.Security.Ciphers.TripleDes168` - will disable the cipher TLS_RSA_WITH_3DES_EDE_CBC_SHA for all TLS(1.0, 1.1 - and 1.2). Setting - `Microsoft.WindowsAzure.ApiManagement.Gateway.Security.Protocols.Tls11` - can be used to disable just TLS 1.1 and setting - `Microsoft.WindowsAzure.ApiManagement.Gateway.Security.Protocols.Tls10` - can be used to disable TLS 1.0 on an API Management service. - :type custom_properties: dict[str, str] - :param certificates: List of Certificates that need to be installed in the - API Management service. Max supported certificates that can be installed - is 10. - :type certificates: - list[~azure.mgmt.apimanagement.models.CertificateConfiguration] - :param enable_client_certificate: Property only meant to be used for - Consumption SKU Service. This enforces a client certificate to be - presented on each request to the gateway. This also enables the ability to - authenticate the certificate in the policy on the gateway. Default value: - False . - :type enable_client_certificate: bool - :param virtual_network_type: The type of VPN in which API Management - service needs to be configured in. None (Default Value) means the API - Management service is not part of any Virtual Network, External means the - API Management deployment is set up inside a Virtual Network having an - Internet Facing Endpoint, and Internal means that API Management - deployment is setup inside a Virtual Network having an Intranet Facing - Endpoint only. Possible values include: 'None', 'External', 'Internal'. - Default value: "None" . - :type virtual_network_type: str or - ~azure.mgmt.apimanagement.models.VirtualNetworkType - :param publisher_email: Publisher email. - :type publisher_email: str - :param publisher_name: Publisher name. - :type publisher_name: str - :param sku: SKU properties of the API Management service. - :type sku: - ~azure.mgmt.apimanagement.models.ApiManagementServiceSkuProperties - :param identity: Managed service identity of the Api Management service. - :type identity: - ~azure.mgmt.apimanagement.models.ApiManagementServiceIdentity - :ivar etag: ETag of the resource. - :vartype etag: str - """ - - _validation = { - 'id': {'readonly': True}, - 'name': {'readonly': True}, - 'type': {'readonly': True}, - 'notification_sender_email': {'max_length': 100}, - 'provisioning_state': {'readonly': True}, - 'target_provisioning_state': {'readonly': True}, - 'created_at_utc': {'readonly': True}, - 'gateway_url': {'readonly': True}, - 'gateway_regional_url': {'readonly': True}, - 'portal_url': {'readonly': True}, - 'management_api_url': {'readonly': True}, - 'scm_url': {'readonly': True}, - 'public_ip_addresses': {'readonly': True}, - 'private_ip_addresses': {'readonly': True}, - 'publisher_email': {'max_length': 100}, - 'publisher_name': {'max_length': 100}, - 'etag': {'readonly': True}, - } - - _attribute_map = { - 'id': {'key': 'id', 'type': 'str'}, - 'name': {'key': 'name', 'type': 'str'}, - 'type': {'key': 'type', 'type': 'str'}, - 'tags': {'key': 'tags', 'type': '{str}'}, - 'notification_sender_email': {'key': 'properties.notificationSenderEmail', 'type': 'str'}, - 'provisioning_state': {'key': 'properties.provisioningState', 'type': 'str'}, - 'target_provisioning_state': {'key': 'properties.targetProvisioningState', 'type': 'str'}, - 'created_at_utc': {'key': 'properties.createdAtUtc', 'type': 'iso-8601'}, - 'gateway_url': {'key': 'properties.gatewayUrl', 'type': 'str'}, - 'gateway_regional_url': {'key': 'properties.gatewayRegionalUrl', 'type': 'str'}, - 'portal_url': {'key': 'properties.portalUrl', 'type': 'str'}, - 'management_api_url': {'key': 'properties.managementApiUrl', 'type': 'str'}, - 'scm_url': {'key': 'properties.scmUrl', 'type': 'str'}, - 'hostname_configurations': {'key': 'properties.hostnameConfigurations', 'type': '[HostnameConfiguration]'}, - 'public_ip_addresses': {'key': 'properties.publicIPAddresses', 'type': '[str]'}, - 'private_ip_addresses': {'key': 'properties.privateIPAddresses', 'type': '[str]'}, - 'virtual_network_configuration': {'key': 'properties.virtualNetworkConfiguration', 'type': 'VirtualNetworkConfiguration'}, - 'additional_locations': {'key': 'properties.additionalLocations', 'type': '[AdditionalLocation]'}, - 'custom_properties': {'key': 'properties.customProperties', 'type': '{str}'}, - 'certificates': {'key': 'properties.certificates', 'type': '[CertificateConfiguration]'}, - 'enable_client_certificate': {'key': 'properties.enableClientCertificate', 'type': 'bool'}, - 'virtual_network_type': {'key': 'properties.virtualNetworkType', 'type': 'str'}, - 'publisher_email': {'key': 'properties.publisherEmail', 'type': 'str'}, - 'publisher_name': {'key': 'properties.publisherName', 'type': 'str'}, - 'sku': {'key': 'sku', 'type': 'ApiManagementServiceSkuProperties'}, - 'identity': {'key': 'identity', 'type': 'ApiManagementServiceIdentity'}, - 'etag': {'key': 'etag', 'type': 'str'}, - } - - def __init__(self, *, tags=None, notification_sender_email: str=None, hostname_configurations=None, virtual_network_configuration=None, additional_locations=None, custom_properties=None, certificates=None, enable_client_certificate: bool=False, virtual_network_type="None", publisher_email: str=None, publisher_name: str=None, sku=None, identity=None, **kwargs) -> None: - super(ApiManagementServiceUpdateParameters, self).__init__(tags=tags, **kwargs) - self.notification_sender_email = notification_sender_email - self.provisioning_state = None - self.target_provisioning_state = None - self.created_at_utc = None - self.gateway_url = None - self.gateway_regional_url = None - self.portal_url = None - self.management_api_url = None - self.scm_url = None - self.hostname_configurations = hostname_configurations - self.public_ip_addresses = None - self.private_ip_addresses = None - self.virtual_network_configuration = virtual_network_configuration - self.additional_locations = additional_locations - self.custom_properties = custom_properties - self.certificates = certificates - self.enable_client_certificate = enable_client_certificate - self.virtual_network_type = virtual_network_type - self.publisher_email = publisher_email - self.publisher_name = publisher_name - self.sku = sku - self.identity = identity - self.etag = None diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/api_release_contract.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/api_release_contract.py deleted file mode 100644 index 4e04b6c68964..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/api_release_contract.py +++ /dev/null @@ -1,62 +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 .resource import Resource - - -class ApiReleaseContract(Resource): - """ApiRelease details. - - Variables are only populated by the server, and will be ignored when - sending a request. - - :ivar id: Resource ID. - :vartype id: str - :ivar name: Resource name. - :vartype name: str - :ivar type: Resource type for API Management resource. - :vartype type: str - :param api_id: Identifier of the API the release belongs to. - :type api_id: str - :ivar created_date_time: The time the API was released. The date conforms - to the following format: yyyy-MM-ddTHH:mm:ssZ as specified by the ISO 8601 - standard. - :vartype created_date_time: datetime - :ivar updated_date_time: The time the API release was updated. - :vartype updated_date_time: datetime - :param notes: Release Notes - :type notes: str - """ - - _validation = { - 'id': {'readonly': True}, - 'name': {'readonly': True}, - 'type': {'readonly': True}, - 'created_date_time': {'readonly': True}, - 'updated_date_time': {'readonly': True}, - } - - _attribute_map = { - 'id': {'key': 'id', 'type': 'str'}, - 'name': {'key': 'name', 'type': 'str'}, - 'type': {'key': 'type', 'type': 'str'}, - 'api_id': {'key': 'properties.apiId', 'type': 'str'}, - 'created_date_time': {'key': 'properties.createdDateTime', 'type': 'iso-8601'}, - 'updated_date_time': {'key': 'properties.updatedDateTime', 'type': 'iso-8601'}, - 'notes': {'key': 'properties.notes', 'type': 'str'}, - } - - def __init__(self, **kwargs): - super(ApiReleaseContract, self).__init__(**kwargs) - self.api_id = kwargs.get('api_id', None) - self.created_date_time = None - self.updated_date_time = None - self.notes = kwargs.get('notes', None) diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/api_release_contract_paged.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/api_release_contract_paged.py deleted file mode 100644 index f95ad2334f66..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/api_release_contract_paged.py +++ /dev/null @@ -1,27 +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.paging import Paged - - -class ApiReleaseContractPaged(Paged): - """ - A paging container for iterating over a list of :class:`ApiReleaseContract ` object - """ - - _attribute_map = { - 'next_link': {'key': 'nextLink', 'type': 'str'}, - 'current_page': {'key': 'value', 'type': '[ApiReleaseContract]'} - } - - def __init__(self, *args, **kwargs): - - super(ApiReleaseContractPaged, self).__init__(*args, **kwargs) diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/api_release_contract_py3.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/api_release_contract_py3.py deleted file mode 100644 index 8792997dfc41..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/api_release_contract_py3.py +++ /dev/null @@ -1,62 +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 .resource_py3 import Resource - - -class ApiReleaseContract(Resource): - """ApiRelease details. - - Variables are only populated by the server, and will be ignored when - sending a request. - - :ivar id: Resource ID. - :vartype id: str - :ivar name: Resource name. - :vartype name: str - :ivar type: Resource type for API Management resource. - :vartype type: str - :param api_id: Identifier of the API the release belongs to. - :type api_id: str - :ivar created_date_time: The time the API was released. The date conforms - to the following format: yyyy-MM-ddTHH:mm:ssZ as specified by the ISO 8601 - standard. - :vartype created_date_time: datetime - :ivar updated_date_time: The time the API release was updated. - :vartype updated_date_time: datetime - :param notes: Release Notes - :type notes: str - """ - - _validation = { - 'id': {'readonly': True}, - 'name': {'readonly': True}, - 'type': {'readonly': True}, - 'created_date_time': {'readonly': True}, - 'updated_date_time': {'readonly': True}, - } - - _attribute_map = { - 'id': {'key': 'id', 'type': 'str'}, - 'name': {'key': 'name', 'type': 'str'}, - 'type': {'key': 'type', 'type': 'str'}, - 'api_id': {'key': 'properties.apiId', 'type': 'str'}, - 'created_date_time': {'key': 'properties.createdDateTime', 'type': 'iso-8601'}, - 'updated_date_time': {'key': 'properties.updatedDateTime', 'type': 'iso-8601'}, - 'notes': {'key': 'properties.notes', 'type': 'str'}, - } - - def __init__(self, *, api_id: str=None, notes: str=None, **kwargs) -> None: - super(ApiReleaseContract, self).__init__(**kwargs) - self.api_id = api_id - self.created_date_time = None - self.updated_date_time = None - self.notes = notes diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/api_revision_contract.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/api_revision_contract.py deleted file mode 100644 index 8ee1788c315a..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/api_revision_contract.py +++ /dev/null @@ -1,74 +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 ApiRevisionContract(Model): - """Summary of revision metadata. - - Variables are only populated by the server, and will be ignored when - sending a request. - - :ivar api_id: Identifier of the API Revision. - :vartype api_id: str - :ivar api_revision: Revision number of API. - :vartype api_revision: str - :ivar created_date_time: The time the API Revision was created. The date - conforms to the following format: yyyy-MM-ddTHH:mm:ssZ as specified by the - ISO 8601 standard. - :vartype created_date_time: datetime - :ivar updated_date_time: The time the API Revision were updated. The date - conforms to the following format: yyyy-MM-ddTHH:mm:ssZ as specified by the - ISO 8601 standard. - :vartype updated_date_time: datetime - :ivar description: Description of the API Revision. - :vartype description: str - :ivar private_url: Gateway URL for accessing the non-current API Revision. - :vartype private_url: str - :ivar is_online: Indicates if API revision is the current api revision. - :vartype is_online: bool - :ivar is_current: Indicates if API revision is accessible via the gateway. - :vartype is_current: bool - """ - - _validation = { - 'api_id': {'readonly': True}, - 'api_revision': {'readonly': True, 'max_length': 100, 'min_length': 1}, - 'created_date_time': {'readonly': True}, - 'updated_date_time': {'readonly': True}, - 'description': {'readonly': True, 'max_length': 256}, - 'private_url': {'readonly': True}, - 'is_online': {'readonly': True}, - 'is_current': {'readonly': True}, - } - - _attribute_map = { - 'api_id': {'key': 'apiId', 'type': 'str'}, - 'api_revision': {'key': 'apiRevision', 'type': 'str'}, - 'created_date_time': {'key': 'createdDateTime', 'type': 'iso-8601'}, - 'updated_date_time': {'key': 'updatedDateTime', 'type': 'iso-8601'}, - 'description': {'key': 'description', 'type': 'str'}, - 'private_url': {'key': 'privateUrl', 'type': 'str'}, - 'is_online': {'key': 'isOnline', 'type': 'bool'}, - 'is_current': {'key': 'isCurrent', 'type': 'bool'}, - } - - def __init__(self, **kwargs): - super(ApiRevisionContract, self).__init__(**kwargs) - self.api_id = None - self.api_revision = None - self.created_date_time = None - self.updated_date_time = None - self.description = None - self.private_url = None - self.is_online = None - self.is_current = None diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/api_revision_contract_paged.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/api_revision_contract_paged.py deleted file mode 100644 index 1cc0fe483079..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/api_revision_contract_paged.py +++ /dev/null @@ -1,27 +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.paging import Paged - - -class ApiRevisionContractPaged(Paged): - """ - A paging container for iterating over a list of :class:`ApiRevisionContract ` object - """ - - _attribute_map = { - 'next_link': {'key': 'nextLink', 'type': 'str'}, - 'current_page': {'key': 'value', 'type': '[ApiRevisionContract]'} - } - - def __init__(self, *args, **kwargs): - - super(ApiRevisionContractPaged, self).__init__(*args, **kwargs) diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/api_revision_contract_py3.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/api_revision_contract_py3.py deleted file mode 100644 index a3b4f9892094..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/api_revision_contract_py3.py +++ /dev/null @@ -1,74 +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 ApiRevisionContract(Model): - """Summary of revision metadata. - - Variables are only populated by the server, and will be ignored when - sending a request. - - :ivar api_id: Identifier of the API Revision. - :vartype api_id: str - :ivar api_revision: Revision number of API. - :vartype api_revision: str - :ivar created_date_time: The time the API Revision was created. The date - conforms to the following format: yyyy-MM-ddTHH:mm:ssZ as specified by the - ISO 8601 standard. - :vartype created_date_time: datetime - :ivar updated_date_time: The time the API Revision were updated. The date - conforms to the following format: yyyy-MM-ddTHH:mm:ssZ as specified by the - ISO 8601 standard. - :vartype updated_date_time: datetime - :ivar description: Description of the API Revision. - :vartype description: str - :ivar private_url: Gateway URL for accessing the non-current API Revision. - :vartype private_url: str - :ivar is_online: Indicates if API revision is the current api revision. - :vartype is_online: bool - :ivar is_current: Indicates if API revision is accessible via the gateway. - :vartype is_current: bool - """ - - _validation = { - 'api_id': {'readonly': True}, - 'api_revision': {'readonly': True, 'max_length': 100, 'min_length': 1}, - 'created_date_time': {'readonly': True}, - 'updated_date_time': {'readonly': True}, - 'description': {'readonly': True, 'max_length': 256}, - 'private_url': {'readonly': True}, - 'is_online': {'readonly': True}, - 'is_current': {'readonly': True}, - } - - _attribute_map = { - 'api_id': {'key': 'apiId', 'type': 'str'}, - 'api_revision': {'key': 'apiRevision', 'type': 'str'}, - 'created_date_time': {'key': 'createdDateTime', 'type': 'iso-8601'}, - 'updated_date_time': {'key': 'updatedDateTime', 'type': 'iso-8601'}, - 'description': {'key': 'description', 'type': 'str'}, - 'private_url': {'key': 'privateUrl', 'type': 'str'}, - 'is_online': {'key': 'isOnline', 'type': 'bool'}, - 'is_current': {'key': 'isCurrent', 'type': 'bool'}, - } - - def __init__(self, **kwargs) -> None: - super(ApiRevisionContract, self).__init__(**kwargs) - self.api_id = None - self.api_revision = None - self.created_date_time = None - self.updated_date_time = None - self.description = None - self.private_url = None - self.is_online = None - self.is_current = None diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/api_revision_info_contract.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/api_revision_info_contract.py deleted file mode 100644 index f134492b1db3..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/api_revision_info_contract.py +++ /dev/null @@ -1,48 +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 ApiRevisionInfoContract(Model): - """Object used to create an API Revision or Version based on an existing API - Revision. - - :param source_api_id: Resource identifier of API to be used to create the - revision from. - :type source_api_id: str - :param api_version_name: Version identifier for the new API Version. - :type api_version_name: str - :param api_revision_description: Description of new API Revision. - :type api_revision_description: str - :param api_version_set: Version set details - :type api_version_set: - ~azure.mgmt.apimanagement.models.ApiVersionSetContractDetails - """ - - _validation = { - 'api_version_name': {'max_length': 100}, - 'api_revision_description': {'max_length': 256}, - } - - _attribute_map = { - 'source_api_id': {'key': 'sourceApiId', 'type': 'str'}, - 'api_version_name': {'key': 'apiVersionName', 'type': 'str'}, - 'api_revision_description': {'key': 'apiRevisionDescription', 'type': 'str'}, - 'api_version_set': {'key': 'apiVersionSet', 'type': 'ApiVersionSetContractDetails'}, - } - - def __init__(self, **kwargs): - super(ApiRevisionInfoContract, self).__init__(**kwargs) - self.source_api_id = kwargs.get('source_api_id', None) - self.api_version_name = kwargs.get('api_version_name', None) - self.api_revision_description = kwargs.get('api_revision_description', None) - self.api_version_set = kwargs.get('api_version_set', None) diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/api_revision_info_contract_py3.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/api_revision_info_contract_py3.py deleted file mode 100644 index 7f2ccaed2b0e..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/api_revision_info_contract_py3.py +++ /dev/null @@ -1,48 +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 ApiRevisionInfoContract(Model): - """Object used to create an API Revision or Version based on an existing API - Revision. - - :param source_api_id: Resource identifier of API to be used to create the - revision from. - :type source_api_id: str - :param api_version_name: Version identifier for the new API Version. - :type api_version_name: str - :param api_revision_description: Description of new API Revision. - :type api_revision_description: str - :param api_version_set: Version set details - :type api_version_set: - ~azure.mgmt.apimanagement.models.ApiVersionSetContractDetails - """ - - _validation = { - 'api_version_name': {'max_length': 100}, - 'api_revision_description': {'max_length': 256}, - } - - _attribute_map = { - 'source_api_id': {'key': 'sourceApiId', 'type': 'str'}, - 'api_version_name': {'key': 'apiVersionName', 'type': 'str'}, - 'api_revision_description': {'key': 'apiRevisionDescription', 'type': 'str'}, - 'api_version_set': {'key': 'apiVersionSet', 'type': 'ApiVersionSetContractDetails'}, - } - - def __init__(self, *, source_api_id: str=None, api_version_name: str=None, api_revision_description: str=None, api_version_set=None, **kwargs) -> None: - super(ApiRevisionInfoContract, self).__init__(**kwargs) - self.source_api_id = source_api_id - self.api_version_name = api_version_name - self.api_revision_description = api_revision_description - self.api_version_set = api_version_set diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/api_tag_resource_contract_properties.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/api_tag_resource_contract_properties.py deleted file mode 100644 index ea0e43b2d27b..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/api_tag_resource_contract_properties.py +++ /dev/null @@ -1,108 +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 .api_entity_base_contract import ApiEntityBaseContract - - -class ApiTagResourceContractProperties(ApiEntityBaseContract): - """API contract properties for the Tag Resources. - - Variables are only populated by the server, and will be ignored when - sending a request. - - :param description: Description of the API. May include HTML formatting - tags. - :type description: str - :param authentication_settings: Collection of authentication settings - included into this API. - :type authentication_settings: - ~azure.mgmt.apimanagement.models.AuthenticationSettingsContract - :param subscription_key_parameter_names: Protocols over which API is made - available. - :type subscription_key_parameter_names: - ~azure.mgmt.apimanagement.models.SubscriptionKeyParameterNamesContract - :param api_type: Type of API. Possible values include: 'http', 'soap' - :type api_type: str or ~azure.mgmt.apimanagement.models.ApiType - :param api_revision: Describes the Revision of the Api. If no value is - provided, default revision 1 is created - :type api_revision: str - :param api_version: Indicates the Version identifier of the API if the API - is versioned - :type api_version: str - :param is_current: Indicates if API revision is current api revision. - :type is_current: bool - :ivar is_online: Indicates if API revision is accessible via the gateway. - :vartype is_online: bool - :param api_revision_description: Description of the Api Revision. - :type api_revision_description: str - :param api_version_description: Description of the Api Version. - :type api_version_description: str - :param api_version_set_id: A resource identifier for the related - ApiVersionSet. - :type api_version_set_id: str - :param subscription_required: Specifies whether an API or Product - subscription is required for accessing the API. - :type subscription_required: bool - :param id: API identifier in the form /apis/{apiId}. - :type id: str - :param name: API name. - :type name: str - :param service_url: Absolute URL of the backend service implementing this - API. - :type service_url: str - :param path: Relative URL uniquely identifying this API and all of its - resource paths within the API Management service instance. It is appended - to the API endpoint base URL specified during the service instance - creation to form a public URL for this API. - :type path: str - :param protocols: Describes on which protocols the operations in this API - can be invoked. - :type protocols: list[str or ~azure.mgmt.apimanagement.models.Protocol] - """ - - _validation = { - 'api_revision': {'max_length': 100, 'min_length': 1}, - 'api_version': {'max_length': 100}, - 'is_online': {'readonly': True}, - 'api_revision_description': {'max_length': 256}, - 'api_version_description': {'max_length': 256}, - 'name': {'max_length': 300, 'min_length': 1}, - 'service_url': {'max_length': 2000, 'min_length': 1}, - 'path': {'max_length': 400, 'min_length': 0}, - } - - _attribute_map = { - 'description': {'key': 'description', 'type': 'str'}, - 'authentication_settings': {'key': 'authenticationSettings', 'type': 'AuthenticationSettingsContract'}, - 'subscription_key_parameter_names': {'key': 'subscriptionKeyParameterNames', 'type': 'SubscriptionKeyParameterNamesContract'}, - 'api_type': {'key': 'type', 'type': 'str'}, - 'api_revision': {'key': 'apiRevision', 'type': 'str'}, - 'api_version': {'key': 'apiVersion', 'type': 'str'}, - 'is_current': {'key': 'isCurrent', 'type': 'bool'}, - 'is_online': {'key': 'isOnline', 'type': 'bool'}, - 'api_revision_description': {'key': 'apiRevisionDescription', 'type': 'str'}, - 'api_version_description': {'key': 'apiVersionDescription', 'type': 'str'}, - 'api_version_set_id': {'key': 'apiVersionSetId', 'type': 'str'}, - 'subscription_required': {'key': 'subscriptionRequired', 'type': 'bool'}, - 'id': {'key': 'id', 'type': 'str'}, - 'name': {'key': 'name', 'type': 'str'}, - 'service_url': {'key': 'serviceUrl', 'type': 'str'}, - 'path': {'key': 'path', 'type': 'str'}, - 'protocols': {'key': 'protocols', 'type': '[Protocol]'}, - } - - def __init__(self, **kwargs): - super(ApiTagResourceContractProperties, self).__init__(**kwargs) - self.id = kwargs.get('id', None) - self.name = kwargs.get('name', None) - self.service_url = kwargs.get('service_url', None) - self.path = kwargs.get('path', None) - self.protocols = kwargs.get('protocols', None) diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/api_tag_resource_contract_properties_py3.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/api_tag_resource_contract_properties_py3.py deleted file mode 100644 index 67cc11942a42..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/api_tag_resource_contract_properties_py3.py +++ /dev/null @@ -1,108 +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 .api_entity_base_contract_py3 import ApiEntityBaseContract - - -class ApiTagResourceContractProperties(ApiEntityBaseContract): - """API contract properties for the Tag Resources. - - Variables are only populated by the server, and will be ignored when - sending a request. - - :param description: Description of the API. May include HTML formatting - tags. - :type description: str - :param authentication_settings: Collection of authentication settings - included into this API. - :type authentication_settings: - ~azure.mgmt.apimanagement.models.AuthenticationSettingsContract - :param subscription_key_parameter_names: Protocols over which API is made - available. - :type subscription_key_parameter_names: - ~azure.mgmt.apimanagement.models.SubscriptionKeyParameterNamesContract - :param api_type: Type of API. Possible values include: 'http', 'soap' - :type api_type: str or ~azure.mgmt.apimanagement.models.ApiType - :param api_revision: Describes the Revision of the Api. If no value is - provided, default revision 1 is created - :type api_revision: str - :param api_version: Indicates the Version identifier of the API if the API - is versioned - :type api_version: str - :param is_current: Indicates if API revision is current api revision. - :type is_current: bool - :ivar is_online: Indicates if API revision is accessible via the gateway. - :vartype is_online: bool - :param api_revision_description: Description of the Api Revision. - :type api_revision_description: str - :param api_version_description: Description of the Api Version. - :type api_version_description: str - :param api_version_set_id: A resource identifier for the related - ApiVersionSet. - :type api_version_set_id: str - :param subscription_required: Specifies whether an API or Product - subscription is required for accessing the API. - :type subscription_required: bool - :param id: API identifier in the form /apis/{apiId}. - :type id: str - :param name: API name. - :type name: str - :param service_url: Absolute URL of the backend service implementing this - API. - :type service_url: str - :param path: Relative URL uniquely identifying this API and all of its - resource paths within the API Management service instance. It is appended - to the API endpoint base URL specified during the service instance - creation to form a public URL for this API. - :type path: str - :param protocols: Describes on which protocols the operations in this API - can be invoked. - :type protocols: list[str or ~azure.mgmt.apimanagement.models.Protocol] - """ - - _validation = { - 'api_revision': {'max_length': 100, 'min_length': 1}, - 'api_version': {'max_length': 100}, - 'is_online': {'readonly': True}, - 'api_revision_description': {'max_length': 256}, - 'api_version_description': {'max_length': 256}, - 'name': {'max_length': 300, 'min_length': 1}, - 'service_url': {'max_length': 2000, 'min_length': 1}, - 'path': {'max_length': 400, 'min_length': 0}, - } - - _attribute_map = { - 'description': {'key': 'description', 'type': 'str'}, - 'authentication_settings': {'key': 'authenticationSettings', 'type': 'AuthenticationSettingsContract'}, - 'subscription_key_parameter_names': {'key': 'subscriptionKeyParameterNames', 'type': 'SubscriptionKeyParameterNamesContract'}, - 'api_type': {'key': 'type', 'type': 'str'}, - 'api_revision': {'key': 'apiRevision', 'type': 'str'}, - 'api_version': {'key': 'apiVersion', 'type': 'str'}, - 'is_current': {'key': 'isCurrent', 'type': 'bool'}, - 'is_online': {'key': 'isOnline', 'type': 'bool'}, - 'api_revision_description': {'key': 'apiRevisionDescription', 'type': 'str'}, - 'api_version_description': {'key': 'apiVersionDescription', 'type': 'str'}, - 'api_version_set_id': {'key': 'apiVersionSetId', 'type': 'str'}, - 'subscription_required': {'key': 'subscriptionRequired', 'type': 'bool'}, - 'id': {'key': 'id', 'type': 'str'}, - 'name': {'key': 'name', 'type': 'str'}, - 'service_url': {'key': 'serviceUrl', 'type': 'str'}, - 'path': {'key': 'path', 'type': 'str'}, - 'protocols': {'key': 'protocols', 'type': '[Protocol]'}, - } - - def __init__(self, *, description: str=None, authentication_settings=None, subscription_key_parameter_names=None, api_type=None, api_revision: str=None, api_version: str=None, is_current: bool=None, api_revision_description: str=None, api_version_description: str=None, api_version_set_id: str=None, subscription_required: bool=None, id: str=None, name: str=None, service_url: str=None, path: str=None, protocols=None, **kwargs) -> None: - super(ApiTagResourceContractProperties, self).__init__(description=description, authentication_settings=authentication_settings, subscription_key_parameter_names=subscription_key_parameter_names, api_type=api_type, api_revision=api_revision, api_version=api_version, is_current=is_current, api_revision_description=api_revision_description, api_version_description=api_version_description, api_version_set_id=api_version_set_id, subscription_required=subscription_required, **kwargs) - self.id = id - self.name = name - self.service_url = service_url - self.path = path - self.protocols = protocols diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/api_update_contract.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/api_update_contract.py deleted file mode 100644 index 16538edb5451..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/api_update_contract.py +++ /dev/null @@ -1,116 +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 ApiUpdateContract(Model): - """API update contract details. - - Variables are only populated by the server, and will be ignored when - sending a request. - - :param description: Description of the API. May include HTML formatting - tags. - :type description: str - :param authentication_settings: Collection of authentication settings - included into this API. - :type authentication_settings: - ~azure.mgmt.apimanagement.models.AuthenticationSettingsContract - :param subscription_key_parameter_names: Protocols over which API is made - available. - :type subscription_key_parameter_names: - ~azure.mgmt.apimanagement.models.SubscriptionKeyParameterNamesContract - :param api_type: Type of API. Possible values include: 'http', 'soap' - :type api_type: str or ~azure.mgmt.apimanagement.models.ApiType - :param api_revision: Describes the Revision of the Api. If no value is - provided, default revision 1 is created - :type api_revision: str - :param api_version: Indicates the Version identifier of the API if the API - is versioned - :type api_version: str - :param is_current: Indicates if API revision is current api revision. - :type is_current: bool - :ivar is_online: Indicates if API revision is accessible via the gateway. - :vartype is_online: bool - :param api_revision_description: Description of the Api Revision. - :type api_revision_description: str - :param api_version_description: Description of the Api Version. - :type api_version_description: str - :param api_version_set_id: A resource identifier for the related - ApiVersionSet. - :type api_version_set_id: str - :param subscription_required: Specifies whether an API or Product - subscription is required for accessing the API. - :type subscription_required: bool - :param display_name: API name. - :type display_name: str - :param service_url: Absolute URL of the backend service implementing this - API. - :type service_url: str - :param path: Relative URL uniquely identifying this API and all of its - resource paths within the API Management service instance. It is appended - to the API endpoint base URL specified during the service instance - creation to form a public URL for this API. - :type path: str - :param protocols: Describes on which protocols the operations in this API - can be invoked. - :type protocols: list[str or ~azure.mgmt.apimanagement.models.Protocol] - """ - - _validation = { - 'api_revision': {'max_length': 100, 'min_length': 1}, - 'api_version': {'max_length': 100}, - 'is_online': {'readonly': True}, - 'api_revision_description': {'max_length': 256}, - 'api_version_description': {'max_length': 256}, - 'display_name': {'max_length': 300, 'min_length': 1}, - 'service_url': {'max_length': 2000, 'min_length': 1}, - 'path': {'max_length': 400, 'min_length': 0}, - } - - _attribute_map = { - 'description': {'key': 'properties.description', 'type': 'str'}, - 'authentication_settings': {'key': 'properties.authenticationSettings', 'type': 'AuthenticationSettingsContract'}, - 'subscription_key_parameter_names': {'key': 'properties.subscriptionKeyParameterNames', 'type': 'SubscriptionKeyParameterNamesContract'}, - 'api_type': {'key': 'properties.type', 'type': 'str'}, - 'api_revision': {'key': 'properties.apiRevision', 'type': 'str'}, - 'api_version': {'key': 'properties.apiVersion', 'type': 'str'}, - 'is_current': {'key': 'properties.isCurrent', 'type': 'bool'}, - 'is_online': {'key': 'properties.isOnline', 'type': 'bool'}, - 'api_revision_description': {'key': 'properties.apiRevisionDescription', 'type': 'str'}, - 'api_version_description': {'key': 'properties.apiVersionDescription', 'type': 'str'}, - 'api_version_set_id': {'key': 'properties.apiVersionSetId', 'type': 'str'}, - 'subscription_required': {'key': 'properties.subscriptionRequired', 'type': 'bool'}, - 'display_name': {'key': 'properties.displayName', 'type': 'str'}, - 'service_url': {'key': 'properties.serviceUrl', 'type': 'str'}, - 'path': {'key': 'properties.path', 'type': 'str'}, - 'protocols': {'key': 'properties.protocols', 'type': '[Protocol]'}, - } - - def __init__(self, **kwargs): - super(ApiUpdateContract, self).__init__(**kwargs) - self.description = kwargs.get('description', None) - self.authentication_settings = kwargs.get('authentication_settings', None) - self.subscription_key_parameter_names = kwargs.get('subscription_key_parameter_names', None) - self.api_type = kwargs.get('api_type', None) - self.api_revision = kwargs.get('api_revision', None) - self.api_version = kwargs.get('api_version', None) - self.is_current = kwargs.get('is_current', None) - self.is_online = None - self.api_revision_description = kwargs.get('api_revision_description', None) - self.api_version_description = kwargs.get('api_version_description', None) - self.api_version_set_id = kwargs.get('api_version_set_id', None) - self.subscription_required = kwargs.get('subscription_required', None) - self.display_name = kwargs.get('display_name', None) - self.service_url = kwargs.get('service_url', None) - self.path = kwargs.get('path', None) - self.protocols = kwargs.get('protocols', None) diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/api_update_contract_py3.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/api_update_contract_py3.py deleted file mode 100644 index c9c8736900a7..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/api_update_contract_py3.py +++ /dev/null @@ -1,116 +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 ApiUpdateContract(Model): - """API update contract details. - - Variables are only populated by the server, and will be ignored when - sending a request. - - :param description: Description of the API. May include HTML formatting - tags. - :type description: str - :param authentication_settings: Collection of authentication settings - included into this API. - :type authentication_settings: - ~azure.mgmt.apimanagement.models.AuthenticationSettingsContract - :param subscription_key_parameter_names: Protocols over which API is made - available. - :type subscription_key_parameter_names: - ~azure.mgmt.apimanagement.models.SubscriptionKeyParameterNamesContract - :param api_type: Type of API. Possible values include: 'http', 'soap' - :type api_type: str or ~azure.mgmt.apimanagement.models.ApiType - :param api_revision: Describes the Revision of the Api. If no value is - provided, default revision 1 is created - :type api_revision: str - :param api_version: Indicates the Version identifier of the API if the API - is versioned - :type api_version: str - :param is_current: Indicates if API revision is current api revision. - :type is_current: bool - :ivar is_online: Indicates if API revision is accessible via the gateway. - :vartype is_online: bool - :param api_revision_description: Description of the Api Revision. - :type api_revision_description: str - :param api_version_description: Description of the Api Version. - :type api_version_description: str - :param api_version_set_id: A resource identifier for the related - ApiVersionSet. - :type api_version_set_id: str - :param subscription_required: Specifies whether an API or Product - subscription is required for accessing the API. - :type subscription_required: bool - :param display_name: API name. - :type display_name: str - :param service_url: Absolute URL of the backend service implementing this - API. - :type service_url: str - :param path: Relative URL uniquely identifying this API and all of its - resource paths within the API Management service instance. It is appended - to the API endpoint base URL specified during the service instance - creation to form a public URL for this API. - :type path: str - :param protocols: Describes on which protocols the operations in this API - can be invoked. - :type protocols: list[str or ~azure.mgmt.apimanagement.models.Protocol] - """ - - _validation = { - 'api_revision': {'max_length': 100, 'min_length': 1}, - 'api_version': {'max_length': 100}, - 'is_online': {'readonly': True}, - 'api_revision_description': {'max_length': 256}, - 'api_version_description': {'max_length': 256}, - 'display_name': {'max_length': 300, 'min_length': 1}, - 'service_url': {'max_length': 2000, 'min_length': 1}, - 'path': {'max_length': 400, 'min_length': 0}, - } - - _attribute_map = { - 'description': {'key': 'properties.description', 'type': 'str'}, - 'authentication_settings': {'key': 'properties.authenticationSettings', 'type': 'AuthenticationSettingsContract'}, - 'subscription_key_parameter_names': {'key': 'properties.subscriptionKeyParameterNames', 'type': 'SubscriptionKeyParameterNamesContract'}, - 'api_type': {'key': 'properties.type', 'type': 'str'}, - 'api_revision': {'key': 'properties.apiRevision', 'type': 'str'}, - 'api_version': {'key': 'properties.apiVersion', 'type': 'str'}, - 'is_current': {'key': 'properties.isCurrent', 'type': 'bool'}, - 'is_online': {'key': 'properties.isOnline', 'type': 'bool'}, - 'api_revision_description': {'key': 'properties.apiRevisionDescription', 'type': 'str'}, - 'api_version_description': {'key': 'properties.apiVersionDescription', 'type': 'str'}, - 'api_version_set_id': {'key': 'properties.apiVersionSetId', 'type': 'str'}, - 'subscription_required': {'key': 'properties.subscriptionRequired', 'type': 'bool'}, - 'display_name': {'key': 'properties.displayName', 'type': 'str'}, - 'service_url': {'key': 'properties.serviceUrl', 'type': 'str'}, - 'path': {'key': 'properties.path', 'type': 'str'}, - 'protocols': {'key': 'properties.protocols', 'type': '[Protocol]'}, - } - - def __init__(self, *, description: str=None, authentication_settings=None, subscription_key_parameter_names=None, api_type=None, api_revision: str=None, api_version: str=None, is_current: bool=None, api_revision_description: str=None, api_version_description: str=None, api_version_set_id: str=None, subscription_required: bool=None, display_name: str=None, service_url: str=None, path: str=None, protocols=None, **kwargs) -> None: - super(ApiUpdateContract, self).__init__(**kwargs) - self.description = description - self.authentication_settings = authentication_settings - self.subscription_key_parameter_names = subscription_key_parameter_names - self.api_type = api_type - self.api_revision = api_revision - self.api_version = api_version - self.is_current = is_current - self.is_online = None - self.api_revision_description = api_revision_description - self.api_version_description = api_version_description - self.api_version_set_id = api_version_set_id - self.subscription_required = subscription_required - self.display_name = display_name - self.service_url = service_url - self.path = path - self.protocols = protocols diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/api_version_set_contract.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/api_version_set_contract.py deleted file mode 100644 index 841221ab5ca4..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/api_version_set_contract.py +++ /dev/null @@ -1,73 +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 .resource import Resource - - -class ApiVersionSetContract(Resource): - """Api Version Set Contract details. - - Variables are only populated by the server, and will be ignored when - sending a request. - - All required parameters must be populated in order to send to Azure. - - :ivar id: Resource ID. - :vartype id: str - :ivar name: Resource name. - :vartype name: str - :ivar type: Resource type for API Management resource. - :vartype type: str - :param description: Description of API Version Set. - :type description: str - :param version_query_name: Name of query parameter that indicates the API - Version if versioningScheme is set to `query`. - :type version_query_name: str - :param version_header_name: Name of HTTP header parameter that indicates - the API Version if versioningScheme is set to `header`. - :type version_header_name: str - :param display_name: Required. Name of API Version Set - :type display_name: str - :param versioning_scheme: Required. An value that determines where the API - Version identifer will be located in a HTTP request. Possible values - include: 'Segment', 'Query', 'Header' - :type versioning_scheme: str or - ~azure.mgmt.apimanagement.models.VersioningScheme - """ - - _validation = { - 'id': {'readonly': True}, - 'name': {'readonly': True}, - 'type': {'readonly': True}, - 'version_query_name': {'max_length': 100, 'min_length': 1}, - 'version_header_name': {'max_length': 100, 'min_length': 1}, - 'display_name': {'required': True, 'max_length': 100, 'min_length': 1}, - 'versioning_scheme': {'required': True}, - } - - _attribute_map = { - 'id': {'key': 'id', 'type': 'str'}, - 'name': {'key': 'name', 'type': 'str'}, - 'type': {'key': 'type', 'type': 'str'}, - 'description': {'key': 'properties.description', 'type': 'str'}, - 'version_query_name': {'key': 'properties.versionQueryName', 'type': 'str'}, - 'version_header_name': {'key': 'properties.versionHeaderName', 'type': 'str'}, - 'display_name': {'key': 'properties.displayName', 'type': 'str'}, - 'versioning_scheme': {'key': 'properties.versioningScheme', 'type': 'str'}, - } - - def __init__(self, **kwargs): - super(ApiVersionSetContract, self).__init__(**kwargs) - self.description = kwargs.get('description', None) - self.version_query_name = kwargs.get('version_query_name', None) - self.version_header_name = kwargs.get('version_header_name', None) - self.display_name = kwargs.get('display_name', None) - self.versioning_scheme = kwargs.get('versioning_scheme', None) diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/api_version_set_contract_details.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/api_version_set_contract_details.py deleted file mode 100644 index ca3eb9e811e4..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/api_version_set_contract_details.py +++ /dev/null @@ -1,54 +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 ApiVersionSetContractDetails(Model): - """An API Version Set contains the common configuration for a set of API - Versions relating . - - :param id: Identifier for existing API Version Set. Omit this value to - create a new Version Set. - :type id: str - :param name: The display Name of the API Version Set. - :type name: str - :param description: Description of API Version Set. - :type description: str - :param versioning_scheme: An value that determines where the API Version - identifer will be located in a HTTP request. Possible values include: - 'Segment', 'Query', 'Header' - :type versioning_scheme: str or ~azure.mgmt.apimanagement.models.enum - :param version_query_name: Name of query parameter that indicates the API - Version if versioningScheme is set to `query`. - :type version_query_name: str - :param version_header_name: Name of HTTP header parameter that indicates - the API Version if versioningScheme is set to `header`. - :type version_header_name: str - """ - - _attribute_map = { - 'id': {'key': 'id', 'type': 'str'}, - 'name': {'key': 'name', 'type': 'str'}, - 'description': {'key': 'description', 'type': 'str'}, - 'versioning_scheme': {'key': 'versioningScheme', 'type': 'str'}, - 'version_query_name': {'key': 'versionQueryName', 'type': 'str'}, - 'version_header_name': {'key': 'versionHeaderName', 'type': 'str'}, - } - - def __init__(self, **kwargs): - super(ApiVersionSetContractDetails, self).__init__(**kwargs) - self.id = kwargs.get('id', None) - self.name = kwargs.get('name', None) - self.description = kwargs.get('description', None) - self.versioning_scheme = kwargs.get('versioning_scheme', None) - self.version_query_name = kwargs.get('version_query_name', None) - self.version_header_name = kwargs.get('version_header_name', None) diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/api_version_set_contract_details_py3.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/api_version_set_contract_details_py3.py deleted file mode 100644 index 9a340f5d4be8..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/api_version_set_contract_details_py3.py +++ /dev/null @@ -1,54 +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 ApiVersionSetContractDetails(Model): - """An API Version Set contains the common configuration for a set of API - Versions relating . - - :param id: Identifier for existing API Version Set. Omit this value to - create a new Version Set. - :type id: str - :param name: The display Name of the API Version Set. - :type name: str - :param description: Description of API Version Set. - :type description: str - :param versioning_scheme: An value that determines where the API Version - identifer will be located in a HTTP request. Possible values include: - 'Segment', 'Query', 'Header' - :type versioning_scheme: str or ~azure.mgmt.apimanagement.models.enum - :param version_query_name: Name of query parameter that indicates the API - Version if versioningScheme is set to `query`. - :type version_query_name: str - :param version_header_name: Name of HTTP header parameter that indicates - the API Version if versioningScheme is set to `header`. - :type version_header_name: str - """ - - _attribute_map = { - 'id': {'key': 'id', 'type': 'str'}, - 'name': {'key': 'name', 'type': 'str'}, - 'description': {'key': 'description', 'type': 'str'}, - 'versioning_scheme': {'key': 'versioningScheme', 'type': 'str'}, - 'version_query_name': {'key': 'versionQueryName', 'type': 'str'}, - 'version_header_name': {'key': 'versionHeaderName', 'type': 'str'}, - } - - def __init__(self, *, id: str=None, name: str=None, description: str=None, versioning_scheme=None, version_query_name: str=None, version_header_name: str=None, **kwargs) -> None: - super(ApiVersionSetContractDetails, self).__init__(**kwargs) - self.id = id - self.name = name - self.description = description - self.versioning_scheme = versioning_scheme - self.version_query_name = version_query_name - self.version_header_name = version_header_name diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/api_version_set_contract_paged.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/api_version_set_contract_paged.py deleted file mode 100644 index cfe10ae6a136..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/api_version_set_contract_paged.py +++ /dev/null @@ -1,27 +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.paging import Paged - - -class ApiVersionSetContractPaged(Paged): - """ - A paging container for iterating over a list of :class:`ApiVersionSetContract ` object - """ - - _attribute_map = { - 'next_link': {'key': 'nextLink', 'type': 'str'}, - 'current_page': {'key': 'value', 'type': '[ApiVersionSetContract]'} - } - - def __init__(self, *args, **kwargs): - - super(ApiVersionSetContractPaged, self).__init__(*args, **kwargs) diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/api_version_set_contract_py3.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/api_version_set_contract_py3.py deleted file mode 100644 index 151e5bec6bf8..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/api_version_set_contract_py3.py +++ /dev/null @@ -1,73 +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 .resource_py3 import Resource - - -class ApiVersionSetContract(Resource): - """Api Version Set Contract details. - - Variables are only populated by the server, and will be ignored when - sending a request. - - All required parameters must be populated in order to send to Azure. - - :ivar id: Resource ID. - :vartype id: str - :ivar name: Resource name. - :vartype name: str - :ivar type: Resource type for API Management resource. - :vartype type: str - :param description: Description of API Version Set. - :type description: str - :param version_query_name: Name of query parameter that indicates the API - Version if versioningScheme is set to `query`. - :type version_query_name: str - :param version_header_name: Name of HTTP header parameter that indicates - the API Version if versioningScheme is set to `header`. - :type version_header_name: str - :param display_name: Required. Name of API Version Set - :type display_name: str - :param versioning_scheme: Required. An value that determines where the API - Version identifer will be located in a HTTP request. Possible values - include: 'Segment', 'Query', 'Header' - :type versioning_scheme: str or - ~azure.mgmt.apimanagement.models.VersioningScheme - """ - - _validation = { - 'id': {'readonly': True}, - 'name': {'readonly': True}, - 'type': {'readonly': True}, - 'version_query_name': {'max_length': 100, 'min_length': 1}, - 'version_header_name': {'max_length': 100, 'min_length': 1}, - 'display_name': {'required': True, 'max_length': 100, 'min_length': 1}, - 'versioning_scheme': {'required': True}, - } - - _attribute_map = { - 'id': {'key': 'id', 'type': 'str'}, - 'name': {'key': 'name', 'type': 'str'}, - 'type': {'key': 'type', 'type': 'str'}, - 'description': {'key': 'properties.description', 'type': 'str'}, - 'version_query_name': {'key': 'properties.versionQueryName', 'type': 'str'}, - 'version_header_name': {'key': 'properties.versionHeaderName', 'type': 'str'}, - 'display_name': {'key': 'properties.displayName', 'type': 'str'}, - 'versioning_scheme': {'key': 'properties.versioningScheme', 'type': 'str'}, - } - - def __init__(self, *, display_name: str, versioning_scheme, description: str=None, version_query_name: str=None, version_header_name: str=None, **kwargs) -> None: - super(ApiVersionSetContract, self).__init__(**kwargs) - self.description = description - self.version_query_name = version_query_name - self.version_header_name = version_header_name - self.display_name = display_name - self.versioning_scheme = versioning_scheme diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/api_version_set_entity_base.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/api_version_set_entity_base.py deleted file mode 100644 index c939168cc5e8..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/api_version_set_entity_base.py +++ /dev/null @@ -1,43 +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 ApiVersionSetEntityBase(Model): - """Api Version set base parameters. - - :param description: Description of API Version Set. - :type description: str - :param version_query_name: Name of query parameter that indicates the API - Version if versioningScheme is set to `query`. - :type version_query_name: str - :param version_header_name: Name of HTTP header parameter that indicates - the API Version if versioningScheme is set to `header`. - :type version_header_name: str - """ - - _validation = { - 'version_query_name': {'max_length': 100, 'min_length': 1}, - 'version_header_name': {'max_length': 100, 'min_length': 1}, - } - - _attribute_map = { - 'description': {'key': 'description', 'type': 'str'}, - 'version_query_name': {'key': 'versionQueryName', 'type': 'str'}, - 'version_header_name': {'key': 'versionHeaderName', 'type': 'str'}, - } - - def __init__(self, **kwargs): - super(ApiVersionSetEntityBase, self).__init__(**kwargs) - self.description = kwargs.get('description', None) - self.version_query_name = kwargs.get('version_query_name', None) - self.version_header_name = kwargs.get('version_header_name', None) diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/api_version_set_entity_base_py3.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/api_version_set_entity_base_py3.py deleted file mode 100644 index 83ff82631423..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/api_version_set_entity_base_py3.py +++ /dev/null @@ -1,43 +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 ApiVersionSetEntityBase(Model): - """Api Version set base parameters. - - :param description: Description of API Version Set. - :type description: str - :param version_query_name: Name of query parameter that indicates the API - Version if versioningScheme is set to `query`. - :type version_query_name: str - :param version_header_name: Name of HTTP header parameter that indicates - the API Version if versioningScheme is set to `header`. - :type version_header_name: str - """ - - _validation = { - 'version_query_name': {'max_length': 100, 'min_length': 1}, - 'version_header_name': {'max_length': 100, 'min_length': 1}, - } - - _attribute_map = { - 'description': {'key': 'description', 'type': 'str'}, - 'version_query_name': {'key': 'versionQueryName', 'type': 'str'}, - 'version_header_name': {'key': 'versionHeaderName', 'type': 'str'}, - } - - def __init__(self, *, description: str=None, version_query_name: str=None, version_header_name: str=None, **kwargs) -> None: - super(ApiVersionSetEntityBase, self).__init__(**kwargs) - self.description = description - self.version_query_name = version_query_name - self.version_header_name = version_header_name diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/api_version_set_update_parameters.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/api_version_set_update_parameters.py deleted file mode 100644 index 0132a009a6e9..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/api_version_set_update_parameters.py +++ /dev/null @@ -1,55 +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 ApiVersionSetUpdateParameters(Model): - """Parameters to update or create an Api Version Set Contract. - - :param description: Description of API Version Set. - :type description: str - :param version_query_name: Name of query parameter that indicates the API - Version if versioningScheme is set to `query`. - :type version_query_name: str - :param version_header_name: Name of HTTP header parameter that indicates - the API Version if versioningScheme is set to `header`. - :type version_header_name: str - :param display_name: Name of API Version Set - :type display_name: str - :param versioning_scheme: An value that determines where the API Version - identifer will be located in a HTTP request. Possible values include: - 'Segment', 'Query', 'Header' - :type versioning_scheme: str or - ~azure.mgmt.apimanagement.models.VersioningScheme - """ - - _validation = { - 'version_query_name': {'max_length': 100, 'min_length': 1}, - 'version_header_name': {'max_length': 100, 'min_length': 1}, - 'display_name': {'max_length': 100, 'min_length': 1}, - } - - _attribute_map = { - 'description': {'key': 'properties.description', 'type': 'str'}, - 'version_query_name': {'key': 'properties.versionQueryName', 'type': 'str'}, - 'version_header_name': {'key': 'properties.versionHeaderName', 'type': 'str'}, - 'display_name': {'key': 'properties.displayName', 'type': 'str'}, - 'versioning_scheme': {'key': 'properties.versioningScheme', 'type': 'str'}, - } - - def __init__(self, **kwargs): - super(ApiVersionSetUpdateParameters, self).__init__(**kwargs) - self.description = kwargs.get('description', None) - self.version_query_name = kwargs.get('version_query_name', None) - self.version_header_name = kwargs.get('version_header_name', None) - self.display_name = kwargs.get('display_name', None) - self.versioning_scheme = kwargs.get('versioning_scheme', None) diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/api_version_set_update_parameters_py3.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/api_version_set_update_parameters_py3.py deleted file mode 100644 index 1a8cce08c012..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/api_version_set_update_parameters_py3.py +++ /dev/null @@ -1,55 +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 ApiVersionSetUpdateParameters(Model): - """Parameters to update or create an Api Version Set Contract. - - :param description: Description of API Version Set. - :type description: str - :param version_query_name: Name of query parameter that indicates the API - Version if versioningScheme is set to `query`. - :type version_query_name: str - :param version_header_name: Name of HTTP header parameter that indicates - the API Version if versioningScheme is set to `header`. - :type version_header_name: str - :param display_name: Name of API Version Set - :type display_name: str - :param versioning_scheme: An value that determines where the API Version - identifer will be located in a HTTP request. Possible values include: - 'Segment', 'Query', 'Header' - :type versioning_scheme: str or - ~azure.mgmt.apimanagement.models.VersioningScheme - """ - - _validation = { - 'version_query_name': {'max_length': 100, 'min_length': 1}, - 'version_header_name': {'max_length': 100, 'min_length': 1}, - 'display_name': {'max_length': 100, 'min_length': 1}, - } - - _attribute_map = { - 'description': {'key': 'properties.description', 'type': 'str'}, - 'version_query_name': {'key': 'properties.versionQueryName', 'type': 'str'}, - 'version_header_name': {'key': 'properties.versionHeaderName', 'type': 'str'}, - 'display_name': {'key': 'properties.displayName', 'type': 'str'}, - 'versioning_scheme': {'key': 'properties.versioningScheme', 'type': 'str'}, - } - - def __init__(self, *, description: str=None, version_query_name: str=None, version_header_name: str=None, display_name: str=None, versioning_scheme=None, **kwargs) -> None: - super(ApiVersionSetUpdateParameters, self).__init__(**kwargs) - self.description = description - self.version_query_name = version_query_name - self.version_header_name = version_header_name - self.display_name = display_name - self.versioning_scheme = versioning_scheme diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/apim_resource.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/apim_resource.py deleted file mode 100644 index 5812e245eb0d..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/apim_resource.py +++ /dev/null @@ -1,50 +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 ApimResource(Model): - """The Resource definition. - - Variables are only populated by the server, and will be ignored when - sending a request. - - :ivar id: Resource ID. - :vartype id: str - :ivar name: Resource name. - :vartype name: str - :ivar type: Resource type for API Management resource is set to - Microsoft.ApiManagement. - :vartype type: str - :param tags: Resource tags. - :type tags: dict[str, str] - """ - - _validation = { - 'id': {'readonly': True}, - 'name': {'readonly': True}, - 'type': {'readonly': True}, - } - - _attribute_map = { - 'id': {'key': 'id', 'type': 'str'}, - 'name': {'key': 'name', 'type': 'str'}, - 'type': {'key': 'type', 'type': 'str'}, - 'tags': {'key': 'tags', 'type': '{str}'}, - } - - def __init__(self, **kwargs): - super(ApimResource, self).__init__(**kwargs) - self.id = None - self.name = None - self.type = None - self.tags = kwargs.get('tags', None) diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/apim_resource_py3.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/apim_resource_py3.py deleted file mode 100644 index b63a2a6ed74c..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/apim_resource_py3.py +++ /dev/null @@ -1,50 +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 ApimResource(Model): - """The Resource definition. - - Variables are only populated by the server, and will be ignored when - sending a request. - - :ivar id: Resource ID. - :vartype id: str - :ivar name: Resource name. - :vartype name: str - :ivar type: Resource type for API Management resource is set to - Microsoft.ApiManagement. - :vartype type: str - :param tags: Resource tags. - :type tags: dict[str, str] - """ - - _validation = { - 'id': {'readonly': True}, - 'name': {'readonly': True}, - 'type': {'readonly': True}, - } - - _attribute_map = { - 'id': {'key': 'id', 'type': 'str'}, - 'name': {'key': 'name', 'type': 'str'}, - 'type': {'key': 'type', 'type': 'str'}, - 'tags': {'key': 'tags', 'type': '{str}'}, - } - - def __init__(self, *, tags=None, **kwargs) -> None: - super(ApimResource, self).__init__(**kwargs) - self.id = None - self.name = None - self.type = None - self.tags = tags diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/authentication_settings_contract.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/authentication_settings_contract.py deleted file mode 100644 index b4eaf5654446..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/authentication_settings_contract.py +++ /dev/null @@ -1,41 +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 AuthenticationSettingsContract(Model): - """API Authentication Settings. - - :param o_auth2: OAuth2 Authentication settings - :type o_auth2: - ~azure.mgmt.apimanagement.models.OAuth2AuthenticationSettingsContract - :param openid: OpenID Connect Authentication Settings - :type openid: - ~azure.mgmt.apimanagement.models.OpenIdAuthenticationSettingsContract - :param subscription_key_required: Specifies whether subscription key is - required during call to this API, true - API is included into closed - products only, false - API is included into open products alone, null - - there is a mix of products. - :type subscription_key_required: bool - """ - - _attribute_map = { - 'o_auth2': {'key': 'oAuth2', 'type': 'OAuth2AuthenticationSettingsContract'}, - 'openid': {'key': 'openid', 'type': 'OpenIdAuthenticationSettingsContract'}, - 'subscription_key_required': {'key': 'subscriptionKeyRequired', 'type': 'bool'}, - } - - def __init__(self, **kwargs): - super(AuthenticationSettingsContract, self).__init__(**kwargs) - self.o_auth2 = kwargs.get('o_auth2', None) - self.openid = kwargs.get('openid', None) - self.subscription_key_required = kwargs.get('subscription_key_required', None) diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/authentication_settings_contract_py3.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/authentication_settings_contract_py3.py deleted file mode 100644 index 725dc936e94f..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/authentication_settings_contract_py3.py +++ /dev/null @@ -1,41 +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 AuthenticationSettingsContract(Model): - """API Authentication Settings. - - :param o_auth2: OAuth2 Authentication settings - :type o_auth2: - ~azure.mgmt.apimanagement.models.OAuth2AuthenticationSettingsContract - :param openid: OpenID Connect Authentication Settings - :type openid: - ~azure.mgmt.apimanagement.models.OpenIdAuthenticationSettingsContract - :param subscription_key_required: Specifies whether subscription key is - required during call to this API, true - API is included into closed - products only, false - API is included into open products alone, null - - there is a mix of products. - :type subscription_key_required: bool - """ - - _attribute_map = { - 'o_auth2': {'key': 'oAuth2', 'type': 'OAuth2AuthenticationSettingsContract'}, - 'openid': {'key': 'openid', 'type': 'OpenIdAuthenticationSettingsContract'}, - 'subscription_key_required': {'key': 'subscriptionKeyRequired', 'type': 'bool'}, - } - - def __init__(self, *, o_auth2=None, openid=None, subscription_key_required: bool=None, **kwargs) -> None: - super(AuthenticationSettingsContract, self).__init__(**kwargs) - self.o_auth2 = o_auth2 - self.openid = openid - self.subscription_key_required = subscription_key_required diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/authorization_server_contract.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/authorization_server_contract.py deleted file mode 100644 index 9a50d1d1ee37..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/authorization_server_contract.py +++ /dev/null @@ -1,142 +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 .resource import Resource - - -class AuthorizationServerContract(Resource): - """External OAuth authorization server settings. - - Variables are only populated by the server, and will be ignored when - sending a request. - - All required parameters must be populated in order to send to Azure. - - :ivar id: Resource ID. - :vartype id: str - :ivar name: Resource name. - :vartype name: str - :ivar type: Resource type for API Management resource. - :vartype type: str - :param description: Description of the authorization server. Can contain - HTML formatting tags. - :type description: str - :param authorization_methods: HTTP verbs supported by the authorization - endpoint. GET must be always present. POST is optional. - :type authorization_methods: list[str or - ~azure.mgmt.apimanagement.models.AuthorizationMethod] - :param client_authentication_method: Method of authentication supported by - the token endpoint of this authorization server. Possible values are Basic - and/or Body. When Body is specified, client credentials and other - parameters are passed within the request body in the - application/x-www-form-urlencoded format. - :type client_authentication_method: list[str or - ~azure.mgmt.apimanagement.models.ClientAuthenticationMethod] - :param token_body_parameters: Additional parameters required by the token - endpoint of this authorization server represented as an array of JSON - objects with name and value string properties, i.e. {"name" : "name - value", "value": "a value"}. - :type token_body_parameters: - list[~azure.mgmt.apimanagement.models.TokenBodyParameterContract] - :param token_endpoint: OAuth token endpoint. Contains absolute URI to - entity being referenced. - :type token_endpoint: str - :param support_state: If true, authorization server will include state - parameter from the authorization request to its response. Client may use - state parameter to raise protocol security. - :type support_state: bool - :param default_scope: Access token scope that is going to be requested by - default. Can be overridden at the API level. Should be provided in the - form of a string containing space-delimited values. - :type default_scope: str - :param bearer_token_sending_methods: Specifies the mechanism by which - access token is passed to the API. - :type bearer_token_sending_methods: list[str or - ~azure.mgmt.apimanagement.models.BearerTokenSendingMethod] - :param client_secret: Client or app secret registered with this - authorization server. - :type client_secret: str - :param resource_owner_username: Can be optionally specified when resource - owner password grant type is supported by this authorization server. - Default resource owner username. - :type resource_owner_username: str - :param resource_owner_password: Can be optionally specified when resource - owner password grant type is supported by this authorization server. - Default resource owner password. - :type resource_owner_password: str - :param display_name: Required. User-friendly authorization server name. - :type display_name: str - :param client_registration_endpoint: Required. Optional reference to a - page where client or app registration for this authorization server is - performed. Contains absolute URL to entity being referenced. - :type client_registration_endpoint: str - :param authorization_endpoint: Required. OAuth authorization endpoint. See - http://tools.ietf.org/html/rfc6749#section-3.2. - :type authorization_endpoint: str - :param grant_types: Required. Form of an authorization grant, which the - client uses to request the access token. - :type grant_types: list[str or ~azure.mgmt.apimanagement.models.GrantType] - :param client_id: Required. Client or app id registered with this - authorization server. - :type client_id: str - """ - - _validation = { - 'id': {'readonly': True}, - 'name': {'readonly': True}, - 'type': {'readonly': True}, - 'display_name': {'required': True, 'max_length': 50, 'min_length': 1}, - 'client_registration_endpoint': {'required': True}, - 'authorization_endpoint': {'required': True}, - 'grant_types': {'required': True}, - 'client_id': {'required': True}, - } - - _attribute_map = { - 'id': {'key': 'id', 'type': 'str'}, - 'name': {'key': 'name', 'type': 'str'}, - 'type': {'key': 'type', 'type': 'str'}, - 'description': {'key': 'properties.description', 'type': 'str'}, - 'authorization_methods': {'key': 'properties.authorizationMethods', 'type': '[AuthorizationMethod]'}, - 'client_authentication_method': {'key': 'properties.clientAuthenticationMethod', 'type': '[str]'}, - 'token_body_parameters': {'key': 'properties.tokenBodyParameters', 'type': '[TokenBodyParameterContract]'}, - 'token_endpoint': {'key': 'properties.tokenEndpoint', 'type': 'str'}, - 'support_state': {'key': 'properties.supportState', 'type': 'bool'}, - 'default_scope': {'key': 'properties.defaultScope', 'type': 'str'}, - 'bearer_token_sending_methods': {'key': 'properties.bearerTokenSendingMethods', 'type': '[str]'}, - 'client_secret': {'key': 'properties.clientSecret', 'type': 'str'}, - 'resource_owner_username': {'key': 'properties.resourceOwnerUsername', 'type': 'str'}, - 'resource_owner_password': {'key': 'properties.resourceOwnerPassword', 'type': 'str'}, - 'display_name': {'key': 'properties.displayName', 'type': 'str'}, - 'client_registration_endpoint': {'key': 'properties.clientRegistrationEndpoint', 'type': 'str'}, - 'authorization_endpoint': {'key': 'properties.authorizationEndpoint', 'type': 'str'}, - 'grant_types': {'key': 'properties.grantTypes', 'type': '[str]'}, - 'client_id': {'key': 'properties.clientId', 'type': 'str'}, - } - - def __init__(self, **kwargs): - super(AuthorizationServerContract, self).__init__(**kwargs) - self.description = kwargs.get('description', None) - self.authorization_methods = kwargs.get('authorization_methods', None) - self.client_authentication_method = kwargs.get('client_authentication_method', None) - self.token_body_parameters = kwargs.get('token_body_parameters', None) - self.token_endpoint = kwargs.get('token_endpoint', None) - self.support_state = kwargs.get('support_state', None) - self.default_scope = kwargs.get('default_scope', None) - self.bearer_token_sending_methods = kwargs.get('bearer_token_sending_methods', None) - self.client_secret = kwargs.get('client_secret', None) - self.resource_owner_username = kwargs.get('resource_owner_username', None) - self.resource_owner_password = kwargs.get('resource_owner_password', None) - self.display_name = kwargs.get('display_name', None) - self.client_registration_endpoint = kwargs.get('client_registration_endpoint', None) - self.authorization_endpoint = kwargs.get('authorization_endpoint', None) - self.grant_types = kwargs.get('grant_types', None) - self.client_id = kwargs.get('client_id', None) diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/authorization_server_contract_base_properties.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/authorization_server_contract_base_properties.py deleted file mode 100644 index 4b5b27bab20c..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/authorization_server_contract_base_properties.py +++ /dev/null @@ -1,92 +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 AuthorizationServerContractBaseProperties(Model): - """External OAuth authorization server Update settings contract. - - :param description: Description of the authorization server. Can contain - HTML formatting tags. - :type description: str - :param authorization_methods: HTTP verbs supported by the authorization - endpoint. GET must be always present. POST is optional. - :type authorization_methods: list[str or - ~azure.mgmt.apimanagement.models.AuthorizationMethod] - :param client_authentication_method: Method of authentication supported by - the token endpoint of this authorization server. Possible values are Basic - and/or Body. When Body is specified, client credentials and other - parameters are passed within the request body in the - application/x-www-form-urlencoded format. - :type client_authentication_method: list[str or - ~azure.mgmt.apimanagement.models.ClientAuthenticationMethod] - :param token_body_parameters: Additional parameters required by the token - endpoint of this authorization server represented as an array of JSON - objects with name and value string properties, i.e. {"name" : "name - value", "value": "a value"}. - :type token_body_parameters: - list[~azure.mgmt.apimanagement.models.TokenBodyParameterContract] - :param token_endpoint: OAuth token endpoint. Contains absolute URI to - entity being referenced. - :type token_endpoint: str - :param support_state: If true, authorization server will include state - parameter from the authorization request to its response. Client may use - state parameter to raise protocol security. - :type support_state: bool - :param default_scope: Access token scope that is going to be requested by - default. Can be overridden at the API level. Should be provided in the - form of a string containing space-delimited values. - :type default_scope: str - :param bearer_token_sending_methods: Specifies the mechanism by which - access token is passed to the API. - :type bearer_token_sending_methods: list[str or - ~azure.mgmt.apimanagement.models.BearerTokenSendingMethod] - :param client_secret: Client or app secret registered with this - authorization server. - :type client_secret: str - :param resource_owner_username: Can be optionally specified when resource - owner password grant type is supported by this authorization server. - Default resource owner username. - :type resource_owner_username: str - :param resource_owner_password: Can be optionally specified when resource - owner password grant type is supported by this authorization server. - Default resource owner password. - :type resource_owner_password: str - """ - - _attribute_map = { - 'description': {'key': 'description', 'type': 'str'}, - 'authorization_methods': {'key': 'authorizationMethods', 'type': '[AuthorizationMethod]'}, - 'client_authentication_method': {'key': 'clientAuthenticationMethod', 'type': '[str]'}, - 'token_body_parameters': {'key': 'tokenBodyParameters', 'type': '[TokenBodyParameterContract]'}, - 'token_endpoint': {'key': 'tokenEndpoint', 'type': 'str'}, - 'support_state': {'key': 'supportState', 'type': 'bool'}, - 'default_scope': {'key': 'defaultScope', 'type': 'str'}, - 'bearer_token_sending_methods': {'key': 'bearerTokenSendingMethods', 'type': '[str]'}, - 'client_secret': {'key': 'clientSecret', 'type': 'str'}, - 'resource_owner_username': {'key': 'resourceOwnerUsername', 'type': 'str'}, - 'resource_owner_password': {'key': 'resourceOwnerPassword', 'type': 'str'}, - } - - def __init__(self, **kwargs): - super(AuthorizationServerContractBaseProperties, self).__init__(**kwargs) - self.description = kwargs.get('description', None) - self.authorization_methods = kwargs.get('authorization_methods', None) - self.client_authentication_method = kwargs.get('client_authentication_method', None) - self.token_body_parameters = kwargs.get('token_body_parameters', None) - self.token_endpoint = kwargs.get('token_endpoint', None) - self.support_state = kwargs.get('support_state', None) - self.default_scope = kwargs.get('default_scope', None) - self.bearer_token_sending_methods = kwargs.get('bearer_token_sending_methods', None) - self.client_secret = kwargs.get('client_secret', None) - self.resource_owner_username = kwargs.get('resource_owner_username', None) - self.resource_owner_password = kwargs.get('resource_owner_password', None) diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/authorization_server_contract_base_properties_py3.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/authorization_server_contract_base_properties_py3.py deleted file mode 100644 index 3d18e7cd3695..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/authorization_server_contract_base_properties_py3.py +++ /dev/null @@ -1,92 +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 AuthorizationServerContractBaseProperties(Model): - """External OAuth authorization server Update settings contract. - - :param description: Description of the authorization server. Can contain - HTML formatting tags. - :type description: str - :param authorization_methods: HTTP verbs supported by the authorization - endpoint. GET must be always present. POST is optional. - :type authorization_methods: list[str or - ~azure.mgmt.apimanagement.models.AuthorizationMethod] - :param client_authentication_method: Method of authentication supported by - the token endpoint of this authorization server. Possible values are Basic - and/or Body. When Body is specified, client credentials and other - parameters are passed within the request body in the - application/x-www-form-urlencoded format. - :type client_authentication_method: list[str or - ~azure.mgmt.apimanagement.models.ClientAuthenticationMethod] - :param token_body_parameters: Additional parameters required by the token - endpoint of this authorization server represented as an array of JSON - objects with name and value string properties, i.e. {"name" : "name - value", "value": "a value"}. - :type token_body_parameters: - list[~azure.mgmt.apimanagement.models.TokenBodyParameterContract] - :param token_endpoint: OAuth token endpoint. Contains absolute URI to - entity being referenced. - :type token_endpoint: str - :param support_state: If true, authorization server will include state - parameter from the authorization request to its response. Client may use - state parameter to raise protocol security. - :type support_state: bool - :param default_scope: Access token scope that is going to be requested by - default. Can be overridden at the API level. Should be provided in the - form of a string containing space-delimited values. - :type default_scope: str - :param bearer_token_sending_methods: Specifies the mechanism by which - access token is passed to the API. - :type bearer_token_sending_methods: list[str or - ~azure.mgmt.apimanagement.models.BearerTokenSendingMethod] - :param client_secret: Client or app secret registered with this - authorization server. - :type client_secret: str - :param resource_owner_username: Can be optionally specified when resource - owner password grant type is supported by this authorization server. - Default resource owner username. - :type resource_owner_username: str - :param resource_owner_password: Can be optionally specified when resource - owner password grant type is supported by this authorization server. - Default resource owner password. - :type resource_owner_password: str - """ - - _attribute_map = { - 'description': {'key': 'description', 'type': 'str'}, - 'authorization_methods': {'key': 'authorizationMethods', 'type': '[AuthorizationMethod]'}, - 'client_authentication_method': {'key': 'clientAuthenticationMethod', 'type': '[str]'}, - 'token_body_parameters': {'key': 'tokenBodyParameters', 'type': '[TokenBodyParameterContract]'}, - 'token_endpoint': {'key': 'tokenEndpoint', 'type': 'str'}, - 'support_state': {'key': 'supportState', 'type': 'bool'}, - 'default_scope': {'key': 'defaultScope', 'type': 'str'}, - 'bearer_token_sending_methods': {'key': 'bearerTokenSendingMethods', 'type': '[str]'}, - 'client_secret': {'key': 'clientSecret', 'type': 'str'}, - 'resource_owner_username': {'key': 'resourceOwnerUsername', 'type': 'str'}, - 'resource_owner_password': {'key': 'resourceOwnerPassword', 'type': 'str'}, - } - - def __init__(self, *, description: str=None, authorization_methods=None, client_authentication_method=None, token_body_parameters=None, token_endpoint: str=None, support_state: bool=None, default_scope: str=None, bearer_token_sending_methods=None, client_secret: str=None, resource_owner_username: str=None, resource_owner_password: str=None, **kwargs) -> None: - super(AuthorizationServerContractBaseProperties, self).__init__(**kwargs) - self.description = description - self.authorization_methods = authorization_methods - self.client_authentication_method = client_authentication_method - self.token_body_parameters = token_body_parameters - self.token_endpoint = token_endpoint - self.support_state = support_state - self.default_scope = default_scope - self.bearer_token_sending_methods = bearer_token_sending_methods - self.client_secret = client_secret - self.resource_owner_username = resource_owner_username - self.resource_owner_password = resource_owner_password diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/authorization_server_contract_paged.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/authorization_server_contract_paged.py deleted file mode 100644 index 471b4f0192d5..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/authorization_server_contract_paged.py +++ /dev/null @@ -1,27 +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.paging import Paged - - -class AuthorizationServerContractPaged(Paged): - """ - A paging container for iterating over a list of :class:`AuthorizationServerContract ` object - """ - - _attribute_map = { - 'next_link': {'key': 'nextLink', 'type': 'str'}, - 'current_page': {'key': 'value', 'type': '[AuthorizationServerContract]'} - } - - def __init__(self, *args, **kwargs): - - super(AuthorizationServerContractPaged, self).__init__(*args, **kwargs) diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/authorization_server_contract_py3.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/authorization_server_contract_py3.py deleted file mode 100644 index a8ccc68ee9ca..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/authorization_server_contract_py3.py +++ /dev/null @@ -1,142 +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 .resource_py3 import Resource - - -class AuthorizationServerContract(Resource): - """External OAuth authorization server settings. - - Variables are only populated by the server, and will be ignored when - sending a request. - - All required parameters must be populated in order to send to Azure. - - :ivar id: Resource ID. - :vartype id: str - :ivar name: Resource name. - :vartype name: str - :ivar type: Resource type for API Management resource. - :vartype type: str - :param description: Description of the authorization server. Can contain - HTML formatting tags. - :type description: str - :param authorization_methods: HTTP verbs supported by the authorization - endpoint. GET must be always present. POST is optional. - :type authorization_methods: list[str or - ~azure.mgmt.apimanagement.models.AuthorizationMethod] - :param client_authentication_method: Method of authentication supported by - the token endpoint of this authorization server. Possible values are Basic - and/or Body. When Body is specified, client credentials and other - parameters are passed within the request body in the - application/x-www-form-urlencoded format. - :type client_authentication_method: list[str or - ~azure.mgmt.apimanagement.models.ClientAuthenticationMethod] - :param token_body_parameters: Additional parameters required by the token - endpoint of this authorization server represented as an array of JSON - objects with name and value string properties, i.e. {"name" : "name - value", "value": "a value"}. - :type token_body_parameters: - list[~azure.mgmt.apimanagement.models.TokenBodyParameterContract] - :param token_endpoint: OAuth token endpoint. Contains absolute URI to - entity being referenced. - :type token_endpoint: str - :param support_state: If true, authorization server will include state - parameter from the authorization request to its response. Client may use - state parameter to raise protocol security. - :type support_state: bool - :param default_scope: Access token scope that is going to be requested by - default. Can be overridden at the API level. Should be provided in the - form of a string containing space-delimited values. - :type default_scope: str - :param bearer_token_sending_methods: Specifies the mechanism by which - access token is passed to the API. - :type bearer_token_sending_methods: list[str or - ~azure.mgmt.apimanagement.models.BearerTokenSendingMethod] - :param client_secret: Client or app secret registered with this - authorization server. - :type client_secret: str - :param resource_owner_username: Can be optionally specified when resource - owner password grant type is supported by this authorization server. - Default resource owner username. - :type resource_owner_username: str - :param resource_owner_password: Can be optionally specified when resource - owner password grant type is supported by this authorization server. - Default resource owner password. - :type resource_owner_password: str - :param display_name: Required. User-friendly authorization server name. - :type display_name: str - :param client_registration_endpoint: Required. Optional reference to a - page where client or app registration for this authorization server is - performed. Contains absolute URL to entity being referenced. - :type client_registration_endpoint: str - :param authorization_endpoint: Required. OAuth authorization endpoint. See - http://tools.ietf.org/html/rfc6749#section-3.2. - :type authorization_endpoint: str - :param grant_types: Required. Form of an authorization grant, which the - client uses to request the access token. - :type grant_types: list[str or ~azure.mgmt.apimanagement.models.GrantType] - :param client_id: Required. Client or app id registered with this - authorization server. - :type client_id: str - """ - - _validation = { - 'id': {'readonly': True}, - 'name': {'readonly': True}, - 'type': {'readonly': True}, - 'display_name': {'required': True, 'max_length': 50, 'min_length': 1}, - 'client_registration_endpoint': {'required': True}, - 'authorization_endpoint': {'required': True}, - 'grant_types': {'required': True}, - 'client_id': {'required': True}, - } - - _attribute_map = { - 'id': {'key': 'id', 'type': 'str'}, - 'name': {'key': 'name', 'type': 'str'}, - 'type': {'key': 'type', 'type': 'str'}, - 'description': {'key': 'properties.description', 'type': 'str'}, - 'authorization_methods': {'key': 'properties.authorizationMethods', 'type': '[AuthorizationMethod]'}, - 'client_authentication_method': {'key': 'properties.clientAuthenticationMethod', 'type': '[str]'}, - 'token_body_parameters': {'key': 'properties.tokenBodyParameters', 'type': '[TokenBodyParameterContract]'}, - 'token_endpoint': {'key': 'properties.tokenEndpoint', 'type': 'str'}, - 'support_state': {'key': 'properties.supportState', 'type': 'bool'}, - 'default_scope': {'key': 'properties.defaultScope', 'type': 'str'}, - 'bearer_token_sending_methods': {'key': 'properties.bearerTokenSendingMethods', 'type': '[str]'}, - 'client_secret': {'key': 'properties.clientSecret', 'type': 'str'}, - 'resource_owner_username': {'key': 'properties.resourceOwnerUsername', 'type': 'str'}, - 'resource_owner_password': {'key': 'properties.resourceOwnerPassword', 'type': 'str'}, - 'display_name': {'key': 'properties.displayName', 'type': 'str'}, - 'client_registration_endpoint': {'key': 'properties.clientRegistrationEndpoint', 'type': 'str'}, - 'authorization_endpoint': {'key': 'properties.authorizationEndpoint', 'type': 'str'}, - 'grant_types': {'key': 'properties.grantTypes', 'type': '[str]'}, - 'client_id': {'key': 'properties.clientId', 'type': 'str'}, - } - - def __init__(self, *, display_name: str, client_registration_endpoint: str, authorization_endpoint: str, grant_types, client_id: str, description: str=None, authorization_methods=None, client_authentication_method=None, token_body_parameters=None, token_endpoint: str=None, support_state: bool=None, default_scope: str=None, bearer_token_sending_methods=None, client_secret: str=None, resource_owner_username: str=None, resource_owner_password: str=None, **kwargs) -> None: - super(AuthorizationServerContract, self).__init__(**kwargs) - self.description = description - self.authorization_methods = authorization_methods - self.client_authentication_method = client_authentication_method - self.token_body_parameters = token_body_parameters - self.token_endpoint = token_endpoint - self.support_state = support_state - self.default_scope = default_scope - self.bearer_token_sending_methods = bearer_token_sending_methods - self.client_secret = client_secret - self.resource_owner_username = resource_owner_username - self.resource_owner_password = resource_owner_password - self.display_name = display_name - self.client_registration_endpoint = client_registration_endpoint - self.authorization_endpoint = authorization_endpoint - self.grant_types = grant_types - self.client_id = client_id diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/authorization_server_update_contract.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/authorization_server_update_contract.py deleted file mode 100644 index 0e7b3a542afe..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/authorization_server_update_contract.py +++ /dev/null @@ -1,136 +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 .resource import Resource - - -class AuthorizationServerUpdateContract(Resource): - """External OAuth authorization server settings. - - Variables are only populated by the server, and will be ignored when - sending a request. - - :ivar id: Resource ID. - :vartype id: str - :ivar name: Resource name. - :vartype name: str - :ivar type: Resource type for API Management resource. - :vartype type: str - :param description: Description of the authorization server. Can contain - HTML formatting tags. - :type description: str - :param authorization_methods: HTTP verbs supported by the authorization - endpoint. GET must be always present. POST is optional. - :type authorization_methods: list[str or - ~azure.mgmt.apimanagement.models.AuthorizationMethod] - :param client_authentication_method: Method of authentication supported by - the token endpoint of this authorization server. Possible values are Basic - and/or Body. When Body is specified, client credentials and other - parameters are passed within the request body in the - application/x-www-form-urlencoded format. - :type client_authentication_method: list[str or - ~azure.mgmt.apimanagement.models.ClientAuthenticationMethod] - :param token_body_parameters: Additional parameters required by the token - endpoint of this authorization server represented as an array of JSON - objects with name and value string properties, i.e. {"name" : "name - value", "value": "a value"}. - :type token_body_parameters: - list[~azure.mgmt.apimanagement.models.TokenBodyParameterContract] - :param token_endpoint: OAuth token endpoint. Contains absolute URI to - entity being referenced. - :type token_endpoint: str - :param support_state: If true, authorization server will include state - parameter from the authorization request to its response. Client may use - state parameter to raise protocol security. - :type support_state: bool - :param default_scope: Access token scope that is going to be requested by - default. Can be overridden at the API level. Should be provided in the - form of a string containing space-delimited values. - :type default_scope: str - :param bearer_token_sending_methods: Specifies the mechanism by which - access token is passed to the API. - :type bearer_token_sending_methods: list[str or - ~azure.mgmt.apimanagement.models.BearerTokenSendingMethod] - :param client_secret: Client or app secret registered with this - authorization server. - :type client_secret: str - :param resource_owner_username: Can be optionally specified when resource - owner password grant type is supported by this authorization server. - Default resource owner username. - :type resource_owner_username: str - :param resource_owner_password: Can be optionally specified when resource - owner password grant type is supported by this authorization server. - Default resource owner password. - :type resource_owner_password: str - :param display_name: User-friendly authorization server name. - :type display_name: str - :param client_registration_endpoint: Optional reference to a page where - client or app registration for this authorization server is performed. - Contains absolute URL to entity being referenced. - :type client_registration_endpoint: str - :param authorization_endpoint: OAuth authorization endpoint. See - http://tools.ietf.org/html/rfc6749#section-3.2. - :type authorization_endpoint: str - :param grant_types: Form of an authorization grant, which the client uses - to request the access token. - :type grant_types: list[str or ~azure.mgmt.apimanagement.models.GrantType] - :param client_id: Client or app id registered with this authorization - server. - :type client_id: str - """ - - _validation = { - 'id': {'readonly': True}, - 'name': {'readonly': True}, - 'type': {'readonly': True}, - 'display_name': {'max_length': 50, 'min_length': 1}, - } - - _attribute_map = { - 'id': {'key': 'id', 'type': 'str'}, - 'name': {'key': 'name', 'type': 'str'}, - 'type': {'key': 'type', 'type': 'str'}, - 'description': {'key': 'properties.description', 'type': 'str'}, - 'authorization_methods': {'key': 'properties.authorizationMethods', 'type': '[AuthorizationMethod]'}, - 'client_authentication_method': {'key': 'properties.clientAuthenticationMethod', 'type': '[str]'}, - 'token_body_parameters': {'key': 'properties.tokenBodyParameters', 'type': '[TokenBodyParameterContract]'}, - 'token_endpoint': {'key': 'properties.tokenEndpoint', 'type': 'str'}, - 'support_state': {'key': 'properties.supportState', 'type': 'bool'}, - 'default_scope': {'key': 'properties.defaultScope', 'type': 'str'}, - 'bearer_token_sending_methods': {'key': 'properties.bearerTokenSendingMethods', 'type': '[str]'}, - 'client_secret': {'key': 'properties.clientSecret', 'type': 'str'}, - 'resource_owner_username': {'key': 'properties.resourceOwnerUsername', 'type': 'str'}, - 'resource_owner_password': {'key': 'properties.resourceOwnerPassword', 'type': 'str'}, - 'display_name': {'key': 'properties.displayName', 'type': 'str'}, - 'client_registration_endpoint': {'key': 'properties.clientRegistrationEndpoint', 'type': 'str'}, - 'authorization_endpoint': {'key': 'properties.authorizationEndpoint', 'type': 'str'}, - 'grant_types': {'key': 'properties.grantTypes', 'type': '[str]'}, - 'client_id': {'key': 'properties.clientId', 'type': 'str'}, - } - - def __init__(self, **kwargs): - super(AuthorizationServerUpdateContract, self).__init__(**kwargs) - self.description = kwargs.get('description', None) - self.authorization_methods = kwargs.get('authorization_methods', None) - self.client_authentication_method = kwargs.get('client_authentication_method', None) - self.token_body_parameters = kwargs.get('token_body_parameters', None) - self.token_endpoint = kwargs.get('token_endpoint', None) - self.support_state = kwargs.get('support_state', None) - self.default_scope = kwargs.get('default_scope', None) - self.bearer_token_sending_methods = kwargs.get('bearer_token_sending_methods', None) - self.client_secret = kwargs.get('client_secret', None) - self.resource_owner_username = kwargs.get('resource_owner_username', None) - self.resource_owner_password = kwargs.get('resource_owner_password', None) - self.display_name = kwargs.get('display_name', None) - self.client_registration_endpoint = kwargs.get('client_registration_endpoint', None) - self.authorization_endpoint = kwargs.get('authorization_endpoint', None) - self.grant_types = kwargs.get('grant_types', None) - self.client_id = kwargs.get('client_id', None) diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/authorization_server_update_contract_py3.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/authorization_server_update_contract_py3.py deleted file mode 100644 index d6b6e2357000..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/authorization_server_update_contract_py3.py +++ /dev/null @@ -1,136 +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 .resource_py3 import Resource - - -class AuthorizationServerUpdateContract(Resource): - """External OAuth authorization server settings. - - Variables are only populated by the server, and will be ignored when - sending a request. - - :ivar id: Resource ID. - :vartype id: str - :ivar name: Resource name. - :vartype name: str - :ivar type: Resource type for API Management resource. - :vartype type: str - :param description: Description of the authorization server. Can contain - HTML formatting tags. - :type description: str - :param authorization_methods: HTTP verbs supported by the authorization - endpoint. GET must be always present. POST is optional. - :type authorization_methods: list[str or - ~azure.mgmt.apimanagement.models.AuthorizationMethod] - :param client_authentication_method: Method of authentication supported by - the token endpoint of this authorization server. Possible values are Basic - and/or Body. When Body is specified, client credentials and other - parameters are passed within the request body in the - application/x-www-form-urlencoded format. - :type client_authentication_method: list[str or - ~azure.mgmt.apimanagement.models.ClientAuthenticationMethod] - :param token_body_parameters: Additional parameters required by the token - endpoint of this authorization server represented as an array of JSON - objects with name and value string properties, i.e. {"name" : "name - value", "value": "a value"}. - :type token_body_parameters: - list[~azure.mgmt.apimanagement.models.TokenBodyParameterContract] - :param token_endpoint: OAuth token endpoint. Contains absolute URI to - entity being referenced. - :type token_endpoint: str - :param support_state: If true, authorization server will include state - parameter from the authorization request to its response. Client may use - state parameter to raise protocol security. - :type support_state: bool - :param default_scope: Access token scope that is going to be requested by - default. Can be overridden at the API level. Should be provided in the - form of a string containing space-delimited values. - :type default_scope: str - :param bearer_token_sending_methods: Specifies the mechanism by which - access token is passed to the API. - :type bearer_token_sending_methods: list[str or - ~azure.mgmt.apimanagement.models.BearerTokenSendingMethod] - :param client_secret: Client or app secret registered with this - authorization server. - :type client_secret: str - :param resource_owner_username: Can be optionally specified when resource - owner password grant type is supported by this authorization server. - Default resource owner username. - :type resource_owner_username: str - :param resource_owner_password: Can be optionally specified when resource - owner password grant type is supported by this authorization server. - Default resource owner password. - :type resource_owner_password: str - :param display_name: User-friendly authorization server name. - :type display_name: str - :param client_registration_endpoint: Optional reference to a page where - client or app registration for this authorization server is performed. - Contains absolute URL to entity being referenced. - :type client_registration_endpoint: str - :param authorization_endpoint: OAuth authorization endpoint. See - http://tools.ietf.org/html/rfc6749#section-3.2. - :type authorization_endpoint: str - :param grant_types: Form of an authorization grant, which the client uses - to request the access token. - :type grant_types: list[str or ~azure.mgmt.apimanagement.models.GrantType] - :param client_id: Client or app id registered with this authorization - server. - :type client_id: str - """ - - _validation = { - 'id': {'readonly': True}, - 'name': {'readonly': True}, - 'type': {'readonly': True}, - 'display_name': {'max_length': 50, 'min_length': 1}, - } - - _attribute_map = { - 'id': {'key': 'id', 'type': 'str'}, - 'name': {'key': 'name', 'type': 'str'}, - 'type': {'key': 'type', 'type': 'str'}, - 'description': {'key': 'properties.description', 'type': 'str'}, - 'authorization_methods': {'key': 'properties.authorizationMethods', 'type': '[AuthorizationMethod]'}, - 'client_authentication_method': {'key': 'properties.clientAuthenticationMethod', 'type': '[str]'}, - 'token_body_parameters': {'key': 'properties.tokenBodyParameters', 'type': '[TokenBodyParameterContract]'}, - 'token_endpoint': {'key': 'properties.tokenEndpoint', 'type': 'str'}, - 'support_state': {'key': 'properties.supportState', 'type': 'bool'}, - 'default_scope': {'key': 'properties.defaultScope', 'type': 'str'}, - 'bearer_token_sending_methods': {'key': 'properties.bearerTokenSendingMethods', 'type': '[str]'}, - 'client_secret': {'key': 'properties.clientSecret', 'type': 'str'}, - 'resource_owner_username': {'key': 'properties.resourceOwnerUsername', 'type': 'str'}, - 'resource_owner_password': {'key': 'properties.resourceOwnerPassword', 'type': 'str'}, - 'display_name': {'key': 'properties.displayName', 'type': 'str'}, - 'client_registration_endpoint': {'key': 'properties.clientRegistrationEndpoint', 'type': 'str'}, - 'authorization_endpoint': {'key': 'properties.authorizationEndpoint', 'type': 'str'}, - 'grant_types': {'key': 'properties.grantTypes', 'type': '[str]'}, - 'client_id': {'key': 'properties.clientId', 'type': 'str'}, - } - - def __init__(self, *, description: str=None, authorization_methods=None, client_authentication_method=None, token_body_parameters=None, token_endpoint: str=None, support_state: bool=None, default_scope: str=None, bearer_token_sending_methods=None, client_secret: str=None, resource_owner_username: str=None, resource_owner_password: str=None, display_name: str=None, client_registration_endpoint: str=None, authorization_endpoint: str=None, grant_types=None, client_id: str=None, **kwargs) -> None: - super(AuthorizationServerUpdateContract, self).__init__(**kwargs) - self.description = description - self.authorization_methods = authorization_methods - self.client_authentication_method = client_authentication_method - self.token_body_parameters = token_body_parameters - self.token_endpoint = token_endpoint - self.support_state = support_state - self.default_scope = default_scope - self.bearer_token_sending_methods = bearer_token_sending_methods - self.client_secret = client_secret - self.resource_owner_username = resource_owner_username - self.resource_owner_password = resource_owner_password - self.display_name = display_name - self.client_registration_endpoint = client_registration_endpoint - self.authorization_endpoint = authorization_endpoint - self.grant_types = grant_types - self.client_id = client_id diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/backend_authorization_header_credentials.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/backend_authorization_header_credentials.py deleted file mode 100644 index f579daecff01..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/backend_authorization_header_credentials.py +++ /dev/null @@ -1,39 +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 BackendAuthorizationHeaderCredentials(Model): - """Authorization header information. - - All required parameters must be populated in order to send to Azure. - - :param scheme: Required. Authentication Scheme name. - :type scheme: str - :param parameter: Required. Authentication Parameter value. - :type parameter: str - """ - - _validation = { - 'scheme': {'required': True, 'max_length': 100, 'min_length': 1}, - 'parameter': {'required': True, 'max_length': 300, 'min_length': 1}, - } - - _attribute_map = { - 'scheme': {'key': 'scheme', 'type': 'str'}, - 'parameter': {'key': 'parameter', 'type': 'str'}, - } - - def __init__(self, **kwargs): - super(BackendAuthorizationHeaderCredentials, self).__init__(**kwargs) - self.scheme = kwargs.get('scheme', None) - self.parameter = kwargs.get('parameter', None) diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/backend_authorization_header_credentials_py3.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/backend_authorization_header_credentials_py3.py deleted file mode 100644 index 9118b95378b7..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/backend_authorization_header_credentials_py3.py +++ /dev/null @@ -1,39 +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 BackendAuthorizationHeaderCredentials(Model): - """Authorization header information. - - All required parameters must be populated in order to send to Azure. - - :param scheme: Required. Authentication Scheme name. - :type scheme: str - :param parameter: Required. Authentication Parameter value. - :type parameter: str - """ - - _validation = { - 'scheme': {'required': True, 'max_length': 100, 'min_length': 1}, - 'parameter': {'required': True, 'max_length': 300, 'min_length': 1}, - } - - _attribute_map = { - 'scheme': {'key': 'scheme', 'type': 'str'}, - 'parameter': {'key': 'parameter', 'type': 'str'}, - } - - def __init__(self, *, scheme: str, parameter: str, **kwargs) -> None: - super(BackendAuthorizationHeaderCredentials, self).__init__(**kwargs) - self.scheme = scheme - self.parameter = parameter diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/backend_base_parameters.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/backend_base_parameters.py deleted file mode 100644 index 8a1440dc943b..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/backend_base_parameters.py +++ /dev/null @@ -1,61 +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 BackendBaseParameters(Model): - """Backend entity base Parameter set. - - :param title: Backend Title. - :type title: str - :param description: Backend Description. - :type description: str - :param resource_id: Management Uri of the Resource in External System. - This url can be the Arm Resource Id of Logic Apps, Function Apps or Api - Apps. - :type resource_id: str - :param properties: Backend Properties contract - :type properties: ~azure.mgmt.apimanagement.models.BackendProperties - :param credentials: Backend Credentials Contract Properties - :type credentials: - ~azure.mgmt.apimanagement.models.BackendCredentialsContract - :param proxy: Backend Proxy Contract Properties - :type proxy: ~azure.mgmt.apimanagement.models.BackendProxyContract - :param tls: Backend TLS Properties - :type tls: ~azure.mgmt.apimanagement.models.BackendTlsProperties - """ - - _validation = { - 'title': {'max_length': 300, 'min_length': 1}, - 'description': {'max_length': 2000, 'min_length': 1}, - 'resource_id': {'max_length': 2000, 'min_length': 1}, - } - - _attribute_map = { - 'title': {'key': 'title', 'type': 'str'}, - 'description': {'key': 'description', 'type': 'str'}, - 'resource_id': {'key': 'resourceId', 'type': 'str'}, - 'properties': {'key': 'properties', 'type': 'BackendProperties'}, - 'credentials': {'key': 'credentials', 'type': 'BackendCredentialsContract'}, - 'proxy': {'key': 'proxy', 'type': 'BackendProxyContract'}, - 'tls': {'key': 'tls', 'type': 'BackendTlsProperties'}, - } - - def __init__(self, **kwargs): - super(BackendBaseParameters, self).__init__(**kwargs) - self.title = kwargs.get('title', None) - self.description = kwargs.get('description', None) - self.resource_id = kwargs.get('resource_id', None) - self.properties = kwargs.get('properties', None) - self.credentials = kwargs.get('credentials', None) - self.proxy = kwargs.get('proxy', None) - self.tls = kwargs.get('tls', None) diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/backend_base_parameters_py3.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/backend_base_parameters_py3.py deleted file mode 100644 index 87c0a199bd72..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/backend_base_parameters_py3.py +++ /dev/null @@ -1,61 +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 BackendBaseParameters(Model): - """Backend entity base Parameter set. - - :param title: Backend Title. - :type title: str - :param description: Backend Description. - :type description: str - :param resource_id: Management Uri of the Resource in External System. - This url can be the Arm Resource Id of Logic Apps, Function Apps or Api - Apps. - :type resource_id: str - :param properties: Backend Properties contract - :type properties: ~azure.mgmt.apimanagement.models.BackendProperties - :param credentials: Backend Credentials Contract Properties - :type credentials: - ~azure.mgmt.apimanagement.models.BackendCredentialsContract - :param proxy: Backend Proxy Contract Properties - :type proxy: ~azure.mgmt.apimanagement.models.BackendProxyContract - :param tls: Backend TLS Properties - :type tls: ~azure.mgmt.apimanagement.models.BackendTlsProperties - """ - - _validation = { - 'title': {'max_length': 300, 'min_length': 1}, - 'description': {'max_length': 2000, 'min_length': 1}, - 'resource_id': {'max_length': 2000, 'min_length': 1}, - } - - _attribute_map = { - 'title': {'key': 'title', 'type': 'str'}, - 'description': {'key': 'description', 'type': 'str'}, - 'resource_id': {'key': 'resourceId', 'type': 'str'}, - 'properties': {'key': 'properties', 'type': 'BackendProperties'}, - 'credentials': {'key': 'credentials', 'type': 'BackendCredentialsContract'}, - 'proxy': {'key': 'proxy', 'type': 'BackendProxyContract'}, - 'tls': {'key': 'tls', 'type': 'BackendTlsProperties'}, - } - - def __init__(self, *, title: str=None, description: str=None, resource_id: str=None, properties=None, credentials=None, proxy=None, tls=None, **kwargs) -> None: - super(BackendBaseParameters, self).__init__(**kwargs) - self.title = title - self.description = description - self.resource_id = resource_id - self.properties = properties - self.credentials = credentials - self.proxy = proxy - self.tls = tls diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/backend_contract.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/backend_contract.py deleted file mode 100644 index 568362361d49..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/backend_contract.py +++ /dev/null @@ -1,89 +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 .resource import Resource - - -class BackendContract(Resource): - """Backend details. - - Variables are only populated by the server, and will be ignored when - sending a request. - - All required parameters must be populated in order to send to Azure. - - :ivar id: Resource ID. - :vartype id: str - :ivar name: Resource name. - :vartype name: str - :ivar type: Resource type for API Management resource. - :vartype type: str - :param title: Backend Title. - :type title: str - :param description: Backend Description. - :type description: str - :param resource_id: Management Uri of the Resource in External System. - This url can be the Arm Resource Id of Logic Apps, Function Apps or Api - Apps. - :type resource_id: str - :param properties: Backend Properties contract - :type properties: ~azure.mgmt.apimanagement.models.BackendProperties - :param credentials: Backend Credentials Contract Properties - :type credentials: - ~azure.mgmt.apimanagement.models.BackendCredentialsContract - :param proxy: Backend Proxy Contract Properties - :type proxy: ~azure.mgmt.apimanagement.models.BackendProxyContract - :param tls: Backend TLS Properties - :type tls: ~azure.mgmt.apimanagement.models.BackendTlsProperties - :param url: Required. Runtime Url of the Backend. - :type url: str - :param protocol: Required. Backend communication protocol. Possible values - include: 'http', 'soap' - :type protocol: str or ~azure.mgmt.apimanagement.models.BackendProtocol - """ - - _validation = { - 'id': {'readonly': True}, - 'name': {'readonly': True}, - 'type': {'readonly': True}, - 'title': {'max_length': 300, 'min_length': 1}, - 'description': {'max_length': 2000, 'min_length': 1}, - 'resource_id': {'max_length': 2000, 'min_length': 1}, - 'url': {'required': True, 'max_length': 2000, 'min_length': 1}, - 'protocol': {'required': True}, - } - - _attribute_map = { - 'id': {'key': 'id', 'type': 'str'}, - 'name': {'key': 'name', 'type': 'str'}, - 'type': {'key': 'type', 'type': 'str'}, - 'title': {'key': 'properties.title', 'type': 'str'}, - 'description': {'key': 'properties.description', 'type': 'str'}, - 'resource_id': {'key': 'properties.resourceId', 'type': 'str'}, - 'properties': {'key': 'properties.properties', 'type': 'BackendProperties'}, - 'credentials': {'key': 'properties.credentials', 'type': 'BackendCredentialsContract'}, - 'proxy': {'key': 'properties.proxy', 'type': 'BackendProxyContract'}, - 'tls': {'key': 'properties.tls', 'type': 'BackendTlsProperties'}, - 'url': {'key': 'properties.url', 'type': 'str'}, - 'protocol': {'key': 'properties.protocol', 'type': 'str'}, - } - - def __init__(self, **kwargs): - super(BackendContract, self).__init__(**kwargs) - self.title = kwargs.get('title', None) - self.description = kwargs.get('description', None) - self.resource_id = kwargs.get('resource_id', None) - self.properties = kwargs.get('properties', None) - self.credentials = kwargs.get('credentials', None) - self.proxy = kwargs.get('proxy', None) - self.tls = kwargs.get('tls', None) - self.url = kwargs.get('url', None) - self.protocol = kwargs.get('protocol', None) diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/backend_contract_paged.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/backend_contract_paged.py deleted file mode 100644 index d79a224281a2..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/backend_contract_paged.py +++ /dev/null @@ -1,27 +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.paging import Paged - - -class BackendContractPaged(Paged): - """ - A paging container for iterating over a list of :class:`BackendContract ` object - """ - - _attribute_map = { - 'next_link': {'key': 'nextLink', 'type': 'str'}, - 'current_page': {'key': 'value', 'type': '[BackendContract]'} - } - - def __init__(self, *args, **kwargs): - - super(BackendContractPaged, self).__init__(*args, **kwargs) diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/backend_contract_py3.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/backend_contract_py3.py deleted file mode 100644 index bb2138c77a9e..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/backend_contract_py3.py +++ /dev/null @@ -1,89 +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 .resource_py3 import Resource - - -class BackendContract(Resource): - """Backend details. - - Variables are only populated by the server, and will be ignored when - sending a request. - - All required parameters must be populated in order to send to Azure. - - :ivar id: Resource ID. - :vartype id: str - :ivar name: Resource name. - :vartype name: str - :ivar type: Resource type for API Management resource. - :vartype type: str - :param title: Backend Title. - :type title: str - :param description: Backend Description. - :type description: str - :param resource_id: Management Uri of the Resource in External System. - This url can be the Arm Resource Id of Logic Apps, Function Apps or Api - Apps. - :type resource_id: str - :param properties: Backend Properties contract - :type properties: ~azure.mgmt.apimanagement.models.BackendProperties - :param credentials: Backend Credentials Contract Properties - :type credentials: - ~azure.mgmt.apimanagement.models.BackendCredentialsContract - :param proxy: Backend Proxy Contract Properties - :type proxy: ~azure.mgmt.apimanagement.models.BackendProxyContract - :param tls: Backend TLS Properties - :type tls: ~azure.mgmt.apimanagement.models.BackendTlsProperties - :param url: Required. Runtime Url of the Backend. - :type url: str - :param protocol: Required. Backend communication protocol. Possible values - include: 'http', 'soap' - :type protocol: str or ~azure.mgmt.apimanagement.models.BackendProtocol - """ - - _validation = { - 'id': {'readonly': True}, - 'name': {'readonly': True}, - 'type': {'readonly': True}, - 'title': {'max_length': 300, 'min_length': 1}, - 'description': {'max_length': 2000, 'min_length': 1}, - 'resource_id': {'max_length': 2000, 'min_length': 1}, - 'url': {'required': True, 'max_length': 2000, 'min_length': 1}, - 'protocol': {'required': True}, - } - - _attribute_map = { - 'id': {'key': 'id', 'type': 'str'}, - 'name': {'key': 'name', 'type': 'str'}, - 'type': {'key': 'type', 'type': 'str'}, - 'title': {'key': 'properties.title', 'type': 'str'}, - 'description': {'key': 'properties.description', 'type': 'str'}, - 'resource_id': {'key': 'properties.resourceId', 'type': 'str'}, - 'properties': {'key': 'properties.properties', 'type': 'BackendProperties'}, - 'credentials': {'key': 'properties.credentials', 'type': 'BackendCredentialsContract'}, - 'proxy': {'key': 'properties.proxy', 'type': 'BackendProxyContract'}, - 'tls': {'key': 'properties.tls', 'type': 'BackendTlsProperties'}, - 'url': {'key': 'properties.url', 'type': 'str'}, - 'protocol': {'key': 'properties.protocol', 'type': 'str'}, - } - - def __init__(self, *, url: str, protocol, title: str=None, description: str=None, resource_id: str=None, properties=None, credentials=None, proxy=None, tls=None, **kwargs) -> None: - super(BackendContract, self).__init__(**kwargs) - self.title = title - self.description = description - self.resource_id = resource_id - self.properties = properties - self.credentials = credentials - self.proxy = proxy - self.tls = tls - self.url = url - self.protocol = protocol diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/backend_credentials_contract.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/backend_credentials_contract.py deleted file mode 100644 index 5a260a612603..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/backend_credentials_contract.py +++ /dev/null @@ -1,45 +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 BackendCredentialsContract(Model): - """Details of the Credentials used to connect to Backend. - - :param certificate: List of Client Certificate Thumbprint. - :type certificate: list[str] - :param query: Query Parameter description. - :type query: dict[str, list[str]] - :param header: Header Parameter description. - :type header: dict[str, list[str]] - :param authorization: Authorization header authentication - :type authorization: - ~azure.mgmt.apimanagement.models.BackendAuthorizationHeaderCredentials - """ - - _validation = { - 'certificate': {'max_items': 32}, - } - - _attribute_map = { - 'certificate': {'key': 'certificate', 'type': '[str]'}, - 'query': {'key': 'query', 'type': '{[str]}'}, - 'header': {'key': 'header', 'type': '{[str]}'}, - 'authorization': {'key': 'authorization', 'type': 'BackendAuthorizationHeaderCredentials'}, - } - - def __init__(self, **kwargs): - super(BackendCredentialsContract, self).__init__(**kwargs) - self.certificate = kwargs.get('certificate', None) - self.query = kwargs.get('query', None) - self.header = kwargs.get('header', None) - self.authorization = kwargs.get('authorization', None) diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/backend_credentials_contract_py3.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/backend_credentials_contract_py3.py deleted file mode 100644 index 437317e64592..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/backend_credentials_contract_py3.py +++ /dev/null @@ -1,45 +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 BackendCredentialsContract(Model): - """Details of the Credentials used to connect to Backend. - - :param certificate: List of Client Certificate Thumbprint. - :type certificate: list[str] - :param query: Query Parameter description. - :type query: dict[str, list[str]] - :param header: Header Parameter description. - :type header: dict[str, list[str]] - :param authorization: Authorization header authentication - :type authorization: - ~azure.mgmt.apimanagement.models.BackendAuthorizationHeaderCredentials - """ - - _validation = { - 'certificate': {'max_items': 32}, - } - - _attribute_map = { - 'certificate': {'key': 'certificate', 'type': '[str]'}, - 'query': {'key': 'query', 'type': '{[str]}'}, - 'header': {'key': 'header', 'type': '{[str]}'}, - 'authorization': {'key': 'authorization', 'type': 'BackendAuthorizationHeaderCredentials'}, - } - - def __init__(self, *, certificate=None, query=None, header=None, authorization=None, **kwargs) -> None: - super(BackendCredentialsContract, self).__init__(**kwargs) - self.certificate = certificate - self.query = query - self.header = header - self.authorization = authorization diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/backend_properties.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/backend_properties.py deleted file mode 100644 index 6772b9235485..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/backend_properties.py +++ /dev/null @@ -1,29 +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 BackendProperties(Model): - """Properties specific to the Backend Type. - - :param service_fabric_cluster: Backend Service Fabric Cluster Properties - :type service_fabric_cluster: - ~azure.mgmt.apimanagement.models.BackendServiceFabricClusterProperties - """ - - _attribute_map = { - 'service_fabric_cluster': {'key': 'serviceFabricCluster', 'type': 'BackendServiceFabricClusterProperties'}, - } - - def __init__(self, **kwargs): - super(BackendProperties, self).__init__(**kwargs) - self.service_fabric_cluster = kwargs.get('service_fabric_cluster', None) diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/backend_properties_py3.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/backend_properties_py3.py deleted file mode 100644 index b84cc3f57d84..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/backend_properties_py3.py +++ /dev/null @@ -1,29 +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 BackendProperties(Model): - """Properties specific to the Backend Type. - - :param service_fabric_cluster: Backend Service Fabric Cluster Properties - :type service_fabric_cluster: - ~azure.mgmt.apimanagement.models.BackendServiceFabricClusterProperties - """ - - _attribute_map = { - 'service_fabric_cluster': {'key': 'serviceFabricCluster', 'type': 'BackendServiceFabricClusterProperties'}, - } - - def __init__(self, *, service_fabric_cluster=None, **kwargs) -> None: - super(BackendProperties, self).__init__(**kwargs) - self.service_fabric_cluster = service_fabric_cluster diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/backend_proxy_contract.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/backend_proxy_contract.py deleted file mode 100644 index d47cd57bbd1c..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/backend_proxy_contract.py +++ /dev/null @@ -1,44 +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 BackendProxyContract(Model): - """Details of the Backend WebProxy Server to use in the Request to Backend. - - All required parameters must be populated in order to send to Azure. - - :param url: Required. WebProxy Server AbsoluteUri property which includes - the entire URI stored in the Uri instance, including all fragments and - query strings. - :type url: str - :param username: Username to connect to the WebProxy server - :type username: str - :param password: Password to connect to the WebProxy Server - :type password: str - """ - - _validation = { - 'url': {'required': True, 'max_length': 2000, 'min_length': 1}, - } - - _attribute_map = { - 'url': {'key': 'url', 'type': 'str'}, - 'username': {'key': 'username', 'type': 'str'}, - 'password': {'key': 'password', 'type': 'str'}, - } - - def __init__(self, **kwargs): - super(BackendProxyContract, self).__init__(**kwargs) - self.url = kwargs.get('url', None) - self.username = kwargs.get('username', None) - self.password = kwargs.get('password', None) diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/backend_proxy_contract_py3.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/backend_proxy_contract_py3.py deleted file mode 100644 index faee560245f7..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/backend_proxy_contract_py3.py +++ /dev/null @@ -1,44 +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 BackendProxyContract(Model): - """Details of the Backend WebProxy Server to use in the Request to Backend. - - All required parameters must be populated in order to send to Azure. - - :param url: Required. WebProxy Server AbsoluteUri property which includes - the entire URI stored in the Uri instance, including all fragments and - query strings. - :type url: str - :param username: Username to connect to the WebProxy server - :type username: str - :param password: Password to connect to the WebProxy Server - :type password: str - """ - - _validation = { - 'url': {'required': True, 'max_length': 2000, 'min_length': 1}, - } - - _attribute_map = { - 'url': {'key': 'url', 'type': 'str'}, - 'username': {'key': 'username', 'type': 'str'}, - 'password': {'key': 'password', 'type': 'str'}, - } - - def __init__(self, *, url: str, username: str=None, password: str=None, **kwargs) -> None: - super(BackendProxyContract, self).__init__(**kwargs) - self.url = url - self.username = username - self.password = password diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/backend_reconnect_contract.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/backend_reconnect_contract.py deleted file mode 100644 index 3ca83471ba8d..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/backend_reconnect_contract.py +++ /dev/null @@ -1,47 +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 .resource import Resource - - -class BackendReconnectContract(Resource): - """Reconnect request parameters. - - Variables are only populated by the server, and will be ignored when - sending a request. - - :ivar id: Resource ID. - :vartype id: str - :ivar name: Resource name. - :vartype name: str - :ivar type: Resource type for API Management resource. - :vartype type: str - :param after: Duration in ISO8601 format after which reconnect will be - initiated. Minimum duration of the Reconnect is PT2M. - :type after: timedelta - """ - - _validation = { - 'id': {'readonly': True}, - 'name': {'readonly': True}, - 'type': {'readonly': True}, - } - - _attribute_map = { - 'id': {'key': 'id', 'type': 'str'}, - 'name': {'key': 'name', 'type': 'str'}, - 'type': {'key': 'type', 'type': 'str'}, - 'after': {'key': 'properties.after', 'type': 'duration'}, - } - - def __init__(self, **kwargs): - super(BackendReconnectContract, self).__init__(**kwargs) - self.after = kwargs.get('after', None) diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/backend_reconnect_contract_py3.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/backend_reconnect_contract_py3.py deleted file mode 100644 index 5e193014df50..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/backend_reconnect_contract_py3.py +++ /dev/null @@ -1,47 +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 .resource_py3 import Resource - - -class BackendReconnectContract(Resource): - """Reconnect request parameters. - - Variables are only populated by the server, and will be ignored when - sending a request. - - :ivar id: Resource ID. - :vartype id: str - :ivar name: Resource name. - :vartype name: str - :ivar type: Resource type for API Management resource. - :vartype type: str - :param after: Duration in ISO8601 format after which reconnect will be - initiated. Minimum duration of the Reconnect is PT2M. - :type after: timedelta - """ - - _validation = { - 'id': {'readonly': True}, - 'name': {'readonly': True}, - 'type': {'readonly': True}, - } - - _attribute_map = { - 'id': {'key': 'id', 'type': 'str'}, - 'name': {'key': 'name', 'type': 'str'}, - 'type': {'key': 'type', 'type': 'str'}, - 'after': {'key': 'properties.after', 'type': 'duration'}, - } - - def __init__(self, *, after=None, **kwargs) -> None: - super(BackendReconnectContract, self).__init__(**kwargs) - self.after = after diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/backend_service_fabric_cluster_properties.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/backend_service_fabric_cluster_properties.py deleted file mode 100644 index cd558fcef895..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/backend_service_fabric_cluster_properties.py +++ /dev/null @@ -1,55 +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 BackendServiceFabricClusterProperties(Model): - """Properties of the Service Fabric Type Backend. - - All required parameters must be populated in order to send to Azure. - - :param client_certificatethumbprint: Required. The client certificate - thumbprint for the management endpoint. - :type client_certificatethumbprint: str - :param max_partition_resolution_retries: Maximum number of retries while - attempting resolve the partition. - :type max_partition_resolution_retries: int - :param management_endpoints: Required. The cluster management endpoint. - :type management_endpoints: list[str] - :param server_certificate_thumbprints: Thumbprints of certificates cluster - management service uses for tls communication - :type server_certificate_thumbprints: list[str] - :param server_x509_names: Server X509 Certificate Names Collection - :type server_x509_names: - list[~azure.mgmt.apimanagement.models.X509CertificateName] - """ - - _validation = { - 'client_certificatethumbprint': {'required': True}, - 'management_endpoints': {'required': True}, - } - - _attribute_map = { - 'client_certificatethumbprint': {'key': 'clientCertificatethumbprint', 'type': 'str'}, - 'max_partition_resolution_retries': {'key': 'maxPartitionResolutionRetries', 'type': 'int'}, - 'management_endpoints': {'key': 'managementEndpoints', 'type': '[str]'}, - 'server_certificate_thumbprints': {'key': 'serverCertificateThumbprints', 'type': '[str]'}, - 'server_x509_names': {'key': 'serverX509Names', 'type': '[X509CertificateName]'}, - } - - def __init__(self, **kwargs): - super(BackendServiceFabricClusterProperties, self).__init__(**kwargs) - self.client_certificatethumbprint = kwargs.get('client_certificatethumbprint', None) - self.max_partition_resolution_retries = kwargs.get('max_partition_resolution_retries', None) - self.management_endpoints = kwargs.get('management_endpoints', None) - self.server_certificate_thumbprints = kwargs.get('server_certificate_thumbprints', None) - self.server_x509_names = kwargs.get('server_x509_names', None) diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/backend_service_fabric_cluster_properties_py3.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/backend_service_fabric_cluster_properties_py3.py deleted file mode 100644 index 7a405ec352b2..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/backend_service_fabric_cluster_properties_py3.py +++ /dev/null @@ -1,55 +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 BackendServiceFabricClusterProperties(Model): - """Properties of the Service Fabric Type Backend. - - All required parameters must be populated in order to send to Azure. - - :param client_certificatethumbprint: Required. The client certificate - thumbprint for the management endpoint. - :type client_certificatethumbprint: str - :param max_partition_resolution_retries: Maximum number of retries while - attempting resolve the partition. - :type max_partition_resolution_retries: int - :param management_endpoints: Required. The cluster management endpoint. - :type management_endpoints: list[str] - :param server_certificate_thumbprints: Thumbprints of certificates cluster - management service uses for tls communication - :type server_certificate_thumbprints: list[str] - :param server_x509_names: Server X509 Certificate Names Collection - :type server_x509_names: - list[~azure.mgmt.apimanagement.models.X509CertificateName] - """ - - _validation = { - 'client_certificatethumbprint': {'required': True}, - 'management_endpoints': {'required': True}, - } - - _attribute_map = { - 'client_certificatethumbprint': {'key': 'clientCertificatethumbprint', 'type': 'str'}, - 'max_partition_resolution_retries': {'key': 'maxPartitionResolutionRetries', 'type': 'int'}, - 'management_endpoints': {'key': 'managementEndpoints', 'type': '[str]'}, - 'server_certificate_thumbprints': {'key': 'serverCertificateThumbprints', 'type': '[str]'}, - 'server_x509_names': {'key': 'serverX509Names', 'type': '[X509CertificateName]'}, - } - - def __init__(self, *, client_certificatethumbprint: str, management_endpoints, max_partition_resolution_retries: int=None, server_certificate_thumbprints=None, server_x509_names=None, **kwargs) -> None: - super(BackendServiceFabricClusterProperties, self).__init__(**kwargs) - self.client_certificatethumbprint = client_certificatethumbprint - self.max_partition_resolution_retries = max_partition_resolution_retries - self.management_endpoints = management_endpoints - self.server_certificate_thumbprints = server_certificate_thumbprints - self.server_x509_names = server_x509_names diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/backend_tls_properties.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/backend_tls_properties.py deleted file mode 100644 index 8524bf76f66f..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/backend_tls_properties.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 BackendTlsProperties(Model): - """Properties controlling TLS Certificate Validation. - - :param validate_certificate_chain: Flag indicating whether SSL certificate - chain validation should be done when using self-signed certificates for - this backend host. Default value: True . - :type validate_certificate_chain: bool - :param validate_certificate_name: Flag indicating whether SSL certificate - name validation should be done when using self-signed certificates for - this backend host. Default value: True . - :type validate_certificate_name: bool - """ - - _attribute_map = { - 'validate_certificate_chain': {'key': 'validateCertificateChain', 'type': 'bool'}, - 'validate_certificate_name': {'key': 'validateCertificateName', 'type': 'bool'}, - } - - def __init__(self, **kwargs): - super(BackendTlsProperties, self).__init__(**kwargs) - self.validate_certificate_chain = kwargs.get('validate_certificate_chain', True) - self.validate_certificate_name = kwargs.get('validate_certificate_name', True) diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/backend_tls_properties_py3.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/backend_tls_properties_py3.py deleted file mode 100644 index a9596d94041e..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/backend_tls_properties_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 BackendTlsProperties(Model): - """Properties controlling TLS Certificate Validation. - - :param validate_certificate_chain: Flag indicating whether SSL certificate - chain validation should be done when using self-signed certificates for - this backend host. Default value: True . - :type validate_certificate_chain: bool - :param validate_certificate_name: Flag indicating whether SSL certificate - name validation should be done when using self-signed certificates for - this backend host. Default value: True . - :type validate_certificate_name: bool - """ - - _attribute_map = { - 'validate_certificate_chain': {'key': 'validateCertificateChain', 'type': 'bool'}, - 'validate_certificate_name': {'key': 'validateCertificateName', 'type': 'bool'}, - } - - def __init__(self, *, validate_certificate_chain: bool=True, validate_certificate_name: bool=True, **kwargs) -> None: - super(BackendTlsProperties, self).__init__(**kwargs) - self.validate_certificate_chain = validate_certificate_chain - self.validate_certificate_name = validate_certificate_name diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/backend_update_parameters.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/backend_update_parameters.py deleted file mode 100644 index a74bfecb8a4a..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/backend_update_parameters.py +++ /dev/null @@ -1,71 +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 BackendUpdateParameters(Model): - """Backend update parameters. - - :param title: Backend Title. - :type title: str - :param description: Backend Description. - :type description: str - :param resource_id: Management Uri of the Resource in External System. - This url can be the Arm Resource Id of Logic Apps, Function Apps or Api - Apps. - :type resource_id: str - :param properties: Backend Properties contract - :type properties: ~azure.mgmt.apimanagement.models.BackendProperties - :param credentials: Backend Credentials Contract Properties - :type credentials: - ~azure.mgmt.apimanagement.models.BackendCredentialsContract - :param proxy: Backend Proxy Contract Properties - :type proxy: ~azure.mgmt.apimanagement.models.BackendProxyContract - :param tls: Backend TLS Properties - :type tls: ~azure.mgmt.apimanagement.models.BackendTlsProperties - :param url: Runtime Url of the Backend. - :type url: str - :param protocol: Backend communication protocol. Possible values include: - 'http', 'soap' - :type protocol: str or ~azure.mgmt.apimanagement.models.BackendProtocol - """ - - _validation = { - 'title': {'max_length': 300, 'min_length': 1}, - 'description': {'max_length': 2000, 'min_length': 1}, - 'resource_id': {'max_length': 2000, 'min_length': 1}, - 'url': {'max_length': 2000, 'min_length': 1}, - } - - _attribute_map = { - 'title': {'key': 'properties.title', 'type': 'str'}, - 'description': {'key': 'properties.description', 'type': 'str'}, - 'resource_id': {'key': 'properties.resourceId', 'type': 'str'}, - 'properties': {'key': 'properties.properties', 'type': 'BackendProperties'}, - 'credentials': {'key': 'properties.credentials', 'type': 'BackendCredentialsContract'}, - 'proxy': {'key': 'properties.proxy', 'type': 'BackendProxyContract'}, - 'tls': {'key': 'properties.tls', 'type': 'BackendTlsProperties'}, - 'url': {'key': 'properties.url', 'type': 'str'}, - 'protocol': {'key': 'properties.protocol', 'type': 'str'}, - } - - def __init__(self, **kwargs): - super(BackendUpdateParameters, self).__init__(**kwargs) - self.title = kwargs.get('title', None) - self.description = kwargs.get('description', None) - self.resource_id = kwargs.get('resource_id', None) - self.properties = kwargs.get('properties', None) - self.credentials = kwargs.get('credentials', None) - self.proxy = kwargs.get('proxy', None) - self.tls = kwargs.get('tls', None) - self.url = kwargs.get('url', None) - self.protocol = kwargs.get('protocol', None) diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/backend_update_parameters_py3.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/backend_update_parameters_py3.py deleted file mode 100644 index a83a9a55586c..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/backend_update_parameters_py3.py +++ /dev/null @@ -1,71 +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 BackendUpdateParameters(Model): - """Backend update parameters. - - :param title: Backend Title. - :type title: str - :param description: Backend Description. - :type description: str - :param resource_id: Management Uri of the Resource in External System. - This url can be the Arm Resource Id of Logic Apps, Function Apps or Api - Apps. - :type resource_id: str - :param properties: Backend Properties contract - :type properties: ~azure.mgmt.apimanagement.models.BackendProperties - :param credentials: Backend Credentials Contract Properties - :type credentials: - ~azure.mgmt.apimanagement.models.BackendCredentialsContract - :param proxy: Backend Proxy Contract Properties - :type proxy: ~azure.mgmt.apimanagement.models.BackendProxyContract - :param tls: Backend TLS Properties - :type tls: ~azure.mgmt.apimanagement.models.BackendTlsProperties - :param url: Runtime Url of the Backend. - :type url: str - :param protocol: Backend communication protocol. Possible values include: - 'http', 'soap' - :type protocol: str or ~azure.mgmt.apimanagement.models.BackendProtocol - """ - - _validation = { - 'title': {'max_length': 300, 'min_length': 1}, - 'description': {'max_length': 2000, 'min_length': 1}, - 'resource_id': {'max_length': 2000, 'min_length': 1}, - 'url': {'max_length': 2000, 'min_length': 1}, - } - - _attribute_map = { - 'title': {'key': 'properties.title', 'type': 'str'}, - 'description': {'key': 'properties.description', 'type': 'str'}, - 'resource_id': {'key': 'properties.resourceId', 'type': 'str'}, - 'properties': {'key': 'properties.properties', 'type': 'BackendProperties'}, - 'credentials': {'key': 'properties.credentials', 'type': 'BackendCredentialsContract'}, - 'proxy': {'key': 'properties.proxy', 'type': 'BackendProxyContract'}, - 'tls': {'key': 'properties.tls', 'type': 'BackendTlsProperties'}, - 'url': {'key': 'properties.url', 'type': 'str'}, - 'protocol': {'key': 'properties.protocol', 'type': 'str'}, - } - - def __init__(self, *, title: str=None, description: str=None, resource_id: str=None, properties=None, credentials=None, proxy=None, tls=None, url: str=None, protocol=None, **kwargs) -> None: - super(BackendUpdateParameters, self).__init__(**kwargs) - self.title = title - self.description = description - self.resource_id = resource_id - self.properties = properties - self.credentials = credentials - self.proxy = proxy - self.tls = tls - self.url = url - self.protocol = protocol diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/body_diagnostic_settings.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/body_diagnostic_settings.py deleted file mode 100644 index b0f9021fbada..000000000000 --- a/sdk/apimanagement/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/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/body_diagnostic_settings_py3.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/body_diagnostic_settings_py3.py deleted file mode 100644 index 4192e4a3dc58..000000000000 --- a/sdk/apimanagement/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/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/cache_contract.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/cache_contract.py deleted file mode 100644 index ea1874f4606c..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/cache_contract.py +++ /dev/null @@ -1,60 +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 .resource import Resource - - -class CacheContract(Resource): - """Cache details. - - Variables are only populated by the server, and will be ignored when - sending a request. - - All required parameters must be populated in order to send to Azure. - - :ivar id: Resource ID. - :vartype id: str - :ivar name: Resource name. - :vartype name: str - :ivar type: Resource type for API Management resource. - :vartype type: str - :param description: Cache description - :type description: str - :param connection_string: Required. Runtime connection string to cache - :type connection_string: str - :param resource_id: Original uri of entity in external system cache points - to - :type resource_id: str - """ - - _validation = { - 'id': {'readonly': True}, - 'name': {'readonly': True}, - 'type': {'readonly': True}, - 'description': {'max_length': 2000}, - 'connection_string': {'required': True, 'max_length': 300}, - 'resource_id': {'max_length': 2000}, - } - - _attribute_map = { - 'id': {'key': 'id', 'type': 'str'}, - 'name': {'key': 'name', 'type': 'str'}, - 'type': {'key': 'type', 'type': 'str'}, - 'description': {'key': 'properties.description', 'type': 'str'}, - 'connection_string': {'key': 'properties.connectionString', 'type': 'str'}, - 'resource_id': {'key': 'properties.resourceId', 'type': 'str'}, - } - - def __init__(self, **kwargs): - super(CacheContract, self).__init__(**kwargs) - self.description = kwargs.get('description', None) - self.connection_string = kwargs.get('connection_string', None) - self.resource_id = kwargs.get('resource_id', None) diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/cache_contract_paged.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/cache_contract_paged.py deleted file mode 100644 index 13b6af191d44..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/cache_contract_paged.py +++ /dev/null @@ -1,27 +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.paging import Paged - - -class CacheContractPaged(Paged): - """ - A paging container for iterating over a list of :class:`CacheContract ` object - """ - - _attribute_map = { - 'next_link': {'key': 'nextLink', 'type': 'str'}, - 'current_page': {'key': 'value', 'type': '[CacheContract]'} - } - - def __init__(self, *args, **kwargs): - - super(CacheContractPaged, self).__init__(*args, **kwargs) diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/cache_contract_py3.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/cache_contract_py3.py deleted file mode 100644 index 646e00c0e511..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/cache_contract_py3.py +++ /dev/null @@ -1,60 +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 .resource_py3 import Resource - - -class CacheContract(Resource): - """Cache details. - - Variables are only populated by the server, and will be ignored when - sending a request. - - All required parameters must be populated in order to send to Azure. - - :ivar id: Resource ID. - :vartype id: str - :ivar name: Resource name. - :vartype name: str - :ivar type: Resource type for API Management resource. - :vartype type: str - :param description: Cache description - :type description: str - :param connection_string: Required. Runtime connection string to cache - :type connection_string: str - :param resource_id: Original uri of entity in external system cache points - to - :type resource_id: str - """ - - _validation = { - 'id': {'readonly': True}, - 'name': {'readonly': True}, - 'type': {'readonly': True}, - 'description': {'max_length': 2000}, - 'connection_string': {'required': True, 'max_length': 300}, - 'resource_id': {'max_length': 2000}, - } - - _attribute_map = { - 'id': {'key': 'id', 'type': 'str'}, - 'name': {'key': 'name', 'type': 'str'}, - 'type': {'key': 'type', 'type': 'str'}, - 'description': {'key': 'properties.description', 'type': 'str'}, - 'connection_string': {'key': 'properties.connectionString', 'type': 'str'}, - 'resource_id': {'key': 'properties.resourceId', 'type': 'str'}, - } - - def __init__(self, *, connection_string: str, description: str=None, resource_id: str=None, **kwargs) -> None: - super(CacheContract, self).__init__(**kwargs) - self.description = description - self.connection_string = connection_string - self.resource_id = resource_id diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/cache_update_parameters.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/cache_update_parameters.py deleted file mode 100644 index 541a426dd833..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/cache_update_parameters.py +++ /dev/null @@ -1,43 +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 CacheUpdateParameters(Model): - """Cache update details. - - :param description: Cache description - :type description: str - :param connection_string: Runtime connection string to cache - :type connection_string: str - :param resource_id: Original uri of entity in external system cache points - to - :type resource_id: str - """ - - _validation = { - 'description': {'max_length': 2000}, - 'connection_string': {'max_length': 300}, - 'resource_id': {'max_length': 2000}, - } - - _attribute_map = { - 'description': {'key': 'properties.description', 'type': 'str'}, - 'connection_string': {'key': 'properties.connectionString', 'type': 'str'}, - 'resource_id': {'key': 'properties.resourceId', 'type': 'str'}, - } - - def __init__(self, **kwargs): - super(CacheUpdateParameters, self).__init__(**kwargs) - self.description = kwargs.get('description', None) - self.connection_string = kwargs.get('connection_string', None) - self.resource_id = kwargs.get('resource_id', None) diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/cache_update_parameters_py3.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/cache_update_parameters_py3.py deleted file mode 100644 index 88a8f3d42bce..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/cache_update_parameters_py3.py +++ /dev/null @@ -1,43 +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 CacheUpdateParameters(Model): - """Cache update details. - - :param description: Cache description - :type description: str - :param connection_string: Runtime connection string to cache - :type connection_string: str - :param resource_id: Original uri of entity in external system cache points - to - :type resource_id: str - """ - - _validation = { - 'description': {'max_length': 2000}, - 'connection_string': {'max_length': 300}, - 'resource_id': {'max_length': 2000}, - } - - _attribute_map = { - 'description': {'key': 'properties.description', 'type': 'str'}, - 'connection_string': {'key': 'properties.connectionString', 'type': 'str'}, - 'resource_id': {'key': 'properties.resourceId', 'type': 'str'}, - } - - def __init__(self, *, description: str=None, connection_string: str=None, resource_id: str=None, **kwargs) -> None: - super(CacheUpdateParameters, self).__init__(**kwargs) - self.description = description - self.connection_string = connection_string - self.resource_id = resource_id diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/certificate_configuration.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/certificate_configuration.py deleted file mode 100644 index 82f9e6d8f4ef..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/certificate_configuration.py +++ /dev/null @@ -1,50 +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 CertificateConfiguration(Model): - """Certificate configuration which consist of non-trusted intermediates and - root certificates. - - All required parameters must be populated in order to send to Azure. - - :param encoded_certificate: Base64 Encoded certificate. - :type encoded_certificate: str - :param certificate_password: Certificate Password. - :type certificate_password: str - :param store_name: Required. The - System.Security.Cryptography.x509certificates.StoreName certificate store - location. Only Root and CertificateAuthority are valid locations. Possible - values include: 'CertificateAuthority', 'Root' - :type store_name: str or ~azure.mgmt.apimanagement.models.enum - :param certificate: Certificate information. - :type certificate: ~azure.mgmt.apimanagement.models.CertificateInformation - """ - - _validation = { - 'store_name': {'required': True}, - } - - _attribute_map = { - 'encoded_certificate': {'key': 'encodedCertificate', 'type': 'str'}, - 'certificate_password': {'key': 'certificatePassword', 'type': 'str'}, - 'store_name': {'key': 'storeName', 'type': 'str'}, - 'certificate': {'key': 'certificate', 'type': 'CertificateInformation'}, - } - - def __init__(self, **kwargs): - super(CertificateConfiguration, self).__init__(**kwargs) - self.encoded_certificate = kwargs.get('encoded_certificate', None) - self.certificate_password = kwargs.get('certificate_password', None) - self.store_name = kwargs.get('store_name', None) - self.certificate = kwargs.get('certificate', None) diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/certificate_configuration_py3.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/certificate_configuration_py3.py deleted file mode 100644 index f15c5709a513..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/certificate_configuration_py3.py +++ /dev/null @@ -1,50 +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 CertificateConfiguration(Model): - """Certificate configuration which consist of non-trusted intermediates and - root certificates. - - All required parameters must be populated in order to send to Azure. - - :param encoded_certificate: Base64 Encoded certificate. - :type encoded_certificate: str - :param certificate_password: Certificate Password. - :type certificate_password: str - :param store_name: Required. The - System.Security.Cryptography.x509certificates.StoreName certificate store - location. Only Root and CertificateAuthority are valid locations. Possible - values include: 'CertificateAuthority', 'Root' - :type store_name: str or ~azure.mgmt.apimanagement.models.enum - :param certificate: Certificate information. - :type certificate: ~azure.mgmt.apimanagement.models.CertificateInformation - """ - - _validation = { - 'store_name': {'required': True}, - } - - _attribute_map = { - 'encoded_certificate': {'key': 'encodedCertificate', 'type': 'str'}, - 'certificate_password': {'key': 'certificatePassword', 'type': 'str'}, - 'store_name': {'key': 'storeName', 'type': 'str'}, - 'certificate': {'key': 'certificate', 'type': 'CertificateInformation'}, - } - - def __init__(self, *, store_name, encoded_certificate: str=None, certificate_password: str=None, certificate=None, **kwargs) -> None: - super(CertificateConfiguration, self).__init__(**kwargs) - self.encoded_certificate = encoded_certificate - self.certificate_password = certificate_password - self.store_name = store_name - self.certificate = certificate diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/certificate_contract.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/certificate_contract.py deleted file mode 100644 index af06bb20cf95..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/certificate_contract.py +++ /dev/null @@ -1,61 +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 .resource import Resource - - -class CertificateContract(Resource): - """Certificate details. - - Variables are only populated by the server, and will be ignored when - sending a request. - - All required parameters must be populated in order to send to Azure. - - :ivar id: Resource ID. - :vartype id: str - :ivar name: Resource name. - :vartype name: str - :ivar type: Resource type for API Management resource. - :vartype type: str - :param subject: Required. Subject attribute of the certificate. - :type subject: str - :param thumbprint: Required. Thumbprint of the certificate. - :type thumbprint: str - :param expiration_date: Required. Expiration date of the certificate. The - date conforms to the following format: `yyyy-MM-ddTHH:mm:ssZ` as specified - by the ISO 8601 standard. - :type expiration_date: datetime - """ - - _validation = { - 'id': {'readonly': True}, - 'name': {'readonly': True}, - 'type': {'readonly': True}, - 'subject': {'required': True}, - 'thumbprint': {'required': True}, - 'expiration_date': {'required': True}, - } - - _attribute_map = { - 'id': {'key': 'id', 'type': 'str'}, - 'name': {'key': 'name', 'type': 'str'}, - 'type': {'key': 'type', 'type': 'str'}, - 'subject': {'key': 'properties.subject', 'type': 'str'}, - 'thumbprint': {'key': 'properties.thumbprint', 'type': 'str'}, - 'expiration_date': {'key': 'properties.expirationDate', 'type': 'iso-8601'}, - } - - def __init__(self, **kwargs): - super(CertificateContract, self).__init__(**kwargs) - self.subject = kwargs.get('subject', None) - self.thumbprint = kwargs.get('thumbprint', None) - self.expiration_date = kwargs.get('expiration_date', None) diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/certificate_contract_paged.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/certificate_contract_paged.py deleted file mode 100644 index e2d7255ecfa6..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/certificate_contract_paged.py +++ /dev/null @@ -1,27 +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.paging import Paged - - -class CertificateContractPaged(Paged): - """ - A paging container for iterating over a list of :class:`CertificateContract ` object - """ - - _attribute_map = { - 'next_link': {'key': 'nextLink', 'type': 'str'}, - 'current_page': {'key': 'value', 'type': '[CertificateContract]'} - } - - def __init__(self, *args, **kwargs): - - super(CertificateContractPaged, self).__init__(*args, **kwargs) diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/certificate_contract_py3.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/certificate_contract_py3.py deleted file mode 100644 index 464100179414..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/certificate_contract_py3.py +++ /dev/null @@ -1,61 +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 .resource_py3 import Resource - - -class CertificateContract(Resource): - """Certificate details. - - Variables are only populated by the server, and will be ignored when - sending a request. - - All required parameters must be populated in order to send to Azure. - - :ivar id: Resource ID. - :vartype id: str - :ivar name: Resource name. - :vartype name: str - :ivar type: Resource type for API Management resource. - :vartype type: str - :param subject: Required. Subject attribute of the certificate. - :type subject: str - :param thumbprint: Required. Thumbprint of the certificate. - :type thumbprint: str - :param expiration_date: Required. Expiration date of the certificate. The - date conforms to the following format: `yyyy-MM-ddTHH:mm:ssZ` as specified - by the ISO 8601 standard. - :type expiration_date: datetime - """ - - _validation = { - 'id': {'readonly': True}, - 'name': {'readonly': True}, - 'type': {'readonly': True}, - 'subject': {'required': True}, - 'thumbprint': {'required': True}, - 'expiration_date': {'required': True}, - } - - _attribute_map = { - 'id': {'key': 'id', 'type': 'str'}, - 'name': {'key': 'name', 'type': 'str'}, - 'type': {'key': 'type', 'type': 'str'}, - 'subject': {'key': 'properties.subject', 'type': 'str'}, - 'thumbprint': {'key': 'properties.thumbprint', 'type': 'str'}, - 'expiration_date': {'key': 'properties.expirationDate', 'type': 'iso-8601'}, - } - - def __init__(self, *, subject: str, thumbprint: str, expiration_date, **kwargs) -> None: - super(CertificateContract, self).__init__(**kwargs) - self.subject = subject - self.thumbprint = thumbprint - self.expiration_date = expiration_date diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/certificate_create_or_update_parameters.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/certificate_create_or_update_parameters.py deleted file mode 100644 index 6b195ea702a7..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/certificate_create_or_update_parameters.py +++ /dev/null @@ -1,40 +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 CertificateCreateOrUpdateParameters(Model): - """Certificate create or update details. - - All required parameters must be populated in order to send to Azure. - - :param data: Required. Base 64 encoded certificate using the - application/x-pkcs12 representation. - :type data: str - :param password: Required. Password for the Certificate - :type password: str - """ - - _validation = { - 'data': {'required': True}, - 'password': {'required': True}, - } - - _attribute_map = { - 'data': {'key': 'properties.data', 'type': 'str'}, - 'password': {'key': 'properties.password', 'type': 'str'}, - } - - def __init__(self, **kwargs): - super(CertificateCreateOrUpdateParameters, self).__init__(**kwargs) - self.data = kwargs.get('data', None) - self.password = kwargs.get('password', None) diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/certificate_create_or_update_parameters_py3.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/certificate_create_or_update_parameters_py3.py deleted file mode 100644 index 0a14fa8710ae..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/certificate_create_or_update_parameters_py3.py +++ /dev/null @@ -1,40 +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 CertificateCreateOrUpdateParameters(Model): - """Certificate create or update details. - - All required parameters must be populated in order to send to Azure. - - :param data: Required. Base 64 encoded certificate using the - application/x-pkcs12 representation. - :type data: str - :param password: Required. Password for the Certificate - :type password: str - """ - - _validation = { - 'data': {'required': True}, - 'password': {'required': True}, - } - - _attribute_map = { - 'data': {'key': 'properties.data', 'type': 'str'}, - 'password': {'key': 'properties.password', 'type': 'str'}, - } - - def __init__(self, *, data: str, password: str, **kwargs) -> None: - super(CertificateCreateOrUpdateParameters, self).__init__(**kwargs) - self.data = data - self.password = password diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/certificate_information.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/certificate_information.py deleted file mode 100644 index d66883195efe..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/certificate_information.py +++ /dev/null @@ -1,46 +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 CertificateInformation(Model): - """SSL certificate information. - - All required parameters must be populated in order to send to Azure. - - :param expiry: Required. Expiration date of the certificate. The date - conforms to the following format: `yyyy-MM-ddTHH:mm:ssZ` as specified by - the ISO 8601 standard. - :type expiry: datetime - :param thumbprint: Required. Thumbprint of the certificate. - :type thumbprint: str - :param subject: Required. Subject of the certificate. - :type subject: str - """ - - _validation = { - 'expiry': {'required': True}, - 'thumbprint': {'required': True}, - 'subject': {'required': True}, - } - - _attribute_map = { - 'expiry': {'key': 'expiry', 'type': 'iso-8601'}, - 'thumbprint': {'key': 'thumbprint', 'type': 'str'}, - 'subject': {'key': 'subject', 'type': 'str'}, - } - - def __init__(self, **kwargs): - super(CertificateInformation, self).__init__(**kwargs) - self.expiry = kwargs.get('expiry', None) - self.thumbprint = kwargs.get('thumbprint', None) - self.subject = kwargs.get('subject', None) diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/certificate_information_py3.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/certificate_information_py3.py deleted file mode 100644 index a14d9b1d7756..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/certificate_information_py3.py +++ /dev/null @@ -1,46 +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 CertificateInformation(Model): - """SSL certificate information. - - All required parameters must be populated in order to send to Azure. - - :param expiry: Required. Expiration date of the certificate. The date - conforms to the following format: `yyyy-MM-ddTHH:mm:ssZ` as specified by - the ISO 8601 standard. - :type expiry: datetime - :param thumbprint: Required. Thumbprint of the certificate. - :type thumbprint: str - :param subject: Required. Subject of the certificate. - :type subject: str - """ - - _validation = { - 'expiry': {'required': True}, - 'thumbprint': {'required': True}, - 'subject': {'required': True}, - } - - _attribute_map = { - 'expiry': {'key': 'expiry', 'type': 'iso-8601'}, - 'thumbprint': {'key': 'thumbprint', 'type': 'str'}, - 'subject': {'key': 'subject', 'type': 'str'}, - } - - def __init__(self, *, expiry, thumbprint: str, subject: str, **kwargs) -> None: - super(CertificateInformation, self).__init__(**kwargs) - self.expiry = expiry - self.thumbprint = thumbprint - self.subject = subject diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/connectivity_status_contract.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/connectivity_status_contract.py deleted file mode 100644 index 58737990e11f..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/connectivity_status_contract.py +++ /dev/null @@ -1,65 +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 ConnectivityStatusContract(Model): - """Details about connectivity to a resource. - - All required parameters must be populated in order to send to Azure. - - :param name: Required. The hostname of the resource which the service - depends on. This can be the database, storage or any other azure resource - on which the service depends upon. - :type name: str - :param status: Required. Resource Connectivity Status Type identifier. - Possible values include: 'initializing', 'success', 'failure' - :type status: str or - ~azure.mgmt.apimanagement.models.ConnectivityStatusType - :param error: Error details of the connectivity to the resource. - :type error: str - :param last_updated: Required. The date when the resource connectivity - status was last updated. This status should be updated every 15 minutes. - If this status has not been updated, then it means that the service has - lost network connectivity to the resource, from inside the Virtual - Network.The date conforms to the following format: `yyyy-MM-ddTHH:mm:ssZ` - as specified by the ISO 8601 standard. - :type last_updated: datetime - :param last_status_change: Required. The date when the resource - connectivity status last Changed from success to failure or vice-versa. - The date conforms to the following format: `yyyy-MM-ddTHH:mm:ssZ` as - specified by the ISO 8601 standard. - :type last_status_change: datetime - """ - - _validation = { - 'name': {'required': True, 'min_length': 1}, - 'status': {'required': True}, - 'last_updated': {'required': True}, - 'last_status_change': {'required': True}, - } - - _attribute_map = { - 'name': {'key': 'name', 'type': 'str'}, - 'status': {'key': 'status', 'type': 'str'}, - 'error': {'key': 'error', 'type': 'str'}, - 'last_updated': {'key': 'lastUpdated', 'type': 'iso-8601'}, - 'last_status_change': {'key': 'lastStatusChange', 'type': 'iso-8601'}, - } - - def __init__(self, **kwargs): - super(ConnectivityStatusContract, self).__init__(**kwargs) - self.name = kwargs.get('name', None) - self.status = kwargs.get('status', None) - self.error = kwargs.get('error', None) - self.last_updated = kwargs.get('last_updated', None) - self.last_status_change = kwargs.get('last_status_change', None) diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/connectivity_status_contract_py3.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/connectivity_status_contract_py3.py deleted file mode 100644 index 4ff86d73dda1..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/connectivity_status_contract_py3.py +++ /dev/null @@ -1,65 +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 ConnectivityStatusContract(Model): - """Details about connectivity to a resource. - - All required parameters must be populated in order to send to Azure. - - :param name: Required. The hostname of the resource which the service - depends on. This can be the database, storage or any other azure resource - on which the service depends upon. - :type name: str - :param status: Required. Resource Connectivity Status Type identifier. - Possible values include: 'initializing', 'success', 'failure' - :type status: str or - ~azure.mgmt.apimanagement.models.ConnectivityStatusType - :param error: Error details of the connectivity to the resource. - :type error: str - :param last_updated: Required. The date when the resource connectivity - status was last updated. This status should be updated every 15 minutes. - If this status has not been updated, then it means that the service has - lost network connectivity to the resource, from inside the Virtual - Network.The date conforms to the following format: `yyyy-MM-ddTHH:mm:ssZ` - as specified by the ISO 8601 standard. - :type last_updated: datetime - :param last_status_change: Required. The date when the resource - connectivity status last Changed from success to failure or vice-versa. - The date conforms to the following format: `yyyy-MM-ddTHH:mm:ssZ` as - specified by the ISO 8601 standard. - :type last_status_change: datetime - """ - - _validation = { - 'name': {'required': True, 'min_length': 1}, - 'status': {'required': True}, - 'last_updated': {'required': True}, - 'last_status_change': {'required': True}, - } - - _attribute_map = { - 'name': {'key': 'name', 'type': 'str'}, - 'status': {'key': 'status', 'type': 'str'}, - 'error': {'key': 'error', 'type': 'str'}, - 'last_updated': {'key': 'lastUpdated', 'type': 'iso-8601'}, - 'last_status_change': {'key': 'lastStatusChange', 'type': 'iso-8601'}, - } - - def __init__(self, *, name: str, status, last_updated, last_status_change, error: str=None, **kwargs) -> None: - super(ConnectivityStatusContract, self).__init__(**kwargs) - self.name = name - self.status = status - self.error = error - self.last_updated = last_updated - self.last_status_change = last_status_change diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/deploy_configuration_parameters.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/deploy_configuration_parameters.py deleted file mode 100644 index 3e3e7db3f36f..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/deploy_configuration_parameters.py +++ /dev/null @@ -1,40 +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 DeployConfigurationParameters(Model): - """Deploy Tenant Configuration Contract. - - All required parameters must be populated in order to send to Azure. - - :param branch: Required. The name of the Git branch from which the - configuration is to be deployed to the configuration database. - :type branch: str - :param force: The value enforcing deleting subscriptions to products that - are deleted in this update. - :type force: bool - """ - - _validation = { - 'branch': {'required': True}, - } - - _attribute_map = { - 'branch': {'key': 'properties.branch', 'type': 'str'}, - 'force': {'key': 'properties.force', 'type': 'bool'}, - } - - def __init__(self, **kwargs): - super(DeployConfigurationParameters, self).__init__(**kwargs) - self.branch = kwargs.get('branch', None) - self.force = kwargs.get('force', None) diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/deploy_configuration_parameters_py3.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/deploy_configuration_parameters_py3.py deleted file mode 100644 index f7bf03929d4d..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/deploy_configuration_parameters_py3.py +++ /dev/null @@ -1,40 +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 DeployConfigurationParameters(Model): - """Deploy Tenant Configuration Contract. - - All required parameters must be populated in order to send to Azure. - - :param branch: Required. The name of the Git branch from which the - configuration is to be deployed to the configuration database. - :type branch: str - :param force: The value enforcing deleting subscriptions to products that - are deleted in this update. - :type force: bool - """ - - _validation = { - 'branch': {'required': True}, - } - - _attribute_map = { - 'branch': {'key': 'properties.branch', 'type': 'str'}, - 'force': {'key': 'properties.force', 'type': 'bool'}, - } - - def __init__(self, *, branch: str, force: bool=None, **kwargs) -> None: - super(DeployConfigurationParameters, self).__init__(**kwargs) - self.branch = branch - self.force = force diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/diagnostic_contract.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/diagnostic_contract.py deleted file mode 100644 index 041dd6002e6a..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/diagnostic_contract.py +++ /dev/null @@ -1,75 +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 .resource import Resource - - -class DiagnosticContract(Resource): - """Diagnostic details. - - Variables are only populated by the server, and will be ignored when - sending a request. - - All required parameters must be populated in order to send to Azure. - - :ivar id: Resource ID. - :vartype id: str - :ivar name: Resource name. - :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/outgoing HTTP messages - to the Gateway. - :type frontend: - ~azure.mgmt.apimanagement.models.PipelineDiagnosticSettings - :param backend: Diagnostic settings for incoming/outgoing HTTP messages to - the Backend - :type backend: ~azure.mgmt.apimanagement.models.PipelineDiagnosticSettings - :param enable_http_correlation_headers: Whether to process Correlation - Headers coming to Api Management Service. Only applicable to Application - Insights diagnostics. Default is true. - :type enable_http_correlation_headers: bool - """ - - _validation = { - 'id': {'readonly': True}, - 'name': {'readonly': True}, - 'type': {'readonly': True}, - 'logger_id': {'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'}, - 'enable_http_correlation_headers': {'key': 'properties.enableHttpCorrelationHeaders', '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.enable_http_correlation_headers = kwargs.get('enable_http_correlation_headers', None) diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/diagnostic_contract_paged.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/diagnostic_contract_paged.py deleted file mode 100644 index ea142d87269f..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/diagnostic_contract_paged.py +++ /dev/null @@ -1,27 +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.paging import Paged - - -class DiagnosticContractPaged(Paged): - """ - A paging container for iterating over a list of :class:`DiagnosticContract ` object - """ - - _attribute_map = { - 'next_link': {'key': 'nextLink', 'type': 'str'}, - 'current_page': {'key': 'value', 'type': '[DiagnosticContract]'} - } - - def __init__(self, *args, **kwargs): - - super(DiagnosticContractPaged, self).__init__(*args, **kwargs) diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/diagnostic_contract_py3.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/diagnostic_contract_py3.py deleted file mode 100644 index b76b868476c7..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/diagnostic_contract_py3.py +++ /dev/null @@ -1,75 +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 .resource_py3 import Resource - - -class DiagnosticContract(Resource): - """Diagnostic details. - - Variables are only populated by the server, and will be ignored when - sending a request. - - All required parameters must be populated in order to send to Azure. - - :ivar id: Resource ID. - :vartype id: str - :ivar name: Resource name. - :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/outgoing HTTP messages - to the Gateway. - :type frontend: - ~azure.mgmt.apimanagement.models.PipelineDiagnosticSettings - :param backend: Diagnostic settings for incoming/outgoing HTTP messages to - the Backend - :type backend: ~azure.mgmt.apimanagement.models.PipelineDiagnosticSettings - :param enable_http_correlation_headers: Whether to process Correlation - Headers coming to Api Management Service. Only applicable to Application - Insights diagnostics. Default is true. - :type enable_http_correlation_headers: bool - """ - - _validation = { - 'id': {'readonly': True}, - 'name': {'readonly': True}, - 'type': {'readonly': True}, - 'logger_id': {'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'}, - 'enable_http_correlation_headers': {'key': 'properties.enableHttpCorrelationHeaders', 'type': 'bool'}, - } - - def __init__(self, *, logger_id: str, always_log=None, sampling=None, frontend=None, backend=None, enable_http_correlation_headers: bool=None, **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.enable_http_correlation_headers = enable_http_correlation_headers diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/email_template_contract.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/email_template_contract.py deleted file mode 100644 index c23ba2c72909..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/email_template_contract.py +++ /dev/null @@ -1,74 +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 .resource import Resource - - -class EmailTemplateContract(Resource): - """Email Template details. - - Variables are only populated by the server, and will be ignored when - sending a request. - - All required parameters must be populated in order to send to Azure. - - :ivar id: Resource ID. - :vartype id: str - :ivar name: Resource name. - :vartype name: str - :ivar type: Resource type for API Management resource. - :vartype type: str - :param subject: Required. Subject of the Template. - :type subject: str - :param body: Required. Email Template Body. This should be a valid - XDocument - :type body: str - :param title: Title of the Template. - :type title: str - :param description: Description of the Email Template. - :type description: str - :ivar is_default: Whether the template is the default template provided by - Api Management or has been edited. - :vartype is_default: bool - :param parameters: Email Template Parameter values. - :type parameters: - list[~azure.mgmt.apimanagement.models.EmailTemplateParametersContractProperties] - """ - - _validation = { - 'id': {'readonly': True}, - 'name': {'readonly': True}, - 'type': {'readonly': True}, - 'subject': {'required': True, 'max_length': 1000, 'min_length': 1}, - 'body': {'required': True, 'min_length': 1}, - 'is_default': {'readonly': True}, - } - - _attribute_map = { - 'id': {'key': 'id', 'type': 'str'}, - 'name': {'key': 'name', 'type': 'str'}, - 'type': {'key': 'type', 'type': 'str'}, - 'subject': {'key': 'properties.subject', 'type': 'str'}, - 'body': {'key': 'properties.body', 'type': 'str'}, - 'title': {'key': 'properties.title', 'type': 'str'}, - 'description': {'key': 'properties.description', 'type': 'str'}, - 'is_default': {'key': 'properties.isDefault', 'type': 'bool'}, - 'parameters': {'key': 'properties.parameters', 'type': '[EmailTemplateParametersContractProperties]'}, - } - - def __init__(self, **kwargs): - super(EmailTemplateContract, self).__init__(**kwargs) - self.subject = kwargs.get('subject', None) - self.body = kwargs.get('body', None) - self.title = kwargs.get('title', None) - self.description = kwargs.get('description', None) - self.is_default = None - self.parameters = kwargs.get('parameters', None) diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/email_template_contract_paged.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/email_template_contract_paged.py deleted file mode 100644 index 9f137e41d6a8..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/email_template_contract_paged.py +++ /dev/null @@ -1,27 +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.paging import Paged - - -class EmailTemplateContractPaged(Paged): - """ - A paging container for iterating over a list of :class:`EmailTemplateContract ` object - """ - - _attribute_map = { - 'next_link': {'key': 'nextLink', 'type': 'str'}, - 'current_page': {'key': 'value', 'type': '[EmailTemplateContract]'} - } - - def __init__(self, *args, **kwargs): - - super(EmailTemplateContractPaged, self).__init__(*args, **kwargs) diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/email_template_contract_py3.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/email_template_contract_py3.py deleted file mode 100644 index 3d3fcd217589..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/email_template_contract_py3.py +++ /dev/null @@ -1,74 +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 .resource_py3 import Resource - - -class EmailTemplateContract(Resource): - """Email Template details. - - Variables are only populated by the server, and will be ignored when - sending a request. - - All required parameters must be populated in order to send to Azure. - - :ivar id: Resource ID. - :vartype id: str - :ivar name: Resource name. - :vartype name: str - :ivar type: Resource type for API Management resource. - :vartype type: str - :param subject: Required. Subject of the Template. - :type subject: str - :param body: Required. Email Template Body. This should be a valid - XDocument - :type body: str - :param title: Title of the Template. - :type title: str - :param description: Description of the Email Template. - :type description: str - :ivar is_default: Whether the template is the default template provided by - Api Management or has been edited. - :vartype is_default: bool - :param parameters: Email Template Parameter values. - :type parameters: - list[~azure.mgmt.apimanagement.models.EmailTemplateParametersContractProperties] - """ - - _validation = { - 'id': {'readonly': True}, - 'name': {'readonly': True}, - 'type': {'readonly': True}, - 'subject': {'required': True, 'max_length': 1000, 'min_length': 1}, - 'body': {'required': True, 'min_length': 1}, - 'is_default': {'readonly': True}, - } - - _attribute_map = { - 'id': {'key': 'id', 'type': 'str'}, - 'name': {'key': 'name', 'type': 'str'}, - 'type': {'key': 'type', 'type': 'str'}, - 'subject': {'key': 'properties.subject', 'type': 'str'}, - 'body': {'key': 'properties.body', 'type': 'str'}, - 'title': {'key': 'properties.title', 'type': 'str'}, - 'description': {'key': 'properties.description', 'type': 'str'}, - 'is_default': {'key': 'properties.isDefault', 'type': 'bool'}, - 'parameters': {'key': 'properties.parameters', 'type': '[EmailTemplateParametersContractProperties]'}, - } - - def __init__(self, *, subject: str, body: str, title: str=None, description: str=None, parameters=None, **kwargs) -> None: - super(EmailTemplateContract, self).__init__(**kwargs) - self.subject = subject - self.body = body - self.title = title - self.description = description - self.is_default = None - self.parameters = parameters diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/email_template_parameters_contract_properties.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/email_template_parameters_contract_properties.py deleted file mode 100644 index 060b64257a7a..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/email_template_parameters_contract_properties.py +++ /dev/null @@ -1,42 +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 EmailTemplateParametersContractProperties(Model): - """Email Template Parameter contract. - - :param name: Template parameter name. - :type name: str - :param title: Template parameter title. - :type title: str - :param description: Template parameter description. - :type description: str - """ - - _validation = { - 'name': {'max_length': 256, 'min_length': 1, 'pattern': r'^[A-Za-z0-9-._]+$'}, - 'title': {'max_length': 4096, 'min_length': 1}, - 'description': {'max_length': 256, 'min_length': 1, 'pattern': r'^[A-Za-z0-9-._]+$'}, - } - - _attribute_map = { - 'name': {'key': 'name', 'type': 'str'}, - 'title': {'key': 'title', 'type': 'str'}, - 'description': {'key': 'description', 'type': 'str'}, - } - - def __init__(self, **kwargs): - super(EmailTemplateParametersContractProperties, self).__init__(**kwargs) - self.name = kwargs.get('name', None) - self.title = kwargs.get('title', None) - self.description = kwargs.get('description', None) diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/email_template_parameters_contract_properties_py3.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/email_template_parameters_contract_properties_py3.py deleted file mode 100644 index 58cce1c0df98..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/email_template_parameters_contract_properties_py3.py +++ /dev/null @@ -1,42 +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 EmailTemplateParametersContractProperties(Model): - """Email Template Parameter contract. - - :param name: Template parameter name. - :type name: str - :param title: Template parameter title. - :type title: str - :param description: Template parameter description. - :type description: str - """ - - _validation = { - 'name': {'max_length': 256, 'min_length': 1, 'pattern': r'^[A-Za-z0-9-._]+$'}, - 'title': {'max_length': 4096, 'min_length': 1}, - 'description': {'max_length': 256, 'min_length': 1, 'pattern': r'^[A-Za-z0-9-._]+$'}, - } - - _attribute_map = { - 'name': {'key': 'name', 'type': 'str'}, - 'title': {'key': 'title', 'type': 'str'}, - 'description': {'key': 'description', 'type': 'str'}, - } - - def __init__(self, *, name: str=None, title: str=None, description: str=None, **kwargs) -> None: - super(EmailTemplateParametersContractProperties, self).__init__(**kwargs) - self.name = name - self.title = title - self.description = description diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/email_template_update_parameters.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/email_template_update_parameters.py deleted file mode 100644 index f7a7e5c3b452..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/email_template_update_parameters.py +++ /dev/null @@ -1,50 +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 EmailTemplateUpdateParameters(Model): - """Email Template update Parameters. - - :param subject: Subject of the Template. - :type subject: str - :param title: Title of the Template. - :type title: str - :param description: Description of the Email Template. - :type description: str - :param body: Email Template Body. This should be a valid XDocument - :type body: str - :param parameters: Email Template Parameter values. - :type parameters: - list[~azure.mgmt.apimanagement.models.EmailTemplateParametersContractProperties] - """ - - _validation = { - 'subject': {'max_length': 1000, 'min_length': 1}, - 'body': {'min_length': 1}, - } - - _attribute_map = { - 'subject': {'key': 'properties.subject', 'type': 'str'}, - 'title': {'key': 'properties.title', 'type': 'str'}, - 'description': {'key': 'properties.description', 'type': 'str'}, - 'body': {'key': 'properties.body', 'type': 'str'}, - 'parameters': {'key': 'properties.parameters', 'type': '[EmailTemplateParametersContractProperties]'}, - } - - def __init__(self, **kwargs): - super(EmailTemplateUpdateParameters, self).__init__(**kwargs) - self.subject = kwargs.get('subject', None) - self.title = kwargs.get('title', None) - self.description = kwargs.get('description', None) - self.body = kwargs.get('body', None) - self.parameters = kwargs.get('parameters', None) diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/email_template_update_parameters_py3.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/email_template_update_parameters_py3.py deleted file mode 100644 index 1907e0c59b21..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/email_template_update_parameters_py3.py +++ /dev/null @@ -1,50 +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 EmailTemplateUpdateParameters(Model): - """Email Template update Parameters. - - :param subject: Subject of the Template. - :type subject: str - :param title: Title of the Template. - :type title: str - :param description: Description of the Email Template. - :type description: str - :param body: Email Template Body. This should be a valid XDocument - :type body: str - :param parameters: Email Template Parameter values. - :type parameters: - list[~azure.mgmt.apimanagement.models.EmailTemplateParametersContractProperties] - """ - - _validation = { - 'subject': {'max_length': 1000, 'min_length': 1}, - 'body': {'min_length': 1}, - } - - _attribute_map = { - 'subject': {'key': 'properties.subject', 'type': 'str'}, - 'title': {'key': 'properties.title', 'type': 'str'}, - 'description': {'key': 'properties.description', 'type': 'str'}, - 'body': {'key': 'properties.body', 'type': 'str'}, - 'parameters': {'key': 'properties.parameters', 'type': '[EmailTemplateParametersContractProperties]'}, - } - - def __init__(self, *, subject: str=None, title: str=None, description: str=None, body: str=None, parameters=None, **kwargs) -> None: - super(EmailTemplateUpdateParameters, self).__init__(**kwargs) - self.subject = subject - self.title = title - self.description = description - self.body = body - self.parameters = parameters diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/error_field_contract.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/error_field_contract.py deleted file mode 100644 index f376b6292b73..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/error_field_contract.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 ErrorFieldContract(Model): - """Error Field contract. - - :param code: Property level error code. - :type code: str - :param message: Human-readable representation of property-level error. - :type message: str - :param target: Property name. - :type target: str - """ - - _attribute_map = { - 'code': {'key': 'code', 'type': 'str'}, - 'message': {'key': 'message', 'type': 'str'}, - 'target': {'key': 'target', 'type': 'str'}, - } - - def __init__(self, **kwargs): - super(ErrorFieldContract, self).__init__(**kwargs) - self.code = kwargs.get('code', None) - self.message = kwargs.get('message', None) - self.target = kwargs.get('target', None) diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/error_field_contract_py3.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/error_field_contract_py3.py deleted file mode 100644 index f5c5e28d94d8..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/error_field_contract_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 ErrorFieldContract(Model): - """Error Field contract. - - :param code: Property level error code. - :type code: str - :param message: Human-readable representation of property-level error. - :type message: str - :param target: Property name. - :type target: str - """ - - _attribute_map = { - 'code': {'key': 'code', 'type': 'str'}, - 'message': {'key': 'message', 'type': 'str'}, - 'target': {'key': 'target', 'type': 'str'}, - } - - def __init__(self, *, code: str=None, message: str=None, target: str=None, **kwargs) -> None: - super(ErrorFieldContract, self).__init__(**kwargs) - self.code = code - self.message = message - self.target = target diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/error_response.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/error_response.py deleted file mode 100644 index cd6591f007db..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/error_response.py +++ /dev/null @@ -1,51 +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 -from msrest.exceptions import HttpOperationError - - -class ErrorResponse(Model): - """Error Response. - - :param code: Service-defined error code. This code serves as a sub-status - for the HTTP error code specified in the response. - :type code: str - :param message: Human-readable representation of the error. - :type message: str - :param details: The list of invalid fields send in request, in case of - validation error. - :type details: list[~azure.mgmt.apimanagement.models.ErrorFieldContract] - """ - - _attribute_map = { - 'code': {'key': 'error.code', 'type': 'str'}, - 'message': {'key': 'error.message', 'type': 'str'}, - 'details': {'key': 'error.details', 'type': '[ErrorFieldContract]'}, - } - - def __init__(self, **kwargs): - super(ErrorResponse, self).__init__(**kwargs) - self.code = kwargs.get('code', None) - self.message = kwargs.get('message', None) - self.details = kwargs.get('details', None) - - -class ErrorResponseException(HttpOperationError): - """Server responsed with exception of type: 'ErrorResponse'. - - :param deserialize: A deserializer - :param response: Server response to be deserialized. - """ - - def __init__(self, deserialize, response, *args): - - super(ErrorResponseException, self).__init__(deserialize, response, 'ErrorResponse', *args) diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/error_response_body.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/error_response_body.py deleted file mode 100644 index 80fd246c2f30..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/error_response_body.py +++ /dev/null @@ -1,38 +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 ErrorResponseBody(Model): - """Error Body contract. - - :param code: Service-defined error code. This code serves as a sub-status - for the HTTP error code specified in the response. - :type code: str - :param message: Human-readable representation of the error. - :type message: str - :param details: The list of invalid fields send in request, in case of - validation error. - :type details: list[~azure.mgmt.apimanagement.models.ErrorFieldContract] - """ - - _attribute_map = { - 'code': {'key': 'code', 'type': 'str'}, - 'message': {'key': 'message', 'type': 'str'}, - 'details': {'key': 'details', 'type': '[ErrorFieldContract]'}, - } - - def __init__(self, **kwargs): - super(ErrorResponseBody, self).__init__(**kwargs) - self.code = kwargs.get('code', None) - self.message = kwargs.get('message', None) - self.details = kwargs.get('details', None) diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/error_response_body_py3.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/error_response_body_py3.py deleted file mode 100644 index 1c8dedf4ed1b..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/error_response_body_py3.py +++ /dev/null @@ -1,38 +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 ErrorResponseBody(Model): - """Error Body contract. - - :param code: Service-defined error code. This code serves as a sub-status - for the HTTP error code specified in the response. - :type code: str - :param message: Human-readable representation of the error. - :type message: str - :param details: The list of invalid fields send in request, in case of - validation error. - :type details: list[~azure.mgmt.apimanagement.models.ErrorFieldContract] - """ - - _attribute_map = { - 'code': {'key': 'code', 'type': 'str'}, - 'message': {'key': 'message', 'type': 'str'}, - 'details': {'key': 'details', 'type': '[ErrorFieldContract]'}, - } - - def __init__(self, *, code: str=None, message: str=None, details=None, **kwargs) -> None: - super(ErrorResponseBody, self).__init__(**kwargs) - self.code = code - self.message = message - self.details = details diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/error_response_py3.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/error_response_py3.py deleted file mode 100644 index 682261f414ec..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/error_response_py3.py +++ /dev/null @@ -1,51 +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 -from msrest.exceptions import HttpOperationError - - -class ErrorResponse(Model): - """Error Response. - - :param code: Service-defined error code. This code serves as a sub-status - for the HTTP error code specified in the response. - :type code: str - :param message: Human-readable representation of the error. - :type message: str - :param details: The list of invalid fields send in request, in case of - validation error. - :type details: list[~azure.mgmt.apimanagement.models.ErrorFieldContract] - """ - - _attribute_map = { - 'code': {'key': 'error.code', 'type': 'str'}, - 'message': {'key': 'error.message', 'type': 'str'}, - 'details': {'key': 'error.details', 'type': '[ErrorFieldContract]'}, - } - - def __init__(self, *, code: str=None, message: str=None, details=None, **kwargs) -> None: - super(ErrorResponse, self).__init__(**kwargs) - self.code = code - self.message = message - self.details = details - - -class ErrorResponseException(HttpOperationError): - """Server responsed with exception of type: 'ErrorResponse'. - - :param deserialize: A deserializer - :param response: Server response to be deserialized. - """ - - def __init__(self, deserialize, response, *args): - - super(ErrorResponseException, self).__init__(deserialize, response, 'ErrorResponse', *args) diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/generate_sso_url_result.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/generate_sso_url_result.py deleted file mode 100644 index 39df1288be36..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/generate_sso_url_result.py +++ /dev/null @@ -1,28 +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 GenerateSsoUrlResult(Model): - """Generate SSO Url operations response details. - - :param value: Redirect Url containing the SSO URL value. - :type value: str - """ - - _attribute_map = { - 'value': {'key': 'value', 'type': 'str'}, - } - - def __init__(self, **kwargs): - super(GenerateSsoUrlResult, self).__init__(**kwargs) - self.value = kwargs.get('value', None) diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/generate_sso_url_result_py3.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/generate_sso_url_result_py3.py deleted file mode 100644 index bc5404c9c47f..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/generate_sso_url_result_py3.py +++ /dev/null @@ -1,28 +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 GenerateSsoUrlResult(Model): - """Generate SSO Url operations response details. - - :param value: Redirect Url containing the SSO URL value. - :type value: str - """ - - _attribute_map = { - 'value': {'key': 'value', 'type': 'str'}, - } - - def __init__(self, *, value: str=None, **kwargs) -> None: - super(GenerateSsoUrlResult, self).__init__(**kwargs) - self.value = value diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/group_contract.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/group_contract.py deleted file mode 100644 index 89aad685c1e5..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/group_contract.py +++ /dev/null @@ -1,73 +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 .resource import Resource - - -class GroupContract(Resource): - """Contract details. - - Variables are only populated by the server, and will be ignored when - sending a request. - - All required parameters must be populated in order to send to Azure. - - :ivar id: Resource ID. - :vartype id: str - :ivar name: Resource name. - :vartype name: str - :ivar type: Resource type for API Management resource. - :vartype type: str - :param display_name: Required. Group name. - :type display_name: str - :param description: Group description. Can contain HTML formatting tags. - :type description: str - :ivar built_in: true if the group is one of the three system groups - (Administrators, Developers, or Guests); otherwise false. - :vartype built_in: bool - :param group_contract_type: Group type. Possible values include: 'custom', - 'system', 'external' - :type group_contract_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/`; - otherwise the value is null. - :type external_id: str - """ - - _validation = { - 'id': {'readonly': True}, - 'name': {'readonly': True}, - 'type': {'readonly': True}, - 'display_name': {'required': True, 'max_length': 300, 'min_length': 1}, - 'description': {'max_length': 1000}, - 'built_in': {'readonly': True}, - } - - _attribute_map = { - 'id': {'key': 'id', 'type': 'str'}, - 'name': {'key': 'name', 'type': 'str'}, - 'type': {'key': 'type', 'type': 'str'}, - 'display_name': {'key': 'properties.displayName', 'type': 'str'}, - 'description': {'key': 'properties.description', 'type': 'str'}, - 'built_in': {'key': 'properties.builtIn', 'type': 'bool'}, - 'group_contract_type': {'key': 'properties.type', 'type': 'GroupType'}, - 'external_id': {'key': 'properties.externalId', 'type': 'str'}, - } - - def __init__(self, **kwargs): - super(GroupContract, self).__init__(**kwargs) - self.display_name = kwargs.get('display_name', None) - self.description = kwargs.get('description', None) - self.built_in = None - self.group_contract_type = kwargs.get('group_contract_type', None) - self.external_id = kwargs.get('external_id', None) diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/group_contract_paged.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/group_contract_paged.py deleted file mode 100644 index 04133d76cef6..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/group_contract_paged.py +++ /dev/null @@ -1,27 +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.paging import Paged - - -class GroupContractPaged(Paged): - """ - A paging container for iterating over a list of :class:`GroupContract ` object - """ - - _attribute_map = { - 'next_link': {'key': 'nextLink', 'type': 'str'}, - 'current_page': {'key': 'value', 'type': '[GroupContract]'} - } - - def __init__(self, *args, **kwargs): - - super(GroupContractPaged, self).__init__(*args, **kwargs) diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/group_contract_properties.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/group_contract_properties.py deleted file mode 100644 index a6cda94f8805..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/group_contract_properties.py +++ /dev/null @@ -1,60 +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 GroupContractProperties(Model): - """Group contract Properties. - - Variables are only populated by the server, and will be ignored when - sending a request. - - All required parameters must be populated in order to send to Azure. - - :param display_name: Required. Group name. - :type display_name: str - :param description: Group description. Can contain HTML formatting tags. - :type description: str - :ivar built_in: true if the group is one of the three system groups - (Administrators, Developers, or Guests); otherwise false. - :vartype built_in: bool - :param type: Group type. Possible values include: 'custom', 'system', - 'external' - :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/`; - otherwise the value is null. - :type external_id: str - """ - - _validation = { - 'display_name': {'required': True, 'max_length': 300, 'min_length': 1}, - 'description': {'max_length': 1000}, - 'built_in': {'readonly': True}, - } - - _attribute_map = { - 'display_name': {'key': 'displayName', 'type': 'str'}, - 'description': {'key': 'description', 'type': 'str'}, - 'built_in': {'key': 'builtIn', 'type': 'bool'}, - 'type': {'key': 'type', 'type': 'GroupType'}, - 'external_id': {'key': 'externalId', 'type': 'str'}, - } - - def __init__(self, **kwargs): - super(GroupContractProperties, self).__init__(**kwargs) - self.display_name = kwargs.get('display_name', None) - self.description = kwargs.get('description', None) - self.built_in = None - self.type = kwargs.get('type', None) - self.external_id = kwargs.get('external_id', None) diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/group_contract_properties_py3.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/group_contract_properties_py3.py deleted file mode 100644 index ab604b4e419b..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/group_contract_properties_py3.py +++ /dev/null @@ -1,60 +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 GroupContractProperties(Model): - """Group contract Properties. - - Variables are only populated by the server, and will be ignored when - sending a request. - - All required parameters must be populated in order to send to Azure. - - :param display_name: Required. Group name. - :type display_name: str - :param description: Group description. Can contain HTML formatting tags. - :type description: str - :ivar built_in: true if the group is one of the three system groups - (Administrators, Developers, or Guests); otherwise false. - :vartype built_in: bool - :param type: Group type. Possible values include: 'custom', 'system', - 'external' - :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/`; - otherwise the value is null. - :type external_id: str - """ - - _validation = { - 'display_name': {'required': True, 'max_length': 300, 'min_length': 1}, - 'description': {'max_length': 1000}, - 'built_in': {'readonly': True}, - } - - _attribute_map = { - 'display_name': {'key': 'displayName', 'type': 'str'}, - 'description': {'key': 'description', 'type': 'str'}, - 'built_in': {'key': 'builtIn', 'type': 'bool'}, - 'type': {'key': 'type', 'type': 'GroupType'}, - 'external_id': {'key': 'externalId', 'type': 'str'}, - } - - def __init__(self, *, display_name: str, description: str=None, type=None, external_id: str=None, **kwargs) -> None: - super(GroupContractProperties, self).__init__(**kwargs) - self.display_name = display_name - self.description = description - self.built_in = None - self.type = type - self.external_id = external_id diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/group_contract_py3.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/group_contract_py3.py deleted file mode 100644 index 5b2c78fbc9f4..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/group_contract_py3.py +++ /dev/null @@ -1,73 +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 .resource_py3 import Resource - - -class GroupContract(Resource): - """Contract details. - - Variables are only populated by the server, and will be ignored when - sending a request. - - All required parameters must be populated in order to send to Azure. - - :ivar id: Resource ID. - :vartype id: str - :ivar name: Resource name. - :vartype name: str - :ivar type: Resource type for API Management resource. - :vartype type: str - :param display_name: Required. Group name. - :type display_name: str - :param description: Group description. Can contain HTML formatting tags. - :type description: str - :ivar built_in: true if the group is one of the three system groups - (Administrators, Developers, or Guests); otherwise false. - :vartype built_in: bool - :param group_contract_type: Group type. Possible values include: 'custom', - 'system', 'external' - :type group_contract_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/`; - otherwise the value is null. - :type external_id: str - """ - - _validation = { - 'id': {'readonly': True}, - 'name': {'readonly': True}, - 'type': {'readonly': True}, - 'display_name': {'required': True, 'max_length': 300, 'min_length': 1}, - 'description': {'max_length': 1000}, - 'built_in': {'readonly': True}, - } - - _attribute_map = { - 'id': {'key': 'id', 'type': 'str'}, - 'name': {'key': 'name', 'type': 'str'}, - 'type': {'key': 'type', 'type': 'str'}, - 'display_name': {'key': 'properties.displayName', 'type': 'str'}, - 'description': {'key': 'properties.description', 'type': 'str'}, - 'built_in': {'key': 'properties.builtIn', 'type': 'bool'}, - 'group_contract_type': {'key': 'properties.type', 'type': 'GroupType'}, - 'external_id': {'key': 'properties.externalId', 'type': 'str'}, - } - - def __init__(self, *, display_name: str, description: str=None, group_contract_type=None, external_id: str=None, **kwargs) -> None: - super(GroupContract, self).__init__(**kwargs) - self.display_name = display_name - self.description = description - self.built_in = None - self.group_contract_type = group_contract_type - self.external_id = external_id diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/group_create_parameters.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/group_create_parameters.py deleted file mode 100644 index eeb0f54e9854..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/group_create_parameters.py +++ /dev/null @@ -1,50 +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 GroupCreateParameters(Model): - """Parameters supplied to the Create Group operation. - - All required parameters must be populated in order to send to Azure. - - :param display_name: Required. Group name. - :type display_name: str - :param description: Group description. - :type description: str - :param type: Group type. Possible values include: 'custom', 'system', - 'external' - :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. - :type external_id: str - """ - - _validation = { - 'display_name': {'required': True, 'max_length': 300, 'min_length': 1}, - } - - _attribute_map = { - 'display_name': {'key': 'properties.displayName', 'type': 'str'}, - 'description': {'key': 'properties.description', 'type': 'str'}, - 'type': {'key': 'properties.type', 'type': 'GroupType'}, - 'external_id': {'key': 'properties.externalId', 'type': 'str'}, - } - - def __init__(self, **kwargs): - super(GroupCreateParameters, self).__init__(**kwargs) - self.display_name = kwargs.get('display_name', None) - self.description = kwargs.get('description', None) - self.type = kwargs.get('type', None) - self.external_id = kwargs.get('external_id', None) diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/group_create_parameters_py3.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/group_create_parameters_py3.py deleted file mode 100644 index 5f6f2d22763d..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/group_create_parameters_py3.py +++ /dev/null @@ -1,50 +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 GroupCreateParameters(Model): - """Parameters supplied to the Create Group operation. - - All required parameters must be populated in order to send to Azure. - - :param display_name: Required. Group name. - :type display_name: str - :param description: Group description. - :type description: str - :param type: Group type. Possible values include: 'custom', 'system', - 'external' - :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. - :type external_id: str - """ - - _validation = { - 'display_name': {'required': True, 'max_length': 300, 'min_length': 1}, - } - - _attribute_map = { - 'display_name': {'key': 'properties.displayName', 'type': 'str'}, - 'description': {'key': 'properties.description', 'type': 'str'}, - 'type': {'key': 'properties.type', 'type': 'GroupType'}, - 'external_id': {'key': 'properties.externalId', 'type': 'str'}, - } - - def __init__(self, *, display_name: str, description: str=None, type=None, external_id: str=None, **kwargs) -> None: - super(GroupCreateParameters, self).__init__(**kwargs) - self.display_name = display_name - self.description = description - self.type = type - self.external_id = external_id diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/group_update_parameters.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/group_update_parameters.py deleted file mode 100644 index 34cb6c6a3b7d..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/group_update_parameters.py +++ /dev/null @@ -1,48 +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 GroupUpdateParameters(Model): - """Parameters supplied to the Update Group operation. - - :param display_name: Group name. - :type display_name: str - :param description: Group description. - :type description: str - :param type: Group type. Possible values include: 'custom', 'system', - 'external' - :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. - :type external_id: str - """ - - _validation = { - 'display_name': {'max_length': 300, 'min_length': 1}, - } - - _attribute_map = { - 'display_name': {'key': 'properties.displayName', 'type': 'str'}, - 'description': {'key': 'properties.description', 'type': 'str'}, - 'type': {'key': 'properties.type', 'type': 'GroupType'}, - 'external_id': {'key': 'properties.externalId', 'type': 'str'}, - } - - def __init__(self, **kwargs): - super(GroupUpdateParameters, self).__init__(**kwargs) - self.display_name = kwargs.get('display_name', None) - self.description = kwargs.get('description', None) - self.type = kwargs.get('type', None) - self.external_id = kwargs.get('external_id', None) diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/group_update_parameters_py3.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/group_update_parameters_py3.py deleted file mode 100644 index 16aee8d02966..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/group_update_parameters_py3.py +++ /dev/null @@ -1,48 +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 GroupUpdateParameters(Model): - """Parameters supplied to the Update Group operation. - - :param display_name: Group name. - :type display_name: str - :param description: Group description. - :type description: str - :param type: Group type. Possible values include: 'custom', 'system', - 'external' - :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. - :type external_id: str - """ - - _validation = { - 'display_name': {'max_length': 300, 'min_length': 1}, - } - - _attribute_map = { - 'display_name': {'key': 'properties.displayName', 'type': 'str'}, - 'description': {'key': 'properties.description', 'type': 'str'}, - 'type': {'key': 'properties.type', 'type': 'GroupType'}, - 'external_id': {'key': 'properties.externalId', 'type': 'str'}, - } - - def __init__(self, *, display_name: str=None, description: str=None, type=None, external_id: str=None, **kwargs) -> None: - super(GroupUpdateParameters, self).__init__(**kwargs) - self.display_name = display_name - self.description = description - self.type = type - self.external_id = external_id diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/hostname_configuration.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/hostname_configuration.py deleted file mode 100644 index 0c0dcfc232bb..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/hostname_configuration.py +++ /dev/null @@ -1,76 +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 HostnameConfiguration(Model): - """Custom hostname configuration. - - All required parameters must be populated in order to send to Azure. - - :param type: Required. Hostname type. Possible values include: 'Proxy', - 'Portal', 'Management', 'Scm', 'DeveloperPortal' - :type type: str or ~azure.mgmt.apimanagement.models.HostnameType - :param host_name: Required. Hostname to configure on the Api Management - service. - :type host_name: str - :param key_vault_id: Url to the KeyVault Secret containing the Ssl - Certificate. If absolute Url containing version is provided, auto-update - of ssl certificate will not work. This requires Api Management service to - be configured with MSI. The secret should be of type - *application/x-pkcs12* - :type key_vault_id: str - :param encoded_certificate: Base64 Encoded certificate. - :type encoded_certificate: str - :param certificate_password: Certificate Password. - :type certificate_password: str - :param default_ssl_binding: Specify true to setup the certificate - associated with this Hostname as the Default SSL Certificate. If a client - does not send the SNI header, then this will be the certificate that will - be challenged. The property is useful if a service has multiple custom - hostname enabled and it needs to decide on the default ssl certificate. - The setting only applied to Proxy Hostname Type. Default value: False . - :type default_ssl_binding: bool - :param negotiate_client_certificate: Specify true to always negotiate - client certificate on the hostname. Default Value is false. Default value: - False . - :type negotiate_client_certificate: bool - :param certificate: Certificate information. - :type certificate: ~azure.mgmt.apimanagement.models.CertificateInformation - """ - - _validation = { - 'type': {'required': True}, - 'host_name': {'required': True}, - } - - _attribute_map = { - 'type': {'key': 'type', 'type': 'str'}, - 'host_name': {'key': 'hostName', 'type': 'str'}, - 'key_vault_id': {'key': 'keyVaultId', 'type': 'str'}, - 'encoded_certificate': {'key': 'encodedCertificate', 'type': 'str'}, - 'certificate_password': {'key': 'certificatePassword', 'type': 'str'}, - 'default_ssl_binding': {'key': 'defaultSslBinding', 'type': 'bool'}, - 'negotiate_client_certificate': {'key': 'negotiateClientCertificate', 'type': 'bool'}, - 'certificate': {'key': 'certificate', 'type': 'CertificateInformation'}, - } - - def __init__(self, **kwargs): - super(HostnameConfiguration, self).__init__(**kwargs) - self.type = kwargs.get('type', None) - self.host_name = kwargs.get('host_name', None) - self.key_vault_id = kwargs.get('key_vault_id', None) - self.encoded_certificate = kwargs.get('encoded_certificate', None) - self.certificate_password = kwargs.get('certificate_password', None) - self.default_ssl_binding = kwargs.get('default_ssl_binding', False) - self.negotiate_client_certificate = kwargs.get('negotiate_client_certificate', False) - self.certificate = kwargs.get('certificate', None) diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/hostname_configuration_py3.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/hostname_configuration_py3.py deleted file mode 100644 index 8770649147a2..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/hostname_configuration_py3.py +++ /dev/null @@ -1,76 +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 HostnameConfiguration(Model): - """Custom hostname configuration. - - All required parameters must be populated in order to send to Azure. - - :param type: Required. Hostname type. Possible values include: 'Proxy', - 'Portal', 'Management', 'Scm', 'DeveloperPortal' - :type type: str or ~azure.mgmt.apimanagement.models.HostnameType - :param host_name: Required. Hostname to configure on the Api Management - service. - :type host_name: str - :param key_vault_id: Url to the KeyVault Secret containing the Ssl - Certificate. If absolute Url containing version is provided, auto-update - of ssl certificate will not work. This requires Api Management service to - be configured with MSI. The secret should be of type - *application/x-pkcs12* - :type key_vault_id: str - :param encoded_certificate: Base64 Encoded certificate. - :type encoded_certificate: str - :param certificate_password: Certificate Password. - :type certificate_password: str - :param default_ssl_binding: Specify true to setup the certificate - associated with this Hostname as the Default SSL Certificate. If a client - does not send the SNI header, then this will be the certificate that will - be challenged. The property is useful if a service has multiple custom - hostname enabled and it needs to decide on the default ssl certificate. - The setting only applied to Proxy Hostname Type. Default value: False . - :type default_ssl_binding: bool - :param negotiate_client_certificate: Specify true to always negotiate - client certificate on the hostname. Default Value is false. Default value: - False . - :type negotiate_client_certificate: bool - :param certificate: Certificate information. - :type certificate: ~azure.mgmt.apimanagement.models.CertificateInformation - """ - - _validation = { - 'type': {'required': True}, - 'host_name': {'required': True}, - } - - _attribute_map = { - 'type': {'key': 'type', 'type': 'str'}, - 'host_name': {'key': 'hostName', 'type': 'str'}, - 'key_vault_id': {'key': 'keyVaultId', 'type': 'str'}, - 'encoded_certificate': {'key': 'encodedCertificate', 'type': 'str'}, - 'certificate_password': {'key': 'certificatePassword', 'type': 'str'}, - 'default_ssl_binding': {'key': 'defaultSslBinding', 'type': 'bool'}, - 'negotiate_client_certificate': {'key': 'negotiateClientCertificate', 'type': 'bool'}, - 'certificate': {'key': 'certificate', 'type': 'CertificateInformation'}, - } - - def __init__(self, *, type, host_name: str, key_vault_id: str=None, encoded_certificate: str=None, certificate_password: str=None, default_ssl_binding: bool=False, negotiate_client_certificate: bool=False, certificate=None, **kwargs) -> None: - super(HostnameConfiguration, self).__init__(**kwargs) - self.type = type - self.host_name = host_name - self.key_vault_id = key_vault_id - self.encoded_certificate = encoded_certificate - self.certificate_password = certificate_password - self.default_ssl_binding = default_ssl_binding - self.negotiate_client_certificate = negotiate_client_certificate - self.certificate = certificate diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/http_message_diagnostic.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/http_message_diagnostic.py deleted file mode 100644 index 2c2651f31bb8..000000000000 --- a/sdk/apimanagement/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/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/http_message_diagnostic_py3.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/http_message_diagnostic_py3.py deleted file mode 100644 index 28171eee4cd7..000000000000 --- a/sdk/apimanagement/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/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/identity_provider_base_parameters.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/identity_provider_base_parameters.py deleted file mode 100644 index 0db06fcfcf1e..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/identity_provider_base_parameters.py +++ /dev/null @@ -1,67 +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 IdentityProviderBaseParameters(Model): - """Identity Provider Base Parameter Properties. - - :param type: Identity Provider Type identifier. Possible values include: - 'facebook', 'google', 'microsoft', 'twitter', 'aad', 'aadB2C' - :type type: str or ~azure.mgmt.apimanagement.models.IdentityProviderType - :param allowed_tenants: List of Allowed Tenants when configuring Azure - Active Directory login. - :type allowed_tenants: list[str] - :param authority: OpenID Connect discovery endpoint hostname for AAD or - AAD B2C. - :type authority: str - :param signup_policy_name: Signup Policy Name. Only applies to AAD B2C - Identity Provider. - :type signup_policy_name: str - :param signin_policy_name: Signin Policy Name. Only applies to AAD B2C - Identity Provider. - :type signin_policy_name: str - :param profile_editing_policy_name: Profile Editing Policy Name. Only - applies to AAD B2C Identity Provider. - :type profile_editing_policy_name: str - :param password_reset_policy_name: Password Reset Policy Name. Only - applies to AAD B2C Identity Provider. - :type password_reset_policy_name: str - """ - - _validation = { - 'allowed_tenants': {'max_items': 32}, - 'signup_policy_name': {'min_length': 1}, - 'signin_policy_name': {'min_length': 1}, - 'profile_editing_policy_name': {'min_length': 1}, - 'password_reset_policy_name': {'min_length': 1}, - } - - _attribute_map = { - 'type': {'key': 'type', 'type': 'str'}, - 'allowed_tenants': {'key': 'allowedTenants', 'type': '[str]'}, - 'authority': {'key': 'authority', 'type': 'str'}, - 'signup_policy_name': {'key': 'signupPolicyName', 'type': 'str'}, - 'signin_policy_name': {'key': 'signinPolicyName', 'type': 'str'}, - 'profile_editing_policy_name': {'key': 'profileEditingPolicyName', 'type': 'str'}, - 'password_reset_policy_name': {'key': 'passwordResetPolicyName', 'type': 'str'}, - } - - def __init__(self, **kwargs): - super(IdentityProviderBaseParameters, self).__init__(**kwargs) - self.type = kwargs.get('type', None) - self.allowed_tenants = kwargs.get('allowed_tenants', None) - self.authority = kwargs.get('authority', None) - self.signup_policy_name = kwargs.get('signup_policy_name', None) - self.signin_policy_name = kwargs.get('signin_policy_name', None) - self.profile_editing_policy_name = kwargs.get('profile_editing_policy_name', None) - self.password_reset_policy_name = kwargs.get('password_reset_policy_name', None) diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/identity_provider_base_parameters_py3.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/identity_provider_base_parameters_py3.py deleted file mode 100644 index e29979994684..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/identity_provider_base_parameters_py3.py +++ /dev/null @@ -1,67 +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 IdentityProviderBaseParameters(Model): - """Identity Provider Base Parameter Properties. - - :param type: Identity Provider Type identifier. Possible values include: - 'facebook', 'google', 'microsoft', 'twitter', 'aad', 'aadB2C' - :type type: str or ~azure.mgmt.apimanagement.models.IdentityProviderType - :param allowed_tenants: List of Allowed Tenants when configuring Azure - Active Directory login. - :type allowed_tenants: list[str] - :param authority: OpenID Connect discovery endpoint hostname for AAD or - AAD B2C. - :type authority: str - :param signup_policy_name: Signup Policy Name. Only applies to AAD B2C - Identity Provider. - :type signup_policy_name: str - :param signin_policy_name: Signin Policy Name. Only applies to AAD B2C - Identity Provider. - :type signin_policy_name: str - :param profile_editing_policy_name: Profile Editing Policy Name. Only - applies to AAD B2C Identity Provider. - :type profile_editing_policy_name: str - :param password_reset_policy_name: Password Reset Policy Name. Only - applies to AAD B2C Identity Provider. - :type password_reset_policy_name: str - """ - - _validation = { - 'allowed_tenants': {'max_items': 32}, - 'signup_policy_name': {'min_length': 1}, - 'signin_policy_name': {'min_length': 1}, - 'profile_editing_policy_name': {'min_length': 1}, - 'password_reset_policy_name': {'min_length': 1}, - } - - _attribute_map = { - 'type': {'key': 'type', 'type': 'str'}, - 'allowed_tenants': {'key': 'allowedTenants', 'type': '[str]'}, - 'authority': {'key': 'authority', 'type': 'str'}, - 'signup_policy_name': {'key': 'signupPolicyName', 'type': 'str'}, - 'signin_policy_name': {'key': 'signinPolicyName', 'type': 'str'}, - 'profile_editing_policy_name': {'key': 'profileEditingPolicyName', 'type': 'str'}, - 'password_reset_policy_name': {'key': 'passwordResetPolicyName', 'type': 'str'}, - } - - def __init__(self, *, type=None, allowed_tenants=None, authority: str=None, signup_policy_name: str=None, signin_policy_name: str=None, profile_editing_policy_name: str=None, password_reset_policy_name: str=None, **kwargs) -> None: - super(IdentityProviderBaseParameters, self).__init__(**kwargs) - self.type = type - self.allowed_tenants = allowed_tenants - self.authority = authority - self.signup_policy_name = signup_policy_name - self.signin_policy_name = signin_policy_name - self.profile_editing_policy_name = profile_editing_policy_name - self.password_reset_policy_name = password_reset_policy_name diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/identity_provider_contract.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/identity_provider_contract.py deleted file mode 100644 index 6acc2feb7d52..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/identity_provider_contract.py +++ /dev/null @@ -1,101 +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 .resource import Resource - - -class IdentityProviderContract(Resource): - """Identity Provider details. - - Variables are only populated by the server, and will be ignored when - sending a request. - - All required parameters must be populated in order to send to Azure. - - :ivar id: Resource ID. - :vartype id: str - :ivar name: Resource name. - :vartype name: str - :ivar type: Resource type for API Management resource. - :vartype type: str - :param identity_provider_contract_type: Identity Provider Type identifier. - Possible values include: 'facebook', 'google', 'microsoft', 'twitter', - 'aad', 'aadB2C' - :type identity_provider_contract_type: str or - ~azure.mgmt.apimanagement.models.IdentityProviderType - :param allowed_tenants: List of Allowed Tenants when configuring Azure - Active Directory login. - :type allowed_tenants: list[str] - :param authority: OpenID Connect discovery endpoint hostname for AAD or - AAD B2C. - :type authority: str - :param signup_policy_name: Signup Policy Name. Only applies to AAD B2C - Identity Provider. - :type signup_policy_name: str - :param signin_policy_name: Signin Policy Name. Only applies to AAD B2C - Identity Provider. - :type signin_policy_name: str - :param profile_editing_policy_name: Profile Editing Policy Name. Only - applies to AAD B2C Identity Provider. - :type profile_editing_policy_name: str - :param password_reset_policy_name: Password Reset Policy Name. Only - applies to AAD B2C Identity Provider. - :type password_reset_policy_name: str - :param client_id: Required. Client Id of the Application in the external - Identity Provider. It is App ID for Facebook login, Client ID for Google - login, App ID for Microsoft. - :type client_id: str - :param client_secret: Required. Client secret of the Application in - external Identity Provider, used to authenticate login request. For - example, it is App Secret for Facebook login, API Key for Google login, - Public Key for Microsoft. - :type client_secret: str - """ - - _validation = { - 'id': {'readonly': True}, - 'name': {'readonly': True}, - 'type': {'readonly': True}, - 'allowed_tenants': {'max_items': 32}, - 'signup_policy_name': {'min_length': 1}, - 'signin_policy_name': {'min_length': 1}, - 'profile_editing_policy_name': {'min_length': 1}, - 'password_reset_policy_name': {'min_length': 1}, - 'client_id': {'required': True, 'min_length': 1}, - 'client_secret': {'required': True, 'min_length': 1}, - } - - _attribute_map = { - 'id': {'key': 'id', 'type': 'str'}, - 'name': {'key': 'name', 'type': 'str'}, - 'type': {'key': 'type', 'type': 'str'}, - 'identity_provider_contract_type': {'key': 'properties.type', 'type': 'str'}, - 'allowed_tenants': {'key': 'properties.allowedTenants', 'type': '[str]'}, - 'authority': {'key': 'properties.authority', 'type': 'str'}, - 'signup_policy_name': {'key': 'properties.signupPolicyName', 'type': 'str'}, - 'signin_policy_name': {'key': 'properties.signinPolicyName', 'type': 'str'}, - 'profile_editing_policy_name': {'key': 'properties.profileEditingPolicyName', 'type': 'str'}, - 'password_reset_policy_name': {'key': 'properties.passwordResetPolicyName', 'type': 'str'}, - 'client_id': {'key': 'properties.clientId', 'type': 'str'}, - 'client_secret': {'key': 'properties.clientSecret', 'type': 'str'}, - } - - def __init__(self, **kwargs): - super(IdentityProviderContract, self).__init__(**kwargs) - self.identity_provider_contract_type = kwargs.get('identity_provider_contract_type', None) - self.allowed_tenants = kwargs.get('allowed_tenants', None) - self.authority = kwargs.get('authority', None) - self.signup_policy_name = kwargs.get('signup_policy_name', None) - self.signin_policy_name = kwargs.get('signin_policy_name', None) - self.profile_editing_policy_name = kwargs.get('profile_editing_policy_name', None) - self.password_reset_policy_name = kwargs.get('password_reset_policy_name', None) - self.client_id = kwargs.get('client_id', None) - self.client_secret = kwargs.get('client_secret', None) diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/identity_provider_contract_paged.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/identity_provider_contract_paged.py deleted file mode 100644 index 4c47b9094fc3..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/identity_provider_contract_paged.py +++ /dev/null @@ -1,27 +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.paging import Paged - - -class IdentityProviderContractPaged(Paged): - """ - A paging container for iterating over a list of :class:`IdentityProviderContract ` object - """ - - _attribute_map = { - 'next_link': {'key': 'nextLink', 'type': 'str'}, - 'current_page': {'key': 'value', 'type': '[IdentityProviderContract]'} - } - - def __init__(self, *args, **kwargs): - - super(IdentityProviderContractPaged, self).__init__(*args, **kwargs) diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/identity_provider_contract_py3.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/identity_provider_contract_py3.py deleted file mode 100644 index d27cad4a2691..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/identity_provider_contract_py3.py +++ /dev/null @@ -1,101 +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 .resource_py3 import Resource - - -class IdentityProviderContract(Resource): - """Identity Provider details. - - Variables are only populated by the server, and will be ignored when - sending a request. - - All required parameters must be populated in order to send to Azure. - - :ivar id: Resource ID. - :vartype id: str - :ivar name: Resource name. - :vartype name: str - :ivar type: Resource type for API Management resource. - :vartype type: str - :param identity_provider_contract_type: Identity Provider Type identifier. - Possible values include: 'facebook', 'google', 'microsoft', 'twitter', - 'aad', 'aadB2C' - :type identity_provider_contract_type: str or - ~azure.mgmt.apimanagement.models.IdentityProviderType - :param allowed_tenants: List of Allowed Tenants when configuring Azure - Active Directory login. - :type allowed_tenants: list[str] - :param authority: OpenID Connect discovery endpoint hostname for AAD or - AAD B2C. - :type authority: str - :param signup_policy_name: Signup Policy Name. Only applies to AAD B2C - Identity Provider. - :type signup_policy_name: str - :param signin_policy_name: Signin Policy Name. Only applies to AAD B2C - Identity Provider. - :type signin_policy_name: str - :param profile_editing_policy_name: Profile Editing Policy Name. Only - applies to AAD B2C Identity Provider. - :type profile_editing_policy_name: str - :param password_reset_policy_name: Password Reset Policy Name. Only - applies to AAD B2C Identity Provider. - :type password_reset_policy_name: str - :param client_id: Required. Client Id of the Application in the external - Identity Provider. It is App ID for Facebook login, Client ID for Google - login, App ID for Microsoft. - :type client_id: str - :param client_secret: Required. Client secret of the Application in - external Identity Provider, used to authenticate login request. For - example, it is App Secret for Facebook login, API Key for Google login, - Public Key for Microsoft. - :type client_secret: str - """ - - _validation = { - 'id': {'readonly': True}, - 'name': {'readonly': True}, - 'type': {'readonly': True}, - 'allowed_tenants': {'max_items': 32}, - 'signup_policy_name': {'min_length': 1}, - 'signin_policy_name': {'min_length': 1}, - 'profile_editing_policy_name': {'min_length': 1}, - 'password_reset_policy_name': {'min_length': 1}, - 'client_id': {'required': True, 'min_length': 1}, - 'client_secret': {'required': True, 'min_length': 1}, - } - - _attribute_map = { - 'id': {'key': 'id', 'type': 'str'}, - 'name': {'key': 'name', 'type': 'str'}, - 'type': {'key': 'type', 'type': 'str'}, - 'identity_provider_contract_type': {'key': 'properties.type', 'type': 'str'}, - 'allowed_tenants': {'key': 'properties.allowedTenants', 'type': '[str]'}, - 'authority': {'key': 'properties.authority', 'type': 'str'}, - 'signup_policy_name': {'key': 'properties.signupPolicyName', 'type': 'str'}, - 'signin_policy_name': {'key': 'properties.signinPolicyName', 'type': 'str'}, - 'profile_editing_policy_name': {'key': 'properties.profileEditingPolicyName', 'type': 'str'}, - 'password_reset_policy_name': {'key': 'properties.passwordResetPolicyName', 'type': 'str'}, - 'client_id': {'key': 'properties.clientId', 'type': 'str'}, - 'client_secret': {'key': 'properties.clientSecret', 'type': 'str'}, - } - - def __init__(self, *, client_id: str, client_secret: str, identity_provider_contract_type=None, allowed_tenants=None, authority: str=None, signup_policy_name: str=None, signin_policy_name: str=None, profile_editing_policy_name: str=None, password_reset_policy_name: str=None, **kwargs) -> None: - super(IdentityProviderContract, self).__init__(**kwargs) - self.identity_provider_contract_type = identity_provider_contract_type - self.allowed_tenants = allowed_tenants - self.authority = authority - self.signup_policy_name = signup_policy_name - self.signin_policy_name = signin_policy_name - self.profile_editing_policy_name = profile_editing_policy_name - self.password_reset_policy_name = password_reset_policy_name - self.client_id = client_id - self.client_secret = client_secret diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/identity_provider_update_parameters.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/identity_provider_update_parameters.py deleted file mode 100644 index ef23abf0a398..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/identity_provider_update_parameters.py +++ /dev/null @@ -1,82 +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 IdentityProviderUpdateParameters(Model): - """Parameters supplied to update Identity Provider. - - :param type: Identity Provider Type identifier. Possible values include: - 'facebook', 'google', 'microsoft', 'twitter', 'aad', 'aadB2C' - :type type: str or ~azure.mgmt.apimanagement.models.IdentityProviderType - :param allowed_tenants: List of Allowed Tenants when configuring Azure - Active Directory login. - :type allowed_tenants: list[str] - :param authority: OpenID Connect discovery endpoint hostname for AAD or - AAD B2C. - :type authority: str - :param signup_policy_name: Signup Policy Name. Only applies to AAD B2C - Identity Provider. - :type signup_policy_name: str - :param signin_policy_name: Signin Policy Name. Only applies to AAD B2C - Identity Provider. - :type signin_policy_name: str - :param profile_editing_policy_name: Profile Editing Policy Name. Only - applies to AAD B2C Identity Provider. - :type profile_editing_policy_name: str - :param password_reset_policy_name: Password Reset Policy Name. Only - applies to AAD B2C Identity Provider. - :type password_reset_policy_name: str - :param client_id: Client Id of the Application in the external Identity - Provider. It is App ID for Facebook login, Client ID for Google login, App - ID for Microsoft. - :type client_id: str - :param client_secret: Client secret of the Application in external - Identity Provider, used to authenticate login request. For example, it is - App Secret for Facebook login, API Key for Google login, Public Key for - Microsoft. - :type client_secret: str - """ - - _validation = { - 'allowed_tenants': {'max_items': 32}, - 'signup_policy_name': {'min_length': 1}, - 'signin_policy_name': {'min_length': 1}, - 'profile_editing_policy_name': {'min_length': 1}, - 'password_reset_policy_name': {'min_length': 1}, - 'client_id': {'min_length': 1}, - 'client_secret': {'min_length': 1}, - } - - _attribute_map = { - 'type': {'key': 'properties.type', 'type': 'str'}, - 'allowed_tenants': {'key': 'properties.allowedTenants', 'type': '[str]'}, - 'authority': {'key': 'properties.authority', 'type': 'str'}, - 'signup_policy_name': {'key': 'properties.signupPolicyName', 'type': 'str'}, - 'signin_policy_name': {'key': 'properties.signinPolicyName', 'type': 'str'}, - 'profile_editing_policy_name': {'key': 'properties.profileEditingPolicyName', 'type': 'str'}, - 'password_reset_policy_name': {'key': 'properties.passwordResetPolicyName', 'type': 'str'}, - 'client_id': {'key': 'properties.clientId', 'type': 'str'}, - 'client_secret': {'key': 'properties.clientSecret', 'type': 'str'}, - } - - def __init__(self, **kwargs): - super(IdentityProviderUpdateParameters, self).__init__(**kwargs) - self.type = kwargs.get('type', None) - self.allowed_tenants = kwargs.get('allowed_tenants', None) - self.authority = kwargs.get('authority', None) - self.signup_policy_name = kwargs.get('signup_policy_name', None) - self.signin_policy_name = kwargs.get('signin_policy_name', None) - self.profile_editing_policy_name = kwargs.get('profile_editing_policy_name', None) - self.password_reset_policy_name = kwargs.get('password_reset_policy_name', None) - self.client_id = kwargs.get('client_id', None) - self.client_secret = kwargs.get('client_secret', None) diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/identity_provider_update_parameters_py3.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/identity_provider_update_parameters_py3.py deleted file mode 100644 index 2cad5892a326..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/identity_provider_update_parameters_py3.py +++ /dev/null @@ -1,82 +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 IdentityProviderUpdateParameters(Model): - """Parameters supplied to update Identity Provider. - - :param type: Identity Provider Type identifier. Possible values include: - 'facebook', 'google', 'microsoft', 'twitter', 'aad', 'aadB2C' - :type type: str or ~azure.mgmt.apimanagement.models.IdentityProviderType - :param allowed_tenants: List of Allowed Tenants when configuring Azure - Active Directory login. - :type allowed_tenants: list[str] - :param authority: OpenID Connect discovery endpoint hostname for AAD or - AAD B2C. - :type authority: str - :param signup_policy_name: Signup Policy Name. Only applies to AAD B2C - Identity Provider. - :type signup_policy_name: str - :param signin_policy_name: Signin Policy Name. Only applies to AAD B2C - Identity Provider. - :type signin_policy_name: str - :param profile_editing_policy_name: Profile Editing Policy Name. Only - applies to AAD B2C Identity Provider. - :type profile_editing_policy_name: str - :param password_reset_policy_name: Password Reset Policy Name. Only - applies to AAD B2C Identity Provider. - :type password_reset_policy_name: str - :param client_id: Client Id of the Application in the external Identity - Provider. It is App ID for Facebook login, Client ID for Google login, App - ID for Microsoft. - :type client_id: str - :param client_secret: Client secret of the Application in external - Identity Provider, used to authenticate login request. For example, it is - App Secret for Facebook login, API Key for Google login, Public Key for - Microsoft. - :type client_secret: str - """ - - _validation = { - 'allowed_tenants': {'max_items': 32}, - 'signup_policy_name': {'min_length': 1}, - 'signin_policy_name': {'min_length': 1}, - 'profile_editing_policy_name': {'min_length': 1}, - 'password_reset_policy_name': {'min_length': 1}, - 'client_id': {'min_length': 1}, - 'client_secret': {'min_length': 1}, - } - - _attribute_map = { - 'type': {'key': 'properties.type', 'type': 'str'}, - 'allowed_tenants': {'key': 'properties.allowedTenants', 'type': '[str]'}, - 'authority': {'key': 'properties.authority', 'type': 'str'}, - 'signup_policy_name': {'key': 'properties.signupPolicyName', 'type': 'str'}, - 'signin_policy_name': {'key': 'properties.signinPolicyName', 'type': 'str'}, - 'profile_editing_policy_name': {'key': 'properties.profileEditingPolicyName', 'type': 'str'}, - 'password_reset_policy_name': {'key': 'properties.passwordResetPolicyName', 'type': 'str'}, - 'client_id': {'key': 'properties.clientId', 'type': 'str'}, - 'client_secret': {'key': 'properties.clientSecret', 'type': 'str'}, - } - - def __init__(self, *, type=None, allowed_tenants=None, authority: str=None, signup_policy_name: str=None, signin_policy_name: str=None, profile_editing_policy_name: str=None, password_reset_policy_name: str=None, client_id: str=None, client_secret: str=None, **kwargs) -> None: - super(IdentityProviderUpdateParameters, self).__init__(**kwargs) - self.type = type - self.allowed_tenants = allowed_tenants - self.authority = authority - self.signup_policy_name = signup_policy_name - self.signin_policy_name = signin_policy_name - self.profile_editing_policy_name = profile_editing_policy_name - self.password_reset_policy_name = password_reset_policy_name - self.client_id = client_id - self.client_secret = client_secret diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/issue_attachment_contract.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/issue_attachment_contract.py deleted file mode 100644 index 3b45cdf7a4a3..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/issue_attachment_contract.py +++ /dev/null @@ -1,61 +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 .resource import Resource - - -class IssueAttachmentContract(Resource): - """Issue Attachment Contract details. - - Variables are only populated by the server, and will be ignored when - sending a request. - - All required parameters must be populated in order to send to Azure. - - :ivar id: Resource ID. - :vartype id: str - :ivar name: Resource name. - :vartype name: str - :ivar type: Resource type for API Management resource. - :vartype type: str - :param title: Required. Filename by which the binary data will be saved. - :type title: str - :param content_format: Required. Either 'link' if content is provided via - an HTTP link or the MIME type of the Base64-encoded binary data provided - in the 'content' property. - :type content_format: str - :param content: Required. An HTTP link or Base64-encoded binary data. - :type content: str - """ - - _validation = { - 'id': {'readonly': True}, - 'name': {'readonly': True}, - 'type': {'readonly': True}, - 'title': {'required': True}, - 'content_format': {'required': True}, - 'content': {'required': True}, - } - - _attribute_map = { - 'id': {'key': 'id', 'type': 'str'}, - 'name': {'key': 'name', 'type': 'str'}, - 'type': {'key': 'type', 'type': 'str'}, - 'title': {'key': 'properties.title', 'type': 'str'}, - 'content_format': {'key': 'properties.contentFormat', 'type': 'str'}, - 'content': {'key': 'properties.content', 'type': 'str'}, - } - - def __init__(self, **kwargs): - super(IssueAttachmentContract, self).__init__(**kwargs) - self.title = kwargs.get('title', None) - self.content_format = kwargs.get('content_format', None) - self.content = kwargs.get('content', None) diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/issue_attachment_contract_paged.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/issue_attachment_contract_paged.py deleted file mode 100644 index 31f08fe12743..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/issue_attachment_contract_paged.py +++ /dev/null @@ -1,27 +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.paging import Paged - - -class IssueAttachmentContractPaged(Paged): - """ - A paging container for iterating over a list of :class:`IssueAttachmentContract ` object - """ - - _attribute_map = { - 'next_link': {'key': 'nextLink', 'type': 'str'}, - 'current_page': {'key': 'value', 'type': '[IssueAttachmentContract]'} - } - - def __init__(self, *args, **kwargs): - - super(IssueAttachmentContractPaged, self).__init__(*args, **kwargs) diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/issue_attachment_contract_py3.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/issue_attachment_contract_py3.py deleted file mode 100644 index 6eda14e9e009..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/issue_attachment_contract_py3.py +++ /dev/null @@ -1,61 +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 .resource_py3 import Resource - - -class IssueAttachmentContract(Resource): - """Issue Attachment Contract details. - - Variables are only populated by the server, and will be ignored when - sending a request. - - All required parameters must be populated in order to send to Azure. - - :ivar id: Resource ID. - :vartype id: str - :ivar name: Resource name. - :vartype name: str - :ivar type: Resource type for API Management resource. - :vartype type: str - :param title: Required. Filename by which the binary data will be saved. - :type title: str - :param content_format: Required. Either 'link' if content is provided via - an HTTP link or the MIME type of the Base64-encoded binary data provided - in the 'content' property. - :type content_format: str - :param content: Required. An HTTP link or Base64-encoded binary data. - :type content: str - """ - - _validation = { - 'id': {'readonly': True}, - 'name': {'readonly': True}, - 'type': {'readonly': True}, - 'title': {'required': True}, - 'content_format': {'required': True}, - 'content': {'required': True}, - } - - _attribute_map = { - 'id': {'key': 'id', 'type': 'str'}, - 'name': {'key': 'name', 'type': 'str'}, - 'type': {'key': 'type', 'type': 'str'}, - 'title': {'key': 'properties.title', 'type': 'str'}, - 'content_format': {'key': 'properties.contentFormat', 'type': 'str'}, - 'content': {'key': 'properties.content', 'type': 'str'}, - } - - def __init__(self, *, title: str, content_format: str, content: str, **kwargs) -> None: - super(IssueAttachmentContract, self).__init__(**kwargs) - self.title = title - self.content_format = content_format - self.content = content diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/issue_comment_contract.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/issue_comment_contract.py deleted file mode 100644 index edcad5812c6e..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/issue_comment_contract.py +++ /dev/null @@ -1,59 +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 .resource import Resource - - -class IssueCommentContract(Resource): - """Issue Comment Contract details. - - Variables are only populated by the server, and will be ignored when - sending a request. - - All required parameters must be populated in order to send to Azure. - - :ivar id: Resource ID. - :vartype id: str - :ivar name: Resource name. - :vartype name: str - :ivar type: Resource type for API Management resource. - :vartype type: str - :param text: Required. Comment text. - :type text: str - :param created_date: Date and time when the comment was created. - :type created_date: datetime - :param user_id: Required. A resource identifier for the user who left the - comment. - :type user_id: str - """ - - _validation = { - 'id': {'readonly': True}, - 'name': {'readonly': True}, - 'type': {'readonly': True}, - 'text': {'required': True}, - 'user_id': {'required': True}, - } - - _attribute_map = { - 'id': {'key': 'id', 'type': 'str'}, - 'name': {'key': 'name', 'type': 'str'}, - 'type': {'key': 'type', 'type': 'str'}, - 'text': {'key': 'properties.text', 'type': 'str'}, - 'created_date': {'key': 'properties.createdDate', 'type': 'iso-8601'}, - 'user_id': {'key': 'properties.userId', 'type': 'str'}, - } - - def __init__(self, **kwargs): - super(IssueCommentContract, self).__init__(**kwargs) - self.text = kwargs.get('text', None) - self.created_date = kwargs.get('created_date', None) - self.user_id = kwargs.get('user_id', None) diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/issue_comment_contract_paged.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/issue_comment_contract_paged.py deleted file mode 100644 index 4dc920095266..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/issue_comment_contract_paged.py +++ /dev/null @@ -1,27 +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.paging import Paged - - -class IssueCommentContractPaged(Paged): - """ - A paging container for iterating over a list of :class:`IssueCommentContract ` object - """ - - _attribute_map = { - 'next_link': {'key': 'nextLink', 'type': 'str'}, - 'current_page': {'key': 'value', 'type': '[IssueCommentContract]'} - } - - def __init__(self, *args, **kwargs): - - super(IssueCommentContractPaged, self).__init__(*args, **kwargs) diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/issue_comment_contract_py3.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/issue_comment_contract_py3.py deleted file mode 100644 index 06b355047a92..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/issue_comment_contract_py3.py +++ /dev/null @@ -1,59 +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 .resource_py3 import Resource - - -class IssueCommentContract(Resource): - """Issue Comment Contract details. - - Variables are only populated by the server, and will be ignored when - sending a request. - - All required parameters must be populated in order to send to Azure. - - :ivar id: Resource ID. - :vartype id: str - :ivar name: Resource name. - :vartype name: str - :ivar type: Resource type for API Management resource. - :vartype type: str - :param text: Required. Comment text. - :type text: str - :param created_date: Date and time when the comment was created. - :type created_date: datetime - :param user_id: Required. A resource identifier for the user who left the - comment. - :type user_id: str - """ - - _validation = { - 'id': {'readonly': True}, - 'name': {'readonly': True}, - 'type': {'readonly': True}, - 'text': {'required': True}, - 'user_id': {'required': True}, - } - - _attribute_map = { - 'id': {'key': 'id', 'type': 'str'}, - 'name': {'key': 'name', 'type': 'str'}, - 'type': {'key': 'type', 'type': 'str'}, - 'text': {'key': 'properties.text', 'type': 'str'}, - 'created_date': {'key': 'properties.createdDate', 'type': 'iso-8601'}, - 'user_id': {'key': 'properties.userId', 'type': 'str'}, - } - - def __init__(self, *, text: str, user_id: str, created_date=None, **kwargs) -> None: - super(IssueCommentContract, self).__init__(**kwargs) - self.text = text - self.created_date = created_date - self.user_id = user_id diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/issue_contract.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/issue_contract.py deleted file mode 100644 index 7e9a0bb26e16..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/issue_contract.py +++ /dev/null @@ -1,74 +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 .resource import Resource - - -class IssueContract(Resource): - """Issue Contract details. - - Variables are only populated by the server, and will be ignored when - sending a request. - - All required parameters must be populated in order to send to Azure. - - :ivar id: Resource ID. - :vartype id: str - :ivar name: Resource name. - :vartype name: str - :ivar type: Resource type for API Management resource. - :vartype type: str - :param created_date: Date and time when the issue was created. - :type created_date: datetime - :param state: Status of the issue. Possible values include: 'proposed', - 'open', 'removed', 'resolved', 'closed' - :type state: str or ~azure.mgmt.apimanagement.models.State - :param api_id: A resource identifier for the API the issue was created - for. - :type api_id: str - :param title: Required. The issue title. - :type title: str - :param description: Required. Text describing the issue. - :type description: str - :param user_id: Required. A resource identifier for the user created the - issue. - :type user_id: str - """ - - _validation = { - 'id': {'readonly': True}, - 'name': {'readonly': True}, - 'type': {'readonly': True}, - 'title': {'required': True}, - 'description': {'required': True}, - 'user_id': {'required': True}, - } - - _attribute_map = { - 'id': {'key': 'id', 'type': 'str'}, - 'name': {'key': 'name', 'type': 'str'}, - 'type': {'key': 'type', 'type': 'str'}, - 'created_date': {'key': 'properties.createdDate', 'type': 'iso-8601'}, - 'state': {'key': 'properties.state', 'type': 'str'}, - 'api_id': {'key': 'properties.apiId', 'type': 'str'}, - 'title': {'key': 'properties.title', 'type': 'str'}, - 'description': {'key': 'properties.description', 'type': 'str'}, - 'user_id': {'key': 'properties.userId', 'type': 'str'}, - } - - def __init__(self, **kwargs): - super(IssueContract, self).__init__(**kwargs) - self.created_date = kwargs.get('created_date', None) - self.state = kwargs.get('state', None) - self.api_id = kwargs.get('api_id', None) - self.title = kwargs.get('title', None) - self.description = kwargs.get('description', None) - self.user_id = kwargs.get('user_id', None) diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/issue_contract_base_properties.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/issue_contract_base_properties.py deleted file mode 100644 index 8bf825f0f0de..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/issue_contract_base_properties.py +++ /dev/null @@ -1,38 +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 IssueContractBaseProperties(Model): - """Issue contract Base Properties. - - :param created_date: Date and time when the issue was created. - :type created_date: datetime - :param state: Status of the issue. Possible values include: 'proposed', - 'open', 'removed', 'resolved', 'closed' - :type state: str or ~azure.mgmt.apimanagement.models.State - :param api_id: A resource identifier for the API the issue was created - for. - :type api_id: str - """ - - _attribute_map = { - 'created_date': {'key': 'createdDate', 'type': 'iso-8601'}, - 'state': {'key': 'state', 'type': 'str'}, - 'api_id': {'key': 'apiId', 'type': 'str'}, - } - - def __init__(self, **kwargs): - super(IssueContractBaseProperties, self).__init__(**kwargs) - self.created_date = kwargs.get('created_date', None) - self.state = kwargs.get('state', None) - self.api_id = kwargs.get('api_id', None) diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/issue_contract_base_properties_py3.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/issue_contract_base_properties_py3.py deleted file mode 100644 index 30126d7f0845..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/issue_contract_base_properties_py3.py +++ /dev/null @@ -1,38 +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 IssueContractBaseProperties(Model): - """Issue contract Base Properties. - - :param created_date: Date and time when the issue was created. - :type created_date: datetime - :param state: Status of the issue. Possible values include: 'proposed', - 'open', 'removed', 'resolved', 'closed' - :type state: str or ~azure.mgmt.apimanagement.models.State - :param api_id: A resource identifier for the API the issue was created - for. - :type api_id: str - """ - - _attribute_map = { - 'created_date': {'key': 'createdDate', 'type': 'iso-8601'}, - 'state': {'key': 'state', 'type': 'str'}, - 'api_id': {'key': 'apiId', 'type': 'str'}, - } - - def __init__(self, *, created_date=None, state=None, api_id: str=None, **kwargs) -> None: - super(IssueContractBaseProperties, self).__init__(**kwargs) - self.created_date = created_date - self.state = state - self.api_id = api_id diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/issue_contract_paged.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/issue_contract_paged.py deleted file mode 100644 index fd9375bcab14..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/issue_contract_paged.py +++ /dev/null @@ -1,27 +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.paging import Paged - - -class IssueContractPaged(Paged): - """ - A paging container for iterating over a list of :class:`IssueContract ` object - """ - - _attribute_map = { - 'next_link': {'key': 'nextLink', 'type': 'str'}, - 'current_page': {'key': 'value', 'type': '[IssueContract]'} - } - - def __init__(self, *args, **kwargs): - - super(IssueContractPaged, self).__init__(*args, **kwargs) diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/issue_contract_py3.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/issue_contract_py3.py deleted file mode 100644 index f635214f5b15..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/issue_contract_py3.py +++ /dev/null @@ -1,74 +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 .resource_py3 import Resource - - -class IssueContract(Resource): - """Issue Contract details. - - Variables are only populated by the server, and will be ignored when - sending a request. - - All required parameters must be populated in order to send to Azure. - - :ivar id: Resource ID. - :vartype id: str - :ivar name: Resource name. - :vartype name: str - :ivar type: Resource type for API Management resource. - :vartype type: str - :param created_date: Date and time when the issue was created. - :type created_date: datetime - :param state: Status of the issue. Possible values include: 'proposed', - 'open', 'removed', 'resolved', 'closed' - :type state: str or ~azure.mgmt.apimanagement.models.State - :param api_id: A resource identifier for the API the issue was created - for. - :type api_id: str - :param title: Required. The issue title. - :type title: str - :param description: Required. Text describing the issue. - :type description: str - :param user_id: Required. A resource identifier for the user created the - issue. - :type user_id: str - """ - - _validation = { - 'id': {'readonly': True}, - 'name': {'readonly': True}, - 'type': {'readonly': True}, - 'title': {'required': True}, - 'description': {'required': True}, - 'user_id': {'required': True}, - } - - _attribute_map = { - 'id': {'key': 'id', 'type': 'str'}, - 'name': {'key': 'name', 'type': 'str'}, - 'type': {'key': 'type', 'type': 'str'}, - 'created_date': {'key': 'properties.createdDate', 'type': 'iso-8601'}, - 'state': {'key': 'properties.state', 'type': 'str'}, - 'api_id': {'key': 'properties.apiId', 'type': 'str'}, - 'title': {'key': 'properties.title', 'type': 'str'}, - 'description': {'key': 'properties.description', 'type': 'str'}, - 'user_id': {'key': 'properties.userId', 'type': 'str'}, - } - - def __init__(self, *, title: str, description: str, user_id: str, created_date=None, state=None, api_id: str=None, **kwargs) -> None: - super(IssueContract, self).__init__(**kwargs) - self.created_date = created_date - self.state = state - self.api_id = api_id - self.title = title - self.description = description - self.user_id = user_id diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/issue_update_contract.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/issue_update_contract.py deleted file mode 100644 index cd0c09f71fe8..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/issue_update_contract.py +++ /dev/null @@ -1,50 +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 IssueUpdateContract(Model): - """Issue update Parameters. - - :param created_date: Date and time when the issue was created. - :type created_date: datetime - :param state: Status of the issue. Possible values include: 'proposed', - 'open', 'removed', 'resolved', 'closed' - :type state: str or ~azure.mgmt.apimanagement.models.State - :param api_id: A resource identifier for the API the issue was created - for. - :type api_id: str - :param title: The issue title. - :type title: str - :param description: Text describing the issue. - :type description: str - :param user_id: A resource identifier for the user created the issue. - :type user_id: str - """ - - _attribute_map = { - 'created_date': {'key': 'properties.createdDate', 'type': 'iso-8601'}, - 'state': {'key': 'properties.state', 'type': 'str'}, - 'api_id': {'key': 'properties.apiId', 'type': 'str'}, - 'title': {'key': 'properties.title', 'type': 'str'}, - 'description': {'key': 'properties.description', 'type': 'str'}, - 'user_id': {'key': 'properties.userId', 'type': 'str'}, - } - - def __init__(self, **kwargs): - super(IssueUpdateContract, self).__init__(**kwargs) - self.created_date = kwargs.get('created_date', None) - self.state = kwargs.get('state', None) - self.api_id = kwargs.get('api_id', None) - self.title = kwargs.get('title', None) - self.description = kwargs.get('description', None) - self.user_id = kwargs.get('user_id', None) diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/issue_update_contract_py3.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/issue_update_contract_py3.py deleted file mode 100644 index adaf82829d94..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/issue_update_contract_py3.py +++ /dev/null @@ -1,50 +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 IssueUpdateContract(Model): - """Issue update Parameters. - - :param created_date: Date and time when the issue was created. - :type created_date: datetime - :param state: Status of the issue. Possible values include: 'proposed', - 'open', 'removed', 'resolved', 'closed' - :type state: str or ~azure.mgmt.apimanagement.models.State - :param api_id: A resource identifier for the API the issue was created - for. - :type api_id: str - :param title: The issue title. - :type title: str - :param description: Text describing the issue. - :type description: str - :param user_id: A resource identifier for the user created the issue. - :type user_id: str - """ - - _attribute_map = { - 'created_date': {'key': 'properties.createdDate', 'type': 'iso-8601'}, - 'state': {'key': 'properties.state', 'type': 'str'}, - 'api_id': {'key': 'properties.apiId', 'type': 'str'}, - 'title': {'key': 'properties.title', 'type': 'str'}, - 'description': {'key': 'properties.description', 'type': 'str'}, - 'user_id': {'key': 'properties.userId', 'type': 'str'}, - } - - def __init__(self, *, created_date=None, state=None, api_id: str=None, title: str=None, description: str=None, user_id: str=None, **kwargs) -> None: - super(IssueUpdateContract, self).__init__(**kwargs) - self.created_date = created_date - self.state = state - self.api_id = api_id - self.title = title - self.description = description - self.user_id = user_id diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/logger_contract.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/logger_contract.py deleted file mode 100644 index 16213cac73bb..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/logger_contract.py +++ /dev/null @@ -1,72 +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 .resource import Resource - - -class LoggerContract(Resource): - """Logger details. - - Variables are only populated by the server, and will be ignored when - sending a request. - - All required parameters must be populated in order to send to Azure. - - :ivar id: Resource ID. - :vartype id: str - :ivar name: Resource name. - :vartype name: str - :ivar type: Resource type for API Management resource. - :vartype type: str - :param logger_type: Required. Logger type. Possible values include: - 'azureEventHub', 'applicationInsights' - :type logger_type: str or ~azure.mgmt.apimanagement.models.LoggerType - :param description: Logger description. - :type description: str - :param credentials: Required. The name and SendRule connection string of - the event hub for azureEventHub logger. - Instrumentation key for applicationInsights logger. - :type credentials: dict[str, str] - :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 = { - 'id': {'readonly': True}, - 'name': {'readonly': True}, - 'type': {'readonly': True}, - 'logger_type': {'required': True}, - 'description': {'max_length': 256}, - 'credentials': {'required': True}, - } - - _attribute_map = { - 'id': {'key': 'id', 'type': 'str'}, - 'name': {'key': 'name', 'type': 'str'}, - 'type': {'key': 'type', 'type': 'str'}, - 'logger_type': {'key': 'properties.loggerType', 'type': 'str'}, - '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): - super(LoggerContract, self).__init__(**kwargs) - self.logger_type = kwargs.get('logger_type', None) - 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/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/logger_contract_paged.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/logger_contract_paged.py deleted file mode 100644 index e43659aa7736..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/logger_contract_paged.py +++ /dev/null @@ -1,27 +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.paging import Paged - - -class LoggerContractPaged(Paged): - """ - A paging container for iterating over a list of :class:`LoggerContract ` object - """ - - _attribute_map = { - 'next_link': {'key': 'nextLink', 'type': 'str'}, - 'current_page': {'key': 'value', 'type': '[LoggerContract]'} - } - - def __init__(self, *args, **kwargs): - - super(LoggerContractPaged, self).__init__(*args, **kwargs) diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/logger_contract_py3.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/logger_contract_py3.py deleted file mode 100644 index 59ceb33e5ea3..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/logger_contract_py3.py +++ /dev/null @@ -1,72 +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 .resource_py3 import Resource - - -class LoggerContract(Resource): - """Logger details. - - Variables are only populated by the server, and will be ignored when - sending a request. - - All required parameters must be populated in order to send to Azure. - - :ivar id: Resource ID. - :vartype id: str - :ivar name: Resource name. - :vartype name: str - :ivar type: Resource type for API Management resource. - :vartype type: str - :param logger_type: Required. Logger type. Possible values include: - 'azureEventHub', 'applicationInsights' - :type logger_type: str or ~azure.mgmt.apimanagement.models.LoggerType - :param description: Logger description. - :type description: str - :param credentials: Required. The name and SendRule connection string of - the event hub for azureEventHub logger. - Instrumentation key for applicationInsights logger. - :type credentials: dict[str, str] - :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 = { - 'id': {'readonly': True}, - 'name': {'readonly': True}, - 'type': {'readonly': True}, - 'logger_type': {'required': True}, - 'description': {'max_length': 256}, - 'credentials': {'required': True}, - } - - _attribute_map = { - 'id': {'key': 'id', 'type': 'str'}, - 'name': {'key': 'name', 'type': 'str'}, - 'type': {'key': 'type', 'type': 'str'}, - 'logger_type': {'key': 'properties.loggerType', 'type': 'str'}, - '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: - 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/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/logger_update_contract.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/logger_update_contract.py deleted file mode 100644 index addfa18e243f..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/logger_update_contract.py +++ /dev/null @@ -1,42 +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 LoggerUpdateContract(Model): - """Logger update contract. - - :param logger_type: Logger type. Possible values include: 'azureEventHub', - 'applicationInsights' - :type logger_type: str or ~azure.mgmt.apimanagement.models.LoggerType - :param description: Logger description. - :type description: str - :param credentials: Logger credentials. - :type credentials: dict[str, str] - :param is_buffered: Whether records are buffered in the logger before - publishing. Default is assumed to be true. - :type is_buffered: bool - """ - - _attribute_map = { - 'logger_type': {'key': 'properties.loggerType', 'type': 'str'}, - 'description': {'key': 'properties.description', 'type': 'str'}, - 'credentials': {'key': 'properties.credentials', 'type': '{str}'}, - 'is_buffered': {'key': 'properties.isBuffered', 'type': 'bool'}, - } - - def __init__(self, **kwargs): - super(LoggerUpdateContract, self).__init__(**kwargs) - self.logger_type = kwargs.get('logger_type', None) - self.description = kwargs.get('description', None) - self.credentials = kwargs.get('credentials', None) - self.is_buffered = kwargs.get('is_buffered', None) diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/logger_update_contract_py3.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/logger_update_contract_py3.py deleted file mode 100644 index c87234102e67..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/logger_update_contract_py3.py +++ /dev/null @@ -1,42 +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 LoggerUpdateContract(Model): - """Logger update contract. - - :param logger_type: Logger type. Possible values include: 'azureEventHub', - 'applicationInsights' - :type logger_type: str or ~azure.mgmt.apimanagement.models.LoggerType - :param description: Logger description. - :type description: str - :param credentials: Logger credentials. - :type credentials: dict[str, str] - :param is_buffered: Whether records are buffered in the logger before - publishing. Default is assumed to be true. - :type is_buffered: bool - """ - - _attribute_map = { - 'logger_type': {'key': 'properties.loggerType', 'type': 'str'}, - 'description': {'key': 'properties.description', 'type': 'str'}, - 'credentials': {'key': 'properties.credentials', 'type': '{str}'}, - 'is_buffered': {'key': 'properties.isBuffered', 'type': 'bool'}, - } - - def __init__(self, *, logger_type=None, description: str=None, credentials=None, is_buffered: bool=None, **kwargs) -> None: - super(LoggerUpdateContract, self).__init__(**kwargs) - self.logger_type = logger_type - self.description = description - self.credentials = credentials - self.is_buffered = is_buffered diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/network_status_contract.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/network_status_contract.py deleted file mode 100644 index 93d8cadb8452..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/network_status_contract.py +++ /dev/null @@ -1,41 +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 NetworkStatusContract(Model): - """Network Status details. - - All required parameters must be populated in order to send to Azure. - - :param dns_servers: Required. Gets the list of DNS servers IPV4 addresses. - :type dns_servers: list[str] - :param connectivity_status: Required. Gets the list of Connectivity Status - to the Resources on which the service depends upon. - :type connectivity_status: - list[~azure.mgmt.apimanagement.models.ConnectivityStatusContract] - """ - - _validation = { - 'dns_servers': {'required': True}, - 'connectivity_status': {'required': True}, - } - - _attribute_map = { - 'dns_servers': {'key': 'dnsServers', 'type': '[str]'}, - 'connectivity_status': {'key': 'connectivityStatus', 'type': '[ConnectivityStatusContract]'}, - } - - def __init__(self, **kwargs): - super(NetworkStatusContract, self).__init__(**kwargs) - self.dns_servers = kwargs.get('dns_servers', None) - self.connectivity_status = kwargs.get('connectivity_status', None) diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/network_status_contract_by_location.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/network_status_contract_by_location.py deleted file mode 100644 index d7268e2806dc..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/network_status_contract_by_location.py +++ /dev/null @@ -1,37 +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 NetworkStatusContractByLocation(Model): - """Network Status in the Location. - - :param location: Location of service - :type location: str - :param network_status: Network status in Location - :type network_status: - ~azure.mgmt.apimanagement.models.NetworkStatusContract - """ - - _validation = { - 'location': {'min_length': 1}, - } - - _attribute_map = { - 'location': {'key': 'location', 'type': 'str'}, - 'network_status': {'key': 'networkStatus', 'type': 'NetworkStatusContract'}, - } - - def __init__(self, **kwargs): - super(NetworkStatusContractByLocation, self).__init__(**kwargs) - self.location = kwargs.get('location', None) - self.network_status = kwargs.get('network_status', None) diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/network_status_contract_by_location_py3.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/network_status_contract_by_location_py3.py deleted file mode 100644 index 8179a33cc8bb..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/network_status_contract_by_location_py3.py +++ /dev/null @@ -1,37 +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 NetworkStatusContractByLocation(Model): - """Network Status in the Location. - - :param location: Location of service - :type location: str - :param network_status: Network status in Location - :type network_status: - ~azure.mgmt.apimanagement.models.NetworkStatusContract - """ - - _validation = { - 'location': {'min_length': 1}, - } - - _attribute_map = { - 'location': {'key': 'location', 'type': 'str'}, - 'network_status': {'key': 'networkStatus', 'type': 'NetworkStatusContract'}, - } - - def __init__(self, *, location: str=None, network_status=None, **kwargs) -> None: - super(NetworkStatusContractByLocation, self).__init__(**kwargs) - self.location = location - self.network_status = network_status diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/network_status_contract_py3.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/network_status_contract_py3.py deleted file mode 100644 index 42847b9bee85..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/network_status_contract_py3.py +++ /dev/null @@ -1,41 +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 NetworkStatusContract(Model): - """Network Status details. - - All required parameters must be populated in order to send to Azure. - - :param dns_servers: Required. Gets the list of DNS servers IPV4 addresses. - :type dns_servers: list[str] - :param connectivity_status: Required. Gets the list of Connectivity Status - to the Resources on which the service depends upon. - :type connectivity_status: - list[~azure.mgmt.apimanagement.models.ConnectivityStatusContract] - """ - - _validation = { - 'dns_servers': {'required': True}, - 'connectivity_status': {'required': True}, - } - - _attribute_map = { - 'dns_servers': {'key': 'dnsServers', 'type': '[str]'}, - 'connectivity_status': {'key': 'connectivityStatus', 'type': '[ConnectivityStatusContract]'}, - } - - def __init__(self, *, dns_servers, connectivity_status, **kwargs) -> None: - super(NetworkStatusContract, self).__init__(**kwargs) - self.dns_servers = dns_servers - self.connectivity_status = connectivity_status diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/notification_contract.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/notification_contract.py deleted file mode 100644 index 0a61e503deae..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/notification_contract.py +++ /dev/null @@ -1,58 +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 .resource import Resource - - -class NotificationContract(Resource): - """Notification details. - - Variables are only populated by the server, and will be ignored when - sending a request. - - All required parameters must be populated in order to send to Azure. - - :ivar id: Resource ID. - :vartype id: str - :ivar name: Resource name. - :vartype name: str - :ivar type: Resource type for API Management resource. - :vartype type: str - :param title: Required. Title of the Notification. - :type title: str - :param description: Description of the Notification. - :type description: str - :param recipients: Recipient Parameter values. - :type recipients: - ~azure.mgmt.apimanagement.models.RecipientsContractProperties - """ - - _validation = { - 'id': {'readonly': True}, - 'name': {'readonly': True}, - 'type': {'readonly': True}, - 'title': {'required': True, 'max_length': 1000, 'min_length': 1}, - } - - _attribute_map = { - 'id': {'key': 'id', 'type': 'str'}, - 'name': {'key': 'name', 'type': 'str'}, - 'type': {'key': 'type', 'type': 'str'}, - 'title': {'key': 'properties.title', 'type': 'str'}, - 'description': {'key': 'properties.description', 'type': 'str'}, - 'recipients': {'key': 'properties.recipients', 'type': 'RecipientsContractProperties'}, - } - - def __init__(self, **kwargs): - super(NotificationContract, self).__init__(**kwargs) - self.title = kwargs.get('title', None) - self.description = kwargs.get('description', None) - self.recipients = kwargs.get('recipients', None) diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/notification_contract_paged.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/notification_contract_paged.py deleted file mode 100644 index be23f722f720..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/notification_contract_paged.py +++ /dev/null @@ -1,27 +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.paging import Paged - - -class NotificationContractPaged(Paged): - """ - A paging container for iterating over a list of :class:`NotificationContract ` object - """ - - _attribute_map = { - 'next_link': {'key': 'nextLink', 'type': 'str'}, - 'current_page': {'key': 'value', 'type': '[NotificationContract]'} - } - - def __init__(self, *args, **kwargs): - - super(NotificationContractPaged, self).__init__(*args, **kwargs) diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/notification_contract_py3.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/notification_contract_py3.py deleted file mode 100644 index bcc72b618ddf..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/notification_contract_py3.py +++ /dev/null @@ -1,58 +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 .resource_py3 import Resource - - -class NotificationContract(Resource): - """Notification details. - - Variables are only populated by the server, and will be ignored when - sending a request. - - All required parameters must be populated in order to send to Azure. - - :ivar id: Resource ID. - :vartype id: str - :ivar name: Resource name. - :vartype name: str - :ivar type: Resource type for API Management resource. - :vartype type: str - :param title: Required. Title of the Notification. - :type title: str - :param description: Description of the Notification. - :type description: str - :param recipients: Recipient Parameter values. - :type recipients: - ~azure.mgmt.apimanagement.models.RecipientsContractProperties - """ - - _validation = { - 'id': {'readonly': True}, - 'name': {'readonly': True}, - 'type': {'readonly': True}, - 'title': {'required': True, 'max_length': 1000, 'min_length': 1}, - } - - _attribute_map = { - 'id': {'key': 'id', 'type': 'str'}, - 'name': {'key': 'name', 'type': 'str'}, - 'type': {'key': 'type', 'type': 'str'}, - 'title': {'key': 'properties.title', 'type': 'str'}, - 'description': {'key': 'properties.description', 'type': 'str'}, - 'recipients': {'key': 'properties.recipients', 'type': 'RecipientsContractProperties'}, - } - - def __init__(self, *, title: str, description: str=None, recipients=None, **kwargs) -> None: - super(NotificationContract, self).__init__(**kwargs) - self.title = title - self.description = description - self.recipients = recipients diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/oauth2_authentication_settings_contract.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/oauth2_authentication_settings_contract.py deleted file mode 100644 index ed8482767874..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/oauth2_authentication_settings_contract.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 OAuth2AuthenticationSettingsContract(Model): - """API OAuth2 Authentication settings details. - - :param authorization_server_id: OAuth authorization server identifier. - :type authorization_server_id: str - :param scope: operations scope. - :type scope: str - """ - - _attribute_map = { - 'authorization_server_id': {'key': 'authorizationServerId', 'type': 'str'}, - 'scope': {'key': 'scope', 'type': 'str'}, - } - - def __init__(self, **kwargs): - super(OAuth2AuthenticationSettingsContract, self).__init__(**kwargs) - self.authorization_server_id = kwargs.get('authorization_server_id', None) - self.scope = kwargs.get('scope', None) diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/oauth2_authentication_settings_contract_py3.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/oauth2_authentication_settings_contract_py3.py deleted file mode 100644 index f0a1eac4ca71..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/oauth2_authentication_settings_contract_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 OAuth2AuthenticationSettingsContract(Model): - """API OAuth2 Authentication settings details. - - :param authorization_server_id: OAuth authorization server identifier. - :type authorization_server_id: str - :param scope: operations scope. - :type scope: str - """ - - _attribute_map = { - 'authorization_server_id': {'key': 'authorizationServerId', 'type': 'str'}, - 'scope': {'key': 'scope', 'type': 'str'}, - } - - def __init__(self, *, authorization_server_id: str=None, scope: str=None, **kwargs) -> None: - super(OAuth2AuthenticationSettingsContract, self).__init__(**kwargs) - self.authorization_server_id = authorization_server_id - self.scope = scope diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/open_id_authentication_settings_contract.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/open_id_authentication_settings_contract.py deleted file mode 100644 index 4e5470794460..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/open_id_authentication_settings_contract.py +++ /dev/null @@ -1,33 +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 OpenIdAuthenticationSettingsContract(Model): - """API OAuth2 Authentication settings details. - - :param openid_provider_id: OAuth authorization server identifier. - :type openid_provider_id: str - :param bearer_token_sending_methods: How to send token to the server. - :type bearer_token_sending_methods: list[str or - ~azure.mgmt.apimanagement.models.BearerTokenSendingMethods] - """ - - _attribute_map = { - 'openid_provider_id': {'key': 'openidProviderId', 'type': 'str'}, - 'bearer_token_sending_methods': {'key': 'bearerTokenSendingMethods', 'type': '[str]'}, - } - - def __init__(self, **kwargs): - super(OpenIdAuthenticationSettingsContract, self).__init__(**kwargs) - self.openid_provider_id = kwargs.get('openid_provider_id', None) - self.bearer_token_sending_methods = kwargs.get('bearer_token_sending_methods', None) diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/open_id_authentication_settings_contract_py3.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/open_id_authentication_settings_contract_py3.py deleted file mode 100644 index 112a077b9833..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/open_id_authentication_settings_contract_py3.py +++ /dev/null @@ -1,33 +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 OpenIdAuthenticationSettingsContract(Model): - """API OAuth2 Authentication settings details. - - :param openid_provider_id: OAuth authorization server identifier. - :type openid_provider_id: str - :param bearer_token_sending_methods: How to send token to the server. - :type bearer_token_sending_methods: list[str or - ~azure.mgmt.apimanagement.models.BearerTokenSendingMethods] - """ - - _attribute_map = { - 'openid_provider_id': {'key': 'openidProviderId', 'type': 'str'}, - 'bearer_token_sending_methods': {'key': 'bearerTokenSendingMethods', 'type': '[str]'}, - } - - def __init__(self, *, openid_provider_id: str=None, bearer_token_sending_methods=None, **kwargs) -> None: - super(OpenIdAuthenticationSettingsContract, self).__init__(**kwargs) - self.openid_provider_id = openid_provider_id - self.bearer_token_sending_methods = bearer_token_sending_methods diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/openid_connect_provider_contract.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/openid_connect_provider_contract.py deleted file mode 100644 index 0ac98bb10f48..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/openid_connect_provider_contract.py +++ /dev/null @@ -1,69 +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 .resource import Resource - - -class OpenidConnectProviderContract(Resource): - """OpenId Connect Provider details. - - Variables are only populated by the server, and will be ignored when - sending a request. - - All required parameters must be populated in order to send to Azure. - - :ivar id: Resource ID. - :vartype id: str - :ivar name: Resource name. - :vartype name: str - :ivar type: Resource type for API Management resource. - :vartype type: str - :param display_name: Required. User-friendly OpenID Connect Provider name. - :type display_name: str - :param description: User-friendly description of OpenID Connect Provider. - :type description: str - :param metadata_endpoint: Required. Metadata endpoint URI. - :type metadata_endpoint: str - :param client_id: Required. Client ID of developer console which is the - client application. - :type client_id: str - :param client_secret: Client Secret of developer console which is the - client application. - :type client_secret: str - """ - - _validation = { - 'id': {'readonly': True}, - 'name': {'readonly': True}, - 'type': {'readonly': True}, - 'display_name': {'required': True, 'max_length': 50}, - 'metadata_endpoint': {'required': True}, - 'client_id': {'required': True}, - } - - _attribute_map = { - 'id': {'key': 'id', 'type': 'str'}, - 'name': {'key': 'name', 'type': 'str'}, - 'type': {'key': 'type', 'type': 'str'}, - 'display_name': {'key': 'properties.displayName', 'type': 'str'}, - 'description': {'key': 'properties.description', 'type': 'str'}, - 'metadata_endpoint': {'key': 'properties.metadataEndpoint', 'type': 'str'}, - 'client_id': {'key': 'properties.clientId', 'type': 'str'}, - 'client_secret': {'key': 'properties.clientSecret', 'type': 'str'}, - } - - def __init__(self, **kwargs): - super(OpenidConnectProviderContract, self).__init__(**kwargs) - self.display_name = kwargs.get('display_name', None) - self.description = kwargs.get('description', None) - self.metadata_endpoint = kwargs.get('metadata_endpoint', None) - self.client_id = kwargs.get('client_id', None) - self.client_secret = kwargs.get('client_secret', None) diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/openid_connect_provider_contract_paged.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/openid_connect_provider_contract_paged.py deleted file mode 100644 index ade0ae119282..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/openid_connect_provider_contract_paged.py +++ /dev/null @@ -1,27 +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.paging import Paged - - -class OpenidConnectProviderContractPaged(Paged): - """ - A paging container for iterating over a list of :class:`OpenidConnectProviderContract ` object - """ - - _attribute_map = { - 'next_link': {'key': 'nextLink', 'type': 'str'}, - 'current_page': {'key': 'value', 'type': '[OpenidConnectProviderContract]'} - } - - def __init__(self, *args, **kwargs): - - super(OpenidConnectProviderContractPaged, self).__init__(*args, **kwargs) diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/openid_connect_provider_contract_py3.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/openid_connect_provider_contract_py3.py deleted file mode 100644 index cbbc85bde124..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/openid_connect_provider_contract_py3.py +++ /dev/null @@ -1,69 +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 .resource_py3 import Resource - - -class OpenidConnectProviderContract(Resource): - """OpenId Connect Provider details. - - Variables are only populated by the server, and will be ignored when - sending a request. - - All required parameters must be populated in order to send to Azure. - - :ivar id: Resource ID. - :vartype id: str - :ivar name: Resource name. - :vartype name: str - :ivar type: Resource type for API Management resource. - :vartype type: str - :param display_name: Required. User-friendly OpenID Connect Provider name. - :type display_name: str - :param description: User-friendly description of OpenID Connect Provider. - :type description: str - :param metadata_endpoint: Required. Metadata endpoint URI. - :type metadata_endpoint: str - :param client_id: Required. Client ID of developer console which is the - client application. - :type client_id: str - :param client_secret: Client Secret of developer console which is the - client application. - :type client_secret: str - """ - - _validation = { - 'id': {'readonly': True}, - 'name': {'readonly': True}, - 'type': {'readonly': True}, - 'display_name': {'required': True, 'max_length': 50}, - 'metadata_endpoint': {'required': True}, - 'client_id': {'required': True}, - } - - _attribute_map = { - 'id': {'key': 'id', 'type': 'str'}, - 'name': {'key': 'name', 'type': 'str'}, - 'type': {'key': 'type', 'type': 'str'}, - 'display_name': {'key': 'properties.displayName', 'type': 'str'}, - 'description': {'key': 'properties.description', 'type': 'str'}, - 'metadata_endpoint': {'key': 'properties.metadataEndpoint', 'type': 'str'}, - 'client_id': {'key': 'properties.clientId', 'type': 'str'}, - 'client_secret': {'key': 'properties.clientSecret', 'type': 'str'}, - } - - def __init__(self, *, display_name: str, metadata_endpoint: str, client_id: str, description: str=None, client_secret: str=None, **kwargs) -> None: - super(OpenidConnectProviderContract, self).__init__(**kwargs) - self.display_name = display_name - self.description = description - self.metadata_endpoint = metadata_endpoint - self.client_id = client_id - self.client_secret = client_secret diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/openid_connect_provider_update_contract.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/openid_connect_provider_update_contract.py deleted file mode 100644 index ff37d87ccedd..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/openid_connect_provider_update_contract.py +++ /dev/null @@ -1,50 +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 OpenidConnectProviderUpdateContract(Model): - """Parameters supplied to the Update OpenID Connect Provider operation. - - :param display_name: User-friendly OpenID Connect Provider name. - :type display_name: str - :param description: User-friendly description of OpenID Connect Provider. - :type description: str - :param metadata_endpoint: Metadata endpoint URI. - :type metadata_endpoint: str - :param client_id: Client ID of developer console which is the client - application. - :type client_id: str - :param client_secret: Client Secret of developer console which is the - client application. - :type client_secret: str - """ - - _validation = { - 'display_name': {'max_length': 50}, - } - - _attribute_map = { - 'display_name': {'key': 'properties.displayName', 'type': 'str'}, - 'description': {'key': 'properties.description', 'type': 'str'}, - 'metadata_endpoint': {'key': 'properties.metadataEndpoint', 'type': 'str'}, - 'client_id': {'key': 'properties.clientId', 'type': 'str'}, - 'client_secret': {'key': 'properties.clientSecret', 'type': 'str'}, - } - - def __init__(self, **kwargs): - super(OpenidConnectProviderUpdateContract, self).__init__(**kwargs) - self.display_name = kwargs.get('display_name', None) - self.description = kwargs.get('description', None) - self.metadata_endpoint = kwargs.get('metadata_endpoint', None) - self.client_id = kwargs.get('client_id', None) - self.client_secret = kwargs.get('client_secret', None) diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/openid_connect_provider_update_contract_py3.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/openid_connect_provider_update_contract_py3.py deleted file mode 100644 index 0acdde07011a..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/openid_connect_provider_update_contract_py3.py +++ /dev/null @@ -1,50 +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 OpenidConnectProviderUpdateContract(Model): - """Parameters supplied to the Update OpenID Connect Provider operation. - - :param display_name: User-friendly OpenID Connect Provider name. - :type display_name: str - :param description: User-friendly description of OpenID Connect Provider. - :type description: str - :param metadata_endpoint: Metadata endpoint URI. - :type metadata_endpoint: str - :param client_id: Client ID of developer console which is the client - application. - :type client_id: str - :param client_secret: Client Secret of developer console which is the - client application. - :type client_secret: str - """ - - _validation = { - 'display_name': {'max_length': 50}, - } - - _attribute_map = { - 'display_name': {'key': 'properties.displayName', 'type': 'str'}, - 'description': {'key': 'properties.description', 'type': 'str'}, - 'metadata_endpoint': {'key': 'properties.metadataEndpoint', 'type': 'str'}, - 'client_id': {'key': 'properties.clientId', 'type': 'str'}, - 'client_secret': {'key': 'properties.clientSecret', 'type': 'str'}, - } - - def __init__(self, *, display_name: str=None, description: str=None, metadata_endpoint: str=None, client_id: str=None, client_secret: str=None, **kwargs) -> None: - super(OpenidConnectProviderUpdateContract, self).__init__(**kwargs) - self.display_name = display_name - self.description = description - self.metadata_endpoint = metadata_endpoint - self.client_id = client_id - self.client_secret = client_secret diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/operation.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/operation.py deleted file mode 100644 index 9b403bad2fcf..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/operation.py +++ /dev/null @@ -1,40 +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 Operation(Model): - """REST API operation. - - :param name: Operation name: {provider}/{resource}/{operation} - :type name: str - :param display: The object that describes the operation. - :type display: ~azure.mgmt.apimanagement.models.OperationDisplay - :param origin: The operation origin. - :type origin: str - :param properties: The operation properties. - :type properties: object - """ - - _attribute_map = { - 'name': {'key': 'name', 'type': 'str'}, - 'display': {'key': 'display', 'type': 'OperationDisplay'}, - 'origin': {'key': 'origin', 'type': 'str'}, - 'properties': {'key': 'properties', 'type': 'object'}, - } - - def __init__(self, **kwargs): - super(Operation, self).__init__(**kwargs) - self.name = kwargs.get('name', None) - self.display = kwargs.get('display', None) - self.origin = kwargs.get('origin', None) - self.properties = kwargs.get('properties', None) diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/operation_contract.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/operation_contract.py deleted file mode 100644 index cf9b5b4a3ff0..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/operation_contract.py +++ /dev/null @@ -1,85 +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 .resource import Resource - - -class OperationContract(Resource): - """Api Operation details. - - Variables are only populated by the server, and will be ignored when - sending a request. - - All required parameters must be populated in order to send to Azure. - - :ivar id: Resource ID. - :vartype id: str - :ivar name: Resource name. - :vartype name: str - :ivar type: Resource type for API Management resource. - :vartype type: str - :param template_parameters: Collection of URL template parameters. - :type template_parameters: - list[~azure.mgmt.apimanagement.models.ParameterContract] - :param description: Description of the operation. May include HTML - formatting tags. - :type description: str - :param request: An entity containing request details. - :type request: ~azure.mgmt.apimanagement.models.RequestContract - :param responses: Array of Operation responses. - :type responses: list[~azure.mgmt.apimanagement.models.ResponseContract] - :param policies: Operation Policies - :type policies: str - :param display_name: Required. Operation Name. - :type display_name: str - :param method: Required. A Valid HTTP Operation Method. Typical Http - Methods like GET, PUT, POST but not limited by only them. - :type method: str - :param url_template: Required. Relative URL template identifying the - target resource for this operation. May include parameters. Example: - /customers/{cid}/orders/{oid}/?date={date} - :type url_template: str - """ - - _validation = { - 'id': {'readonly': True}, - 'name': {'readonly': True}, - 'type': {'readonly': True}, - 'description': {'max_length': 1000}, - 'display_name': {'required': True, 'max_length': 300, 'min_length': 1}, - 'method': {'required': True}, - 'url_template': {'required': True, 'max_length': 1000, 'min_length': 1}, - } - - _attribute_map = { - 'id': {'key': 'id', 'type': 'str'}, - 'name': {'key': 'name', 'type': 'str'}, - 'type': {'key': 'type', 'type': 'str'}, - 'template_parameters': {'key': 'properties.templateParameters', 'type': '[ParameterContract]'}, - 'description': {'key': 'properties.description', 'type': 'str'}, - 'request': {'key': 'properties.request', 'type': 'RequestContract'}, - 'responses': {'key': 'properties.responses', 'type': '[ResponseContract]'}, - 'policies': {'key': 'properties.policies', 'type': 'str'}, - 'display_name': {'key': 'properties.displayName', 'type': 'str'}, - 'method': {'key': 'properties.method', 'type': 'str'}, - 'url_template': {'key': 'properties.urlTemplate', 'type': 'str'}, - } - - def __init__(self, **kwargs): - super(OperationContract, self).__init__(**kwargs) - self.template_parameters = kwargs.get('template_parameters', None) - self.description = kwargs.get('description', None) - self.request = kwargs.get('request', None) - self.responses = kwargs.get('responses', None) - self.policies = kwargs.get('policies', None) - self.display_name = kwargs.get('display_name', None) - self.method = kwargs.get('method', None) - self.url_template = kwargs.get('url_template', None) diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/operation_contract_paged.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/operation_contract_paged.py deleted file mode 100644 index d26188bf9f3b..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/operation_contract_paged.py +++ /dev/null @@ -1,27 +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.paging import Paged - - -class OperationContractPaged(Paged): - """ - A paging container for iterating over a list of :class:`OperationContract ` object - """ - - _attribute_map = { - 'next_link': {'key': 'nextLink', 'type': 'str'}, - 'current_page': {'key': 'value', 'type': '[OperationContract]'} - } - - def __init__(self, *args, **kwargs): - - super(OperationContractPaged, self).__init__(*args, **kwargs) diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/operation_contract_py3.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/operation_contract_py3.py deleted file mode 100644 index 197b2f410f8d..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/operation_contract_py3.py +++ /dev/null @@ -1,85 +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 .resource_py3 import Resource - - -class OperationContract(Resource): - """Api Operation details. - - Variables are only populated by the server, and will be ignored when - sending a request. - - All required parameters must be populated in order to send to Azure. - - :ivar id: Resource ID. - :vartype id: str - :ivar name: Resource name. - :vartype name: str - :ivar type: Resource type for API Management resource. - :vartype type: str - :param template_parameters: Collection of URL template parameters. - :type template_parameters: - list[~azure.mgmt.apimanagement.models.ParameterContract] - :param description: Description of the operation. May include HTML - formatting tags. - :type description: str - :param request: An entity containing request details. - :type request: ~azure.mgmt.apimanagement.models.RequestContract - :param responses: Array of Operation responses. - :type responses: list[~azure.mgmt.apimanagement.models.ResponseContract] - :param policies: Operation Policies - :type policies: str - :param display_name: Required. Operation Name. - :type display_name: str - :param method: Required. A Valid HTTP Operation Method. Typical Http - Methods like GET, PUT, POST but not limited by only them. - :type method: str - :param url_template: Required. Relative URL template identifying the - target resource for this operation. May include parameters. Example: - /customers/{cid}/orders/{oid}/?date={date} - :type url_template: str - """ - - _validation = { - 'id': {'readonly': True}, - 'name': {'readonly': True}, - 'type': {'readonly': True}, - 'description': {'max_length': 1000}, - 'display_name': {'required': True, 'max_length': 300, 'min_length': 1}, - 'method': {'required': True}, - 'url_template': {'required': True, 'max_length': 1000, 'min_length': 1}, - } - - _attribute_map = { - 'id': {'key': 'id', 'type': 'str'}, - 'name': {'key': 'name', 'type': 'str'}, - 'type': {'key': 'type', 'type': 'str'}, - 'template_parameters': {'key': 'properties.templateParameters', 'type': '[ParameterContract]'}, - 'description': {'key': 'properties.description', 'type': 'str'}, - 'request': {'key': 'properties.request', 'type': 'RequestContract'}, - 'responses': {'key': 'properties.responses', 'type': '[ResponseContract]'}, - 'policies': {'key': 'properties.policies', 'type': 'str'}, - 'display_name': {'key': 'properties.displayName', 'type': 'str'}, - 'method': {'key': 'properties.method', 'type': 'str'}, - 'url_template': {'key': 'properties.urlTemplate', 'type': 'str'}, - } - - def __init__(self, *, display_name: str, method: str, url_template: str, template_parameters=None, description: str=None, request=None, responses=None, policies: str=None, **kwargs) -> None: - super(OperationContract, self).__init__(**kwargs) - self.template_parameters = template_parameters - self.description = description - self.request = request - self.responses = responses - self.policies = policies - self.display_name = display_name - self.method = method - self.url_template = url_template diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/operation_display.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/operation_display.py deleted file mode 100644 index d0fde0c4a0b9..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/operation_display.py +++ /dev/null @@ -1,41 +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 OperationDisplay(Model): - """The object that describes the operation. - - :param provider: Friendly name of the resource provider - :type provider: str - :param operation: Operation type: read, write, delete, listKeys/action, - etc. - :type operation: str - :param resource: Resource type on which the operation is performed. - :type resource: str - :param description: Friendly name of the operation - :type description: str - """ - - _attribute_map = { - 'provider': {'key': 'provider', 'type': 'str'}, - 'operation': {'key': 'operation', 'type': 'str'}, - 'resource': {'key': 'resource', 'type': 'str'}, - 'description': {'key': 'description', 'type': 'str'}, - } - - def __init__(self, **kwargs): - super(OperationDisplay, self).__init__(**kwargs) - self.provider = kwargs.get('provider', None) - self.operation = kwargs.get('operation', None) - self.resource = kwargs.get('resource', None) - self.description = kwargs.get('description', None) diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/operation_display_py3.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/operation_display_py3.py deleted file mode 100644 index 37858ea03adb..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/operation_display_py3.py +++ /dev/null @@ -1,41 +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 OperationDisplay(Model): - """The object that describes the operation. - - :param provider: Friendly name of the resource provider - :type provider: str - :param operation: Operation type: read, write, delete, listKeys/action, - etc. - :type operation: str - :param resource: Resource type on which the operation is performed. - :type resource: str - :param description: Friendly name of the operation - :type description: str - """ - - _attribute_map = { - 'provider': {'key': 'provider', 'type': 'str'}, - 'operation': {'key': 'operation', 'type': 'str'}, - 'resource': {'key': 'resource', 'type': 'str'}, - 'description': {'key': 'description', 'type': 'str'}, - } - - def __init__(self, *, provider: str=None, operation: str=None, resource: str=None, description: str=None, **kwargs) -> None: - super(OperationDisplay, self).__init__(**kwargs) - self.provider = provider - self.operation = operation - self.resource = resource - self.description = description diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/operation_entity_base_contract.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/operation_entity_base_contract.py deleted file mode 100644 index bc0a8f41ace2..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/operation_entity_base_contract.py +++ /dev/null @@ -1,50 +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 OperationEntityBaseContract(Model): - """Api Operation Entity Base Contract details. - - :param template_parameters: Collection of URL template parameters. - :type template_parameters: - list[~azure.mgmt.apimanagement.models.ParameterContract] - :param description: Description of the operation. May include HTML - formatting tags. - :type description: str - :param request: An entity containing request details. - :type request: ~azure.mgmt.apimanagement.models.RequestContract - :param responses: Array of Operation responses. - :type responses: list[~azure.mgmt.apimanagement.models.ResponseContract] - :param policies: Operation Policies - :type policies: str - """ - - _validation = { - 'description': {'max_length': 1000}, - } - - _attribute_map = { - 'template_parameters': {'key': 'templateParameters', 'type': '[ParameterContract]'}, - 'description': {'key': 'description', 'type': 'str'}, - 'request': {'key': 'request', 'type': 'RequestContract'}, - 'responses': {'key': 'responses', 'type': '[ResponseContract]'}, - 'policies': {'key': 'policies', 'type': 'str'}, - } - - def __init__(self, **kwargs): - super(OperationEntityBaseContract, self).__init__(**kwargs) - self.template_parameters = kwargs.get('template_parameters', None) - self.description = kwargs.get('description', None) - self.request = kwargs.get('request', None) - self.responses = kwargs.get('responses', None) - self.policies = kwargs.get('policies', None) diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/operation_entity_base_contract_py3.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/operation_entity_base_contract_py3.py deleted file mode 100644 index 62d409a210db..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/operation_entity_base_contract_py3.py +++ /dev/null @@ -1,50 +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 OperationEntityBaseContract(Model): - """Api Operation Entity Base Contract details. - - :param template_parameters: Collection of URL template parameters. - :type template_parameters: - list[~azure.mgmt.apimanagement.models.ParameterContract] - :param description: Description of the operation. May include HTML - formatting tags. - :type description: str - :param request: An entity containing request details. - :type request: ~azure.mgmt.apimanagement.models.RequestContract - :param responses: Array of Operation responses. - :type responses: list[~azure.mgmt.apimanagement.models.ResponseContract] - :param policies: Operation Policies - :type policies: str - """ - - _validation = { - 'description': {'max_length': 1000}, - } - - _attribute_map = { - 'template_parameters': {'key': 'templateParameters', 'type': '[ParameterContract]'}, - 'description': {'key': 'description', 'type': 'str'}, - 'request': {'key': 'request', 'type': 'RequestContract'}, - 'responses': {'key': 'responses', 'type': '[ResponseContract]'}, - 'policies': {'key': 'policies', 'type': 'str'}, - } - - def __init__(self, *, template_parameters=None, description: str=None, request=None, responses=None, policies: str=None, **kwargs) -> None: - super(OperationEntityBaseContract, self).__init__(**kwargs) - self.template_parameters = template_parameters - self.description = description - self.request = request - self.responses = responses - self.policies = policies diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/operation_paged.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/operation_paged.py deleted file mode 100644 index 950b8acd7466..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/operation_paged.py +++ /dev/null @@ -1,27 +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.paging import Paged - - -class OperationPaged(Paged): - """ - A paging container for iterating over a list of :class:`Operation ` object - """ - - _attribute_map = { - 'next_link': {'key': 'nextLink', 'type': 'str'}, - 'current_page': {'key': 'value', 'type': '[Operation]'} - } - - def __init__(self, *args, **kwargs): - - super(OperationPaged, self).__init__(*args, **kwargs) diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/operation_py3.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/operation_py3.py deleted file mode 100644 index eb38d162365a..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/operation_py3.py +++ /dev/null @@ -1,40 +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 Operation(Model): - """REST API operation. - - :param name: Operation name: {provider}/{resource}/{operation} - :type name: str - :param display: The object that describes the operation. - :type display: ~azure.mgmt.apimanagement.models.OperationDisplay - :param origin: The operation origin. - :type origin: str - :param properties: The operation properties. - :type properties: object - """ - - _attribute_map = { - 'name': {'key': 'name', 'type': 'str'}, - 'display': {'key': 'display', 'type': 'OperationDisplay'}, - 'origin': {'key': 'origin', 'type': 'str'}, - 'properties': {'key': 'properties', 'type': 'object'}, - } - - def __init__(self, *, name: str=None, display=None, origin: str=None, properties=None, **kwargs) -> None: - super(Operation, self).__init__(**kwargs) - self.name = name - self.display = display - self.origin = origin - self.properties = properties diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/operation_result_contract.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/operation_result_contract.py deleted file mode 100644 index 736344faab29..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/operation_result_contract.py +++ /dev/null @@ -1,68 +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 OperationResultContract(Model): - """Operation Result. - - Variables are only populated by the server, and will be ignored when - sending a request. - - :param id: Operation result identifier. - :type id: str - :param status: Status of an async operation. Possible values include: - 'Started', 'InProgress', 'Succeeded', 'Failed' - :type status: str or ~azure.mgmt.apimanagement.models.AsyncOperationStatus - :param started: Start time of an async operation. The date conforms to the - following format: `yyyy-MM-ddTHH:mm:ssZ` as specified by the ISO 8601 - standard. - :type started: datetime - :param updated: Last update time of an async operation. The date conforms - to the following format: `yyyy-MM-ddTHH:mm:ssZ` as specified by the ISO - 8601 standard. - :type updated: datetime - :param result_info: Optional result info. - :type result_info: str - :param error: Error Body Contract - :type error: ~azure.mgmt.apimanagement.models.ErrorResponseBody - :ivar action_log: This property if only provided as part of the - TenantConfiguration_Validate operation. It contains the log the entities - which will be updated/created/deleted as part of the - TenantConfiguration_Deploy operation. - :vartype action_log: - list[~azure.mgmt.apimanagement.models.OperationResultLogItemContract] - """ - - _validation = { - 'action_log': {'readonly': True}, - } - - _attribute_map = { - 'id': {'key': 'id', 'type': 'str'}, - 'status': {'key': 'status', 'type': 'AsyncOperationStatus'}, - 'started': {'key': 'started', 'type': 'iso-8601'}, - 'updated': {'key': 'updated', 'type': 'iso-8601'}, - 'result_info': {'key': 'resultInfo', 'type': 'str'}, - 'error': {'key': 'error', 'type': 'ErrorResponseBody'}, - 'action_log': {'key': 'actionLog', 'type': '[OperationResultLogItemContract]'}, - } - - def __init__(self, **kwargs): - super(OperationResultContract, self).__init__(**kwargs) - self.id = kwargs.get('id', None) - self.status = kwargs.get('status', None) - self.started = kwargs.get('started', None) - self.updated = kwargs.get('updated', None) - self.result_info = kwargs.get('result_info', None) - self.error = kwargs.get('error', None) - self.action_log = None diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/operation_result_contract_py3.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/operation_result_contract_py3.py deleted file mode 100644 index 0694c535ae2b..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/operation_result_contract_py3.py +++ /dev/null @@ -1,68 +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 OperationResultContract(Model): - """Operation Result. - - Variables are only populated by the server, and will be ignored when - sending a request. - - :param id: Operation result identifier. - :type id: str - :param status: Status of an async operation. Possible values include: - 'Started', 'InProgress', 'Succeeded', 'Failed' - :type status: str or ~azure.mgmt.apimanagement.models.AsyncOperationStatus - :param started: Start time of an async operation. The date conforms to the - following format: `yyyy-MM-ddTHH:mm:ssZ` as specified by the ISO 8601 - standard. - :type started: datetime - :param updated: Last update time of an async operation. The date conforms - to the following format: `yyyy-MM-ddTHH:mm:ssZ` as specified by the ISO - 8601 standard. - :type updated: datetime - :param result_info: Optional result info. - :type result_info: str - :param error: Error Body Contract - :type error: ~azure.mgmt.apimanagement.models.ErrorResponseBody - :ivar action_log: This property if only provided as part of the - TenantConfiguration_Validate operation. It contains the log the entities - which will be updated/created/deleted as part of the - TenantConfiguration_Deploy operation. - :vartype action_log: - list[~azure.mgmt.apimanagement.models.OperationResultLogItemContract] - """ - - _validation = { - 'action_log': {'readonly': True}, - } - - _attribute_map = { - 'id': {'key': 'id', 'type': 'str'}, - 'status': {'key': 'status', 'type': 'AsyncOperationStatus'}, - 'started': {'key': 'started', 'type': 'iso-8601'}, - 'updated': {'key': 'updated', 'type': 'iso-8601'}, - 'result_info': {'key': 'resultInfo', 'type': 'str'}, - 'error': {'key': 'error', 'type': 'ErrorResponseBody'}, - 'action_log': {'key': 'actionLog', 'type': '[OperationResultLogItemContract]'}, - } - - def __init__(self, *, id: str=None, status=None, started=None, updated=None, result_info: str=None, error=None, **kwargs) -> None: - super(OperationResultContract, self).__init__(**kwargs) - self.id = id - self.status = status - self.started = started - self.updated = updated - self.result_info = result_info - self.error = error - self.action_log = None diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/operation_result_log_item_contract.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/operation_result_log_item_contract.py deleted file mode 100644 index 7c6f2c63c7c0..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/operation_result_log_item_contract.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 OperationResultLogItemContract(Model): - """Log of the entity being created, updated or deleted. - - :param object_type: The type of entity contract. - :type object_type: str - :param action: Action like create/update/delete. - :type action: str - :param object_key: Identifier of the entity being created/updated/deleted. - :type object_key: str - """ - - _attribute_map = { - 'object_type': {'key': 'objectType', 'type': 'str'}, - 'action': {'key': 'action', 'type': 'str'}, - 'object_key': {'key': 'objectKey', 'type': 'str'}, - } - - def __init__(self, **kwargs): - super(OperationResultLogItemContract, self).__init__(**kwargs) - self.object_type = kwargs.get('object_type', None) - self.action = kwargs.get('action', None) - self.object_key = kwargs.get('object_key', None) diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/operation_result_log_item_contract_py3.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/operation_result_log_item_contract_py3.py deleted file mode 100644 index e89f3615cae4..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/operation_result_log_item_contract_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 OperationResultLogItemContract(Model): - """Log of the entity being created, updated or deleted. - - :param object_type: The type of entity contract. - :type object_type: str - :param action: Action like create/update/delete. - :type action: str - :param object_key: Identifier of the entity being created/updated/deleted. - :type object_key: str - """ - - _attribute_map = { - 'object_type': {'key': 'objectType', 'type': 'str'}, - 'action': {'key': 'action', 'type': 'str'}, - 'object_key': {'key': 'objectKey', 'type': 'str'}, - } - - def __init__(self, *, object_type: str=None, action: str=None, object_key: str=None, **kwargs) -> None: - super(OperationResultLogItemContract, self).__init__(**kwargs) - self.object_type = object_type - self.action = action - self.object_key = object_key diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/operation_tag_resource_contract_properties.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/operation_tag_resource_contract_properties.py deleted file mode 100644 index c8d6e0a6d9f1..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/operation_tag_resource_contract_properties.py +++ /dev/null @@ -1,72 +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 OperationTagResourceContractProperties(Model): - """Operation Entity contract Properties. - - Variables are only populated by the server, and will be ignored when - sending a request. - - :param id: Identifier of the operation in form /operations/{operationId}. - :type id: str - :ivar name: Operation name. - :vartype name: str - :ivar api_name: Api Name. - :vartype api_name: str - :ivar api_revision: Api Revision. - :vartype api_revision: str - :ivar api_version: Api Version. - :vartype api_version: str - :ivar description: Operation Description. - :vartype description: str - :ivar method: A Valid HTTP Operation Method. Typical Http Methods like - GET, PUT, POST but not limited by only them. - :vartype method: str - :ivar url_template: Relative URL template identifying the target resource - for this operation. May include parameters. Example: - /customers/{cid}/orders/{oid}/?date={date} - :vartype url_template: str - """ - - _validation = { - 'name': {'readonly': True}, - 'api_name': {'readonly': True}, - 'api_revision': {'readonly': True}, - 'api_version': {'readonly': True}, - 'description': {'readonly': True}, - 'method': {'readonly': True}, - 'url_template': {'readonly': True}, - } - - _attribute_map = { - 'id': {'key': 'id', 'type': 'str'}, - 'name': {'key': 'name', 'type': 'str'}, - 'api_name': {'key': 'apiName', 'type': 'str'}, - 'api_revision': {'key': 'apiRevision', 'type': 'str'}, - 'api_version': {'key': 'apiVersion', 'type': 'str'}, - 'description': {'key': 'description', 'type': 'str'}, - 'method': {'key': 'method', 'type': 'str'}, - 'url_template': {'key': 'urlTemplate', 'type': 'str'}, - } - - def __init__(self, **kwargs): - super(OperationTagResourceContractProperties, self).__init__(**kwargs) - self.id = kwargs.get('id', None) - self.name = None - self.api_name = None - self.api_revision = None - self.api_version = None - self.description = None - self.method = None - self.url_template = None diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/operation_tag_resource_contract_properties_py3.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/operation_tag_resource_contract_properties_py3.py deleted file mode 100644 index 8ec9c0cb0f3b..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/operation_tag_resource_contract_properties_py3.py +++ /dev/null @@ -1,72 +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 OperationTagResourceContractProperties(Model): - """Operation Entity contract Properties. - - Variables are only populated by the server, and will be ignored when - sending a request. - - :param id: Identifier of the operation in form /operations/{operationId}. - :type id: str - :ivar name: Operation name. - :vartype name: str - :ivar api_name: Api Name. - :vartype api_name: str - :ivar api_revision: Api Revision. - :vartype api_revision: str - :ivar api_version: Api Version. - :vartype api_version: str - :ivar description: Operation Description. - :vartype description: str - :ivar method: A Valid HTTP Operation Method. Typical Http Methods like - GET, PUT, POST but not limited by only them. - :vartype method: str - :ivar url_template: Relative URL template identifying the target resource - for this operation. May include parameters. Example: - /customers/{cid}/orders/{oid}/?date={date} - :vartype url_template: str - """ - - _validation = { - 'name': {'readonly': True}, - 'api_name': {'readonly': True}, - 'api_revision': {'readonly': True}, - 'api_version': {'readonly': True}, - 'description': {'readonly': True}, - 'method': {'readonly': True}, - 'url_template': {'readonly': True}, - } - - _attribute_map = { - 'id': {'key': 'id', 'type': 'str'}, - 'name': {'key': 'name', 'type': 'str'}, - 'api_name': {'key': 'apiName', 'type': 'str'}, - 'api_revision': {'key': 'apiRevision', 'type': 'str'}, - 'api_version': {'key': 'apiVersion', 'type': 'str'}, - 'description': {'key': 'description', 'type': 'str'}, - 'method': {'key': 'method', 'type': 'str'}, - 'url_template': {'key': 'urlTemplate', 'type': 'str'}, - } - - def __init__(self, *, id: str=None, **kwargs) -> None: - super(OperationTagResourceContractProperties, self).__init__(**kwargs) - self.id = id - self.name = None - self.api_name = None - self.api_revision = None - self.api_version = None - self.description = None - self.method = None - self.url_template = None diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/operation_update_contract.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/operation_update_contract.py deleted file mode 100644 index b4b17f1dab95..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/operation_update_contract.py +++ /dev/null @@ -1,67 +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 OperationUpdateContract(Model): - """Api Operation Update Contract details. - - :param template_parameters: Collection of URL template parameters. - :type template_parameters: - list[~azure.mgmt.apimanagement.models.ParameterContract] - :param description: Description of the operation. May include HTML - formatting tags. - :type description: str - :param request: An entity containing request details. - :type request: ~azure.mgmt.apimanagement.models.RequestContract - :param responses: Array of Operation responses. - :type responses: list[~azure.mgmt.apimanagement.models.ResponseContract] - :param policies: Operation Policies - :type policies: str - :param display_name: Operation Name. - :type display_name: str - :param method: A Valid HTTP Operation Method. Typical Http Methods like - GET, PUT, POST but not limited by only them. - :type method: str - :param url_template: Relative URL template identifying the target resource - for this operation. May include parameters. Example: - /customers/{cid}/orders/{oid}/?date={date} - :type url_template: str - """ - - _validation = { - 'description': {'max_length': 1000}, - 'display_name': {'max_length': 300, 'min_length': 1}, - 'url_template': {'max_length': 1000, 'min_length': 1}, - } - - _attribute_map = { - 'template_parameters': {'key': 'properties.templateParameters', 'type': '[ParameterContract]'}, - 'description': {'key': 'properties.description', 'type': 'str'}, - 'request': {'key': 'properties.request', 'type': 'RequestContract'}, - 'responses': {'key': 'properties.responses', 'type': '[ResponseContract]'}, - 'policies': {'key': 'properties.policies', 'type': 'str'}, - 'display_name': {'key': 'properties.displayName', 'type': 'str'}, - 'method': {'key': 'properties.method', 'type': 'str'}, - 'url_template': {'key': 'properties.urlTemplate', 'type': 'str'}, - } - - def __init__(self, **kwargs): - super(OperationUpdateContract, self).__init__(**kwargs) - self.template_parameters = kwargs.get('template_parameters', None) - self.description = kwargs.get('description', None) - self.request = kwargs.get('request', None) - self.responses = kwargs.get('responses', None) - self.policies = kwargs.get('policies', None) - self.display_name = kwargs.get('display_name', None) - self.method = kwargs.get('method', None) - self.url_template = kwargs.get('url_template', None) diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/operation_update_contract_py3.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/operation_update_contract_py3.py deleted file mode 100644 index ad070cb9c980..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/operation_update_contract_py3.py +++ /dev/null @@ -1,67 +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 OperationUpdateContract(Model): - """Api Operation Update Contract details. - - :param template_parameters: Collection of URL template parameters. - :type template_parameters: - list[~azure.mgmt.apimanagement.models.ParameterContract] - :param description: Description of the operation. May include HTML - formatting tags. - :type description: str - :param request: An entity containing request details. - :type request: ~azure.mgmt.apimanagement.models.RequestContract - :param responses: Array of Operation responses. - :type responses: list[~azure.mgmt.apimanagement.models.ResponseContract] - :param policies: Operation Policies - :type policies: str - :param display_name: Operation Name. - :type display_name: str - :param method: A Valid HTTP Operation Method. Typical Http Methods like - GET, PUT, POST but not limited by only them. - :type method: str - :param url_template: Relative URL template identifying the target resource - for this operation. May include parameters. Example: - /customers/{cid}/orders/{oid}/?date={date} - :type url_template: str - """ - - _validation = { - 'description': {'max_length': 1000}, - 'display_name': {'max_length': 300, 'min_length': 1}, - 'url_template': {'max_length': 1000, 'min_length': 1}, - } - - _attribute_map = { - 'template_parameters': {'key': 'properties.templateParameters', 'type': '[ParameterContract]'}, - 'description': {'key': 'properties.description', 'type': 'str'}, - 'request': {'key': 'properties.request', 'type': 'RequestContract'}, - 'responses': {'key': 'properties.responses', 'type': '[ResponseContract]'}, - 'policies': {'key': 'properties.policies', 'type': 'str'}, - 'display_name': {'key': 'properties.displayName', 'type': 'str'}, - 'method': {'key': 'properties.method', 'type': 'str'}, - 'url_template': {'key': 'properties.urlTemplate', 'type': 'str'}, - } - - def __init__(self, *, template_parameters=None, description: str=None, request=None, responses=None, policies: str=None, display_name: str=None, method: str=None, url_template: str=None, **kwargs) -> None: - super(OperationUpdateContract, self).__init__(**kwargs) - self.template_parameters = template_parameters - self.description = description - self.request = request - self.responses = responses - self.policies = policies - self.display_name = display_name - self.method = method - self.url_template = url_template diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/parameter_contract.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/parameter_contract.py deleted file mode 100644 index 147a96efdf68..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/parameter_contract.py +++ /dev/null @@ -1,55 +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 ParameterContract(Model): - """Operation parameters details. - - All required parameters must be populated in order to send to Azure. - - :param name: Required. Parameter name. - :type name: str - :param description: Parameter description. - :type description: str - :param type: Required. Parameter type. - :type type: str - :param default_value: Default parameter value. - :type default_value: str - :param required: Specifies whether parameter is required or not. - :type required: bool - :param values: Parameter values. - :type values: list[str] - """ - - _validation = { - 'name': {'required': True}, - 'type': {'required': True}, - } - - _attribute_map = { - 'name': {'key': 'name', 'type': 'str'}, - 'description': {'key': 'description', 'type': 'str'}, - 'type': {'key': 'type', 'type': 'str'}, - 'default_value': {'key': 'defaultValue', 'type': 'str'}, - 'required': {'key': 'required', 'type': 'bool'}, - 'values': {'key': 'values', 'type': '[str]'}, - } - - def __init__(self, **kwargs): - super(ParameterContract, self).__init__(**kwargs) - self.name = kwargs.get('name', None) - self.description = kwargs.get('description', None) - self.type = kwargs.get('type', None) - self.default_value = kwargs.get('default_value', None) - self.required = kwargs.get('required', None) - self.values = kwargs.get('values', None) diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/parameter_contract_py3.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/parameter_contract_py3.py deleted file mode 100644 index 5f6ea4a0e91b..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/parameter_contract_py3.py +++ /dev/null @@ -1,55 +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 ParameterContract(Model): - """Operation parameters details. - - All required parameters must be populated in order to send to Azure. - - :param name: Required. Parameter name. - :type name: str - :param description: Parameter description. - :type description: str - :param type: Required. Parameter type. - :type type: str - :param default_value: Default parameter value. - :type default_value: str - :param required: Specifies whether parameter is required or not. - :type required: bool - :param values: Parameter values. - :type values: list[str] - """ - - _validation = { - 'name': {'required': True}, - 'type': {'required': True}, - } - - _attribute_map = { - 'name': {'key': 'name', 'type': 'str'}, - 'description': {'key': 'description', 'type': 'str'}, - 'type': {'key': 'type', 'type': 'str'}, - 'default_value': {'key': 'defaultValue', 'type': 'str'}, - 'required': {'key': 'required', 'type': 'bool'}, - 'values': {'key': 'values', 'type': '[str]'}, - } - - def __init__(self, *, name: str, type: str, description: str=None, default_value: str=None, required: bool=None, values=None, **kwargs) -> None: - super(ParameterContract, self).__init__(**kwargs) - self.name = name - self.description = description - self.type = type - self.default_value = default_value - self.required = required - self.values = values diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/pipeline_diagnostic_settings.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/pipeline_diagnostic_settings.py deleted file mode 100644 index 0089215e3802..000000000000 --- a/sdk/apimanagement/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/outgoing 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/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/pipeline_diagnostic_settings_py3.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/pipeline_diagnostic_settings_py3.py deleted file mode 100644 index ba30e8468d35..000000000000 --- a/sdk/apimanagement/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/outgoing 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/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/policy_collection.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/policy_collection.py deleted file mode 100644 index 4e983e14003b..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/policy_collection.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 PolicyCollection(Model): - """The response of the list policy operation. - - :param value: Policy Contract value. - :type value: list[~azure.mgmt.apimanagement.models.PolicyContract] - :param next_link: Next page link if any. - :type next_link: str - """ - - _attribute_map = { - 'value': {'key': 'value', 'type': '[PolicyContract]'}, - 'next_link': {'key': 'nextLink', 'type': 'str'}, - } - - def __init__(self, **kwargs): - super(PolicyCollection, self).__init__(**kwargs) - self.value = kwargs.get('value', None) - self.next_link = kwargs.get('next_link', None) diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/policy_collection_py3.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/policy_collection_py3.py deleted file mode 100644 index c48d44838266..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/policy_collection_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 PolicyCollection(Model): - """The response of the list policy operation. - - :param value: Policy Contract value. - :type value: list[~azure.mgmt.apimanagement.models.PolicyContract] - :param next_link: Next page link if any. - :type next_link: str - """ - - _attribute_map = { - 'value': {'key': 'value', 'type': '[PolicyContract]'}, - 'next_link': {'key': 'nextLink', 'type': 'str'}, - } - - def __init__(self, *, value=None, next_link: str=None, **kwargs) -> None: - super(PolicyCollection, self).__init__(**kwargs) - self.value = value - self.next_link = next_link diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/policy_contract.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/policy_contract.py deleted file mode 100644 index 313c69931b1c..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/policy_contract.py +++ /dev/null @@ -1,54 +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 .resource import Resource - - -class PolicyContract(Resource): - """Policy Contract details. - - Variables are only populated by the server, and will be ignored when - sending a request. - - All required parameters must be populated in order to send to Azure. - - :ivar id: Resource ID. - :vartype id: str - :ivar name: Resource name. - :vartype name: str - :ivar type: Resource type for API Management resource. - :vartype type: str - :param value: Required. Contents of the Policy as defined by the format. - :type value: str - :param format: Format of the policyContent. Possible values include: - 'xml', 'xml-link', 'rawxml', 'rawxml-link'. Default value: "xml" . - :type format: str or ~azure.mgmt.apimanagement.models.PolicyContentFormat - """ - - _validation = { - 'id': {'readonly': True}, - 'name': {'readonly': True}, - 'type': {'readonly': True}, - 'value': {'required': True}, - } - - _attribute_map = { - 'id': {'key': 'id', 'type': 'str'}, - 'name': {'key': 'name', 'type': 'str'}, - 'type': {'key': 'type', 'type': 'str'}, - 'value': {'key': 'properties.value', 'type': 'str'}, - 'format': {'key': 'properties.format', 'type': 'str'}, - } - - def __init__(self, **kwargs): - super(PolicyContract, self).__init__(**kwargs) - self.value = kwargs.get('value', None) - self.format = kwargs.get('format', "xml") diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/policy_contract_py3.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/policy_contract_py3.py deleted file mode 100644 index 34ff1900dac8..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/policy_contract_py3.py +++ /dev/null @@ -1,54 +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 .resource_py3 import Resource - - -class PolicyContract(Resource): - """Policy Contract details. - - Variables are only populated by the server, and will be ignored when - sending a request. - - All required parameters must be populated in order to send to Azure. - - :ivar id: Resource ID. - :vartype id: str - :ivar name: Resource name. - :vartype name: str - :ivar type: Resource type for API Management resource. - :vartype type: str - :param value: Required. Contents of the Policy as defined by the format. - :type value: str - :param format: Format of the policyContent. Possible values include: - 'xml', 'xml-link', 'rawxml', 'rawxml-link'. Default value: "xml" . - :type format: str or ~azure.mgmt.apimanagement.models.PolicyContentFormat - """ - - _validation = { - 'id': {'readonly': True}, - 'name': {'readonly': True}, - 'type': {'readonly': True}, - 'value': {'required': True}, - } - - _attribute_map = { - 'id': {'key': 'id', 'type': 'str'}, - 'name': {'key': 'name', 'type': 'str'}, - 'type': {'key': 'type', 'type': 'str'}, - 'value': {'key': 'properties.value', 'type': 'str'}, - 'format': {'key': 'properties.format', 'type': 'str'}, - } - - def __init__(self, *, value: str, format="xml", **kwargs) -> None: - super(PolicyContract, self).__init__(**kwargs) - self.value = value - self.format = format diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/policy_snippet_contract.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/policy_snippet_contract.py deleted file mode 100644 index e9317d9566c6..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/policy_snippet_contract.py +++ /dev/null @@ -1,50 +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 PolicySnippetContract(Model): - """Policy snippet. - - Variables are only populated by the server, and will be ignored when - sending a request. - - :ivar name: Snippet name. - :vartype name: str - :ivar content: Snippet content. - :vartype content: str - :ivar tool_tip: Snippet toolTip. - :vartype tool_tip: str - :ivar scope: Binary OR value of the Snippet scope. - :vartype scope: int - """ - - _validation = { - 'name': {'readonly': True}, - 'content': {'readonly': True}, - 'tool_tip': {'readonly': True}, - 'scope': {'readonly': True}, - } - - _attribute_map = { - 'name': {'key': 'name', 'type': 'str'}, - 'content': {'key': 'content', 'type': 'str'}, - 'tool_tip': {'key': 'toolTip', 'type': 'str'}, - 'scope': {'key': 'scope', 'type': 'int'}, - } - - def __init__(self, **kwargs): - super(PolicySnippetContract, self).__init__(**kwargs) - self.name = None - self.content = None - self.tool_tip = None - self.scope = None diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/policy_snippet_contract_py3.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/policy_snippet_contract_py3.py deleted file mode 100644 index 8bc7494b939f..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/policy_snippet_contract_py3.py +++ /dev/null @@ -1,50 +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 PolicySnippetContract(Model): - """Policy snippet. - - Variables are only populated by the server, and will be ignored when - sending a request. - - :ivar name: Snippet name. - :vartype name: str - :ivar content: Snippet content. - :vartype content: str - :ivar tool_tip: Snippet toolTip. - :vartype tool_tip: str - :ivar scope: Binary OR value of the Snippet scope. - :vartype scope: int - """ - - _validation = { - 'name': {'readonly': True}, - 'content': {'readonly': True}, - 'tool_tip': {'readonly': True}, - 'scope': {'readonly': True}, - } - - _attribute_map = { - 'name': {'key': 'name', 'type': 'str'}, - 'content': {'key': 'content', 'type': 'str'}, - 'tool_tip': {'key': 'toolTip', 'type': 'str'}, - 'scope': {'key': 'scope', 'type': 'int'}, - } - - def __init__(self, **kwargs) -> None: - super(PolicySnippetContract, self).__init__(**kwargs) - self.name = None - self.content = None - self.tool_tip = None - self.scope = None diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/policy_snippets_collection.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/policy_snippets_collection.py deleted file mode 100644 index 84129684df80..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/policy_snippets_collection.py +++ /dev/null @@ -1,28 +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 PolicySnippetsCollection(Model): - """The response of the list policy snippets operation. - - :param value: Policy snippet value. - :type value: list[~azure.mgmt.apimanagement.models.PolicySnippetContract] - """ - - _attribute_map = { - 'value': {'key': 'value', 'type': '[PolicySnippetContract]'}, - } - - def __init__(self, **kwargs): - super(PolicySnippetsCollection, self).__init__(**kwargs) - self.value = kwargs.get('value', None) diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/policy_snippets_collection_py3.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/policy_snippets_collection_py3.py deleted file mode 100644 index 0744acea8038..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/policy_snippets_collection_py3.py +++ /dev/null @@ -1,28 +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 PolicySnippetsCollection(Model): - """The response of the list policy snippets operation. - - :param value: Policy snippet value. - :type value: list[~azure.mgmt.apimanagement.models.PolicySnippetContract] - """ - - _attribute_map = { - 'value': {'key': 'value', 'type': '[PolicySnippetContract]'}, - } - - def __init__(self, *, value=None, **kwargs) -> None: - super(PolicySnippetsCollection, self).__init__(**kwargs) - self.value = value diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/portal_delegation_settings.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/portal_delegation_settings.py deleted file mode 100644 index 12afb1d73450..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/portal_delegation_settings.py +++ /dev/null @@ -1,61 +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 .resource import Resource - - -class PortalDelegationSettings(Resource): - """Delegation settings for a developer portal. - - Variables are only populated by the server, and will be ignored when - sending a request. - - :ivar id: Resource ID. - :vartype id: str - :ivar name: Resource name. - :vartype name: str - :ivar type: Resource type for API Management resource. - :vartype type: str - :param url: A delegation Url. - :type url: str - :param validation_key: A base64-encoded validation key to validate, that a - request is coming from Azure API Management. - :type validation_key: str - :param subscriptions: Subscriptions delegation settings. - :type subscriptions: - ~azure.mgmt.apimanagement.models.SubscriptionsDelegationSettingsProperties - :param user_registration: User registration delegation settings. - :type user_registration: - ~azure.mgmt.apimanagement.models.RegistrationDelegationSettingsProperties - """ - - _validation = { - 'id': {'readonly': True}, - 'name': {'readonly': True}, - 'type': {'readonly': True}, - } - - _attribute_map = { - 'id': {'key': 'id', 'type': 'str'}, - 'name': {'key': 'name', 'type': 'str'}, - 'type': {'key': 'type', 'type': 'str'}, - 'url': {'key': 'properties.url', 'type': 'str'}, - 'validation_key': {'key': 'properties.validationKey', 'type': 'str'}, - 'subscriptions': {'key': 'properties.subscriptions', 'type': 'SubscriptionsDelegationSettingsProperties'}, - 'user_registration': {'key': 'properties.userRegistration', 'type': 'RegistrationDelegationSettingsProperties'}, - } - - def __init__(self, **kwargs): - super(PortalDelegationSettings, self).__init__(**kwargs) - self.url = kwargs.get('url', None) - self.validation_key = kwargs.get('validation_key', None) - self.subscriptions = kwargs.get('subscriptions', None) - self.user_registration = kwargs.get('user_registration', None) diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/portal_delegation_settings_py3.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/portal_delegation_settings_py3.py deleted file mode 100644 index 3aa96ae6ff5a..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/portal_delegation_settings_py3.py +++ /dev/null @@ -1,61 +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 .resource_py3 import Resource - - -class PortalDelegationSettings(Resource): - """Delegation settings for a developer portal. - - Variables are only populated by the server, and will be ignored when - sending a request. - - :ivar id: Resource ID. - :vartype id: str - :ivar name: Resource name. - :vartype name: str - :ivar type: Resource type for API Management resource. - :vartype type: str - :param url: A delegation Url. - :type url: str - :param validation_key: A base64-encoded validation key to validate, that a - request is coming from Azure API Management. - :type validation_key: str - :param subscriptions: Subscriptions delegation settings. - :type subscriptions: - ~azure.mgmt.apimanagement.models.SubscriptionsDelegationSettingsProperties - :param user_registration: User registration delegation settings. - :type user_registration: - ~azure.mgmt.apimanagement.models.RegistrationDelegationSettingsProperties - """ - - _validation = { - 'id': {'readonly': True}, - 'name': {'readonly': True}, - 'type': {'readonly': True}, - } - - _attribute_map = { - 'id': {'key': 'id', 'type': 'str'}, - 'name': {'key': 'name', 'type': 'str'}, - 'type': {'key': 'type', 'type': 'str'}, - 'url': {'key': 'properties.url', 'type': 'str'}, - 'validation_key': {'key': 'properties.validationKey', 'type': 'str'}, - 'subscriptions': {'key': 'properties.subscriptions', 'type': 'SubscriptionsDelegationSettingsProperties'}, - 'user_registration': {'key': 'properties.userRegistration', 'type': 'RegistrationDelegationSettingsProperties'}, - } - - def __init__(self, *, url: str=None, validation_key: str=None, subscriptions=None, user_registration=None, **kwargs) -> None: - super(PortalDelegationSettings, self).__init__(**kwargs) - self.url = url - self.validation_key = validation_key - self.subscriptions = subscriptions - self.user_registration = user_registration diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/portal_signin_settings.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/portal_signin_settings.py deleted file mode 100644 index b8f376395a0e..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/portal_signin_settings.py +++ /dev/null @@ -1,46 +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 .resource import Resource - - -class PortalSigninSettings(Resource): - """Sign-In settings for the Developer Portal. - - Variables are only populated by the server, and will be ignored when - sending a request. - - :ivar id: Resource ID. - :vartype id: str - :ivar name: Resource name. - :vartype name: str - :ivar type: Resource type for API Management resource. - :vartype type: str - :param enabled: Redirect Anonymous users to the Sign-In page. - :type enabled: bool - """ - - _validation = { - 'id': {'readonly': True}, - 'name': {'readonly': True}, - 'type': {'readonly': True}, - } - - _attribute_map = { - 'id': {'key': 'id', 'type': 'str'}, - 'name': {'key': 'name', 'type': 'str'}, - 'type': {'key': 'type', 'type': 'str'}, - 'enabled': {'key': 'properties.enabled', 'type': 'bool'}, - } - - def __init__(self, **kwargs): - super(PortalSigninSettings, self).__init__(**kwargs) - self.enabled = kwargs.get('enabled', None) diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/portal_signin_settings_py3.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/portal_signin_settings_py3.py deleted file mode 100644 index 5f7a08a5a7f9..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/portal_signin_settings_py3.py +++ /dev/null @@ -1,46 +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 .resource_py3 import Resource - - -class PortalSigninSettings(Resource): - """Sign-In settings for the Developer Portal. - - Variables are only populated by the server, and will be ignored when - sending a request. - - :ivar id: Resource ID. - :vartype id: str - :ivar name: Resource name. - :vartype name: str - :ivar type: Resource type for API Management resource. - :vartype type: str - :param enabled: Redirect Anonymous users to the Sign-In page. - :type enabled: bool - """ - - _validation = { - 'id': {'readonly': True}, - 'name': {'readonly': True}, - 'type': {'readonly': True}, - } - - _attribute_map = { - 'id': {'key': 'id', 'type': 'str'}, - 'name': {'key': 'name', 'type': 'str'}, - 'type': {'key': 'type', 'type': 'str'}, - 'enabled': {'key': 'properties.enabled', 'type': 'bool'}, - } - - def __init__(self, *, enabled: bool=None, **kwargs) -> None: - super(PortalSigninSettings, self).__init__(**kwargs) - self.enabled = enabled diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/portal_signup_settings.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/portal_signup_settings.py deleted file mode 100644 index ed58574923bd..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/portal_signup_settings.py +++ /dev/null @@ -1,51 +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 .resource import Resource - - -class PortalSignupSettings(Resource): - """Sign-Up settings for a developer portal. - - Variables are only populated by the server, and will be ignored when - sending a request. - - :ivar id: Resource ID. - :vartype id: str - :ivar name: Resource name. - :vartype name: str - :ivar type: Resource type for API Management resource. - :vartype type: str - :param enabled: Allow users to sign up on a developer portal. - :type enabled: bool - :param terms_of_service: Terms of service contract properties. - :type terms_of_service: - ~azure.mgmt.apimanagement.models.TermsOfServiceProperties - """ - - _validation = { - 'id': {'readonly': True}, - 'name': {'readonly': True}, - 'type': {'readonly': True}, - } - - _attribute_map = { - 'id': {'key': 'id', 'type': 'str'}, - 'name': {'key': 'name', 'type': 'str'}, - 'type': {'key': 'type', 'type': 'str'}, - 'enabled': {'key': 'properties.enabled', 'type': 'bool'}, - 'terms_of_service': {'key': 'properties.termsOfService', 'type': 'TermsOfServiceProperties'}, - } - - def __init__(self, **kwargs): - super(PortalSignupSettings, self).__init__(**kwargs) - self.enabled = kwargs.get('enabled', None) - self.terms_of_service = kwargs.get('terms_of_service', None) diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/portal_signup_settings_py3.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/portal_signup_settings_py3.py deleted file mode 100644 index 46eb461e53ff..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/portal_signup_settings_py3.py +++ /dev/null @@ -1,51 +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 .resource_py3 import Resource - - -class PortalSignupSettings(Resource): - """Sign-Up settings for a developer portal. - - Variables are only populated by the server, and will be ignored when - sending a request. - - :ivar id: Resource ID. - :vartype id: str - :ivar name: Resource name. - :vartype name: str - :ivar type: Resource type for API Management resource. - :vartype type: str - :param enabled: Allow users to sign up on a developer portal. - :type enabled: bool - :param terms_of_service: Terms of service contract properties. - :type terms_of_service: - ~azure.mgmt.apimanagement.models.TermsOfServiceProperties - """ - - _validation = { - 'id': {'readonly': True}, - 'name': {'readonly': True}, - 'type': {'readonly': True}, - } - - _attribute_map = { - 'id': {'key': 'id', 'type': 'str'}, - 'name': {'key': 'name', 'type': 'str'}, - 'type': {'key': 'type', 'type': 'str'}, - 'enabled': {'key': 'properties.enabled', 'type': 'bool'}, - 'terms_of_service': {'key': 'properties.termsOfService', 'type': 'TermsOfServiceProperties'}, - } - - def __init__(self, *, enabled: bool=None, terms_of_service=None, **kwargs) -> None: - super(PortalSignupSettings, self).__init__(**kwargs) - self.enabled = enabled - self.terms_of_service = terms_of_service diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/product_contract.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/product_contract.py deleted file mode 100644 index c25ec9bde595..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/product_contract.py +++ /dev/null @@ -1,93 +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 .resource import Resource - - -class ProductContract(Resource): - """Product details. - - Variables are only populated by the server, and will be ignored when - sending a request. - - All required parameters must be populated in order to send to Azure. - - :ivar id: Resource ID. - :vartype id: str - :ivar name: Resource name. - :vartype name: str - :ivar type: Resource type for API Management resource. - :vartype type: str - :param description: Product description. May include HTML formatting tags. - :type description: str - :param terms: Product terms of use. Developers trying to subscribe to the - product will be presented and required to accept these terms before they - can complete the subscription process. - :type terms: str - :param subscription_required: Whether a product subscription is required - for accessing APIs included in this product. If true, the product is - referred to as "protected" and a valid subscription key is required for a - request to an API included in the product to succeed. If false, the - product is referred to as "open" and requests to an API included in the - product can be made without a subscription key. If property is omitted - when creating a new product it's value is assumed to be true. - :type subscription_required: bool - :param approval_required: whether subscription approval is required. If - false, new subscriptions will be approved automatically enabling - developers to call the product’s APIs immediately after subscribing. If - true, administrators must manually approve the subscription before the - developer can any of the product’s APIs. Can be present only if - 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 - unlimited per user subscriptions. Can be present only if - subscriptionRequired property is present and has a value of false. - :type subscriptions_limit: int - :param state: whether product is published or not. Published products are - discoverable by users of developer portal. Non published products are - visible only to administrators. Default state of Product is notPublished. - Possible values include: 'notPublished', 'published' - :type state: str or ~azure.mgmt.apimanagement.models.ProductState - :param display_name: Required. Product name. - :type display_name: str - """ - - _validation = { - 'id': {'readonly': True}, - 'name': {'readonly': True}, - 'type': {'readonly': True}, - 'description': {'max_length': 1000, 'min_length': 1}, - 'display_name': {'required': True, 'max_length': 300, 'min_length': 1}, - } - - _attribute_map = { - 'id': {'key': 'id', 'type': 'str'}, - 'name': {'key': 'name', 'type': 'str'}, - 'type': {'key': 'type', 'type': 'str'}, - 'description': {'key': 'properties.description', 'type': 'str'}, - 'terms': {'key': 'properties.terms', 'type': 'str'}, - 'subscription_required': {'key': 'properties.subscriptionRequired', 'type': 'bool'}, - 'approval_required': {'key': 'properties.approvalRequired', 'type': 'bool'}, - 'subscriptions_limit': {'key': 'properties.subscriptionsLimit', 'type': 'int'}, - 'state': {'key': 'properties.state', 'type': 'ProductState'}, - 'display_name': {'key': 'properties.displayName', 'type': 'str'}, - } - - def __init__(self, **kwargs): - super(ProductContract, self).__init__(**kwargs) - self.description = kwargs.get('description', None) - self.terms = kwargs.get('terms', None) - self.subscription_required = kwargs.get('subscription_required', None) - self.approval_required = kwargs.get('approval_required', None) - self.subscriptions_limit = kwargs.get('subscriptions_limit', None) - self.state = kwargs.get('state', None) - self.display_name = kwargs.get('display_name', None) diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/product_contract_paged.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/product_contract_paged.py deleted file mode 100644 index ed575a6564cb..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/product_contract_paged.py +++ /dev/null @@ -1,27 +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.paging import Paged - - -class ProductContractPaged(Paged): - """ - A paging container for iterating over a list of :class:`ProductContract ` object - """ - - _attribute_map = { - 'next_link': {'key': 'nextLink', 'type': 'str'}, - 'current_page': {'key': 'value', 'type': '[ProductContract]'} - } - - def __init__(self, *args, **kwargs): - - super(ProductContractPaged, self).__init__(*args, **kwargs) diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/product_contract_py3.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/product_contract_py3.py deleted file mode 100644 index 2183cdb4de8a..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/product_contract_py3.py +++ /dev/null @@ -1,93 +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 .resource_py3 import Resource - - -class ProductContract(Resource): - """Product details. - - Variables are only populated by the server, and will be ignored when - sending a request. - - All required parameters must be populated in order to send to Azure. - - :ivar id: Resource ID. - :vartype id: str - :ivar name: Resource name. - :vartype name: str - :ivar type: Resource type for API Management resource. - :vartype type: str - :param description: Product description. May include HTML formatting tags. - :type description: str - :param terms: Product terms of use. Developers trying to subscribe to the - product will be presented and required to accept these terms before they - can complete the subscription process. - :type terms: str - :param subscription_required: Whether a product subscription is required - for accessing APIs included in this product. If true, the product is - referred to as "protected" and a valid subscription key is required for a - request to an API included in the product to succeed. If false, the - product is referred to as "open" and requests to an API included in the - product can be made without a subscription key. If property is omitted - when creating a new product it's value is assumed to be true. - :type subscription_required: bool - :param approval_required: whether subscription approval is required. If - false, new subscriptions will be approved automatically enabling - developers to call the product’s APIs immediately after subscribing. If - true, administrators must manually approve the subscription before the - developer can any of the product’s APIs. Can be present only if - 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 - unlimited per user subscriptions. Can be present only if - subscriptionRequired property is present and has a value of false. - :type subscriptions_limit: int - :param state: whether product is published or not. Published products are - discoverable by users of developer portal. Non published products are - visible only to administrators. Default state of Product is notPublished. - Possible values include: 'notPublished', 'published' - :type state: str or ~azure.mgmt.apimanagement.models.ProductState - :param display_name: Required. Product name. - :type display_name: str - """ - - _validation = { - 'id': {'readonly': True}, - 'name': {'readonly': True}, - 'type': {'readonly': True}, - 'description': {'max_length': 1000, 'min_length': 1}, - 'display_name': {'required': True, 'max_length': 300, 'min_length': 1}, - } - - _attribute_map = { - 'id': {'key': 'id', 'type': 'str'}, - 'name': {'key': 'name', 'type': 'str'}, - 'type': {'key': 'type', 'type': 'str'}, - 'description': {'key': 'properties.description', 'type': 'str'}, - 'terms': {'key': 'properties.terms', 'type': 'str'}, - 'subscription_required': {'key': 'properties.subscriptionRequired', 'type': 'bool'}, - 'approval_required': {'key': 'properties.approvalRequired', 'type': 'bool'}, - 'subscriptions_limit': {'key': 'properties.subscriptionsLimit', 'type': 'int'}, - 'state': {'key': 'properties.state', 'type': 'ProductState'}, - 'display_name': {'key': 'properties.displayName', 'type': 'str'}, - } - - def __init__(self, *, display_name: str, description: str=None, terms: str=None, subscription_required: bool=None, approval_required: bool=None, subscriptions_limit: int=None, state=None, **kwargs) -> None: - super(ProductContract, self).__init__(**kwargs) - self.description = description - self.terms = terms - self.subscription_required = subscription_required - self.approval_required = approval_required - self.subscriptions_limit = subscriptions_limit - self.state = state - self.display_name = display_name diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/product_entity_base_parameters.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/product_entity_base_parameters.py deleted file mode 100644 index 4e1f97bc6694..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/product_entity_base_parameters.py +++ /dev/null @@ -1,71 +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 ProductEntityBaseParameters(Model): - """Product Entity Base Parameters. - - :param description: Product description. May include HTML formatting tags. - :type description: str - :param terms: Product terms of use. Developers trying to subscribe to the - product will be presented and required to accept these terms before they - can complete the subscription process. - :type terms: str - :param subscription_required: Whether a product subscription is required - for accessing APIs included in this product. If true, the product is - referred to as "protected" and a valid subscription key is required for a - request to an API included in the product to succeed. If false, the - product is referred to as "open" and requests to an API included in the - product can be made without a subscription key. If property is omitted - when creating a new product it's value is assumed to be true. - :type subscription_required: bool - :param approval_required: whether subscription approval is required. If - false, new subscriptions will be approved automatically enabling - developers to call the product’s APIs immediately after subscribing. If - true, administrators must manually approve the subscription before the - developer can any of the product’s APIs. Can be present only if - 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 - unlimited per user subscriptions. Can be present only if - subscriptionRequired property is present and has a value of false. - :type subscriptions_limit: int - :param state: whether product is published or not. Published products are - discoverable by users of developer portal. Non published products are - visible only to administrators. Default state of Product is notPublished. - Possible values include: 'notPublished', 'published' - :type state: str or ~azure.mgmt.apimanagement.models.ProductState - """ - - _validation = { - 'description': {'max_length': 1000, 'min_length': 1}, - } - - _attribute_map = { - 'description': {'key': 'description', 'type': 'str'}, - 'terms': {'key': 'terms', 'type': 'str'}, - 'subscription_required': {'key': 'subscriptionRequired', 'type': 'bool'}, - 'approval_required': {'key': 'approvalRequired', 'type': 'bool'}, - 'subscriptions_limit': {'key': 'subscriptionsLimit', 'type': 'int'}, - 'state': {'key': 'state', 'type': 'ProductState'}, - } - - def __init__(self, **kwargs): - super(ProductEntityBaseParameters, self).__init__(**kwargs) - self.description = kwargs.get('description', None) - self.terms = kwargs.get('terms', None) - self.subscription_required = kwargs.get('subscription_required', None) - self.approval_required = kwargs.get('approval_required', None) - self.subscriptions_limit = kwargs.get('subscriptions_limit', None) - self.state = kwargs.get('state', None) diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/product_entity_base_parameters_py3.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/product_entity_base_parameters_py3.py deleted file mode 100644 index 5574461683ea..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/product_entity_base_parameters_py3.py +++ /dev/null @@ -1,71 +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 ProductEntityBaseParameters(Model): - """Product Entity Base Parameters. - - :param description: Product description. May include HTML formatting tags. - :type description: str - :param terms: Product terms of use. Developers trying to subscribe to the - product will be presented and required to accept these terms before they - can complete the subscription process. - :type terms: str - :param subscription_required: Whether a product subscription is required - for accessing APIs included in this product. If true, the product is - referred to as "protected" and a valid subscription key is required for a - request to an API included in the product to succeed. If false, the - product is referred to as "open" and requests to an API included in the - product can be made without a subscription key. If property is omitted - when creating a new product it's value is assumed to be true. - :type subscription_required: bool - :param approval_required: whether subscription approval is required. If - false, new subscriptions will be approved automatically enabling - developers to call the product’s APIs immediately after subscribing. If - true, administrators must manually approve the subscription before the - developer can any of the product’s APIs. Can be present only if - 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 - unlimited per user subscriptions. Can be present only if - subscriptionRequired property is present and has a value of false. - :type subscriptions_limit: int - :param state: whether product is published or not. Published products are - discoverable by users of developer portal. Non published products are - visible only to administrators. Default state of Product is notPublished. - Possible values include: 'notPublished', 'published' - :type state: str or ~azure.mgmt.apimanagement.models.ProductState - """ - - _validation = { - 'description': {'max_length': 1000, 'min_length': 1}, - } - - _attribute_map = { - 'description': {'key': 'description', 'type': 'str'}, - 'terms': {'key': 'terms', 'type': 'str'}, - 'subscription_required': {'key': 'subscriptionRequired', 'type': 'bool'}, - 'approval_required': {'key': 'approvalRequired', 'type': 'bool'}, - 'subscriptions_limit': {'key': 'subscriptionsLimit', 'type': 'int'}, - 'state': {'key': 'state', 'type': 'ProductState'}, - } - - def __init__(self, *, description: str=None, terms: str=None, subscription_required: bool=None, approval_required: bool=None, subscriptions_limit: int=None, state=None, **kwargs) -> None: - super(ProductEntityBaseParameters, self).__init__(**kwargs) - self.description = description - self.terms = terms - self.subscription_required = subscription_required - self.approval_required = approval_required - self.subscriptions_limit = subscriptions_limit - self.state = state diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/product_tag_resource_contract_properties.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/product_tag_resource_contract_properties.py deleted file mode 100644 index 0b32a2c9df40..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/product_tag_resource_contract_properties.py +++ /dev/null @@ -1,76 +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 .product_entity_base_parameters import ProductEntityBaseParameters - - -class ProductTagResourceContractProperties(ProductEntityBaseParameters): - """Product profile. - - All required parameters must be populated in order to send to Azure. - - :param description: Product description. May include HTML formatting tags. - :type description: str - :param terms: Product terms of use. Developers trying to subscribe to the - product will be presented and required to accept these terms before they - can complete the subscription process. - :type terms: str - :param subscription_required: Whether a product subscription is required - for accessing APIs included in this product. If true, the product is - referred to as "protected" and a valid subscription key is required for a - request to an API included in the product to succeed. If false, the - product is referred to as "open" and requests to an API included in the - product can be made without a subscription key. If property is omitted - when creating a new product it's value is assumed to be true. - :type subscription_required: bool - :param approval_required: whether subscription approval is required. If - false, new subscriptions will be approved automatically enabling - developers to call the product’s APIs immediately after subscribing. If - true, administrators must manually approve the subscription before the - developer can any of the product’s APIs. Can be present only if - 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 - unlimited per user subscriptions. Can be present only if - subscriptionRequired property is present and has a value of false. - :type subscriptions_limit: int - :param state: whether product is published or not. Published products are - discoverable by users of developer portal. Non published products are - visible only to administrators. Default state of Product is notPublished. - Possible values include: 'notPublished', 'published' - :type state: str or ~azure.mgmt.apimanagement.models.ProductState - :param id: Identifier of the product in the form of /products/{productId} - :type id: str - :param name: Required. Product name. - :type name: str - """ - - _validation = { - 'description': {'max_length': 1000, 'min_length': 1}, - 'name': {'required': True, 'max_length': 300, 'min_length': 1}, - } - - _attribute_map = { - 'description': {'key': 'description', 'type': 'str'}, - 'terms': {'key': 'terms', 'type': 'str'}, - 'subscription_required': {'key': 'subscriptionRequired', 'type': 'bool'}, - 'approval_required': {'key': 'approvalRequired', 'type': 'bool'}, - 'subscriptions_limit': {'key': 'subscriptionsLimit', 'type': 'int'}, - 'state': {'key': 'state', 'type': 'ProductState'}, - 'id': {'key': 'id', 'type': 'str'}, - 'name': {'key': 'name', 'type': 'str'}, - } - - def __init__(self, **kwargs): - super(ProductTagResourceContractProperties, self).__init__(**kwargs) - self.id = kwargs.get('id', None) - self.name = kwargs.get('name', None) diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/product_tag_resource_contract_properties_py3.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/product_tag_resource_contract_properties_py3.py deleted file mode 100644 index ecb7fef20809..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/product_tag_resource_contract_properties_py3.py +++ /dev/null @@ -1,76 +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 .product_entity_base_parameters_py3 import ProductEntityBaseParameters - - -class ProductTagResourceContractProperties(ProductEntityBaseParameters): - """Product profile. - - All required parameters must be populated in order to send to Azure. - - :param description: Product description. May include HTML formatting tags. - :type description: str - :param terms: Product terms of use. Developers trying to subscribe to the - product will be presented and required to accept these terms before they - can complete the subscription process. - :type terms: str - :param subscription_required: Whether a product subscription is required - for accessing APIs included in this product. If true, the product is - referred to as "protected" and a valid subscription key is required for a - request to an API included in the product to succeed. If false, the - product is referred to as "open" and requests to an API included in the - product can be made without a subscription key. If property is omitted - when creating a new product it's value is assumed to be true. - :type subscription_required: bool - :param approval_required: whether subscription approval is required. If - false, new subscriptions will be approved automatically enabling - developers to call the product’s APIs immediately after subscribing. If - true, administrators must manually approve the subscription before the - developer can any of the product’s APIs. Can be present only if - 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 - unlimited per user subscriptions. Can be present only if - subscriptionRequired property is present and has a value of false. - :type subscriptions_limit: int - :param state: whether product is published or not. Published products are - discoverable by users of developer portal. Non published products are - visible only to administrators. Default state of Product is notPublished. - Possible values include: 'notPublished', 'published' - :type state: str or ~azure.mgmt.apimanagement.models.ProductState - :param id: Identifier of the product in the form of /products/{productId} - :type id: str - :param name: Required. Product name. - :type name: str - """ - - _validation = { - 'description': {'max_length': 1000, 'min_length': 1}, - 'name': {'required': True, 'max_length': 300, 'min_length': 1}, - } - - _attribute_map = { - 'description': {'key': 'description', 'type': 'str'}, - 'terms': {'key': 'terms', 'type': 'str'}, - 'subscription_required': {'key': 'subscriptionRequired', 'type': 'bool'}, - 'approval_required': {'key': 'approvalRequired', 'type': 'bool'}, - 'subscriptions_limit': {'key': 'subscriptionsLimit', 'type': 'int'}, - 'state': {'key': 'state', 'type': 'ProductState'}, - 'id': {'key': 'id', 'type': 'str'}, - 'name': {'key': 'name', 'type': 'str'}, - } - - def __init__(self, *, name: str, description: str=None, terms: str=None, subscription_required: bool=None, approval_required: bool=None, subscriptions_limit: int=None, state=None, id: str=None, **kwargs) -> None: - super(ProductTagResourceContractProperties, self).__init__(description=description, terms=terms, subscription_required=subscription_required, approval_required=approval_required, subscriptions_limit=subscriptions_limit, state=state, **kwargs) - self.id = id - self.name = name diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/product_update_parameters.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/product_update_parameters.py deleted file mode 100644 index ce8e0d73d728..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/product_update_parameters.py +++ /dev/null @@ -1,76 +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 ProductUpdateParameters(Model): - """Product Update parameters. - - :param description: Product description. May include HTML formatting tags. - :type description: str - :param terms: Product terms of use. Developers trying to subscribe to the - product will be presented and required to accept these terms before they - can complete the subscription process. - :type terms: str - :param subscription_required: Whether a product subscription is required - for accessing APIs included in this product. If true, the product is - referred to as "protected" and a valid subscription key is required for a - request to an API included in the product to succeed. If false, the - product is referred to as "open" and requests to an API included in the - product can be made without a subscription key. If property is omitted - when creating a new product it's value is assumed to be true. - :type subscription_required: bool - :param approval_required: whether subscription approval is required. If - false, new subscriptions will be approved automatically enabling - developers to call the product’s APIs immediately after subscribing. If - true, administrators must manually approve the subscription before the - developer can any of the product’s APIs. Can be present only if - 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 - unlimited per user subscriptions. Can be present only if - subscriptionRequired property is present and has a value of false. - :type subscriptions_limit: int - :param state: whether product is published or not. Published products are - discoverable by users of developer portal. Non published products are - visible only to administrators. Default state of Product is notPublished. - Possible values include: 'notPublished', 'published' - :type state: str or ~azure.mgmt.apimanagement.models.ProductState - :param display_name: Product name. - :type display_name: str - """ - - _validation = { - 'description': {'max_length': 1000, 'min_length': 1}, - 'display_name': {'max_length': 300, 'min_length': 1}, - } - - _attribute_map = { - 'description': {'key': 'properties.description', 'type': 'str'}, - 'terms': {'key': 'properties.terms', 'type': 'str'}, - 'subscription_required': {'key': 'properties.subscriptionRequired', 'type': 'bool'}, - 'approval_required': {'key': 'properties.approvalRequired', 'type': 'bool'}, - 'subscriptions_limit': {'key': 'properties.subscriptionsLimit', 'type': 'int'}, - 'state': {'key': 'properties.state', 'type': 'ProductState'}, - 'display_name': {'key': 'properties.displayName', 'type': 'str'}, - } - - def __init__(self, **kwargs): - super(ProductUpdateParameters, self).__init__(**kwargs) - self.description = kwargs.get('description', None) - self.terms = kwargs.get('terms', None) - self.subscription_required = kwargs.get('subscription_required', None) - self.approval_required = kwargs.get('approval_required', None) - self.subscriptions_limit = kwargs.get('subscriptions_limit', None) - self.state = kwargs.get('state', None) - self.display_name = kwargs.get('display_name', None) diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/product_update_parameters_py3.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/product_update_parameters_py3.py deleted file mode 100644 index 9154962e697d..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/product_update_parameters_py3.py +++ /dev/null @@ -1,76 +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 ProductUpdateParameters(Model): - """Product Update parameters. - - :param description: Product description. May include HTML formatting tags. - :type description: str - :param terms: Product terms of use. Developers trying to subscribe to the - product will be presented and required to accept these terms before they - can complete the subscription process. - :type terms: str - :param subscription_required: Whether a product subscription is required - for accessing APIs included in this product. If true, the product is - referred to as "protected" and a valid subscription key is required for a - request to an API included in the product to succeed. If false, the - product is referred to as "open" and requests to an API included in the - product can be made without a subscription key. If property is omitted - when creating a new product it's value is assumed to be true. - :type subscription_required: bool - :param approval_required: whether subscription approval is required. If - false, new subscriptions will be approved automatically enabling - developers to call the product’s APIs immediately after subscribing. If - true, administrators must manually approve the subscription before the - developer can any of the product’s APIs. Can be present only if - 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 - unlimited per user subscriptions. Can be present only if - subscriptionRequired property is present and has a value of false. - :type subscriptions_limit: int - :param state: whether product is published or not. Published products are - discoverable by users of developer portal. Non published products are - visible only to administrators. Default state of Product is notPublished. - Possible values include: 'notPublished', 'published' - :type state: str or ~azure.mgmt.apimanagement.models.ProductState - :param display_name: Product name. - :type display_name: str - """ - - _validation = { - 'description': {'max_length': 1000, 'min_length': 1}, - 'display_name': {'max_length': 300, 'min_length': 1}, - } - - _attribute_map = { - 'description': {'key': 'properties.description', 'type': 'str'}, - 'terms': {'key': 'properties.terms', 'type': 'str'}, - 'subscription_required': {'key': 'properties.subscriptionRequired', 'type': 'bool'}, - 'approval_required': {'key': 'properties.approvalRequired', 'type': 'bool'}, - 'subscriptions_limit': {'key': 'properties.subscriptionsLimit', 'type': 'int'}, - 'state': {'key': 'properties.state', 'type': 'ProductState'}, - 'display_name': {'key': 'properties.displayName', 'type': 'str'}, - } - - def __init__(self, *, description: str=None, terms: str=None, subscription_required: bool=None, approval_required: bool=None, subscriptions_limit: int=None, state=None, display_name: str=None, **kwargs) -> None: - super(ProductUpdateParameters, self).__init__(**kwargs) - self.description = description - self.terms = terms - self.subscription_required = subscription_required - self.approval_required = approval_required - self.subscriptions_limit = subscriptions_limit - self.state = state - self.display_name = display_name diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/property_contract.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/property_contract.py deleted file mode 100644 index aed61008da89..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/property_contract.py +++ /dev/null @@ -1,67 +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 .resource import Resource - - -class PropertyContract(Resource): - """Property details. - - Variables are only populated by the server, and will be ignored when - sending a request. - - All required parameters must be populated in order to send to Azure. - - :ivar id: Resource ID. - :vartype id: str - :ivar name: Resource name. - :vartype name: str - :ivar type: Resource type for API Management resource. - :vartype type: str - :param tags: Optional tags that when provided can be used to filter the - property list. - :type tags: list[str] - :param secret: Determines whether the value is a secret and should be - encrypted or not. Default value is false. - :type secret: bool - :param display_name: Required. Unique name of Property. It may contain - only letters, digits, period, dash, and underscore characters. - :type display_name: str - :param value: Required. Value of the property. Can contain policy - expressions. It may not be empty or consist only of whitespace. - :type value: str - """ - - _validation = { - 'id': {'readonly': True}, - 'name': {'readonly': True}, - 'type': {'readonly': True}, - 'tags': {'max_items': 32}, - 'display_name': {'required': True, 'max_length': 256, 'min_length': 1, 'pattern': r'^[A-Za-z0-9-._]+$'}, - 'value': {'required': True, 'max_length': 4096, 'min_length': 1}, - } - - _attribute_map = { - 'id': {'key': 'id', 'type': 'str'}, - 'name': {'key': 'name', 'type': 'str'}, - 'type': {'key': 'type', 'type': 'str'}, - 'tags': {'key': 'properties.tags', 'type': '[str]'}, - 'secret': {'key': 'properties.secret', 'type': 'bool'}, - 'display_name': {'key': 'properties.displayName', 'type': 'str'}, - 'value': {'key': 'properties.value', 'type': 'str'}, - } - - def __init__(self, **kwargs): - super(PropertyContract, self).__init__(**kwargs) - self.tags = kwargs.get('tags', None) - self.secret = kwargs.get('secret', None) - self.display_name = kwargs.get('display_name', None) - self.value = kwargs.get('value', None) diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/property_contract_paged.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/property_contract_paged.py deleted file mode 100644 index da50c40cf02a..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/property_contract_paged.py +++ /dev/null @@ -1,27 +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.paging import Paged - - -class PropertyContractPaged(Paged): - """ - A paging container for iterating over a list of :class:`PropertyContract ` object - """ - - _attribute_map = { - 'next_link': {'key': 'nextLink', 'type': 'str'}, - 'current_page': {'key': 'value', 'type': '[PropertyContract]'} - } - - def __init__(self, *args, **kwargs): - - super(PropertyContractPaged, self).__init__(*args, **kwargs) diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/property_contract_py3.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/property_contract_py3.py deleted file mode 100644 index 36a779b263c2..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/property_contract_py3.py +++ /dev/null @@ -1,67 +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 .resource_py3 import Resource - - -class PropertyContract(Resource): - """Property details. - - Variables are only populated by the server, and will be ignored when - sending a request. - - All required parameters must be populated in order to send to Azure. - - :ivar id: Resource ID. - :vartype id: str - :ivar name: Resource name. - :vartype name: str - :ivar type: Resource type for API Management resource. - :vartype type: str - :param tags: Optional tags that when provided can be used to filter the - property list. - :type tags: list[str] - :param secret: Determines whether the value is a secret and should be - encrypted or not. Default value is false. - :type secret: bool - :param display_name: Required. Unique name of Property. It may contain - only letters, digits, period, dash, and underscore characters. - :type display_name: str - :param value: Required. Value of the property. Can contain policy - expressions. It may not be empty or consist only of whitespace. - :type value: str - """ - - _validation = { - 'id': {'readonly': True}, - 'name': {'readonly': True}, - 'type': {'readonly': True}, - 'tags': {'max_items': 32}, - 'display_name': {'required': True, 'max_length': 256, 'min_length': 1, 'pattern': r'^[A-Za-z0-9-._]+$'}, - 'value': {'required': True, 'max_length': 4096, 'min_length': 1}, - } - - _attribute_map = { - 'id': {'key': 'id', 'type': 'str'}, - 'name': {'key': 'name', 'type': 'str'}, - 'type': {'key': 'type', 'type': 'str'}, - 'tags': {'key': 'properties.tags', 'type': '[str]'}, - 'secret': {'key': 'properties.secret', 'type': 'bool'}, - 'display_name': {'key': 'properties.displayName', 'type': 'str'}, - 'value': {'key': 'properties.value', 'type': 'str'}, - } - - def __init__(self, *, display_name: str, value: str, tags=None, secret: bool=None, **kwargs) -> None: - super(PropertyContract, self).__init__(**kwargs) - self.tags = tags - self.secret = secret - self.display_name = display_name - self.value = value diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/property_entity_base_parameters.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/property_entity_base_parameters.py deleted file mode 100644 index 7666d3463f19..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/property_entity_base_parameters.py +++ /dev/null @@ -1,38 +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 PropertyEntityBaseParameters(Model): - """Property Entity Base Parameters set. - - :param tags: Optional tags that when provided can be used to filter the - property list. - :type tags: list[str] - :param secret: Determines whether the value is a secret and should be - encrypted or not. Default value is false. - :type secret: bool - """ - - _validation = { - 'tags': {'max_items': 32}, - } - - _attribute_map = { - 'tags': {'key': 'tags', 'type': '[str]'}, - 'secret': {'key': 'secret', 'type': 'bool'}, - } - - def __init__(self, **kwargs): - super(PropertyEntityBaseParameters, self).__init__(**kwargs) - self.tags = kwargs.get('tags', None) - self.secret = kwargs.get('secret', None) diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/property_entity_base_parameters_py3.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/property_entity_base_parameters_py3.py deleted file mode 100644 index e01077848439..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/property_entity_base_parameters_py3.py +++ /dev/null @@ -1,38 +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 PropertyEntityBaseParameters(Model): - """Property Entity Base Parameters set. - - :param tags: Optional tags that when provided can be used to filter the - property list. - :type tags: list[str] - :param secret: Determines whether the value is a secret and should be - encrypted or not. Default value is false. - :type secret: bool - """ - - _validation = { - 'tags': {'max_items': 32}, - } - - _attribute_map = { - 'tags': {'key': 'tags', 'type': '[str]'}, - 'secret': {'key': 'secret', 'type': 'bool'}, - } - - def __init__(self, *, tags=None, secret: bool=None, **kwargs) -> None: - super(PropertyEntityBaseParameters, self).__init__(**kwargs) - self.tags = tags - self.secret = secret diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/property_update_parameters.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/property_update_parameters.py deleted file mode 100644 index 5a21c08aa09e..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/property_update_parameters.py +++ /dev/null @@ -1,50 +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 PropertyUpdateParameters(Model): - """Property update Parameters. - - :param tags: Optional tags that when provided can be used to filter the - property list. - :type tags: list[str] - :param secret: Determines whether the value is a secret and should be - encrypted or not. Default value is false. - :type secret: bool - :param display_name: Unique name of Property. It may contain only letters, - digits, period, dash, and underscore characters. - :type display_name: str - :param value: Value of the property. Can contain policy expressions. It - may not be empty or consist only of whitespace. - :type value: str - """ - - _validation = { - 'tags': {'max_items': 32}, - 'display_name': {'max_length': 256, 'min_length': 1, 'pattern': r'^[A-Za-z0-9-._]+$'}, - 'value': {'max_length': 4096, 'min_length': 1}, - } - - _attribute_map = { - 'tags': {'key': 'properties.tags', 'type': '[str]'}, - 'secret': {'key': 'properties.secret', 'type': 'bool'}, - 'display_name': {'key': 'properties.displayName', 'type': 'str'}, - 'value': {'key': 'properties.value', 'type': 'str'}, - } - - def __init__(self, **kwargs): - super(PropertyUpdateParameters, self).__init__(**kwargs) - self.tags = kwargs.get('tags', None) - self.secret = kwargs.get('secret', None) - self.display_name = kwargs.get('display_name', None) - self.value = kwargs.get('value', None) diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/property_update_parameters_py3.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/property_update_parameters_py3.py deleted file mode 100644 index 18a8e255b6c4..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/property_update_parameters_py3.py +++ /dev/null @@ -1,50 +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 PropertyUpdateParameters(Model): - """Property update Parameters. - - :param tags: Optional tags that when provided can be used to filter the - property list. - :type tags: list[str] - :param secret: Determines whether the value is a secret and should be - encrypted or not. Default value is false. - :type secret: bool - :param display_name: Unique name of Property. It may contain only letters, - digits, period, dash, and underscore characters. - :type display_name: str - :param value: Value of the property. Can contain policy expressions. It - may not be empty or consist only of whitespace. - :type value: str - """ - - _validation = { - 'tags': {'max_items': 32}, - 'display_name': {'max_length': 256, 'min_length': 1, 'pattern': r'^[A-Za-z0-9-._]+$'}, - 'value': {'max_length': 4096, 'min_length': 1}, - } - - _attribute_map = { - 'tags': {'key': 'properties.tags', 'type': '[str]'}, - 'secret': {'key': 'properties.secret', 'type': 'bool'}, - 'display_name': {'key': 'properties.displayName', 'type': 'str'}, - 'value': {'key': 'properties.value', 'type': 'str'}, - } - - def __init__(self, *, tags=None, secret: bool=None, display_name: str=None, value: str=None, **kwargs) -> None: - super(PropertyUpdateParameters, self).__init__(**kwargs) - self.tags = tags - self.secret = secret - self.display_name = display_name - self.value = value diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/quota_counter_collection.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/quota_counter_collection.py deleted file mode 100644 index 6785ba44e42a..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/quota_counter_collection.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 QuotaCounterCollection(Model): - """Paged Quota Counter list representation. - - :param value: Quota counter values. - :type value: list[~azure.mgmt.apimanagement.models.QuotaCounterContract] - :param count: Total record count number across all pages. - :type count: long - :param next_link: Next page link if any. - :type next_link: str - """ - - _attribute_map = { - 'value': {'key': 'value', 'type': '[QuotaCounterContract]'}, - 'count': {'key': 'count', 'type': 'long'}, - 'next_link': {'key': 'nextLink', 'type': 'str'}, - } - - def __init__(self, **kwargs): - super(QuotaCounterCollection, self).__init__(**kwargs) - self.value = kwargs.get('value', None) - self.count = kwargs.get('count', None) - self.next_link = kwargs.get('next_link', None) diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/quota_counter_collection_py3.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/quota_counter_collection_py3.py deleted file mode 100644 index 498623ce8b55..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/quota_counter_collection_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 QuotaCounterCollection(Model): - """Paged Quota Counter list representation. - - :param value: Quota counter values. - :type value: list[~azure.mgmt.apimanagement.models.QuotaCounterContract] - :param count: Total record count number across all pages. - :type count: long - :param next_link: Next page link if any. - :type next_link: str - """ - - _attribute_map = { - 'value': {'key': 'value', 'type': '[QuotaCounterContract]'}, - 'count': {'key': 'count', 'type': 'long'}, - 'next_link': {'key': 'nextLink', 'type': 'str'}, - } - - def __init__(self, *, value=None, count: int=None, next_link: str=None, **kwargs) -> None: - super(QuotaCounterCollection, self).__init__(**kwargs) - self.value = value - self.count = count - self.next_link = next_link diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/quota_counter_contract.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/quota_counter_contract.py deleted file mode 100644 index ce05718d13f9..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/quota_counter_contract.py +++ /dev/null @@ -1,60 +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 QuotaCounterContract(Model): - """Quota counter details. - - All required parameters must be populated in order to send to Azure. - - :param counter_key: Required. The Key value of the Counter. Must not be - empty. - :type counter_key: str - :param period_key: Required. Identifier of the Period for which the - counter was collected. Must not be empty. - :type period_key: str - :param period_start_time: Required. The date of the start of Counter - Period. The date conforms to the following format: `yyyy-MM-ddTHH:mm:ssZ` - as specified by the ISO 8601 standard. - :type period_start_time: datetime - :param period_end_time: Required. The date of the end of Counter Period. - The date conforms to the following format: `yyyy-MM-ddTHH:mm:ssZ` as - specified by the ISO 8601 standard. - :type period_end_time: datetime - :param value: Quota Value Properties - :type value: - ~azure.mgmt.apimanagement.models.QuotaCounterValueContractProperties - """ - - _validation = { - 'counter_key': {'required': True, 'min_length': 1}, - 'period_key': {'required': True, 'min_length': 1}, - 'period_start_time': {'required': True}, - 'period_end_time': {'required': True}, - } - - _attribute_map = { - 'counter_key': {'key': 'counterKey', 'type': 'str'}, - 'period_key': {'key': 'periodKey', 'type': 'str'}, - 'period_start_time': {'key': 'periodStartTime', 'type': 'iso-8601'}, - 'period_end_time': {'key': 'periodEndTime', 'type': 'iso-8601'}, - 'value': {'key': 'value', 'type': 'QuotaCounterValueContractProperties'}, - } - - def __init__(self, **kwargs): - super(QuotaCounterContract, self).__init__(**kwargs) - self.counter_key = kwargs.get('counter_key', None) - self.period_key = kwargs.get('period_key', None) - self.period_start_time = kwargs.get('period_start_time', None) - self.period_end_time = kwargs.get('period_end_time', None) - self.value = kwargs.get('value', None) diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/quota_counter_contract_py3.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/quota_counter_contract_py3.py deleted file mode 100644 index d3469173ad8b..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/quota_counter_contract_py3.py +++ /dev/null @@ -1,60 +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 QuotaCounterContract(Model): - """Quota counter details. - - All required parameters must be populated in order to send to Azure. - - :param counter_key: Required. The Key value of the Counter. Must not be - empty. - :type counter_key: str - :param period_key: Required. Identifier of the Period for which the - counter was collected. Must not be empty. - :type period_key: str - :param period_start_time: Required. The date of the start of Counter - Period. The date conforms to the following format: `yyyy-MM-ddTHH:mm:ssZ` - as specified by the ISO 8601 standard. - :type period_start_time: datetime - :param period_end_time: Required. The date of the end of Counter Period. - The date conforms to the following format: `yyyy-MM-ddTHH:mm:ssZ` as - specified by the ISO 8601 standard. - :type period_end_time: datetime - :param value: Quota Value Properties - :type value: - ~azure.mgmt.apimanagement.models.QuotaCounterValueContractProperties - """ - - _validation = { - 'counter_key': {'required': True, 'min_length': 1}, - 'period_key': {'required': True, 'min_length': 1}, - 'period_start_time': {'required': True}, - 'period_end_time': {'required': True}, - } - - _attribute_map = { - 'counter_key': {'key': 'counterKey', 'type': 'str'}, - 'period_key': {'key': 'periodKey', 'type': 'str'}, - 'period_start_time': {'key': 'periodStartTime', 'type': 'iso-8601'}, - 'period_end_time': {'key': 'periodEndTime', 'type': 'iso-8601'}, - 'value': {'key': 'value', 'type': 'QuotaCounterValueContractProperties'}, - } - - def __init__(self, *, counter_key: str, period_key: str, period_start_time, period_end_time, value=None, **kwargs) -> None: - super(QuotaCounterContract, self).__init__(**kwargs) - self.counter_key = counter_key - self.period_key = period_key - self.period_start_time = period_start_time - self.period_end_time = period_end_time - self.value = value diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/quota_counter_value_contract.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/quota_counter_value_contract.py deleted file mode 100644 index b09ad9d57dba..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/quota_counter_value_contract.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 QuotaCounterValueContract(Model): - """Quota counter value details. - - :param calls_count: Number of times Counter was called. - :type calls_count: int - :param kb_transferred: Data Transferred in KiloBytes. - :type kb_transferred: float - """ - - _attribute_map = { - 'calls_count': {'key': 'value.callsCount', 'type': 'int'}, - 'kb_transferred': {'key': 'value.kbTransferred', 'type': 'float'}, - } - - def __init__(self, **kwargs): - super(QuotaCounterValueContract, self).__init__(**kwargs) - self.calls_count = kwargs.get('calls_count', None) - self.kb_transferred = kwargs.get('kb_transferred', None) diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/quota_counter_value_contract_properties.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/quota_counter_value_contract_properties.py deleted file mode 100644 index f3109571e5a2..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/quota_counter_value_contract_properties.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 QuotaCounterValueContractProperties(Model): - """Quota counter value details. - - :param calls_count: Number of times Counter was called. - :type calls_count: int - :param kb_transferred: Data Transferred in KiloBytes. - :type kb_transferred: float - """ - - _attribute_map = { - 'calls_count': {'key': 'callsCount', 'type': 'int'}, - 'kb_transferred': {'key': 'kbTransferred', 'type': 'float'}, - } - - def __init__(self, **kwargs): - super(QuotaCounterValueContractProperties, self).__init__(**kwargs) - self.calls_count = kwargs.get('calls_count', None) - self.kb_transferred = kwargs.get('kb_transferred', None) diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/quota_counter_value_contract_properties_py3.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/quota_counter_value_contract_properties_py3.py deleted file mode 100644 index d425c680cab8..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/quota_counter_value_contract_properties_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 QuotaCounterValueContractProperties(Model): - """Quota counter value details. - - :param calls_count: Number of times Counter was called. - :type calls_count: int - :param kb_transferred: Data Transferred in KiloBytes. - :type kb_transferred: float - """ - - _attribute_map = { - 'calls_count': {'key': 'callsCount', 'type': 'int'}, - 'kb_transferred': {'key': 'kbTransferred', 'type': 'float'}, - } - - def __init__(self, *, calls_count: int=None, kb_transferred: float=None, **kwargs) -> None: - super(QuotaCounterValueContractProperties, self).__init__(**kwargs) - self.calls_count = calls_count - self.kb_transferred = kb_transferred diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/quota_counter_value_contract_py3.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/quota_counter_value_contract_py3.py deleted file mode 100644 index 2a2d0b9216e9..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/quota_counter_value_contract_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 QuotaCounterValueContract(Model): - """Quota counter value details. - - :param calls_count: Number of times Counter was called. - :type calls_count: int - :param kb_transferred: Data Transferred in KiloBytes. - :type kb_transferred: float - """ - - _attribute_map = { - 'calls_count': {'key': 'value.callsCount', 'type': 'int'}, - 'kb_transferred': {'key': 'value.kbTransferred', 'type': 'float'}, - } - - def __init__(self, *, calls_count: int=None, kb_transferred: float=None, **kwargs) -> None: - super(QuotaCounterValueContract, self).__init__(**kwargs) - self.calls_count = calls_count - self.kb_transferred = kb_transferred diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/recipient_email_collection.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/recipient_email_collection.py deleted file mode 100644 index e56dbf2f3a19..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/recipient_email_collection.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 RecipientEmailCollection(Model): - """Paged Recipient User list representation. - - :param value: Page values. - :type value: list[~azure.mgmt.apimanagement.models.RecipientEmailContract] - :param next_link: Next page link if any. - :type next_link: str - """ - - _attribute_map = { - 'value': {'key': 'value', 'type': '[RecipientEmailContract]'}, - 'next_link': {'key': 'nextLink', 'type': 'str'}, - } - - def __init__(self, **kwargs): - super(RecipientEmailCollection, self).__init__(**kwargs) - self.value = kwargs.get('value', None) - self.next_link = kwargs.get('next_link', None) diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/recipient_email_collection_py3.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/recipient_email_collection_py3.py deleted file mode 100644 index 20592d1ac7ce..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/recipient_email_collection_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 RecipientEmailCollection(Model): - """Paged Recipient User list representation. - - :param value: Page values. - :type value: list[~azure.mgmt.apimanagement.models.RecipientEmailContract] - :param next_link: Next page link if any. - :type next_link: str - """ - - _attribute_map = { - 'value': {'key': 'value', 'type': '[RecipientEmailContract]'}, - 'next_link': {'key': 'nextLink', 'type': 'str'}, - } - - def __init__(self, *, value=None, next_link: str=None, **kwargs) -> None: - super(RecipientEmailCollection, self).__init__(**kwargs) - self.value = value - self.next_link = next_link diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/recipient_email_contract.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/recipient_email_contract.py deleted file mode 100644 index 862e3f09c0f1..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/recipient_email_contract.py +++ /dev/null @@ -1,46 +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 .resource import Resource - - -class RecipientEmailContract(Resource): - """Recipient Email details. - - Variables are only populated by the server, and will be ignored when - sending a request. - - :ivar id: Resource ID. - :vartype id: str - :ivar name: Resource name. - :vartype name: str - :ivar type: Resource type for API Management resource. - :vartype type: str - :param email: User Email subscribed to notification. - :type email: str - """ - - _validation = { - 'id': {'readonly': True}, - 'name': {'readonly': True}, - 'type': {'readonly': True}, - } - - _attribute_map = { - 'id': {'key': 'id', 'type': 'str'}, - 'name': {'key': 'name', 'type': 'str'}, - 'type': {'key': 'type', 'type': 'str'}, - 'email': {'key': 'properties.email', 'type': 'str'}, - } - - def __init__(self, **kwargs): - super(RecipientEmailContract, self).__init__(**kwargs) - self.email = kwargs.get('email', None) diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/recipient_email_contract_py3.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/recipient_email_contract_py3.py deleted file mode 100644 index 175381652c07..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/recipient_email_contract_py3.py +++ /dev/null @@ -1,46 +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 .resource_py3 import Resource - - -class RecipientEmailContract(Resource): - """Recipient Email details. - - Variables are only populated by the server, and will be ignored when - sending a request. - - :ivar id: Resource ID. - :vartype id: str - :ivar name: Resource name. - :vartype name: str - :ivar type: Resource type for API Management resource. - :vartype type: str - :param email: User Email subscribed to notification. - :type email: str - """ - - _validation = { - 'id': {'readonly': True}, - 'name': {'readonly': True}, - 'type': {'readonly': True}, - } - - _attribute_map = { - 'id': {'key': 'id', 'type': 'str'}, - 'name': {'key': 'name', 'type': 'str'}, - 'type': {'key': 'type', 'type': 'str'}, - 'email': {'key': 'properties.email', 'type': 'str'}, - } - - def __init__(self, *, email: str=None, **kwargs) -> None: - super(RecipientEmailContract, self).__init__(**kwargs) - self.email = email diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/recipient_user_collection.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/recipient_user_collection.py deleted file mode 100644 index 8555f416e541..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/recipient_user_collection.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 RecipientUserCollection(Model): - """Paged Recipient User list representation. - - :param value: Page values. - :type value: list[~azure.mgmt.apimanagement.models.RecipientUserContract] - :param next_link: Next page link if any. - :type next_link: str - """ - - _attribute_map = { - 'value': {'key': 'value', 'type': '[RecipientUserContract]'}, - 'next_link': {'key': 'nextLink', 'type': 'str'}, - } - - def __init__(self, **kwargs): - super(RecipientUserCollection, self).__init__(**kwargs) - self.value = kwargs.get('value', None) - self.next_link = kwargs.get('next_link', None) diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/recipient_user_collection_py3.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/recipient_user_collection_py3.py deleted file mode 100644 index 1efa3a09c093..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/recipient_user_collection_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 RecipientUserCollection(Model): - """Paged Recipient User list representation. - - :param value: Page values. - :type value: list[~azure.mgmt.apimanagement.models.RecipientUserContract] - :param next_link: Next page link if any. - :type next_link: str - """ - - _attribute_map = { - 'value': {'key': 'value', 'type': '[RecipientUserContract]'}, - 'next_link': {'key': 'nextLink', 'type': 'str'}, - } - - def __init__(self, *, value=None, next_link: str=None, **kwargs) -> None: - super(RecipientUserCollection, self).__init__(**kwargs) - self.value = value - self.next_link = next_link diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/recipient_user_contract.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/recipient_user_contract.py deleted file mode 100644 index d357cd431be5..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/recipient_user_contract.py +++ /dev/null @@ -1,46 +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 .resource import Resource - - -class RecipientUserContract(Resource): - """Recipient User details. - - Variables are only populated by the server, and will be ignored when - sending a request. - - :ivar id: Resource ID. - :vartype id: str - :ivar name: Resource name. - :vartype name: str - :ivar type: Resource type for API Management resource. - :vartype type: str - :param user_id: API Management UserId subscribed to notification. - :type user_id: str - """ - - _validation = { - 'id': {'readonly': True}, - 'name': {'readonly': True}, - 'type': {'readonly': True}, - } - - _attribute_map = { - 'id': {'key': 'id', 'type': 'str'}, - 'name': {'key': 'name', 'type': 'str'}, - 'type': {'key': 'type', 'type': 'str'}, - 'user_id': {'key': 'properties.userId', 'type': 'str'}, - } - - def __init__(self, **kwargs): - super(RecipientUserContract, self).__init__(**kwargs) - self.user_id = kwargs.get('user_id', None) diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/recipient_user_contract_py3.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/recipient_user_contract_py3.py deleted file mode 100644 index a3112c65a24d..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/recipient_user_contract_py3.py +++ /dev/null @@ -1,46 +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 .resource_py3 import Resource - - -class RecipientUserContract(Resource): - """Recipient User details. - - Variables are only populated by the server, and will be ignored when - sending a request. - - :ivar id: Resource ID. - :vartype id: str - :ivar name: Resource name. - :vartype name: str - :ivar type: Resource type for API Management resource. - :vartype type: str - :param user_id: API Management UserId subscribed to notification. - :type user_id: str - """ - - _validation = { - 'id': {'readonly': True}, - 'name': {'readonly': True}, - 'type': {'readonly': True}, - } - - _attribute_map = { - 'id': {'key': 'id', 'type': 'str'}, - 'name': {'key': 'name', 'type': 'str'}, - 'type': {'key': 'type', 'type': 'str'}, - 'user_id': {'key': 'properties.userId', 'type': 'str'}, - } - - def __init__(self, *, user_id: str=None, **kwargs) -> None: - super(RecipientUserContract, self).__init__(**kwargs) - self.user_id = user_id diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/recipients_contract_properties.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/recipients_contract_properties.py deleted file mode 100644 index ec3457181ae8..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/recipients_contract_properties.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 RecipientsContractProperties(Model): - """Notification Parameter contract. - - :param emails: List of Emails subscribed for the notification. - :type emails: list[str] - :param users: List of Users subscribed for the notification. - :type users: list[str] - """ - - _attribute_map = { - 'emails': {'key': 'emails', 'type': '[str]'}, - 'users': {'key': 'users', 'type': '[str]'}, - } - - def __init__(self, **kwargs): - super(RecipientsContractProperties, self).__init__(**kwargs) - self.emails = kwargs.get('emails', None) - self.users = kwargs.get('users', None) diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/recipients_contract_properties_py3.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/recipients_contract_properties_py3.py deleted file mode 100644 index 4ee05780273d..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/recipients_contract_properties_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 RecipientsContractProperties(Model): - """Notification Parameter contract. - - :param emails: List of Emails subscribed for the notification. - :type emails: list[str] - :param users: List of Users subscribed for the notification. - :type users: list[str] - """ - - _attribute_map = { - 'emails': {'key': 'emails', 'type': '[str]'}, - 'users': {'key': 'users', 'type': '[str]'}, - } - - def __init__(self, *, emails=None, users=None, **kwargs) -> None: - super(RecipientsContractProperties, self).__init__(**kwargs) - self.emails = emails - self.users = users diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/region_contract.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/region_contract.py deleted file mode 100644 index b45ef72db4c0..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/region_contract.py +++ /dev/null @@ -1,43 +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 RegionContract(Model): - """Region profile. - - Variables are only populated by the server, and will be ignored when - sending a request. - - :ivar name: Region name. - :vartype name: str - :param is_master_region: whether Region is the master region. - :type is_master_region: bool - :param is_deleted: whether Region is deleted. - :type is_deleted: bool - """ - - _validation = { - 'name': {'readonly': True}, - } - - _attribute_map = { - 'name': {'key': 'name', 'type': 'str'}, - 'is_master_region': {'key': 'isMasterRegion', 'type': 'bool'}, - 'is_deleted': {'key': 'isDeleted', 'type': 'bool'}, - } - - def __init__(self, **kwargs): - super(RegionContract, self).__init__(**kwargs) - self.name = None - self.is_master_region = kwargs.get('is_master_region', None) - self.is_deleted = kwargs.get('is_deleted', None) diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/region_contract_paged.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/region_contract_paged.py deleted file mode 100644 index d2d31024ffdd..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/region_contract_paged.py +++ /dev/null @@ -1,27 +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.paging import Paged - - -class RegionContractPaged(Paged): - """ - A paging container for iterating over a list of :class:`RegionContract ` object - """ - - _attribute_map = { - 'next_link': {'key': 'nextLink', 'type': 'str'}, - 'current_page': {'key': 'value', 'type': '[RegionContract]'} - } - - def __init__(self, *args, **kwargs): - - super(RegionContractPaged, self).__init__(*args, **kwargs) diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/region_contract_py3.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/region_contract_py3.py deleted file mode 100644 index 6818fd3baca6..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/region_contract_py3.py +++ /dev/null @@ -1,43 +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 RegionContract(Model): - """Region profile. - - Variables are only populated by the server, and will be ignored when - sending a request. - - :ivar name: Region name. - :vartype name: str - :param is_master_region: whether Region is the master region. - :type is_master_region: bool - :param is_deleted: whether Region is deleted. - :type is_deleted: bool - """ - - _validation = { - 'name': {'readonly': True}, - } - - _attribute_map = { - 'name': {'key': 'name', 'type': 'str'}, - 'is_master_region': {'key': 'isMasterRegion', 'type': 'bool'}, - 'is_deleted': {'key': 'isDeleted', 'type': 'bool'}, - } - - def __init__(self, *, is_master_region: bool=None, is_deleted: bool=None, **kwargs) -> None: - super(RegionContract, self).__init__(**kwargs) - self.name = None - self.is_master_region = is_master_region - self.is_deleted = is_deleted diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/registration_delegation_settings_properties.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/registration_delegation_settings_properties.py deleted file mode 100644 index d104cb341470..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/registration_delegation_settings_properties.py +++ /dev/null @@ -1,28 +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 RegistrationDelegationSettingsProperties(Model): - """User registration delegation settings properties. - - :param enabled: Enable or disable delegation for user registration. - :type enabled: bool - """ - - _attribute_map = { - 'enabled': {'key': 'enabled', 'type': 'bool'}, - } - - def __init__(self, **kwargs): - super(RegistrationDelegationSettingsProperties, self).__init__(**kwargs) - self.enabled = kwargs.get('enabled', None) diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/registration_delegation_settings_properties_py3.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/registration_delegation_settings_properties_py3.py deleted file mode 100644 index 26b410a0720b..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/registration_delegation_settings_properties_py3.py +++ /dev/null @@ -1,28 +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 RegistrationDelegationSettingsProperties(Model): - """User registration delegation settings properties. - - :param enabled: Enable or disable delegation for user registration. - :type enabled: bool - """ - - _attribute_map = { - 'enabled': {'key': 'enabled', 'type': 'bool'}, - } - - def __init__(self, *, enabled: bool=None, **kwargs) -> None: - super(RegistrationDelegationSettingsProperties, self).__init__(**kwargs) - self.enabled = enabled diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/report_record_contract.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/report_record_contract.py deleted file mode 100644 index 21d19e4184e0..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/report_record_contract.py +++ /dev/null @@ -1,153 +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 ReportRecordContract(Model): - """Report data. - - Variables are only populated by the server, and will be ignored when - sending a request. - - :param name: Name depending on report endpoint specifies product, API, - operation or developer name. - :type name: str - :param timestamp: Start of aggregation period. The date conforms to the - following format: `yyyy-MM-ddTHH:mm:ssZ` as specified by the ISO 8601 - standard. - :type timestamp: datetime - :param interval: Length of aggregation period. Interval must be multiple - of 15 minutes and may not be zero. The value should be in ISO 8601 format - (http://en.wikipedia.org/wiki/ISO_8601#Durations). - :type interval: str - :param country: Country to which this record data is related. - :type country: str - :param region: Country region to which this record data is related. - :type region: str - :param zip: Zip code to which this record data is related. - :type zip: str - :ivar user_id: User identifier path. /users/{userId} - :vartype user_id: str - :ivar product_id: Product identifier path. /products/{productId} - :vartype product_id: str - :param api_id: API identifier path. /apis/{apiId} - :type api_id: str - :param operation_id: Operation identifier path. - /apis/{apiId}/operations/{operationId} - :type operation_id: str - :param api_region: API region identifier. - :type api_region: str - :param subscription_id: Subscription identifier path. - /subscriptions/{subscriptionId} - :type subscription_id: str - :param call_count_success: Number of successful calls. This includes calls - returning HttpStatusCode <= 301 and HttpStatusCode.NotModified and - HttpStatusCode.TemporaryRedirect - :type call_count_success: int - :param call_count_blocked: Number of calls blocked due to invalid - credentials. This includes calls returning HttpStatusCode.Unauthorized and - HttpStatusCode.Forbidden and HttpStatusCode.TooManyRequests - :type call_count_blocked: int - :param call_count_failed: Number of calls failed due to proxy or backend - errors. This includes calls returning HttpStatusCode.BadRequest(400) and - any Code between HttpStatusCode.InternalServerError (500) and 600 - :type call_count_failed: int - :param call_count_other: Number of other calls. - :type call_count_other: int - :param call_count_total: Total number of calls. - :type call_count_total: int - :param bandwidth: Bandwidth consumed. - :type bandwidth: long - :param cache_hit_count: Number of times when content was served from cache - policy. - :type cache_hit_count: int - :param cache_miss_count: Number of times content was fetched from backend. - :type cache_miss_count: int - :param api_time_avg: Average time it took to process request. - :type api_time_avg: float - :param api_time_min: Minimum time it took to process request. - :type api_time_min: float - :param api_time_max: Maximum time it took to process request. - :type api_time_max: float - :param service_time_avg: Average time it took to process request on - backend. - :type service_time_avg: float - :param service_time_min: Minimum time it took to process request on - backend. - :type service_time_min: float - :param service_time_max: Maximum time it took to process request on - backend. - :type service_time_max: float - """ - - _validation = { - 'user_id': {'readonly': True}, - 'product_id': {'readonly': True}, - } - - _attribute_map = { - 'name': {'key': 'name', 'type': 'str'}, - 'timestamp': {'key': 'timestamp', 'type': 'iso-8601'}, - 'interval': {'key': 'interval', 'type': 'str'}, - 'country': {'key': 'country', 'type': 'str'}, - 'region': {'key': 'region', 'type': 'str'}, - 'zip': {'key': 'zip', 'type': 'str'}, - 'user_id': {'key': 'userId', 'type': 'str'}, - 'product_id': {'key': 'productId', 'type': 'str'}, - 'api_id': {'key': 'apiId', 'type': 'str'}, - 'operation_id': {'key': 'operationId', 'type': 'str'}, - 'api_region': {'key': 'apiRegion', 'type': 'str'}, - 'subscription_id': {'key': 'subscriptionId', 'type': 'str'}, - 'call_count_success': {'key': 'callCountSuccess', 'type': 'int'}, - 'call_count_blocked': {'key': 'callCountBlocked', 'type': 'int'}, - 'call_count_failed': {'key': 'callCountFailed', 'type': 'int'}, - 'call_count_other': {'key': 'callCountOther', 'type': 'int'}, - 'call_count_total': {'key': 'callCountTotal', 'type': 'int'}, - 'bandwidth': {'key': 'bandwidth', 'type': 'long'}, - 'cache_hit_count': {'key': 'cacheHitCount', 'type': 'int'}, - 'cache_miss_count': {'key': 'cacheMissCount', 'type': 'int'}, - 'api_time_avg': {'key': 'apiTimeAvg', 'type': 'float'}, - 'api_time_min': {'key': 'apiTimeMin', 'type': 'float'}, - 'api_time_max': {'key': 'apiTimeMax', 'type': 'float'}, - 'service_time_avg': {'key': 'serviceTimeAvg', 'type': 'float'}, - 'service_time_min': {'key': 'serviceTimeMin', 'type': 'float'}, - 'service_time_max': {'key': 'serviceTimeMax', 'type': 'float'}, - } - - def __init__(self, **kwargs): - super(ReportRecordContract, self).__init__(**kwargs) - self.name = kwargs.get('name', None) - self.timestamp = kwargs.get('timestamp', None) - self.interval = kwargs.get('interval', None) - self.country = kwargs.get('country', None) - self.region = kwargs.get('region', None) - self.zip = kwargs.get('zip', None) - self.user_id = None - self.product_id = None - self.api_id = kwargs.get('api_id', None) - self.operation_id = kwargs.get('operation_id', None) - self.api_region = kwargs.get('api_region', None) - self.subscription_id = kwargs.get('subscription_id', None) - self.call_count_success = kwargs.get('call_count_success', None) - self.call_count_blocked = kwargs.get('call_count_blocked', None) - self.call_count_failed = kwargs.get('call_count_failed', None) - self.call_count_other = kwargs.get('call_count_other', None) - self.call_count_total = kwargs.get('call_count_total', None) - self.bandwidth = kwargs.get('bandwidth', None) - self.cache_hit_count = kwargs.get('cache_hit_count', None) - self.cache_miss_count = kwargs.get('cache_miss_count', None) - self.api_time_avg = kwargs.get('api_time_avg', None) - self.api_time_min = kwargs.get('api_time_min', None) - self.api_time_max = kwargs.get('api_time_max', None) - self.service_time_avg = kwargs.get('service_time_avg', None) - self.service_time_min = kwargs.get('service_time_min', None) - self.service_time_max = kwargs.get('service_time_max', None) diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/report_record_contract_paged.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/report_record_contract_paged.py deleted file mode 100644 index 94a23d6b3fd8..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/report_record_contract_paged.py +++ /dev/null @@ -1,27 +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.paging import Paged - - -class ReportRecordContractPaged(Paged): - """ - A paging container for iterating over a list of :class:`ReportRecordContract ` object - """ - - _attribute_map = { - 'next_link': {'key': 'nextLink', 'type': 'str'}, - 'current_page': {'key': 'value', 'type': '[ReportRecordContract]'} - } - - def __init__(self, *args, **kwargs): - - super(ReportRecordContractPaged, self).__init__(*args, **kwargs) diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/report_record_contract_py3.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/report_record_contract_py3.py deleted file mode 100644 index 465870d5fc01..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/report_record_contract_py3.py +++ /dev/null @@ -1,153 +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 ReportRecordContract(Model): - """Report data. - - Variables are only populated by the server, and will be ignored when - sending a request. - - :param name: Name depending on report endpoint specifies product, API, - operation or developer name. - :type name: str - :param timestamp: Start of aggregation period. The date conforms to the - following format: `yyyy-MM-ddTHH:mm:ssZ` as specified by the ISO 8601 - standard. - :type timestamp: datetime - :param interval: Length of aggregation period. Interval must be multiple - of 15 minutes and may not be zero. The value should be in ISO 8601 format - (http://en.wikipedia.org/wiki/ISO_8601#Durations). - :type interval: str - :param country: Country to which this record data is related. - :type country: str - :param region: Country region to which this record data is related. - :type region: str - :param zip: Zip code to which this record data is related. - :type zip: str - :ivar user_id: User identifier path. /users/{userId} - :vartype user_id: str - :ivar product_id: Product identifier path. /products/{productId} - :vartype product_id: str - :param api_id: API identifier path. /apis/{apiId} - :type api_id: str - :param operation_id: Operation identifier path. - /apis/{apiId}/operations/{operationId} - :type operation_id: str - :param api_region: API region identifier. - :type api_region: str - :param subscription_id: Subscription identifier path. - /subscriptions/{subscriptionId} - :type subscription_id: str - :param call_count_success: Number of successful calls. This includes calls - returning HttpStatusCode <= 301 and HttpStatusCode.NotModified and - HttpStatusCode.TemporaryRedirect - :type call_count_success: int - :param call_count_blocked: Number of calls blocked due to invalid - credentials. This includes calls returning HttpStatusCode.Unauthorized and - HttpStatusCode.Forbidden and HttpStatusCode.TooManyRequests - :type call_count_blocked: int - :param call_count_failed: Number of calls failed due to proxy or backend - errors. This includes calls returning HttpStatusCode.BadRequest(400) and - any Code between HttpStatusCode.InternalServerError (500) and 600 - :type call_count_failed: int - :param call_count_other: Number of other calls. - :type call_count_other: int - :param call_count_total: Total number of calls. - :type call_count_total: int - :param bandwidth: Bandwidth consumed. - :type bandwidth: long - :param cache_hit_count: Number of times when content was served from cache - policy. - :type cache_hit_count: int - :param cache_miss_count: Number of times content was fetched from backend. - :type cache_miss_count: int - :param api_time_avg: Average time it took to process request. - :type api_time_avg: float - :param api_time_min: Minimum time it took to process request. - :type api_time_min: float - :param api_time_max: Maximum time it took to process request. - :type api_time_max: float - :param service_time_avg: Average time it took to process request on - backend. - :type service_time_avg: float - :param service_time_min: Minimum time it took to process request on - backend. - :type service_time_min: float - :param service_time_max: Maximum time it took to process request on - backend. - :type service_time_max: float - """ - - _validation = { - 'user_id': {'readonly': True}, - 'product_id': {'readonly': True}, - } - - _attribute_map = { - 'name': {'key': 'name', 'type': 'str'}, - 'timestamp': {'key': 'timestamp', 'type': 'iso-8601'}, - 'interval': {'key': 'interval', 'type': 'str'}, - 'country': {'key': 'country', 'type': 'str'}, - 'region': {'key': 'region', 'type': 'str'}, - 'zip': {'key': 'zip', 'type': 'str'}, - 'user_id': {'key': 'userId', 'type': 'str'}, - 'product_id': {'key': 'productId', 'type': 'str'}, - 'api_id': {'key': 'apiId', 'type': 'str'}, - 'operation_id': {'key': 'operationId', 'type': 'str'}, - 'api_region': {'key': 'apiRegion', 'type': 'str'}, - 'subscription_id': {'key': 'subscriptionId', 'type': 'str'}, - 'call_count_success': {'key': 'callCountSuccess', 'type': 'int'}, - 'call_count_blocked': {'key': 'callCountBlocked', 'type': 'int'}, - 'call_count_failed': {'key': 'callCountFailed', 'type': 'int'}, - 'call_count_other': {'key': 'callCountOther', 'type': 'int'}, - 'call_count_total': {'key': 'callCountTotal', 'type': 'int'}, - 'bandwidth': {'key': 'bandwidth', 'type': 'long'}, - 'cache_hit_count': {'key': 'cacheHitCount', 'type': 'int'}, - 'cache_miss_count': {'key': 'cacheMissCount', 'type': 'int'}, - 'api_time_avg': {'key': 'apiTimeAvg', 'type': 'float'}, - 'api_time_min': {'key': 'apiTimeMin', 'type': 'float'}, - 'api_time_max': {'key': 'apiTimeMax', 'type': 'float'}, - 'service_time_avg': {'key': 'serviceTimeAvg', 'type': 'float'}, - 'service_time_min': {'key': 'serviceTimeMin', 'type': 'float'}, - 'service_time_max': {'key': 'serviceTimeMax', 'type': 'float'}, - } - - def __init__(self, *, name: str=None, timestamp=None, interval: str=None, country: str=None, region: str=None, zip: str=None, api_id: str=None, operation_id: str=None, api_region: str=None, subscription_id: str=None, call_count_success: int=None, call_count_blocked: int=None, call_count_failed: int=None, call_count_other: int=None, call_count_total: int=None, bandwidth: int=None, cache_hit_count: int=None, cache_miss_count: int=None, api_time_avg: float=None, api_time_min: float=None, api_time_max: float=None, service_time_avg: float=None, service_time_min: float=None, service_time_max: float=None, **kwargs) -> None: - super(ReportRecordContract, self).__init__(**kwargs) - self.name = name - self.timestamp = timestamp - self.interval = interval - self.country = country - self.region = region - self.zip = zip - self.user_id = None - self.product_id = None - self.api_id = api_id - self.operation_id = operation_id - self.api_region = api_region - self.subscription_id = subscription_id - self.call_count_success = call_count_success - self.call_count_blocked = call_count_blocked - self.call_count_failed = call_count_failed - self.call_count_other = call_count_other - self.call_count_total = call_count_total - self.bandwidth = bandwidth - self.cache_hit_count = cache_hit_count - self.cache_miss_count = cache_miss_count - self.api_time_avg = api_time_avg - self.api_time_min = api_time_min - self.api_time_max = api_time_max - self.service_time_avg = service_time_avg - self.service_time_min = service_time_min - self.service_time_max = service_time_max diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/representation_contract.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/representation_contract.py deleted file mode 100644 index 3bdfe5e8581e..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/representation_contract.py +++ /dev/null @@ -1,58 +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 RepresentationContract(Model): - """Operation request/response representation details. - - All required parameters must be populated in order to send to Azure. - - :param content_type: Required. Specifies a registered or custom content - type for this representation, e.g. application/xml. - :type content_type: str - :param sample: An example of the representation. - :type sample: str - :param schema_id: Schema identifier. Applicable only if 'contentType' - value is neither 'application/x-www-form-urlencoded' nor - 'multipart/form-data'. - :type schema_id: str - :param type_name: Type name defined by the schema. Applicable only if - 'contentType' value is neither 'application/x-www-form-urlencoded' nor - 'multipart/form-data'. - :type type_name: str - :param form_parameters: Collection of form parameters. Required if - 'contentType' value is either 'application/x-www-form-urlencoded' or - 'multipart/form-data'.. - :type form_parameters: - list[~azure.mgmt.apimanagement.models.ParameterContract] - """ - - _validation = { - 'content_type': {'required': True}, - } - - _attribute_map = { - 'content_type': {'key': 'contentType', 'type': 'str'}, - 'sample': {'key': 'sample', 'type': 'str'}, - 'schema_id': {'key': 'schemaId', 'type': 'str'}, - 'type_name': {'key': 'typeName', 'type': 'str'}, - 'form_parameters': {'key': 'formParameters', 'type': '[ParameterContract]'}, - } - - def __init__(self, **kwargs): - super(RepresentationContract, self).__init__(**kwargs) - self.content_type = kwargs.get('content_type', None) - self.sample = kwargs.get('sample', None) - self.schema_id = kwargs.get('schema_id', None) - self.type_name = kwargs.get('type_name', None) - self.form_parameters = kwargs.get('form_parameters', None) diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/representation_contract_py3.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/representation_contract_py3.py deleted file mode 100644 index 2dc5be839fe4..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/representation_contract_py3.py +++ /dev/null @@ -1,58 +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 RepresentationContract(Model): - """Operation request/response representation details. - - All required parameters must be populated in order to send to Azure. - - :param content_type: Required. Specifies a registered or custom content - type for this representation, e.g. application/xml. - :type content_type: str - :param sample: An example of the representation. - :type sample: str - :param schema_id: Schema identifier. Applicable only if 'contentType' - value is neither 'application/x-www-form-urlencoded' nor - 'multipart/form-data'. - :type schema_id: str - :param type_name: Type name defined by the schema. Applicable only if - 'contentType' value is neither 'application/x-www-form-urlencoded' nor - 'multipart/form-data'. - :type type_name: str - :param form_parameters: Collection of form parameters. Required if - 'contentType' value is either 'application/x-www-form-urlencoded' or - 'multipart/form-data'.. - :type form_parameters: - list[~azure.mgmt.apimanagement.models.ParameterContract] - """ - - _validation = { - 'content_type': {'required': True}, - } - - _attribute_map = { - 'content_type': {'key': 'contentType', 'type': 'str'}, - 'sample': {'key': 'sample', 'type': 'str'}, - 'schema_id': {'key': 'schemaId', 'type': 'str'}, - 'type_name': {'key': 'typeName', 'type': 'str'}, - 'form_parameters': {'key': 'formParameters', 'type': '[ParameterContract]'}, - } - - def __init__(self, *, content_type: str, sample: str=None, schema_id: str=None, type_name: str=None, form_parameters=None, **kwargs) -> None: - super(RepresentationContract, self).__init__(**kwargs) - self.content_type = content_type - self.sample = sample - self.schema_id = schema_id - self.type_name = type_name - self.form_parameters = form_parameters diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/request_contract.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/request_contract.py deleted file mode 100644 index c576288d0328..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/request_contract.py +++ /dev/null @@ -1,42 +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 RequestContract(Model): - """Operation request details. - - :param description: Operation request description. - :type description: str - :param query_parameters: Collection of operation request query parameters. - :type query_parameters: - list[~azure.mgmt.apimanagement.models.ParameterContract] - :param headers: Collection of operation request headers. - :type headers: list[~azure.mgmt.apimanagement.models.ParameterContract] - :param representations: Collection of operation request representations. - :type representations: - list[~azure.mgmt.apimanagement.models.RepresentationContract] - """ - - _attribute_map = { - 'description': {'key': 'description', 'type': 'str'}, - 'query_parameters': {'key': 'queryParameters', 'type': '[ParameterContract]'}, - 'headers': {'key': 'headers', 'type': '[ParameterContract]'}, - 'representations': {'key': 'representations', 'type': '[RepresentationContract]'}, - } - - def __init__(self, **kwargs): - super(RequestContract, self).__init__(**kwargs) - self.description = kwargs.get('description', None) - self.query_parameters = kwargs.get('query_parameters', None) - self.headers = kwargs.get('headers', None) - self.representations = kwargs.get('representations', None) diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/request_contract_py3.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/request_contract_py3.py deleted file mode 100644 index b2d8810a7be0..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/request_contract_py3.py +++ /dev/null @@ -1,42 +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 RequestContract(Model): - """Operation request details. - - :param description: Operation request description. - :type description: str - :param query_parameters: Collection of operation request query parameters. - :type query_parameters: - list[~azure.mgmt.apimanagement.models.ParameterContract] - :param headers: Collection of operation request headers. - :type headers: list[~azure.mgmt.apimanagement.models.ParameterContract] - :param representations: Collection of operation request representations. - :type representations: - list[~azure.mgmt.apimanagement.models.RepresentationContract] - """ - - _attribute_map = { - 'description': {'key': 'description', 'type': 'str'}, - 'query_parameters': {'key': 'queryParameters', 'type': '[ParameterContract]'}, - 'headers': {'key': 'headers', 'type': '[ParameterContract]'}, - 'representations': {'key': 'representations', 'type': '[RepresentationContract]'}, - } - - def __init__(self, *, description: str=None, query_parameters=None, headers=None, representations=None, **kwargs) -> None: - super(RequestContract, self).__init__(**kwargs) - self.description = description - self.query_parameters = query_parameters - self.headers = headers - self.representations = representations diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/request_report_record_contract.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/request_report_record_contract.py deleted file mode 100644 index b63a4c377d97..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/request_report_record_contract.py +++ /dev/null @@ -1,114 +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 RequestReportRecordContract(Model): - """Request Report data. - - Variables are only populated by the server, and will be ignored when - sending a request. - - :param api_id: API identifier path. /apis/{apiId} - :type api_id: str - :param operation_id: Operation identifier path. - /apis/{apiId}/operations/{operationId} - :type operation_id: str - :ivar product_id: Product identifier path. /products/{productId} - :vartype product_id: str - :ivar user_id: User identifier path. /users/{userId} - :vartype user_id: str - :param method: The HTTP method associated with this request.. - :type method: str - :param url: The full URL associated with this request. - :type url: str - :param ip_address: The client IP address associated with this request. - :type ip_address: str - :param backend_response_code: The HTTP status code received by the gateway - as a result of forwarding this request to the backend. - :type backend_response_code: str - :param response_code: The HTTP status code returned by the gateway. - :type response_code: int - :param response_size: The size of the response returned by the gateway. - :type response_size: int - :param timestamp: The date and time when this request was received by the - gateway in ISO 8601 format. - :type timestamp: datetime - :param cache: Specifies if response cache was involved in generating the - response. If the value is none, the cache was not used. If the value is - hit, cached response was returned. If the value is miss, the cache was - used but lookup resulted in a miss and request was fulfilled by the - backend. - :type cache: str - :param api_time: The total time it took to process this request. - :type api_time: float - :param service_time: he time it took to forward this request to the - backend and get the response back. - :type service_time: float - :param api_region: Azure region where the gateway that processed this - request is located. - :type api_region: str - :param subscription_id: Subscription identifier path. - /subscriptions/{subscriptionId} - :type subscription_id: str - :param request_id: Request Identifier. - :type request_id: str - :param request_size: The size of this request.. - :type request_size: int - """ - - _validation = { - 'product_id': {'readonly': True}, - 'user_id': {'readonly': True}, - } - - _attribute_map = { - 'api_id': {'key': 'apiId', 'type': 'str'}, - 'operation_id': {'key': 'operationId', 'type': 'str'}, - 'product_id': {'key': 'productId', 'type': 'str'}, - 'user_id': {'key': 'userId', 'type': 'str'}, - 'method': {'key': 'method', 'type': 'str'}, - 'url': {'key': 'url', 'type': 'str'}, - 'ip_address': {'key': 'ipAddress', 'type': 'str'}, - 'backend_response_code': {'key': 'backendResponseCode', 'type': 'str'}, - 'response_code': {'key': 'responseCode', 'type': 'int'}, - 'response_size': {'key': 'responseSize', 'type': 'int'}, - 'timestamp': {'key': 'timestamp', 'type': 'iso-8601'}, - 'cache': {'key': 'cache', 'type': 'str'}, - 'api_time': {'key': 'apiTime', 'type': 'float'}, - 'service_time': {'key': 'serviceTime', 'type': 'float'}, - 'api_region': {'key': 'apiRegion', 'type': 'str'}, - 'subscription_id': {'key': 'subscriptionId', 'type': 'str'}, - 'request_id': {'key': 'requestId', 'type': 'str'}, - 'request_size': {'key': 'requestSize', 'type': 'int'}, - } - - def __init__(self, **kwargs): - super(RequestReportRecordContract, self).__init__(**kwargs) - self.api_id = kwargs.get('api_id', None) - self.operation_id = kwargs.get('operation_id', None) - self.product_id = None - self.user_id = None - self.method = kwargs.get('method', None) - self.url = kwargs.get('url', None) - self.ip_address = kwargs.get('ip_address', None) - self.backend_response_code = kwargs.get('backend_response_code', None) - self.response_code = kwargs.get('response_code', None) - self.response_size = kwargs.get('response_size', None) - self.timestamp = kwargs.get('timestamp', None) - self.cache = kwargs.get('cache', None) - self.api_time = kwargs.get('api_time', None) - self.service_time = kwargs.get('service_time', None) - self.api_region = kwargs.get('api_region', None) - self.subscription_id = kwargs.get('subscription_id', None) - self.request_id = kwargs.get('request_id', None) - self.request_size = kwargs.get('request_size', None) diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/request_report_record_contract_paged.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/request_report_record_contract_paged.py deleted file mode 100644 index f5cc659ead9e..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/request_report_record_contract_paged.py +++ /dev/null @@ -1,27 +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.paging import Paged - - -class RequestReportRecordContractPaged(Paged): - """ - A paging container for iterating over a list of :class:`RequestReportRecordContract ` object - """ - - _attribute_map = { - 'next_link': {'key': 'nextLink', 'type': 'str'}, - 'current_page': {'key': 'value', 'type': '[RequestReportRecordContract]'} - } - - def __init__(self, *args, **kwargs): - - super(RequestReportRecordContractPaged, self).__init__(*args, **kwargs) diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/request_report_record_contract_py3.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/request_report_record_contract_py3.py deleted file mode 100644 index c1c1e53646d2..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/request_report_record_contract_py3.py +++ /dev/null @@ -1,114 +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 RequestReportRecordContract(Model): - """Request Report data. - - Variables are only populated by the server, and will be ignored when - sending a request. - - :param api_id: API identifier path. /apis/{apiId} - :type api_id: str - :param operation_id: Operation identifier path. - /apis/{apiId}/operations/{operationId} - :type operation_id: str - :ivar product_id: Product identifier path. /products/{productId} - :vartype product_id: str - :ivar user_id: User identifier path. /users/{userId} - :vartype user_id: str - :param method: The HTTP method associated with this request.. - :type method: str - :param url: The full URL associated with this request. - :type url: str - :param ip_address: The client IP address associated with this request. - :type ip_address: str - :param backend_response_code: The HTTP status code received by the gateway - as a result of forwarding this request to the backend. - :type backend_response_code: str - :param response_code: The HTTP status code returned by the gateway. - :type response_code: int - :param response_size: The size of the response returned by the gateway. - :type response_size: int - :param timestamp: The date and time when this request was received by the - gateway in ISO 8601 format. - :type timestamp: datetime - :param cache: Specifies if response cache was involved in generating the - response. If the value is none, the cache was not used. If the value is - hit, cached response was returned. If the value is miss, the cache was - used but lookup resulted in a miss and request was fulfilled by the - backend. - :type cache: str - :param api_time: The total time it took to process this request. - :type api_time: float - :param service_time: he time it took to forward this request to the - backend and get the response back. - :type service_time: float - :param api_region: Azure region where the gateway that processed this - request is located. - :type api_region: str - :param subscription_id: Subscription identifier path. - /subscriptions/{subscriptionId} - :type subscription_id: str - :param request_id: Request Identifier. - :type request_id: str - :param request_size: The size of this request.. - :type request_size: int - """ - - _validation = { - 'product_id': {'readonly': True}, - 'user_id': {'readonly': True}, - } - - _attribute_map = { - 'api_id': {'key': 'apiId', 'type': 'str'}, - 'operation_id': {'key': 'operationId', 'type': 'str'}, - 'product_id': {'key': 'productId', 'type': 'str'}, - 'user_id': {'key': 'userId', 'type': 'str'}, - 'method': {'key': 'method', 'type': 'str'}, - 'url': {'key': 'url', 'type': 'str'}, - 'ip_address': {'key': 'ipAddress', 'type': 'str'}, - 'backend_response_code': {'key': 'backendResponseCode', 'type': 'str'}, - 'response_code': {'key': 'responseCode', 'type': 'int'}, - 'response_size': {'key': 'responseSize', 'type': 'int'}, - 'timestamp': {'key': 'timestamp', 'type': 'iso-8601'}, - 'cache': {'key': 'cache', 'type': 'str'}, - 'api_time': {'key': 'apiTime', 'type': 'float'}, - 'service_time': {'key': 'serviceTime', 'type': 'float'}, - 'api_region': {'key': 'apiRegion', 'type': 'str'}, - 'subscription_id': {'key': 'subscriptionId', 'type': 'str'}, - 'request_id': {'key': 'requestId', 'type': 'str'}, - 'request_size': {'key': 'requestSize', 'type': 'int'}, - } - - def __init__(self, *, api_id: str=None, operation_id: str=None, method: str=None, url: str=None, ip_address: str=None, backend_response_code: str=None, response_code: int=None, response_size: int=None, timestamp=None, cache: str=None, api_time: float=None, service_time: float=None, api_region: str=None, subscription_id: str=None, request_id: str=None, request_size: int=None, **kwargs) -> None: - super(RequestReportRecordContract, self).__init__(**kwargs) - self.api_id = api_id - self.operation_id = operation_id - self.product_id = None - self.user_id = None - self.method = method - self.url = url - self.ip_address = ip_address - self.backend_response_code = backend_response_code - self.response_code = response_code - self.response_size = response_size - self.timestamp = timestamp - self.cache = cache - self.api_time = api_time - self.service_time = service_time - self.api_region = api_region - self.subscription_id = subscription_id - self.request_id = request_id - self.request_size = request_size diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/resource.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/resource.py deleted file mode 100644 index 228f9a4bad1a..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/resource.py +++ /dev/null @@ -1,45 +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 Resource(Model): - """The Resource definition. - - Variables are only populated by the server, and will be ignored when - sending a request. - - :ivar id: Resource ID. - :vartype id: str - :ivar name: Resource name. - :vartype name: str - :ivar type: Resource type for API Management resource. - :vartype type: str - """ - - _validation = { - 'id': {'readonly': True}, - 'name': {'readonly': True}, - 'type': {'readonly': True}, - } - - _attribute_map = { - 'id': {'key': 'id', 'type': 'str'}, - 'name': {'key': 'name', 'type': 'str'}, - 'type': {'key': 'type', 'type': 'str'}, - } - - def __init__(self, **kwargs): - super(Resource, self).__init__(**kwargs) - self.id = None - self.name = None - self.type = None diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/resource_py3.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/resource_py3.py deleted file mode 100644 index d847e3f57d60..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/resource_py3.py +++ /dev/null @@ -1,45 +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 Resource(Model): - """The Resource definition. - - Variables are only populated by the server, and will be ignored when - sending a request. - - :ivar id: Resource ID. - :vartype id: str - :ivar name: Resource name. - :vartype name: str - :ivar type: Resource type for API Management resource. - :vartype type: str - """ - - _validation = { - 'id': {'readonly': True}, - 'name': {'readonly': True}, - 'type': {'readonly': True}, - } - - _attribute_map = { - 'id': {'key': 'id', 'type': 'str'}, - 'name': {'key': 'name', 'type': 'str'}, - 'type': {'key': 'type', 'type': 'str'}, - } - - def __init__(self, **kwargs) -> None: - super(Resource, self).__init__(**kwargs) - self.id = None - self.name = None - self.type = None diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/resource_sku.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/resource_sku.py deleted file mode 100644 index c130ac57f637..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/resource_sku.py +++ /dev/null @@ -1,29 +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 ResourceSku(Model): - """Describes an available API Management SKU. - - :param name: Name of the Sku. Possible values include: 'Developer', - 'Standard', 'Premium', 'Basic', 'Consumption' - :type name: str or ~azure.mgmt.apimanagement.models.SkuType - """ - - _attribute_map = { - 'name': {'key': 'name', 'type': 'str'}, - } - - def __init__(self, **kwargs): - super(ResourceSku, self).__init__(**kwargs) - self.name = kwargs.get('name', None) diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/resource_sku_capacity.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/resource_sku_capacity.py deleted file mode 100644 index 54109ac235b1..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/resource_sku_capacity.py +++ /dev/null @@ -1,52 +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 ResourceSkuCapacity(Model): - """Describes scaling information of a SKU. - - Variables are only populated by the server, and will be ignored when - sending a request. - - :ivar minimum: The minimum capacity. - :vartype minimum: int - :ivar maximum: The maximum capacity that can be set. - :vartype maximum: int - :ivar default: The default capacity. - :vartype default: int - :ivar scale_type: The scale type applicable to the sku. Possible values - include: 'automatic', 'manual', 'none' - :vartype scale_type: str or - ~azure.mgmt.apimanagement.models.ResourceSkuCapacityScaleType - """ - - _validation = { - 'minimum': {'readonly': True}, - 'maximum': {'readonly': True}, - 'default': {'readonly': True}, - 'scale_type': {'readonly': True}, - } - - _attribute_map = { - 'minimum': {'key': 'minimum', 'type': 'int'}, - 'maximum': {'key': 'maximum', 'type': 'int'}, - 'default': {'key': 'default', 'type': 'int'}, - 'scale_type': {'key': 'scaleType', 'type': 'str'}, - } - - def __init__(self, **kwargs): - super(ResourceSkuCapacity, self).__init__(**kwargs) - self.minimum = None - self.maximum = None - self.default = None - self.scale_type = None diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/resource_sku_capacity_py3.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/resource_sku_capacity_py3.py deleted file mode 100644 index 27d799babc94..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/resource_sku_capacity_py3.py +++ /dev/null @@ -1,52 +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 ResourceSkuCapacity(Model): - """Describes scaling information of a SKU. - - Variables are only populated by the server, and will be ignored when - sending a request. - - :ivar minimum: The minimum capacity. - :vartype minimum: int - :ivar maximum: The maximum capacity that can be set. - :vartype maximum: int - :ivar default: The default capacity. - :vartype default: int - :ivar scale_type: The scale type applicable to the sku. Possible values - include: 'automatic', 'manual', 'none' - :vartype scale_type: str or - ~azure.mgmt.apimanagement.models.ResourceSkuCapacityScaleType - """ - - _validation = { - 'minimum': {'readonly': True}, - 'maximum': {'readonly': True}, - 'default': {'readonly': True}, - 'scale_type': {'readonly': True}, - } - - _attribute_map = { - 'minimum': {'key': 'minimum', 'type': 'int'}, - 'maximum': {'key': 'maximum', 'type': 'int'}, - 'default': {'key': 'default', 'type': 'int'}, - 'scale_type': {'key': 'scaleType', 'type': 'str'}, - } - - def __init__(self, **kwargs) -> None: - super(ResourceSkuCapacity, self).__init__(**kwargs) - self.minimum = None - self.maximum = None - self.default = None - self.scale_type = None diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/resource_sku_py3.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/resource_sku_py3.py deleted file mode 100644 index 7e30812cefcd..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/resource_sku_py3.py +++ /dev/null @@ -1,29 +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 ResourceSku(Model): - """Describes an available API Management SKU. - - :param name: Name of the Sku. Possible values include: 'Developer', - 'Standard', 'Premium', 'Basic', 'Consumption' - :type name: str or ~azure.mgmt.apimanagement.models.SkuType - """ - - _attribute_map = { - 'name': {'key': 'name', 'type': 'str'}, - } - - def __init__(self, *, name=None, **kwargs) -> None: - super(ResourceSku, self).__init__(**kwargs) - self.name = name diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/resource_sku_result.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/resource_sku_result.py deleted file mode 100644 index 7457c7bd9d0f..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/resource_sku_result.py +++ /dev/null @@ -1,45 +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 ResourceSkuResult(Model): - """Describes an available API Management service SKU. - - Variables are only populated by the server, and will be ignored when - sending a request. - - :ivar resource_type: The type of resource the SKU applies to. - :vartype resource_type: str - :ivar sku: Specifies API Management SKU. - :vartype sku: ~azure.mgmt.apimanagement.models.ResourceSku - :ivar capacity: Specifies the number of API Management units. - :vartype capacity: ~azure.mgmt.apimanagement.models.ResourceSkuCapacity - """ - - _validation = { - 'resource_type': {'readonly': True}, - 'sku': {'readonly': True}, - 'capacity': {'readonly': True}, - } - - _attribute_map = { - 'resource_type': {'key': 'resourceType', 'type': 'str'}, - 'sku': {'key': 'sku', 'type': 'ResourceSku'}, - 'capacity': {'key': 'capacity', 'type': 'ResourceSkuCapacity'}, - } - - def __init__(self, **kwargs): - super(ResourceSkuResult, self).__init__(**kwargs) - self.resource_type = None - self.sku = None - self.capacity = None diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/resource_sku_result_paged.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/resource_sku_result_paged.py deleted file mode 100644 index 1a888249f3d9..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/resource_sku_result_paged.py +++ /dev/null @@ -1,27 +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.paging import Paged - - -class ResourceSkuResultPaged(Paged): - """ - A paging container for iterating over a list of :class:`ResourceSkuResult ` object - """ - - _attribute_map = { - 'next_link': {'key': 'nextLink', 'type': 'str'}, - 'current_page': {'key': 'value', 'type': '[ResourceSkuResult]'} - } - - def __init__(self, *args, **kwargs): - - super(ResourceSkuResultPaged, self).__init__(*args, **kwargs) diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/resource_sku_result_py3.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/resource_sku_result_py3.py deleted file mode 100644 index 2a35b75ee655..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/resource_sku_result_py3.py +++ /dev/null @@ -1,45 +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 ResourceSkuResult(Model): - """Describes an available API Management service SKU. - - Variables are only populated by the server, and will be ignored when - sending a request. - - :ivar resource_type: The type of resource the SKU applies to. - :vartype resource_type: str - :ivar sku: Specifies API Management SKU. - :vartype sku: ~azure.mgmt.apimanagement.models.ResourceSku - :ivar capacity: Specifies the number of API Management units. - :vartype capacity: ~azure.mgmt.apimanagement.models.ResourceSkuCapacity - """ - - _validation = { - 'resource_type': {'readonly': True}, - 'sku': {'readonly': True}, - 'capacity': {'readonly': True}, - } - - _attribute_map = { - 'resource_type': {'key': 'resourceType', 'type': 'str'}, - 'sku': {'key': 'sku', 'type': 'ResourceSku'}, - 'capacity': {'key': 'capacity', 'type': 'ResourceSkuCapacity'}, - } - - def __init__(self, **kwargs) -> None: - super(ResourceSkuResult, self).__init__(**kwargs) - self.resource_type = None - self.sku = None - self.capacity = None diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/response_contract.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/response_contract.py deleted file mode 100644 index 511adab1f030..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/response_contract.py +++ /dev/null @@ -1,47 +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 ResponseContract(Model): - """Operation response details. - - All required parameters must be populated in order to send to Azure. - - :param status_code: Required. Operation response HTTP status code. - :type status_code: int - :param description: Operation response description. - :type description: str - :param representations: Collection of operation response representations. - :type representations: - list[~azure.mgmt.apimanagement.models.RepresentationContract] - :param headers: Collection of operation response headers. - :type headers: list[~azure.mgmt.apimanagement.models.ParameterContract] - """ - - _validation = { - 'status_code': {'required': True}, - } - - _attribute_map = { - 'status_code': {'key': 'statusCode', 'type': 'int'}, - 'description': {'key': 'description', 'type': 'str'}, - 'representations': {'key': 'representations', 'type': '[RepresentationContract]'}, - 'headers': {'key': 'headers', 'type': '[ParameterContract]'}, - } - - def __init__(self, **kwargs): - super(ResponseContract, self).__init__(**kwargs) - self.status_code = kwargs.get('status_code', None) - self.description = kwargs.get('description', None) - self.representations = kwargs.get('representations', None) - self.headers = kwargs.get('headers', None) diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/response_contract_py3.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/response_contract_py3.py deleted file mode 100644 index e2101f5e2c26..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/response_contract_py3.py +++ /dev/null @@ -1,47 +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 ResponseContract(Model): - """Operation response details. - - All required parameters must be populated in order to send to Azure. - - :param status_code: Required. Operation response HTTP status code. - :type status_code: int - :param description: Operation response description. - :type description: str - :param representations: Collection of operation response representations. - :type representations: - list[~azure.mgmt.apimanagement.models.RepresentationContract] - :param headers: Collection of operation response headers. - :type headers: list[~azure.mgmt.apimanagement.models.ParameterContract] - """ - - _validation = { - 'status_code': {'required': True}, - } - - _attribute_map = { - 'status_code': {'key': 'statusCode', 'type': 'int'}, - 'description': {'key': 'description', 'type': 'str'}, - 'representations': {'key': 'representations', 'type': '[RepresentationContract]'}, - 'headers': {'key': 'headers', 'type': '[ParameterContract]'}, - } - - def __init__(self, *, status_code: int, description: str=None, representations=None, headers=None, **kwargs) -> None: - super(ResponseContract, self).__init__(**kwargs) - self.status_code = status_code - self.description = description - self.representations = representations - self.headers = headers diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/sampling_settings.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/sampling_settings.py deleted file mode 100644 index c773f5b593b1..000000000000 --- a/sdk/apimanagement/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/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/sampling_settings_py3.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/sampling_settings_py3.py deleted file mode 100644 index 544dbda52a7f..000000000000 --- a/sdk/apimanagement/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/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/save_configuration_parameter.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/save_configuration_parameter.py deleted file mode 100644 index 0350003491c4..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/save_configuration_parameter.py +++ /dev/null @@ -1,41 +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 SaveConfigurationParameter(Model): - """Save Tenant Configuration Contract details. - - All required parameters must be populated in order to send to Azure. - - :param branch: Required. The name of the Git branch in which to commit the - current configuration snapshot. - :type branch: str - :param force: The value if true, the current configuration database is - committed to the Git repository, even if the Git repository has newer - changes that would be overwritten. - :type force: bool - """ - - _validation = { - 'branch': {'required': True}, - } - - _attribute_map = { - 'branch': {'key': 'properties.branch', 'type': 'str'}, - 'force': {'key': 'properties.force', 'type': 'bool'}, - } - - def __init__(self, **kwargs): - super(SaveConfigurationParameter, self).__init__(**kwargs) - self.branch = kwargs.get('branch', None) - self.force = kwargs.get('force', None) diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/save_configuration_parameter_py3.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/save_configuration_parameter_py3.py deleted file mode 100644 index fb5acd418212..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/save_configuration_parameter_py3.py +++ /dev/null @@ -1,41 +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 SaveConfigurationParameter(Model): - """Save Tenant Configuration Contract details. - - All required parameters must be populated in order to send to Azure. - - :param branch: Required. The name of the Git branch in which to commit the - current configuration snapshot. - :type branch: str - :param force: The value if true, the current configuration database is - committed to the Git repository, even if the Git repository has newer - changes that would be overwritten. - :type force: bool - """ - - _validation = { - 'branch': {'required': True}, - } - - _attribute_map = { - 'branch': {'key': 'properties.branch', 'type': 'str'}, - 'force': {'key': 'properties.force', 'type': 'bool'}, - } - - def __init__(self, *, branch: str, force: bool=None, **kwargs) -> None: - super(SaveConfigurationParameter, self).__init__(**kwargs) - self.branch = branch - self.force = force diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/schema_contract.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/schema_contract.py deleted file mode 100644 index 03ea8798496d..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/schema_contract.py +++ /dev/null @@ -1,59 +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 .resource import Resource - - -class SchemaContract(Resource): - """Schema Contract details. - - Variables are only populated by the server, and will be ignored when - sending a request. - - All required parameters must be populated in order to send to Azure. - - :ivar id: Resource ID. - :vartype id: str - :ivar name: Resource name. - :vartype name: str - :ivar type: Resource type for API Management resource. - :vartype type: str - :param content_type: Required. Must be a valid a media type used in a - Content-Type header as defined in the RFC 2616. Media type of the schema - document (e.g. application/json, application/xml).
- `Swagger` - Schema use `application/vnd.ms-azure-apim.swagger.definitions+json`
- - `WSDL` Schema use `application/vnd.ms-azure-apim.xsd+xml`
- - `OpenApi` Schema use `application/vnd.oai.openapi.components+json`
- - `WADL Schema` use `application/vnd.ms-azure-apim.wadl.grammars+xml`. - :type content_type: str - :param document: Properties of the Schema Document. - :type document: object - """ - - _validation = { - 'id': {'readonly': True}, - 'name': {'readonly': True}, - 'type': {'readonly': True}, - 'content_type': {'required': True}, - } - - _attribute_map = { - 'id': {'key': 'id', 'type': 'str'}, - 'name': {'key': 'name', 'type': 'str'}, - 'type': {'key': 'type', 'type': 'str'}, - 'content_type': {'key': 'properties.contentType', 'type': 'str'}, - 'document': {'key': 'properties.document', 'type': 'object'}, - } - - def __init__(self, **kwargs): - super(SchemaContract, self).__init__(**kwargs) - self.content_type = kwargs.get('content_type', None) - self.document = kwargs.get('document', None) diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/schema_contract_paged.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/schema_contract_paged.py deleted file mode 100644 index 7c89d8c021ee..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/schema_contract_paged.py +++ /dev/null @@ -1,27 +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.paging import Paged - - -class SchemaContractPaged(Paged): - """ - A paging container for iterating over a list of :class:`SchemaContract ` object - """ - - _attribute_map = { - 'next_link': {'key': 'nextLink', 'type': 'str'}, - 'current_page': {'key': 'value', 'type': '[SchemaContract]'} - } - - def __init__(self, *args, **kwargs): - - super(SchemaContractPaged, self).__init__(*args, **kwargs) diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/schema_contract_py3.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/schema_contract_py3.py deleted file mode 100644 index bde8934130e2..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/schema_contract_py3.py +++ /dev/null @@ -1,59 +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 .resource_py3 import Resource - - -class SchemaContract(Resource): - """Schema Contract details. - - Variables are only populated by the server, and will be ignored when - sending a request. - - All required parameters must be populated in order to send to Azure. - - :ivar id: Resource ID. - :vartype id: str - :ivar name: Resource name. - :vartype name: str - :ivar type: Resource type for API Management resource. - :vartype type: str - :param content_type: Required. Must be a valid a media type used in a - Content-Type header as defined in the RFC 2616. Media type of the schema - document (e.g. application/json, application/xml).
- `Swagger` - Schema use `application/vnd.ms-azure-apim.swagger.definitions+json`
- - `WSDL` Schema use `application/vnd.ms-azure-apim.xsd+xml`
- - `OpenApi` Schema use `application/vnd.oai.openapi.components+json`
- - `WADL Schema` use `application/vnd.ms-azure-apim.wadl.grammars+xml`. - :type content_type: str - :param document: Properties of the Schema Document. - :type document: object - """ - - _validation = { - 'id': {'readonly': True}, - 'name': {'readonly': True}, - 'type': {'readonly': True}, - 'content_type': {'required': True}, - } - - _attribute_map = { - 'id': {'key': 'id', 'type': 'str'}, - 'name': {'key': 'name', 'type': 'str'}, - 'type': {'key': 'type', 'type': 'str'}, - 'content_type': {'key': 'properties.contentType', 'type': 'str'}, - 'document': {'key': 'properties.document', 'type': 'object'}, - } - - def __init__(self, *, content_type: str, document=None, **kwargs) -> None: - super(SchemaContract, self).__init__(**kwargs) - self.content_type = content_type - self.document = document diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/schema_create_or_update_contract.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/schema_create_or_update_contract.py deleted file mode 100644 index c22e78058a1e..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/schema_create_or_update_contract.py +++ /dev/null @@ -1,60 +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 .resource import Resource - - -class SchemaCreateOrUpdateContract(Resource): - """Schema Contract details. - - Variables are only populated by the server, and will be ignored when - sending a request. - - All required parameters must be populated in order to send to Azure. - - :ivar id: Resource ID. - :vartype id: str - :ivar name: Resource name. - :vartype name: str - :ivar type: Resource type for API Management resource. - :vartype type: str - :param content_type: Required. Must be a valid a media type used in a - Content-Type header as defined in the RFC 2616. Media type of the schema - document (e.g. application/json, application/xml).
- `Swagger` - Schema use `application/vnd.ms-azure-apim.swagger.definitions+json`
- - `WSDL` Schema use `application/vnd.ms-azure-apim.xsd+xml`
- - `OpenApi` Schema use `application/vnd.oai.openapi.components+json`
- - `WADL Schema` use `application/vnd.ms-azure-apim.wadl.grammars+xml`. - :type content_type: str - :param value: Json escaped string defining the document representing the - Schema. - :type value: str - """ - - _validation = { - 'id': {'readonly': True}, - 'name': {'readonly': True}, - 'type': {'readonly': True}, - 'content_type': {'required': True}, - } - - _attribute_map = { - 'id': {'key': 'id', 'type': 'str'}, - 'name': {'key': 'name', 'type': 'str'}, - 'type': {'key': 'type', 'type': 'str'}, - 'content_type': {'key': 'properties.contentType', 'type': 'str'}, - 'value': {'key': 'properties.document.value', 'type': 'str'}, - } - - def __init__(self, **kwargs): - super(SchemaCreateOrUpdateContract, self).__init__(**kwargs) - self.content_type = kwargs.get('content_type', None) - self.value = kwargs.get('value', None) diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/schema_create_or_update_contract_py3.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/schema_create_or_update_contract_py3.py deleted file mode 100644 index 75aa161af9b8..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/schema_create_or_update_contract_py3.py +++ /dev/null @@ -1,60 +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 .resource_py3 import Resource - - -class SchemaCreateOrUpdateContract(Resource): - """Schema Contract details. - - Variables are only populated by the server, and will be ignored when - sending a request. - - All required parameters must be populated in order to send to Azure. - - :ivar id: Resource ID. - :vartype id: str - :ivar name: Resource name. - :vartype name: str - :ivar type: Resource type for API Management resource. - :vartype type: str - :param content_type: Required. Must be a valid a media type used in a - Content-Type header as defined in the RFC 2616. Media type of the schema - document (e.g. application/json, application/xml).
- `Swagger` - Schema use `application/vnd.ms-azure-apim.swagger.definitions+json`
- - `WSDL` Schema use `application/vnd.ms-azure-apim.xsd+xml`
- - `OpenApi` Schema use `application/vnd.oai.openapi.components+json`
- - `WADL Schema` use `application/vnd.ms-azure-apim.wadl.grammars+xml`. - :type content_type: str - :param value: Json escaped string defining the document representing the - Schema. - :type value: str - """ - - _validation = { - 'id': {'readonly': True}, - 'name': {'readonly': True}, - 'type': {'readonly': True}, - 'content_type': {'required': True}, - } - - _attribute_map = { - 'id': {'key': 'id', 'type': 'str'}, - 'name': {'key': 'name', 'type': 'str'}, - 'type': {'key': 'type', 'type': 'str'}, - 'content_type': {'key': 'properties.contentType', 'type': 'str'}, - 'value': {'key': 'properties.document.value', 'type': 'str'}, - } - - def __init__(self, *, content_type: str, value: str=None, **kwargs) -> None: - super(SchemaCreateOrUpdateContract, self).__init__(**kwargs) - self.content_type = content_type - self.value = value diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/subscription_contract.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/subscription_contract.py deleted file mode 100644 index 98d716699780..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/subscription_contract.py +++ /dev/null @@ -1,131 +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 .resource import Resource - - -class SubscriptionContract(Resource): - """Subscription details. - - Variables are only populated by the server, and will be ignored when - sending a request. - - All required parameters must be populated in order to send to Azure. - - :ivar id: Resource ID. - :vartype id: str - :ivar name: Resource name. - :vartype name: str - :ivar type: Resource type for API Management resource. - :vartype type: str - :param owner_id: The user resource identifier of the subscription owner. - The value is a valid relative URL in the format of /users/{userId} where - {userId} is a user identifier. - :type owner_id: str - :param scope: Required. Scope like /products/{productId} or /apis or - /apis/{apiId}. - :type scope: str - :param display_name: The name of the subscription, or null if the - subscription has no name. - :type display_name: str - :param state: Required. Subscription state. Possible states are * active – - the subscription is active, * suspended – the subscription is blocked, and - the subscriber cannot call any APIs of the product, * submitted – the - subscription request has been made by the developer, but has not yet been - approved or rejected, * rejected – the subscription request has been - denied by an administrator, * cancelled – the subscription has been - cancelled by the developer or administrator, * expired – the subscription - reached its expiration date and was deactivated. Possible values include: - 'suspended', 'active', 'expired', 'submitted', 'rejected', 'cancelled' - :type state: str or ~azure.mgmt.apimanagement.models.SubscriptionState - :ivar created_date: Subscription creation date. The date conforms to the - following format: `yyyy-MM-ddTHH:mm:ssZ` as specified by the ISO 8601 - standard. - :vartype created_date: datetime - :param start_date: Subscription activation date. The setting is for audit - purposes only and the subscription is not automatically activated. The - subscription lifecycle can be managed by using the `state` property. The - date conforms to the following format: `yyyy-MM-ddTHH:mm:ssZ` as specified - by the ISO 8601 standard. - :type start_date: datetime - :param expiration_date: Subscription expiration date. The setting is for - audit purposes only and the subscription is not automatically expired. The - subscription lifecycle can be managed by using the `state` property. The - date conforms to the following format: `yyyy-MM-ddTHH:mm:ssZ` as specified - by the ISO 8601 standard. - :type expiration_date: datetime - :param end_date: Date when subscription was cancelled or expired. The - setting is for audit purposes only and the subscription is not - automatically cancelled. The subscription lifecycle can be managed by - using the `state` property. The date conforms to the following format: - `yyyy-MM-ddTHH:mm:ssZ` as specified by the ISO 8601 standard. - :type end_date: datetime - :param notification_date: Upcoming subscription expiration notification - date. The date conforms to the following format: `yyyy-MM-ddTHH:mm:ssZ` as - specified by the ISO 8601 standard. - :type notification_date: datetime - :param primary_key: Required. Subscription primary key. - :type primary_key: str - :param secondary_key: Required. Subscription secondary key. - :type secondary_key: str - :param state_comment: Optional subscription comment added by an - administrator. - :type state_comment: str - :param allow_tracing: Determines whether tracing is enabled - :type allow_tracing: bool - """ - - _validation = { - 'id': {'readonly': True}, - 'name': {'readonly': True}, - 'type': {'readonly': True}, - 'scope': {'required': True}, - 'display_name': {'max_length': 100, 'min_length': 0}, - 'state': {'required': True}, - 'created_date': {'readonly': True}, - 'primary_key': {'required': True, 'max_length': 256, 'min_length': 1}, - 'secondary_key': {'required': True, 'max_length': 256, 'min_length': 1}, - } - - _attribute_map = { - 'id': {'key': 'id', 'type': 'str'}, - 'name': {'key': 'name', 'type': 'str'}, - 'type': {'key': 'type', 'type': 'str'}, - 'owner_id': {'key': 'properties.ownerId', 'type': 'str'}, - 'scope': {'key': 'properties.scope', 'type': 'str'}, - 'display_name': {'key': 'properties.displayName', 'type': 'str'}, - 'state': {'key': 'properties.state', 'type': 'SubscriptionState'}, - 'created_date': {'key': 'properties.createdDate', 'type': 'iso-8601'}, - 'start_date': {'key': 'properties.startDate', 'type': 'iso-8601'}, - 'expiration_date': {'key': 'properties.expirationDate', 'type': 'iso-8601'}, - 'end_date': {'key': 'properties.endDate', 'type': 'iso-8601'}, - 'notification_date': {'key': 'properties.notificationDate', 'type': 'iso-8601'}, - 'primary_key': {'key': 'properties.primaryKey', 'type': 'str'}, - 'secondary_key': {'key': 'properties.secondaryKey', 'type': 'str'}, - 'state_comment': {'key': 'properties.stateComment', 'type': 'str'}, - 'allow_tracing': {'key': 'properties.allowTracing', 'type': 'bool'}, - } - - def __init__(self, **kwargs): - super(SubscriptionContract, self).__init__(**kwargs) - self.owner_id = kwargs.get('owner_id', None) - self.scope = kwargs.get('scope', None) - self.display_name = kwargs.get('display_name', None) - self.state = kwargs.get('state', None) - self.created_date = None - self.start_date = kwargs.get('start_date', None) - self.expiration_date = kwargs.get('expiration_date', None) - self.end_date = kwargs.get('end_date', None) - self.notification_date = kwargs.get('notification_date', None) - self.primary_key = kwargs.get('primary_key', None) - self.secondary_key = kwargs.get('secondary_key', None) - self.state_comment = kwargs.get('state_comment', None) - self.allow_tracing = kwargs.get('allow_tracing', None) diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/subscription_contract_paged.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/subscription_contract_paged.py deleted file mode 100644 index b781048674f1..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/subscription_contract_paged.py +++ /dev/null @@ -1,27 +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.paging import Paged - - -class SubscriptionContractPaged(Paged): - """ - A paging container for iterating over a list of :class:`SubscriptionContract ` object - """ - - _attribute_map = { - 'next_link': {'key': 'nextLink', 'type': 'str'}, - 'current_page': {'key': 'value', 'type': '[SubscriptionContract]'} - } - - def __init__(self, *args, **kwargs): - - super(SubscriptionContractPaged, self).__init__(*args, **kwargs) diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/subscription_contract_py3.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/subscription_contract_py3.py deleted file mode 100644 index 3735162a4c76..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/subscription_contract_py3.py +++ /dev/null @@ -1,131 +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 .resource_py3 import Resource - - -class SubscriptionContract(Resource): - """Subscription details. - - Variables are only populated by the server, and will be ignored when - sending a request. - - All required parameters must be populated in order to send to Azure. - - :ivar id: Resource ID. - :vartype id: str - :ivar name: Resource name. - :vartype name: str - :ivar type: Resource type for API Management resource. - :vartype type: str - :param owner_id: The user resource identifier of the subscription owner. - The value is a valid relative URL in the format of /users/{userId} where - {userId} is a user identifier. - :type owner_id: str - :param scope: Required. Scope like /products/{productId} or /apis or - /apis/{apiId}. - :type scope: str - :param display_name: The name of the subscription, or null if the - subscription has no name. - :type display_name: str - :param state: Required. Subscription state. Possible states are * active – - the subscription is active, * suspended – the subscription is blocked, and - the subscriber cannot call any APIs of the product, * submitted – the - subscription request has been made by the developer, but has not yet been - approved or rejected, * rejected – the subscription request has been - denied by an administrator, * cancelled – the subscription has been - cancelled by the developer or administrator, * expired – the subscription - reached its expiration date and was deactivated. Possible values include: - 'suspended', 'active', 'expired', 'submitted', 'rejected', 'cancelled' - :type state: str or ~azure.mgmt.apimanagement.models.SubscriptionState - :ivar created_date: Subscription creation date. The date conforms to the - following format: `yyyy-MM-ddTHH:mm:ssZ` as specified by the ISO 8601 - standard. - :vartype created_date: datetime - :param start_date: Subscription activation date. The setting is for audit - purposes only and the subscription is not automatically activated. The - subscription lifecycle can be managed by using the `state` property. The - date conforms to the following format: `yyyy-MM-ddTHH:mm:ssZ` as specified - by the ISO 8601 standard. - :type start_date: datetime - :param expiration_date: Subscription expiration date. The setting is for - audit purposes only and the subscription is not automatically expired. The - subscription lifecycle can be managed by using the `state` property. The - date conforms to the following format: `yyyy-MM-ddTHH:mm:ssZ` as specified - by the ISO 8601 standard. - :type expiration_date: datetime - :param end_date: Date when subscription was cancelled or expired. The - setting is for audit purposes only and the subscription is not - automatically cancelled. The subscription lifecycle can be managed by - using the `state` property. The date conforms to the following format: - `yyyy-MM-ddTHH:mm:ssZ` as specified by the ISO 8601 standard. - :type end_date: datetime - :param notification_date: Upcoming subscription expiration notification - date. The date conforms to the following format: `yyyy-MM-ddTHH:mm:ssZ` as - specified by the ISO 8601 standard. - :type notification_date: datetime - :param primary_key: Required. Subscription primary key. - :type primary_key: str - :param secondary_key: Required. Subscription secondary key. - :type secondary_key: str - :param state_comment: Optional subscription comment added by an - administrator. - :type state_comment: str - :param allow_tracing: Determines whether tracing is enabled - :type allow_tracing: bool - """ - - _validation = { - 'id': {'readonly': True}, - 'name': {'readonly': True}, - 'type': {'readonly': True}, - 'scope': {'required': True}, - 'display_name': {'max_length': 100, 'min_length': 0}, - 'state': {'required': True}, - 'created_date': {'readonly': True}, - 'primary_key': {'required': True, 'max_length': 256, 'min_length': 1}, - 'secondary_key': {'required': True, 'max_length': 256, 'min_length': 1}, - } - - _attribute_map = { - 'id': {'key': 'id', 'type': 'str'}, - 'name': {'key': 'name', 'type': 'str'}, - 'type': {'key': 'type', 'type': 'str'}, - 'owner_id': {'key': 'properties.ownerId', 'type': 'str'}, - 'scope': {'key': 'properties.scope', 'type': 'str'}, - 'display_name': {'key': 'properties.displayName', 'type': 'str'}, - 'state': {'key': 'properties.state', 'type': 'SubscriptionState'}, - 'created_date': {'key': 'properties.createdDate', 'type': 'iso-8601'}, - 'start_date': {'key': 'properties.startDate', 'type': 'iso-8601'}, - 'expiration_date': {'key': 'properties.expirationDate', 'type': 'iso-8601'}, - 'end_date': {'key': 'properties.endDate', 'type': 'iso-8601'}, - 'notification_date': {'key': 'properties.notificationDate', 'type': 'iso-8601'}, - 'primary_key': {'key': 'properties.primaryKey', 'type': 'str'}, - 'secondary_key': {'key': 'properties.secondaryKey', 'type': 'str'}, - 'state_comment': {'key': 'properties.stateComment', 'type': 'str'}, - 'allow_tracing': {'key': 'properties.allowTracing', 'type': 'bool'}, - } - - def __init__(self, *, scope: str, state, primary_key: str, secondary_key: str, owner_id: str=None, display_name: str=None, start_date=None, expiration_date=None, end_date=None, notification_date=None, state_comment: str=None, allow_tracing: bool=None, **kwargs) -> None: - super(SubscriptionContract, self).__init__(**kwargs) - self.owner_id = owner_id - self.scope = scope - self.display_name = display_name - self.state = state - self.created_date = None - self.start_date = start_date - self.expiration_date = expiration_date - self.end_date = end_date - self.notification_date = notification_date - self.primary_key = primary_key - self.secondary_key = secondary_key - self.state_comment = state_comment - self.allow_tracing = allow_tracing diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/subscription_create_parameters.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/subscription_create_parameters.py deleted file mode 100644 index 9d5789c6a4a4..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/subscription_create_parameters.py +++ /dev/null @@ -1,74 +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 SubscriptionCreateParameters(Model): - """Subscription create details. - - All required parameters must be populated in order to send to Azure. - - :param owner_id: User (user id path) for whom subscription is being - created in form /users/{userId} - :type owner_id: str - :param scope: Required. Scope like /products/{productId} or /apis or - /apis/{apiId}. - :type scope: str - :param display_name: Required. Subscription name. - :type display_name: str - :param primary_key: Primary subscription key. If not specified during - request key will be generated automatically. - :type primary_key: str - :param secondary_key: Secondary subscription key. If not specified during - request key will be generated automatically. - :type secondary_key: str - :param state: Initial subscription state. If no value is specified, - subscription is created with Submitted state. Possible states are * active - – the subscription is active, * suspended – the subscription is blocked, - and the subscriber cannot call any APIs of the product, * submitted – the - subscription request has been made by the developer, but has not yet been - approved or rejected, * rejected – the subscription request has been - denied by an administrator, * cancelled – the subscription has been - cancelled by the developer or administrator, * expired – the subscription - reached its expiration date and was deactivated. Possible values include: - 'suspended', 'active', 'expired', 'submitted', 'rejected', 'cancelled' - :type state: str or ~azure.mgmt.apimanagement.models.SubscriptionState - :param allow_tracing: Determines whether tracing can be enabled - :type allow_tracing: bool - """ - - _validation = { - 'scope': {'required': True}, - 'display_name': {'required': True, 'max_length': 100, 'min_length': 1}, - 'primary_key': {'max_length': 256, 'min_length': 1}, - 'secondary_key': {'max_length': 256, 'min_length': 1}, - } - - _attribute_map = { - 'owner_id': {'key': 'properties.ownerId', 'type': 'str'}, - 'scope': {'key': 'properties.scope', 'type': 'str'}, - 'display_name': {'key': 'properties.displayName', 'type': 'str'}, - 'primary_key': {'key': 'properties.primaryKey', 'type': 'str'}, - 'secondary_key': {'key': 'properties.secondaryKey', 'type': 'str'}, - 'state': {'key': 'properties.state', 'type': 'SubscriptionState'}, - 'allow_tracing': {'key': 'properties.allowTracing', 'type': 'bool'}, - } - - def __init__(self, **kwargs): - super(SubscriptionCreateParameters, self).__init__(**kwargs) - self.owner_id = kwargs.get('owner_id', None) - self.scope = kwargs.get('scope', None) - self.display_name = kwargs.get('display_name', None) - self.primary_key = kwargs.get('primary_key', None) - self.secondary_key = kwargs.get('secondary_key', None) - self.state = kwargs.get('state', None) - self.allow_tracing = kwargs.get('allow_tracing', None) diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/subscription_create_parameters_py3.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/subscription_create_parameters_py3.py deleted file mode 100644 index 10eac288ec91..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/subscription_create_parameters_py3.py +++ /dev/null @@ -1,74 +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 SubscriptionCreateParameters(Model): - """Subscription create details. - - All required parameters must be populated in order to send to Azure. - - :param owner_id: User (user id path) for whom subscription is being - created in form /users/{userId} - :type owner_id: str - :param scope: Required. Scope like /products/{productId} or /apis or - /apis/{apiId}. - :type scope: str - :param display_name: Required. Subscription name. - :type display_name: str - :param primary_key: Primary subscription key. If not specified during - request key will be generated automatically. - :type primary_key: str - :param secondary_key: Secondary subscription key. If not specified during - request key will be generated automatically. - :type secondary_key: str - :param state: Initial subscription state. If no value is specified, - subscription is created with Submitted state. Possible states are * active - – the subscription is active, * suspended – the subscription is blocked, - and the subscriber cannot call any APIs of the product, * submitted – the - subscription request has been made by the developer, but has not yet been - approved or rejected, * rejected – the subscription request has been - denied by an administrator, * cancelled – the subscription has been - cancelled by the developer or administrator, * expired – the subscription - reached its expiration date and was deactivated. Possible values include: - 'suspended', 'active', 'expired', 'submitted', 'rejected', 'cancelled' - :type state: str or ~azure.mgmt.apimanagement.models.SubscriptionState - :param allow_tracing: Determines whether tracing can be enabled - :type allow_tracing: bool - """ - - _validation = { - 'scope': {'required': True}, - 'display_name': {'required': True, 'max_length': 100, 'min_length': 1}, - 'primary_key': {'max_length': 256, 'min_length': 1}, - 'secondary_key': {'max_length': 256, 'min_length': 1}, - } - - _attribute_map = { - 'owner_id': {'key': 'properties.ownerId', 'type': 'str'}, - 'scope': {'key': 'properties.scope', 'type': 'str'}, - 'display_name': {'key': 'properties.displayName', 'type': 'str'}, - 'primary_key': {'key': 'properties.primaryKey', 'type': 'str'}, - 'secondary_key': {'key': 'properties.secondaryKey', 'type': 'str'}, - 'state': {'key': 'properties.state', 'type': 'SubscriptionState'}, - 'allow_tracing': {'key': 'properties.allowTracing', 'type': 'bool'}, - } - - def __init__(self, *, scope: str, display_name: str, owner_id: str=None, primary_key: str=None, secondary_key: str=None, state=None, allow_tracing: bool=None, **kwargs) -> None: - super(SubscriptionCreateParameters, self).__init__(**kwargs) - self.owner_id = owner_id - self.scope = scope - self.display_name = display_name - self.primary_key = primary_key - self.secondary_key = secondary_key - self.state = state - self.allow_tracing = allow_tracing diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/subscription_key_parameter_names_contract.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/subscription_key_parameter_names_contract.py deleted file mode 100644 index f211ba47878c..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/subscription_key_parameter_names_contract.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 SubscriptionKeyParameterNamesContract(Model): - """Subscription key parameter names details. - - :param header: Subscription key header name. - :type header: str - :param query: Subscription key query string parameter name. - :type query: str - """ - - _attribute_map = { - 'header': {'key': 'header', 'type': 'str'}, - 'query': {'key': 'query', 'type': 'str'}, - } - - def __init__(self, **kwargs): - super(SubscriptionKeyParameterNamesContract, self).__init__(**kwargs) - self.header = kwargs.get('header', None) - self.query = kwargs.get('query', None) diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/subscription_key_parameter_names_contract_py3.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/subscription_key_parameter_names_contract_py3.py deleted file mode 100644 index b1163f189a3f..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/subscription_key_parameter_names_contract_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 SubscriptionKeyParameterNamesContract(Model): - """Subscription key parameter names details. - - :param header: Subscription key header name. - :type header: str - :param query: Subscription key query string parameter name. - :type query: str - """ - - _attribute_map = { - 'header': {'key': 'header', 'type': 'str'}, - 'query': {'key': 'query', 'type': 'str'}, - } - - def __init__(self, *, header: str=None, query: str=None, **kwargs) -> None: - super(SubscriptionKeyParameterNamesContract, self).__init__(**kwargs) - self.header = header - self.query = query diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/subscription_update_parameters.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/subscription_update_parameters.py deleted file mode 100644 index c17af927f3ad..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/subscription_update_parameters.py +++ /dev/null @@ -1,78 +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 SubscriptionUpdateParameters(Model): - """Subscription update details. - - :param owner_id: User identifier path: /users/{userId} - :type owner_id: str - :param scope: Scope like /products/{productId} or /apis or /apis/{apiId} - :type scope: str - :param expiration_date: Subscription expiration date. The setting is for - audit purposes only and the subscription is not automatically expired. The - subscription lifecycle can be managed by using the `state` property. The - date conforms to the following format: `yyyy-MM-ddTHH:mm:ssZ` as specified - by the ISO 8601 standard. - :type expiration_date: datetime - :param display_name: Subscription name. - :type display_name: str - :param primary_key: Primary subscription key. - :type primary_key: str - :param secondary_key: Secondary subscription key. - :type secondary_key: str - :param state: Subscription state. Possible states are * active – the - subscription is active, * suspended – the subscription is blocked, and the - subscriber cannot call any APIs of the product, * submitted – the - subscription request has been made by the developer, but has not yet been - approved or rejected, * rejected – the subscription request has been - denied by an administrator, * cancelled – the subscription has been - cancelled by the developer or administrator, * expired – the subscription - reached its expiration date and was deactivated. Possible values include: - 'suspended', 'active', 'expired', 'submitted', 'rejected', 'cancelled' - :type state: str or ~azure.mgmt.apimanagement.models.SubscriptionState - :param state_comment: Comments describing subscription state change by the - administrator. - :type state_comment: str - :param allow_tracing: Determines whether tracing can be enabled - :type allow_tracing: bool - """ - - _validation = { - 'primary_key': {'max_length': 256, 'min_length': 1}, - 'secondary_key': {'max_length': 256, 'min_length': 1}, - } - - _attribute_map = { - 'owner_id': {'key': 'properties.ownerId', 'type': 'str'}, - 'scope': {'key': 'properties.scope', 'type': 'str'}, - 'expiration_date': {'key': 'properties.expirationDate', 'type': 'iso-8601'}, - 'display_name': {'key': 'properties.displayName', 'type': 'str'}, - 'primary_key': {'key': 'properties.primaryKey', 'type': 'str'}, - 'secondary_key': {'key': 'properties.secondaryKey', 'type': 'str'}, - 'state': {'key': 'properties.state', 'type': 'SubscriptionState'}, - 'state_comment': {'key': 'properties.stateComment', 'type': 'str'}, - 'allow_tracing': {'key': 'properties.allowTracing', 'type': 'bool'}, - } - - def __init__(self, **kwargs): - super(SubscriptionUpdateParameters, self).__init__(**kwargs) - self.owner_id = kwargs.get('owner_id', None) - self.scope = kwargs.get('scope', None) - self.expiration_date = kwargs.get('expiration_date', None) - self.display_name = kwargs.get('display_name', None) - self.primary_key = kwargs.get('primary_key', None) - self.secondary_key = kwargs.get('secondary_key', None) - self.state = kwargs.get('state', None) - self.state_comment = kwargs.get('state_comment', None) - self.allow_tracing = kwargs.get('allow_tracing', None) diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/subscription_update_parameters_py3.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/subscription_update_parameters_py3.py deleted file mode 100644 index 18e1dd2f5df8..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/subscription_update_parameters_py3.py +++ /dev/null @@ -1,78 +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 SubscriptionUpdateParameters(Model): - """Subscription update details. - - :param owner_id: User identifier path: /users/{userId} - :type owner_id: str - :param scope: Scope like /products/{productId} or /apis or /apis/{apiId} - :type scope: str - :param expiration_date: Subscription expiration date. The setting is for - audit purposes only and the subscription is not automatically expired. The - subscription lifecycle can be managed by using the `state` property. The - date conforms to the following format: `yyyy-MM-ddTHH:mm:ssZ` as specified - by the ISO 8601 standard. - :type expiration_date: datetime - :param display_name: Subscription name. - :type display_name: str - :param primary_key: Primary subscription key. - :type primary_key: str - :param secondary_key: Secondary subscription key. - :type secondary_key: str - :param state: Subscription state. Possible states are * active – the - subscription is active, * suspended – the subscription is blocked, and the - subscriber cannot call any APIs of the product, * submitted – the - subscription request has been made by the developer, but has not yet been - approved or rejected, * rejected – the subscription request has been - denied by an administrator, * cancelled – the subscription has been - cancelled by the developer or administrator, * expired – the subscription - reached its expiration date and was deactivated. Possible values include: - 'suspended', 'active', 'expired', 'submitted', 'rejected', 'cancelled' - :type state: str or ~azure.mgmt.apimanagement.models.SubscriptionState - :param state_comment: Comments describing subscription state change by the - administrator. - :type state_comment: str - :param allow_tracing: Determines whether tracing can be enabled - :type allow_tracing: bool - """ - - _validation = { - 'primary_key': {'max_length': 256, 'min_length': 1}, - 'secondary_key': {'max_length': 256, 'min_length': 1}, - } - - _attribute_map = { - 'owner_id': {'key': 'properties.ownerId', 'type': 'str'}, - 'scope': {'key': 'properties.scope', 'type': 'str'}, - 'expiration_date': {'key': 'properties.expirationDate', 'type': 'iso-8601'}, - 'display_name': {'key': 'properties.displayName', 'type': 'str'}, - 'primary_key': {'key': 'properties.primaryKey', 'type': 'str'}, - 'secondary_key': {'key': 'properties.secondaryKey', 'type': 'str'}, - 'state': {'key': 'properties.state', 'type': 'SubscriptionState'}, - 'state_comment': {'key': 'properties.stateComment', 'type': 'str'}, - 'allow_tracing': {'key': 'properties.allowTracing', 'type': 'bool'}, - } - - def __init__(self, *, owner_id: str=None, scope: str=None, expiration_date=None, display_name: str=None, primary_key: str=None, secondary_key: str=None, state=None, state_comment: str=None, allow_tracing: bool=None, **kwargs) -> None: - super(SubscriptionUpdateParameters, self).__init__(**kwargs) - self.owner_id = owner_id - self.scope = scope - self.expiration_date = expiration_date - self.display_name = display_name - self.primary_key = primary_key - self.secondary_key = secondary_key - self.state = state - self.state_comment = state_comment - self.allow_tracing = allow_tracing diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/subscriptions_delegation_settings_properties.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/subscriptions_delegation_settings_properties.py deleted file mode 100644 index 82beeab1135d..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/subscriptions_delegation_settings_properties.py +++ /dev/null @@ -1,28 +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 SubscriptionsDelegationSettingsProperties(Model): - """Subscriptions delegation settings properties. - - :param enabled: Enable or disable delegation for subscriptions. - :type enabled: bool - """ - - _attribute_map = { - 'enabled': {'key': 'enabled', 'type': 'bool'}, - } - - def __init__(self, **kwargs): - super(SubscriptionsDelegationSettingsProperties, self).__init__(**kwargs) - self.enabled = kwargs.get('enabled', None) diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/subscriptions_delegation_settings_properties_py3.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/subscriptions_delegation_settings_properties_py3.py deleted file mode 100644 index 61fab5253a59..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/subscriptions_delegation_settings_properties_py3.py +++ /dev/null @@ -1,28 +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 SubscriptionsDelegationSettingsProperties(Model): - """Subscriptions delegation settings properties. - - :param enabled: Enable or disable delegation for subscriptions. - :type enabled: bool - """ - - _attribute_map = { - 'enabled': {'key': 'enabled', 'type': 'bool'}, - } - - def __init__(self, *, enabled: bool=None, **kwargs) -> None: - super(SubscriptionsDelegationSettingsProperties, self).__init__(**kwargs) - self.enabled = enabled diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/tag_contract.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/tag_contract.py deleted file mode 100644 index d0b129412cf1..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/tag_contract.py +++ /dev/null @@ -1,49 +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 .resource import Resource - - -class TagContract(Resource): - """Tag Contract details. - - Variables are only populated by the server, and will be ignored when - sending a request. - - All required parameters must be populated in order to send to Azure. - - :ivar id: Resource ID. - :vartype id: str - :ivar name: Resource name. - :vartype name: str - :ivar type: Resource type for API Management resource. - :vartype type: str - :param display_name: Required. Tag name. - :type display_name: str - """ - - _validation = { - 'id': {'readonly': True}, - 'name': {'readonly': True}, - 'type': {'readonly': True}, - 'display_name': {'required': True, 'max_length': 160, 'min_length': 1}, - } - - _attribute_map = { - 'id': {'key': 'id', 'type': 'str'}, - 'name': {'key': 'name', 'type': 'str'}, - 'type': {'key': 'type', 'type': 'str'}, - 'display_name': {'key': 'properties.displayName', 'type': 'str'}, - } - - def __init__(self, **kwargs): - super(TagContract, self).__init__(**kwargs) - self.display_name = kwargs.get('display_name', None) diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/tag_contract_paged.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/tag_contract_paged.py deleted file mode 100644 index 48974c2715cf..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/tag_contract_paged.py +++ /dev/null @@ -1,27 +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.paging import Paged - - -class TagContractPaged(Paged): - """ - A paging container for iterating over a list of :class:`TagContract ` object - """ - - _attribute_map = { - 'next_link': {'key': 'nextLink', 'type': 'str'}, - 'current_page': {'key': 'value', 'type': '[TagContract]'} - } - - def __init__(self, *args, **kwargs): - - super(TagContractPaged, self).__init__(*args, **kwargs) diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/tag_contract_py3.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/tag_contract_py3.py deleted file mode 100644 index 175c0410c173..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/tag_contract_py3.py +++ /dev/null @@ -1,49 +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 .resource_py3 import Resource - - -class TagContract(Resource): - """Tag Contract details. - - Variables are only populated by the server, and will be ignored when - sending a request. - - All required parameters must be populated in order to send to Azure. - - :ivar id: Resource ID. - :vartype id: str - :ivar name: Resource name. - :vartype name: str - :ivar type: Resource type for API Management resource. - :vartype type: str - :param display_name: Required. Tag name. - :type display_name: str - """ - - _validation = { - 'id': {'readonly': True}, - 'name': {'readonly': True}, - 'type': {'readonly': True}, - 'display_name': {'required': True, 'max_length': 160, 'min_length': 1}, - } - - _attribute_map = { - 'id': {'key': 'id', 'type': 'str'}, - 'name': {'key': 'name', 'type': 'str'}, - 'type': {'key': 'type', 'type': 'str'}, - 'display_name': {'key': 'properties.displayName', 'type': 'str'}, - } - - def __init__(self, *, display_name: str, **kwargs) -> None: - super(TagContract, self).__init__(**kwargs) - self.display_name = display_name diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/tag_create_update_parameters.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/tag_create_update_parameters.py deleted file mode 100644 index c133f3ffbf39..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/tag_create_update_parameters.py +++ /dev/null @@ -1,34 +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 TagCreateUpdateParameters(Model): - """Parameters supplied to Create/Update Tag operations. - - All required parameters must be populated in order to send to Azure. - - :param display_name: Required. Tag name. - :type display_name: str - """ - - _validation = { - 'display_name': {'required': True, 'max_length': 160, 'min_length': 1}, - } - - _attribute_map = { - 'display_name': {'key': 'properties.displayName', 'type': 'str'}, - } - - def __init__(self, **kwargs): - super(TagCreateUpdateParameters, self).__init__(**kwargs) - self.display_name = kwargs.get('display_name', None) diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/tag_create_update_parameters_py3.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/tag_create_update_parameters_py3.py deleted file mode 100644 index e7a08d2fb302..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/tag_create_update_parameters_py3.py +++ /dev/null @@ -1,34 +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 TagCreateUpdateParameters(Model): - """Parameters supplied to Create/Update Tag operations. - - All required parameters must be populated in order to send to Azure. - - :param display_name: Required. Tag name. - :type display_name: str - """ - - _validation = { - 'display_name': {'required': True, 'max_length': 160, 'min_length': 1}, - } - - _attribute_map = { - 'display_name': {'key': 'properties.displayName', 'type': 'str'}, - } - - def __init__(self, *, display_name: str, **kwargs) -> None: - super(TagCreateUpdateParameters, self).__init__(**kwargs) - self.display_name = display_name diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/tag_description_contract.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/tag_description_contract.py deleted file mode 100644 index 26e272617407..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/tag_description_contract.py +++ /dev/null @@ -1,62 +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 .resource import Resource - - -class TagDescriptionContract(Resource): - """Contract details. - - Variables are only populated by the server, and will be ignored when - sending a request. - - :ivar id: Resource ID. - :vartype id: str - :ivar name: Resource name. - :vartype name: str - :ivar type: Resource type for API Management resource. - :vartype type: str - :param description: Description of the Tag. - :type description: str - :param external_docs_url: Absolute URL of external resources describing - the tag. - :type external_docs_url: str - :param external_docs_description: Description of the external resources - describing the tag. - :type external_docs_description: str - :param display_name: Tag name. - :type display_name: str - """ - - _validation = { - 'id': {'readonly': True}, - 'name': {'readonly': True}, - 'type': {'readonly': True}, - 'external_docs_url': {'max_length': 2000}, - 'display_name': {'max_length': 160, 'min_length': 1}, - } - - _attribute_map = { - 'id': {'key': 'id', 'type': 'str'}, - 'name': {'key': 'name', 'type': 'str'}, - 'type': {'key': 'type', 'type': 'str'}, - 'description': {'key': 'properties.description', 'type': 'str'}, - 'external_docs_url': {'key': 'properties.externalDocsUrl', 'type': 'str'}, - 'external_docs_description': {'key': 'properties.externalDocsDescription', 'type': 'str'}, - 'display_name': {'key': 'properties.displayName', 'type': 'str'}, - } - - def __init__(self, **kwargs): - super(TagDescriptionContract, self).__init__(**kwargs) - self.description = kwargs.get('description', None) - self.external_docs_url = kwargs.get('external_docs_url', None) - self.external_docs_description = kwargs.get('external_docs_description', None) - self.display_name = kwargs.get('display_name', None) diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/tag_description_contract_paged.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/tag_description_contract_paged.py deleted file mode 100644 index 3867d66bf905..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/tag_description_contract_paged.py +++ /dev/null @@ -1,27 +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.paging import Paged - - -class TagDescriptionContractPaged(Paged): - """ - A paging container for iterating over a list of :class:`TagDescriptionContract ` object - """ - - _attribute_map = { - 'next_link': {'key': 'nextLink', 'type': 'str'}, - 'current_page': {'key': 'value', 'type': '[TagDescriptionContract]'} - } - - def __init__(self, *args, **kwargs): - - super(TagDescriptionContractPaged, self).__init__(*args, **kwargs) diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/tag_description_contract_py3.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/tag_description_contract_py3.py deleted file mode 100644 index 4ae8bda6437a..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/tag_description_contract_py3.py +++ /dev/null @@ -1,62 +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 .resource_py3 import Resource - - -class TagDescriptionContract(Resource): - """Contract details. - - Variables are only populated by the server, and will be ignored when - sending a request. - - :ivar id: Resource ID. - :vartype id: str - :ivar name: Resource name. - :vartype name: str - :ivar type: Resource type for API Management resource. - :vartype type: str - :param description: Description of the Tag. - :type description: str - :param external_docs_url: Absolute URL of external resources describing - the tag. - :type external_docs_url: str - :param external_docs_description: Description of the external resources - describing the tag. - :type external_docs_description: str - :param display_name: Tag name. - :type display_name: str - """ - - _validation = { - 'id': {'readonly': True}, - 'name': {'readonly': True}, - 'type': {'readonly': True}, - 'external_docs_url': {'max_length': 2000}, - 'display_name': {'max_length': 160, 'min_length': 1}, - } - - _attribute_map = { - 'id': {'key': 'id', 'type': 'str'}, - 'name': {'key': 'name', 'type': 'str'}, - 'type': {'key': 'type', 'type': 'str'}, - 'description': {'key': 'properties.description', 'type': 'str'}, - 'external_docs_url': {'key': 'properties.externalDocsUrl', 'type': 'str'}, - 'external_docs_description': {'key': 'properties.externalDocsDescription', 'type': 'str'}, - 'display_name': {'key': 'properties.displayName', 'type': 'str'}, - } - - def __init__(self, *, description: str=None, external_docs_url: str=None, external_docs_description: str=None, display_name: str=None, **kwargs) -> None: - super(TagDescriptionContract, self).__init__(**kwargs) - self.description = description - self.external_docs_url = external_docs_url - self.external_docs_description = external_docs_description - self.display_name = display_name diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/tag_description_create_parameters.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/tag_description_create_parameters.py deleted file mode 100644 index 15842608702c..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/tag_description_create_parameters.py +++ /dev/null @@ -1,42 +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 TagDescriptionCreateParameters(Model): - """Parameters supplied to the Create TagDescription operation. - - :param description: Description of the Tag. - :type description: str - :param external_docs_url: Absolute URL of external resources describing - the tag. - :type external_docs_url: str - :param external_docs_description: Description of the external resources - describing the tag. - :type external_docs_description: str - """ - - _validation = { - 'external_docs_url': {'max_length': 2000}, - } - - _attribute_map = { - 'description': {'key': 'properties.description', 'type': 'str'}, - 'external_docs_url': {'key': 'properties.externalDocsUrl', 'type': 'str'}, - 'external_docs_description': {'key': 'properties.externalDocsDescription', 'type': 'str'}, - } - - def __init__(self, **kwargs): - super(TagDescriptionCreateParameters, self).__init__(**kwargs) - self.description = kwargs.get('description', None) - self.external_docs_url = kwargs.get('external_docs_url', None) - self.external_docs_description = kwargs.get('external_docs_description', None) diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/tag_description_create_parameters_py3.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/tag_description_create_parameters_py3.py deleted file mode 100644 index dd5a8b4ad441..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/tag_description_create_parameters_py3.py +++ /dev/null @@ -1,42 +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 TagDescriptionCreateParameters(Model): - """Parameters supplied to the Create TagDescription operation. - - :param description: Description of the Tag. - :type description: str - :param external_docs_url: Absolute URL of external resources describing - the tag. - :type external_docs_url: str - :param external_docs_description: Description of the external resources - describing the tag. - :type external_docs_description: str - """ - - _validation = { - 'external_docs_url': {'max_length': 2000}, - } - - _attribute_map = { - 'description': {'key': 'properties.description', 'type': 'str'}, - 'external_docs_url': {'key': 'properties.externalDocsUrl', 'type': 'str'}, - 'external_docs_description': {'key': 'properties.externalDocsDescription', 'type': 'str'}, - } - - def __init__(self, *, description: str=None, external_docs_url: str=None, external_docs_description: str=None, **kwargs) -> None: - super(TagDescriptionCreateParameters, self).__init__(**kwargs) - self.description = description - self.external_docs_url = external_docs_url - self.external_docs_description = external_docs_description diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/tag_resource_contract.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/tag_resource_contract.py deleted file mode 100644 index 594a0780d833..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/tag_resource_contract.py +++ /dev/null @@ -1,50 +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 TagResourceContract(Model): - """TagResource contract properties. - - All required parameters must be populated in order to send to Azure. - - :param tag: Required. Tag associated with the resource. - :type tag: - ~azure.mgmt.apimanagement.models.TagTagResourceContractProperties - :param api: Api associated with the tag. - :type api: - ~azure.mgmt.apimanagement.models.ApiTagResourceContractProperties - :param operation: Operation associated with the tag. - :type operation: - ~azure.mgmt.apimanagement.models.OperationTagResourceContractProperties - :param product: Product associated with the tag. - :type product: - ~azure.mgmt.apimanagement.models.ProductTagResourceContractProperties - """ - - _validation = { - 'tag': {'required': True}, - } - - _attribute_map = { - 'tag': {'key': 'tag', 'type': 'TagTagResourceContractProperties'}, - 'api': {'key': 'api', 'type': 'ApiTagResourceContractProperties'}, - 'operation': {'key': 'operation', 'type': 'OperationTagResourceContractProperties'}, - 'product': {'key': 'product', 'type': 'ProductTagResourceContractProperties'}, - } - - def __init__(self, **kwargs): - super(TagResourceContract, self).__init__(**kwargs) - self.tag = kwargs.get('tag', None) - self.api = kwargs.get('api', None) - self.operation = kwargs.get('operation', None) - self.product = kwargs.get('product', None) diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/tag_resource_contract_paged.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/tag_resource_contract_paged.py deleted file mode 100644 index c64d82f24e7c..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/tag_resource_contract_paged.py +++ /dev/null @@ -1,27 +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.paging import Paged - - -class TagResourceContractPaged(Paged): - """ - A paging container for iterating over a list of :class:`TagResourceContract ` object - """ - - _attribute_map = { - 'next_link': {'key': 'nextLink', 'type': 'str'}, - 'current_page': {'key': 'value', 'type': '[TagResourceContract]'} - } - - def __init__(self, *args, **kwargs): - - super(TagResourceContractPaged, self).__init__(*args, **kwargs) diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/tag_resource_contract_py3.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/tag_resource_contract_py3.py deleted file mode 100644 index 1377128c02d7..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/tag_resource_contract_py3.py +++ /dev/null @@ -1,50 +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 TagResourceContract(Model): - """TagResource contract properties. - - All required parameters must be populated in order to send to Azure. - - :param tag: Required. Tag associated with the resource. - :type tag: - ~azure.mgmt.apimanagement.models.TagTagResourceContractProperties - :param api: Api associated with the tag. - :type api: - ~azure.mgmt.apimanagement.models.ApiTagResourceContractProperties - :param operation: Operation associated with the tag. - :type operation: - ~azure.mgmt.apimanagement.models.OperationTagResourceContractProperties - :param product: Product associated with the tag. - :type product: - ~azure.mgmt.apimanagement.models.ProductTagResourceContractProperties - """ - - _validation = { - 'tag': {'required': True}, - } - - _attribute_map = { - 'tag': {'key': 'tag', 'type': 'TagTagResourceContractProperties'}, - 'api': {'key': 'api', 'type': 'ApiTagResourceContractProperties'}, - 'operation': {'key': 'operation', 'type': 'OperationTagResourceContractProperties'}, - 'product': {'key': 'product', 'type': 'ProductTagResourceContractProperties'}, - } - - def __init__(self, *, tag, api=None, operation=None, product=None, **kwargs) -> None: - super(TagResourceContract, self).__init__(**kwargs) - self.tag = tag - self.api = api - self.operation = operation - self.product = product diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/tag_tag_resource_contract_properties.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/tag_tag_resource_contract_properties.py deleted file mode 100644 index 54330625ad6d..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/tag_tag_resource_contract_properties.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 TagTagResourceContractProperties(Model): - """Contract defining the Tag property in the Tag Resource Contract. - - :param id: Tag identifier - :type id: str - :param name: Tag Name - :type name: str - """ - - _validation = { - 'name': {'max_length': 160, 'min_length': 1}, - } - - _attribute_map = { - 'id': {'key': 'id', 'type': 'str'}, - 'name': {'key': 'name', 'type': 'str'}, - } - - def __init__(self, **kwargs): - super(TagTagResourceContractProperties, self).__init__(**kwargs) - self.id = kwargs.get('id', None) - self.name = kwargs.get('name', None) diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/tag_tag_resource_contract_properties_py3.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/tag_tag_resource_contract_properties_py3.py deleted file mode 100644 index 48f937aa9e52..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/tag_tag_resource_contract_properties_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 TagTagResourceContractProperties(Model): - """Contract defining the Tag property in the Tag Resource Contract. - - :param id: Tag identifier - :type id: str - :param name: Tag Name - :type name: str - """ - - _validation = { - 'name': {'max_length': 160, 'min_length': 1}, - } - - _attribute_map = { - 'id': {'key': 'id', 'type': 'str'}, - 'name': {'key': 'name', 'type': 'str'}, - } - - def __init__(self, *, id: str=None, name: str=None, **kwargs) -> None: - super(TagTagResourceContractProperties, self).__init__(**kwargs) - self.id = id - self.name = name diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/tenant_configuration_sync_state_contract.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/tenant_configuration_sync_state_contract.py deleted file mode 100644 index 8b5d7e2d4c46..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/tenant_configuration_sync_state_contract.py +++ /dev/null @@ -1,59 +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 TenantConfigurationSyncStateContract(Model): - """Tenant Configuration Synchronization State. - - :param branch: The name of Git branch. - :type branch: str - :param commit_id: The latest commit Id. - :type commit_id: str - :param is_export: value indicating if last sync was save (true) or deploy - (false) operation. - :type is_export: bool - :param is_synced: value indicating if last synchronization was later than - the configuration change. - :type is_synced: bool - :param is_git_enabled: value indicating whether Git configuration access - is enabled. - :type is_git_enabled: bool - :param sync_date: The date of the latest synchronization. The date - conforms to the following format: `yyyy-MM-ddTHH:mm:ssZ` as specified by - the ISO 8601 standard. - :type sync_date: datetime - :param configuration_change_date: The date of the latest configuration - change. The date conforms to the following format: `yyyy-MM-ddTHH:mm:ssZ` - as specified by the ISO 8601 standard. - :type configuration_change_date: datetime - """ - - _attribute_map = { - 'branch': {'key': 'branch', 'type': 'str'}, - 'commit_id': {'key': 'commitId', 'type': 'str'}, - 'is_export': {'key': 'isExport', 'type': 'bool'}, - 'is_synced': {'key': 'isSynced', 'type': 'bool'}, - 'is_git_enabled': {'key': 'isGitEnabled', 'type': 'bool'}, - 'sync_date': {'key': 'syncDate', 'type': 'iso-8601'}, - 'configuration_change_date': {'key': 'configurationChangeDate', 'type': 'iso-8601'}, - } - - def __init__(self, **kwargs): - super(TenantConfigurationSyncStateContract, self).__init__(**kwargs) - self.branch = kwargs.get('branch', None) - self.commit_id = kwargs.get('commit_id', None) - self.is_export = kwargs.get('is_export', None) - self.is_synced = kwargs.get('is_synced', None) - self.is_git_enabled = kwargs.get('is_git_enabled', None) - self.sync_date = kwargs.get('sync_date', None) - self.configuration_change_date = kwargs.get('configuration_change_date', None) diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/tenant_configuration_sync_state_contract_py3.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/tenant_configuration_sync_state_contract_py3.py deleted file mode 100644 index 7b9c9e8d2c40..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/tenant_configuration_sync_state_contract_py3.py +++ /dev/null @@ -1,59 +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 TenantConfigurationSyncStateContract(Model): - """Tenant Configuration Synchronization State. - - :param branch: The name of Git branch. - :type branch: str - :param commit_id: The latest commit Id. - :type commit_id: str - :param is_export: value indicating if last sync was save (true) or deploy - (false) operation. - :type is_export: bool - :param is_synced: value indicating if last synchronization was later than - the configuration change. - :type is_synced: bool - :param is_git_enabled: value indicating whether Git configuration access - is enabled. - :type is_git_enabled: bool - :param sync_date: The date of the latest synchronization. The date - conforms to the following format: `yyyy-MM-ddTHH:mm:ssZ` as specified by - the ISO 8601 standard. - :type sync_date: datetime - :param configuration_change_date: The date of the latest configuration - change. The date conforms to the following format: `yyyy-MM-ddTHH:mm:ssZ` - as specified by the ISO 8601 standard. - :type configuration_change_date: datetime - """ - - _attribute_map = { - 'branch': {'key': 'branch', 'type': 'str'}, - 'commit_id': {'key': 'commitId', 'type': 'str'}, - 'is_export': {'key': 'isExport', 'type': 'bool'}, - 'is_synced': {'key': 'isSynced', 'type': 'bool'}, - 'is_git_enabled': {'key': 'isGitEnabled', 'type': 'bool'}, - 'sync_date': {'key': 'syncDate', 'type': 'iso-8601'}, - 'configuration_change_date': {'key': 'configurationChangeDate', 'type': 'iso-8601'}, - } - - def __init__(self, *, branch: str=None, commit_id: str=None, is_export: bool=None, is_synced: bool=None, is_git_enabled: bool=None, sync_date=None, configuration_change_date=None, **kwargs) -> None: - super(TenantConfigurationSyncStateContract, self).__init__(**kwargs) - self.branch = branch - self.commit_id = commit_id - self.is_export = is_export - self.is_synced = is_synced - self.is_git_enabled = is_git_enabled - self.sync_date = sync_date - self.configuration_change_date = configuration_change_date diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/terms_of_service_properties.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/terms_of_service_properties.py deleted file mode 100644 index 8967b154c12c..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/terms_of_service_properties.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 TermsOfServiceProperties(Model): - """Terms of service contract properties. - - :param text: A terms of service text. - :type text: str - :param enabled: Display terms of service during a sign-up process. - :type enabled: bool - :param consent_required: Ask user for consent to the terms of service. - :type consent_required: bool - """ - - _attribute_map = { - 'text': {'key': 'text', 'type': 'str'}, - 'enabled': {'key': 'enabled', 'type': 'bool'}, - 'consent_required': {'key': 'consentRequired', 'type': 'bool'}, - } - - def __init__(self, **kwargs): - super(TermsOfServiceProperties, self).__init__(**kwargs) - self.text = kwargs.get('text', None) - self.enabled = kwargs.get('enabled', None) - self.consent_required = kwargs.get('consent_required', None) diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/terms_of_service_properties_py3.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/terms_of_service_properties_py3.py deleted file mode 100644 index 12ba02c648fa..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/terms_of_service_properties_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 TermsOfServiceProperties(Model): - """Terms of service contract properties. - - :param text: A terms of service text. - :type text: str - :param enabled: Display terms of service during a sign-up process. - :type enabled: bool - :param consent_required: Ask user for consent to the terms of service. - :type consent_required: bool - """ - - _attribute_map = { - 'text': {'key': 'text', 'type': 'str'}, - 'enabled': {'key': 'enabled', 'type': 'bool'}, - 'consent_required': {'key': 'consentRequired', 'type': 'bool'}, - } - - def __init__(self, *, text: str=None, enabled: bool=None, consent_required: bool=None, **kwargs) -> None: - super(TermsOfServiceProperties, self).__init__(**kwargs) - self.text = text - self.enabled = enabled - self.consent_required = consent_required diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/token_body_parameter_contract.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/token_body_parameter_contract.py deleted file mode 100644 index 605ff1d0d585..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/token_body_parameter_contract.py +++ /dev/null @@ -1,39 +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 TokenBodyParameterContract(Model): - """OAuth acquire token request body parameter (www-url-form-encoded). - - All required parameters must be populated in order to send to Azure. - - :param name: Required. body parameter name. - :type name: str - :param value: Required. body parameter value. - :type value: str - """ - - _validation = { - 'name': {'required': True}, - 'value': {'required': True}, - } - - _attribute_map = { - 'name': {'key': 'name', 'type': 'str'}, - 'value': {'key': 'value', 'type': 'str'}, - } - - def __init__(self, **kwargs): - super(TokenBodyParameterContract, self).__init__(**kwargs) - self.name = kwargs.get('name', None) - self.value = kwargs.get('value', None) diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/token_body_parameter_contract_py3.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/token_body_parameter_contract_py3.py deleted file mode 100644 index 737fc6853009..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/token_body_parameter_contract_py3.py +++ /dev/null @@ -1,39 +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 TokenBodyParameterContract(Model): - """OAuth acquire token request body parameter (www-url-form-encoded). - - All required parameters must be populated in order to send to Azure. - - :param name: Required. body parameter name. - :type name: str - :param value: Required. body parameter value. - :type value: str - """ - - _validation = { - 'name': {'required': True}, - 'value': {'required': True}, - } - - _attribute_map = { - 'name': {'key': 'name', 'type': 'str'}, - 'value': {'key': 'value', 'type': 'str'}, - } - - def __init__(self, *, name: str, value: str, **kwargs) -> None: - super(TokenBodyParameterContract, self).__init__(**kwargs) - self.name = name - self.value = value diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/user_contract.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/user_contract.py deleted file mode 100644 index b36d4717e4d4..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/user_contract.py +++ /dev/null @@ -1,83 +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 .resource import Resource - - -class UserContract(Resource): - """User details. - - Variables are only populated by the server, and will be ignored when - sending a request. - - :ivar id: Resource ID. - :vartype id: str - :ivar name: Resource name. - :vartype name: str - :ivar type: Resource type for API Management resource. - :vartype type: str - :param state: Account state. Specifies whether the user is active or not. - Blocked users are unable to sign into the developer portal or call any - APIs of subscribed products. Default state is Active. Possible values - include: 'active', 'blocked', 'pending', 'deleted'. Default value: - "active" . - :type state: str or ~azure.mgmt.apimanagement.models.UserState - :param note: Optional note about a user set by the administrator. - :type note: str - :param identities: Collection of user identities. - :type identities: - list[~azure.mgmt.apimanagement.models.UserIdentityContract] - :param first_name: First name. - :type first_name: str - :param last_name: Last name. - :type last_name: str - :param email: Email address. - :type email: str - :param registration_date: Date of user registration. The date conforms to - the following format: `yyyy-MM-ddTHH:mm:ssZ` as specified by the ISO 8601 - standard. - :type registration_date: datetime - :ivar groups: Collection of groups user is part of. - :vartype groups: - list[~azure.mgmt.apimanagement.models.GroupContractProperties] - """ - - _validation = { - 'id': {'readonly': True}, - 'name': {'readonly': True}, - 'type': {'readonly': True}, - 'groups': {'readonly': True}, - } - - _attribute_map = { - 'id': {'key': 'id', 'type': 'str'}, - 'name': {'key': 'name', 'type': 'str'}, - 'type': {'key': 'type', 'type': 'str'}, - 'state': {'key': 'properties.state', 'type': 'str'}, - 'note': {'key': 'properties.note', 'type': 'str'}, - 'identities': {'key': 'properties.identities', 'type': '[UserIdentityContract]'}, - 'first_name': {'key': 'properties.firstName', 'type': 'str'}, - 'last_name': {'key': 'properties.lastName', 'type': 'str'}, - 'email': {'key': 'properties.email', 'type': 'str'}, - 'registration_date': {'key': 'properties.registrationDate', 'type': 'iso-8601'}, - 'groups': {'key': 'properties.groups', 'type': '[GroupContractProperties]'}, - } - - def __init__(self, **kwargs): - super(UserContract, self).__init__(**kwargs) - self.state = kwargs.get('state', "active") - self.note = kwargs.get('note', None) - self.identities = kwargs.get('identities', None) - self.first_name = kwargs.get('first_name', None) - self.last_name = kwargs.get('last_name', None) - self.email = kwargs.get('email', None) - self.registration_date = kwargs.get('registration_date', None) - self.groups = None diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/user_contract_paged.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/user_contract_paged.py deleted file mode 100644 index a31093562e22..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/user_contract_paged.py +++ /dev/null @@ -1,27 +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.paging import Paged - - -class UserContractPaged(Paged): - """ - A paging container for iterating over a list of :class:`UserContract ` object - """ - - _attribute_map = { - 'next_link': {'key': 'nextLink', 'type': 'str'}, - 'current_page': {'key': 'value', 'type': '[UserContract]'} - } - - def __init__(self, *args, **kwargs): - - super(UserContractPaged, self).__init__(*args, **kwargs) diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/user_contract_py3.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/user_contract_py3.py deleted file mode 100644 index 3c2d23be38af..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/user_contract_py3.py +++ /dev/null @@ -1,83 +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 .resource_py3 import Resource - - -class UserContract(Resource): - """User details. - - Variables are only populated by the server, and will be ignored when - sending a request. - - :ivar id: Resource ID. - :vartype id: str - :ivar name: Resource name. - :vartype name: str - :ivar type: Resource type for API Management resource. - :vartype type: str - :param state: Account state. Specifies whether the user is active or not. - Blocked users are unable to sign into the developer portal or call any - APIs of subscribed products. Default state is Active. Possible values - include: 'active', 'blocked', 'pending', 'deleted'. Default value: - "active" . - :type state: str or ~azure.mgmt.apimanagement.models.UserState - :param note: Optional note about a user set by the administrator. - :type note: str - :param identities: Collection of user identities. - :type identities: - list[~azure.mgmt.apimanagement.models.UserIdentityContract] - :param first_name: First name. - :type first_name: str - :param last_name: Last name. - :type last_name: str - :param email: Email address. - :type email: str - :param registration_date: Date of user registration. The date conforms to - the following format: `yyyy-MM-ddTHH:mm:ssZ` as specified by the ISO 8601 - standard. - :type registration_date: datetime - :ivar groups: Collection of groups user is part of. - :vartype groups: - list[~azure.mgmt.apimanagement.models.GroupContractProperties] - """ - - _validation = { - 'id': {'readonly': True}, - 'name': {'readonly': True}, - 'type': {'readonly': True}, - 'groups': {'readonly': True}, - } - - _attribute_map = { - 'id': {'key': 'id', 'type': 'str'}, - 'name': {'key': 'name', 'type': 'str'}, - 'type': {'key': 'type', 'type': 'str'}, - 'state': {'key': 'properties.state', 'type': 'str'}, - 'note': {'key': 'properties.note', 'type': 'str'}, - 'identities': {'key': 'properties.identities', 'type': '[UserIdentityContract]'}, - 'first_name': {'key': 'properties.firstName', 'type': 'str'}, - 'last_name': {'key': 'properties.lastName', 'type': 'str'}, - 'email': {'key': 'properties.email', 'type': 'str'}, - 'registration_date': {'key': 'properties.registrationDate', 'type': 'iso-8601'}, - 'groups': {'key': 'properties.groups', 'type': '[GroupContractProperties]'}, - } - - def __init__(self, *, state="active", note: str=None, identities=None, first_name: str=None, last_name: str=None, email: str=None, registration_date=None, **kwargs) -> None: - super(UserContract, self).__init__(**kwargs) - self.state = state - self.note = note - self.identities = identities - self.first_name = first_name - self.last_name = last_name - self.email = email - self.registration_date = registration_date - self.groups = None diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/user_create_parameters.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/user_create_parameters.py deleted file mode 100644 index c2a08c3fd236..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/user_create_parameters.py +++ /dev/null @@ -1,73 +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 UserCreateParameters(Model): - """User create details. - - All required parameters must be populated in order to send to Azure. - - :param state: Account state. Specifies whether the user is active or not. - Blocked users are unable to sign into the developer portal or call any - APIs of subscribed products. Default state is Active. Possible values - include: 'active', 'blocked', 'pending', 'deleted'. Default value: - "active" . - :type state: str or ~azure.mgmt.apimanagement.models.UserState - :param note: Optional note about a user set by the administrator. - :type note: str - :param identities: Collection of user identities. - :type identities: - list[~azure.mgmt.apimanagement.models.UserIdentityContract] - :param email: Required. Email address. Must not be empty and must be - unique within the service instance. - :type email: str - :param first_name: Required. First name. - :type first_name: str - :param last_name: Required. Last name. - :type last_name: str - :param password: User Password. If no value is provided, a default - password is generated. - :type password: str - :param confirmation: Determines the type of confirmation e-mail that will - be sent to the newly created user. Possible values include: 'signup', - 'invite' - :type confirmation: str or ~azure.mgmt.apimanagement.models.Confirmation - """ - - _validation = { - 'email': {'required': True, 'max_length': 254, 'min_length': 1}, - 'first_name': {'required': True, 'max_length': 100, 'min_length': 1}, - 'last_name': {'required': True, 'max_length': 100, 'min_length': 1}, - } - - _attribute_map = { - 'state': {'key': 'properties.state', 'type': 'str'}, - 'note': {'key': 'properties.note', 'type': 'str'}, - 'identities': {'key': 'properties.identities', 'type': '[UserIdentityContract]'}, - 'email': {'key': 'properties.email', 'type': 'str'}, - 'first_name': {'key': 'properties.firstName', 'type': 'str'}, - 'last_name': {'key': 'properties.lastName', 'type': 'str'}, - 'password': {'key': 'properties.password', 'type': 'str'}, - 'confirmation': {'key': 'properties.confirmation', 'type': 'str'}, - } - - def __init__(self, **kwargs): - super(UserCreateParameters, self).__init__(**kwargs) - self.state = kwargs.get('state', "active") - self.note = kwargs.get('note', None) - self.identities = kwargs.get('identities', None) - self.email = kwargs.get('email', None) - self.first_name = kwargs.get('first_name', None) - self.last_name = kwargs.get('last_name', None) - self.password = kwargs.get('password', None) - self.confirmation = kwargs.get('confirmation', None) diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/user_create_parameters_py3.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/user_create_parameters_py3.py deleted file mode 100644 index 240440728fdb..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/user_create_parameters_py3.py +++ /dev/null @@ -1,73 +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 UserCreateParameters(Model): - """User create details. - - All required parameters must be populated in order to send to Azure. - - :param state: Account state. Specifies whether the user is active or not. - Blocked users are unable to sign into the developer portal or call any - APIs of subscribed products. Default state is Active. Possible values - include: 'active', 'blocked', 'pending', 'deleted'. Default value: - "active" . - :type state: str or ~azure.mgmt.apimanagement.models.UserState - :param note: Optional note about a user set by the administrator. - :type note: str - :param identities: Collection of user identities. - :type identities: - list[~azure.mgmt.apimanagement.models.UserIdentityContract] - :param email: Required. Email address. Must not be empty and must be - unique within the service instance. - :type email: str - :param first_name: Required. First name. - :type first_name: str - :param last_name: Required. Last name. - :type last_name: str - :param password: User Password. If no value is provided, a default - password is generated. - :type password: str - :param confirmation: Determines the type of confirmation e-mail that will - be sent to the newly created user. Possible values include: 'signup', - 'invite' - :type confirmation: str or ~azure.mgmt.apimanagement.models.Confirmation - """ - - _validation = { - 'email': {'required': True, 'max_length': 254, 'min_length': 1}, - 'first_name': {'required': True, 'max_length': 100, 'min_length': 1}, - 'last_name': {'required': True, 'max_length': 100, 'min_length': 1}, - } - - _attribute_map = { - 'state': {'key': 'properties.state', 'type': 'str'}, - 'note': {'key': 'properties.note', 'type': 'str'}, - 'identities': {'key': 'properties.identities', 'type': '[UserIdentityContract]'}, - 'email': {'key': 'properties.email', 'type': 'str'}, - 'first_name': {'key': 'properties.firstName', 'type': 'str'}, - 'last_name': {'key': 'properties.lastName', 'type': 'str'}, - 'password': {'key': 'properties.password', 'type': 'str'}, - 'confirmation': {'key': 'properties.confirmation', 'type': 'str'}, - } - - def __init__(self, *, email: str, first_name: str, last_name: str, state="active", note: str=None, identities=None, password: str=None, confirmation=None, **kwargs) -> None: - super(UserCreateParameters, self).__init__(**kwargs) - self.state = state - self.note = note - self.identities = identities - self.email = email - self.first_name = first_name - self.last_name = last_name - self.password = password - self.confirmation = confirmation diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/user_entity_base_parameters.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/user_entity_base_parameters.py deleted file mode 100644 index f190379aa298..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/user_entity_base_parameters.py +++ /dev/null @@ -1,41 +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 UserEntityBaseParameters(Model): - """User Entity Base Parameters set. - - :param state: Account state. Specifies whether the user is active or not. - Blocked users are unable to sign into the developer portal or call any - APIs of subscribed products. Default state is Active. Possible values - include: 'active', 'blocked', 'pending', 'deleted'. Default value: - "active" . - :type state: str or ~azure.mgmt.apimanagement.models.UserState - :param note: Optional note about a user set by the administrator. - :type note: str - :param identities: Collection of user identities. - :type identities: - list[~azure.mgmt.apimanagement.models.UserIdentityContract] - """ - - _attribute_map = { - 'state': {'key': 'state', 'type': 'str'}, - 'note': {'key': 'note', 'type': 'str'}, - 'identities': {'key': 'identities', 'type': '[UserIdentityContract]'}, - } - - def __init__(self, **kwargs): - super(UserEntityBaseParameters, self).__init__(**kwargs) - self.state = kwargs.get('state', "active") - self.note = kwargs.get('note', None) - self.identities = kwargs.get('identities', None) diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/user_entity_base_parameters_py3.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/user_entity_base_parameters_py3.py deleted file mode 100644 index cd8a291e9a3a..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/user_entity_base_parameters_py3.py +++ /dev/null @@ -1,41 +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 UserEntityBaseParameters(Model): - """User Entity Base Parameters set. - - :param state: Account state. Specifies whether the user is active or not. - Blocked users are unable to sign into the developer portal or call any - APIs of subscribed products. Default state is Active. Possible values - include: 'active', 'blocked', 'pending', 'deleted'. Default value: - "active" . - :type state: str or ~azure.mgmt.apimanagement.models.UserState - :param note: Optional note about a user set by the administrator. - :type note: str - :param identities: Collection of user identities. - :type identities: - list[~azure.mgmt.apimanagement.models.UserIdentityContract] - """ - - _attribute_map = { - 'state': {'key': 'state', 'type': 'str'}, - 'note': {'key': 'note', 'type': 'str'}, - 'identities': {'key': 'identities', 'type': '[UserIdentityContract]'}, - } - - def __init__(self, *, state="active", note: str=None, identities=None, **kwargs) -> None: - super(UserEntityBaseParameters, self).__init__(**kwargs) - self.state = state - self.note = note - self.identities = identities diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/user_identity_contract.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/user_identity_contract.py deleted file mode 100644 index 1e0bd1a8ac33..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/user_identity_contract.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 UserIdentityContract(Model): - """User identity details. - - :param provider: Identity provider name. - :type provider: str - :param id: Identifier value within provider. - :type id: str - """ - - _attribute_map = { - 'provider': {'key': 'provider', 'type': 'str'}, - 'id': {'key': 'id', 'type': 'str'}, - } - - def __init__(self, **kwargs): - super(UserIdentityContract, self).__init__(**kwargs) - self.provider = kwargs.get('provider', None) - self.id = kwargs.get('id', None) diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/user_identity_contract_paged.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/user_identity_contract_paged.py deleted file mode 100644 index f1f4040a5e7b..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/user_identity_contract_paged.py +++ /dev/null @@ -1,27 +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.paging import Paged - - -class UserIdentityContractPaged(Paged): - """ - A paging container for iterating over a list of :class:`UserIdentityContract ` object - """ - - _attribute_map = { - 'next_link': {'key': 'nextLink', 'type': 'str'}, - 'current_page': {'key': 'value', 'type': '[UserIdentityContract]'} - } - - def __init__(self, *args, **kwargs): - - super(UserIdentityContractPaged, self).__init__(*args, **kwargs) diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/user_identity_contract_py3.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/user_identity_contract_py3.py deleted file mode 100644 index 880bf2e0336a..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/user_identity_contract_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 UserIdentityContract(Model): - """User identity details. - - :param provider: Identity provider name. - :type provider: str - :param id: Identifier value within provider. - :type id: str - """ - - _attribute_map = { - 'provider': {'key': 'provider', 'type': 'str'}, - 'id': {'key': 'id', 'type': 'str'}, - } - - def __init__(self, *, provider: str=None, id: str=None, **kwargs) -> None: - super(UserIdentityContract, self).__init__(**kwargs) - self.provider = provider - self.id = id diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/user_token_parameters.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/user_token_parameters.py deleted file mode 100644 index e8092006538f..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/user_token_parameters.py +++ /dev/null @@ -1,43 +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 UserTokenParameters(Model): - """Get User Token parameters. - - All required parameters must be populated in order to send to Azure. - - :param key_type: Required. The Key to be used to generate token for user. - Possible values include: 'primary', 'secondary'. Default value: "primary" - . - :type key_type: str or ~azure.mgmt.apimanagement.models.KeyType - :param expiry: Required. The Expiry time of the Token. Maximum token - expiry time is set to 30 days. The date conforms to the following format: - `yyyy-MM-ddTHH:mm:ssZ` as specified by the ISO 8601 standard. - :type expiry: datetime - """ - - _validation = { - 'key_type': {'required': True}, - 'expiry': {'required': True}, - } - - _attribute_map = { - 'key_type': {'key': 'properties.keyType', 'type': 'KeyType'}, - 'expiry': {'key': 'properties.expiry', 'type': 'iso-8601'}, - } - - def __init__(self, **kwargs): - super(UserTokenParameters, self).__init__(**kwargs) - self.key_type = kwargs.get('key_type', "primary") - self.expiry = kwargs.get('expiry', None) diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/user_token_parameters_py3.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/user_token_parameters_py3.py deleted file mode 100644 index d0aecd5b2174..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/user_token_parameters_py3.py +++ /dev/null @@ -1,43 +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 UserTokenParameters(Model): - """Get User Token parameters. - - All required parameters must be populated in order to send to Azure. - - :param key_type: Required. The Key to be used to generate token for user. - Possible values include: 'primary', 'secondary'. Default value: "primary" - . - :type key_type: str or ~azure.mgmt.apimanagement.models.KeyType - :param expiry: Required. The Expiry time of the Token. Maximum token - expiry time is set to 30 days. The date conforms to the following format: - `yyyy-MM-ddTHH:mm:ssZ` as specified by the ISO 8601 standard. - :type expiry: datetime - """ - - _validation = { - 'key_type': {'required': True}, - 'expiry': {'required': True}, - } - - _attribute_map = { - 'key_type': {'key': 'properties.keyType', 'type': 'KeyType'}, - 'expiry': {'key': 'properties.expiry', 'type': 'iso-8601'}, - } - - def __init__(self, *, expiry, key_type="primary", **kwargs) -> None: - super(UserTokenParameters, self).__init__(**kwargs) - self.key_type = key_type - self.expiry = expiry diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/user_token_result.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/user_token_result.py deleted file mode 100644 index d124715b1855..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/user_token_result.py +++ /dev/null @@ -1,28 +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 UserTokenResult(Model): - """Get User Token response details. - - :param value: Shared Access Authorization token for the User. - :type value: str - """ - - _attribute_map = { - 'value': {'key': 'value', 'type': 'str'}, - } - - def __init__(self, **kwargs): - super(UserTokenResult, self).__init__(**kwargs) - self.value = kwargs.get('value', None) diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/user_token_result_py3.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/user_token_result_py3.py deleted file mode 100644 index 466feaef0a44..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/user_token_result_py3.py +++ /dev/null @@ -1,28 +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 UserTokenResult(Model): - """Get User Token response details. - - :param value: Shared Access Authorization token for the User. - :type value: str - """ - - _attribute_map = { - 'value': {'key': 'value', 'type': 'str'}, - } - - def __init__(self, *, value: str=None, **kwargs) -> None: - super(UserTokenResult, self).__init__(**kwargs) - self.value = value diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/user_update_parameters.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/user_update_parameters.py deleted file mode 100644 index 2adc28870a0f..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/user_update_parameters.py +++ /dev/null @@ -1,64 +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 UserUpdateParameters(Model): - """User update parameters. - - :param state: Account state. Specifies whether the user is active or not. - Blocked users are unable to sign into the developer portal or call any - APIs of subscribed products. Default state is Active. Possible values - include: 'active', 'blocked', 'pending', 'deleted'. Default value: - "active" . - :type state: str or ~azure.mgmt.apimanagement.models.UserState - :param note: Optional note about a user set by the administrator. - :type note: str - :param identities: Collection of user identities. - :type identities: - list[~azure.mgmt.apimanagement.models.UserIdentityContract] - :param email: Email address. Must not be empty and must be unique within - the service instance. - :type email: str - :param password: User Password. - :type password: str - :param first_name: First name. - :type first_name: str - :param last_name: Last name. - :type last_name: str - """ - - _validation = { - 'email': {'max_length': 254, 'min_length': 1}, - 'first_name': {'max_length': 100, 'min_length': 1}, - 'last_name': {'max_length': 100, 'min_length': 1}, - } - - _attribute_map = { - 'state': {'key': 'properties.state', 'type': 'str'}, - 'note': {'key': 'properties.note', 'type': 'str'}, - 'identities': {'key': 'properties.identities', 'type': '[UserIdentityContract]'}, - 'email': {'key': 'properties.email', 'type': 'str'}, - 'password': {'key': 'properties.password', 'type': 'str'}, - 'first_name': {'key': 'properties.firstName', 'type': 'str'}, - 'last_name': {'key': 'properties.lastName', 'type': 'str'}, - } - - def __init__(self, **kwargs): - super(UserUpdateParameters, self).__init__(**kwargs) - self.state = kwargs.get('state', "active") - self.note = kwargs.get('note', None) - self.identities = kwargs.get('identities', None) - self.email = kwargs.get('email', None) - self.password = kwargs.get('password', None) - self.first_name = kwargs.get('first_name', None) - self.last_name = kwargs.get('last_name', None) diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/user_update_parameters_py3.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/user_update_parameters_py3.py deleted file mode 100644 index 8208852bdcb2..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/user_update_parameters_py3.py +++ /dev/null @@ -1,64 +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 UserUpdateParameters(Model): - """User update parameters. - - :param state: Account state. Specifies whether the user is active or not. - Blocked users are unable to sign into the developer portal or call any - APIs of subscribed products. Default state is Active. Possible values - include: 'active', 'blocked', 'pending', 'deleted'. Default value: - "active" . - :type state: str or ~azure.mgmt.apimanagement.models.UserState - :param note: Optional note about a user set by the administrator. - :type note: str - :param identities: Collection of user identities. - :type identities: - list[~azure.mgmt.apimanagement.models.UserIdentityContract] - :param email: Email address. Must not be empty and must be unique within - the service instance. - :type email: str - :param password: User Password. - :type password: str - :param first_name: First name. - :type first_name: str - :param last_name: Last name. - :type last_name: str - """ - - _validation = { - 'email': {'max_length': 254, 'min_length': 1}, - 'first_name': {'max_length': 100, 'min_length': 1}, - 'last_name': {'max_length': 100, 'min_length': 1}, - } - - _attribute_map = { - 'state': {'key': 'properties.state', 'type': 'str'}, - 'note': {'key': 'properties.note', 'type': 'str'}, - 'identities': {'key': 'properties.identities', 'type': '[UserIdentityContract]'}, - 'email': {'key': 'properties.email', 'type': 'str'}, - 'password': {'key': 'properties.password', 'type': 'str'}, - 'first_name': {'key': 'properties.firstName', 'type': 'str'}, - 'last_name': {'key': 'properties.lastName', 'type': 'str'}, - } - - def __init__(self, *, state="active", note: str=None, identities=None, email: str=None, password: str=None, first_name: str=None, last_name: str=None, **kwargs) -> None: - super(UserUpdateParameters, self).__init__(**kwargs) - self.state = state - self.note = note - self.identities = identities - self.email = email - self.password = password - self.first_name = first_name - self.last_name = last_name diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/virtual_network_configuration.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/virtual_network_configuration.py deleted file mode 100644 index 2bc74d949399..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/virtual_network_configuration.py +++ /dev/null @@ -1,48 +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 VirtualNetworkConfiguration(Model): - """Configuration of a virtual network to which API Management service is - deployed. - - Variables are only populated by the server, and will be ignored when - sending a request. - - :ivar vnetid: The virtual network ID. This is typically a GUID. Expect a - null GUID by default. - :vartype vnetid: str - :ivar subnetname: The name of the subnet. - :vartype subnetname: str - :param subnet_resource_id: The full resource ID of a subnet in a virtual - network to deploy the API Management service in. - :type subnet_resource_id: str - """ - - _validation = { - 'vnetid': {'readonly': True}, - 'subnetname': {'readonly': True}, - 'subnet_resource_id': {'pattern': r'^/subscriptions/[^/]*/resourceGroups/[^/]*/providers/Microsoft.(ClassicNetwork|Network)/virtualNetworks/[^/]*/subnets/[^/]*$'}, - } - - _attribute_map = { - 'vnetid': {'key': 'vnetid', 'type': 'str'}, - 'subnetname': {'key': 'subnetname', 'type': 'str'}, - 'subnet_resource_id': {'key': 'subnetResourceId', 'type': 'str'}, - } - - def __init__(self, **kwargs): - super(VirtualNetworkConfiguration, self).__init__(**kwargs) - self.vnetid = None - self.subnetname = None - self.subnet_resource_id = kwargs.get('subnet_resource_id', None) diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/virtual_network_configuration_py3.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/virtual_network_configuration_py3.py deleted file mode 100644 index 1cfd6c15d5a9..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/virtual_network_configuration_py3.py +++ /dev/null @@ -1,48 +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 VirtualNetworkConfiguration(Model): - """Configuration of a virtual network to which API Management service is - deployed. - - Variables are only populated by the server, and will be ignored when - sending a request. - - :ivar vnetid: The virtual network ID. This is typically a GUID. Expect a - null GUID by default. - :vartype vnetid: str - :ivar subnetname: The name of the subnet. - :vartype subnetname: str - :param subnet_resource_id: The full resource ID of a subnet in a virtual - network to deploy the API Management service in. - :type subnet_resource_id: str - """ - - _validation = { - 'vnetid': {'readonly': True}, - 'subnetname': {'readonly': True}, - 'subnet_resource_id': {'pattern': r'^/subscriptions/[^/]*/resourceGroups/[^/]*/providers/Microsoft.(ClassicNetwork|Network)/virtualNetworks/[^/]*/subnets/[^/]*$'}, - } - - _attribute_map = { - 'vnetid': {'key': 'vnetid', 'type': 'str'}, - 'subnetname': {'key': 'subnetname', 'type': 'str'}, - 'subnet_resource_id': {'key': 'subnetResourceId', 'type': 'str'}, - } - - def __init__(self, *, subnet_resource_id: str=None, **kwargs) -> None: - super(VirtualNetworkConfiguration, self).__init__(**kwargs) - self.vnetid = None - self.subnetname = None - self.subnet_resource_id = subnet_resource_id diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/x509_certificate_name.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/x509_certificate_name.py deleted file mode 100644 index 625c689ce7d2..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/x509_certificate_name.py +++ /dev/null @@ -1,33 +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 X509CertificateName(Model): - """Properties of server X509Names. - - :param name: Common Name of the Certificate. - :type name: str - :param issuer_certificate_thumbprint: Thumbprint for the Issuer of the - Certificate. - :type issuer_certificate_thumbprint: str - """ - - _attribute_map = { - 'name': {'key': 'name', 'type': 'str'}, - 'issuer_certificate_thumbprint': {'key': 'issuerCertificateThumbprint', 'type': 'str'}, - } - - def __init__(self, **kwargs): - super(X509CertificateName, self).__init__(**kwargs) - self.name = kwargs.get('name', None) - self.issuer_certificate_thumbprint = kwargs.get('issuer_certificate_thumbprint', None) diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/x509_certificate_name_py3.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/x509_certificate_name_py3.py deleted file mode 100644 index 6a0e571d3296..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/models/x509_certificate_name_py3.py +++ /dev/null @@ -1,33 +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 X509CertificateName(Model): - """Properties of server X509Names. - - :param name: Common Name of the Certificate. - :type name: str - :param issuer_certificate_thumbprint: Thumbprint for the Issuer of the - Certificate. - :type issuer_certificate_thumbprint: str - """ - - _attribute_map = { - 'name': {'key': 'name', 'type': 'str'}, - 'issuer_certificate_thumbprint': {'key': 'issuerCertificateThumbprint', 'type': 'str'}, - } - - def __init__(self, *, name: str=None, issuer_certificate_thumbprint: str=None, **kwargs) -> None: - super(X509CertificateName, self).__init__(**kwargs) - self.name = name - self.issuer_certificate_thumbprint = issuer_certificate_thumbprint diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/__init__.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/__init__.py index 1e1aeda77f92..985d086de7be 100644 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/__init__.py +++ b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/__init__.py @@ -9,67 +9,67 @@ # regenerated. # -------------------------------------------------------------------------- -from .api_operations import ApiOperations -from .api_revision_operations import ApiRevisionOperations -from .api_release_operations import ApiReleaseOperations -from .api_operation_operations import ApiOperationOperations -from .api_operation_policy_operations import ApiOperationPolicyOperations -from .tag_operations import TagOperations -from .api_product_operations import ApiProductOperations -from .api_policy_operations import ApiPolicyOperations -from .api_schema_operations import ApiSchemaOperations -from .api_diagnostic_operations import ApiDiagnosticOperations -from .api_issue_operations import ApiIssueOperations -from .api_issue_comment_operations import ApiIssueCommentOperations -from .api_issue_attachment_operations import ApiIssueAttachmentOperations -from .api_tag_description_operations import ApiTagDescriptionOperations -from .operation_operations import OperationOperations -from .api_version_set_operations import ApiVersionSetOperations -from .authorization_server_operations import AuthorizationServerOperations -from .backend_operations import BackendOperations -from .cache_operations import CacheOperations -from .certificate_operations import CertificateOperations -from .api_management_operations import ApiManagementOperations -from .api_management_service_skus_operations import ApiManagementServiceSkusOperations -from .api_management_service_operations import ApiManagementServiceOperations -from .diagnostic_operations import DiagnosticOperations -from .email_template_operations import EmailTemplateOperations -from .group_operations import GroupOperations -from .group_user_operations import GroupUserOperations -from .identity_provider_operations import IdentityProviderOperations -from .issue_operations import IssueOperations -from .logger_operations import LoggerOperations -from .network_status_operations import NetworkStatusOperations -from .notification_operations import NotificationOperations -from .notification_recipient_user_operations import NotificationRecipientUserOperations -from .notification_recipient_email_operations import NotificationRecipientEmailOperations -from .open_id_connect_provider_operations import OpenIdConnectProviderOperations -from .policy_operations import PolicyOperations -from .policy_snippet_operations import PolicySnippetOperations -from .sign_in_settings_operations import SignInSettingsOperations -from .sign_up_settings_operations import SignUpSettingsOperations -from .delegation_settings_operations import DelegationSettingsOperations -from .product_operations import ProductOperations -from .product_api_operations import ProductApiOperations -from .product_group_operations import ProductGroupOperations -from .product_subscriptions_operations import ProductSubscriptionsOperations -from .product_policy_operations import ProductPolicyOperations -from .property_operations import PropertyOperations -from .quota_by_counter_keys_operations import QuotaByCounterKeysOperations -from .quota_by_period_keys_operations import QuotaByPeriodKeysOperations -from .region_operations import RegionOperations -from .reports_operations import ReportsOperations -from .subscription_operations import SubscriptionOperations -from .tag_resource_operations import TagResourceOperations -from .tenant_access_operations import TenantAccessOperations -from .tenant_access_git_operations import TenantAccessGitOperations -from .tenant_configuration_operations import TenantConfigurationOperations -from .user_operations import UserOperations -from .user_group_operations import UserGroupOperations -from .user_subscription_operations import UserSubscriptionOperations -from .user_identities_operations import UserIdentitiesOperations -from .user_confirmation_password_operations import UserConfirmationPasswordOperations -from .api_export_operations import ApiExportOperations +from ._api_operations import ApiOperations +from ._api_revision_operations import ApiRevisionOperations +from ._api_release_operations import ApiReleaseOperations +from ._api_operation_operations import ApiOperationOperations +from ._api_operation_policy_operations import ApiOperationPolicyOperations +from ._tag_operations import TagOperations +from ._api_product_operations import ApiProductOperations +from ._api_policy_operations import ApiPolicyOperations +from ._api_schema_operations import ApiSchemaOperations +from ._api_diagnostic_operations import ApiDiagnosticOperations +from ._api_issue_operations import ApiIssueOperations +from ._api_issue_comment_operations import ApiIssueCommentOperations +from ._api_issue_attachment_operations import ApiIssueAttachmentOperations +from ._api_tag_description_operations import ApiTagDescriptionOperations +from ._operation_operations import OperationOperations +from ._api_version_set_operations import ApiVersionSetOperations +from ._authorization_server_operations import AuthorizationServerOperations +from ._backend_operations import BackendOperations +from ._cache_operations import CacheOperations +from ._certificate_operations import CertificateOperations +from ._api_management_operations import ApiManagementOperations +from ._api_management_service_skus_operations import ApiManagementServiceSkusOperations +from ._api_management_service_operations import ApiManagementServiceOperations +from ._diagnostic_operations import DiagnosticOperations +from ._email_template_operations import EmailTemplateOperations +from ._group_operations import GroupOperations +from ._group_user_operations import GroupUserOperations +from ._identity_provider_operations import IdentityProviderOperations +from ._issue_operations import IssueOperations +from ._logger_operations import LoggerOperations +from ._network_status_operations import NetworkStatusOperations +from ._notification_operations import NotificationOperations +from ._notification_recipient_user_operations import NotificationRecipientUserOperations +from ._notification_recipient_email_operations import NotificationRecipientEmailOperations +from ._open_id_connect_provider_operations import OpenIdConnectProviderOperations +from ._policy_operations import PolicyOperations +from ._policy_description_operations import PolicyDescriptionOperations +from ._sign_in_settings_operations import SignInSettingsOperations +from ._sign_up_settings_operations import SignUpSettingsOperations +from ._delegation_settings_operations import DelegationSettingsOperations +from ._product_operations import ProductOperations +from ._product_api_operations import ProductApiOperations +from ._product_group_operations import ProductGroupOperations +from ._product_subscriptions_operations import ProductSubscriptionsOperations +from ._product_policy_operations import ProductPolicyOperations +from ._named_value_operations import NamedValueOperations +from ._quota_by_counter_keys_operations import QuotaByCounterKeysOperations +from ._quota_by_period_keys_operations import QuotaByPeriodKeysOperations +from ._region_operations import RegionOperations +from ._reports_operations import ReportsOperations +from ._subscription_operations import SubscriptionOperations +from ._tag_resource_operations import TagResourceOperations +from ._tenant_access_operations import TenantAccessOperations +from ._tenant_access_git_operations import TenantAccessGitOperations +from ._tenant_configuration_operations import TenantConfigurationOperations +from ._user_operations import UserOperations +from ._user_group_operations import UserGroupOperations +from ._user_subscription_operations import UserSubscriptionOperations +from ._user_identities_operations import UserIdentitiesOperations +from ._user_confirmation_password_operations import UserConfirmationPasswordOperations +from ._api_export_operations import ApiExportOperations __all__ = [ 'ApiOperations', @@ -108,7 +108,7 @@ 'NotificationRecipientEmailOperations', 'OpenIdConnectProviderOperations', 'PolicyOperations', - 'PolicySnippetOperations', + 'PolicyDescriptionOperations', 'SignInSettingsOperations', 'SignUpSettingsOperations', 'DelegationSettingsOperations', @@ -117,7 +117,7 @@ 'ProductGroupOperations', 'ProductSubscriptionsOperations', 'ProductPolicyOperations', - 'PropertyOperations', + 'NamedValueOperations', 'QuotaByCounterKeysOperations', 'QuotaByPeriodKeysOperations', 'RegionOperations', diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/api_diagnostic_operations.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/_api_diagnostic_operations.py similarity index 97% rename from sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/api_diagnostic_operations.py rename to sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/_api_diagnostic_operations.py index b00a8d13b667..4d4eab437e64 100644 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/api_diagnostic_operations.py +++ b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/_api_diagnostic_operations.py @@ -18,11 +18,13 @@ class ApiDiagnosticOperations(object): """ApiDiagnosticOperations operations. + You should not instantiate directly this class, but create a Client instance that will create it for you and attach it as attribute. + :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: "2019-01-01". + :ivar api_version: Version of the API to be used with the client request. Constant value: "2019-12-01-preview". """ models = models @@ -32,7 +34,7 @@ def __init__(self, client, config, serializer, deserializer): self._client = client self._serialize = serializer self._deserialize = deserializer - self.api_version = "2019-01-01" + self.api_version = "2019-12-01-preview" self.config = config @@ -68,15 +70,14 @@ def list_by_service( :raises: :class:`ErrorResponseException` """ - def internal_paging(next_link=None, raw=False): - + def prepare_request(next_link=None): 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'^[^*#&+:<>?]+$'), + 'apiId': self._serialize.url("api_id", api_id, 'str', max_length=80, min_length=1), 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str') } url = self._client.format_url(url, **path_format_arguments) @@ -107,6 +108,11 @@ def internal_paging(next_link=None, raw=False): # Construct and send request request = self._client.get(url, query_parameters, header_parameters) + return request + + def internal_paging(next_link=None): + request = prepare_request(next_link) + response = self._client.send(request, stream=False, **operation_config) if response.status_code not in [200]: @@ -115,12 +121,10 @@ def internal_paging(next_link=None, raw=False): return response # Deserialize response - deserialized = models.DiagnosticContractPaged(internal_paging, self._deserialize.dependencies) - + header_dict = None if raw: header_dict = {} - client_raw_response = models.DiagnosticContractPaged(internal_paging, self._deserialize.dependencies, header_dict) - return client_raw_response + deserialized = models.DiagnosticContractPaged(internal_paging, self._deserialize.dependencies, header_dict) return deserialized list_by_service.metadata = {'url': '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ApiManagement/service/{serviceName}/apis/{apiId}/diagnostics'} @@ -155,7 +159,7 @@ def get_entity_tag( 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'^[^*#&+:<>?]+$'), + 'apiId': self._serialize.url("api_id", api_id, 'str', max_length=80, min_length=1), 'diagnosticId': self._serialize.url("diagnostic_id", diagnostic_id, 'str', max_length=80, min_length=1, pattern=r'^[^*#&+:<>?]+$'), 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str') } @@ -220,7 +224,7 @@ def get( 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'^[^*#&+:<>?]+$'), + 'apiId': self._serialize.url("api_id", api_id, 'str', max_length=80, min_length=1), 'diagnosticId': self._serialize.url("diagnostic_id", diagnostic_id, 'str', max_length=80, min_length=1, pattern=r'^[^*#&+:<>?]+$'), 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str') } @@ -247,9 +251,8 @@ def get( if response.status_code not in [200]: raise models.ErrorResponseException(self._deserialize, response) - deserialized = None header_dict = {} - + deserialized = None if response.status_code == 200: deserialized = self._deserialize('DiagnosticContract', response) header_dict = { @@ -299,7 +302,7 @@ def create_or_update( 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'^[^*#&+:<>?]+$'), + 'apiId': self._serialize.url("api_id", api_id, 'str', max_length=80, min_length=1), 'diagnosticId': self._serialize.url("diagnostic_id", diagnostic_id, 'str', max_length=80, min_length=1, pattern=r'^[^*#&+:<>?]+$'), 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str') } @@ -332,9 +335,8 @@ def create_or_update( if response.status_code not in [200, 201]: raise models.ErrorResponseException(self._deserialize, response) - deserialized = None header_dict = {} - + deserialized = None if response.status_code == 200: deserialized = self._deserialize('DiagnosticContract', response) header_dict = { @@ -390,7 +392,7 @@ def update( 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'^[^*#&+:<>?]+$'), + 'apiId': self._serialize.url("api_id", api_id, 'str', max_length=80, min_length=1), 'diagnosticId': self._serialize.url("diagnostic_id", diagnostic_id, 'str', max_length=80, min_length=1, pattern=r'^[^*#&+:<>?]+$'), 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str') } @@ -459,7 +461,7 @@ def delete( 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'^[^*#&+:<>?]+$'), + 'apiId': self._serialize.url("api_id", api_id, 'str', max_length=80, min_length=1), 'diagnosticId': self._serialize.url("diagnostic_id", diagnostic_id, 'str', max_length=80, min_length=1, pattern=r'^[^*#&+:<>?]+$'), 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str') } diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/api_export_operations.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/_api_export_operations.py similarity index 94% rename from sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/api_export_operations.py rename to sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/_api_export_operations.py index 18aa4a080a00..043567b966a7 100644 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/api_export_operations.py +++ b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/_api_export_operations.py @@ -18,12 +18,14 @@ class ApiExportOperations(object): """ApiExportOperations operations. + You should not instantiate directly this class, but create a Client instance that will create it for you and attach it as attribute. + :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 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: "2019-01-01". + :ivar api_version: Version of the API to be used with the client request. Constant value: "2019-12-01-preview". """ models = models @@ -34,7 +36,7 @@ def __init__(self, client, config, serializer, deserializer): self._serialize = serializer self._deserialize = deserializer self.export = "true" - self.api_version = "2019-01-01" + self.api_version = "2019-12-01-preview" self.config = config @@ -53,7 +55,7 @@ def get( :type api_id: str :param format: Format in which to export the Api Details to the Storage Blob with Sas Key valid for 5 minutes. Possible values - include: 'Swagger', 'Wsdl', 'Wadl', 'Openapi' + include: 'Swagger', 'Wsdl', 'Wadl', 'Openapi', 'OpenapiJson' :type format: str or ~azure.mgmt.apimanagement.models.ExportFormat :param dict custom_headers: headers that will be added to the request :param bool raw: returns the direct response alongside the @@ -100,7 +102,6 @@ def get( raise models.ErrorResponseException(self._deserialize, response) deserialized = None - if response.status_code == 200: deserialized = self._deserialize('ApiExportResult', response) diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/api_issue_attachment_operations.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/_api_issue_attachment_operations.py similarity index 97% rename from sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/api_issue_attachment_operations.py rename to sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/_api_issue_attachment_operations.py index 859143e02e2f..0ab62b59ae4b 100644 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/api_issue_attachment_operations.py +++ b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/_api_issue_attachment_operations.py @@ -18,11 +18,13 @@ class ApiIssueAttachmentOperations(object): """ApiIssueAttachmentOperations operations. + You should not instantiate directly this class, but create a Client instance that will create it for you and attach it as attribute. + :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: "2019-01-01". + :ivar api_version: Version of the API to be used with the client request. Constant value: "2019-12-01-preview". """ models = models @@ -32,7 +34,7 @@ def __init__(self, client, config, serializer, deserializer): self._client = client self._serialize = serializer self._deserialize = deserializer - self.api_version = "2019-01-01" + self.api_version = "2019-12-01-preview" self.config = config @@ -72,15 +74,14 @@ def list_by_service( :raises: :class:`ErrorResponseException` """ - def internal_paging(next_link=None, raw=False): - + def prepare_request(next_link=None): 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'^[^*#&+:<>?]+$'), + 'apiId': self._serialize.url("api_id", api_id, 'str', max_length=80, min_length=1), 'issueId': self._serialize.url("issue_id", issue_id, 'str', max_length=256, min_length=1, pattern=r'^[^*#&+:<>?]+$'), 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str') } @@ -112,6 +113,11 @@ def internal_paging(next_link=None, raw=False): # Construct and send request request = self._client.get(url, query_parameters, header_parameters) + return request + + def internal_paging(next_link=None): + request = prepare_request(next_link) + response = self._client.send(request, stream=False, **operation_config) if response.status_code not in [200]: @@ -120,12 +126,10 @@ def internal_paging(next_link=None, raw=False): return response # Deserialize response - deserialized = models.IssueAttachmentContractPaged(internal_paging, self._deserialize.dependencies) - + header_dict = None if raw: header_dict = {} - client_raw_response = models.IssueAttachmentContractPaged(internal_paging, self._deserialize.dependencies, header_dict) - return client_raw_response + deserialized = models.IssueAttachmentContractPaged(internal_paging, self._deserialize.dependencies, header_dict) return deserialized list_by_service.metadata = {'url': '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ApiManagement/service/{serviceName}/apis/{apiId}/issues/{issueId}/attachments'} @@ -163,7 +167,7 @@ def get_entity_tag( 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'^[^*#&+:<>?]+$'), + 'apiId': self._serialize.url("api_id", api_id, 'str', max_length=80, min_length=1), 'issueId': self._serialize.url("issue_id", issue_id, 'str', max_length=256, min_length=1, pattern=r'^[^*#&+:<>?]+$'), 'attachmentId': self._serialize.url("attachment_id", attachment_id, 'str', max_length=256, min_length=1, pattern=r'^[^*#&+:<>?]+$'), 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str') @@ -232,7 +236,7 @@ def get( 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'^[^*#&+:<>?]+$'), + 'apiId': self._serialize.url("api_id", api_id, 'str', max_length=80, min_length=1), 'issueId': self._serialize.url("issue_id", issue_id, 'str', max_length=256, min_length=1, pattern=r'^[^*#&+:<>?]+$'), 'attachmentId': self._serialize.url("attachment_id", attachment_id, 'str', max_length=256, min_length=1, pattern=r'^[^*#&+:<>?]+$'), 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str') @@ -260,9 +264,8 @@ def get( if response.status_code not in [200]: raise models.ErrorResponseException(self._deserialize, response) - deserialized = None header_dict = {} - + deserialized = None if response.status_code == 200: deserialized = self._deserialize('IssueAttachmentContract', response) header_dict = { @@ -317,7 +320,7 @@ def create_or_update( 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'^[^*#&+:<>?]+$'), + 'apiId': self._serialize.url("api_id", api_id, 'str', max_length=80, min_length=1), 'issueId': self._serialize.url("issue_id", issue_id, 'str', max_length=256, min_length=1, pattern=r'^[^*#&+:<>?]+$'), 'attachmentId': self._serialize.url("attachment_id", attachment_id, 'str', max_length=256, min_length=1, pattern=r'^[^*#&+:<>?]+$'), 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str') @@ -351,9 +354,8 @@ def create_or_update( if response.status_code not in [200, 201]: raise models.ErrorResponseException(self._deserialize, response) - deserialized = None header_dict = {} - + deserialized = None if response.status_code == 200: deserialized = self._deserialize('IssueAttachmentContract', response) header_dict = { @@ -409,7 +411,7 @@ def delete( 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'^[^*#&+:<>?]+$'), + 'apiId': self._serialize.url("api_id", api_id, 'str', max_length=80, min_length=1), 'issueId': self._serialize.url("issue_id", issue_id, 'str', max_length=256, min_length=1, pattern=r'^[^*#&+:<>?]+$'), 'attachmentId': self._serialize.url("attachment_id", attachment_id, 'str', max_length=256, min_length=1, pattern=r'^[^*#&+:<>?]+$'), 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str') diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/api_issue_comment_operations.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/_api_issue_comment_operations.py similarity index 97% rename from sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/api_issue_comment_operations.py rename to sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/_api_issue_comment_operations.py index d6598520f1dc..1e03ad6f1b32 100644 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/api_issue_comment_operations.py +++ b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/_api_issue_comment_operations.py @@ -18,11 +18,13 @@ class ApiIssueCommentOperations(object): """ApiIssueCommentOperations operations. + You should not instantiate directly this class, but create a Client instance that will create it for you and attach it as attribute. + :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: "2019-01-01". + :ivar api_version: Version of the API to be used with the client request. Constant value: "2019-12-01-preview". """ models = models @@ -32,7 +34,7 @@ def __init__(self, client, config, serializer, deserializer): self._client = client self._serialize = serializer self._deserialize = deserializer - self.api_version = "2019-01-01" + self.api_version = "2019-12-01-preview" self.config = config @@ -72,15 +74,14 @@ def list_by_service( :raises: :class:`ErrorResponseException` """ - def internal_paging(next_link=None, raw=False): - + def prepare_request(next_link=None): 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'^[^*#&+:<>?]+$'), + 'apiId': self._serialize.url("api_id", api_id, 'str', max_length=80, min_length=1), 'issueId': self._serialize.url("issue_id", issue_id, 'str', max_length=256, min_length=1, pattern=r'^[^*#&+:<>?]+$'), 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str') } @@ -112,6 +113,11 @@ def internal_paging(next_link=None, raw=False): # Construct and send request request = self._client.get(url, query_parameters, header_parameters) + return request + + def internal_paging(next_link=None): + request = prepare_request(next_link) + response = self._client.send(request, stream=False, **operation_config) if response.status_code not in [200]: @@ -120,12 +126,10 @@ def internal_paging(next_link=None, raw=False): return response # Deserialize response - deserialized = models.IssueCommentContractPaged(internal_paging, self._deserialize.dependencies) - + header_dict = None if raw: header_dict = {} - client_raw_response = models.IssueCommentContractPaged(internal_paging, self._deserialize.dependencies, header_dict) - return client_raw_response + deserialized = models.IssueCommentContractPaged(internal_paging, self._deserialize.dependencies, header_dict) return deserialized list_by_service.metadata = {'url': '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ApiManagement/service/{serviceName}/apis/{apiId}/issues/{issueId}/comments'} @@ -163,7 +167,7 @@ def get_entity_tag( 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'^[^*#&+:<>?]+$'), + 'apiId': self._serialize.url("api_id", api_id, 'str', max_length=80, min_length=1), 'issueId': self._serialize.url("issue_id", issue_id, 'str', max_length=256, min_length=1, pattern=r'^[^*#&+:<>?]+$'), 'commentId': self._serialize.url("comment_id", comment_id, 'str', max_length=256, min_length=1, pattern=r'^[^*#&+:<>?]+$'), 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str') @@ -232,7 +236,7 @@ def get( 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'^[^*#&+:<>?]+$'), + 'apiId': self._serialize.url("api_id", api_id, 'str', max_length=80, min_length=1), 'issueId': self._serialize.url("issue_id", issue_id, 'str', max_length=256, min_length=1, pattern=r'^[^*#&+:<>?]+$'), 'commentId': self._serialize.url("comment_id", comment_id, 'str', max_length=256, min_length=1, pattern=r'^[^*#&+:<>?]+$'), 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str') @@ -260,9 +264,8 @@ def get( if response.status_code not in [200]: raise models.ErrorResponseException(self._deserialize, response) - deserialized = None header_dict = {} - + deserialized = None if response.status_code == 200: deserialized = self._deserialize('IssueCommentContract', response) header_dict = { @@ -317,7 +320,7 @@ def create_or_update( 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'^[^*#&+:<>?]+$'), + 'apiId': self._serialize.url("api_id", api_id, 'str', max_length=80, min_length=1), 'issueId': self._serialize.url("issue_id", issue_id, 'str', max_length=256, min_length=1, pattern=r'^[^*#&+:<>?]+$'), 'commentId': self._serialize.url("comment_id", comment_id, 'str', max_length=256, min_length=1, pattern=r'^[^*#&+:<>?]+$'), 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str') @@ -351,9 +354,8 @@ def create_or_update( if response.status_code not in [200, 201]: raise models.ErrorResponseException(self._deserialize, response) - deserialized = None header_dict = {} - + deserialized = None if response.status_code == 200: deserialized = self._deserialize('IssueCommentContract', response) header_dict = { @@ -409,7 +411,7 @@ def delete( 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'^[^*#&+:<>?]+$'), + 'apiId': self._serialize.url("api_id", api_id, 'str', max_length=80, min_length=1), 'issueId': self._serialize.url("issue_id", issue_id, 'str', max_length=256, min_length=1, pattern=r'^[^*#&+:<>?]+$'), 'commentId': self._serialize.url("comment_id", comment_id, 'str', max_length=256, min_length=1, pattern=r'^[^*#&+:<>?]+$'), 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str') diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/api_issue_operations.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/_api_issue_operations.py similarity index 97% rename from sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/api_issue_operations.py rename to sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/_api_issue_operations.py index c513d93b2c20..fd8fe7944878 100644 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/api_issue_operations.py +++ b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/_api_issue_operations.py @@ -18,11 +18,13 @@ class ApiIssueOperations(object): """ApiIssueOperations operations. + You should not instantiate directly this class, but create a Client instance that will create it for you and attach it as attribute. + :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: "2019-01-01". + :ivar api_version: Version of the API to be used with the client request. Constant value: "2019-12-01-preview". """ models = models @@ -32,7 +34,7 @@ def __init__(self, client, config, serializer, deserializer): self._client = client self._serialize = serializer self._deserialize = deserializer - self.api_version = "2019-01-01" + self.api_version = "2019-12-01-preview" self.config = config @@ -72,15 +74,14 @@ def list_by_service( :raises: :class:`ErrorResponseException` """ - def internal_paging(next_link=None, raw=False): - + def prepare_request(next_link=None): 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'^[^*#&+:<>?]+$'), + 'apiId': self._serialize.url("api_id", api_id, 'str', max_length=80, min_length=1), 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str') } url = self._client.format_url(url, **path_format_arguments) @@ -113,6 +114,11 @@ def internal_paging(next_link=None, raw=False): # Construct and send request request = self._client.get(url, query_parameters, header_parameters) + return request + + def internal_paging(next_link=None): + request = prepare_request(next_link) + response = self._client.send(request, stream=False, **operation_config) if response.status_code not in [200]: @@ -121,12 +127,10 @@ def internal_paging(next_link=None, raw=False): return response # Deserialize response - deserialized = models.IssueContractPaged(internal_paging, self._deserialize.dependencies) - + header_dict = None if raw: header_dict = {} - client_raw_response = models.IssueContractPaged(internal_paging, self._deserialize.dependencies, header_dict) - return client_raw_response + deserialized = models.IssueContractPaged(internal_paging, self._deserialize.dependencies, header_dict) return deserialized list_by_service.metadata = {'url': '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ApiManagement/service/{serviceName}/apis/{apiId}/issues'} @@ -161,7 +165,7 @@ def get_entity_tag( 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'^[^*#&+:<>?]+$'), + 'apiId': self._serialize.url("api_id", api_id, 'str', max_length=80, min_length=1), 'issueId': self._serialize.url("issue_id", issue_id, 'str', max_length=256, min_length=1, pattern=r'^[^*#&+:<>?]+$'), 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str') } @@ -227,7 +231,7 @@ def get( 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'^[^*#&+:<>?]+$'), + 'apiId': self._serialize.url("api_id", api_id, 'str', max_length=80, min_length=1), 'issueId': self._serialize.url("issue_id", issue_id, 'str', max_length=256, min_length=1, pattern=r'^[^*#&+:<>?]+$'), 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str') } @@ -256,9 +260,8 @@ def get( if response.status_code not in [200]: raise models.ErrorResponseException(self._deserialize, response) - deserialized = None header_dict = {} - + deserialized = None if response.status_code == 200: deserialized = self._deserialize('IssueContract', response) header_dict = { @@ -308,7 +311,7 @@ def create_or_update( 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'^[^*#&+:<>?]+$'), + 'apiId': self._serialize.url("api_id", api_id, 'str', max_length=80, min_length=1), 'issueId': self._serialize.url("issue_id", issue_id, 'str', max_length=256, min_length=1, pattern=r'^[^*#&+:<>?]+$'), 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str') } @@ -341,9 +344,8 @@ def create_or_update( if response.status_code not in [200, 201]: raise models.ErrorResponseException(self._deserialize, response) - deserialized = None header_dict = {} - + deserialized = None if response.status_code == 200: deserialized = self._deserialize('IssueContract', response) header_dict = { @@ -398,7 +400,7 @@ def update( 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'^[^*#&+:<>?]+$'), + 'apiId': self._serialize.url("api_id", api_id, 'str', max_length=80, min_length=1), 'issueId': self._serialize.url("issue_id", issue_id, 'str', max_length=256, min_length=1, pattern=r'^[^*#&+:<>?]+$'), 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str') } @@ -467,7 +469,7 @@ def delete( 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'^[^*#&+:<>?]+$'), + 'apiId': self._serialize.url("api_id", api_id, 'str', max_length=80, min_length=1), 'issueId': self._serialize.url("issue_id", issue_id, 'str', max_length=256, min_length=1, pattern=r'^[^*#&+:<>?]+$'), 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str') } diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/api_management_operations.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/_api_management_operations.py similarity index 88% rename from sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/api_management_operations.py rename to sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/_api_management_operations.py index a6e74dd10cce..8412f3edcc1e 100644 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/api_management_operations.py +++ b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/_api_management_operations.py @@ -19,11 +19,13 @@ class ApiManagementOperations(object): """ApiManagementOperations operations. + You should not instantiate directly this class, but create a Client instance that will create it for you and attach it as attribute. + :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: "2019-01-01". + :ivar api_version: Version of the API to be used with the client request. Constant value: "2019-12-01-preview". """ models = models @@ -33,7 +35,7 @@ def __init__(self, client, config, serializer, deserializer): self._client = client self._serialize = serializer self._deserialize = deserializer - self.api_version = "2019-01-01" + self.api_version = "2019-12-01-preview" self.config = config @@ -52,8 +54,7 @@ def list( ~azure.mgmt.apimanagement.models.OperationPaged[~azure.mgmt.apimanagement.models.Operation] :raises: :class:`CloudError` """ - def internal_paging(next_link=None, raw=False): - + def prepare_request(next_link=None): if not next_link: # Construct URL url = self.list.metadata['url'] @@ -78,6 +79,11 @@ def internal_paging(next_link=None, raw=False): # Construct and send request request = self._client.get(url, query_parameters, header_parameters) + return request + + def internal_paging(next_link=None): + request = prepare_request(next_link) + response = self._client.send(request, stream=False, **operation_config) if response.status_code not in [200]: @@ -88,12 +94,10 @@ def internal_paging(next_link=None, raw=False): return response # Deserialize response - deserialized = models.OperationPaged(internal_paging, self._deserialize.dependencies) - + header_dict = None if raw: header_dict = {} - client_raw_response = models.OperationPaged(internal_paging, self._deserialize.dependencies, header_dict) - return client_raw_response + deserialized = models.OperationPaged(internal_paging, self._deserialize.dependencies, header_dict) return deserialized list.metadata = {'url': '/providers/Microsoft.ApiManagement/operations'} diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/api_management_service_operations.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/_api_management_service_operations.py similarity index 94% rename from sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/api_management_service_operations.py rename to sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/_api_management_service_operations.py index 5f7313e5fdf4..2b0bf98b9746 100644 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/api_management_service_operations.py +++ b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/_api_management_service_operations.py @@ -21,11 +21,13 @@ class ApiManagementServiceOperations(object): """ApiManagementServiceOperations operations. + You should not instantiate directly this class, but create a Client instance that will create it for you and attach it as attribute. + :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: "2019-01-01". + :ivar api_version: Version of the API to be used with the client request. Constant value: "2019-12-01-preview". """ models = models @@ -35,7 +37,7 @@ def __init__(self, client, config, serializer, deserializer): self._client = client self._serialize = serializer self._deserialize = deserializer - self.api_version = "2019-01-01" + self.api_version = "2019-12-01-preview" self.config = config @@ -74,9 +76,7 @@ def _restore_initial( response = self._client.send(request, stream=False, **operation_config) if response.status_code not in [200, 202]: - exp = CloudError(response) - exp.request_id = response.headers.get('x-ms-request-id') - raise exp + raise models.ErrorResponseException(self._deserialize, response) deserialized = None @@ -115,7 +115,8 @@ def restore( ~msrestazure.azure_operation.AzureOperationPoller[~azure.mgmt.apimanagement.models.ApiManagementServiceResource] or ~msrestazure.azure_operation.AzureOperationPoller[~msrest.pipeline.ClientRawResponse[~azure.mgmt.apimanagement.models.ApiManagementServiceResource]] - :raises: :class:`CloudError` + :raises: + :class:`ErrorResponseException` """ raw_result = self._restore_initial( resource_group_name=resource_group_name, @@ -179,9 +180,7 @@ def _backup_initial( response = self._client.send(request, stream=False, **operation_config) if response.status_code not in [200, 202]: - exp = CloudError(response) - exp.request_id = response.headers.get('x-ms-request-id') - raise exp + raise models.ErrorResponseException(self._deserialize, response) deserialized = None @@ -220,7 +219,8 @@ def backup( ~msrestazure.azure_operation.AzureOperationPoller[~azure.mgmt.apimanagement.models.ApiManagementServiceResource] or ~msrestazure.azure_operation.AzureOperationPoller[~msrest.pipeline.ClientRawResponse[~azure.mgmt.apimanagement.models.ApiManagementServiceResource]] - :raises: :class:`CloudError` + :raises: + :class:`ErrorResponseException` """ raw_result = self._backup_initial( resource_group_name=resource_group_name, @@ -284,9 +284,7 @@ def _create_or_update_initial( response = self._client.send(request, stream=False, **operation_config) if response.status_code not in [200, 201, 202]: - exp = CloudError(response) - exp.request_id = response.headers.get('x-ms-request-id') - raise exp + raise models.ErrorResponseException(self._deserialize, response) deserialized = None @@ -326,7 +324,8 @@ def create_or_update( ~msrestazure.azure_operation.AzureOperationPoller[~azure.mgmt.apimanagement.models.ApiManagementServiceResource] or ~msrestazure.azure_operation.AzureOperationPoller[~msrest.pipeline.ClientRawResponse[~azure.mgmt.apimanagement.models.ApiManagementServiceResource]] - :raises: :class:`CloudError` + :raises: + :class:`ErrorResponseException` """ raw_result = self._create_or_update_initial( resource_group_name=resource_group_name, @@ -390,9 +389,7 @@ def _update_initial( response = self._client.send(request, stream=False, **operation_config) if response.status_code not in [200, 202]: - exp = CloudError(response) - exp.request_id = response.headers.get('x-ms-request-id') - raise exp + raise models.ErrorResponseException(self._deserialize, response) deserialized = None @@ -429,7 +426,8 @@ def update( ~msrestazure.azure_operation.AzureOperationPoller[~azure.mgmt.apimanagement.models.ApiManagementServiceResource] or ~msrestazure.azure_operation.AzureOperationPoller[~msrest.pipeline.ClientRawResponse[~azure.mgmt.apimanagement.models.ApiManagementServiceResource]] - :raises: :class:`CloudError` + :raises: + :class:`ErrorResponseException` """ raw_result = self._update_initial( resource_group_name=resource_group_name, @@ -474,7 +472,8 @@ def get( :return: ApiManagementServiceResource or ClientRawResponse if raw=true :rtype: ~azure.mgmt.apimanagement.models.ApiManagementServiceResource or ~msrest.pipeline.ClientRawResponse - :raises: :class:`CloudError` + :raises: + :class:`ErrorResponseException` """ # Construct URL url = self.get.metadata['url'] @@ -504,12 +503,9 @@ def get( response = self._client.send(request, stream=False, **operation_config) if response.status_code not in [200]: - exp = CloudError(response) - exp.request_id = response.headers.get('x-ms-request-id') - raise exp + raise models.ErrorResponseException(self._deserialize, response) deserialized = None - if response.status_code == 200: deserialized = self._deserialize('ApiManagementServiceResource', response) @@ -551,9 +547,7 @@ def _delete_initial( response = self._client.send(request, stream=False, **operation_config) if response.status_code not in [200, 202, 204]: - exp = CloudError(response) - exp.request_id = response.headers.get('x-ms-request-id') - raise exp + raise models.ErrorResponseException(self._deserialize, response) deserialized = None @@ -586,7 +580,8 @@ def delete( ~msrestazure.azure_operation.AzureOperationPoller[~azure.mgmt.apimanagement.models.ApiManagementServiceResource] or ~msrestazure.azure_operation.AzureOperationPoller[~msrest.pipeline.ClientRawResponse[~azure.mgmt.apimanagement.models.ApiManagementServiceResource]] - :raises: :class:`CloudError` + :raises: + :class:`ErrorResponseException` """ raw_result = self._delete_initial( resource_group_name=resource_group_name, @@ -628,10 +623,10 @@ def list_by_resource_group( :return: An iterator like instance of ApiManagementServiceResource :rtype: ~azure.mgmt.apimanagement.models.ApiManagementServiceResourcePaged[~azure.mgmt.apimanagement.models.ApiManagementServiceResource] - :raises: :class:`CloudError` + :raises: + :class:`ErrorResponseException` """ - def internal_paging(next_link=None, raw=False): - + def prepare_request(next_link=None): if not next_link: # Construct URL url = self.list_by_resource_group.metadata['url'] @@ -661,22 +656,23 @@ def internal_paging(next_link=None, raw=False): # Construct and send request request = self._client.get(url, query_parameters, header_parameters) + return request + + def internal_paging(next_link=None): + request = prepare_request(next_link) + response = self._client.send(request, stream=False, **operation_config) if response.status_code not in [200]: - exp = CloudError(response) - exp.request_id = response.headers.get('x-ms-request-id') - raise exp + raise models.ErrorResponseException(self._deserialize, response) return response # Deserialize response - deserialized = models.ApiManagementServiceResourcePaged(internal_paging, self._deserialize.dependencies) - + header_dict = None if raw: header_dict = {} - client_raw_response = models.ApiManagementServiceResourcePaged(internal_paging, self._deserialize.dependencies, header_dict) - return client_raw_response + deserialized = models.ApiManagementServiceResourcePaged(internal_paging, self._deserialize.dependencies, header_dict) return deserialized list_by_resource_group.metadata = {'url': '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ApiManagement/service'} @@ -695,8 +691,7 @@ def list( ~azure.mgmt.apimanagement.models.ApiManagementServiceResourcePaged[~azure.mgmt.apimanagement.models.ApiManagementServiceResource] :raises: :class:`CloudError` """ - def internal_paging(next_link=None, raw=False): - + def prepare_request(next_link=None): if not next_link: # Construct URL url = self.list.metadata['url'] @@ -725,6 +720,11 @@ def internal_paging(next_link=None, raw=False): # Construct and send request request = self._client.get(url, query_parameters, header_parameters) + return request + + def internal_paging(next_link=None): + request = prepare_request(next_link) + response = self._client.send(request, stream=False, **operation_config) if response.status_code not in [200]: @@ -735,12 +735,10 @@ def internal_paging(next_link=None, raw=False): return response # Deserialize response - deserialized = models.ApiManagementServiceResourcePaged(internal_paging, self._deserialize.dependencies) - + header_dict = None if raw: header_dict = {} - client_raw_response = models.ApiManagementServiceResourcePaged(internal_paging, self._deserialize.dependencies, header_dict) - return client_raw_response + deserialized = models.ApiManagementServiceResourcePaged(internal_paging, self._deserialize.dependencies, header_dict) return deserialized list.metadata = {'url': '/subscriptions/{subscriptionId}/providers/Microsoft.ApiManagement/service'} @@ -764,7 +762,8 @@ def get_sso_token( :rtype: ~azure.mgmt.apimanagement.models.ApiManagementServiceGetSsoTokenResult or ~msrest.pipeline.ClientRawResponse - :raises: :class:`CloudError` + :raises: + :class:`ErrorResponseException` """ # Construct URL url = self.get_sso_token.metadata['url'] @@ -794,12 +793,9 @@ def get_sso_token( response = self._client.send(request, stream=False, **operation_config) if response.status_code not in [200]: - exp = CloudError(response) - exp.request_id = response.headers.get('x-ms-request-id') - raise exp + raise models.ErrorResponseException(self._deserialize, response) deserialized = None - if response.status_code == 200: deserialized = self._deserialize('ApiManagementServiceGetSsoTokenResult', response) @@ -827,7 +823,8 @@ def check_name_availability( :rtype: ~azure.mgmt.apimanagement.models.ApiManagementServiceNameAvailabilityResult or ~msrest.pipeline.ClientRawResponse - :raises: :class:`CloudError` + :raises: + :class:`ErrorResponseException` """ parameters = models.ApiManagementServiceCheckNameAvailabilityParameters(name=name) @@ -861,12 +858,9 @@ def check_name_availability( response = self._client.send(request, stream=False, **operation_config) if response.status_code not in [200]: - exp = CloudError(response) - exp.request_id = response.headers.get('x-ms-request-id') - raise exp + raise models.ErrorResponseException(self._deserialize, response) deserialized = None - if response.status_code == 200: deserialized = self._deserialize('ApiManagementServiceNameAvailabilityResult', response) @@ -919,9 +913,7 @@ def _apply_network_configuration_updates_initial( response = self._client.send(request, stream=False, **operation_config) if response.status_code not in [200, 202]: - exp = CloudError(response) - exp.request_id = response.headers.get('x-ms-request-id') - raise exp + raise models.ErrorResponseException(self._deserialize, response) deserialized = None @@ -959,7 +951,8 @@ def apply_network_configuration_updates( ~msrestazure.azure_operation.AzureOperationPoller[~azure.mgmt.apimanagement.models.ApiManagementServiceResource] or ~msrestazure.azure_operation.AzureOperationPoller[~msrest.pipeline.ClientRawResponse[~azure.mgmt.apimanagement.models.ApiManagementServiceResource]] - :raises: :class:`CloudError` + :raises: + :class:`ErrorResponseException` """ raw_result = self._apply_network_configuration_updates_initial( resource_group_name=resource_group_name, diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/api_management_service_skus_operations.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/_api_management_service_skus_operations.py similarity index 86% rename from sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/api_management_service_skus_operations.py rename to sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/_api_management_service_skus_operations.py index 876da69e682e..0d3bdb858c08 100644 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/api_management_service_skus_operations.py +++ b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/_api_management_service_skus_operations.py @@ -11,7 +11,6 @@ import uuid from msrest.pipeline import ClientRawResponse -from msrestazure.azure_exceptions import CloudError from .. import models @@ -19,11 +18,13 @@ class ApiManagementServiceSkusOperations(object): """ApiManagementServiceSkusOperations operations. + You should not instantiate directly this class, but create a Client instance that will create it for you and attach it as attribute. + :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: "2019-01-01". + :ivar api_version: Version of the API to be used with the client request. Constant value: "2019-12-01-preview". """ models = models @@ -33,7 +34,7 @@ def __init__(self, client, config, serializer, deserializer): self._client = client self._serialize = serializer self._deserialize = deserializer - self.api_version = "2019-01-01" + self.api_version = "2019-12-01-preview" self.config = config @@ -55,10 +56,10 @@ def list_available_service_skus( :return: An iterator like instance of ResourceSkuResult :rtype: ~azure.mgmt.apimanagement.models.ResourceSkuResultPaged[~azure.mgmt.apimanagement.models.ResourceSkuResult] - :raises: :class:`CloudError` + :raises: + :class:`ErrorResponseException` """ - def internal_paging(next_link=None, raw=False): - + def prepare_request(next_link=None): if not next_link: # Construct URL url = self.list_available_service_skus.metadata['url'] @@ -89,22 +90,23 @@ def internal_paging(next_link=None, raw=False): # Construct and send request request = self._client.get(url, query_parameters, header_parameters) + return request + + def internal_paging(next_link=None): + request = prepare_request(next_link) + response = self._client.send(request, stream=False, **operation_config) if response.status_code not in [200]: - exp = CloudError(response) - exp.request_id = response.headers.get('x-ms-request-id') - raise exp + raise models.ErrorResponseException(self._deserialize, response) return response # Deserialize response - deserialized = models.ResourceSkuResultPaged(internal_paging, self._deserialize.dependencies) - + header_dict = None if raw: header_dict = {} - client_raw_response = models.ResourceSkuResultPaged(internal_paging, self._deserialize.dependencies, header_dict) - return client_raw_response + deserialized = models.ResourceSkuResultPaged(internal_paging, self._deserialize.dependencies, header_dict) return deserialized list_available_service_skus.metadata = {'url': '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ApiManagement/service/{serviceName}/skus'} diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/api_operation_operations.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/_api_operation_operations.py similarity index 97% rename from sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/api_operation_operations.py rename to sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/_api_operation_operations.py index 596f3528bf20..6164624c988b 100644 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/api_operation_operations.py +++ b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/_api_operation_operations.py @@ -18,11 +18,13 @@ class ApiOperationOperations(object): """ApiOperationOperations operations. + You should not instantiate directly this class, but create a Client instance that will create it for you and attach it as attribute. + :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: "2019-01-01". + :ivar api_version: Version of the API to be used with the client request. Constant value: "2019-12-01-preview". """ models = models @@ -32,7 +34,7 @@ def __init__(self, client, config, serializer, deserializer): self._client = client self._serialize = serializer self._deserialize = deserializer - self.api_version = "2019-01-01" + self.api_version = "2019-12-01-preview" self.config = config @@ -77,8 +79,7 @@ def list_by_api( :raises: :class:`ErrorResponseException` """ - def internal_paging(next_link=None, raw=False): - + def prepare_request(next_link=None): if not next_link: # Construct URL url = self.list_by_api.metadata['url'] @@ -118,6 +119,11 @@ def internal_paging(next_link=None, raw=False): # Construct and send request request = self._client.get(url, query_parameters, header_parameters) + return request + + def internal_paging(next_link=None): + request = prepare_request(next_link) + response = self._client.send(request, stream=False, **operation_config) if response.status_code not in [200]: @@ -126,12 +132,10 @@ def internal_paging(next_link=None, raw=False): return response # Deserialize response - deserialized = models.OperationContractPaged(internal_paging, self._deserialize.dependencies) - + header_dict = None if raw: header_dict = {} - client_raw_response = models.OperationContractPaged(internal_paging, self._deserialize.dependencies, header_dict) - return client_raw_response + deserialized = models.OperationContractPaged(internal_paging, self._deserialize.dependencies, header_dict) return deserialized list_by_api.metadata = {'url': '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ApiManagement/service/{serviceName}/apis/{apiId}/operations'} @@ -168,7 +172,7 @@ def get_entity_tag( '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=256, min_length=1, pattern=r'^[^*#&+:<>?]+$'), - 'operationId': self._serialize.url("operation_id", operation_id, 'str', max_length=80, min_length=1, pattern=r'^[^*#&+:<>?]+$'), + 'operationId': self._serialize.url("operation_id", operation_id, 'str', max_length=80, min_length=1), 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str') } url = self._client.format_url(url, **path_format_arguments) @@ -233,7 +237,7 @@ def get( '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=256, min_length=1, pattern=r'^[^*#&+:<>?]+$'), - 'operationId': self._serialize.url("operation_id", operation_id, 'str', max_length=80, min_length=1, pattern=r'^[^*#&+:<>?]+$'), + 'operationId': self._serialize.url("operation_id", operation_id, 'str', max_length=80, min_length=1), 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str') } url = self._client.format_url(url, **path_format_arguments) @@ -259,9 +263,8 @@ def get( if response.status_code not in [200]: raise models.ErrorResponseException(self._deserialize, response) - deserialized = None header_dict = {} - + deserialized = None if response.status_code == 200: deserialized = self._deserialize('OperationContract', response) header_dict = { @@ -313,7 +316,7 @@ def create_or_update( '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=256, min_length=1, pattern=r'^[^*#&+:<>?]+$'), - 'operationId': self._serialize.url("operation_id", operation_id, 'str', max_length=80, min_length=1, pattern=r'^[^*#&+:<>?]+$'), + 'operationId': self._serialize.url("operation_id", operation_id, 'str', max_length=80, min_length=1), 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str') } url = self._client.format_url(url, **path_format_arguments) @@ -345,9 +348,8 @@ def create_or_update( if response.status_code not in [200, 201]: raise models.ErrorResponseException(self._deserialize, response) - deserialized = None header_dict = {} - + deserialized = None if response.status_code == 200: deserialized = self._deserialize('OperationContract', response) header_dict = { @@ -406,7 +408,7 @@ def update( '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=256, min_length=1, pattern=r'^[^*#&+:<>?]+$'), - 'operationId': self._serialize.url("operation_id", operation_id, 'str', max_length=80, min_length=1, pattern=r'^[^*#&+:<>?]+$'), + 'operationId': self._serialize.url("operation_id", operation_id, 'str', max_length=80, min_length=1), 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str') } url = self._client.format_url(url, **path_format_arguments) @@ -476,7 +478,7 @@ def delete( '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=256, min_length=1, pattern=r'^[^*#&+:<>?]+$'), - 'operationId': self._serialize.url("operation_id", operation_id, 'str', max_length=80, min_length=1, pattern=r'^[^*#&+:<>?]+$'), + 'operationId': self._serialize.url("operation_id", operation_id, 'str', max_length=80, min_length=1), 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str') } url = self._client.format_url(url, **path_format_arguments) diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/api_operation_policy_operations.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/_api_operation_policy_operations.py similarity index 97% rename from sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/api_operation_policy_operations.py rename to sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/_api_operation_policy_operations.py index 57f3b7bbecc1..3cd14c22a349 100644 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/api_operation_policy_operations.py +++ b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/_api_operation_policy_operations.py @@ -18,11 +18,13 @@ class ApiOperationPolicyOperations(object): """ApiOperationPolicyOperations operations. + You should not instantiate directly this class, but create a Client instance that will create it for you and attach it as attribute. + :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: "2019-01-01". + :ivar api_version: Version of the API to be used with the client request. Constant value: "2019-12-01-preview". :ivar policy_id: The identifier of the Policy. Constant value: "policy". """ @@ -33,7 +35,7 @@ def __init__(self, client, config, serializer, deserializer): self._client = client self._serialize = serializer self._deserialize = deserializer - self.api_version = "2019-01-01" + self.api_version = "2019-12-01-preview" self.policy_id = "policy" self.config = config @@ -70,7 +72,7 @@ def list_by_operation( '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=256, min_length=1, pattern=r'^[^*#&+:<>?]+$'), - 'operationId': self._serialize.url("operation_id", operation_id, 'str', max_length=80, min_length=1, pattern=r'^[^*#&+:<>?]+$'), + 'operationId': self._serialize.url("operation_id", operation_id, 'str', max_length=80, min_length=1), 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str') } url = self._client.format_url(url, **path_format_arguments) @@ -97,7 +99,6 @@ def list_by_operation( raise models.ErrorResponseException(self._deserialize, response) deserialized = None - if response.status_code == 200: deserialized = self._deserialize('PolicyCollection', response) @@ -140,7 +141,7 @@ def get_entity_tag( '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=256, min_length=1, pattern=r'^[^*#&+:<>?]+$'), - 'operationId': self._serialize.url("operation_id", operation_id, 'str', max_length=80, min_length=1, pattern=r'^[^*#&+:<>?]+$'), + 'operationId': self._serialize.url("operation_id", operation_id, 'str', max_length=80, min_length=1), 'policyId': self._serialize.url("self.policy_id", self.policy_id, 'str'), 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str') } @@ -210,7 +211,7 @@ def get( '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=256, min_length=1, pattern=r'^[^*#&+:<>?]+$'), - 'operationId': self._serialize.url("operation_id", operation_id, 'str', max_length=80, min_length=1, pattern=r'^[^*#&+:<>?]+$'), + 'operationId': self._serialize.url("operation_id", operation_id, 'str', max_length=80, min_length=1), 'policyId': self._serialize.url("self.policy_id", self.policy_id, 'str'), 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str') } @@ -239,9 +240,8 @@ def get( if response.status_code not in [200]: raise models.ErrorResponseException(self._deserialize, response) - deserialized = None header_dict = {} - + deserialized = None if response.status_code == 200: deserialized = self._deserialize('PolicyContract', response) header_dict = { @@ -299,7 +299,7 @@ def create_or_update( '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=256, min_length=1, pattern=r'^[^*#&+:<>?]+$'), - 'operationId': self._serialize.url("operation_id", operation_id, 'str', max_length=80, min_length=1, pattern=r'^[^*#&+:<>?]+$'), + 'operationId': self._serialize.url("operation_id", operation_id, 'str', max_length=80, min_length=1), 'policyId': self._serialize.url("self.policy_id", self.policy_id, 'str'), 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str') } @@ -332,9 +332,8 @@ def create_or_update( if response.status_code not in [200, 201]: raise models.ErrorResponseException(self._deserialize, response) - deserialized = None header_dict = {} - + deserialized = None if response.status_code == 200: deserialized = self._deserialize('PolicyContract', response) header_dict = { @@ -389,7 +388,7 @@ def delete( '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=256, min_length=1, pattern=r'^[^*#&+:<>?]+$'), - 'operationId': self._serialize.url("operation_id", operation_id, 'str', max_length=80, min_length=1, pattern=r'^[^*#&+:<>?]+$'), + 'operationId': self._serialize.url("operation_id", operation_id, 'str', max_length=80, min_length=1), 'policyId': self._serialize.url("self.policy_id", self.policy_id, 'str'), 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str') } diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/api_operations.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/_api_operations.py similarity index 97% rename from sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/api_operations.py rename to sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/_api_operations.py index 9828b2d15211..c66ad2c3374a 100644 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/api_operations.py +++ b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/_api_operations.py @@ -20,11 +20,13 @@ class ApiOperations(object): """ApiOperations operations. + You should not instantiate directly this class, but create a Client instance that will create it for you and attach it as attribute. + :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: "2019-01-01". + :ivar api_version: Version of the API to be used with the client request. Constant value: "2019-12-01-preview". """ models = models @@ -34,7 +36,7 @@ def __init__(self, client, config, serializer, deserializer): self._client = client self._serialize = serializer self._deserialize = deserializer - self.api_version = "2019-01-01" + self.api_version = "2019-12-01-preview" self.config = config @@ -78,8 +80,7 @@ def list_by_service( :raises: :class:`ErrorResponseException` """ - def internal_paging(next_link=None, raw=False): - + def prepare_request(next_link=None): if not next_link: # Construct URL url = self.list_by_service.metadata['url'] @@ -120,6 +121,11 @@ def internal_paging(next_link=None, raw=False): # Construct and send request request = self._client.get(url, query_parameters, header_parameters) + return request + + def internal_paging(next_link=None): + request = prepare_request(next_link) + response = self._client.send(request, stream=False, **operation_config) if response.status_code not in [200]: @@ -128,12 +134,10 @@ def internal_paging(next_link=None, raw=False): return response # Deserialize response - deserialized = models.ApiContractPaged(internal_paging, self._deserialize.dependencies) - + header_dict = None if raw: header_dict = {} - client_raw_response = models.ApiContractPaged(internal_paging, self._deserialize.dependencies, header_dict) - return client_raw_response + deserialized = models.ApiContractPaged(internal_paging, self._deserialize.dependencies, header_dict) return deserialized list_by_service.metadata = {'url': '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ApiManagement/service/{serviceName}/apis'} @@ -253,9 +257,8 @@ def get( if response.status_code not in [200]: raise models.ErrorResponseException(self._deserialize, response) - deserialized = None header_dict = {} - + deserialized = None if response.status_code == 200: deserialized = self._deserialize('ApiContract', response) header_dict = { @@ -573,8 +576,7 @@ def list_by_tags( :raises: :class:`ErrorResponseException` """ - def internal_paging(next_link=None, raw=False): - + def prepare_request(next_link=None): if not next_link: # Construct URL url = self.list_by_tags.metadata['url'] @@ -613,6 +615,11 @@ def internal_paging(next_link=None, raw=False): # Construct and send request request = self._client.get(url, query_parameters, header_parameters) + return request + + def internal_paging(next_link=None): + request = prepare_request(next_link) + response = self._client.send(request, stream=False, **operation_config) if response.status_code not in [200]: @@ -621,12 +628,10 @@ def internal_paging(next_link=None, raw=False): return response # Deserialize response - deserialized = models.TagResourceContractPaged(internal_paging, self._deserialize.dependencies) - + header_dict = None if raw: header_dict = {} - client_raw_response = models.TagResourceContractPaged(internal_paging, self._deserialize.dependencies, header_dict) - return client_raw_response + deserialized = models.TagResourceContractPaged(internal_paging, self._deserialize.dependencies, header_dict) return deserialized list_by_tags.metadata = {'url': '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ApiManagement/service/{serviceName}/apisByTags'} diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/api_policy_operations.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/_api_policy_operations.py similarity index 98% rename from sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/api_policy_operations.py rename to sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/_api_policy_operations.py index 8618fda61700..a6ac57b8a4bb 100644 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/api_policy_operations.py +++ b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/_api_policy_operations.py @@ -18,11 +18,13 @@ class ApiPolicyOperations(object): """ApiPolicyOperations operations. + You should not instantiate directly this class, but create a Client instance that will create it for you and attach it as attribute. + :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: "2019-01-01". + :ivar api_version: Version of the API to be used with the client request. Constant value: "2019-12-01-preview". :ivar policy_id: The identifier of the Policy. Constant value: "policy". """ @@ -33,7 +35,7 @@ def __init__(self, client, config, serializer, deserializer): self._client = client self._serialize = serializer self._deserialize = deserializer - self.api_version = "2019-01-01" + self.api_version = "2019-12-01-preview" self.policy_id = "policy" self.config = config @@ -93,7 +95,6 @@ def list_by_api( raise models.ErrorResponseException(self._deserialize, response) deserialized = None - if response.status_code == 200: deserialized = self._deserialize('PolicyCollection', response) @@ -227,9 +228,8 @@ def get( if response.status_code not in [200]: raise models.ErrorResponseException(self._deserialize, response) - deserialized = None header_dict = {} - + deserialized = None if response.status_code == 200: deserialized = self._deserialize('PolicyContract', response) header_dict = { @@ -316,9 +316,8 @@ def create_or_update( if response.status_code not in [200, 201]: raise models.ErrorResponseException(self._deserialize, response) - deserialized = None header_dict = {} - + deserialized = None if response.status_code == 200: deserialized = self._deserialize('PolicyContract', response) header_dict = { diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/api_product_operations.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/_api_product_operations.py similarity index 91% rename from sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/api_product_operations.py rename to sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/_api_product_operations.py index 27542a5e3b4a..85f7ed406eda 100644 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/api_product_operations.py +++ b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/_api_product_operations.py @@ -18,11 +18,13 @@ class ApiProductOperations(object): """ApiProductOperations operations. + You should not instantiate directly this class, but create a Client instance that will create it for you and attach it as attribute. + :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: "2019-01-01". + :ivar api_version: Version of the API to be used with the client request. Constant value: "2019-12-01-preview". """ models = models @@ -32,7 +34,7 @@ def __init__(self, client, config, serializer, deserializer): self._client = client self._serialize = serializer self._deserialize = deserializer - self.api_version = "2019-01-01" + self.api_version = "2019-12-01-preview" self.config = config @@ -68,15 +70,14 @@ def list_by_apis( :raises: :class:`ErrorResponseException` """ - def internal_paging(next_link=None, raw=False): - + def prepare_request(next_link=None): if not next_link: # Construct URL url = self.list_by_apis.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'^[^*#&+:<>?]+$'), + 'apiId': self._serialize.url("api_id", api_id, 'str', max_length=80, min_length=1), 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str') } url = self._client.format_url(url, **path_format_arguments) @@ -107,6 +108,11 @@ def internal_paging(next_link=None, raw=False): # Construct and send request request = self._client.get(url, query_parameters, header_parameters) + return request + + def internal_paging(next_link=None): + request = prepare_request(next_link) + response = self._client.send(request, stream=False, **operation_config) if response.status_code not in [200]: @@ -115,12 +121,10 @@ def internal_paging(next_link=None, raw=False): return response # Deserialize response - deserialized = models.ProductContractPaged(internal_paging, self._deserialize.dependencies) - + header_dict = None if raw: header_dict = {} - client_raw_response = models.ProductContractPaged(internal_paging, self._deserialize.dependencies, header_dict) - return client_raw_response + deserialized = models.ProductContractPaged(internal_paging, self._deserialize.dependencies, header_dict) return deserialized list_by_apis.metadata = {'url': '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ApiManagement/service/{serviceName}/apis/{apiId}/products'} diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/api_release_operations.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/_api_release_operations.py similarity index 97% rename from sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/api_release_operations.py rename to sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/_api_release_operations.py index c00e71b80676..d4f41f58727a 100644 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/api_release_operations.py +++ b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/_api_release_operations.py @@ -18,11 +18,13 @@ class ApiReleaseOperations(object): """ApiReleaseOperations operations. + You should not instantiate directly this class, but create a Client instance that will create it for you and attach it as attribute. + :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: "2019-01-01". + :ivar api_version: Version of the API to be used with the client request. Constant value: "2019-12-01-preview". """ models = models @@ -32,7 +34,7 @@ def __init__(self, client, config, serializer, deserializer): self._client = client self._serialize = serializer self._deserialize = deserializer - self.api_version = "2019-01-01" + self.api_version = "2019-12-01-preview" self.config = config @@ -71,15 +73,14 @@ def list_by_service( :raises: :class:`ErrorResponseException` """ - def internal_paging(next_link=None, raw=False): - + def prepare_request(next_link=None): 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'^[^*#&+:<>?]+$'), + 'apiId': self._serialize.url("api_id", api_id, 'str', max_length=80, min_length=1), 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str') } url = self._client.format_url(url, **path_format_arguments) @@ -110,6 +111,11 @@ def internal_paging(next_link=None, raw=False): # Construct and send request request = self._client.get(url, query_parameters, header_parameters) + return request + + def internal_paging(next_link=None): + request = prepare_request(next_link) + response = self._client.send(request, stream=False, **operation_config) if response.status_code not in [200]: @@ -118,12 +124,10 @@ def internal_paging(next_link=None, raw=False): return response # Deserialize response - deserialized = models.ApiReleaseContractPaged(internal_paging, self._deserialize.dependencies) - + header_dict = None if raw: header_dict = {} - client_raw_response = models.ApiReleaseContractPaged(internal_paging, self._deserialize.dependencies, header_dict) - return client_raw_response + deserialized = models.ApiReleaseContractPaged(internal_paging, self._deserialize.dependencies, header_dict) return deserialized list_by_service.metadata = {'url': '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ApiManagement/service/{serviceName}/apis/{apiId}/releases'} @@ -157,7 +161,7 @@ def get_entity_tag( 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'^[^*#&+:<>?]+$'), + 'apiId': self._serialize.url("api_id", api_id, 'str', max_length=80, min_length=1), 'releaseId': self._serialize.url("release_id", release_id, 'str', max_length=80, min_length=1, pattern=r'^[^*#&+:<>?]+$'), 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str') } @@ -221,7 +225,7 @@ def get( 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'^[^*#&+:<>?]+$'), + 'apiId': self._serialize.url("api_id", api_id, 'str', max_length=80, min_length=1), 'releaseId': self._serialize.url("release_id", release_id, 'str', max_length=80, min_length=1, pattern=r'^[^*#&+:<>?]+$'), 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str') } @@ -248,9 +252,8 @@ def get( if response.status_code not in [200]: raise models.ErrorResponseException(self._deserialize, response) - deserialized = None header_dict = {} - + deserialized = None if response.status_code == 200: deserialized = self._deserialize('ApiReleaseContract', response) header_dict = { @@ -304,7 +307,7 @@ def create_or_update( 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'^[^*#&+:<>?]+$'), + 'apiId': self._serialize.url("api_id", api_id, 'str', max_length=80, min_length=1), 'releaseId': self._serialize.url("release_id", release_id, 'str', max_length=80, min_length=1, pattern=r'^[^*#&+:<>?]+$'), 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str') } @@ -337,9 +340,8 @@ def create_or_update( if response.status_code not in [200, 201]: raise models.ErrorResponseException(self._deserialize, response) - deserialized = None header_dict = {} - + deserialized = None if response.status_code == 200: deserialized = self._deserialize('ApiReleaseContract', response) header_dict = { @@ -399,7 +401,7 @@ def update( 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'^[^*#&+:<>?]+$'), + 'apiId': self._serialize.url("api_id", api_id, 'str', max_length=80, min_length=1), 'releaseId': self._serialize.url("release_id", release_id, 'str', max_length=80, min_length=1, pattern=r'^[^*#&+:<>?]+$'), 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str') } @@ -468,7 +470,7 @@ def delete( 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'^[^*#&+:<>?]+$'), + 'apiId': self._serialize.url("api_id", api_id, 'str', max_length=80, min_length=1), 'releaseId': self._serialize.url("release_id", release_id, 'str', max_length=80, min_length=1, pattern=r'^[^*#&+:<>?]+$'), 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str') } diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/api_revision_operations.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/_api_revision_operations.py similarity index 91% rename from sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/api_revision_operations.py rename to sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/_api_revision_operations.py index fc654cfe9f18..19177a3dbec3 100644 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/api_revision_operations.py +++ b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/_api_revision_operations.py @@ -18,11 +18,13 @@ class ApiRevisionOperations(object): """ApiRevisionOperations operations. + You should not instantiate directly this class, but create a Client instance that will create it for you and attach it as attribute. + :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: "2019-01-01". + :ivar api_version: Version of the API to be used with the client request. Constant value: "2019-12-01-preview". """ models = models @@ -32,7 +34,7 @@ def __init__(self, client, config, serializer, deserializer): self._client = client self._serialize = serializer self._deserialize = deserializer - self.api_version = "2019-01-01" + self.api_version = "2019-12-01-preview" self.config = config @@ -68,15 +70,14 @@ def list_by_service( :raises: :class:`ErrorResponseException` """ - def internal_paging(next_link=None, raw=False): - + def prepare_request(next_link=None): 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'^[^*#&+:<>?]+$'), + 'apiId': self._serialize.url("api_id", api_id, 'str', max_length=80, min_length=1), 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str') } url = self._client.format_url(url, **path_format_arguments) @@ -107,6 +108,11 @@ def internal_paging(next_link=None, raw=False): # Construct and send request request = self._client.get(url, query_parameters, header_parameters) + return request + + def internal_paging(next_link=None): + request = prepare_request(next_link) + response = self._client.send(request, stream=False, **operation_config) if response.status_code not in [200]: @@ -115,12 +121,10 @@ def internal_paging(next_link=None, raw=False): return response # Deserialize response - deserialized = models.ApiRevisionContractPaged(internal_paging, self._deserialize.dependencies) - + header_dict = None if raw: header_dict = {} - client_raw_response = models.ApiRevisionContractPaged(internal_paging, self._deserialize.dependencies, header_dict) - return client_raw_response + deserialized = models.ApiRevisionContractPaged(internal_paging, self._deserialize.dependencies, header_dict) return deserialized list_by_service.metadata = {'url': '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ApiManagement/service/{serviceName}/apis/{apiId}/revisions'} diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/api_schema_operations.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/_api_schema_operations.py similarity index 87% rename from sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/api_schema_operations.py rename to sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/_api_schema_operations.py index 6d9dc76a4f8c..89a98697195b 100644 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/api_schema_operations.py +++ b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/_api_schema_operations.py @@ -11,6 +11,8 @@ import uuid from msrest.pipeline import ClientRawResponse +from msrest.polling import LROPoller, NoPolling +from msrestazure.polling.arm_polling import ARMPolling from .. import models @@ -18,11 +20,13 @@ class ApiSchemaOperations(object): """ApiSchemaOperations operations. + You should not instantiate directly this class, but create a Client instance that will create it for you and attach it as attribute. + :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: "2019-01-01". + :ivar api_version: Version of the API to be used with the client request. Constant value: "2019-12-01-preview". """ models = models @@ -32,7 +36,7 @@ def __init__(self, client, config, serializer, deserializer): self._client = client self._serialize = serializer self._deserialize = deserializer - self.api_version = "2019-01-01" + self.api_version = "2019-12-01-preview" self.config = config @@ -69,8 +73,7 @@ def list_by_api( :raises: :class:`ErrorResponseException` """ - def internal_paging(next_link=None, raw=False): - + def prepare_request(next_link=None): if not next_link: # Construct URL url = self.list_by_api.metadata['url'] @@ -108,6 +111,11 @@ def internal_paging(next_link=None, raw=False): # Construct and send request request = self._client.get(url, query_parameters, header_parameters) + return request + + def internal_paging(next_link=None): + request = prepare_request(next_link) + response = self._client.send(request, stream=False, **operation_config) if response.status_code not in [200]: @@ -116,12 +124,10 @@ def internal_paging(next_link=None, raw=False): return response # Deserialize response - deserialized = models.SchemaContractPaged(internal_paging, self._deserialize.dependencies) - + header_dict = None if raw: header_dict = {} - client_raw_response = models.SchemaContractPaged(internal_paging, self._deserialize.dependencies, header_dict) - return client_raw_response + deserialized = models.SchemaContractPaged(internal_paging, self._deserialize.dependencies, header_dict) return deserialized list_by_api.metadata = {'url': '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ApiManagement/service/{serviceName}/apis/{apiId}/schemas'} @@ -249,9 +255,8 @@ def get( if response.status_code not in [200]: raise models.ErrorResponseException(self._deserialize, response) - deserialized = None header_dict = {} - + deserialized = None if response.status_code == 200: deserialized = self._deserialize('SchemaContract', response) header_dict = { @@ -266,50 +271,9 @@ def get( return deserialized get.metadata = {'url': '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ApiManagement/service/{serviceName}/apis/{apiId}/schemas/{schemaId}'} - def create_or_update( - self, resource_group_name, service_name, api_id, schema_id, content_type, if_match=None, value=None, custom_headers=None, raw=False, **operation_config): - """Creates or updates schema configuration for the 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 revision identifier. Must be unique in the current - API Management service instance. Non-current revision has ;rev=n as a - suffix where n is the revision number. - :type api_id: str - :param schema_id: Schema identifier within an API. Must be unique in - the current API Management service instance. - :type schema_id: str - :param content_type: Must be a valid a media type used in a - Content-Type header as defined in the RFC 2616. Media type of the - schema document (e.g. application/json, application/xml).
- - `Swagger` Schema use - `application/vnd.ms-azure-apim.swagger.definitions+json`
- - `WSDL` Schema use `application/vnd.ms-azure-apim.xsd+xml`
- - `OpenApi` Schema use `application/vnd.oai.openapi.components+json` -
- `WADL Schema` use - `application/vnd.ms-azure-apim.wadl.grammars+xml`. - :type content_type: str - :param if_match: ETag of the Entity. Not required when creating an - entity, but required when updating an entity. - :type if_match: str - :param value: Json escaped string defining the document representing - the Schema. - :type value: 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: SchemaContract or ClientRawResponse if raw=true - :rtype: ~azure.mgmt.apimanagement.models.SchemaContract or - ~msrest.pipeline.ClientRawResponse - :raises: - :class:`ErrorResponseException` - """ - parameters = models.SchemaCreateOrUpdateContract(content_type=content_type, value=value) + def _create_or_update_initial( + self, resource_group_name, service_name, api_id, schema_id, parameters, if_match=None, custom_headers=None, raw=False, **operation_config): # Construct URL url = self.create_or_update.metadata['url'] path_format_arguments = { @@ -339,13 +303,13 @@ def create_or_update( header_parameters['accept-language'] = self._serialize.header("self.config.accept_language", self.config.accept_language, 'str') # Construct body - body_content = self._serialize.body(parameters, 'SchemaCreateOrUpdateContract') + body_content = self._serialize.body(parameters, 'SchemaContract') # Construct and send request request = self._client.put(url, query_parameters, header_parameters, body_content) response = self._client.send(request, stream=False, **operation_config) - if response.status_code not in [200, 201]: + if response.status_code not in [200, 201, 202]: raise models.ErrorResponseException(self._deserialize, response) deserialized = None @@ -368,6 +332,73 @@ def create_or_update( return client_raw_response return deserialized + + def create_or_update( + self, resource_group_name, service_name, api_id, schema_id, parameters, if_match=None, custom_headers=None, raw=False, polling=True, **operation_config): + """Creates or updates schema configuration for the 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 revision identifier. Must be unique in the current + API Management service instance. Non-current revision has ;rev=n as a + suffix where n is the revision number. + :type api_id: str + :param schema_id: Schema identifier within an API. Must be unique in + the current API Management service instance. + :type schema_id: str + :param parameters: The schema contents to apply. + :type parameters: ~azure.mgmt.apimanagement.models.SchemaContract + :param if_match: ETag of the Entity. Not required when creating an + entity, but required when updating an entity. + :type if_match: str + :param dict custom_headers: headers that will be added to the request + :param bool raw: The poller return type is ClientRawResponse, the + direct response alongside the deserialized response + :param polling: True for ARMPolling, False for no polling, or a + polling object for personal polling strategy + :return: An instance of LROPoller that returns SchemaContract or + ClientRawResponse if raw==True + :rtype: + ~msrestazure.azure_operation.AzureOperationPoller[~azure.mgmt.apimanagement.models.SchemaContract] + or + ~msrestazure.azure_operation.AzureOperationPoller[~msrest.pipeline.ClientRawResponse[~azure.mgmt.apimanagement.models.SchemaContract]] + :raises: + :class:`ErrorResponseException` + """ + raw_result = self._create_or_update_initial( + resource_group_name=resource_group_name, + service_name=service_name, + api_id=api_id, + schema_id=schema_id, + parameters=parameters, + if_match=if_match, + custom_headers=custom_headers, + raw=True, + **operation_config + ) + + def get_long_running_output(response): + header_dict = { + 'ETag': 'str', + } + deserialized = self._deserialize('SchemaContract', response) + + if raw: + client_raw_response = ClientRawResponse(deserialized, response) + client_raw_response.add_headers(header_dict) + return client_raw_response + + return deserialized + + lro_delay = operation_config.get( + 'long_running_operation_timeout', + self.config.long_running_operation_timeout) + if polling is True: polling_method = ARMPolling(lro_delay, **operation_config) + elif polling is False: polling_method = NoPolling() + else: polling_method = polling + return LROPoller(self._client, raw_result, get_long_running_output, polling_method) create_or_update.metadata = {'url': '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ApiManagement/service/{serviceName}/apis/{apiId}/schemas/{schemaId}'} def delete( diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/api_tag_description_operations.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/_api_tag_description_operations.py similarity index 89% rename from sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/api_tag_description_operations.py rename to sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/_api_tag_description_operations.py index 9c2324b24d6f..a1b3201f4744 100644 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/api_tag_description_operations.py +++ b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/_api_tag_description_operations.py @@ -18,11 +18,13 @@ class ApiTagDescriptionOperations(object): """ApiTagDescriptionOperations operations. + You should not instantiate directly this class, but create a Client instance that will create it for you and attach it as attribute. + :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: "2019-01-01". + :ivar api_version: Version of the API to be used with the client request. Constant value: "2019-12-01-preview". """ models = models @@ -32,7 +34,7 @@ def __init__(self, client, config, serializer, deserializer): self._client = client self._serialize = serializer self._deserialize = deserializer - self.api_version = "2019-01-01" + self.api_version = "2019-12-01-preview" self.config = config @@ -72,8 +74,7 @@ def list_by_service( :raises: :class:`ErrorResponseException` """ - def internal_paging(next_link=None, raw=False): - + def prepare_request(next_link=None): if not next_link: # Construct URL url = self.list_by_service.metadata['url'] @@ -111,6 +112,11 @@ def internal_paging(next_link=None, raw=False): # Construct and send request request = self._client.get(url, query_parameters, header_parameters) + return request + + def internal_paging(next_link=None): + request = prepare_request(next_link) + response = self._client.send(request, stream=False, **operation_config) if response.status_code not in [200]: @@ -119,18 +125,16 @@ def internal_paging(next_link=None, raw=False): return response # Deserialize response - deserialized = models.TagDescriptionContractPaged(internal_paging, self._deserialize.dependencies) - + header_dict = None if raw: header_dict = {} - client_raw_response = models.TagDescriptionContractPaged(internal_paging, self._deserialize.dependencies, header_dict) - return client_raw_response + deserialized = models.TagDescriptionContractPaged(internal_paging, self._deserialize.dependencies, header_dict) return deserialized list_by_service.metadata = {'url': '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ApiManagement/service/{serviceName}/apis/{apiId}/tagDescriptions'} def get_entity_tag( - self, resource_group_name, service_name, api_id, tag_id, custom_headers=None, raw=False, **operation_config): + self, resource_group_name, service_name, api_id, tag_description_id, custom_headers=None, raw=False, **operation_config): """Gets the entity state version of the tag specified by its identifier. :param resource_group_name: The name of the resource group. @@ -141,9 +145,10 @@ def get_entity_tag( API Management service instance. Non-current revision has ;rev=n as a suffix where n is the revision number. :type api_id: str - :param tag_id: Tag identifier. Must be unique in the current API - Management service instance. - :type tag_id: str + :param tag_description_id: Tag description identifier. Used when + creating tagDescription for API/Tag association. Based on API and Tag + names. + :type tag_description_id: str :param dict custom_headers: headers that will be added to the request :param bool raw: returns the direct response alongside the deserialized response @@ -160,7 +165,7 @@ def get_entity_tag( '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=256, min_length=1, pattern=r'^[^*#&+:<>?]+$'), - 'tagId': self._serialize.url("tag_id", tag_id, 'str', max_length=80, min_length=1, pattern=r'^[^*#&+:<>?]+$'), + 'tagDescriptionId': self._serialize.url("tag_description_id", tag_description_id, 'str', max_length=80, min_length=1, pattern=r'^[^*#&+:<>?]+$'), 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str') } url = self._client.format_url(url, **path_format_arguments) @@ -191,10 +196,10 @@ def get_entity_tag( 'ETag': 'str', }) return client_raw_response - get_entity_tag.metadata = {'url': '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ApiManagement/service/{serviceName}/apis/{apiId}/tagDescriptions/{tagId}'} + get_entity_tag.metadata = {'url': '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ApiManagement/service/{serviceName}/apis/{apiId}/tagDescriptions/{tagDescriptionId}'} def get( - self, resource_group_name, service_name, api_id, tag_id, custom_headers=None, raw=False, **operation_config): + self, resource_group_name, service_name, api_id, tag_description_id, custom_headers=None, raw=False, **operation_config): """Get Tag description in scope of API. :param resource_group_name: The name of the resource group. @@ -205,9 +210,10 @@ def get( API Management service instance. Non-current revision has ;rev=n as a suffix where n is the revision number. :type api_id: str - :param tag_id: Tag identifier. Must be unique in the current API - Management service instance. - :type tag_id: str + :param tag_description_id: Tag description identifier. Used when + creating tagDescription for API/Tag association. Based on API and Tag + names. + :type tag_description_id: str :param dict custom_headers: headers that will be added to the request :param bool raw: returns the direct response alongside the deserialized response @@ -225,7 +231,7 @@ def get( '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=256, min_length=1, pattern=r'^[^*#&+:<>?]+$'), - 'tagId': self._serialize.url("tag_id", tag_id, 'str', max_length=80, min_length=1, pattern=r'^[^*#&+:<>?]+$'), + 'tagDescriptionId': self._serialize.url("tag_description_id", tag_description_id, 'str', max_length=80, min_length=1, pattern=r'^[^*#&+:<>?]+$'), 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str') } url = self._client.format_url(url, **path_format_arguments) @@ -251,9 +257,8 @@ def get( if response.status_code not in [200]: raise models.ErrorResponseException(self._deserialize, response) - deserialized = None header_dict = {} - + deserialized = None if response.status_code == 200: deserialized = self._deserialize('TagDescriptionContract', response) header_dict = { @@ -266,10 +271,10 @@ def get( return client_raw_response return deserialized - get.metadata = {'url': '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ApiManagement/service/{serviceName}/apis/{apiId}/tagDescriptions/{tagId}'} + get.metadata = {'url': '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ApiManagement/service/{serviceName}/apis/{apiId}/tagDescriptions/{tagDescriptionId}'} def create_or_update( - self, resource_group_name, service_name, api_id, tag_id, parameters, if_match=None, custom_headers=None, raw=False, **operation_config): + self, resource_group_name, service_name, api_id, tag_description_id, parameters, if_match=None, custom_headers=None, raw=False, **operation_config): """Create/Update tag description in scope of the Api. :param resource_group_name: The name of the resource group. @@ -280,9 +285,10 @@ def create_or_update( API Management service instance. Non-current revision has ;rev=n as a suffix where n is the revision number. :type api_id: str - :param tag_id: Tag identifier. Must be unique in the current API - Management service instance. - :type tag_id: str + :param tag_description_id: Tag description identifier. Used when + creating tagDescription for API/Tag association. Based on API and Tag + names. + :type tag_description_id: str :param parameters: Create parameters. :type parameters: ~azure.mgmt.apimanagement.models.TagDescriptionCreateParameters @@ -306,7 +312,7 @@ def create_or_update( '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=256, min_length=1, pattern=r'^[^*#&+:<>?]+$'), - 'tagId': self._serialize.url("tag_id", tag_id, 'str', max_length=80, min_length=1, pattern=r'^[^*#&+:<>?]+$'), + 'tagDescriptionId': self._serialize.url("tag_description_id", tag_description_id, 'str', max_length=80, min_length=1, pattern=r'^[^*#&+:<>?]+$'), 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str') } url = self._client.format_url(url, **path_format_arguments) @@ -338,9 +344,8 @@ def create_or_update( if response.status_code not in [200, 201]: raise models.ErrorResponseException(self._deserialize, response) - deserialized = None header_dict = {} - + deserialized = None if response.status_code == 200: deserialized = self._deserialize('TagDescriptionContract', response) header_dict = { @@ -358,10 +363,10 @@ def create_or_update( return client_raw_response return deserialized - create_or_update.metadata = {'url': '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ApiManagement/service/{serviceName}/apis/{apiId}/tagDescriptions/{tagId}'} + create_or_update.metadata = {'url': '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ApiManagement/service/{serviceName}/apis/{apiId}/tagDescriptions/{tagDescriptionId}'} def delete( - self, resource_group_name, service_name, api_id, tag_id, if_match, custom_headers=None, raw=False, **operation_config): + self, resource_group_name, service_name, api_id, tag_description_id, if_match, custom_headers=None, raw=False, **operation_config): """Delete tag description for the Api. :param resource_group_name: The name of the resource group. @@ -372,9 +377,10 @@ def delete( API Management service instance. Non-current revision has ;rev=n as a suffix where n is the revision number. :type api_id: str - :param tag_id: Tag identifier. Must be unique in the current API - Management service instance. - :type tag_id: str + :param tag_description_id: Tag description identifier. Used when + creating tagDescription for API/Tag association. Based on API and Tag + names. + :type tag_description_id: str :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. @@ -395,7 +401,7 @@ def delete( '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=256, min_length=1, pattern=r'^[^*#&+:<>?]+$'), - 'tagId': self._serialize.url("tag_id", tag_id, 'str', max_length=80, min_length=1, pattern=r'^[^*#&+:<>?]+$'), + 'tagDescriptionId': self._serialize.url("tag_description_id", tag_description_id, 'str', max_length=80, min_length=1, pattern=r'^[^*#&+:<>?]+$'), 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str') } url = self._client.format_url(url, **path_format_arguments) @@ -424,4 +430,4 @@ def delete( 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}/tagDescriptions/{tagId}'} + delete.metadata = {'url': '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ApiManagement/service/{serviceName}/apis/{apiId}/tagDescriptions/{tagDescriptionId}'} diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/api_version_set_operations.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/_api_version_set_operations.py similarity index 97% rename from sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/api_version_set_operations.py rename to sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/_api_version_set_operations.py index 72173a8b483f..08f29bdf2a66 100644 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/api_version_set_operations.py +++ b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/_api_version_set_operations.py @@ -18,11 +18,13 @@ class ApiVersionSetOperations(object): """ApiVersionSetOperations operations. + You should not instantiate directly this class, but create a Client instance that will create it for you and attach it as attribute. + :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: "2019-01-01". + :ivar api_version: Version of the API to be used with the client request. Constant value: "2019-12-01-preview". """ models = models @@ -32,7 +34,7 @@ def __init__(self, client, config, serializer, deserializer): self._client = client self._serialize = serializer self._deserialize = deserializer - self.api_version = "2019-01-01" + self.api_version = "2019-12-01-preview" self.config = config @@ -64,8 +66,7 @@ def list_by_service( :raises: :class:`ErrorResponseException` """ - def internal_paging(next_link=None, raw=False): - + def prepare_request(next_link=None): if not next_link: # Construct URL url = self.list_by_service.metadata['url'] @@ -102,6 +103,11 @@ def internal_paging(next_link=None, raw=False): # Construct and send request request = self._client.get(url, query_parameters, header_parameters) + return request + + def internal_paging(next_link=None): + request = prepare_request(next_link) + response = self._client.send(request, stream=False, **operation_config) if response.status_code not in [200]: @@ -110,12 +116,10 @@ def internal_paging(next_link=None, raw=False): return response # Deserialize response - deserialized = models.ApiVersionSetContractPaged(internal_paging, self._deserialize.dependencies) - + header_dict = None if raw: header_dict = {} - client_raw_response = models.ApiVersionSetContractPaged(internal_paging, self._deserialize.dependencies, header_dict) - return client_raw_response + deserialized = models.ApiVersionSetContractPaged(internal_paging, self._deserialize.dependencies, header_dict) return deserialized list_by_service.metadata = {'url': '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ApiManagement/service/{serviceName}/apiVersionSets'} @@ -233,9 +237,8 @@ def get( if response.status_code not in [200]: raise models.ErrorResponseException(self._deserialize, response) - deserialized = None header_dict = {} - + deserialized = None if response.status_code == 200: deserialized = self._deserialize('ApiVersionSetContract', response) header_dict = { @@ -315,9 +318,8 @@ def create_or_update( if response.status_code not in [200, 201]: raise models.ErrorResponseException(self._deserialize, response) - deserialized = None header_dict = {} - + deserialized = None if response.status_code == 200: deserialized = self._deserialize('ApiVersionSetContract', response) header_dict = { diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/authorization_server_operations.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/_authorization_server_operations.py similarity index 86% rename from sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/authorization_server_operations.py rename to sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/_authorization_server_operations.py index 7473c7856313..3d55be13d4e5 100644 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/authorization_server_operations.py +++ b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/_authorization_server_operations.py @@ -18,11 +18,13 @@ class AuthorizationServerOperations(object): """AuthorizationServerOperations operations. + You should not instantiate directly this class, but create a Client instance that will create it for you and attach it as attribute. + :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: "2019-01-01". + :ivar api_version: Version of the API to be used with the client request. Constant value: "2019-12-01-preview". """ models = models @@ -32,7 +34,7 @@ def __init__(self, client, config, serializer, deserializer): self._client = client self._serialize = serializer self._deserialize = deserializer - self.api_version = "2019-01-01" + self.api_version = "2019-12-01-preview" self.config = config @@ -67,8 +69,7 @@ def list_by_service( :raises: :class:`ErrorResponseException` """ - def internal_paging(next_link=None, raw=False): - + def prepare_request(next_link=None): if not next_link: # Construct URL url = self.list_by_service.metadata['url'] @@ -105,6 +106,11 @@ def internal_paging(next_link=None, raw=False): # Construct and send request request = self._client.get(url, query_parameters, header_parameters) + return request + + def internal_paging(next_link=None): + request = prepare_request(next_link) + response = self._client.send(request, stream=False, **operation_config) if response.status_code not in [200]: @@ -113,12 +119,10 @@ def internal_paging(next_link=None, raw=False): return response # Deserialize response - deserialized = models.AuthorizationServerContractPaged(internal_paging, self._deserialize.dependencies) - + header_dict = None if raw: header_dict = {} - client_raw_response = models.AuthorizationServerContractPaged(internal_paging, self._deserialize.dependencies, header_dict) - return client_raw_response + deserialized = models.AuthorizationServerContractPaged(internal_paging, self._deserialize.dependencies, header_dict) return deserialized list_by_service.metadata = {'url': '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ApiManagement/service/{serviceName}/authorizationServers'} @@ -235,9 +239,8 @@ def get( if response.status_code not in [200]: raise models.ErrorResponseException(self._deserialize, response) - deserialized = None header_dict = {} - + deserialized = None if response.status_code == 200: deserialized = self._deserialize('AuthorizationServerContract', response) header_dict = { @@ -317,9 +320,8 @@ def create_or_update( if response.status_code not in [200, 201]: raise models.ErrorResponseException(self._deserialize, response) - deserialized = None header_dict = {} - + deserialized = None if response.status_code == 200: deserialized = self._deserialize('AuthorizationServerContract', response) header_dict = { @@ -466,3 +468,66 @@ def delete( client_raw_response = ClientRawResponse(None, response) return client_raw_response delete.metadata = {'url': '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ApiManagement/service/{serviceName}/authorizationServers/{authsid}'} + + def list_secrets( + self, resource_group_name, service_name, authsid, custom_headers=None, raw=False, **operation_config): + """Gets the client secret details of the authorization server. + + :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 authsid: Identifier of the authorization server. + :type authsid: 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: ClientSecretContract or ClientRawResponse if raw=true + :rtype: ~azure.mgmt.apimanagement.models.ClientSecretContract or + ~msrest.pipeline.ClientRawResponse + :raises: + :class:`ErrorResponseException` + """ + # Construct URL + url = self.list_secrets.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])?$'), + 'authsid': self._serialize.url("authsid", authsid, 'str', max_length=80, min_length=1, pattern=r'^[^*#&+:<>?]+$'), + '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.post(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) + + deserialized = None + if response.status_code == 200: + deserialized = self._deserialize('ClientSecretContract', response) + + if raw: + client_raw_response = ClientRawResponse(deserialized, response) + return client_raw_response + + return deserialized + list_secrets.metadata = {'url': '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ApiManagement/service/{serviceName}/authorizationServers/{authsid}/listSecrets'} diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/backend_operations.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/_backend_operations.py similarity index 97% rename from sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/backend_operations.py rename to sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/_backend_operations.py index 5afb9bbb081a..7ce29db3c6fa 100644 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/backend_operations.py +++ b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/_backend_operations.py @@ -18,11 +18,13 @@ class BackendOperations(object): """BackendOperations operations. + You should not instantiate directly this class, but create a Client instance that will create it for you and attach it as attribute. + :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: "2019-01-01". + :ivar api_version: Version of the API to be used with the client request. Constant value: "2019-12-01-preview". """ models = models @@ -32,7 +34,7 @@ def __init__(self, client, config, serializer, deserializer): self._client = client self._serialize = serializer self._deserialize = deserializer - self.api_version = "2019-01-01" + self.api_version = "2019-12-01-preview" self.config = config @@ -68,8 +70,7 @@ def list_by_service( :raises: :class:`ErrorResponseException` """ - def internal_paging(next_link=None, raw=False): - + def prepare_request(next_link=None): if not next_link: # Construct URL url = self.list_by_service.metadata['url'] @@ -106,6 +107,11 @@ def internal_paging(next_link=None, raw=False): # Construct and send request request = self._client.get(url, query_parameters, header_parameters) + return request + + def internal_paging(next_link=None): + request = prepare_request(next_link) + response = self._client.send(request, stream=False, **operation_config) if response.status_code not in [200]: @@ -114,12 +120,10 @@ def internal_paging(next_link=None, raw=False): return response # Deserialize response - deserialized = models.BackendContractPaged(internal_paging, self._deserialize.dependencies) - + header_dict = None if raw: header_dict = {} - client_raw_response = models.BackendContractPaged(internal_paging, self._deserialize.dependencies, header_dict) - return client_raw_response + deserialized = models.BackendContractPaged(internal_paging, self._deserialize.dependencies, header_dict) return deserialized list_by_service.metadata = {'url': '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ApiManagement/service/{serviceName}/backends'} @@ -151,7 +155,7 @@ def get_entity_tag( 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])?$'), - 'backendId': self._serialize.url("backend_id", backend_id, 'str', max_length=80, min_length=1, pattern=r'^[^*#&+:<>?]+$'), + 'backendId': self._serialize.url("backend_id", backend_id, 'str', max_length=80, min_length=1), 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str') } url = self._client.format_url(url, **path_format_arguments) @@ -211,7 +215,7 @@ def get( 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])?$'), - 'backendId': self._serialize.url("backend_id", backend_id, 'str', max_length=80, min_length=1, pattern=r'^[^*#&+:<>?]+$'), + 'backendId': self._serialize.url("backend_id", backend_id, 'str', max_length=80, min_length=1), 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str') } url = self._client.format_url(url, **path_format_arguments) @@ -237,9 +241,8 @@ def get( if response.status_code not in [200]: raise models.ErrorResponseException(self._deserialize, response) - deserialized = None header_dict = {} - + deserialized = None if response.status_code == 200: deserialized = self._deserialize('BackendContract', response) header_dict = { @@ -286,7 +289,7 @@ def create_or_update( 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])?$'), - 'backendId': self._serialize.url("backend_id", backend_id, 'str', max_length=80, min_length=1, pattern=r'^[^*#&+:<>?]+$'), + 'backendId': self._serialize.url("backend_id", backend_id, 'str', max_length=80, min_length=1), 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str') } url = self._client.format_url(url, **path_format_arguments) @@ -318,9 +321,8 @@ def create_or_update( if response.status_code not in [200, 201]: raise models.ErrorResponseException(self._deserialize, response) - deserialized = None header_dict = {} - + deserialized = None if response.status_code == 200: deserialized = self._deserialize('BackendContract', response) header_dict = { @@ -373,7 +375,7 @@ def update( 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])?$'), - 'backendId': self._serialize.url("backend_id", backend_id, 'str', max_length=80, min_length=1, pattern=r'^[^*#&+:<>?]+$'), + 'backendId': self._serialize.url("backend_id", backend_id, 'str', max_length=80, min_length=1), 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str') } url = self._client.format_url(url, **path_format_arguments) @@ -438,7 +440,7 @@ def delete( 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])?$'), - 'backendId': self._serialize.url("backend_id", backend_id, 'str', max_length=80, min_length=1, pattern=r'^[^*#&+:<>?]+$'), + 'backendId': self._serialize.url("backend_id", backend_id, 'str', max_length=80, min_length=1), 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str') } url = self._client.format_url(url, **path_format_arguments) @@ -504,7 +506,7 @@ def reconnect( 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])?$'), - 'backendId': self._serialize.url("backend_id", backend_id, 'str', max_length=80, min_length=1, pattern=r'^[^*#&+:<>?]+$'), + 'backendId': self._serialize.url("backend_id", backend_id, 'str', max_length=80, min_length=1), 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str') } url = self._client.format_url(url, **path_format_arguments) diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/cache_operations.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/_cache_operations.py similarity index 97% rename from sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/cache_operations.py rename to sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/_cache_operations.py index 165b93f2c6f3..e763c146395d 100644 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/cache_operations.py +++ b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/_cache_operations.py @@ -18,11 +18,13 @@ class CacheOperations(object): """CacheOperations operations. + You should not instantiate directly this class, but create a Client instance that will create it for you and attach it as attribute. + :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: "2019-01-01". + :ivar api_version: Version of the API to be used with the client request. Constant value: "2019-12-01-preview". """ models = models @@ -32,7 +34,7 @@ def __init__(self, client, config, serializer, deserializer): self._client = client self._serialize = serializer self._deserialize = deserializer - self.api_version = "2019-01-01" + self.api_version = "2019-12-01-preview" self.config = config @@ -60,8 +62,7 @@ def list_by_service( :raises: :class:`ErrorResponseException` """ - def internal_paging(next_link=None, raw=False): - + def prepare_request(next_link=None): if not next_link: # Construct URL url = self.list_by_service.metadata['url'] @@ -96,6 +97,11 @@ def internal_paging(next_link=None, raw=False): # Construct and send request request = self._client.get(url, query_parameters, header_parameters) + return request + + def internal_paging(next_link=None): + request = prepare_request(next_link) + response = self._client.send(request, stream=False, **operation_config) if response.status_code not in [200]: @@ -104,12 +110,10 @@ def internal_paging(next_link=None, raw=False): return response # Deserialize response - deserialized = models.CacheContractPaged(internal_paging, self._deserialize.dependencies) - + header_dict = None if raw: header_dict = {} - client_raw_response = models.CacheContractPaged(internal_paging, self._deserialize.dependencies, header_dict) - return client_raw_response + deserialized = models.CacheContractPaged(internal_paging, self._deserialize.dependencies, header_dict) return deserialized list_by_service.metadata = {'url': '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ApiManagement/service/{serviceName}/caches'} @@ -227,9 +231,8 @@ def get( if response.status_code not in [200]: raise models.ErrorResponseException(self._deserialize, response) - deserialized = None header_dict = {} - + deserialized = None if response.status_code == 200: deserialized = self._deserialize('CacheContract', response) header_dict = { @@ -309,9 +312,8 @@ def create_or_update( if response.status_code not in [200, 201]: raise models.ErrorResponseException(self._deserialize, response) - deserialized = None header_dict = {} - + deserialized = None if response.status_code == 200: deserialized = self._deserialize('CacheContract', response) header_dict = { diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/certificate_operations.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/_certificate_operations.py similarity index 97% rename from sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/certificate_operations.py rename to sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/_certificate_operations.py index 12276ecf2d2c..f0ae97fcd979 100644 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/certificate_operations.py +++ b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/_certificate_operations.py @@ -18,11 +18,13 @@ class CertificateOperations(object): """CertificateOperations operations. + You should not instantiate directly this class, but create a Client instance that will create it for you and attach it as attribute. + :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: "2019-01-01". + :ivar api_version: Version of the API to be used with the client request. Constant value: "2019-12-01-preview". """ models = models @@ -32,7 +34,7 @@ def __init__(self, client, config, serializer, deserializer): self._client = client self._serialize = serializer self._deserialize = deserializer - self.api_version = "2019-01-01" + self.api_version = "2019-12-01-preview" self.config = config @@ -70,8 +72,7 @@ def list_by_service( :raises: :class:`ErrorResponseException` """ - def internal_paging(next_link=None, raw=False): - + def prepare_request(next_link=None): if not next_link: # Construct URL url = self.list_by_service.metadata['url'] @@ -108,6 +109,11 @@ def internal_paging(next_link=None, raw=False): # Construct and send request request = self._client.get(url, query_parameters, header_parameters) + return request + + def internal_paging(next_link=None): + request = prepare_request(next_link) + response = self._client.send(request, stream=False, **operation_config) if response.status_code not in [200]: @@ -116,12 +122,10 @@ def internal_paging(next_link=None, raw=False): return response # Deserialize response - deserialized = models.CertificateContractPaged(internal_paging, self._deserialize.dependencies) - + header_dict = None if raw: header_dict = {} - client_raw_response = models.CertificateContractPaged(internal_paging, self._deserialize.dependencies, header_dict) - return client_raw_response + deserialized = models.CertificateContractPaged(internal_paging, self._deserialize.dependencies, header_dict) return deserialized list_by_service.metadata = {'url': '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ApiManagement/service/{serviceName}/certificates'} @@ -239,9 +243,8 @@ def get( if response.status_code not in [200]: raise models.ErrorResponseException(self._deserialize, response) - deserialized = None header_dict = {} - + deserialized = None if response.status_code == 200: deserialized = self._deserialize('CertificateContract', response) header_dict = { @@ -326,9 +329,8 @@ def create_or_update( if response.status_code not in [200, 201]: raise models.ErrorResponseException(self._deserialize, response) - deserialized = None header_dict = {} - + deserialized = None if response.status_code == 200: deserialized = self._deserialize('CertificateContract', response) header_dict = { diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/delegation_settings_operations.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/_delegation_settings_operations.py similarity index 80% rename from sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/delegation_settings_operations.py rename to sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/_delegation_settings_operations.py index d3671260fe47..986cc7166478 100644 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/delegation_settings_operations.py +++ b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/_delegation_settings_operations.py @@ -18,11 +18,13 @@ class DelegationSettingsOperations(object): """DelegationSettingsOperations operations. + You should not instantiate directly this class, but create a Client instance that will create it for you and attach it as attribute. + :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: "2019-01-01". + :ivar api_version: Version of the API to be used with the client request. Constant value: "2019-12-01-preview". """ models = models @@ -32,7 +34,7 @@ def __init__(self, client, config, serializer, deserializer): self._client = client self._serialize = serializer self._deserialize = deserializer - self.api_version = "2019-01-01" + self.api_version = "2019-12-01-preview" self.config = config @@ -140,9 +142,8 @@ def get( if response.status_code not in [200]: raise models.ErrorResponseException(self._deserialize, response) - deserialized = None header_dict = {} - + deserialized = None if response.status_code == 200: deserialized = self._deserialize('PortalDelegationSettings', response) header_dict = { @@ -283,7 +284,6 @@ def create_or_update( raise models.ErrorResponseException(self._deserialize, response) deserialized = None - if response.status_code == 200: deserialized = self._deserialize('PortalDelegationSettings', response) @@ -293,3 +293,65 @@ def create_or_update( return deserialized create_or_update.metadata = {'url': '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ApiManagement/service/{serviceName}/portalsettings/delegation'} + + def list_secrets( + self, resource_group_name, service_name, custom_headers=None, raw=False, **operation_config): + """Gets the secret validation key of the DelegationSettings. + + :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 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: PortalSettingValidationKeyContract or ClientRawResponse if + raw=true + :rtype: + ~azure.mgmt.apimanagement.models.PortalSettingValidationKeyContract or + ~msrest.pipeline.ClientRawResponse + :raises: + :class:`ErrorResponseException` + """ + # Construct URL + url = self.list_secrets.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') + } + 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.post(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) + + deserialized = None + if response.status_code == 200: + deserialized = self._deserialize('PortalSettingValidationKeyContract', response) + + if raw: + client_raw_response = ClientRawResponse(deserialized, response) + return client_raw_response + + return deserialized + list_secrets.metadata = {'url': '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ApiManagement/service/{serviceName}/portalsettings/delegation/listSecrets'} diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/diagnostic_operations.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/_diagnostic_operations.py similarity index 97% rename from sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/diagnostic_operations.py rename to sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/_diagnostic_operations.py index 8aeb6d1d3ed8..f209d1fca8e8 100644 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/diagnostic_operations.py +++ b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/_diagnostic_operations.py @@ -18,11 +18,13 @@ class DiagnosticOperations(object): """DiagnosticOperations operations. + You should not instantiate directly this class, but create a Client instance that will create it for you and attach it as attribute. + :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: "2019-01-01". + :ivar api_version: Version of the API to be used with the client request. Constant value: "2019-12-01-preview". """ models = models @@ -32,7 +34,7 @@ def __init__(self, client, config, serializer, deserializer): self._client = client self._serialize = serializer self._deserialize = deserializer - self.api_version = "2019-01-01" + self.api_version = "2019-12-01-preview" self.config = config @@ -65,8 +67,7 @@ def list_by_service( :raises: :class:`ErrorResponseException` """ - def internal_paging(next_link=None, raw=False): - + def prepare_request(next_link=None): if not next_link: # Construct URL url = self.list_by_service.metadata['url'] @@ -103,6 +104,11 @@ def internal_paging(next_link=None, raw=False): # Construct and send request request = self._client.get(url, query_parameters, header_parameters) + return request + + def internal_paging(next_link=None): + request = prepare_request(next_link) + response = self._client.send(request, stream=False, **operation_config) if response.status_code not in [200]: @@ -111,12 +117,10 @@ def internal_paging(next_link=None, raw=False): return response # Deserialize response - deserialized = models.DiagnosticContractPaged(internal_paging, self._deserialize.dependencies) - + header_dict = None if raw: header_dict = {} - client_raw_response = models.DiagnosticContractPaged(internal_paging, self._deserialize.dependencies, header_dict) - return client_raw_response + deserialized = models.DiagnosticContractPaged(internal_paging, self._deserialize.dependencies, header_dict) return deserialized list_by_service.metadata = {'url': '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ApiManagement/service/{serviceName}/diagnostics'} @@ -234,9 +238,8 @@ def get( if response.status_code not in [200]: raise models.ErrorResponseException(self._deserialize, response) - deserialized = None header_dict = {} - + deserialized = None if response.status_code == 200: deserialized = self._deserialize('DiagnosticContract', response) header_dict = { @@ -315,9 +318,8 @@ def create_or_update( if response.status_code not in [200, 201]: raise models.ErrorResponseException(self._deserialize, response) - deserialized = None header_dict = {} - + deserialized = None if response.status_code == 200: deserialized = self._deserialize('DiagnosticContract', response) header_dict = { diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/email_template_operations.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/_email_template_operations.py similarity index 98% rename from sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/email_template_operations.py rename to sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/_email_template_operations.py index 65badc17e0bb..13047b32c8fe 100644 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/email_template_operations.py +++ b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/_email_template_operations.py @@ -18,11 +18,13 @@ class EmailTemplateOperations(object): """EmailTemplateOperations operations. + You should not instantiate directly this class, but create a Client instance that will create it for you and attach it as attribute. + :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: "2019-01-01". + :ivar api_version: Version of the API to be used with the client request. Constant value: "2019-12-01-preview". """ models = models @@ -32,7 +34,7 @@ def __init__(self, client, config, serializer, deserializer): self._client = client self._serialize = serializer self._deserialize = deserializer - self.api_version = "2019-01-01" + self.api_version = "2019-12-01-preview" self.config = config @@ -65,8 +67,7 @@ def list_by_service( :raises: :class:`ErrorResponseException` """ - def internal_paging(next_link=None, raw=False): - + def prepare_request(next_link=None): if not next_link: # Construct URL url = self.list_by_service.metadata['url'] @@ -103,6 +104,11 @@ def internal_paging(next_link=None, raw=False): # Construct and send request request = self._client.get(url, query_parameters, header_parameters) + return request + + def internal_paging(next_link=None): + request = prepare_request(next_link) + response = self._client.send(request, stream=False, **operation_config) if response.status_code not in [200]: @@ -111,12 +117,10 @@ def internal_paging(next_link=None, raw=False): return response # Deserialize response - deserialized = models.EmailTemplateContractPaged(internal_paging, self._deserialize.dependencies) - + header_dict = None if raw: header_dict = {} - client_raw_response = models.EmailTemplateContractPaged(internal_paging, self._deserialize.dependencies, header_dict) - return client_raw_response + deserialized = models.EmailTemplateContractPaged(internal_paging, self._deserialize.dependencies, header_dict) return deserialized list_by_service.metadata = {'url': '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ApiManagement/service/{serviceName}/templates'} @@ -256,9 +260,8 @@ def get( if response.status_code not in [200]: raise models.ErrorResponseException(self._deserialize, response) - deserialized = None header_dict = {} - + deserialized = None if response.status_code == 200: deserialized = self._deserialize('EmailTemplateContract', response) header_dict = { @@ -350,7 +353,6 @@ def create_or_update( raise models.ErrorResponseException(self._deserialize, response) deserialized = None - if response.status_code == 200: deserialized = self._deserialize('EmailTemplateContract', response) if response.status_code == 201: diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/group_operations.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/_group_operations.py similarity index 97% rename from sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/group_operations.py rename to sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/_group_operations.py index a7cda28143af..f05a52a36510 100644 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/group_operations.py +++ b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/_group_operations.py @@ -18,11 +18,13 @@ class GroupOperations(object): """GroupOperations operations. + You should not instantiate directly this class, but create a Client instance that will create it for you and attach it as attribute. + :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: "2019-01-01". + :ivar api_version: Version of the API to be used with the client request. Constant value: "2019-12-01-preview". """ models = models @@ -32,7 +34,7 @@ def __init__(self, client, config, serializer, deserializer): self._client = client self._serialize = serializer self._deserialize = deserializer - self.api_version = "2019-01-01" + self.api_version = "2019-12-01-preview" self.config = config @@ -68,8 +70,7 @@ def list_by_service( :raises: :class:`ErrorResponseException` """ - def internal_paging(next_link=None, raw=False): - + def prepare_request(next_link=None): if not next_link: # Construct URL url = self.list_by_service.metadata['url'] @@ -106,6 +107,11 @@ def internal_paging(next_link=None, raw=False): # Construct and send request request = self._client.get(url, query_parameters, header_parameters) + return request + + def internal_paging(next_link=None): + request = prepare_request(next_link) + response = self._client.send(request, stream=False, **operation_config) if response.status_code not in [200]: @@ -114,12 +120,10 @@ def internal_paging(next_link=None, raw=False): return response # Deserialize response - deserialized = models.GroupContractPaged(internal_paging, self._deserialize.dependencies) - + header_dict = None if raw: header_dict = {} - client_raw_response = models.GroupContractPaged(internal_paging, self._deserialize.dependencies, header_dict) - return client_raw_response + deserialized = models.GroupContractPaged(internal_paging, self._deserialize.dependencies, header_dict) return deserialized list_by_service.metadata = {'url': '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ApiManagement/service/{serviceName}/groups'} @@ -151,7 +155,7 @@ def get_entity_tag( 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])?$'), - 'groupId': self._serialize.url("group_id", group_id, 'str', max_length=256, min_length=1, pattern=r'^[^*#&+:<>?]+$'), + 'groupId': self._serialize.url("group_id", group_id, 'str', max_length=256, min_length=1), 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str') } url = self._client.format_url(url, **path_format_arguments) @@ -211,7 +215,7 @@ def get( 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])?$'), - 'groupId': self._serialize.url("group_id", group_id, 'str', max_length=256, min_length=1, pattern=r'^[^*#&+:<>?]+$'), + 'groupId': self._serialize.url("group_id", group_id, 'str', max_length=256, min_length=1), 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str') } url = self._client.format_url(url, **path_format_arguments) @@ -237,9 +241,8 @@ def get( if response.status_code not in [200]: raise models.ErrorResponseException(self._deserialize, response) - deserialized = None header_dict = {} - + deserialized = None if response.status_code == 200: deserialized = self._deserialize('GroupContract', response) header_dict = { @@ -287,7 +290,7 @@ def create_or_update( 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])?$'), - 'groupId': self._serialize.url("group_id", group_id, 'str', max_length=256, min_length=1, pattern=r'^[^*#&+:<>?]+$'), + 'groupId': self._serialize.url("group_id", group_id, 'str', max_length=256, min_length=1), 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str') } url = self._client.format_url(url, **path_format_arguments) @@ -319,9 +322,8 @@ def create_or_update( if response.status_code not in [200, 201]: raise models.ErrorResponseException(self._deserialize, response) - deserialized = None header_dict = {} - + deserialized = None if response.status_code == 200: deserialized = self._deserialize('GroupContract', response) header_dict = { @@ -374,7 +376,7 @@ def update( 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])?$'), - 'groupId': self._serialize.url("group_id", group_id, 'str', max_length=256, min_length=1, pattern=r'^[^*#&+:<>?]+$'), + 'groupId': self._serialize.url("group_id", group_id, 'str', max_length=256, min_length=1), 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str') } url = self._client.format_url(url, **path_format_arguments) @@ -439,7 +441,7 @@ def delete( 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])?$'), - 'groupId': self._serialize.url("group_id", group_id, 'str', max_length=256, min_length=1, pattern=r'^[^*#&+:<>?]+$'), + 'groupId': self._serialize.url("group_id", group_id, 'str', max_length=256, min_length=1), 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str') } url = self._client.format_url(url, **path_format_arguments) diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/group_user_operations.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/_group_user_operations.py similarity index 95% rename from sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/group_user_operations.py rename to sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/_group_user_operations.py index 728f33598003..98b0bee758b5 100644 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/group_user_operations.py +++ b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/_group_user_operations.py @@ -18,11 +18,13 @@ class GroupUserOperations(object): """GroupUserOperations operations. + You should not instantiate directly this class, but create a Client instance that will create it for you and attach it as attribute. + :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: "2019-01-01". + :ivar api_version: Version of the API to be used with the client request. Constant value: "2019-12-01-preview". """ models = models @@ -32,7 +34,7 @@ def __init__(self, client, config, serializer, deserializer): self._client = client self._serialize = serializer self._deserialize = deserializer - self.api_version = "2019-01-01" + self.api_version = "2019-12-01-preview" self.config = config @@ -75,15 +77,14 @@ def list( :raises: :class:`ErrorResponseException` """ - def internal_paging(next_link=None, raw=False): - + def prepare_request(next_link=None): if not next_link: # Construct URL url = self.list.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])?$'), - 'groupId': self._serialize.url("group_id", group_id, 'str', max_length=256, min_length=1, pattern=r'^[^*#&+:<>?]+$'), + 'groupId': self._serialize.url("group_id", group_id, 'str', max_length=256, min_length=1), 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str') } url = self._client.format_url(url, **path_format_arguments) @@ -114,6 +115,11 @@ def internal_paging(next_link=None, raw=False): # Construct and send request request = self._client.get(url, query_parameters, header_parameters) + return request + + def internal_paging(next_link=None): + request = prepare_request(next_link) + response = self._client.send(request, stream=False, **operation_config) if response.status_code not in [200]: @@ -122,12 +128,10 @@ def internal_paging(next_link=None, raw=False): return response # Deserialize response - deserialized = models.UserContractPaged(internal_paging, self._deserialize.dependencies) - + header_dict = None if raw: header_dict = {} - client_raw_response = models.UserContractPaged(internal_paging, self._deserialize.dependencies, header_dict) - return client_raw_response + deserialized = models.UserContractPaged(internal_paging, self._deserialize.dependencies, header_dict) return deserialized list.metadata = {'url': '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ApiManagement/service/{serviceName}/groups/{groupId}/users'} @@ -162,8 +166,8 @@ def check_entity_exists( 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])?$'), - 'groupId': self._serialize.url("group_id", group_id, 'str', max_length=256, min_length=1, pattern=r'^[^*#&+:<>?]+$'), - 'userId': self._serialize.url("user_id", user_id, 'str', max_length=80, min_length=1, pattern=r'^[^*#&+:<>?]+$'), + 'groupId': self._serialize.url("group_id", group_id, 'str', max_length=256, min_length=1), + 'userId': self._serialize.url("user_id", user_id, 'str', max_length=80, min_length=1), 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str') } url = self._client.format_url(url, **path_format_arguments) @@ -225,8 +229,8 @@ def create( 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])?$'), - 'groupId': self._serialize.url("group_id", group_id, 'str', max_length=256, min_length=1, pattern=r'^[^*#&+:<>?]+$'), - 'userId': self._serialize.url("user_id", user_id, 'str', max_length=80, min_length=1, pattern=r'^[^*#&+:<>?]+$'), + 'groupId': self._serialize.url("group_id", group_id, 'str', max_length=256, min_length=1), + 'userId': self._serialize.url("user_id", user_id, 'str', max_length=80, min_length=1), 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str') } url = self._client.format_url(url, **path_format_arguments) @@ -253,7 +257,6 @@ def create( raise models.ErrorResponseException(self._deserialize, response) deserialized = None - if response.status_code == 200: deserialized = self._deserialize('UserContract', response) if response.status_code == 201: @@ -295,8 +298,8 @@ def delete( 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])?$'), - 'groupId': self._serialize.url("group_id", group_id, 'str', max_length=256, min_length=1, pattern=r'^[^*#&+:<>?]+$'), - 'userId': self._serialize.url("user_id", user_id, 'str', max_length=80, min_length=1, pattern=r'^[^*#&+:<>?]+$'), + 'groupId': self._serialize.url("group_id", group_id, 'str', max_length=256, min_length=1), + 'userId': self._serialize.url("user_id", user_id, 'str', max_length=80, min_length=1), 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str') } url = self._client.format_url(url, **path_format_arguments) diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/identity_provider_operations.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/_identity_provider_operations.py similarity index 85% rename from sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/identity_provider_operations.py rename to sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/_identity_provider_operations.py index 601391c42832..d72b64c30417 100644 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/identity_provider_operations.py +++ b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/_identity_provider_operations.py @@ -18,11 +18,13 @@ class IdentityProviderOperations(object): """IdentityProviderOperations operations. + You should not instantiate directly this class, but create a Client instance that will create it for you and attach it as attribute. + :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: "2019-01-01". + :ivar api_version: Version of the API to be used with the client request. Constant value: "2019-12-01-preview". """ models = models @@ -32,7 +34,7 @@ def __init__(self, client, config, serializer, deserializer): self._client = client self._serialize = serializer self._deserialize = deserializer - self.api_version = "2019-01-01" + self.api_version = "2019-12-01-preview" self.config = config @@ -56,8 +58,7 @@ def list_by_service( :raises: :class:`ErrorResponseException` """ - def internal_paging(next_link=None, raw=False): - + def prepare_request(next_link=None): if not next_link: # Construct URL url = self.list_by_service.metadata['url'] @@ -88,6 +89,11 @@ def internal_paging(next_link=None, raw=False): # Construct and send request request = self._client.get(url, query_parameters, header_parameters) + return request + + def internal_paging(next_link=None): + request = prepare_request(next_link) + response = self._client.send(request, stream=False, **operation_config) if response.status_code not in [200]: @@ -96,12 +102,10 @@ def internal_paging(next_link=None, raw=False): return response # Deserialize response - deserialized = models.IdentityProviderContractPaged(internal_paging, self._deserialize.dependencies) - + header_dict = None if raw: header_dict = {} - client_raw_response = models.IdentityProviderContractPaged(internal_paging, self._deserialize.dependencies, header_dict) - return client_raw_response + deserialized = models.IdentityProviderContractPaged(internal_paging, self._deserialize.dependencies, header_dict) return deserialized list_by_service.metadata = {'url': '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ApiManagement/service/{serviceName}/identityProviders'} @@ -224,9 +228,8 @@ def get( if response.status_code not in [200]: raise models.ErrorResponseException(self._deserialize, response) - deserialized = None header_dict = {} - + deserialized = None if response.status_code == 200: deserialized = self._deserialize('IdentityProviderContract', response) header_dict = { @@ -256,7 +259,7 @@ def create_or_update( ~azure.mgmt.apimanagement.models.IdentityProviderType :param parameters: Create parameters. :type parameters: - ~azure.mgmt.apimanagement.models.IdentityProviderContract + ~azure.mgmt.apimanagement.models.IdentityProviderCreateContract :param if_match: ETag of the Entity. Not required when creating an entity, but required when updating an entity. :type if_match: str @@ -299,7 +302,7 @@ def create_or_update( header_parameters['accept-language'] = self._serialize.header("self.config.accept_language", self.config.accept_language, 'str') # Construct body - body_content = self._serialize.body(parameters, 'IdentityProviderContract') + body_content = self._serialize.body(parameters, 'IdentityProviderCreateContract') # Construct and send request request = self._client.put(url, query_parameters, header_parameters, body_content) @@ -308,9 +311,8 @@ def create_or_update( if response.status_code not in [200, 201]: raise models.ErrorResponseException(self._deserialize, response) - deserialized = None header_dict = {} - + deserialized = None if response.status_code == 200: deserialized = self._deserialize('IdentityProviderContract', response) header_dict = { @@ -462,3 +464,69 @@ def delete( client_raw_response = ClientRawResponse(None, response) return client_raw_response delete.metadata = {'url': '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ApiManagement/service/{serviceName}/identityProviders/{identityProviderName}'} + + def list_secrets( + self, resource_group_name, service_name, identity_provider_name, custom_headers=None, raw=False, **operation_config): + """Gets the client secret details of the Identity Provider. + + :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 identity_provider_name: Identity Provider Type identifier. + Possible values include: 'facebook', 'google', 'microsoft', 'twitter', + 'aad', 'aadB2C' + :type identity_provider_name: str or + ~azure.mgmt.apimanagement.models.IdentityProviderType + :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: ClientSecretContract or ClientRawResponse if raw=true + :rtype: ~azure.mgmt.apimanagement.models.ClientSecretContract or + ~msrest.pipeline.ClientRawResponse + :raises: + :class:`ErrorResponseException` + """ + # Construct URL + url = self.list_secrets.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])?$'), + 'identityProviderName': self._serialize.url("identity_provider_name", identity_provider_name, 'str'), + '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.post(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) + + deserialized = None + if response.status_code == 200: + deserialized = self._deserialize('ClientSecretContract', response) + + if raw: + client_raw_response = ClientRawResponse(deserialized, response) + return client_raw_response + + return deserialized + list_secrets.metadata = {'url': '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ApiManagement/service/{serviceName}/identityProviders/{identityProviderName}/listSecrets'} diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/issue_operations.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/_issue_operations.py similarity index 95% rename from sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/issue_operations.py rename to sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/_issue_operations.py index 370534595261..0446aed7ce56 100644 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/issue_operations.py +++ b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/_issue_operations.py @@ -18,11 +18,13 @@ class IssueOperations(object): """IssueOperations operations. + You should not instantiate directly this class, but create a Client instance that will create it for you and attach it as attribute. + :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: "2019-01-01". + :ivar api_version: Version of the API to be used with the client request. Constant value: "2019-12-01-preview". """ models = models @@ -32,7 +34,7 @@ def __init__(self, client, config, serializer, deserializer): self._client = client self._serialize = serializer self._deserialize = deserializer - self.api_version = "2019-01-01" + self.api_version = "2019-12-01-preview" self.config = config @@ -71,8 +73,7 @@ def list_by_service( :raises: :class:`ErrorResponseException` """ - def internal_paging(next_link=None, raw=False): - + def prepare_request(next_link=None): if not next_link: # Construct URL url = self.list_by_service.metadata['url'] @@ -109,6 +110,11 @@ def internal_paging(next_link=None, raw=False): # Construct and send request request = self._client.get(url, query_parameters, header_parameters) + return request + + def internal_paging(next_link=None): + request = prepare_request(next_link) + response = self._client.send(request, stream=False, **operation_config) if response.status_code not in [200]: @@ -117,12 +123,10 @@ def internal_paging(next_link=None, raw=False): return response # Deserialize response - deserialized = models.IssueContractPaged(internal_paging, self._deserialize.dependencies) - + header_dict = None if raw: header_dict = {} - client_raw_response = models.IssueContractPaged(internal_paging, self._deserialize.dependencies, header_dict) - return client_raw_response + deserialized = models.IssueContractPaged(internal_paging, self._deserialize.dependencies, header_dict) return deserialized list_by_service.metadata = {'url': '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ApiManagement/service/{serviceName}/issues'} @@ -180,9 +184,8 @@ def get( if response.status_code not in [200]: raise models.ErrorResponseException(self._deserialize, response) - deserialized = None header_dict = {} - + deserialized = None if response.status_code == 200: deserialized = self._deserialize('IssueContract', response) header_dict = { diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/logger_operations.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/_logger_operations.py similarity index 98% rename from sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/logger_operations.py rename to sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/_logger_operations.py index b8ac594d7456..8a04ac322925 100644 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/logger_operations.py +++ b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/_logger_operations.py @@ -18,11 +18,13 @@ class LoggerOperations(object): """LoggerOperations operations. + You should not instantiate directly this class, but create a Client instance that will create it for you and attach it as attribute. + :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: "2019-01-01". + :ivar api_version: Version of the API to be used with the client request. Constant value: "2019-12-01-preview". """ models = models @@ -32,7 +34,7 @@ def __init__(self, client, config, serializer, deserializer): self._client = client self._serialize = serializer self._deserialize = deserializer - self.api_version = "2019-01-01" + self.api_version = "2019-12-01-preview" self.config = config @@ -68,8 +70,7 @@ def list_by_service( :raises: :class:`ErrorResponseException` """ - def internal_paging(next_link=None, raw=False): - + def prepare_request(next_link=None): if not next_link: # Construct URL url = self.list_by_service.metadata['url'] @@ -106,6 +107,11 @@ def internal_paging(next_link=None, raw=False): # Construct and send request request = self._client.get(url, query_parameters, header_parameters) + return request + + def internal_paging(next_link=None): + request = prepare_request(next_link) + response = self._client.send(request, stream=False, **operation_config) if response.status_code not in [200]: @@ -114,12 +120,10 @@ def internal_paging(next_link=None, raw=False): return response # Deserialize response - deserialized = models.LoggerContractPaged(internal_paging, self._deserialize.dependencies) - + header_dict = None if raw: header_dict = {} - client_raw_response = models.LoggerContractPaged(internal_paging, self._deserialize.dependencies, header_dict) - return client_raw_response + deserialized = models.LoggerContractPaged(internal_paging, self._deserialize.dependencies, header_dict) return deserialized list_by_service.metadata = {'url': '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ApiManagement/service/{serviceName}/loggers'} @@ -237,9 +241,8 @@ def get( if response.status_code not in [200]: raise models.ErrorResponseException(self._deserialize, response) - deserialized = None header_dict = {} - + deserialized = None if response.status_code == 200: deserialized = self._deserialize('LoggerContract', response) header_dict = { @@ -318,9 +321,8 @@ def create_or_update( if response.status_code not in [200, 201]: raise models.ErrorResponseException(self._deserialize, response) - deserialized = None header_dict = {} - + deserialized = None if response.status_code == 200: deserialized = self._deserialize('LoggerContract', response) header_dict = { diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/_named_value_operations.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/_named_value_operations.py new file mode 100644 index 000000000000..2eae51c8456d --- /dev/null +++ b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/_named_value_operations.py @@ -0,0 +1,622 @@ +# 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 msrest.polling import LROPoller, NoPolling +from msrestazure.polling.arm_polling import ARMPolling + +from .. import models + + +class NamedValueOperations(object): + """NamedValueOperations operations. + + You should not instantiate directly this class, but create a Client instance that will create it for you and attach it as attribute. + + :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: "2019-12-01-preview". + """ + + models = models + + def __init__(self, client, config, serializer, deserializer): + + self._client = client + self._serialize = serializer + self._deserialize = deserializer + self.api_version = "2019-12-01-preview" + + self.config = config + + def list_by_service( + self, resource_group_name, service_name, filter=None, top=None, skip=None, custom_headers=None, raw=False, **operation_config): + """Lists a collection of NamedValues defined within a 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 filter: | Field | Usage | Supported operators + | Supported functions + |
|-------------|-------------|-------------|-------------|
| + tags | filter | ge, le, eq, ne, gt, lt | substringof, contains, + startswith, endswith, any, all |
| displayName | filter | ge, le, + eq, ne, gt, lt | substringof, contains, startswith, endswith |
+ :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 NamedValueContract + :rtype: + ~azure.mgmt.apimanagement.models.NamedValueContractPaged[~azure.mgmt.apimanagement.models.NamedValueContract] + :raises: + :class:`ErrorResponseException` + """ + def prepare_request(next_link=None): + 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') + } + url = self._client.format_url(url, **path_format_arguments) + + # Construct parameters + query_parameters = {} + 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) + query_parameters['api-version'] = self._serialize.query("self.api_version", self.api_version, 'str') + + 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) + return request + + def internal_paging(next_link=None): + request = prepare_request(next_link) + + 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 + header_dict = None + if raw: + header_dict = {} + deserialized = models.NamedValueContractPaged(internal_paging, self._deserialize.dependencies, header_dict) + + return deserialized + list_by_service.metadata = {'url': '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ApiManagement/service/{serviceName}/namedValues'} + + def get_entity_tag( + self, resource_group_name, service_name, named_value_id, custom_headers=None, raw=False, **operation_config): + """Gets the entity state (Etag) version of the NamedValue specified by its + identifier. + + :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 named_value_id: Identifier of the NamedValue. + :type named_value_id: 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.get_entity_tag.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])?$'), + 'namedValueId': self._serialize.url("named_value_id", named_value_id, 'str', max_length=256, pattern=r'^[^*#&+:<>?]+$'), + '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 [200]: + raise models.ErrorResponseException(self._deserialize, response) + + if raw: + client_raw_response = ClientRawResponse(None, response) + client_raw_response.add_headers({ + 'ETag': 'str', + }) + return client_raw_response + get_entity_tag.metadata = {'url': '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ApiManagement/service/{serviceName}/namedValues/{namedValueId}'} + + def get( + self, resource_group_name, service_name, named_value_id, custom_headers=None, raw=False, **operation_config): + """Gets the details of the NamedValue specified by its identifier. + + :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 named_value_id: Identifier of the NamedValue. + :type named_value_id: 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: NamedValueContract or ClientRawResponse if raw=true + :rtype: ~azure.mgmt.apimanagement.models.NamedValueContract or + ~msrest.pipeline.ClientRawResponse + :raises: + :class:`ErrorResponseException` + """ + # Construct URL + url = self.get.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])?$'), + 'namedValueId': self._serialize.url("named_value_id", named_value_id, 'str', max_length=256, pattern=r'^[^*#&+:<>?]+$'), + '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.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) + + header_dict = {} + deserialized = None + if response.status_code == 200: + deserialized = self._deserialize('NamedValueContract', response) + header_dict = { + 'ETag': 'str', + } + + if raw: + client_raw_response = ClientRawResponse(deserialized, response) + client_raw_response.add_headers(header_dict) + return client_raw_response + + return deserialized + get.metadata = {'url': '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ApiManagement/service/{serviceName}/namedValues/{namedValueId}'} + + + def _create_or_update_initial( + self, resource_group_name, service_name, named_value_id, parameters, if_match=None, custom_headers=None, raw=False, **operation_config): + # 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])?$'), + 'namedValueId': self._serialize.url("named_value_id", named_value_id, 'str', max_length=256, pattern=r'^[^*#&+:<>?]+$'), + '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' + header_parameters['Content-Type'] = 'application/json; charset=utf-8' + 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 if_match is not None: + header_parameters['If-Match'] = self._serialize.header("if_match", if_match, 'str') + 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 body + body_content = self._serialize.body(parameters, 'NamedValueCreateContract') + + # Construct and send request + request = self._client.put(url, query_parameters, header_parameters, body_content) + response = self._client.send(request, stream=False, **operation_config) + + if response.status_code not in [200, 201, 202]: + raise models.ErrorResponseException(self._deserialize, response) + + deserialized = None + header_dict = {} + + if response.status_code == 200: + deserialized = self._deserialize('NamedValueContract', response) + header_dict = { + 'ETag': 'str', + } + if response.status_code == 201: + deserialized = self._deserialize('NamedValueContract', response) + header_dict = { + 'ETag': 'str', + } + + if raw: + client_raw_response = ClientRawResponse(deserialized, response) + client_raw_response.add_headers(header_dict) + return client_raw_response + + return deserialized + + def create_or_update( + self, resource_group_name, service_name, named_value_id, parameters, if_match=None, custom_headers=None, raw=False, polling=True, **operation_config): + """Creates or updates a NamedValue. + + :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 named_value_id: Identifier of the NamedValue. + :type named_value_id: str + :param parameters: Create parameters. + :type parameters: + ~azure.mgmt.apimanagement.models.NamedValueCreateContract + :param if_match: ETag of the Entity. Not required when creating an + entity, but required when updating an entity. + :type if_match: str + :param dict custom_headers: headers that will be added to the request + :param bool raw: The poller return type is ClientRawResponse, the + direct response alongside the deserialized response + :param polling: True for ARMPolling, False for no polling, or a + polling object for personal polling strategy + :return: An instance of LROPoller that returns NamedValueContract or + ClientRawResponse if raw==True + :rtype: + ~msrestazure.azure_operation.AzureOperationPoller[~azure.mgmt.apimanagement.models.NamedValueContract] + or + ~msrestazure.azure_operation.AzureOperationPoller[~msrest.pipeline.ClientRawResponse[~azure.mgmt.apimanagement.models.NamedValueContract]] + :raises: + :class:`ErrorResponseException` + """ + raw_result = self._create_or_update_initial( + resource_group_name=resource_group_name, + service_name=service_name, + named_value_id=named_value_id, + parameters=parameters, + if_match=if_match, + custom_headers=custom_headers, + raw=True, + **operation_config + ) + + def get_long_running_output(response): + header_dict = { + 'ETag': 'str', + } + deserialized = self._deserialize('NamedValueContract', response) + + if raw: + client_raw_response = ClientRawResponse(deserialized, response) + client_raw_response.add_headers(header_dict) + return client_raw_response + + return deserialized + + lro_delay = operation_config.get( + 'long_running_operation_timeout', + self.config.long_running_operation_timeout) + if polling is True: polling_method = ARMPolling(lro_delay, **operation_config) + elif polling is False: polling_method = NoPolling() + else: polling_method = polling + return LROPoller(self._client, raw_result, get_long_running_output, polling_method) + create_or_update.metadata = {'url': '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ApiManagement/service/{serviceName}/namedValues/{namedValueId}'} + + + def _update_initial( + self, resource_group_name, service_name, named_value_id, parameters, if_match, custom_headers=None, raw=False, **operation_config): + # Construct URL + url = self.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])?$'), + 'namedValueId': self._serialize.url("named_value_id", named_value_id, 'str', max_length=256, pattern=r'^[^*#&+:<>?]+$'), + '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' + header_parameters['Content-Type'] = 'application/json; charset=utf-8' + 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) + header_parameters['If-Match'] = self._serialize.header("if_match", if_match, 'str') + 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 body + body_content = self._serialize.body(parameters, 'NamedValueUpdateParameters') + + # Construct and send request + request = self._client.patch(url, query_parameters, header_parameters, body_content) + response = self._client.send(request, stream=False, **operation_config) + + if response.status_code not in [200, 202, 204]: + raise models.ErrorResponseException(self._deserialize, response) + + deserialized = None + header_dict = {} + + if response.status_code == 200: + deserialized = self._deserialize('NamedValueContract', response) + header_dict = { + 'ETag': 'str', + } + + if raw: + client_raw_response = ClientRawResponse(deserialized, response) + client_raw_response.add_headers(header_dict) + return client_raw_response + + return deserialized + + def update( + self, resource_group_name, service_name, named_value_id, parameters, if_match, custom_headers=None, raw=False, polling=True, **operation_config): + """Updates the specific NamedValue. + + :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 named_value_id: Identifier of the NamedValue. + :type named_value_id: str + :param parameters: Update parameters. + :type parameters: + ~azure.mgmt.apimanagement.models.NamedValueUpdateParameters + :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 dict custom_headers: headers that will be added to the request + :param bool raw: The poller return type is ClientRawResponse, the + direct response alongside the deserialized response + :param polling: True for ARMPolling, False for no polling, or a + polling object for personal polling strategy + :return: An instance of LROPoller that returns NamedValueContract or + ClientRawResponse if raw==True + :rtype: + ~msrestazure.azure_operation.AzureOperationPoller[~azure.mgmt.apimanagement.models.NamedValueContract] + or + ~msrestazure.azure_operation.AzureOperationPoller[~msrest.pipeline.ClientRawResponse[~azure.mgmt.apimanagement.models.NamedValueContract]] + :raises: + :class:`ErrorResponseException` + """ + raw_result = self._update_initial( + resource_group_name=resource_group_name, + service_name=service_name, + named_value_id=named_value_id, + parameters=parameters, + if_match=if_match, + custom_headers=custom_headers, + raw=True, + **operation_config + ) + + def get_long_running_output(response): + header_dict = { + 'ETag': 'str', + } + deserialized = self._deserialize('NamedValueContract', response) + + if raw: + client_raw_response = ClientRawResponse(deserialized, response) + client_raw_response.add_headers(header_dict) + return client_raw_response + + return deserialized + + lro_delay = operation_config.get( + 'long_running_operation_timeout', + self.config.long_running_operation_timeout) + if polling is True: polling_method = ARMPolling(lro_delay, **operation_config) + elif polling is False: polling_method = NoPolling() + else: polling_method = polling + return LROPoller(self._client, raw_result, get_long_running_output, polling_method) + update.metadata = {'url': '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ApiManagement/service/{serviceName}/namedValues/{namedValueId}'} + + def delete( + self, resource_group_name, service_name, named_value_id, if_match, custom_headers=None, raw=False, **operation_config): + """Deletes specific NamedValue from 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 named_value_id: Identifier of the NamedValue. + :type named_value_id: str + :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 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])?$'), + 'namedValueId': self._serialize.url("named_value_id", named_value_id, 'str', max_length=256, pattern=r'^[^*#&+:<>?]+$'), + '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) + header_parameters['If-Match'] = self._serialize.header("if_match", if_match, 'str') + 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}/namedValues/{namedValueId}'} + + def list_value( + self, resource_group_name, service_name, named_value_id, custom_headers=None, raw=False, **operation_config): + """Gets the secret value of the NamedValue. + + :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 named_value_id: Identifier of the NamedValue. + :type named_value_id: 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: PropertyValueContract or ClientRawResponse if raw=true + :rtype: ~azure.mgmt.apimanagement.models.PropertyValueContract or + ~msrest.pipeline.ClientRawResponse + :raises: + :class:`ErrorResponseException` + """ + # Construct URL + url = self.list_value.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])?$'), + 'namedValueId': self._serialize.url("named_value_id", named_value_id, 'str', max_length=256, pattern=r'^[^*#&+:<>?]+$'), + '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.post(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) + + deserialized = None + if response.status_code == 200: + deserialized = self._deserialize('PropertyValueContract', response) + + if raw: + client_raw_response = ClientRawResponse(deserialized, response) + return client_raw_response + + return deserialized + list_value.metadata = {'url': '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ApiManagement/service/{serviceName}/namedValues/{namedValueId}/listValue'} diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/network_status_operations.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/_network_status_operations.py similarity index 97% rename from sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/network_status_operations.py rename to sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/_network_status_operations.py index 3dd3986da8e7..2b98b9e7904d 100644 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/network_status_operations.py +++ b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/_network_status_operations.py @@ -18,11 +18,13 @@ class NetworkStatusOperations(object): """NetworkStatusOperations operations. + You should not instantiate directly this class, but create a Client instance that will create it for you and attach it as attribute. + :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: "2019-01-01". + :ivar api_version: Version of the API to be used with the client request. Constant value: "2019-12-01-preview". """ models = models @@ -32,7 +34,7 @@ def __init__(self, client, config, serializer, deserializer): self._client = client self._serialize = serializer self._deserialize = deserializer - self.api_version = "2019-01-01" + self.api_version = "2019-12-01-preview" self.config = config @@ -89,7 +91,6 @@ def list_by_service( raise models.ErrorResponseException(self._deserialize, response) deserialized = None - if response.status_code == 200: deserialized = self._deserialize('[NetworkStatusContractByLocation]', response) @@ -157,7 +158,6 @@ def list_by_location( raise models.ErrorResponseException(self._deserialize, response) deserialized = None - if response.status_code == 200: deserialized = self._deserialize('NetworkStatusContract', response) diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/notification_operations.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/_notification_operations.py similarity index 96% rename from sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/notification_operations.py rename to sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/_notification_operations.py index 51ca2ea6c65f..842ab00bddeb 100644 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/notification_operations.py +++ b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/_notification_operations.py @@ -18,11 +18,13 @@ class NotificationOperations(object): """NotificationOperations operations. + You should not instantiate directly this class, but create a Client instance that will create it for you and attach it as attribute. + :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: "2019-01-01". + :ivar api_version: Version of the API to be used with the client request. Constant value: "2019-12-01-preview". """ models = models @@ -32,7 +34,7 @@ def __init__(self, client, config, serializer, deserializer): self._client = client self._serialize = serializer self._deserialize = deserializer - self.api_version = "2019-01-01" + self.api_version = "2019-12-01-preview" self.config = config @@ -59,8 +61,7 @@ def list_by_service( :raises: :class:`ErrorResponseException` """ - def internal_paging(next_link=None, raw=False): - + def prepare_request(next_link=None): if not next_link: # Construct URL url = self.list_by_service.metadata['url'] @@ -95,6 +96,11 @@ def internal_paging(next_link=None, raw=False): # Construct and send request request = self._client.get(url, query_parameters, header_parameters) + return request + + def internal_paging(next_link=None): + request = prepare_request(next_link) + response = self._client.send(request, stream=False, **operation_config) if response.status_code not in [200]: @@ -103,12 +109,10 @@ def internal_paging(next_link=None, raw=False): return response # Deserialize response - deserialized = models.NotificationContractPaged(internal_paging, self._deserialize.dependencies) - + header_dict = None if raw: header_dict = {} - client_raw_response = models.NotificationContractPaged(internal_paging, self._deserialize.dependencies, header_dict) - return client_raw_response + deserialized = models.NotificationContractPaged(internal_paging, self._deserialize.dependencies, header_dict) return deserialized list_by_service.metadata = {'url': '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ApiManagement/service/{serviceName}/notifications'} @@ -172,7 +176,6 @@ def get( raise models.ErrorResponseException(self._deserialize, response) deserialized = None - if response.status_code == 200: deserialized = self._deserialize('NotificationContract', response) @@ -247,7 +250,6 @@ def create_or_update( raise models.ErrorResponseException(self._deserialize, response) deserialized = None - if response.status_code == 200: deserialized = self._deserialize('NotificationContract', response) diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/notification_recipient_email_operations.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/_notification_recipient_email_operations.py similarity index 98% rename from sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/notification_recipient_email_operations.py rename to sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/_notification_recipient_email_operations.py index ce26d8d03aab..8ae275c75b03 100644 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/notification_recipient_email_operations.py +++ b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/_notification_recipient_email_operations.py @@ -18,11 +18,13 @@ class NotificationRecipientEmailOperations(object): """NotificationRecipientEmailOperations operations. + You should not instantiate directly this class, but create a Client instance that will create it for you and attach it as attribute. + :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: "2019-01-01". + :ivar api_version: Version of the API to be used with the client request. Constant value: "2019-12-01-preview". """ models = models @@ -32,7 +34,7 @@ def __init__(self, client, config, serializer, deserializer): self._client = client self._serialize = serializer self._deserialize = deserializer - self.api_version = "2019-01-01" + self.api_version = "2019-12-01-preview" self.config = config @@ -96,7 +98,6 @@ def list_by_notification( raise models.ErrorResponseException(self._deserialize, response) deserialized = None - if response.status_code == 200: deserialized = self._deserialize('RecipientEmailCollection', response) @@ -236,7 +237,6 @@ def create_or_update( raise models.ErrorResponseException(self._deserialize, response) deserialized = None - if response.status_code == 200: deserialized = self._deserialize('RecipientEmailContract', response) if response.status_code == 201: diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/notification_recipient_user_operations.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/_notification_recipient_user_operations.py similarity index 97% rename from sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/notification_recipient_user_operations.py rename to sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/_notification_recipient_user_operations.py index 7041ad6440a4..ae1311eb7cd4 100644 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/notification_recipient_user_operations.py +++ b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/_notification_recipient_user_operations.py @@ -18,11 +18,13 @@ class NotificationRecipientUserOperations(object): """NotificationRecipientUserOperations operations. + You should not instantiate directly this class, but create a Client instance that will create it for you and attach it as attribute. + :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: "2019-01-01". + :ivar api_version: Version of the API to be used with the client request. Constant value: "2019-12-01-preview". """ models = models @@ -32,7 +34,7 @@ def __init__(self, client, config, serializer, deserializer): self._client = client self._serialize = serializer self._deserialize = deserializer - self.api_version = "2019-01-01" + self.api_version = "2019-12-01-preview" self.config = config @@ -96,7 +98,6 @@ def list_by_notification( raise models.ErrorResponseException(self._deserialize, response) deserialized = None - if response.status_code == 200: deserialized = self._deserialize('RecipientUserCollection', response) @@ -143,7 +144,7 @@ def check_entity_exists( '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])?$'), 'notificationName': self._serialize.url("notification_name", notification_name, 'str'), - 'userId': self._serialize.url("user_id", user_id, 'str', max_length=80, min_length=1, pattern=r'^[^*#&+:<>?]+$'), + 'userId': self._serialize.url("user_id", user_id, 'str', max_length=80, min_length=1), 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str') } url = self._client.format_url(url, **path_format_arguments) @@ -212,7 +213,7 @@ def create_or_update( '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])?$'), 'notificationName': self._serialize.url("notification_name", notification_name, 'str'), - 'userId': self._serialize.url("user_id", user_id, 'str', max_length=80, min_length=1, pattern=r'^[^*#&+:<>?]+$'), + 'userId': self._serialize.url("user_id", user_id, 'str', max_length=80, min_length=1), 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str') } url = self._client.format_url(url, **path_format_arguments) @@ -239,7 +240,6 @@ def create_or_update( raise models.ErrorResponseException(self._deserialize, response) deserialized = None - if response.status_code == 200: deserialized = self._deserialize('RecipientUserContract', response) if response.status_code == 201: @@ -287,7 +287,7 @@ def delete( '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])?$'), 'notificationName': self._serialize.url("notification_name", notification_name, 'str'), - 'userId': self._serialize.url("user_id", user_id, 'str', max_length=80, min_length=1, pattern=r'^[^*#&+:<>?]+$'), + 'userId': self._serialize.url("user_id", user_id, 'str', max_length=80, min_length=1), 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str') } url = self._client.format_url(url, **path_format_arguments) diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/open_id_connect_provider_operations.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/_open_id_connect_provider_operations.py similarity index 85% rename from sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/open_id_connect_provider_operations.py rename to sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/_open_id_connect_provider_operations.py index 1987a36bceed..be3790aee648 100644 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/open_id_connect_provider_operations.py +++ b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/_open_id_connect_provider_operations.py @@ -18,11 +18,13 @@ class OpenIdConnectProviderOperations(object): """OpenIdConnectProviderOperations operations. + You should not instantiate directly this class, but create a Client instance that will create it for you and attach it as attribute. + :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: "2019-01-01". + :ivar api_version: Version of the API to be used with the client request. Constant value: "2019-12-01-preview". """ models = models @@ -32,7 +34,7 @@ def __init__(self, client, config, serializer, deserializer): self._client = client self._serialize = serializer self._deserialize = deserializer - self.api_version = "2019-01-01" + self.api_version = "2019-12-01-preview" self.config = config @@ -66,8 +68,7 @@ def list_by_service( :raises: :class:`ErrorResponseException` """ - def internal_paging(next_link=None, raw=False): - + def prepare_request(next_link=None): if not next_link: # Construct URL url = self.list_by_service.metadata['url'] @@ -104,6 +105,11 @@ def internal_paging(next_link=None, raw=False): # Construct and send request request = self._client.get(url, query_parameters, header_parameters) + return request + + def internal_paging(next_link=None): + request = prepare_request(next_link) + response = self._client.send(request, stream=False, **operation_config) if response.status_code not in [200]: @@ -112,12 +118,10 @@ def internal_paging(next_link=None, raw=False): return response # Deserialize response - deserialized = models.OpenidConnectProviderContractPaged(internal_paging, self._deserialize.dependencies) - + header_dict = None if raw: header_dict = {} - client_raw_response = models.OpenidConnectProviderContractPaged(internal_paging, self._deserialize.dependencies, header_dict) - return client_raw_response + deserialized = models.OpenidConnectProviderContractPaged(internal_paging, self._deserialize.dependencies, header_dict) return deserialized list_by_service.metadata = {'url': '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ApiManagement/service/{serviceName}/openidConnectProviders'} @@ -234,9 +238,8 @@ def get( if response.status_code not in [200]: raise models.ErrorResponseException(self._deserialize, response) - deserialized = None header_dict = {} - + deserialized = None if response.status_code == 200: deserialized = self._deserialize('OpenidConnectProviderContract', response) header_dict = { @@ -263,7 +266,7 @@ def create_or_update( :type opid: str :param parameters: Create parameters. :type parameters: - ~azure.mgmt.apimanagement.models.OpenidConnectProviderContract + ~azure.mgmt.apimanagement.models.OpenidConnectProviderCreateContract :param if_match: ETag of the Entity. Not required when creating an entity, but required when updating an entity. :type if_match: str @@ -307,7 +310,7 @@ def create_or_update( header_parameters['accept-language'] = self._serialize.header("self.config.accept_language", self.config.accept_language, 'str') # Construct body - body_content = self._serialize.body(parameters, 'OpenidConnectProviderContract') + body_content = self._serialize.body(parameters, 'OpenidConnectProviderCreateContract') # Construct and send request request = self._client.put(url, query_parameters, header_parameters, body_content) @@ -316,9 +319,8 @@ def create_or_update( if response.status_code not in [200, 201]: raise models.ErrorResponseException(self._deserialize, response) - deserialized = None header_dict = {} - + deserialized = None if response.status_code == 200: deserialized = self._deserialize('OpenidConnectProviderContract', response) header_dict = { @@ -465,3 +467,66 @@ def delete( client_raw_response = ClientRawResponse(None, response) return client_raw_response delete.metadata = {'url': '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ApiManagement/service/{serviceName}/openidConnectProviders/{opid}'} + + def list_secrets( + self, resource_group_name, service_name, opid, custom_headers=None, raw=False, **operation_config): + """Gets the client secret details of the OpenID Connect Provider. + + :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 opid: Identifier of the OpenID Connect Provider. + :type opid: 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: ClientSecretContract or ClientRawResponse if raw=true + :rtype: ~azure.mgmt.apimanagement.models.ClientSecretContract or + ~msrest.pipeline.ClientRawResponse + :raises: + :class:`ErrorResponseException` + """ + # Construct URL + url = self.list_secrets.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])?$'), + 'opid': self._serialize.url("opid", opid, 'str', max_length=256, pattern=r'^[^*#&+:<>?]+$'), + '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.post(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) + + deserialized = None + if response.status_code == 200: + deserialized = self._deserialize('ClientSecretContract', response) + + if raw: + client_raw_response = ClientRawResponse(deserialized, response) + return client_raw_response + + return deserialized + list_secrets.metadata = {'url': '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ApiManagement/service/{serviceName}/openidConnectProviders/{opid}/listSecrets'} diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/operation_operations.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/_operation_operations.py similarity index 93% rename from sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/operation_operations.py rename to sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/_operation_operations.py index d3289232f1e2..c42b49a7bb6e 100644 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/operation_operations.py +++ b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/_operation_operations.py @@ -19,11 +19,13 @@ class OperationOperations(object): """OperationOperations operations. + You should not instantiate directly this class, but create a Client instance that will create it for you and attach it as attribute. + :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: "2019-01-01". + :ivar api_version: Version of the API to be used with the client request. Constant value: "2019-12-01-preview". """ models = models @@ -33,7 +35,7 @@ def __init__(self, client, config, serializer, deserializer): self._client = client self._serialize = serializer self._deserialize = deserializer - self.api_version = "2019-01-01" + self.api_version = "2019-12-01-preview" self.config = config @@ -78,8 +80,7 @@ def list_by_tags( ~azure.mgmt.apimanagement.models.TagResourceContractPaged[~azure.mgmt.apimanagement.models.TagResourceContract] :raises: :class:`CloudError` """ - def internal_paging(next_link=None, raw=False): - + def prepare_request(next_link=None): if not next_link: # Construct URL url = self.list_by_tags.metadata['url'] @@ -119,6 +120,11 @@ def internal_paging(next_link=None, raw=False): # Construct and send request request = self._client.get(url, query_parameters, header_parameters) + return request + + def internal_paging(next_link=None): + request = prepare_request(next_link) + response = self._client.send(request, stream=False, **operation_config) if response.status_code not in [200]: @@ -129,12 +135,10 @@ def internal_paging(next_link=None, raw=False): return response # Deserialize response - deserialized = models.TagResourceContractPaged(internal_paging, self._deserialize.dependencies) - + header_dict = None if raw: header_dict = {} - client_raw_response = models.TagResourceContractPaged(internal_paging, self._deserialize.dependencies, header_dict) - return client_raw_response + deserialized = models.TagResourceContractPaged(internal_paging, self._deserialize.dependencies, header_dict) return deserialized list_by_tags.metadata = {'url': '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ApiManagement/service/{serviceName}/apis/{apiId}/operationsByTags'} diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/policy_snippet_operations.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/_policy_description_operations.py similarity index 85% rename from sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/policy_snippet_operations.py rename to sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/_policy_description_operations.py index 97872fd324fd..11695f642c1c 100644 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/policy_snippet_operations.py +++ b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/_policy_description_operations.py @@ -15,14 +15,16 @@ from .. import models -class PolicySnippetOperations(object): - """PolicySnippetOperations operations. +class PolicyDescriptionOperations(object): + """PolicyDescriptionOperations operations. + + You should not instantiate directly this class, but create a Client instance that will create it for you and attach it as attribute. :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: "2019-01-01". + :ivar api_version: Version of the API to be used with the client request. Constant value: "2019-12-01-preview". """ models = models @@ -32,13 +34,13 @@ def __init__(self, client, config, serializer, deserializer): self._client = client self._serialize = serializer self._deserialize = deserializer - self.api_version = "2019-01-01" + self.api_version = "2019-12-01-preview" self.config = config def list_by_service( self, resource_group_name, service_name, scope=None, custom_headers=None, raw=False, **operation_config): - """Lists all policy snippets. + """Lists all policy descriptions. :param resource_group_name: The name of the resource group. :type resource_group_name: str @@ -53,9 +55,9 @@ def list_by_service( deserialized response :param operation_config: :ref:`Operation configuration overrides`. - :return: PolicySnippetsCollection or ClientRawResponse if raw=true - :rtype: ~azure.mgmt.apimanagement.models.PolicySnippetsCollection or - ~msrest.pipeline.ClientRawResponse + :return: PolicyDescriptionCollection or ClientRawResponse if raw=true + :rtype: ~azure.mgmt.apimanagement.models.PolicyDescriptionCollection + or ~msrest.pipeline.ClientRawResponse :raises: :class:`ErrorResponseException` """ @@ -92,13 +94,12 @@ def list_by_service( raise models.ErrorResponseException(self._deserialize, response) deserialized = None - if response.status_code == 200: - deserialized = self._deserialize('PolicySnippetsCollection', response) + deserialized = self._deserialize('PolicyDescriptionCollection', response) if raw: client_raw_response = ClientRawResponse(deserialized, response) return client_raw_response return deserialized - list_by_service.metadata = {'url': '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ApiManagement/service/{serviceName}/policySnippets'} + list_by_service.metadata = {'url': '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ApiManagement/service/{serviceName}/policyDescriptions'} diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/policy_operations.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/_policy_operations.py similarity index 98% rename from sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/policy_operations.py rename to sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/_policy_operations.py index 8413d78ea04c..fe4bce3c4c37 100644 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/policy_operations.py +++ b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/_policy_operations.py @@ -18,11 +18,13 @@ class PolicyOperations(object): """PolicyOperations operations. + You should not instantiate directly this class, but create a Client instance that will create it for you and attach it as attribute. + :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: "2019-01-01". + :ivar api_version: Version of the API to be used with the client request. Constant value: "2019-12-01-preview". :ivar policy_id: The identifier of the Policy. Constant value: "policy". """ @@ -33,7 +35,7 @@ def __init__(self, client, config, serializer, deserializer): self._client = client self._serialize = serializer self._deserialize = deserializer - self.api_version = "2019-01-01" + self.api_version = "2019-12-01-preview" self.policy_id = "policy" self.config = config @@ -88,7 +90,6 @@ def list_by_service( raise models.ErrorResponseException(self._deserialize, response) deserialized = None - if response.status_code == 200: deserialized = self._deserialize('PolicyCollection', response) @@ -212,9 +213,8 @@ def get( if response.status_code not in [200]: raise models.ErrorResponseException(self._deserialize, response) - deserialized = None header_dict = {} - + deserialized = None if response.status_code == 200: deserialized = self._deserialize('PolicyContract', response) header_dict = { @@ -297,9 +297,8 @@ def create_or_update( if response.status_code not in [200, 201]: raise models.ErrorResponseException(self._deserialize, response) - deserialized = None header_dict = {} - + deserialized = None if response.status_code == 200: deserialized = self._deserialize('PolicyContract', response) header_dict = { diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/product_api_operations.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/_product_api_operations.py similarity index 96% rename from sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/product_api_operations.py rename to sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/_product_api_operations.py index 5263136fbbaf..813059b2dc1f 100644 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/product_api_operations.py +++ b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/_product_api_operations.py @@ -18,11 +18,13 @@ class ProductApiOperations(object): """ProductApiOperations operations. + You should not instantiate directly this class, but create a Client instance that will create it for you and attach it as attribute. + :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: "2019-01-01". + :ivar api_version: Version of the API to be used with the client request. Constant value: "2019-12-01-preview". """ models = models @@ -32,7 +34,7 @@ def __init__(self, client, config, serializer, deserializer): self._client = client self._serialize = serializer self._deserialize = deserializer - self.api_version = "2019-01-01" + self.api_version = "2019-12-01-preview" self.config = config @@ -74,15 +76,14 @@ def list_by_product( :raises: :class:`ErrorResponseException` """ - def internal_paging(next_link=None, raw=False): - + def prepare_request(next_link=None): if not next_link: # Construct URL url = self.list_by_product.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])?$'), - 'productId': self._serialize.url("product_id", product_id, 'str', max_length=256, min_length=1, pattern=r'^[^*#&+:<>?]+$'), + 'productId': self._serialize.url("product_id", product_id, 'str', max_length=256, min_length=1), 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str') } url = self._client.format_url(url, **path_format_arguments) @@ -113,6 +114,11 @@ def internal_paging(next_link=None, raw=False): # Construct and send request request = self._client.get(url, query_parameters, header_parameters) + return request + + def internal_paging(next_link=None): + request = prepare_request(next_link) + response = self._client.send(request, stream=False, **operation_config) if response.status_code not in [200]: @@ -121,12 +127,10 @@ def internal_paging(next_link=None, raw=False): return response # Deserialize response - deserialized = models.ApiContractPaged(internal_paging, self._deserialize.dependencies) - + header_dict = None if raw: header_dict = {} - client_raw_response = models.ApiContractPaged(internal_paging, self._deserialize.dependencies, header_dict) - return client_raw_response + deserialized = models.ApiContractPaged(internal_paging, self._deserialize.dependencies, header_dict) return deserialized list_by_product.metadata = {'url': '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ApiManagement/service/{serviceName}/products/{productId}/apis'} @@ -162,7 +166,7 @@ def check_entity_exists( 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])?$'), - 'productId': self._serialize.url("product_id", product_id, 'str', max_length=256, min_length=1, pattern=r'^[^*#&+:<>?]+$'), + 'productId': self._serialize.url("product_id", product_id, 'str', max_length=256, min_length=1), 'apiId': self._serialize.url("api_id", api_id, 'str', max_length=256, min_length=1, pattern=r'^[^*#&+:<>?]+$'), 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str') } @@ -224,7 +228,7 @@ def create_or_update( 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])?$'), - 'productId': self._serialize.url("product_id", product_id, 'str', max_length=256, min_length=1, pattern=r'^[^*#&+:<>?]+$'), + 'productId': self._serialize.url("product_id", product_id, 'str', max_length=256, min_length=1), 'apiId': self._serialize.url("api_id", api_id, 'str', max_length=256, min_length=1, pattern=r'^[^*#&+:<>?]+$'), 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str') } @@ -252,7 +256,6 @@ def create_or_update( raise models.ErrorResponseException(self._deserialize, response) deserialized = None - if response.status_code == 200: deserialized = self._deserialize('ApiContract', response) if response.status_code == 201: @@ -295,7 +298,7 @@ def delete( 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])?$'), - 'productId': self._serialize.url("product_id", product_id, 'str', max_length=256, min_length=1, pattern=r'^[^*#&+:<>?]+$'), + 'productId': self._serialize.url("product_id", product_id, 'str', max_length=256, min_length=1), 'apiId': self._serialize.url("api_id", api_id, 'str', max_length=256, min_length=1, pattern=r'^[^*#&+:<>?]+$'), 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str') } diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/product_group_operations.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/_product_group_operations.py similarity index 95% rename from sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/product_group_operations.py rename to sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/_product_group_operations.py index cefd7ce25cdb..ad2c2f2fbf3d 100644 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/product_group_operations.py +++ b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/_product_group_operations.py @@ -18,11 +18,13 @@ class ProductGroupOperations(object): """ProductGroupOperations operations. + You should not instantiate directly this class, but create a Client instance that will create it for you and attach it as attribute. + :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: "2019-01-01". + :ivar api_version: Version of the API to be used with the client request. Constant value: "2019-12-01-preview". """ models = models @@ -32,7 +34,7 @@ def __init__(self, client, config, serializer, deserializer): self._client = client self._serialize = serializer self._deserialize = deserializer - self.api_version = "2019-01-01" + self.api_version = "2019-12-01-preview" self.config = config @@ -70,15 +72,14 @@ def list_by_product( :raises: :class:`ErrorResponseException` """ - def internal_paging(next_link=None, raw=False): - + def prepare_request(next_link=None): if not next_link: # Construct URL url = self.list_by_product.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])?$'), - 'productId': self._serialize.url("product_id", product_id, 'str', max_length=256, min_length=1, pattern=r'^[^*#&+:<>?]+$'), + 'productId': self._serialize.url("product_id", product_id, 'str', max_length=256, min_length=1), 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str') } url = self._client.format_url(url, **path_format_arguments) @@ -109,6 +110,11 @@ def internal_paging(next_link=None, raw=False): # Construct and send request request = self._client.get(url, query_parameters, header_parameters) + return request + + def internal_paging(next_link=None): + request = prepare_request(next_link) + response = self._client.send(request, stream=False, **operation_config) if response.status_code not in [200]: @@ -117,12 +123,10 @@ def internal_paging(next_link=None, raw=False): return response # Deserialize response - deserialized = models.GroupContractPaged(internal_paging, self._deserialize.dependencies) - + header_dict = None if raw: header_dict = {} - client_raw_response = models.GroupContractPaged(internal_paging, self._deserialize.dependencies, header_dict) - return client_raw_response + deserialized = models.GroupContractPaged(internal_paging, self._deserialize.dependencies, header_dict) return deserialized list_by_product.metadata = {'url': '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ApiManagement/service/{serviceName}/products/{productId}/groups'} @@ -157,8 +161,8 @@ def check_entity_exists( 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])?$'), - 'productId': self._serialize.url("product_id", product_id, 'str', max_length=256, min_length=1, pattern=r'^[^*#&+:<>?]+$'), - 'groupId': self._serialize.url("group_id", group_id, 'str', max_length=256, min_length=1, pattern=r'^[^*#&+:<>?]+$'), + 'productId': self._serialize.url("product_id", product_id, 'str', max_length=256, min_length=1), + 'groupId': self._serialize.url("group_id", group_id, 'str', max_length=256, min_length=1), 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str') } url = self._client.format_url(url, **path_format_arguments) @@ -219,8 +223,8 @@ def create_or_update( 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])?$'), - 'productId': self._serialize.url("product_id", product_id, 'str', max_length=256, min_length=1, pattern=r'^[^*#&+:<>?]+$'), - 'groupId': self._serialize.url("group_id", group_id, 'str', max_length=256, min_length=1, pattern=r'^[^*#&+:<>?]+$'), + 'productId': self._serialize.url("product_id", product_id, 'str', max_length=256, min_length=1), + 'groupId': self._serialize.url("group_id", group_id, 'str', max_length=256, min_length=1), 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str') } url = self._client.format_url(url, **path_format_arguments) @@ -247,7 +251,6 @@ def create_or_update( raise models.ErrorResponseException(self._deserialize, response) deserialized = None - if response.status_code == 200: deserialized = self._deserialize('GroupContract', response) if response.status_code == 201: @@ -289,8 +292,8 @@ def delete( 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])?$'), - 'productId': self._serialize.url("product_id", product_id, 'str', max_length=256, min_length=1, pattern=r'^[^*#&+:<>?]+$'), - 'groupId': self._serialize.url("group_id", group_id, 'str', max_length=256, min_length=1, pattern=r'^[^*#&+:<>?]+$'), + 'productId': self._serialize.url("product_id", product_id, 'str', max_length=256, min_length=1), + 'groupId': self._serialize.url("group_id", group_id, 'str', max_length=256, min_length=1), 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str') } url = self._client.format_url(url, **path_format_arguments) diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/product_operations.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/_product_operations.py similarity index 96% rename from sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/product_operations.py rename to sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/_product_operations.py index ab5a195f764f..517f8dbee77e 100644 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/product_operations.py +++ b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/_product_operations.py @@ -18,11 +18,13 @@ class ProductOperations(object): """ProductOperations operations. + You should not instantiate directly this class, but create a Client instance that will create it for you and attach it as attribute. + :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: "2019-01-01". + :ivar api_version: Version of the API to be used with the client request. Constant value: "2019-12-01-preview". """ models = models @@ -32,7 +34,7 @@ def __init__(self, client, config, serializer, deserializer): self._client = client self._serialize = serializer self._deserialize = deserializer - self.api_version = "2019-01-01" + self.api_version = "2019-12-01-preview" self.config = config @@ -75,8 +77,7 @@ def list_by_service( :raises: :class:`ErrorResponseException` """ - def internal_paging(next_link=None, raw=False): - + def prepare_request(next_link=None): if not next_link: # Construct URL url = self.list_by_service.metadata['url'] @@ -117,6 +118,11 @@ def internal_paging(next_link=None, raw=False): # Construct and send request request = self._client.get(url, query_parameters, header_parameters) + return request + + def internal_paging(next_link=None): + request = prepare_request(next_link) + response = self._client.send(request, stream=False, **operation_config) if response.status_code not in [200]: @@ -125,12 +131,10 @@ def internal_paging(next_link=None, raw=False): return response # Deserialize response - deserialized = models.ProductContractPaged(internal_paging, self._deserialize.dependencies) - + header_dict = None if raw: header_dict = {} - client_raw_response = models.ProductContractPaged(internal_paging, self._deserialize.dependencies, header_dict) - return client_raw_response + deserialized = models.ProductContractPaged(internal_paging, self._deserialize.dependencies, header_dict) return deserialized list_by_service.metadata = {'url': '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ApiManagement/service/{serviceName}/products'} @@ -162,7 +166,7 @@ def get_entity_tag( 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])?$'), - 'productId': self._serialize.url("product_id", product_id, 'str', max_length=256, min_length=1, pattern=r'^[^*#&+:<>?]+$'), + 'productId': self._serialize.url("product_id", product_id, 'str', max_length=256, min_length=1), 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str') } url = self._client.format_url(url, **path_format_arguments) @@ -222,7 +226,7 @@ def get( 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])?$'), - 'productId': self._serialize.url("product_id", product_id, 'str', max_length=256, min_length=1, pattern=r'^[^*#&+:<>?]+$'), + 'productId': self._serialize.url("product_id", product_id, 'str', max_length=256, min_length=1), 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str') } url = self._client.format_url(url, **path_format_arguments) @@ -248,9 +252,8 @@ def get( if response.status_code not in [200]: raise models.ErrorResponseException(self._deserialize, response) - deserialized = None header_dict = {} - + deserialized = None if response.status_code == 200: deserialized = self._deserialize('ProductContract', response) header_dict = { @@ -297,7 +300,7 @@ def create_or_update( 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])?$'), - 'productId': self._serialize.url("product_id", product_id, 'str', max_length=256, min_length=1, pattern=r'^[^*#&+:<>?]+$'), + 'productId': self._serialize.url("product_id", product_id, 'str', max_length=256, min_length=1), 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str') } url = self._client.format_url(url, **path_format_arguments) @@ -329,9 +332,8 @@ def create_or_update( if response.status_code not in [200, 201]: raise models.ErrorResponseException(self._deserialize, response) - deserialized = None header_dict = {} - + deserialized = None if response.status_code == 200: deserialized = self._deserialize('ProductContract', response) header_dict = { @@ -384,7 +386,7 @@ def update( 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])?$'), - 'productId': self._serialize.url("product_id", product_id, 'str', max_length=256, min_length=1, pattern=r'^[^*#&+:<>?]+$'), + 'productId': self._serialize.url("product_id", product_id, 'str', max_length=256, min_length=1), 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str') } url = self._client.format_url(url, **path_format_arguments) @@ -452,7 +454,7 @@ def delete( 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])?$'), - 'productId': self._serialize.url("product_id", product_id, 'str', max_length=256, min_length=1, pattern=r'^[^*#&+:<>?]+$'), + 'productId': self._serialize.url("product_id", product_id, 'str', max_length=256, min_length=1), 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str') } url = self._client.format_url(url, **path_format_arguments) @@ -521,8 +523,7 @@ def list_by_tags( :raises: :class:`ErrorResponseException` """ - def internal_paging(next_link=None, raw=False): - + def prepare_request(next_link=None): if not next_link: # Construct URL url = self.list_by_tags.metadata['url'] @@ -561,6 +562,11 @@ def internal_paging(next_link=None, raw=False): # Construct and send request request = self._client.get(url, query_parameters, header_parameters) + return request + + def internal_paging(next_link=None): + request = prepare_request(next_link) + response = self._client.send(request, stream=False, **operation_config) if response.status_code not in [200]: @@ -569,12 +575,10 @@ def internal_paging(next_link=None, raw=False): return response # Deserialize response - deserialized = models.TagResourceContractPaged(internal_paging, self._deserialize.dependencies) - + header_dict = None if raw: header_dict = {} - client_raw_response = models.TagResourceContractPaged(internal_paging, self._deserialize.dependencies, header_dict) - return client_raw_response + deserialized = models.TagResourceContractPaged(internal_paging, self._deserialize.dependencies, header_dict) return deserialized list_by_tags.metadata = {'url': '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ApiManagement/service/{serviceName}/productsByTags'} diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/product_policy_operations.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/_product_policy_operations.py similarity index 97% rename from sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/product_policy_operations.py rename to sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/_product_policy_operations.py index 88efe0a55ee4..141f4d5a6ff2 100644 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/product_policy_operations.py +++ b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/_product_policy_operations.py @@ -18,11 +18,13 @@ class ProductPolicyOperations(object): """ProductPolicyOperations operations. + You should not instantiate directly this class, but create a Client instance that will create it for you and attach it as attribute. + :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: "2019-01-01". + :ivar api_version: Version of the API to be used with the client request. Constant value: "2019-12-01-preview". :ivar policy_id: The identifier of the Policy. Constant value: "policy". """ @@ -33,7 +35,7 @@ def __init__(self, client, config, serializer, deserializer): self._client = client self._serialize = serializer self._deserialize = deserializer - self.api_version = "2019-01-01" + self.api_version = "2019-12-01-preview" self.policy_id = "policy" self.config = config @@ -65,7 +67,7 @@ def list_by_product( 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])?$'), - 'productId': self._serialize.url("product_id", product_id, 'str', max_length=256, min_length=1, pattern=r'^[^*#&+:<>?]+$'), + 'productId': self._serialize.url("product_id", product_id, 'str', max_length=256, min_length=1), 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str') } url = self._client.format_url(url, **path_format_arguments) @@ -92,7 +94,6 @@ def list_by_product( raise models.ErrorResponseException(self._deserialize, response) deserialized = None - if response.status_code == 200: deserialized = self._deserialize('PolicyCollection', response) @@ -129,7 +130,7 @@ def get_entity_tag( 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])?$'), - 'productId': self._serialize.url("product_id", product_id, 'str', max_length=256, min_length=1, pattern=r'^[^*#&+:<>?]+$'), + 'productId': self._serialize.url("product_id", product_id, 'str', max_length=256, min_length=1), 'policyId': self._serialize.url("self.policy_id", self.policy_id, 'str'), 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str') } @@ -194,7 +195,7 @@ def get( 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])?$'), - 'productId': self._serialize.url("product_id", product_id, 'str', max_length=256, min_length=1, pattern=r'^[^*#&+:<>?]+$'), + 'productId': self._serialize.url("product_id", product_id, 'str', max_length=256, min_length=1), 'policyId': self._serialize.url("self.policy_id", self.policy_id, 'str'), 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str') } @@ -223,9 +224,8 @@ def get( if response.status_code not in [200]: raise models.ErrorResponseException(self._deserialize, response) - deserialized = None header_dict = {} - + deserialized = None if response.status_code == 200: deserialized = self._deserialize('PolicyContract', response) header_dict = { @@ -278,7 +278,7 @@ def create_or_update( 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])?$'), - 'productId': self._serialize.url("product_id", product_id, 'str', max_length=256, min_length=1, pattern=r'^[^*#&+:<>?]+$'), + 'productId': self._serialize.url("product_id", product_id, 'str', max_length=256, min_length=1), 'policyId': self._serialize.url("self.policy_id", self.policy_id, 'str'), 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str') } @@ -311,9 +311,8 @@ def create_or_update( if response.status_code not in [200, 201]: raise models.ErrorResponseException(self._deserialize, response) - deserialized = None header_dict = {} - + deserialized = None if response.status_code == 200: deserialized = self._deserialize('PolicyContract', response) header_dict = { @@ -363,7 +362,7 @@ def delete( 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])?$'), - 'productId': self._serialize.url("product_id", product_id, 'str', max_length=256, min_length=1, pattern=r'^[^*#&+:<>?]+$'), + 'productId': self._serialize.url("product_id", product_id, 'str', max_length=256, min_length=1), 'policyId': self._serialize.url("self.policy_id", self.policy_id, 'str'), 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str') } diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/product_subscriptions_operations.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/_product_subscriptions_operations.py similarity index 92% rename from sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/product_subscriptions_operations.py rename to sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/_product_subscriptions_operations.py index fee36bbc7942..f0e3d56b167e 100644 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/product_subscriptions_operations.py +++ b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/_product_subscriptions_operations.py @@ -18,11 +18,13 @@ class ProductSubscriptionsOperations(object): """ProductSubscriptionsOperations operations. + You should not instantiate directly this class, but create a Client instance that will create it for you and attach it as attribute. + :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: "2019-01-01". + :ivar api_version: Version of the API to be used with the client request. Constant value: "2019-12-01-preview". """ models = models @@ -32,7 +34,7 @@ def __init__(self, client, config, serializer, deserializer): self._client = client self._serialize = serializer self._deserialize = deserializer - self.api_version = "2019-01-01" + self.api_version = "2019-12-01-preview" self.config = config @@ -78,15 +80,14 @@ def list( :raises: :class:`ErrorResponseException` """ - def internal_paging(next_link=None, raw=False): - + def prepare_request(next_link=None): if not next_link: # Construct URL url = self.list.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])?$'), - 'productId': self._serialize.url("product_id", product_id, 'str', max_length=256, min_length=1, pattern=r'^[^*#&+:<>?]+$'), + 'productId': self._serialize.url("product_id", product_id, 'str', max_length=256, min_length=1), 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str') } url = self._client.format_url(url, **path_format_arguments) @@ -117,6 +118,11 @@ def internal_paging(next_link=None, raw=False): # Construct and send request request = self._client.get(url, query_parameters, header_parameters) + return request + + def internal_paging(next_link=None): + request = prepare_request(next_link) + response = self._client.send(request, stream=False, **operation_config) if response.status_code not in [200]: @@ -125,12 +131,10 @@ def internal_paging(next_link=None, raw=False): return response # Deserialize response - deserialized = models.SubscriptionContractPaged(internal_paging, self._deserialize.dependencies) - + header_dict = None if raw: header_dict = {} - client_raw_response = models.SubscriptionContractPaged(internal_paging, self._deserialize.dependencies, header_dict) - return client_raw_response + deserialized = models.SubscriptionContractPaged(internal_paging, self._deserialize.dependencies, header_dict) return deserialized list.metadata = {'url': '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ApiManagement/service/{serviceName}/products/{productId}/subscriptions'} diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/quota_by_counter_keys_operations.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/_quota_by_counter_keys_operations.py similarity index 97% rename from sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/quota_by_counter_keys_operations.py rename to sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/_quota_by_counter_keys_operations.py index 6c6da85b6b02..a0ad5acf819e 100644 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/quota_by_counter_keys_operations.py +++ b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/_quota_by_counter_keys_operations.py @@ -18,11 +18,13 @@ class QuotaByCounterKeysOperations(object): """QuotaByCounterKeysOperations operations. + You should not instantiate directly this class, but create a Client instance that will create it for you and attach it as attribute. + :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: "2019-01-01". + :ivar api_version: Version of the API to be used with the client request. Constant value: "2019-12-01-preview". """ models = models @@ -32,7 +34,7 @@ def __init__(self, client, config, serializer, deserializer): self._client = client self._serialize = serializer self._deserialize = deserializer - self.api_version = "2019-01-01" + self.api_version = "2019-12-01-preview" self.config = config @@ -96,7 +98,6 @@ def list_by_service( raise models.ErrorResponseException(self._deserialize, response) deserialized = None - if response.status_code == 200: deserialized = self._deserialize('QuotaCounterCollection', response) diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/quota_by_period_keys_operations.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/_quota_by_period_keys_operations.py similarity index 97% rename from sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/quota_by_period_keys_operations.py rename to sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/_quota_by_period_keys_operations.py index ac05c971c9ae..acd6d05fab92 100644 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/quota_by_period_keys_operations.py +++ b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/_quota_by_period_keys_operations.py @@ -18,11 +18,13 @@ class QuotaByPeriodKeysOperations(object): """QuotaByPeriodKeysOperations operations. + You should not instantiate directly this class, but create a Client instance that will create it for you and attach it as attribute. + :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: "2019-01-01". + :ivar api_version: Version of the API to be used with the client request. Constant value: "2019-12-01-preview". """ models = models @@ -32,7 +34,7 @@ def __init__(self, client, config, serializer, deserializer): self._client = client self._serialize = serializer self._deserialize = deserializer - self.api_version = "2019-01-01" + self.api_version = "2019-12-01-preview" self.config = config @@ -98,7 +100,6 @@ def get( raise models.ErrorResponseException(self._deserialize, response) deserialized = None - if response.status_code == 200: deserialized = self._deserialize('QuotaCounterContract', response) diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/region_operations.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/_region_operations.py similarity index 90% rename from sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/region_operations.py rename to sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/_region_operations.py index c57466505a4a..4633be66d32d 100644 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/region_operations.py +++ b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/_region_operations.py @@ -18,11 +18,13 @@ class RegionOperations(object): """RegionOperations operations. + You should not instantiate directly this class, but create a Client instance that will create it for you and attach it as attribute. + :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: "2019-01-01". + :ivar api_version: Version of the API to be used with the client request. Constant value: "2019-12-01-preview". """ models = models @@ -32,7 +34,7 @@ def __init__(self, client, config, serializer, deserializer): self._client = client self._serialize = serializer self._deserialize = deserializer - self.api_version = "2019-01-01" + self.api_version = "2019-12-01-preview" self.config = config @@ -55,8 +57,7 @@ def list_by_service( :raises: :class:`ErrorResponseException` """ - def internal_paging(next_link=None, raw=False): - + def prepare_request(next_link=None): if not next_link: # Construct URL url = self.list_by_service.metadata['url'] @@ -87,6 +88,11 @@ def internal_paging(next_link=None, raw=False): # Construct and send request request = self._client.get(url, query_parameters, header_parameters) + return request + + def internal_paging(next_link=None): + request = prepare_request(next_link) + response = self._client.send(request, stream=False, **operation_config) if response.status_code not in [200]: @@ -95,12 +101,10 @@ def internal_paging(next_link=None, raw=False): return response # Deserialize response - deserialized = models.RegionContractPaged(internal_paging, self._deserialize.dependencies) - + header_dict = None if raw: header_dict = {} - client_raw_response = models.RegionContractPaged(internal_paging, self._deserialize.dependencies, header_dict) - return client_raw_response + deserialized = models.RegionContractPaged(internal_paging, self._deserialize.dependencies, header_dict) return deserialized list_by_service.metadata = {'url': '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ApiManagement/service/{serviceName}/regions'} diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/reports_operations.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/_reports_operations.py similarity index 94% rename from sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/reports_operations.py rename to sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/_reports_operations.py index 1e238b46aa3f..77171f68f587 100644 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/reports_operations.py +++ b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/_reports_operations.py @@ -19,11 +19,13 @@ class ReportsOperations(object): """ReportsOperations operations. + You should not instantiate directly this class, but create a Client instance that will create it for you and attach it as attribute. + :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: "2019-01-01". + :ivar api_version: Version of the API to be used with the client request. Constant value: "2019-12-01-preview". """ models = models @@ -33,7 +35,7 @@ def __init__(self, client, config, serializer, deserializer): self._client = client self._serialize = serializer self._deserialize = deserializer - self.api_version = "2019-01-01" + self.api_version = "2019-12-01-preview" self.config = config @@ -63,8 +65,7 @@ def list_by_api( ~azure.mgmt.apimanagement.models.ReportRecordContractPaged[~azure.mgmt.apimanagement.models.ReportRecordContract] :raises: :class:`CloudError` """ - def internal_paging(next_link=None, raw=False): - + def prepare_request(next_link=None): if not next_link: # Construct URL url = self.list_by_api.metadata['url'] @@ -102,6 +103,11 @@ def internal_paging(next_link=None, raw=False): # Construct and send request request = self._client.get(url, query_parameters, header_parameters) + return request + + def internal_paging(next_link=None): + request = prepare_request(next_link) + response = self._client.send(request, stream=False, **operation_config) if response.status_code not in [200]: @@ -112,12 +118,10 @@ def internal_paging(next_link=None, raw=False): return response # Deserialize response - deserialized = models.ReportRecordContractPaged(internal_paging, self._deserialize.dependencies) - + header_dict = None if raw: header_dict = {} - client_raw_response = models.ReportRecordContractPaged(internal_paging, self._deserialize.dependencies, header_dict) - return client_raw_response + deserialized = models.ReportRecordContractPaged(internal_paging, self._deserialize.dependencies, header_dict) return deserialized list_by_api.metadata = {'url': '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ApiManagement/service/{serviceName}/reports/byApi'} @@ -166,8 +170,7 @@ def list_by_user( ~azure.mgmt.apimanagement.models.ReportRecordContractPaged[~azure.mgmt.apimanagement.models.ReportRecordContract] :raises: :class:`CloudError` """ - def internal_paging(next_link=None, raw=False): - + def prepare_request(next_link=None): if not next_link: # Construct URL url = self.list_by_user.metadata['url'] @@ -205,6 +208,11 @@ def internal_paging(next_link=None, raw=False): # Construct and send request request = self._client.get(url, query_parameters, header_parameters) + return request + + def internal_paging(next_link=None): + request = prepare_request(next_link) + response = self._client.send(request, stream=False, **operation_config) if response.status_code not in [200]: @@ -215,12 +223,10 @@ def internal_paging(next_link=None, raw=False): return response # Deserialize response - deserialized = models.ReportRecordContractPaged(internal_paging, self._deserialize.dependencies) - + header_dict = None if raw: header_dict = {} - client_raw_response = models.ReportRecordContractPaged(internal_paging, self._deserialize.dependencies, header_dict) - return client_raw_response + deserialized = models.ReportRecordContractPaged(internal_paging, self._deserialize.dependencies, header_dict) return deserialized list_by_user.metadata = {'url': '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ApiManagement/service/{serviceName}/reports/byUser'} @@ -269,8 +275,7 @@ def list_by_operation( ~azure.mgmt.apimanagement.models.ReportRecordContractPaged[~azure.mgmt.apimanagement.models.ReportRecordContract] :raises: :class:`CloudError` """ - def internal_paging(next_link=None, raw=False): - + def prepare_request(next_link=None): if not next_link: # Construct URL url = self.list_by_operation.metadata['url'] @@ -308,6 +313,11 @@ def internal_paging(next_link=None, raw=False): # Construct and send request request = self._client.get(url, query_parameters, header_parameters) + return request + + def internal_paging(next_link=None): + request = prepare_request(next_link) + response = self._client.send(request, stream=False, **operation_config) if response.status_code not in [200]: @@ -318,12 +328,10 @@ def internal_paging(next_link=None, raw=False): return response # Deserialize response - deserialized = models.ReportRecordContractPaged(internal_paging, self._deserialize.dependencies) - + header_dict = None if raw: header_dict = {} - client_raw_response = models.ReportRecordContractPaged(internal_paging, self._deserialize.dependencies, header_dict) - return client_raw_response + deserialized = models.ReportRecordContractPaged(internal_paging, self._deserialize.dependencies, header_dict) return deserialized list_by_operation.metadata = {'url': '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ApiManagement/service/{serviceName}/reports/byOperation'} @@ -370,8 +378,7 @@ def list_by_product( ~azure.mgmt.apimanagement.models.ReportRecordContractPaged[~azure.mgmt.apimanagement.models.ReportRecordContract] :raises: :class:`CloudError` """ - def internal_paging(next_link=None, raw=False): - + def prepare_request(next_link=None): if not next_link: # Construct URL url = self.list_by_product.metadata['url'] @@ -409,6 +416,11 @@ def internal_paging(next_link=None, raw=False): # Construct and send request request = self._client.get(url, query_parameters, header_parameters) + return request + + def internal_paging(next_link=None): + request = prepare_request(next_link) + response = self._client.send(request, stream=False, **operation_config) if response.status_code not in [200]: @@ -419,12 +431,10 @@ def internal_paging(next_link=None, raw=False): return response # Deserialize response - deserialized = models.ReportRecordContractPaged(internal_paging, self._deserialize.dependencies) - + header_dict = None if raw: header_dict = {} - client_raw_response = models.ReportRecordContractPaged(internal_paging, self._deserialize.dependencies, header_dict) - return client_raw_response + deserialized = models.ReportRecordContractPaged(internal_paging, self._deserialize.dependencies, header_dict) return deserialized list_by_product.metadata = {'url': '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ApiManagement/service/{serviceName}/reports/byProduct'} @@ -469,8 +479,7 @@ def list_by_geo( ~azure.mgmt.apimanagement.models.ReportRecordContractPaged[~azure.mgmt.apimanagement.models.ReportRecordContract] :raises: :class:`CloudError` """ - def internal_paging(next_link=None, raw=False): - + def prepare_request(next_link=None): if not next_link: # Construct URL url = self.list_by_geo.metadata['url'] @@ -506,6 +515,11 @@ def internal_paging(next_link=None, raw=False): # Construct and send request request = self._client.get(url, query_parameters, header_parameters) + return request + + def internal_paging(next_link=None): + request = prepare_request(next_link) + response = self._client.send(request, stream=False, **operation_config) if response.status_code not in [200]: @@ -516,12 +530,10 @@ def internal_paging(next_link=None, raw=False): return response # Deserialize response - deserialized = models.ReportRecordContractPaged(internal_paging, self._deserialize.dependencies) - + header_dict = None if raw: header_dict = {} - client_raw_response = models.ReportRecordContractPaged(internal_paging, self._deserialize.dependencies, header_dict) - return client_raw_response + deserialized = models.ReportRecordContractPaged(internal_paging, self._deserialize.dependencies, header_dict) return deserialized list_by_geo.metadata = {'url': '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ApiManagement/service/{serviceName}/reports/byGeo'} @@ -569,8 +581,7 @@ def list_by_subscription( ~azure.mgmt.apimanagement.models.ReportRecordContractPaged[~azure.mgmt.apimanagement.models.ReportRecordContract] :raises: :class:`CloudError` """ - def internal_paging(next_link=None, raw=False): - + def prepare_request(next_link=None): if not next_link: # Construct URL url = self.list_by_subscription.metadata['url'] @@ -608,6 +619,11 @@ def internal_paging(next_link=None, raw=False): # Construct and send request request = self._client.get(url, query_parameters, header_parameters) + return request + + def internal_paging(next_link=None): + request = prepare_request(next_link) + response = self._client.send(request, stream=False, **operation_config) if response.status_code not in [200]: @@ -618,12 +634,10 @@ def internal_paging(next_link=None, raw=False): return response # Deserialize response - deserialized = models.ReportRecordContractPaged(internal_paging, self._deserialize.dependencies) - + header_dict = None if raw: header_dict = {} - client_raw_response = models.ReportRecordContractPaged(internal_paging, self._deserialize.dependencies, header_dict) - return client_raw_response + deserialized = models.ReportRecordContractPaged(internal_paging, self._deserialize.dependencies, header_dict) return deserialized list_by_subscription.metadata = {'url': '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ApiManagement/service/{serviceName}/reports/bySubscription'} @@ -676,8 +690,7 @@ def list_by_time( ~azure.mgmt.apimanagement.models.ReportRecordContractPaged[~azure.mgmt.apimanagement.models.ReportRecordContract] :raises: :class:`CloudError` """ - def internal_paging(next_link=None, raw=False): - + def prepare_request(next_link=None): if not next_link: # Construct URL url = self.list_by_time.metadata['url'] @@ -716,6 +729,11 @@ def internal_paging(next_link=None, raw=False): # Construct and send request request = self._client.get(url, query_parameters, header_parameters) + return request + + def internal_paging(next_link=None): + request = prepare_request(next_link) + response = self._client.send(request, stream=False, **operation_config) if response.status_code not in [200]: @@ -726,12 +744,10 @@ def internal_paging(next_link=None, raw=False): return response # Deserialize response - deserialized = models.ReportRecordContractPaged(internal_paging, self._deserialize.dependencies) - + header_dict = None if raw: header_dict = {} - client_raw_response = models.ReportRecordContractPaged(internal_paging, self._deserialize.dependencies, header_dict) - return client_raw_response + deserialized = models.ReportRecordContractPaged(internal_paging, self._deserialize.dependencies, header_dict) return deserialized list_by_time.metadata = {'url': '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ApiManagement/service/{serviceName}/reports/byTime'} @@ -766,8 +782,7 @@ def list_by_request( ~azure.mgmt.apimanagement.models.RequestReportRecordContractPaged[~azure.mgmt.apimanagement.models.RequestReportRecordContract] :raises: :class:`CloudError` """ - def internal_paging(next_link=None, raw=False): - + def prepare_request(next_link=None): if not next_link: # Construct URL url = self.list_by_request.metadata['url'] @@ -803,6 +818,11 @@ def internal_paging(next_link=None, raw=False): # Construct and send request request = self._client.get(url, query_parameters, header_parameters) + return request + + def internal_paging(next_link=None): + request = prepare_request(next_link) + response = self._client.send(request, stream=False, **operation_config) if response.status_code not in [200]: @@ -813,12 +833,10 @@ def internal_paging(next_link=None, raw=False): return response # Deserialize response - deserialized = models.RequestReportRecordContractPaged(internal_paging, self._deserialize.dependencies) - + header_dict = None if raw: header_dict = {} - client_raw_response = models.RequestReportRecordContractPaged(internal_paging, self._deserialize.dependencies, header_dict) - return client_raw_response + deserialized = models.RequestReportRecordContractPaged(internal_paging, self._deserialize.dependencies, header_dict) return deserialized list_by_request.metadata = {'url': '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ApiManagement/service/{serviceName}/reports/byRequest'} diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/sign_in_settings_operations.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/_sign_in_settings_operations.py similarity index 98% rename from sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/sign_in_settings_operations.py rename to sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/_sign_in_settings_operations.py index c93a303527d2..6240978fc209 100644 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/sign_in_settings_operations.py +++ b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/_sign_in_settings_operations.py @@ -18,11 +18,13 @@ class SignInSettingsOperations(object): """SignInSettingsOperations operations. + You should not instantiate directly this class, but create a Client instance that will create it for you and attach it as attribute. + :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: "2019-01-01". + :ivar api_version: Version of the API to be used with the client request. Constant value: "2019-12-01-preview". """ models = models @@ -32,7 +34,7 @@ def __init__(self, client, config, serializer, deserializer): self._client = client self._serialize = serializer self._deserialize = deserializer - self.api_version = "2019-01-01" + self.api_version = "2019-12-01-preview" self.config = config @@ -140,9 +142,8 @@ def get( if response.status_code not in [200]: raise models.ErrorResponseException(self._deserialize, response) - deserialized = None header_dict = {} - + deserialized = None if response.status_code == 200: deserialized = self._deserialize('PortalSigninSettings', response) header_dict = { @@ -285,7 +286,6 @@ def create_or_update( raise models.ErrorResponseException(self._deserialize, response) deserialized = None - if response.status_code == 200: deserialized = self._deserialize('PortalSigninSettings', response) diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/sign_up_settings_operations.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/_sign_up_settings_operations.py similarity index 98% rename from sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/sign_up_settings_operations.py rename to sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/_sign_up_settings_operations.py index b8639ccaff81..2f7c56a5fa86 100644 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/sign_up_settings_operations.py +++ b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/_sign_up_settings_operations.py @@ -18,11 +18,13 @@ class SignUpSettingsOperations(object): """SignUpSettingsOperations operations. + You should not instantiate directly this class, but create a Client instance that will create it for you and attach it as attribute. + :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: "2019-01-01". + :ivar api_version: Version of the API to be used with the client request. Constant value: "2019-12-01-preview". """ models = models @@ -32,7 +34,7 @@ def __init__(self, client, config, serializer, deserializer): self._client = client self._serialize = serializer self._deserialize = deserializer - self.api_version = "2019-01-01" + self.api_version = "2019-12-01-preview" self.config = config @@ -140,9 +142,8 @@ def get( if response.status_code not in [200]: raise models.ErrorResponseException(self._deserialize, response) - deserialized = None header_dict = {} - + deserialized = None if response.status_code == 200: deserialized = self._deserialize('PortalSignupSettings', response) header_dict = { @@ -291,7 +292,6 @@ def create_or_update( raise models.ErrorResponseException(self._deserialize, response) deserialized = None - if response.status_code == 200: deserialized = self._deserialize('PortalSignupSettings', response) diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/subscription_operations.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/_subscription_operations.py similarity index 89% rename from sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/subscription_operations.py rename to sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/_subscription_operations.py index 848dd5ecd901..5ae50ec42958 100644 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/subscription_operations.py +++ b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/_subscription_operations.py @@ -18,11 +18,13 @@ class SubscriptionOperations(object): """SubscriptionOperations operations. + You should not instantiate directly this class, but create a Client instance that will create it for you and attach it as attribute. + :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: "2019-01-01". + :ivar api_version: Version of the API to be used with the client request. Constant value: "2019-12-01-preview". """ models = models @@ -32,7 +34,7 @@ def __init__(self, client, config, serializer, deserializer): self._client = client self._serialize = serializer self._deserialize = deserializer - self.api_version = "2019-01-01" + self.api_version = "2019-12-01-preview" self.config = config @@ -75,8 +77,7 @@ def list( :raises: :class:`ErrorResponseException` """ - def internal_paging(next_link=None, raw=False): - + def prepare_request(next_link=None): if not next_link: # Construct URL url = self.list.metadata['url'] @@ -113,6 +114,11 @@ def internal_paging(next_link=None, raw=False): # Construct and send request request = self._client.get(url, query_parameters, header_parameters) + return request + + def internal_paging(next_link=None): + request = prepare_request(next_link) + response = self._client.send(request, stream=False, **operation_config) if response.status_code not in [200]: @@ -121,12 +127,10 @@ def internal_paging(next_link=None, raw=False): return response # Deserialize response - deserialized = models.SubscriptionContractPaged(internal_paging, self._deserialize.dependencies) - + header_dict = None if raw: header_dict = {} - client_raw_response = models.SubscriptionContractPaged(internal_paging, self._deserialize.dependencies, header_dict) - return client_raw_response + deserialized = models.SubscriptionContractPaged(internal_paging, self._deserialize.dependencies, header_dict) return deserialized list.metadata = {'url': '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ApiManagement/service/{serviceName}/subscriptions'} @@ -244,9 +248,8 @@ def get( if response.status_code not in [200]: raise models.ErrorResponseException(self._deserialize, response) - deserialized = None header_dict = {} - + deserialized = None if response.status_code == 200: deserialized = self._deserialize('SubscriptionContract', response) header_dict = { @@ -334,9 +337,8 @@ def create_or_update( if response.status_code not in [200, 201]: raise models.ErrorResponseException(self._deserialize, response) - deserialized = None header_dict = {} - + deserialized = None if response.status_code == 200: deserialized = self._deserialize('SubscriptionContract', response) header_dict = { @@ -605,3 +607,67 @@ def regenerate_secondary_key( client_raw_response = ClientRawResponse(None, response) return client_raw_response regenerate_secondary_key.metadata = {'url': '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ApiManagement/service/{serviceName}/subscriptions/{sid}/regenerateSecondaryKey'} + + def list_secrets( + self, resource_group_name, service_name, sid, custom_headers=None, raw=False, **operation_config): + """Gets the subscription keys. + + :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 sid: Subscription entity Identifier. The entity represents the + association between a user and a product in API Management. + :type sid: 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: SubscriptionKeysContract or ClientRawResponse if raw=true + :rtype: ~azure.mgmt.apimanagement.models.SubscriptionKeysContract or + ~msrest.pipeline.ClientRawResponse + :raises: + :class:`ErrorResponseException` + """ + # Construct URL + url = self.list_secrets.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])?$'), + 'sid': self._serialize.url("sid", sid, 'str', max_length=256, pattern=r'^[^*#&+:<>?]+$'), + '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.post(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) + + deserialized = None + if response.status_code == 200: + deserialized = self._deserialize('SubscriptionKeysContract', response) + + if raw: + client_raw_response = ClientRawResponse(deserialized, response) + return client_raw_response + + return deserialized + list_secrets.metadata = {'url': '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ApiManagement/service/{serviceName}/subscriptions/{sid}/listSecrets'} diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/tag_operations.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/_tag_operations.py similarity index 97% rename from sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/tag_operations.py rename to sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/_tag_operations.py index 9c314c560929..b2152291051b 100644 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/tag_operations.py +++ b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/_tag_operations.py @@ -18,11 +18,13 @@ class TagOperations(object): """TagOperations operations. + You should not instantiate directly this class, but create a Client instance that will create it for you and attach it as attribute. + :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: "2019-01-01". + :ivar api_version: Version of the API to be used with the client request. Constant value: "2019-12-01-preview". """ models = models @@ -32,7 +34,7 @@ def __init__(self, client, config, serializer, deserializer): self._client = client self._serialize = serializer self._deserialize = deserializer - self.api_version = "2019-01-01" + self.api_version = "2019-12-01-preview" self.config = config @@ -73,8 +75,7 @@ def list_by_operation( :raises: :class:`ErrorResponseException` """ - def internal_paging(next_link=None, raw=False): - + def prepare_request(next_link=None): if not next_link: # Construct URL url = self.list_by_operation.metadata['url'] @@ -82,7 +83,7 @@ def internal_paging(next_link=None, raw=False): '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=256, min_length=1, pattern=r'^[^*#&+:<>?]+$'), - 'operationId': self._serialize.url("operation_id", operation_id, 'str', max_length=80, min_length=1, pattern=r'^[^*#&+:<>?]+$'), + 'operationId': self._serialize.url("operation_id", operation_id, 'str', max_length=80, min_length=1), 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str') } url = self._client.format_url(url, **path_format_arguments) @@ -113,6 +114,11 @@ def internal_paging(next_link=None, raw=False): # Construct and send request request = self._client.get(url, query_parameters, header_parameters) + return request + + def internal_paging(next_link=None): + request = prepare_request(next_link) + response = self._client.send(request, stream=False, **operation_config) if response.status_code not in [200]: @@ -121,12 +127,10 @@ def internal_paging(next_link=None, raw=False): return response # Deserialize response - deserialized = models.TagContractPaged(internal_paging, self._deserialize.dependencies) - + header_dict = None if raw: header_dict = {} - client_raw_response = models.TagContractPaged(internal_paging, self._deserialize.dependencies, header_dict) - return client_raw_response + deserialized = models.TagContractPaged(internal_paging, self._deserialize.dependencies, header_dict) return deserialized list_by_operation.metadata = {'url': '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ApiManagement/service/{serviceName}/apis/{apiId}/operations/{operationId}/tags'} @@ -165,7 +169,7 @@ def get_entity_state_by_operation( '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=256, min_length=1, pattern=r'^[^*#&+:<>?]+$'), - 'operationId': self._serialize.url("operation_id", operation_id, 'str', max_length=80, min_length=1, pattern=r'^[^*#&+:<>?]+$'), + 'operationId': self._serialize.url("operation_id", operation_id, 'str', max_length=80, min_length=1), 'tagId': self._serialize.url("tag_id", tag_id, 'str', max_length=80, min_length=1, pattern=r'^[^*#&+:<>?]+$'), 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str') } @@ -234,7 +238,7 @@ def get_by_operation( '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=256, min_length=1, pattern=r'^[^*#&+:<>?]+$'), - 'operationId': self._serialize.url("operation_id", operation_id, 'str', max_length=80, min_length=1, pattern=r'^[^*#&+:<>?]+$'), + 'operationId': self._serialize.url("operation_id", operation_id, 'str', max_length=80, min_length=1), 'tagId': self._serialize.url("tag_id", tag_id, 'str', max_length=80, min_length=1, pattern=r'^[^*#&+:<>?]+$'), 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str') } @@ -261,9 +265,8 @@ def get_by_operation( if response.status_code not in [200]: raise models.ErrorResponseException(self._deserialize, response) - deserialized = None header_dict = {} - + deserialized = None if response.status_code == 200: deserialized = self._deserialize('TagContract', response) header_dict = { @@ -313,7 +316,7 @@ def assign_to_operation( '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=256, min_length=1, pattern=r'^[^*#&+:<>?]+$'), - 'operationId': self._serialize.url("operation_id", operation_id, 'str', max_length=80, min_length=1, pattern=r'^[^*#&+:<>?]+$'), + 'operationId': self._serialize.url("operation_id", operation_id, 'str', max_length=80, min_length=1), 'tagId': self._serialize.url("tag_id", tag_id, 'str', max_length=80, min_length=1, pattern=r'^[^*#&+:<>?]+$'), 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str') } @@ -341,7 +344,6 @@ def assign_to_operation( raise models.ErrorResponseException(self._deserialize, response) deserialized = None - if response.status_code == 200: deserialized = self._deserialize('TagContract', response) if response.status_code == 201: @@ -388,7 +390,7 @@ def detach_from_operation( '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=256, min_length=1, pattern=r'^[^*#&+:<>?]+$'), - 'operationId': self._serialize.url("operation_id", operation_id, 'str', max_length=80, min_length=1, pattern=r'^[^*#&+:<>?]+$'), + 'operationId': self._serialize.url("operation_id", operation_id, 'str', max_length=80, min_length=1), 'tagId': self._serialize.url("tag_id", tag_id, 'str', max_length=80, min_length=1, pattern=r'^[^*#&+:<>?]+$'), 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str') } @@ -453,8 +455,7 @@ def list_by_api( :raises: :class:`ErrorResponseException` """ - def internal_paging(next_link=None, raw=False): - + def prepare_request(next_link=None): if not next_link: # Construct URL url = self.list_by_api.metadata['url'] @@ -492,6 +493,11 @@ def internal_paging(next_link=None, raw=False): # Construct and send request request = self._client.get(url, query_parameters, header_parameters) + return request + + def internal_paging(next_link=None): + request = prepare_request(next_link) + response = self._client.send(request, stream=False, **operation_config) if response.status_code not in [200]: @@ -500,12 +506,10 @@ def internal_paging(next_link=None, raw=False): return response # Deserialize response - deserialized = models.TagContractPaged(internal_paging, self._deserialize.dependencies) - + header_dict = None if raw: header_dict = {} - client_raw_response = models.TagContractPaged(internal_paging, self._deserialize.dependencies, header_dict) - return client_raw_response + deserialized = models.TagContractPaged(internal_paging, self._deserialize.dependencies, header_dict) return deserialized list_by_api.metadata = {'url': '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ApiManagement/service/{serviceName}/apis/{apiId}/tags'} @@ -632,9 +636,8 @@ def get_by_api( if response.status_code not in [200]: raise models.ErrorResponseException(self._deserialize, response) - deserialized = None header_dict = {} - + deserialized = None if response.status_code == 200: deserialized = self._deserialize('TagContract', response) header_dict = { @@ -707,9 +710,8 @@ def assign_to_api( if response.status_code not in [200, 201]: raise models.ErrorResponseException(self._deserialize, response) - deserialized = None header_dict = {} - + deserialized = None if response.status_code == 200: deserialized = self._deserialize('TagContract', response) header_dict = { @@ -823,15 +825,14 @@ def list_by_product( :raises: :class:`ErrorResponseException` """ - def internal_paging(next_link=None, raw=False): - + def prepare_request(next_link=None): if not next_link: # Construct URL url = self.list_by_product.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])?$'), - 'productId': self._serialize.url("product_id", product_id, 'str', max_length=256, min_length=1, pattern=r'^[^*#&+:<>?]+$'), + 'productId': self._serialize.url("product_id", product_id, 'str', max_length=256, min_length=1), 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str') } url = self._client.format_url(url, **path_format_arguments) @@ -862,6 +863,11 @@ def internal_paging(next_link=None, raw=False): # Construct and send request request = self._client.get(url, query_parameters, header_parameters) + return request + + def internal_paging(next_link=None): + request = prepare_request(next_link) + response = self._client.send(request, stream=False, **operation_config) if response.status_code not in [200]: @@ -870,12 +876,10 @@ def internal_paging(next_link=None, raw=False): return response # Deserialize response - deserialized = models.TagContractPaged(internal_paging, self._deserialize.dependencies) - + header_dict = None if raw: header_dict = {} - client_raw_response = models.TagContractPaged(internal_paging, self._deserialize.dependencies, header_dict) - return client_raw_response + deserialized = models.TagContractPaged(internal_paging, self._deserialize.dependencies, header_dict) return deserialized list_by_product.metadata = {'url': '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ApiManagement/service/{serviceName}/products/{productId}/tags'} @@ -909,7 +913,7 @@ def get_entity_state_by_product( 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])?$'), - 'productId': self._serialize.url("product_id", product_id, 'str', max_length=256, min_length=1, pattern=r'^[^*#&+:<>?]+$'), + 'productId': self._serialize.url("product_id", product_id, 'str', max_length=256, min_length=1), 'tagId': self._serialize.url("tag_id", tag_id, 'str', max_length=80, min_length=1, pattern=r'^[^*#&+:<>?]+$'), 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str') } @@ -973,7 +977,7 @@ def get_by_product( 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])?$'), - 'productId': self._serialize.url("product_id", product_id, 'str', max_length=256, min_length=1, pattern=r'^[^*#&+:<>?]+$'), + 'productId': self._serialize.url("product_id", product_id, 'str', max_length=256, min_length=1), 'tagId': self._serialize.url("tag_id", tag_id, 'str', max_length=80, min_length=1, pattern=r'^[^*#&+:<>?]+$'), 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str') } @@ -1000,9 +1004,8 @@ def get_by_product( if response.status_code not in [200]: raise models.ErrorResponseException(self._deserialize, response) - deserialized = None header_dict = {} - + deserialized = None if response.status_code == 200: deserialized = self._deserialize('TagContract', response) header_dict = { @@ -1047,7 +1050,7 @@ def assign_to_product( 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])?$'), - 'productId': self._serialize.url("product_id", product_id, 'str', max_length=256, min_length=1, pattern=r'^[^*#&+:<>?]+$'), + 'productId': self._serialize.url("product_id", product_id, 'str', max_length=256, min_length=1), 'tagId': self._serialize.url("tag_id", tag_id, 'str', max_length=80, min_length=1, pattern=r'^[^*#&+:<>?]+$'), 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str') } @@ -1075,7 +1078,6 @@ def assign_to_product( raise models.ErrorResponseException(self._deserialize, response) deserialized = None - if response.status_code == 200: deserialized = self._deserialize('TagContract', response) if response.status_code == 201: @@ -1117,7 +1119,7 @@ def detach_from_product( 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])?$'), - 'productId': self._serialize.url("product_id", product_id, 'str', max_length=256, min_length=1, pattern=r'^[^*#&+:<>?]+$'), + 'productId': self._serialize.url("product_id", product_id, 'str', max_length=256, min_length=1), 'tagId': self._serialize.url("tag_id", tag_id, 'str', max_length=80, min_length=1, pattern=r'^[^*#&+:<>?]+$'), 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str') } @@ -1180,8 +1182,7 @@ def list_by_service( :raises: :class:`ErrorResponseException` """ - def internal_paging(next_link=None, raw=False): - + def prepare_request(next_link=None): if not next_link: # Construct URL url = self.list_by_service.metadata['url'] @@ -1220,6 +1221,11 @@ def internal_paging(next_link=None, raw=False): # Construct and send request request = self._client.get(url, query_parameters, header_parameters) + return request + + def internal_paging(next_link=None): + request = prepare_request(next_link) + response = self._client.send(request, stream=False, **operation_config) if response.status_code not in [200]: @@ -1228,12 +1234,10 @@ def internal_paging(next_link=None, raw=False): return response # Deserialize response - deserialized = models.TagContractPaged(internal_paging, self._deserialize.dependencies) - + header_dict = None if raw: header_dict = {} - client_raw_response = models.TagContractPaged(internal_paging, self._deserialize.dependencies, header_dict) - return client_raw_response + deserialized = models.TagContractPaged(internal_paging, self._deserialize.dependencies, header_dict) return deserialized list_by_service.metadata = {'url': '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ApiManagement/service/{serviceName}/tags'} @@ -1350,9 +1354,8 @@ def get( if response.status_code not in [200]: raise models.ErrorResponseException(self._deserialize, response) - deserialized = None header_dict = {} - + deserialized = None if response.status_code == 200: deserialized = self._deserialize('TagContract', response) header_dict = { @@ -1433,9 +1436,8 @@ def create_or_update( if response.status_code not in [200, 201]: raise models.ErrorResponseException(self._deserialize, response) - deserialized = None header_dict = {} - + deserialized = None if response.status_code == 200: deserialized = self._deserialize('TagContract', response) header_dict = { diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/tag_resource_operations.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/_tag_resource_operations.py similarity index 93% rename from sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/tag_resource_operations.py rename to sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/_tag_resource_operations.py index 4fb092521714..bb8561c8cb26 100644 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/tag_resource_operations.py +++ b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/_tag_resource_operations.py @@ -18,11 +18,13 @@ class TagResourceOperations(object): """TagResourceOperations operations. + You should not instantiate directly this class, but create a Client instance that will create it for you and attach it as attribute. + :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: "2019-01-01". + :ivar api_version: Version of the API to be used with the client request. Constant value: "2019-12-01-preview". """ models = models @@ -32,7 +34,7 @@ def __init__(self, client, config, serializer, deserializer): self._client = client self._serialize = serializer self._deserialize = deserializer - self.api_version = "2019-01-01" + self.api_version = "2019-12-01-preview" self.config = config @@ -81,8 +83,7 @@ def list_by_service( :raises: :class:`ErrorResponseException` """ - def internal_paging(next_link=None, raw=False): - + def prepare_request(next_link=None): if not next_link: # Construct URL url = self.list_by_service.metadata['url'] @@ -119,6 +120,11 @@ def internal_paging(next_link=None, raw=False): # Construct and send request request = self._client.get(url, query_parameters, header_parameters) + return request + + def internal_paging(next_link=None): + request = prepare_request(next_link) + response = self._client.send(request, stream=False, **operation_config) if response.status_code not in [200]: @@ -127,12 +133,10 @@ def internal_paging(next_link=None, raw=False): return response # Deserialize response - deserialized = models.TagResourceContractPaged(internal_paging, self._deserialize.dependencies) - + header_dict = None if raw: header_dict = {} - client_raw_response = models.TagResourceContractPaged(internal_paging, self._deserialize.dependencies, header_dict) - return client_raw_response + deserialized = models.TagResourceContractPaged(internal_paging, self._deserialize.dependencies, header_dict) return deserialized list_by_service.metadata = {'url': '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ApiManagement/service/{serviceName}/tagResources'} diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/tenant_access_git_operations.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/_tenant_access_git_operations.py similarity index 74% rename from sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/tenant_access_git_operations.py rename to sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/_tenant_access_git_operations.py index 84740f7e47f6..ce25ff051276 100644 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/tenant_access_git_operations.py +++ b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/_tenant_access_git_operations.py @@ -18,11 +18,13 @@ class TenantAccessGitOperations(object): """TenantAccessGitOperations operations. + You should not instantiate directly this class, but create a Client instance that will create it for you and attach it as attribute. + :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: "2019-01-01". + :ivar api_version: Version of the API to be used with the client request. Constant value: "2019-12-01-preview". :ivar access_name: The identifier of the Access configuration. Constant value: "access". """ @@ -33,14 +35,14 @@ def __init__(self, client, config, serializer, deserializer): self._client = client self._serialize = serializer self._deserialize = deserializer - self.api_version = "2019-01-01" + self.api_version = "2019-12-01-preview" self.access_name = "access" self.config = config def get( self, resource_group_name, service_name, custom_headers=None, raw=False, **operation_config): - """Gets the Git access configuration for the tenant. + """Gets the Git access configuration for the tenant. Without secrets. :param resource_group_name: The name of the resource group. :type resource_group_name: str @@ -88,9 +90,8 @@ def get( if response.status_code not in [200]: raise models.ErrorResponseException(self._deserialize, response) - deserialized = None header_dict = {} - + deserialized = None if response.status_code == 200: deserialized = self._deserialize('AccessInformationContract', response) header_dict = { @@ -210,3 +211,69 @@ def regenerate_secondary_key( client_raw_response = ClientRawResponse(None, response) return client_raw_response regenerate_secondary_key.metadata = {'url': '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ApiManagement/service/{serviceName}/tenant/{accessName}/git/regenerateSecondaryKey'} + + def list_secrets( + self, resource_group_name, service_name, custom_headers=None, raw=False, **operation_config): + """Gets the Git access configuration for the tenant. + + :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 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: AccessInformationContract or ClientRawResponse if raw=true + :rtype: ~azure.mgmt.apimanagement.models.AccessInformationContract or + ~msrest.pipeline.ClientRawResponse + :raises: + :class:`ErrorResponseException` + """ + # Construct URL + url = self.list_secrets.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'), + 'accessName': self._serialize.url("self.access_name", self.access_name, '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.post(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) + + header_dict = {} + deserialized = None + if response.status_code == 200: + deserialized = self._deserialize('AccessInformationContract', response) + header_dict = { + 'ETag': 'str', + } + + if raw: + client_raw_response = ClientRawResponse(deserialized, response) + client_raw_response.add_headers(header_dict) + return client_raw_response + + return deserialized + list_secrets.metadata = {'url': '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ApiManagement/service/{serviceName}/tenant/{accessName}/git/listSecrets'} diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/tenant_access_operations.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/_tenant_access_operations.py similarity index 82% rename from sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/tenant_access_operations.py rename to sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/_tenant_access_operations.py index 3c7deb2493c9..7cfc4f837433 100644 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/tenant_access_operations.py +++ b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/_tenant_access_operations.py @@ -18,11 +18,13 @@ class TenantAccessOperations(object): """TenantAccessOperations operations. + You should not instantiate directly this class, but create a Client instance that will create it for you and attach it as attribute. + :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: "2019-01-01". + :ivar api_version: Version of the API to be used with the client request. Constant value: "2019-12-01-preview". :ivar access_name: The identifier of the Access configuration. Constant value: "access". """ @@ -33,7 +35,7 @@ def __init__(self, client, config, serializer, deserializer): self._client = client self._serialize = serializer self._deserialize = deserializer - self.api_version = "2019-01-01" + self.api_version = "2019-12-01-preview" self.access_name = "access" self.config = config @@ -96,7 +98,7 @@ def get_entity_tag( def get( self, resource_group_name, service_name, custom_headers=None, raw=False, **operation_config): - """Get tenant access information details. + """Get tenant access information details without secrets. :param resource_group_name: The name of the resource group. :type resource_group_name: str @@ -144,9 +146,8 @@ def get( if response.status_code not in [200]: raise models.ErrorResponseException(self._deserialize, response) - deserialized = None header_dict = {} - + deserialized = None if response.status_code == 200: deserialized = self._deserialize('AccessInformationContract', response) header_dict = { @@ -332,3 +333,69 @@ def regenerate_secondary_key( client_raw_response = ClientRawResponse(None, response) return client_raw_response regenerate_secondary_key.metadata = {'url': '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ApiManagement/service/{serviceName}/tenant/{accessName}/regenerateSecondaryKey'} + + def list_secrets( + self, resource_group_name, service_name, custom_headers=None, raw=False, **operation_config): + """Get tenant access information details. + + :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 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: AccessInformationContract or ClientRawResponse if raw=true + :rtype: ~azure.mgmt.apimanagement.models.AccessInformationContract or + ~msrest.pipeline.ClientRawResponse + :raises: + :class:`ErrorResponseException` + """ + # Construct URL + url = self.list_secrets.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'), + 'accessName': self._serialize.url("self.access_name", self.access_name, '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.post(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) + + header_dict = {} + deserialized = None + if response.status_code == 200: + deserialized = self._deserialize('AccessInformationContract', response) + header_dict = { + 'ETag': 'str', + } + + if raw: + client_raw_response = ClientRawResponse(deserialized, response) + client_raw_response.add_headers(header_dict) + return client_raw_response + + return deserialized + list_secrets.metadata = {'url': '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ApiManagement/service/{serviceName}/tenant/{accessName}/listSecrets'} diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/tenant_configuration_operations.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/_tenant_configuration_operations.py similarity index 98% rename from sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/tenant_configuration_operations.py rename to sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/_tenant_configuration_operations.py index 7b4a9bf37a4d..4bb26a04f229 100644 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/tenant_configuration_operations.py +++ b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/_tenant_configuration_operations.py @@ -21,11 +21,13 @@ class TenantConfigurationOperations(object): """TenantConfigurationOperations operations. + You should not instantiate directly this class, but create a Client instance that will create it for you and attach it as attribute. + :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: "2019-01-01". + :ivar api_version: Version of the API to be used with the client request. Constant value: "2019-12-01-preview". :ivar configuration_name: The identifier of the Git Configuration Operation. Constant value: "configuration". """ @@ -36,7 +38,7 @@ def __init__(self, client, config, serializer, deserializer): self._client = client self._serialize = serializer self._deserialize = deserializer - self.api_version = "2019-01-01" + self.api_version = "2019-12-01-preview" self.configuration_name = "configuration" self.config = config @@ -423,7 +425,6 @@ def get_sync_state( raise exp deserialized = None - if response.status_code == 200: deserialized = self._deserialize('TenantConfigurationSyncStateContract', response) diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/user_confirmation_password_operations.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/_user_confirmation_password_operations.py similarity index 93% rename from sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/user_confirmation_password_operations.py rename to sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/_user_confirmation_password_operations.py index faa76b03f4d2..90f203e88ff2 100644 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/user_confirmation_password_operations.py +++ b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/_user_confirmation_password_operations.py @@ -18,11 +18,13 @@ class UserConfirmationPasswordOperations(object): """UserConfirmationPasswordOperations operations. + You should not instantiate directly this class, but create a Client instance that will create it for you and attach it as attribute. + :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: "2019-01-01". + :ivar api_version: Version of the API to be used with the client request. Constant value: "2019-12-01-preview". """ models = models @@ -32,7 +34,7 @@ def __init__(self, client, config, serializer, deserializer): self._client = client self._serialize = serializer self._deserialize = deserializer - self.api_version = "2019-01-01" + self.api_version = "2019-12-01-preview" self.config = config @@ -62,7 +64,7 @@ def send( 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])?$'), - 'userId': self._serialize.url("user_id", user_id, 'str', max_length=80, min_length=1, pattern=r'^[^*#&+:<>?]+$'), + 'userId': self._serialize.url("user_id", user_id, 'str', max_length=80, min_length=1), 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str') } url = self._client.format_url(url, **path_format_arguments) diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/user_group_operations.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/_user_group_operations.py similarity index 91% rename from sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/user_group_operations.py rename to sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/_user_group_operations.py index d43a29185134..e7475736c086 100644 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/user_group_operations.py +++ b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/_user_group_operations.py @@ -18,11 +18,13 @@ class UserGroupOperations(object): """UserGroupOperations operations. + You should not instantiate directly this class, but create a Client instance that will create it for you and attach it as attribute. + :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: "2019-01-01". + :ivar api_version: Version of the API to be used with the client request. Constant value: "2019-12-01-preview". """ models = models @@ -32,7 +34,7 @@ def __init__(self, client, config, serializer, deserializer): self._client = client self._serialize = serializer self._deserialize = deserializer - self.api_version = "2019-01-01" + self.api_version = "2019-12-01-preview" self.config = config @@ -71,15 +73,14 @@ def list( :raises: :class:`ErrorResponseException` """ - def internal_paging(next_link=None, raw=False): - + def prepare_request(next_link=None): if not next_link: # Construct URL url = self.list.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])?$'), - 'userId': self._serialize.url("user_id", user_id, 'str', max_length=80, min_length=1, pattern=r'^[^*#&+:<>?]+$'), + 'userId': self._serialize.url("user_id", user_id, 'str', max_length=80, min_length=1), 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str') } url = self._client.format_url(url, **path_format_arguments) @@ -110,6 +111,11 @@ def internal_paging(next_link=None, raw=False): # Construct and send request request = self._client.get(url, query_parameters, header_parameters) + return request + + def internal_paging(next_link=None): + request = prepare_request(next_link) + response = self._client.send(request, stream=False, **operation_config) if response.status_code not in [200]: @@ -118,12 +124,10 @@ def internal_paging(next_link=None, raw=False): return response # Deserialize response - deserialized = models.GroupContractPaged(internal_paging, self._deserialize.dependencies) - + header_dict = None if raw: header_dict = {} - client_raw_response = models.GroupContractPaged(internal_paging, self._deserialize.dependencies, header_dict) - return client_raw_response + deserialized = models.GroupContractPaged(internal_paging, self._deserialize.dependencies, header_dict) return deserialized list.metadata = {'url': '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ApiManagement/service/{serviceName}/users/{userId}/groups'} diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/user_identities_operations.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/_user_identities_operations.py similarity index 89% rename from sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/user_identities_operations.py rename to sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/_user_identities_operations.py index 6a9ce0a5b8e2..90b4cf032c44 100644 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/user_identities_operations.py +++ b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/_user_identities_operations.py @@ -18,11 +18,13 @@ class UserIdentitiesOperations(object): """UserIdentitiesOperations operations. + You should not instantiate directly this class, but create a Client instance that will create it for you and attach it as attribute. + :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: "2019-01-01". + :ivar api_version: Version of the API to be used with the client request. Constant value: "2019-12-01-preview". """ models = models @@ -32,7 +34,7 @@ def __init__(self, client, config, serializer, deserializer): self._client = client self._serialize = serializer self._deserialize = deserializer - self.api_version = "2019-01-01" + self.api_version = "2019-12-01-preview" self.config = config @@ -58,15 +60,14 @@ def list( :raises: :class:`ErrorResponseException` """ - def internal_paging(next_link=None, raw=False): - + def prepare_request(next_link=None): if not next_link: # Construct URL url = self.list.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])?$'), - 'userId': self._serialize.url("user_id", user_id, 'str', max_length=80, min_length=1, pattern=r'^[^*#&+:<>?]+$'), + 'userId': self._serialize.url("user_id", user_id, 'str', max_length=80, min_length=1), 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str') } url = self._client.format_url(url, **path_format_arguments) @@ -91,6 +92,11 @@ def internal_paging(next_link=None, raw=False): # Construct and send request request = self._client.get(url, query_parameters, header_parameters) + return request + + def internal_paging(next_link=None): + request = prepare_request(next_link) + response = self._client.send(request, stream=False, **operation_config) if response.status_code not in [200]: @@ -99,12 +105,10 @@ def internal_paging(next_link=None, raw=False): return response # Deserialize response - deserialized = models.UserIdentityContractPaged(internal_paging, self._deserialize.dependencies) - + header_dict = None if raw: header_dict = {} - client_raw_response = models.UserIdentityContractPaged(internal_paging, self._deserialize.dependencies, header_dict) - return client_raw_response + deserialized = models.UserIdentityContractPaged(internal_paging, self._deserialize.dependencies, header_dict) return deserialized list.metadata = {'url': '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ApiManagement/service/{serviceName}/users/{userId}/identities'} diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/user_operations.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/_user_operations.py similarity index 97% rename from sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/user_operations.py rename to sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/_user_operations.py index 79e55902d2e5..a205dceb7406 100644 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/user_operations.py +++ b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/_user_operations.py @@ -18,11 +18,13 @@ class UserOperations(object): """UserOperations operations. + You should not instantiate directly this class, but create a Client instance that will create it for you and attach it as attribute. + :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: "2019-01-01". + :ivar api_version: Version of the API to be used with the client request. Constant value: "2019-12-01-preview". """ models = models @@ -32,7 +34,7 @@ def __init__(self, client, config, serializer, deserializer): self._client = client self._serialize = serializer self._deserialize = deserializer - self.api_version = "2019-01-01" + self.api_version = "2019-12-01-preview" self.config = config @@ -76,8 +78,7 @@ def list_by_service( :raises: :class:`ErrorResponseException` """ - def internal_paging(next_link=None, raw=False): - + def prepare_request(next_link=None): if not next_link: # Construct URL url = self.list_by_service.metadata['url'] @@ -116,6 +117,11 @@ def internal_paging(next_link=None, raw=False): # Construct and send request request = self._client.get(url, query_parameters, header_parameters) + return request + + def internal_paging(next_link=None): + request = prepare_request(next_link) + response = self._client.send(request, stream=False, **operation_config) if response.status_code not in [200]: @@ -124,12 +130,10 @@ def internal_paging(next_link=None, raw=False): return response # Deserialize response - deserialized = models.UserContractPaged(internal_paging, self._deserialize.dependencies) - + header_dict = None if raw: header_dict = {} - client_raw_response = models.UserContractPaged(internal_paging, self._deserialize.dependencies, header_dict) - return client_raw_response + deserialized = models.UserContractPaged(internal_paging, self._deserialize.dependencies, header_dict) return deserialized list_by_service.metadata = {'url': '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ApiManagement/service/{serviceName}/users'} @@ -161,7 +165,7 @@ def get_entity_tag( 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])?$'), - 'userId': self._serialize.url("user_id", user_id, 'str', max_length=80, min_length=1, pattern=r'^[^*#&+:<>?]+$'), + 'userId': self._serialize.url("user_id", user_id, 'str', max_length=80, min_length=1), 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str') } url = self._client.format_url(url, **path_format_arguments) @@ -221,7 +225,7 @@ def get( 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])?$'), - 'userId': self._serialize.url("user_id", user_id, 'str', max_length=80, min_length=1, pattern=r'^[^*#&+:<>?]+$'), + 'userId': self._serialize.url("user_id", user_id, 'str', max_length=80, min_length=1), 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str') } url = self._client.format_url(url, **path_format_arguments) @@ -247,9 +251,8 @@ def get( if response.status_code not in [200]: raise models.ErrorResponseException(self._deserialize, response) - deserialized = None header_dict = {} - + deserialized = None if response.status_code == 200: deserialized = self._deserialize('UserContract', response) header_dict = { @@ -297,7 +300,7 @@ def create_or_update( 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])?$'), - 'userId': self._serialize.url("user_id", user_id, 'str', max_length=80, min_length=1, pattern=r'^[^*#&+:<>?]+$'), + 'userId': self._serialize.url("user_id", user_id, 'str', max_length=80, min_length=1), 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str') } url = self._client.format_url(url, **path_format_arguments) @@ -329,9 +332,8 @@ def create_or_update( if response.status_code not in [200, 201]: raise models.ErrorResponseException(self._deserialize, response) - deserialized = None header_dict = {} - + deserialized = None if response.status_code == 200: deserialized = self._deserialize('UserContract', response) header_dict = { @@ -384,7 +386,7 @@ def update( 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])?$'), - 'userId': self._serialize.url("user_id", user_id, 'str', max_length=80, min_length=1, pattern=r'^[^*#&+:<>?]+$'), + 'userId': self._serialize.url("user_id", user_id, 'str', max_length=80, min_length=1), 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str') } url = self._client.format_url(url, **path_format_arguments) @@ -454,7 +456,7 @@ def delete( 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])?$'), - 'userId': self._serialize.url("user_id", user_id, 'str', max_length=80, min_length=1, pattern=r'^[^*#&+:<>?]+$'), + 'userId': self._serialize.url("user_id", user_id, 'str', max_length=80, min_length=1), 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str') } url = self._client.format_url(url, **path_format_arguments) @@ -517,7 +519,7 @@ def generate_sso_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])?$'), - 'userId': self._serialize.url("user_id", user_id, 'str', max_length=80, min_length=1, pattern=r'^[^*#&+:<>?]+$'), + 'userId': self._serialize.url("user_id", user_id, 'str', max_length=80, min_length=1), 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str') } url = self._client.format_url(url, **path_format_arguments) @@ -544,7 +546,6 @@ def generate_sso_url( raise models.ErrorResponseException(self._deserialize, response) deserialized = None - if response.status_code == 200: deserialized = self._deserialize('GenerateSsoUrlResult', response) @@ -591,7 +592,7 @@ def get_shared_access_token( 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])?$'), - 'userId': self._serialize.url("user_id", user_id, 'str', max_length=80, min_length=1, pattern=r'^[^*#&+:<>?]+$'), + 'userId': self._serialize.url("user_id", user_id, 'str', max_length=80, min_length=1), 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str') } url = self._client.format_url(url, **path_format_arguments) @@ -622,7 +623,6 @@ def get_shared_access_token( raise models.ErrorResponseException(self._deserialize, response) deserialized = None - if response.status_code == 200: deserialized = self._deserialize('UserTokenResult', response) diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/user_subscription_operations.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/_user_subscription_operations.py similarity index 92% rename from sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/user_subscription_operations.py rename to sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/_user_subscription_operations.py index bf2802f5bab9..8c90073d133d 100644 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/user_subscription_operations.py +++ b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/_user_subscription_operations.py @@ -18,11 +18,13 @@ class UserSubscriptionOperations(object): """UserSubscriptionOperations operations. + You should not instantiate directly this class, but create a Client instance that will create it for you and attach it as attribute. + :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: "2019-01-01". + :ivar api_version: Version of the API to be used with the client request. Constant value: "2019-12-01-preview". """ models = models @@ -32,7 +34,7 @@ def __init__(self, client, config, serializer, deserializer): self._client = client self._serialize = serializer self._deserialize = deserializer - self.api_version = "2019-01-01" + self.api_version = "2019-12-01-preview" self.config = config @@ -77,15 +79,14 @@ def list( :raises: :class:`ErrorResponseException` """ - def internal_paging(next_link=None, raw=False): - + def prepare_request(next_link=None): if not next_link: # Construct URL url = self.list.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])?$'), - 'userId': self._serialize.url("user_id", user_id, 'str', max_length=80, min_length=1, pattern=r'^[^*#&+:<>?]+$'), + 'userId': self._serialize.url("user_id", user_id, 'str', max_length=80, min_length=1), 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str') } url = self._client.format_url(url, **path_format_arguments) @@ -116,6 +117,11 @@ def internal_paging(next_link=None, raw=False): # Construct and send request request = self._client.get(url, query_parameters, header_parameters) + return request + + def internal_paging(next_link=None): + request = prepare_request(next_link) + response = self._client.send(request, stream=False, **operation_config) if response.status_code not in [200]: @@ -124,12 +130,10 @@ def internal_paging(next_link=None, raw=False): return response # Deserialize response - deserialized = models.SubscriptionContractPaged(internal_paging, self._deserialize.dependencies) - + header_dict = None if raw: header_dict = {} - client_raw_response = models.SubscriptionContractPaged(internal_paging, self._deserialize.dependencies, header_dict) - return client_raw_response + deserialized = models.SubscriptionContractPaged(internal_paging, self._deserialize.dependencies, header_dict) return deserialized list.metadata = {'url': '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ApiManagement/service/{serviceName}/users/{userId}/subscriptions'} diff --git a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/property_operations.py b/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/property_operations.py deleted file mode 100644 index 3c243740613c..000000000000 --- a/sdk/apimanagement/azure-mgmt-apimanagement/azure/mgmt/apimanagement/operations/property_operations.py +++ /dev/null @@ -1,463 +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. -# -------------------------------------------------------------------------- - -import uuid -from msrest.pipeline import ClientRawResponse - -from .. import models - - -class PropertyOperations(object): - """PropertyOperations 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: "2019-01-01". - """ - - models = models - - def __init__(self, client, config, serializer, deserializer): - - self._client = client - self._serialize = serializer - self._deserialize = deserializer - self.api_version = "2019-01-01" - - self.config = config - - def list_by_service( - self, resource_group_name, service_name, filter=None, top=None, skip=None, custom_headers=None, raw=False, **operation_config): - """Lists a collection of properties defined within a 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 filter: | Field | Usage | Supported operators - | Supported functions - |
|-------------|-------------|-------------|-------------|
| - tags | filter | ge, le, eq, ne, gt, lt | substringof, contains, - startswith, endswith, any, all |
| displayName | filter | ge, le, - eq, ne, gt, lt | substringof, contains, startswith, endswith |
- :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 PropertyContract - :rtype: - ~azure.mgmt.apimanagement.models.PropertyContractPaged[~azure.mgmt.apimanagement.models.PropertyContract] - :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') - } - url = self._client.format_url(url, **path_format_arguments) - - # Construct parameters - query_parameters = {} - 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) - query_parameters['api-version'] = self._serialize.query("self.api_version", self.api_version, 'str') - - 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.PropertyContractPaged(internal_paging, self._deserialize.dependencies) - - if raw: - header_dict = {} - client_raw_response = models.PropertyContractPaged(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}/properties'} - - def get_entity_tag( - self, resource_group_name, service_name, prop_id, custom_headers=None, raw=False, **operation_config): - """Gets the entity state (Etag) version of the property specified by its - identifier. - - :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 prop_id: Identifier of the property. - :type prop_id: 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.get_entity_tag.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])?$'), - 'propId': self._serialize.url("prop_id", prop_id, 'str', max_length=256, pattern=r'^[^*#&+:<>?]+$'), - '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 [200]: - raise models.ErrorResponseException(self._deserialize, response) - - if raw: - client_raw_response = ClientRawResponse(None, response) - client_raw_response.add_headers({ - 'ETag': 'str', - }) - return client_raw_response - get_entity_tag.metadata = {'url': '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ApiManagement/service/{serviceName}/properties/{propId}'} - - def get( - self, resource_group_name, service_name, prop_id, custom_headers=None, raw=False, **operation_config): - """Gets the details of the property specified by its identifier. - - :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 prop_id: Identifier of the property. - :type prop_id: 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: PropertyContract or ClientRawResponse if raw=true - :rtype: ~azure.mgmt.apimanagement.models.PropertyContract or - ~msrest.pipeline.ClientRawResponse - :raises: - :class:`ErrorResponseException` - """ - # Construct URL - url = self.get.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])?$'), - 'propId': self._serialize.url("prop_id", prop_id, 'str', max_length=256, pattern=r'^[^*#&+:<>?]+$'), - '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.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) - - deserialized = None - header_dict = {} - - if response.status_code == 200: - deserialized = self._deserialize('PropertyContract', response) - header_dict = { - 'ETag': 'str', - } - - if raw: - client_raw_response = ClientRawResponse(deserialized, response) - client_raw_response.add_headers(header_dict) - return client_raw_response - - return deserialized - get.metadata = {'url': '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ApiManagement/service/{serviceName}/properties/{propId}'} - - def create_or_update( - self, resource_group_name, service_name, prop_id, parameters, if_match=None, custom_headers=None, raw=False, **operation_config): - """Creates or updates a property. - - :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 prop_id: Identifier of the property. - :type prop_id: str - :param parameters: Create parameters. - :type parameters: ~azure.mgmt.apimanagement.models.PropertyContract - :param if_match: ETag of the Entity. Not required when creating an - entity, but required when updating an entity. - :type if_match: 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: PropertyContract or ClientRawResponse if raw=true - :rtype: ~azure.mgmt.apimanagement.models.PropertyContract 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])?$'), - 'propId': self._serialize.url("prop_id", prop_id, 'str', max_length=256, pattern=r'^[^*#&+:<>?]+$'), - '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' - header_parameters['Content-Type'] = 'application/json; charset=utf-8' - 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 if_match is not None: - header_parameters['If-Match'] = self._serialize.header("if_match", if_match, 'str') - 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 body - body_content = self._serialize.body(parameters, 'PropertyContract') - - # Construct and send request - request = self._client.put(url, query_parameters, header_parameters, body_content) - 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 - header_dict = {} - - if response.status_code == 200: - deserialized = self._deserialize('PropertyContract', response) - header_dict = { - 'ETag': 'str', - } - if response.status_code == 201: - deserialized = self._deserialize('PropertyContract', response) - header_dict = { - 'ETag': 'str', - } - - if raw: - client_raw_response = ClientRawResponse(deserialized, response) - client_raw_response.add_headers(header_dict) - return client_raw_response - - return deserialized - create_or_update.metadata = {'url': '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ApiManagement/service/{serviceName}/properties/{propId}'} - - def update( - self, resource_group_name, service_name, prop_id, parameters, if_match, custom_headers=None, raw=False, **operation_config): - """Updates the specific property. - - :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 prop_id: Identifier of the property. - :type prop_id: str - :param parameters: Update parameters. - :type parameters: - ~azure.mgmt.apimanagement.models.PropertyUpdateParameters - :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 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.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])?$'), - 'propId': self._serialize.url("prop_id", prop_id, 'str', max_length=256, pattern=r'^[^*#&+:<>?]+$'), - '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['Content-Type'] = 'application/json; charset=utf-8' - 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) - header_parameters['If-Match'] = self._serialize.header("if_match", if_match, 'str') - 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 body - body_content = self._serialize.body(parameters, 'PropertyUpdateParameters') - - # Construct and send request - request = self._client.patch(url, query_parameters, header_parameters, body_content) - response = self._client.send(request, stream=False, **operation_config) - - if response.status_code not in [204]: - raise models.ErrorResponseException(self._deserialize, response) - - if raw: - client_raw_response = ClientRawResponse(None, response) - return client_raw_response - update.metadata = {'url': '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ApiManagement/service/{serviceName}/properties/{propId}'} - - def delete( - self, resource_group_name, service_name, prop_id, if_match, custom_headers=None, raw=False, **operation_config): - """Deletes specific property from 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 prop_id: Identifier of the property. - :type prop_id: str - :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 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])?$'), - 'propId': self._serialize.url("prop_id", prop_id, 'str', max_length=256, pattern=r'^[^*#&+:<>?]+$'), - '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) - header_parameters['If-Match'] = self._serialize.header("if_match", if_match, 'str') - 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}/properties/{propId}'}