# Source code for azure.mgmt.cdn.models._models_py3

    # coding=utf-8
    # --------------------------------------------------------------------------
    # Copyright (c) Microsoft Corporation. All rights reserved.
    # Licensed under the MIT License. See License.txt in the project root for
    # license information.
    #
    # 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 CacheExpirationActionParameters(Model):
        """Defines the parameters for the cache expiration action.

        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 odatatype: Required.  Default value:
         "#Microsoft.Azure.Cdn.Models.DeliveryRuleCacheExpirationActionParameters"
         .
        :vartype odatatype: str
        :param cache_behavior: Required. Caching behavior for the requests.
         Possible values include: 'BypassCache', 'Override', 'SetIfMissing'
        :type cache_behavior: str or ~azure.mgmt.cdn.models.CacheBehavior
        :ivar cache_type: Required. The level at which the content needs to be
         cached. Default value: "All" .
        :vartype cache_type: str
        :param cache_duration: The duration for which the content needs to be
         cached. Allowed format is [d.]hh:mm:ss
        :type cache_duration: str
        """

        _validation = {
            'odatatype': {'required': True, 'constant': True},
            'cache_behavior': {'required': True},
            'cache_type': {'required': True, 'constant': True},
        }

        _attribute_map = {
            'odatatype': {'key': '@odata\\.type', 'type': 'str'},
            'cache_behavior': {'key': 'cacheBehavior', 'type': 'str'},
            'cache_type': {'key': 'cacheType', 'type': 'str'},
            'cache_duration': {'key': 'cacheDuration', 'type': 'str'},
        }

        odatatype = "#Microsoft.Azure.Cdn.Models.DeliveryRuleCacheExpirationActionParameters"

        cache_type = "All"

        def __init__(self, *, cache_behavior, cache_duration: str=None, **kwargs) -> None:
            super(CacheExpirationActionParameters, self).__init__(**kwargs)
            self.cache_behavior = cache_behavior
            self.cache_duration = cache_duration

    class CacheKeyQueryStringActionParameters(Model):
        """Defines the parameters for the cache-key query string action.

        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 odatatype: Required.  Default value:
         "#Microsoft.Azure.Cdn.Models.DeliveryRuleCacheKeyQueryStringBehaviorActionParameters"
         .
        :vartype odatatype: str
        :param query_string_behavior: Required. Caching behavior for the requests.
         Possible values include: 'Include', 'IncludeAll', 'Exclude', 'ExcludeAll'
        :type query_string_behavior: str or
         ~azure.mgmt.cdn.models.QueryStringBehavior
        :param query_parameters: query parameters to include or exclude (comma
         separated).
        :type query_parameters: str
        """

        _validation = {
            'odatatype': {'required': True, 'constant': True},
            'query_string_behavior': {'required': True},
        }

        _attribute_map = {
            'odatatype': {'key': '@odata\\.type', 'type': 'str'},
            'query_string_behavior': {'key': 'queryStringBehavior', 'type': 'str'},
            'query_parameters': {'key': 'queryParameters', 'type': 'str'},
        }

        odatatype = "#Microsoft.Azure.Cdn.Models.DeliveryRuleCacheKeyQueryStringBehaviorActionParameters"

        def __init__(self, *, query_string_behavior, query_parameters: str=None, **kwargs) -> None:
            super(CacheKeyQueryStringActionParameters, self).__init__(**kwargs)
            self.query_string_behavior = query_string_behavior
            self.query_parameters = query_parameters

    class CdnCertificateSourceParameters(Model):
        """Defines the parameters for using CDN managed certificate for securing
        custom domain.

        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 odatatype: Required.  Default value:
         "#Microsoft.Azure.Cdn.Models.CdnCertificateSourceParameters" .
        :vartype odatatype: str
        :param certificate_type: Required. Type of certificate used. Possible
         values include: 'Shared', 'Dedicated'
        :type certificate_type: str or ~azure.mgmt.cdn.models.CertificateType
        """

        _validation = {
            'odatatype': {'required': True, 'constant': True},
            'certificate_type': {'required': True},
        }

        _attribute_map = {
            'odatatype': {'key': '@odata\\.type', 'type': 'str'},
            'certificate_type': {'key': 'certificateType', 'type': 'str'},
        }

        odatatype = "#Microsoft.Azure.Cdn.Models.CdnCertificateSourceParameters"

        def __init__(self, *, certificate_type, **kwargs) -> None:
            super(CdnCertificateSourceParameters, self).__init__(**kwargs)
            self.certificate_type = certificate_type

    class CdnEndpoint(Model):
        """Defines the ARM Resource ID for the linked endpoints.

        :param id: ARM Resource ID string.
        :type id: str
        """

        _attribute_map = {
            'id': {'key': 'id', 'type': 'str'},
        }

        def __init__(self, *, id: str=None, **kwargs) -> None:
            super(CdnEndpoint, self).__init__(**kwargs)
            self.id = id

    class CustomDomainHttpsParameters(Model):
        """The JSON object that contains the properties to secure a custom domain.

        You probably want to use the sub-classes and not this class directly. Known
        sub-classes are: CdnManagedHttpsParameters, UserManagedHttpsParameters

        All required parameters must be populated in order to send to Azure.

        :param protocol_type: Required. Defines the TLS extension protocol that is
         used for secure delivery. Possible values include: 'ServerNameIndication',
         'IPBased'
        :type protocol_type: str or ~azure.mgmt.cdn.models.ProtocolType
        :param minimum_tls_version: TLS protocol version that will be used for
         Https. Possible values include: 'None', 'TLS10', 'TLS12'
        :type minimum_tls_version: str or ~azure.mgmt.cdn.models.MinimumTlsVersion
        :param certificate_source: Required. Constant filled by server.
        :type certificate_source: str
        """

        _validation = {
            'protocol_type': {'required': True},
            'certificate_source': {'required': True},
        }

        _attribute_map = {
            'protocol_type': {'key': 'protocolType', 'type': 'str'},
            'minimum_tls_version': {'key': 'minimumTlsVersion', 'type': 'MinimumTlsVersion'},
            'certificate_source': {'key': 'certificateSource', 'type': 'str'},
        }

        _subtype_map = {
            'certificate_source': {'Cdn': 'CdnManagedHttpsParameters', 'AzureKeyVault': 'UserManagedHttpsParameters'}
        }

        def __init__(self, *, protocol_type, minimum_tls_version=None, **kwargs) -> None:
            super(CustomDomainHttpsParameters, self).__init__(**kwargs)
            self.protocol_type = protocol_type
            self.minimum_tls_version = minimum_tls_version
            self.certificate_source = None

    class CdnManagedHttpsParameters(CustomDomainHttpsParameters):
        """Defines the certificate source parameters using CDN managed certificate for
        enabling SSL.

        All required parameters must be populated in order to send to Azure.

        :param protocol_type: Required. Defines the TLS extension protocol that is
         used for secure delivery. Possible values include: 'ServerNameIndication',
         'IPBased'
        :type protocol_type: str or ~azure.mgmt.cdn.models.ProtocolType
        :param minimum_tls_version: TLS protocol version that will be used for
         Https. Possible values include: 'None', 'TLS10', 'TLS12'
        :type minimum_tls_version: str or ~azure.mgmt.cdn.models.MinimumTlsVersion
        :param certificate_source: Required. Constant filled by server.
        :type certificate_source: str
        :param certificate_source_parameters: Required. Defines the certificate
         source parameters using CDN managed certificate for enabling SSL.
        :type certificate_source_parameters:
         ~azure.mgmt.cdn.models.CdnCertificateSourceParameters
        """

        _validation = {
            'protocol_type': {'required': True},
            'certificate_source': {'required': True},
            'certificate_source_parameters': {'required': True},
        }

        _attribute_map = {
            'protocol_type': {'key': 'protocolType', 'type': 'str'},
            'minimum_tls_version': {'key': 'minimumTlsVersion', 'type': 'MinimumTlsVersion'},
            'certificate_source': {'key': 'certificateSource', 'type': 'str'},
            'certificate_source_parameters': {'key': 'certificateSourceParameters', 'type': 'CdnCertificateSourceParameters'},
        }

        def __init__(self, *, protocol_type, certificate_source_parameters, minimum_tls_version=None, **kwargs) -> None:
            super(CdnManagedHttpsParameters, self).__init__(protocol_type=protocol_type, minimum_tls_version=minimum_tls_version, **kwargs)
            self.certificate_source_parameters = certificate_source_parameters
            self.certificate_source = 'Cdn'

    class Resource(Model):
        """The core properties of ARM resources.

        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.
        :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 TrackedResource(Resource):
        """The resource model definition for a ARM tracked top level 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 id: Resource ID.
        :vartype id: str
        :ivar name: Resource name.
        :vartype name: str
        :ivar type: Resource type.
        :vartype type: str
        :param location: Required. Resource location.
        :type location: str
        :param tags: Resource tags.
        :type tags: dict[str, str]
        """

        _validation = {
            'id': {'readonly': True},
            'name': {'readonly': True},
            'type': {'readonly': True},
            'location': {'required': True},
        }

        _attribute_map = {
            'id': {'key': 'id', 'type': 'str'},
            'name': {'key': 'name', 'type': 'str'},
            'type': {'key': 'type', 'type': 'str'},
            'location': {'key': 'location', 'type': 'str'},
            'tags': {'key': 'tags', 'type': '{str}'},
        }

        def __init__(self, *, location: str, tags=None, **kwargs) -> None:
            super(TrackedResource, self).__init__(**kwargs)
            self.location = location
            self.tags = tags

    class CdnWebApplicationFirewallPolicy(TrackedResource):
        """Defines web application firewall policy for Azure CDN.

        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.
        :vartype type: str
        :param location: Required. Resource location.
        :type location: str
        :param tags: Resource tags.
        :type tags: dict[str, str]
        :param policy_settings: Describes  policySettings for policy
        :type policy_settings: ~azure.mgmt.cdn.models.PolicySettings
        :param rate_limit_rules: Describes rate limit rules inside the policy.
        :type rate_limit_rules: ~azure.mgmt.cdn.models.RateLimitRuleList
        :param custom_rules: Describes custom rules inside the policy.
        :type custom_rules: ~azure.mgmt.cdn.models.CustomRuleList
        :param managed_rules: Describes managed rules inside the policy.
        :type managed_rules: ~azure.mgmt.cdn.models.ManagedRuleSetList
        :ivar endpoint_links: Describes Azure CDN endpoints associated with this
         Web Application Firewall policy.
        :vartype endpoint_links: list[~azure.mgmt.cdn.models.CdnEndpoint]
        :ivar provisioning_state: Provisioning state of the
         WebApplicationFirewallPolicy. Possible values include: 'Creating',
         'Succeeded', 'Failed'
        :vartype provisioning_state: str or
         ~azure.mgmt.cdn.models.ProvisioningState
        :ivar resource_state: Resource status of the policy. Possible values
         include: 'Creating', 'Enabling', 'Enabled', 'Disabling', 'Disabled',
         'Deleting'
        :vartype resource_state: str or ~azure.mgmt.cdn.models.PolicyResourceState
        :param etag: Gets a unique read-only string that changes whenever the
         resource is updated.
        :type etag: str
        :param sku: Required. The pricing tier (defines a CDN provider, feature
         list and rate) of the CdnWebApplicationFirewallPolicy.
        :type sku: ~azure.mgmt.cdn.models.Sku
        """

        _validation = {
            'id': {'readonly': True},
            'name': {'readonly': True},
            'type': {'readonly': True},
            'location': {'required': True},
            'endpoint_links': {'readonly': True},
            'provisioning_state': {'readonly': True},
            'resource_state': {'readonly': True},
            'sku': {'required': True},
        }

        _attribute_map = {
            'id': {'key': 'id', 'type': 'str'},
            'name': {'key': 'name', 'type': 'str'},
            'type': {'key': 'type', 'type': 'str'},
            'location': {'key': 'location', 'type': 'str'},
            'tags': {'key': 'tags', 'type': '{str}'},
            'policy_settings': {'key': 'properties.policySettings', 'type': 'PolicySettings'},
            'rate_limit_rules': {'key': 'properties.rateLimitRules', 'type': 'RateLimitRuleList'},
            'custom_rules': {'key': 'properties.customRules', 'type': 'CustomRuleList'},
            'managed_rules': {'key': 'properties.managedRules', 'type': 'ManagedRuleSetList'},
            'endpoint_links': {'key': 'properties.endpointLinks', 'type': '[CdnEndpoint]'},
            'provisioning_state': {'key': 'properties.provisioningState', 'type': 'str'},
            'resource_state': {'key': 'properties.resourceState', 'type': 'str'},
            'etag': {'key': 'etag', 'type': 'str'},
            'sku': {'key': 'sku', 'type': 'Sku'},
        }

        def __init__(self, *, location: str, sku, tags=None, policy_settings=None, rate_limit_rules=None, custom_rules=None, managed_rules=None, etag: str=None, **kwargs) -> None:
            super(CdnWebApplicationFirewallPolicy, self).__init__(location=location, tags=tags, **kwargs)
            self.policy_settings = policy_settings
            self.rate_limit_rules = rate_limit_rules
            self.custom_rules = custom_rules
            self.managed_rules = managed_rules
            self.endpoint_links = None
            self.provisioning_state = None
            self.resource_state = None
            self.etag = etag
            self.sku = sku

    class CdnWebApplicationFirewallPolicyPatchParameters(Model):
        """Properties required to update a CdnWebApplicationFirewallPolicy.

        :param tags: CdnWebApplicationFirewallPolicy tags
        :type tags: dict[str, str]
        """

        _attribute_map = {
            'tags': {'key': 'tags', 'type': '{str}'},
        }

        def __init__(self, *, tags=None, **kwargs) -> None:
            super(CdnWebApplicationFirewallPolicyPatchParameters, self).__init__(**kwargs)
            self.tags = tags

    class CheckNameAvailabilityInput(Model):
        """Input of CheckNameAvailability API.

        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 name: Required. The resource name to validate.
        :type name: str
        :ivar type: Required. The type of the resource whose name is to be
         validated. Default value: "Microsoft.Cdn/Profiles/Endpoints" .
        :vartype type: str
        """

        _validation = {
            'name': {'required': True},
            'type': {'required': True, 'constant': True},
        }

        _attribute_map = {
            'name': {'key': 'name', 'type': 'str'},
            'type': {'key': 'type', 'type': 'str'},
        }

        type = "Microsoft.Cdn/Profiles/Endpoints"

        def __init__(self, *, name: str, **kwargs) -> None:
            super(CheckNameAvailabilityInput, self).__init__(**kwargs)
            self.name = name

    class CheckNameAvailabilityOutput(Model):
        """Output of check name availability API.

        Variables are only populated by the server, and will be ignored when
        sending a request.

        :ivar name_available: Indicates whether the name is available.
        :vartype name_available: bool
        :ivar reason: The reason why the name is not available.
        :vartype reason: str
        :ivar message: The detailed error message describing why the name is not
         available.
        :vartype message: str
        """

        _validation = {
            'name_available': {'readonly': True},
            'reason': {'readonly': True},
            'message': {'readonly': True},
        }

        _attribute_map = {
            'name_available': {'key': 'nameAvailable', 'type': 'bool'},
            'reason': {'key': 'reason', 'type': 'str'},
            'message': {'key': 'message', 'type': 'str'},
        }

        def __init__(self, **kwargs) -> None:
            super(CheckNameAvailabilityOutput, self).__init__(**kwargs)
            self.name_available = None
            self.reason = None
            self.message = None

    class CidrIpAddress(Model):
        """CIDR Ip address.

        :param base_ip_address: Ip address itself.
        :type base_ip_address: str
        :param prefix_length: The length of the prefix of the ip address.
        :type prefix_length: int
        """

        _attribute_map = {
            'base_ip_address': {'key': 'baseIpAddress', 'type': 'str'},
            'prefix_length': {'key': 'prefixLength', 'type': 'int'},
        }

        def __init__(self, *, base_ip_address: str=None, prefix_length: int=None, **kwargs) -> None:
            super(CidrIpAddress, self).__init__(**kwargs)
            self.base_ip_address = base_ip_address
            self.prefix_length = prefix_length

    class CloudError(Model):
        """CloudError.
        """

        _attribute_map = {
        }

    class CookiesMatchConditionParameters(Model):
        """Defines the parameters for Cookies match conditions.

        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 odatatype: Required.  Default value:
         "#Microsoft.Azure.Cdn.Models.DeliveryRuleCookiesConditionParameters" .
        :vartype odatatype: str
        :param selector: Required. Name of Cookies to be matched
        :type selector: str
        :param operator: Required. Describes operator to be matched. Possible
         values include: 'Any', 'Equal', 'Contains', 'BeginsWith', 'EndsWith',
         'LessThan', 'LessThanOrEqual', 'GreaterThan', 'GreaterThanOrEqual'
        :type operator: str or ~azure.mgmt.cdn.models.CookiesOperator
        :param negate_condition: Describes if this is negate condition or not
        :type negate_condition: bool
        :param match_values: Required. The match value for the condition of the
         delivery rule
        :type match_values: list[str]
        :param transforms: List of transforms
        :type transforms: list[str or ~azure.mgmt.cdn.models.Transform]
        """

        _validation = {
            'odatatype': {'required': True, 'constant': True},
            'selector': {'required': True},
            'operator': {'required': True},
            'match_values': {'required': True},
        }

        _attribute_map = {
            'odatatype': {'key': '@odata\\.type', 'type': 'str'},
            'selector': {'key': 'selector', 'type': 'str'},
            'operator': {'key': 'operator', 'type': 'str'},
            'negate_condition': {'key': 'negateCondition', 'type': 'bool'},
            'match_values': {'key': 'matchValues', 'type': '[str]'},
            'transforms': {'key': 'transforms', 'type': '[str]'},
        }

        odatatype = "#Microsoft.Azure.Cdn.Models.DeliveryRuleCookiesConditionParameters"

        def __init__(self, *, selector: str, operator, match_values, negate_condition: bool=None, transforms=None, **kwargs) -> None:
            super(CookiesMatchConditionParameters, self).__init__(**kwargs)
            self.selector = selector
            self.operator = operator
            self.negate_condition = negate_condition
            self.match_values = match_values
            self.transforms = transforms

    class ProxyResource(Resource):
        """The resource model definition for a ARM proxy resource. It will have
        everything other than required location and tags.

        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.
        :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(ProxyResource, self).__init__(**kwargs)

    class CustomDomain(ProxyResource):
        """Friendly domain name mapping to the endpoint hostname that the customer
        provides for branding purposes, e.g. www.contoso.com.

        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.
        :vartype type: str
        :param host_name: Required. The host name of the custom domain. Must be a
         domain name.
        :type host_name: str
        :ivar resource_state: Resource status of the custom domain. Possible
         values include: 'Creating', 'Active', 'Deleting'
        :vartype resource_state: str or
         ~azure.mgmt.cdn.models.CustomDomainResourceState
        :ivar custom_https_provisioning_state: Provisioning status of Custom Https
         of the custom domain. Possible values include: 'Enabling', 'Enabled',
         'Disabling', 'Disabled', 'Failed'
        :vartype custom_https_provisioning_state: str or
         ~azure.mgmt.cdn.models.CustomHttpsProvisioningState
        :ivar custom_https_provisioning_substate: Provisioning substate shows the
         progress of custom HTTPS enabling/disabling process step by step. Possible
         values include: 'SubmittingDomainControlValidationRequest',
         'PendingDomainControlValidationREquestApproval',
         'DomainControlValidationRequestApproved',
         'DomainControlValidationRequestRejected',
         'DomainControlValidationRequestTimedOut', 'IssuingCertificate',
         'DeployingCertificate', 'CertificateDeployed', 'DeletingCertificate',
         'CertificateDeleted'
        :vartype custom_https_provisioning_substate: str or
         ~azure.mgmt.cdn.models.CustomHttpsProvisioningSubstate
        :param custom_https_parameters: Certificate parameters for securing custom
         HTTPS
        :type custom_https_parameters:
         ~azure.mgmt.cdn.models.CustomDomainHttpsParameters
        :param validation_data: Special validation or data may be required when
         delivering CDN to some regions due to local compliance reasons. E.g. ICP
         license number of a custom domain is required to deliver content in China.
        :type validation_data: str
        :ivar provisioning_state: Provisioning status of the custom domain.
        :vartype provisioning_state: str
        """

        _validation = {
            'id': {'readonly': True},
            'name': {'readonly': True},
            'type': {'readonly': True},
            'host_name': {'required': True},
            'resource_state': {'readonly': True},
            'custom_https_provisioning_state': {'readonly': True},
            'custom_https_provisioning_substate': {'readonly': True},
            'provisioning_state': {'readonly': True},
        }

        _attribute_map = {
            'id': {'key': 'id', 'type': 'str'},
            'name': {'key': 'name', 'type': 'str'},
            'type': {'key': 'type', 'type': 'str'},
            'host_name': {'key': 'properties.hostName', 'type': 'str'},
            'resource_state': {'key': 'properties.resourceState', 'type': 'str'},
            'custom_https_provisioning_state': {'key': 'properties.customHttpsProvisioningState', 'type': 'str'},
            'custom_https_provisioning_substate': {'key': 'properties.customHttpsProvisioningSubstate', 'type': 'str'},
            'custom_https_parameters': {'key': 'properties.customHttpsParameters', 'type': 'CustomDomainHttpsParameters'},
            'validation_data': {'key': 'properties.validationData', 'type': 'str'},
            'provisioning_state': {'key': 'properties.provisioningState', 'type': 'str'},
        }

        def __init__(self, *, host_name: str, custom_https_parameters=None, validation_data: str=None, **kwargs) -> None:
            super(CustomDomain, self).__init__(**kwargs)
            self.host_name = host_name
            self.resource_state = None
            self.custom_https_provisioning_state = None
            self.custom_https_provisioning_substate = None
            self.custom_https_parameters = custom_https_parameters
            self.validation_data = validation_data
            self.provisioning_state = None

    class CustomDomainParameters(Model):
        """The customDomain JSON object required for custom domain creation or update.

        All required parameters must be populated in order to send to Azure.

        :param host_name: Required. The host name of the custom domain. Must be a
         domain name.
        :type host_name: str
        """

        _validation = {
            'host_name': {'required': True},
        }

        _attribute_map = {
            'host_name': {'key': 'properties.hostName', 'type': 'str'},
        }

        def __init__(self, *, host_name: str, **kwargs) -> None:
            super(CustomDomainParameters, self).__init__(**kwargs)
            self.host_name = host_name

    class CustomRule(Model):
        """Defines the common attributes for a custom rule that can be included in a
        waf policy.

        All required parameters must be populated in order to send to Azure.

        :param name: Required. Defines the name of the custom rule
        :type name: str
        :param enabled_state: Describes if the custom rule is in enabled or
         disabled state. Defaults to Enabled if not specified. Possible values
         include: 'Disabled', 'Enabled'
        :type enabled_state: str or ~azure.mgmt.cdn.models.CustomRuleEnabledState
        :param priority: Required. Defines in what order this rule be evaluated in
         the overall list of custom rules
        :type priority: int
        :param match_conditions: Required. List of match conditions.
        :type match_conditions: list[~azure.mgmt.cdn.models.MatchCondition]
        :param action: Required. Describes what action to be applied when rule
         matches. Possible values include: 'Allow', 'Block', 'Log', 'Redirect'
        :type action: str or ~azure.mgmt.cdn.models.ActionType
        """

        _validation = {
            'name': {'required': True},
            'priority': {'required': True, 'maximum': 1000, 'minimum': 0},
            'match_conditions': {'required': True},
            'action': {'required': True},
        }

        _attribute_map = {
            'name': {'key': 'name', 'type': 'str'},
            'enabled_state': {'key': 'enabledState', 'type': 'str'},
            'priority': {'key': 'priority', 'type': 'int'},
            'match_conditions': {'key': 'matchConditions', 'type': '[MatchCondition]'},
            'action': {'key': 'action', 'type': 'str'},
        }

        def __init__(self, *, name: str, priority: int, match_conditions, action, enabled_state=None, **kwargs) -> None:
            super(CustomRule, self).__init__(**kwargs)
            self.name = name
            self.enabled_state = enabled_state
            self.priority = priority
            self.match_conditions = match_conditions
            self.action = action

    class CustomRuleList(Model):
        """Defines contents of custom rules.

        :param rules: List of rules
        :type rules: list[~azure.mgmt.cdn.models.CustomRule]
        """

        _attribute_map = {
            'rules': {'key': 'rules', 'type': '[CustomRule]'},
        }

        def __init__(self, *, rules=None, **kwargs) -> None:
            super(CustomRuleList, self).__init__(**kwargs)
            self.rules = rules

    class DeepCreatedOrigin(Model):
        """The main origin of CDN content which is added when creating a CDN endpoint.

        All required parameters must be populated in order to send to Azure.

        :param name: Required. Origin name
        :type name: str
        :param host_name: Required. The address of the origin. It can be a domain
         name, IPv4 address, or IPv6 address.
        :type host_name: str
        :param http_port: The value of the HTTP port. Must be between 1 and 65535
        :type http_port: int
        :param https_port: The value of the HTTPS port. Must be between 1 and
         65535
        :type https_port: int
        """

        _validation = {
            'name': {'required': True},
            'host_name': {'required': True},
            'http_port': {'maximum': 65535, 'minimum': 1},
            'https_port': {'maximum': 65535, 'minimum': 1},
        }

        _attribute_map = {
            'name': {'key': 'name', 'type': 'str'},
            'host_name': {'key': 'properties.hostName', 'type': 'str'},
            'http_port': {'key': 'properties.httpPort', 'type': 'int'},
            'https_port': {'key': 'properties.httpsPort', 'type': 'int'},
        }

        def __init__(self, *, name: str, host_name: str, http_port: int=None, https_port: int=None, **kwargs) -> None:
            super(DeepCreatedOrigin, self).__init__(**kwargs)
            self.name = name
            self.host_name = host_name
            self.http_port = http_port
            self.https_port = https_port

    class DeliveryRule(Model):
        """A rule that specifies a set of actions and conditions.

        All required parameters must be populated in order to send to Azure.

        :param name: Name of the rule
        :type name: str
        :param order: Required. The order in which the rules are applied for the
         endpoint. Possible values {0,1,2,3,………}. A rule with a lesser order will
         be applied before a rule with a greater order. Rule with order 0 is a
         special rule. It does not require any condition and actions listed in it
         will always be applied.
        :type order: int
        :param conditions: A list of conditions that must be matched for the
         actions to be executed
        :type conditions: list[~azure.mgmt.cdn.models.DeliveryRuleCondition]
        :param actions: Required. A list of actions that are executed when all the
         conditions of a rule are satisfied.
        :type actions: list[~azure.mgmt.cdn.models.DeliveryRuleAction]
        """

        _validation = {
            'order': {'required': True},
            'actions': {'required': True},
        }

        _attribute_map = {
            'name': {'key': 'name', 'type': 'str'},
            'order': {'key': 'order', 'type': 'int'},
            'conditions': {'key': 'conditions', 'type': '[DeliveryRuleCondition]'},
            'actions': {'key': 'actions', 'type': '[DeliveryRuleAction]'},
        }

        def __init__(self, *, order: int, actions, name: str=None, conditions=None, **kwargs) -> None:
            super(DeliveryRule, self).__init__(**kwargs)
            self.name = name
            self.order = order
            self.conditions = conditions
            self.actions = actions

    class DeliveryRuleAction(Model):
        """An action for the delivery rule.

        You probably want to use the sub-classes and not this class directly. Known
        sub-classes are: UrlRedirectAction, UrlRewriteAction,
        DeliveryRuleRequestHeaderAction, DeliveryRuleResponseHeaderAction,
        DeliveryRuleCacheExpirationAction, DeliveryRuleCacheKeyQueryStringAction

        All required parameters must be populated in order to send to Azure.

        :param name: Required. Constant filled by server.
        :type name: str
        """

        _validation = {
            'name': {'required': True},
        }

        _attribute_map = {
            'name': {'key': 'name', 'type': 'str'},
        }

        _subtype_map = {
            'name': {'UrlRedirect': 'UrlRedirectAction', 'UrlRewrite': 'UrlRewriteAction', 'ModifyRequestHeader': 'DeliveryRuleRequestHeaderAction', 'ModifyResponseHeader': 'DeliveryRuleResponseHeaderAction', 'CacheExpiration': 'DeliveryRuleCacheExpirationAction', 'CacheKeyQueryString': 'DeliveryRuleCacheKeyQueryStringAction'}
        }

        def __init__(self, **kwargs) -> None:
            super(DeliveryRuleAction, self).__init__(**kwargs)
            self.name = None

    class DeliveryRuleCacheExpirationAction(DeliveryRuleAction):
        """Defines the cache expiration action for the delivery rule.

        All required parameters must be populated in order to send to Azure.

        :param name: Required. Constant filled by server.
        :type name: str
        :param parameters: Required. Defines the parameters for the action.
        :type parameters: ~azure.mgmt.cdn.models.CacheExpirationActionParameters
        """

        _validation = {
            'name': {'required': True},
            'parameters': {'required': True},
        }

        _attribute_map = {
            'name': {'key': 'name', 'type': 'str'},
            'parameters': {'key': 'parameters', 'type': 'CacheExpirationActionParameters'},
        }

        def __init__(self, *, parameters, **kwargs) -> None:
            super(DeliveryRuleCacheExpirationAction, self).__init__(**kwargs)
            self.parameters = parameters
            self.name = 'CacheExpiration'

    class DeliveryRuleCacheKeyQueryStringAction(DeliveryRuleAction):
        """Defines the cache-key query string action for the delivery rule.

        All required parameters must be populated in order to send to Azure.

        :param name: Required. Constant filled by server.
        :type name: str
        :param parameters: Required. Defines the parameters for the action.
        :type parameters:
         ~azure.mgmt.cdn.models.CacheKeyQueryStringActionParameters
        """

        _validation = {
            'name': {'required': True},
            'parameters': {'required': True},
        }

        _attribute_map = {
            'name': {'key': 'name', 'type': 'str'},
            'parameters': {'key': 'parameters', 'type': 'CacheKeyQueryStringActionParameters'},
        }

        def __init__(self, *, parameters, **kwargs) -> None:
            super(DeliveryRuleCacheKeyQueryStringAction, self).__init__(**kwargs)
            self.parameters = parameters
            self.name = 'CacheKeyQueryString'

    class DeliveryRuleCondition(Model):
        """A condition for the delivery rule.

        You probably want to use the sub-classes and not this class directly. Known
        sub-classes are: DeliveryRuleRemoteAddressCondition,
        DeliveryRuleRequestMethodCondition, DeliveryRuleQueryStringCondition,
        DeliveryRulePostArgsCondition, DeliveryRuleRequestUriCondition,
        DeliveryRuleRequestHeaderCondition, DeliveryRuleRequestBodyCondition,
        DeliveryRuleRequestSchemeCondition, DeliveryRuleUrlPathCondition,
        DeliveryRuleUrlFileExtensionCondition, DeliveryRuleUrlFileNameCondition,
        DeliveryRuleHttpVersionCondition, DeliveryRuleCookiesCondition,
        DeliveryRuleIsDeviceCondition

        All required parameters must be populated in order to send to Azure.

        :param name: Required. Constant filled by server.
        :type name: str
        """

        _validation = {
            'name': {'required': True},
        }

        _attribute_map = {
            'name': {'key': 'name', 'type': 'str'},
        }

        _subtype_map = {
            'name': {'RemoteAddress': 'DeliveryRuleRemoteAddressCondition', 'RequestMethod': 'DeliveryRuleRequestMethodCondition', 'QueryString': 'DeliveryRuleQueryStringCondition', 'PostArgs': 'DeliveryRulePostArgsCondition', 'RequestUri': 'DeliveryRuleRequestUriCondition', 'RequestHeader': 'DeliveryRuleRequestHeaderCondition', 'RequestBody': 'DeliveryRuleRequestBodyCondition', 'RequestScheme': 'DeliveryRuleRequestSchemeCondition', 'UrlPath': 'DeliveryRuleUrlPathCondition', 'UrlFileExtension': 'DeliveryRuleUrlFileExtensionCondition', 'UrlFileName': 'DeliveryRuleUrlFileNameCondition', 'HttpVersion': 'DeliveryRuleHttpVersionCondition', 'Cookies': 'DeliveryRuleCookiesCondition', 'IsDevice': 'DeliveryRuleIsDeviceCondition'}
        }

        def __init__(self, **kwargs) -> None:
            super(DeliveryRuleCondition, self).__init__(**kwargs)
            self.name = None

    class DeliveryRuleCookiesCondition(DeliveryRuleCondition):
        """Defines the Cookies condition for the delivery rule.

        All required parameters must be populated in order to send to Azure.

        :param name: Required. Constant filled by server.
        :type name: str
        :param parameters: Required. Defines the parameters for the condition.
        :type parameters: ~azure.mgmt.cdn.models.CookiesMatchConditionParameters
        """

        _validation = {
            'name': {'required': True},
            'parameters': {'required': True},
        }

        _attribute_map = {
            'name': {'key': 'name', 'type': 'str'},
            'parameters': {'key': 'parameters', 'type': 'CookiesMatchConditionParameters'},
        }

        def __init__(self, *, parameters, **kwargs) -> None:
            super(DeliveryRuleCookiesCondition, self).__init__(**kwargs)
            self.parameters = parameters
            self.name = 'Cookies'

    class DeliveryRuleHttpVersionCondition(DeliveryRuleCondition):
        """Defines the HttpVersion condition for the delivery rule.

        All required parameters must be populated in order to send to Azure.

        :param name: Required. Constant filled by server.
        :type name: str
        :param parameters: Required. Defines the parameters for the condition.
        :type parameters:
         ~azure.mgmt.cdn.models.HttpVersionMatchConditionParameters
        """

        _validation = {
            'name': {'required': True},
            'parameters': {'required': True},
        }

        _attribute_map = {
            'name': {'key': 'name', 'type': 'str'},
            'parameters': {'key': 'parameters', 'type': 'HttpVersionMatchConditionParameters'},
        }

        def __init__(self, *, parameters, **kwargs) -> None:
            super(DeliveryRuleHttpVersionCondition, self).__init__(**kwargs)
            self.parameters = parameters
            self.name = 'HttpVersion'

    class DeliveryRuleIsDeviceCondition(DeliveryRuleCondition):
        """Defines the IsDevice condition for the delivery rule.

        All required parameters must be populated in order to send to Azure.

        :param name: Required. Constant filled by server.
        :type name: str
        :param parameters: Required. Defines the parameters for the condition.
        :type parameters: ~azure.mgmt.cdn.models.IsDeviceMatchConditionParameters
        """

        _validation = {
            'name': {'required': True},
            'parameters': {'required': True},
        }

        _attribute_map = {
            'name': {'key': 'name', 'type': 'str'},
            'parameters': {'key': 'parameters', 'type': 'IsDeviceMatchConditionParameters'},
        }

        def __init__(self, *, parameters, **kwargs) -> None:
            super(DeliveryRuleIsDeviceCondition, self).__init__(**kwargs)
            self.parameters = parameters
            self.name = 'IsDevice'

    class DeliveryRulePostArgsCondition(DeliveryRuleCondition):
        """Defines the PostArgs condition for the delivery rule.

        All required parameters must be populated in order to send to Azure.

        :param name: Required. Constant filled by server.
        :type name: str
        :param parameters: Required. Defines the parameters for the condition.
        :type parameters: ~azure.mgmt.cdn.models.PostArgsMatchConditionParameters
        """

        _validation = {
            'name': {'required': True},
            'parameters': {'required': True},
        }

        _attribute_map = {
            'name': {'key': 'name', 'type': 'str'},
            'parameters': {'key': 'parameters', 'type': 'PostArgsMatchConditionParameters'},
        }

        def __init__(self, *, parameters, **kwargs) -> None:
            super(DeliveryRulePostArgsCondition, self).__init__(**kwargs)
            self.parameters = parameters
            self.name = 'PostArgs'

    class DeliveryRuleQueryStringCondition(DeliveryRuleCondition):
        """Defines the QueryString condition for the delivery rule.

        All required parameters must be populated in order to send to Azure.

        :param name: Required. Constant filled by server.
        :type name: str
        :param parameters: Required. Defines the parameters for the condition.
        :type parameters:
         ~azure.mgmt.cdn.models.QueryStringMatchConditionParameters
        """

        _validation = {
            'name': {'required': True},
            'parameters': {'required': True},
        }

        _attribute_map = {
            'name': {'key': 'name', 'type': 'str'},
            'parameters': {'key': 'parameters', 'type': 'QueryStringMatchConditionParameters'},
        }

        def __init__(self, *, parameters, **kwargs) -> None:
            super(DeliveryRuleQueryStringCondition, self).__init__(**kwargs)
            self.parameters = parameters
            self.name = 'QueryString'

    class DeliveryRuleRemoteAddressCondition(DeliveryRuleCondition):
        """Defines the RemoteAddress condition for the delivery rule.

        All required parameters must be populated in order to send to Azure.

        :param name: Required. Constant filled by server.
        :type name: str
        :param parameters: Required. Defines the parameters for the condition.
        :type parameters:
         ~azure.mgmt.cdn.models.RemoteAddressMatchConditionParameters
        """

        _validation = {
            'name': {'required': True},
            'parameters': {'required': True},
        }

        _attribute_map = {
            'name': {'key': 'name', 'type': 'str'},
            'parameters': {'key': 'parameters', 'type': 'RemoteAddressMatchConditionParameters'},
        }

        def __init__(self, *, parameters, **kwargs) -> None:
            super(DeliveryRuleRemoteAddressCondition, self).__init__(**kwargs)
            self.parameters = parameters
            self.name = 'RemoteAddress'

    class DeliveryRuleRequestBodyCondition(DeliveryRuleCondition):
        """Defines the RequestBody condition for the delivery rule.

        All required parameters must be populated in order to send to Azure.

        :param name: Required. Constant filled by server.
        :type name: str
        :param parameters: Required. Defines the parameters for the condition.
        :type parameters:
         ~azure.mgmt.cdn.models.RequestBodyMatchConditionParameters
        """

        _validation = {
            'name': {'required': True},
            'parameters': {'required': True},
        }

        _attribute_map = {
            'name': {'key': 'name', 'type': 'str'},
            'parameters': {'key': 'parameters', 'type': 'RequestBodyMatchConditionParameters'},
        }

        def __init__(self, *, parameters, **kwargs) -> None:
            super(DeliveryRuleRequestBodyCondition, self).__init__(**kwargs)
            self.parameters = parameters
            self.name = 'RequestBody'

    class DeliveryRuleRequestHeaderAction(DeliveryRuleAction):
        """Defines the request header action for the delivery rule.

        All required parameters must be populated in order to send to Azure.

        :param name: Required. Constant filled by server.
        :type name: str
        :param parameters: Required. Defines the parameters for the action.
        :type parameters: ~azure.mgmt.cdn.models.HeaderActionParameters
        """

        _validation = {
            'name': {'required': True},
            'parameters': {'required': True},
        }

        _attribute_map = {
            'name': {'key': 'name', 'type': 'str'},
            'parameters': {'key': 'parameters', 'type': 'HeaderActionParameters'},
        }

        def __init__(self, *, parameters, **kwargs) -> None:
            super(DeliveryRuleRequestHeaderAction, self).__init__(**kwargs)
            self.parameters = parameters
            self.name = 'ModifyRequestHeader'

    class DeliveryRuleRequestHeaderCondition(DeliveryRuleCondition):
        """Defines the RequestHeader condition for the delivery rule.

        All required parameters must be populated in order to send to Azure.

        :param name: Required. Constant filled by server.
        :type name: str
        :param parameters: Required. Defines the parameters for the condition.
        :type parameters:
         ~azure.mgmt.cdn.models.RequestHeaderMatchConditionParameters
        """

        _validation = {
            'name': {'required': True},
            'parameters': {'required': True},
        }

        _attribute_map = {
            'name': {'key': 'name', 'type': 'str'},
            'parameters': {'key': 'parameters', 'type': 'RequestHeaderMatchConditionParameters'},
        }

        def __init__(self, *, parameters, **kwargs) -> None:
            super(DeliveryRuleRequestHeaderCondition, self).__init__(**kwargs)
            self.parameters = parameters
            self.name = 'RequestHeader'

    class DeliveryRuleRequestMethodCondition(DeliveryRuleCondition):
        """Defines the RequestMethod condition for the delivery rule.

        All required parameters must be populated in order to send to Azure.

        :param name: Required. Constant filled by server.
        :type name: str
        :param parameters: Required. Defines the parameters for the condition.
        :type parameters:
         ~azure.mgmt.cdn.models.RequestMethodMatchConditionParameters
        """

        _validation = {
            'name': {'required': True},
            'parameters': {'required': True},
        }

        _attribute_map = {
            'name': {'key': 'name', 'type': 'str'},
            'parameters': {'key': 'parameters', 'type': 'RequestMethodMatchConditionParameters'},
        }

        def __init__(self, *, parameters, **kwargs) -> None:
            super(DeliveryRuleRequestMethodCondition, self).__init__(**kwargs)
            self.parameters = parameters
            self.name = 'RequestMethod'

    class DeliveryRuleRequestSchemeCondition(DeliveryRuleCondition):
        """Defines the RequestScheme condition for the delivery rule.

        All required parameters must be populated in order to send to Azure.

        :param name: Required. Constant filled by server.
        :type name: str
        :param parameters: Required. Defines the parameters for the condition.
        :type parameters:
         ~azure.mgmt.cdn.models.RequestSchemeMatchConditionParameters
        """

        _validation = {
            'name': {'required': True},
            'parameters': {'required': True},
        }

        _attribute_map = {
            'name': {'key': 'name', 'type': 'str'},
            'parameters': {'key': 'parameters', 'type': 'RequestSchemeMatchConditionParameters'},
        }

        def __init__(self, *, parameters, **kwargs) -> None:
            super(DeliveryRuleRequestSchemeCondition, self).__init__(**kwargs)
            self.parameters = parameters
            self.name = 'RequestScheme'

    class DeliveryRuleRequestUriCondition(DeliveryRuleCondition):
        """Defines the RequestUri condition for the delivery rule.

        All required parameters must be populated in order to send to Azure.

        :param name: Required. Constant filled by server.
        :type name: str
        :param parameters: Required. Defines the parameters for the condition.
        :type parameters:
         ~azure.mgmt.cdn.models.RequestUriMatchConditionParameters
        """

        _validation = {
            'name': {'required': True},
            'parameters': {'required': True},
        }

        _attribute_map = {
            'name': {'key': 'name', 'type': 'str'},
            'parameters': {'key': 'parameters', 'type': 'RequestUriMatchConditionParameters'},
        }

        def __init__(self, *, parameters, **kwargs) -> None:
            super(DeliveryRuleRequestUriCondition, self).__init__(**kwargs)
            self.parameters = parameters
            self.name = 'RequestUri'

    class DeliveryRuleResponseHeaderAction(DeliveryRuleAction):
        """Defines the response header action for the delivery rule.

        All required parameters must be populated in order to send to Azure.

        :param name: Required. Constant filled by server.
        :type name: str
        :param parameters: Required. Defines the parameters for the action.
        :type parameters: ~azure.mgmt.cdn.models.HeaderActionParameters
        """

        _validation = {
            'name': {'required': True},
            'parameters': {'required': True},
        }

        _attribute_map = {
            'name': {'key': 'name', 'type': 'str'},
            'parameters': {'key': 'parameters', 'type': 'HeaderActionParameters'},
        }

        def __init__(self, *, parameters, **kwargs) -> None:
            super(DeliveryRuleResponseHeaderAction, self).__init__(**kwargs)
            self.parameters = parameters
            self.name = 'ModifyResponseHeader'

    class DeliveryRuleUrlFileExtensionCondition(DeliveryRuleCondition):
        """Defines the UrlFileExtension condition for the delivery rule.

        All required parameters must be populated in order to send to Azure.

        :param name: Required. Constant filled by server.
        :type name: str
        :param parameters: Required. Defines the parameters for the condition.
        :type parameters:
         ~azure.mgmt.cdn.models.UrlFileExtensionMatchConditionParameters
        """

        _validation = {
            'name': {'required': True},
            'parameters': {'required': True},
        }

        _attribute_map = {
            'name': {'key': 'name', 'type': 'str'},
            'parameters': {'key': 'parameters', 'type': 'UrlFileExtensionMatchConditionParameters'},
        }

        def __init__(self, *, parameters, **kwargs) -> None:
            super(DeliveryRuleUrlFileExtensionCondition, self).__init__(**kwargs)
            self.parameters = parameters
            self.name = 'UrlFileExtension'

    class DeliveryRuleUrlFileNameCondition(DeliveryRuleCondition):
        """Defines the UrlFileName condition for the delivery rule.

        All required parameters must be populated in order to send to Azure.

        :param name: Required. Constant filled by server.
        :type name: str
        :param parameters: Required. Defines the parameters for the condition.
        :type parameters:
         ~azure.mgmt.cdn.models.UrlFileNameMatchConditionParameters
        """

        _validation = {
            'name': {'required': True},
            'parameters': {'required': True},
        }

        _attribute_map = {
            'name': {'key': 'name', 'type': 'str'},
            'parameters': {'key': 'parameters', 'type': 'UrlFileNameMatchConditionParameters'},
        }

        def __init__(self, *, parameters, **kwargs) -> None:
            super(DeliveryRuleUrlFileNameCondition, self).__init__(**kwargs)
            self.parameters = parameters
            self.name = 'UrlFileName'

    class DeliveryRuleUrlPathCondition(DeliveryRuleCondition):
        """Defines the UrlPath condition for the delivery rule.

        All required parameters must be populated in order to send to Azure.

        :param name: Required. Constant filled by server.
        :type name: str
        :param parameters: Required. Defines the parameters for the condition.
        :type parameters: ~azure.mgmt.cdn.models.UrlPathMatchConditionParameters
        """

        _validation = {
            'name': {'required': True},
            'parameters': {'required': True},
        }

        _attribute_map = {
            'name': {'key': 'name', 'type': 'str'},
            'parameters': {'key': 'parameters', 'type': 'UrlPathMatchConditionParameters'},
        }

        def __init__(self, *, parameters, **kwargs) -> None:
            super(DeliveryRuleUrlPathCondition, self).__init__(**kwargs)
            self.parameters = parameters
            self.name = 'UrlPath'

    class EdgeNode(ProxyResource):
        """Edgenode is a global Point of Presence (POP) location used to deliver CDN
        content to end users.

        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.
        :vartype type: str
        :param ip_address_groups: Required. List of ip address groups.
        :type ip_address_groups: list[~azure.mgmt.cdn.models.IpAddressGroup]
        """

        _validation = {
            'id': {'readonly': True},
            'name': {'readonly': True},
            'type': {'readonly': True},
            'ip_address_groups': {'required': True},
        }

        _attribute_map = {
            'id': {'key': 'id', 'type': 'str'},
            'name': {'key': 'name', 'type': 'str'},
            'type': {'key': 'type', 'type': 'str'},
            'ip_address_groups': {'key': 'properties.ipAddressGroups', 'type': '[IpAddressGroup]'},
        }

        def __init__(self, *, ip_address_groups, **kwargs) -> None:
            super(EdgeNode, self).__init__(**kwargs)
            self.ip_address_groups = ip_address_groups

    class Endpoint(TrackedResource):
        """CDN endpoint is the entity within a CDN profile containing configuration
        information such as origin, protocol, content caching and delivery
        behavior. The CDN endpoint uses the URL format
        <endpointname>.azureedge.net.

        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.
        :vartype type: str
        :param location: Required. Resource location.
        :type location: str
        :param tags: Resource tags.
        :type tags: dict[str, str]
        :param origin_host_header: The host header value sent to the origin with
         each request. If you leave this blank, the request hostname determines
         this value. Azure CDN origins, such as Web Apps, Blob Storage, and Cloud
         Services require this host header value to match the origin hostname by
         default.
        :type origin_host_header: str
        :param origin_path: A directory path on the origin that CDN can use to
         retrieve content from, e.g. contoso.cloudapp.net/originpath.
        :type origin_path: str
        :param content_types_to_compress: List of content types on which
         compression applies. The value should be a valid MIME type.
        :type content_types_to_compress: list[str]
        :param is_compression_enabled: Indicates whether content compression is
         enabled on CDN. Default value is false. If compression is enabled, content
         will be served as compressed if user requests for a compressed version.
         Content won't be compressed on CDN when requested content is smaller than
         1 byte or larger than 1 MB.
        :type is_compression_enabled: bool
        :param is_http_allowed: Indicates whether HTTP traffic is allowed on the
         endpoint. Default value is true. At least one protocol (HTTP or HTTPS)
         must be allowed.
        :type is_http_allowed: bool
        :param is_https_allowed: Indicates whether HTTPS traffic is allowed on the
         endpoint. Default value is true. At least one protocol (HTTP or HTTPS)
         must be allowed.
        :type is_https_allowed: bool
        :param query_string_caching_behavior: Defines how CDN caches requests that
         include query strings. You can ignore any query strings when caching,
         bypass caching to prevent requests that contain query strings from being
         cached, or cache every request with a unique URL. Possible values include:
         'IgnoreQueryString', 'BypassCaching', 'UseQueryString', 'NotSet'
        :type query_string_caching_behavior: str or
         ~azure.mgmt.cdn.models.QueryStringCachingBehavior
        :param optimization_type: Specifies what scenario the customer wants this
         CDN endpoint to optimize for, e.g. Download, Media services. With this
         information, CDN can apply scenario driven optimization. Possible values
         include: 'GeneralWebDelivery', 'GeneralMediaStreaming',
         'VideoOnDemandMediaStreaming', 'LargeFileDownload',
         'DynamicSiteAcceleration'
        :type optimization_type: str or ~azure.mgmt.cdn.models.OptimizationType
        :param probe_path: Path to a file hosted on the origin which helps
         accelerate delivery of the dynamic content and calculate the most optimal
         routes for the CDN. This is relative to the origin path.
        :type probe_path: str
        :param geo_filters: List of rules defining the user's geo access within a
         CDN endpoint. Each geo filter defines an access rule to a specified path
         or content, e.g. block APAC for path /pictures/
        :type geo_filters: list[~azure.mgmt.cdn.models.GeoFilter]
        :param delivery_policy: A policy that specifies the delivery rules to be
         used for an endpoint.
        :type delivery_policy:
         ~azure.mgmt.cdn.models.EndpointPropertiesUpdateParametersDeliveryPolicy
        :param web_application_firewall_policy_link: Defines the Web Application
         Firewall policy for the endpoint (if applicable)
        :type web_application_firewall_policy_link:
         ~azure.mgmt.cdn.models.EndpointPropertiesUpdateParametersWebApplicationFirewallPolicyLink
        :ivar host_name: The host name of the endpoint structured as
         {endpointName}.{DNSZone}, e.g. contoso.azureedge.net
        :vartype host_name: str
        :param origins: Required. The source of the content being delivered via
         CDN.
        :type origins: list[~azure.mgmt.cdn.models.DeepCreatedOrigin]
        :ivar resource_state: Resource status of the endpoint. Possible values
         include: 'Creating', 'Deleting', 'Running', 'Starting', 'Stopped',
         'Stopping'
        :vartype resource_state: str or
         ~azure.mgmt.cdn.models.EndpointResourceState
        :ivar provisioning_state: Provisioning status of the endpoint.
        :vartype provisioning_state: str
        """

        _validation = {
            'id': {'readonly': True},
            'name': {'readonly': True},
            'type': {'readonly': True},
            'location': {'required': True},
            'host_name': {'readonly': True},
            'origins': {'required': True},
            'resource_state': {'readonly': True},
            'provisioning_state': {'readonly': True},
        }

        _attribute_map = {
            'id': {'key': 'id', 'type': 'str'},
            'name': {'key': 'name', 'type': 'str'},
            'type': {'key': 'type', 'type': 'str'},
            'location': {'key': 'location', 'type': 'str'},
            'tags': {'key': 'tags', 'type': '{str}'},
            'origin_host_header': {'key': 'properties.originHostHeader', 'type': 'str'},
            'origin_path': {'key': 'properties.originPath', 'type': 'str'},
            'content_types_to_compress': {'key': 'properties.contentTypesToCompress', 'type': '[str]'},
            'is_compression_enabled': {'key': 'properties.isCompressionEnabled', 'type': 'bool'},
            'is_http_allowed': {'key': 'properties.isHttpAllowed', 'type': 'bool'},
            'is_https_allowed': {'key': 'properties.isHttpsAllowed', 'type': 'bool'},
            'query_string_caching_behavior': {'key': 'properties.queryStringCachingBehavior', 'type': 'QueryStringCachingBehavior'},
            'optimization_type': {'key': 'properties.optimizationType', 'type': 'str'},
            'probe_path': {'key': 'properties.probePath', 'type': 'str'},
            'geo_filters': {'key': 'properties.geoFilters', 'type': '[GeoFilter]'},
            'delivery_policy': {'key': 'properties.deliveryPolicy', 'type': 'EndpointPropertiesUpdateParametersDeliveryPolicy'},
            'web_application_firewall_policy_link': {'key': 'properties.webApplicationFirewallPolicyLink', 'type': 'EndpointPropertiesUpdateParametersWebApplicationFirewallPolicyLink'},
            'host_name': {'key': 'properties.hostName', 'type': 'str'},
            'origins': {'key': 'properties.origins', 'type': '[DeepCreatedOrigin]'},
            'resource_state': {'key': 'properties.resourceState', 'type': 'str'},
            'provisioning_state': {'key': 'properties.provisioningState', 'type': 'str'},
        }

        def __init__(self, *, location: str, origins, tags=None, origin_host_header: str=None, origin_path: str=None, content_types_to_compress=None, is_compression_enabled: bool=None, is_http_allowed: bool=None, is_https_allowed: bool=None, query_string_caching_behavior=None, optimization_type=None, probe_path: str=None, geo_filters=None, delivery_policy=None, web_application_firewall_policy_link=None, **kwargs) -> None:
            super(Endpoint, self).__init__(location=location, tags=tags, **kwargs)
            self.origin_host_header = origin_host_header
            self.origin_path = origin_path
            self.content_types_to_compress = content_types_to_compress
            self.is_compression_enabled = is_compression_enabled
            self.is_http_allowed = is_http_allowed
            self.is_https_allowed = is_https_allowed
            self.query_string_caching_behavior = query_string_caching_behavior
            self.optimization_type = optimization_type
            self.probe_path = probe_path
            self.geo_filters = geo_filters
            self.delivery_policy = delivery_policy
            self.web_application_firewall_policy_link = web_application_firewall_policy_link
            self.host_name = None
            self.origins = origins
            self.resource_state = None
            self.provisioning_state = None

    class EndpointPropertiesUpdateParametersDeliveryPolicy(Model):
        """A policy that specifies the delivery rules to be used for an endpoint.

        All required parameters must be populated in order to send to Azure.

        :param description: User-friendly description of the policy.
        :type description: str
        :param rules: Required. A list of the delivery rules.
        :type rules: list[~azure.mgmt.cdn.models.DeliveryRule]
        """

        _validation = {
            'rules': {'required': True},
        }

        _attribute_map = {
            'description': {'key': 'description', 'type': 'str'},
            'rules': {'key': 'rules', 'type': '[DeliveryRule]'},
        }

        def __init__(self, *, rules, description: str=None, **kwargs) -> None:
            super(EndpointPropertiesUpdateParametersDeliveryPolicy, self).__init__(**kwargs)
            self.description = description
            self.rules = rules

    class EndpointPropertiesUpdateParametersWebApplicationFirewallPolicyLink(Model):
        """Defines the Web Application Firewall policy for the endpoint (if
        applicable).

        :param id: Resource ID.
        :type id: str
        """

        _attribute_map = {
            'id': {'key': 'id', 'type': 'str'},
        }

        def __init__(self, *, id: str=None, **kwargs) -> None:
            super(EndpointPropertiesUpdateParametersWebApplicationFirewallPolicyLink, self).__init__(**kwargs)
            self.id = id

    class EndpointUpdateParameters(Model):
        """Properties required to create or update an endpoint.

        :param tags: Endpoint tags.
        :type tags: dict[str, str]
        :param origin_host_header: The host header value sent to the origin with
         each request. If you leave this blank, the request hostname determines
         this value. Azure CDN origins, such as Web Apps, Blob Storage, and Cloud
         Services require this host header value to match the origin hostname by
         default.
        :type origin_host_header: str
        :param origin_path: A directory path on the origin that CDN can use to
         retrieve content from, e.g. contoso.cloudapp.net/originpath.
        :type origin_path: str
        :param content_types_to_compress: List of content types on which
         compression applies. The value should be a valid MIME type.
        :type content_types_to_compress: list[str]
        :param is_compression_enabled: Indicates whether content compression is
         enabled on CDN. Default value is false. If compression is enabled, content
         will be served as compressed if user requests for a compressed version.
         Content won't be compressed on CDN when requested content is smaller than
         1 byte or larger than 1 MB.
        :type is_compression_enabled: bool
        :param is_http_allowed: Indicates whether HTTP traffic is allowed on the
         endpoint. Default value is true. At least one protocol (HTTP or HTTPS)
         must be allowed.
        :type is_http_allowed: bool
        :param is_https_allowed: Indicates whether HTTPS traffic is allowed on the
         endpoint. Default value is true. At least one protocol (HTTP or HTTPS)
         must be allowed.
        :type is_https_allowed: bool
        :param query_string_caching_behavior: Defines how CDN caches requests that
         include query strings. You can ignore any query strings when caching,
         bypass caching to prevent requests that contain query strings from being
         cached, or cache every request with a unique URL. Possible values include:
         'IgnoreQueryString', 'BypassCaching', 'UseQueryString', 'NotSet'
        :type query_string_caching_behavior: str or
         ~azure.mgmt.cdn.models.QueryStringCachingBehavior
        :param optimization_type: Specifies what scenario the customer wants this
         CDN endpoint to optimize for, e.g. Download, Media services. With this
         information, CDN can apply scenario driven optimization. Possible values
         include: 'GeneralWebDelivery', 'GeneralMediaStreaming',
         'VideoOnDemandMediaStreaming', 'LargeFileDownload',
         'DynamicSiteAcceleration'
        :type optimization_type: str or ~azure.mgmt.cdn.models.OptimizationType
        :param probe_path: Path to a file hosted on the origin which helps
         accelerate delivery of the dynamic content and calculate the most optimal
         routes for the CDN. This is relative to the origin path.
        :type probe_path: str
        :param geo_filters: List of rules defining the user's geo access within a
         CDN endpoint. Each geo filter defines an access rule to a specified path
         or content, e.g. block APAC for path /pictures/
        :type geo_filters: list[~azure.mgmt.cdn.models.GeoFilter]
        :param delivery_policy: A policy that specifies the delivery rules to be
         used for an endpoint.
        :type delivery_policy:
         ~azure.mgmt.cdn.models.EndpointPropertiesUpdateParametersDeliveryPolicy
        :param web_application_firewall_policy_link: Defines the Web Application
         Firewall policy for the endpoint (if applicable)
        :type web_application_firewall_policy_link:
         ~azure.mgmt.cdn.models.EndpointPropertiesUpdateParametersWebApplicationFirewallPolicyLink
        """

        _attribute_map = {
            'tags': {'key': 'tags', 'type': '{str}'},
            'origin_host_header': {'key': 'properties.originHostHeader', 'type': 'str'},
            'origin_path': {'key': 'properties.originPath', 'type': 'str'},
            'content_types_to_compress': {'key': 'properties.contentTypesToCompress', 'type': '[str]'},
            'is_compression_enabled': {'key': 'properties.isCompressionEnabled', 'type': 'bool'},
            'is_http_allowed': {'key': 'properties.isHttpAllowed', 'type': 'bool'},
            'is_https_allowed': {'key': 'properties.isHttpsAllowed', 'type': 'bool'},
            'query_string_caching_behavior': {'key': 'properties.queryStringCachingBehavior', 'type': 'QueryStringCachingBehavior'},
            'optimization_type': {'key': 'properties.optimizationType', 'type': 'str'},
            'probe_path': {'key': 'properties.probePath', 'type': 'str'},
            'geo_filters': {'key': 'properties.geoFilters', 'type': '[GeoFilter]'},
            'delivery_policy': {'key': 'properties.deliveryPolicy', 'type': 'EndpointPropertiesUpdateParametersDeliveryPolicy'},
            'web_application_firewall_policy_link': {'key': 'properties.webApplicationFirewallPolicyLink', 'type': 'EndpointPropertiesUpdateParametersWebApplicationFirewallPolicyLink'},
        }

        def __init__(self, *, tags=None, origin_host_header: str=None, origin_path: str=None, content_types_to_compress=None, is_compression_enabled: bool=None, is_http_allowed: bool=None, is_https_allowed: bool=None, query_string_caching_behavior=None, optimization_type=None, probe_path: str=None, geo_filters=None, delivery_policy=None, web_application_firewall_policy_link=None, **kwargs) -> None:
            super(EndpointUpdateParameters, self).__init__(**kwargs)
            self.tags = tags
            self.origin_host_header = origin_host_header
            self.origin_path = origin_path
            self.content_types_to_compress = content_types_to_compress
            self.is_compression_enabled = is_compression_enabled
            self.is_http_allowed = is_http_allowed
            self.is_https_allowed = is_https_allowed
            self.query_string_caching_behavior = query_string_caching_behavior
            self.optimization_type = optimization_type
            self.probe_path = probe_path
            self.geo_filters = geo_filters
            self.delivery_policy = delivery_policy
            self.web_application_firewall_policy_link = web_application_firewall_policy_link

    class ErrorResponse(Model):
        """Error response indicates CDN service is not able to process the incoming
        request. The reason is provided in the error message.

        Variables are only populated by the server, and will be ignored when
        sending a request.

        :ivar code: Error code.
        :vartype code: str
        :ivar message: Error message indicating why the operation failed.
        :vartype message: str
        """

        _validation = {
            'code': {'readonly': True},
            'message': {'readonly': True},
        }

        _attribute_map = {
            'code': {'key': 'code', 'type': 'str'},
            'message': {'key': 'message', 'type': 'str'},
        }

        def __init__(self, **kwargs) -> None:
            super(ErrorResponse, self).__init__(**kwargs)
            self.code = None
            self.message = 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 GeoFilter(Model):
        """Rules defining user's geo access within a CDN endpoint.

        All required parameters must be populated in order to send to Azure.

        :param relative_path: Required. Relative path applicable to geo filter.
         (e.g. '/mypictures', '/mypicture/kitty.jpg', and etc.)
        :type relative_path: str
        :param action: Required. Action of the geo filter, i.e. allow or block
         access. Possible values include: 'Block', 'Allow'
        :type action: str or ~azure.mgmt.cdn.models.GeoFilterActions
        :param country_codes: Required. Two letter country codes defining user
         country access in a geo filter, e.g. AU, MX, US.
        :type country_codes: list[str]
        """

        _validation = {
            'relative_path': {'required': True},
            'action': {'required': True},
            'country_codes': {'required': True},
        }

        _attribute_map = {
            'relative_path': {'key': 'relativePath', 'type': 'str'},
            'action': {'key': 'action', 'type': 'GeoFilterActions'},
            'country_codes': {'key': 'countryCodes', 'type': '[str]'},
        }

        def __init__(self, *, relative_path: str, action, country_codes, **kwargs) -> None:
            super(GeoFilter, self).__init__(**kwargs)
            self.relative_path = relative_path
            self.action = action
            self.country_codes = country_codes

    class HeaderActionParameters(Model):
        """Defines the parameters for the request header action.

        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 odatatype: Required.  Default value:
         "#Microsoft.Azure.Cdn.Models.DeliveryRuleHeaderActionParameters" .
        :vartype odatatype: str
        :param header_action: Required. Action to perform. Possible values
         include: 'Append', 'Overwrite', 'Delete'
        :type header_action: str or ~azure.mgmt.cdn.models.HeaderAction
        :param header_name: Required. Name of the header to modify
        :type header_name: str
        :param value: Value for the specified action
        :type value: str
        """

        _validation = {
            'odatatype': {'required': True, 'constant': True},
            'header_action': {'required': True},
            'header_name': {'required': True},
        }

        _attribute_map = {
            'odatatype': {'key': '@odata\\.type', 'type': 'str'},
            'header_action': {'key': 'headerAction', 'type': 'str'},
            'header_name': {'key': 'headerName', 'type': 'str'},
            'value': {'key': 'value', 'type': 'str'},
        }

        odatatype = "#Microsoft.Azure.Cdn.Models.DeliveryRuleHeaderActionParameters"

        def __init__(self, *, header_action, header_name: str, value: str=None, **kwargs) -> None:
            super(HeaderActionParameters, self).__init__(**kwargs)
            self.header_action = header_action
            self.header_name = header_name
            self.value = value

    class HttpVersionMatchConditionParameters(Model):
        """Defines the parameters for HttpVersion match conditions.

        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 odatatype: Required.  Default value:
         "#Microsoft.Azure.Cdn.Models.DeliveryRuleHttpVersionConditionParameters" .
        :vartype odatatype: str
        :ivar operator: Required. Describes operator to be matched. Default value:
         "Equal" .
        :vartype operator: str
        :param negate_condition: Describes if this is negate condition or not
        :type negate_condition: bool
        :param match_values: Required. The match value for the condition of the
         delivery rule
        :type match_values: list[str]
        """

        _validation = {
            'odatatype': {'required': True, 'constant': True},
            'operator': {'required': True, 'constant': True},
            'match_values': {'required': True},
        }

        _attribute_map = {
            'odatatype': {'key': '@odata\\.type', 'type': 'str'},
            'operator': {'key': 'operator', 'type': 'str'},
            'negate_condition': {'key': 'negateCondition', 'type': 'bool'},
            'match_values': {'key': 'matchValues', 'type': '[str]'},
        }

        odatatype = "#Microsoft.Azure.Cdn.Models.DeliveryRuleHttpVersionConditionParameters"

        operator = "Equal"

        def __init__(self, *, match_values, negate_condition: bool=None, **kwargs) -> None:
            super(HttpVersionMatchConditionParameters, self).__init__(**kwargs)
            self.negate_condition = negate_condition
            self.match_values = match_values

    class IpAddressGroup(Model):
        """CDN Ip address group.

        :param delivery_region: The delivery region of the ip address group
        :type delivery_region: str
        :param ipv4_addresses: The list of ip v4 addresses.
        :type ipv4_addresses: list[~azure.mgmt.cdn.models.CidrIpAddress]
        :param ipv6_addresses: The list of ip v6 addresses.
        :type ipv6_addresses: list[~azure.mgmt.cdn.models.CidrIpAddress]
        """

        _attribute_map = {
            'delivery_region': {'key': 'deliveryRegion', 'type': 'str'},
            'ipv4_addresses': {'key': 'ipv4Addresses', 'type': '[CidrIpAddress]'},
            'ipv6_addresses': {'key': 'ipv6Addresses', 'type': '[CidrIpAddress]'},
        }

        def __init__(self, *, delivery_region: str=None, ipv4_addresses=None, ipv6_addresses=None, **kwargs) -> None:
            super(IpAddressGroup, self).__init__(**kwargs)
            self.delivery_region = delivery_region
            self.ipv4_addresses = ipv4_addresses
            self.ipv6_addresses = ipv6_addresses

    class IsDeviceMatchConditionParameters(Model):
        """Defines the parameters for IsDevice match conditions.

        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 odatatype: Required.  Default value:
         "#Microsoft.Azure.Cdn.Models.DeliveryRuleIsDeviceConditionParameters" .
        :vartype odatatype: str
        :ivar operator: Required. Describes operator to be matched. Default value:
         "Equal" .
        :vartype operator: str
        :param negate_condition: Describes if this is negate condition or not
        :type negate_condition: bool
        :param match_values: Required. The match value for the condition of the
         delivery rule
        :type match_values: list[str]
        :param transforms: List of transforms
        :type transforms: list[str or ~azure.mgmt.cdn.models.Transform]
        """

        _validation = {
            'odatatype': {'required': True, 'constant': True},
            'operator': {'required': True, 'constant': True},
            'match_values': {'required': True},
        }

        _attribute_map = {
            'odatatype': {'key': '@odata\\.type', 'type': 'str'},
            'operator': {'key': 'operator', 'type': 'str'},
            'negate_condition': {'key': 'negateCondition', 'type': 'bool'},
            'match_values': {'key': 'matchValues', 'type': '[str]'},
            'transforms': {'key': 'transforms', 'type': '[str]'},
        }

        odatatype = "#Microsoft.Azure.Cdn.Models.DeliveryRuleIsDeviceConditionParameters"

        operator = "Equal"

        def __init__(self, *, match_values, negate_condition: bool=None, transforms=None, **kwargs) -> None:
            super(IsDeviceMatchConditionParameters, self).__init__(**kwargs)
            self.negate_condition = negate_condition
            self.match_values = match_values
            self.transforms = transforms

    class KeyVaultCertificateSourceParameters(Model):
        """Describes the parameters for using a user's KeyVault certificate for
        securing custom domain.

        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 odatatype: Required.  Default value:
         "#Microsoft.Azure.Cdn.Models.KeyVaultCertificateSourceParameters" .
        :vartype odatatype: str
        :param subscription_id: Required. Subscription Id of the user's Key Vault
         containing the SSL certificate
        :type subscription_id: str
        :param resource_group_name: Required. Resource group of the user's Key
         Vault containing the SSL certificate
        :type resource_group_name: str
        :param vault_name: Required. The name of the user's Key Vault containing
         the SSL certificate
        :type vault_name: str
        :param secret_name: Required. The name of Key Vault Secret (representing
         the full certificate PFX) in Key Vault.
        :type secret_name: str
        :param secret_version: Required. The version(GUID) of Key Vault Secret in
         Key Vault.
        :type secret_version: str
        :ivar update_rule: Required. Describes the action that shall be taken when
         the certificate is updated in Key Vault. Default value: "NoAction" .
        :vartype update_rule: str
        :ivar delete_rule: Required. Describes the action that shall be taken when
         the certificate is removed from Key Vault. Default value: "NoAction" .
        :vartype delete_rule: str
        """

        _validation = {
            'odatatype': {'required': True, 'constant': True},
            'subscription_id': {'required': True},
            'resource_group_name': {'required': True},
            'vault_name': {'required': True},
            'secret_name': {'required': True},
            'secret_version': {'required': True},
            'update_rule': {'required': True, 'constant': True},
            'delete_rule': {'required': True, 'constant': True},
        }

        _attribute_map = {
            'odatatype': {'key': '@odata\\.type', 'type': 'str'},
            'subscription_id': {'key': 'subscriptionId', 'type': 'str'},
            'resource_group_name': {'key': 'resourceGroupName', 'type': 'str'},
            'vault_name': {'key': 'vaultName', 'type': 'str'},
            'secret_name': {'key': 'secretName', 'type': 'str'},
            'secret_version': {'key': 'secretVersion', 'type': 'str'},
            'update_rule': {'key': 'updateRule', 'type': 'str'},
            'delete_rule': {'key': 'deleteRule', 'type': 'str'},
        }

        odatatype = "#Microsoft.Azure.Cdn.Models.KeyVaultCertificateSourceParameters"

        update_rule = "NoAction"

        delete_rule = "NoAction"

        def __init__(self, *, subscription_id: str, resource_group_name: str, vault_name: str, secret_name: str, secret_version: str, **kwargs) -> None:
            super(KeyVaultCertificateSourceParameters, self).__init__(**kwargs)
            self.subscription_id = subscription_id
            self.resource_group_name = resource_group_name
            self.vault_name = vault_name
            self.secret_name = secret_name
            self.secret_version = secret_version

    class LoadParameters(Model):
        """Parameters required for content load.

        All required parameters must be populated in order to send to Azure.

        :param content_paths: Required. The path to the content to be loaded. Path
         should be a relative file URL of the origin.
        :type content_paths: list[str]
        """

        _validation = {
            'content_paths': {'required': True},
        }

        _attribute_map = {
            'content_paths': {'key': 'contentPaths', 'type': '[str]'},
        }

        def __init__(self, *, content_paths, **kwargs) -> None:
            super(LoadParameters, self).__init__(**kwargs)
            self.content_paths = content_paths

    class ManagedRuleDefinition(Model):
        """Describes a managed rule definition.

        Variables are only populated by the server, and will be ignored when
        sending a request.

        :ivar rule_id: Identifier for the managed rule.
        :vartype rule_id: str
        :ivar description: Describes the functionality of the managed rule.
        :vartype description: str
        """

        _validation = {
            'rule_id': {'readonly': True},
            'description': {'readonly': True},
        }

        _attribute_map = {
            'rule_id': {'key': 'ruleId', 'type': 'str'},
            'description': {'key': 'description', 'type': 'str'},
        }

        def __init__(self, **kwargs) -> None:
            super(ManagedRuleDefinition, self).__init__(**kwargs)
            self.rule_id = None
            self.description = None

    class ManagedRuleGroupDefinition(Model):
        """Describes a managed rule group.

        Variables are only populated by the server, and will be ignored when
        sending a request.

        :ivar rule_group_name: Name of the managed rule group.
        :vartype rule_group_name: str
        :ivar description: Description of the managed rule group.
        :vartype description: str
        :ivar rules: List of rules within the managed rule group.
        :vartype rules: list[~azure.mgmt.cdn.models.ManagedRuleDefinition]
        """

        _validation = {
            'rule_group_name': {'readonly': True},
            'description': {'readonly': True},
            'rules': {'readonly': True},
        }

        _attribute_map = {
            'rule_group_name': {'key': 'ruleGroupName', 'type': 'str'},
            'description': {'key': 'description', 'type': 'str'},
            'rules': {'key': 'rules', 'type': '[ManagedRuleDefinition]'},
        }

        def __init__(self, **kwargs) -> None:
            super(ManagedRuleGroupDefinition, self).__init__(**kwargs)
            self.rule_group_name = None
            self.description = None
            self.rules = None

    class ManagedRuleGroupOverride(Model):
        """Defines a managed rule group override setting.

        All required parameters must be populated in order to send to Azure.

        :param rule_group_name: Required. Describes the managed rule group within
         the rule set to override
        :type rule_group_name: str
        :param rules: List of rules that will be disabled. If none specified, all
         rules in the group will be disabled.
        :type rules: list[~azure.mgmt.cdn.models.ManagedRuleOverride]
        """

        _validation = {
            'rule_group_name': {'required': True},
        }

        _attribute_map = {
            'rule_group_name': {'key': 'ruleGroupName', 'type': 'str'},
            'rules': {'key': 'rules', 'type': '[ManagedRuleOverride]'},
        }

        def __init__(self, *, rule_group_name: str, rules=None, **kwargs) -> None:
            super(ManagedRuleGroupOverride, self).__init__(**kwargs)
            self.rule_group_name = rule_group_name
            self.rules = rules

    class ManagedRuleOverride(Model):
        """Defines a managed rule group override setting.

        All required parameters must be populated in order to send to Azure.

        :param rule_id: Required. Identifier for the managed rule.
        :type rule_id: str
        :param enabled_state: Describes if the managed rule is in enabled or
         disabled state. Defaults to Disabled if not specified. Possible values
         include: 'Disabled', 'Enabled'
        :type enabled_state: str or ~azure.mgmt.cdn.models.ManagedRuleEnabledState
        :param action: Describes the override action to be applied when rule
         matches. Possible values include: 'Allow', 'Block', 'Log', 'Redirect'
        :type action: str or ~azure.mgmt.cdn.models.ActionType
        """

        _validation = {
            'rule_id': {'required': True},
        }

        _attribute_map = {
            'rule_id': {'key': 'ruleId', 'type': 'str'},
            'enabled_state': {'key': 'enabledState', 'type': 'str'},
            'action': {'key': 'action', 'type': 'str'},
        }

        def __init__(self, *, rule_id: str, enabled_state=None, action=None, **kwargs) -> None:
            super(ManagedRuleOverride, self).__init__(**kwargs)
            self.rule_id = rule_id
            self.enabled_state = enabled_state
            self.action = action

    class ManagedRuleSet(Model):
        """Defines a managed rule set.

        All required parameters must be populated in order to send to Azure.

        :param rule_set_type: Required. Defines the rule set type to use.
        :type rule_set_type: str
        :param rule_set_version: Required. Defines the version of the rule set to
         use.
        :type rule_set_version: str
        :param anomaly_score: Verizon only : If the rule set supports anomaly
         detection mode, this describes the threshold for blocking requests.
        :type anomaly_score: int
        :param rule_group_overrides: Defines the rule overrides to apply to the
         rule set.
        :type rule_group_overrides:
         list[~azure.mgmt.cdn.models.ManagedRuleGroupOverride]
        """

        _validation = {
            'rule_set_type': {'required': True},
            'rule_set_version': {'required': True},
            'anomaly_score': {'maximum': 20, 'minimum': 0},
        }

        _attribute_map = {
            'rule_set_type': {'key': 'ruleSetType', 'type': 'str'},
            'rule_set_version': {'key': 'ruleSetVersion', 'type': 'str'},
            'anomaly_score': {'key': 'anomalyScore', 'type': 'int'},
            'rule_group_overrides': {'key': 'ruleGroupOverrides', 'type': '[ManagedRuleGroupOverride]'},
        }

        def __init__(self, *, rule_set_type: str, rule_set_version: str, anomaly_score: int=None, rule_group_overrides=None, **kwargs) -> None:
            super(ManagedRuleSet, self).__init__(**kwargs)
            self.rule_set_type = rule_set_type
            self.rule_set_version = rule_set_version
            self.anomaly_score = anomaly_score
            self.rule_group_overrides = rule_group_overrides

    class ManagedRuleSetDefinition(Resource):
        """Describes a managed rule set 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.
        :vartype type: str
        :ivar provisioning_state: Provisioning state of the managed rule set.
        :vartype provisioning_state: str
        :ivar rule_set_type: Type of the managed rule set.
        :vartype rule_set_type: str
        :ivar rule_set_version: Version of the managed rule set type.
        :vartype rule_set_version: str
        :ivar rule_groups: Rule groups of the managed rule set.
        :vartype rule_groups:
         list[~azure.mgmt.cdn.models.ManagedRuleGroupDefinition]
        :param sku: The pricing tier (defines a CDN provider, feature list and
         rate) of the CdnWebApplicationFirewallPolicy.
        :type sku: ~azure.mgmt.cdn.models.Sku
        """

        _validation = {
            'id': {'readonly': True},
            'name': {'readonly': True},
            'type': {'readonly': True},
            'provisioning_state': {'readonly': True},
            'rule_set_type': {'readonly': True},
            'rule_set_version': {'readonly': True},
            'rule_groups': {'readonly': True},
        }

        _attribute_map = {
            'id': {'key': 'id', 'type': 'str'},
            'name': {'key': 'name', 'type': 'str'},
            'type': {'key': 'type', 'type': 'str'},
            'provisioning_state': {'key': 'properties.provisioningState', 'type': 'str'},
            'rule_set_type': {'key': 'properties.ruleSetType', 'type': 'str'},
            'rule_set_version': {'key': 'properties.ruleSetVersion', 'type': 'str'},
            'rule_groups': {'key': 'properties.ruleGroups', 'type': '[ManagedRuleGroupDefinition]'},
            'sku': {'key': 'sku', 'type': 'Sku'},
        }

        def __init__(self, *, sku=None, **kwargs) -> None:
            super(ManagedRuleSetDefinition, self).__init__(**kwargs)
            self.provisioning_state = None
            self.rule_set_type = None
            self.rule_set_version = None
            self.rule_groups = None
            self.sku = sku

    class ManagedRuleSetList(Model):
        """Defines the list of managed rule sets for the policy.

        :param managed_rule_sets: List of rule sets.
        :type managed_rule_sets: list[~azure.mgmt.cdn.models.ManagedRuleSet]
        """

        _attribute_map = {
            'managed_rule_sets': {'key': 'managedRuleSets', 'type': '[ManagedRuleSet]'},
        }

        def __init__(self, *, managed_rule_sets=None, **kwargs) -> None:
            super(ManagedRuleSetList, self).__init__(**kwargs)
            self.managed_rule_sets = managed_rule_sets

    class MatchCondition(Model):
        """Define match conditions.

        All required parameters must be populated in order to send to Azure.

        :param match_variable: Required. Match variable to compare against.
         Possible values include: 'RemoteAddr', 'Country', 'RequestMethod',
         'RequestHeader', 'RequestUri', 'QueryString', 'RequestBody', 'Cookies',
         'PostArgs'
        :type match_variable: str or ~azure.mgmt.cdn.models.MatchVariable
        :param selector: Selector can used to match a specific key for
         QueryString, RequestUri, RequestHeaders or RequestBody.
        :type selector: str
        :param operator: Required. Describes operator to be matched. Possible
         values include: 'Any', 'IPMatch', 'GeoMatch', 'Equal', 'Contains',
         'LessThan', 'GreaterThan', 'LessThanOrEqual', 'GreaterThanOrEqual',
         'BeginsWith', 'EndsWith', 'RegEx'
        :type operator: str or ~azure.mgmt.cdn.models.Operator
        :param negate_condition: Describes if the result of this condition should
         be negated.
        :type negate_condition: bool
        :param match_value: Required. List of possible match values.
        :type match_value: list[str]
        :param transforms: List of transforms.
        :type transforms: list[str or ~azure.mgmt.cdn.models.TransformType]
        """

        _validation = {
            'match_variable': {'required': True},
            'operator': {'required': True},
            'match_value': {'required': True},
        }

        _attribute_map = {
            'match_variable': {'key': 'matchVariable', 'type': 'str'},
            'selector': {'key': 'selector', 'type': 'str'},
            'operator': {'key': 'operator', 'type': 'str'},
            'negate_condition': {'key': 'negateCondition', 'type': 'bool'},
            'match_value': {'key': 'matchValue', 'type': '[str]'},
            'transforms': {'key': 'transforms', 'type': '[str]'},
        }

        def __init__(self, *, match_variable, operator, match_value, selector: str=None, negate_condition: bool=None, transforms=None, **kwargs) -> None:
            super(MatchCondition, self).__init__(**kwargs)
            self.match_variable = match_variable
            self.selector = selector
            self.operator = operator
            self.negate_condition = negate_condition
            self.match_value = match_value
            self.transforms = transforms

    class Operation(Model):
        """CDN REST API operation.

        Variables are only populated by the server, and will be ignored when
        sending a request.

        :ivar name: Operation name: {provider}/{resource}/{operation}
        :vartype name: str
        :param display: The object that represents the operation.
        :type display: ~azure.mgmt.cdn.models.OperationDisplay
        """

        _validation = {
            'name': {'readonly': True},
        }

        _attribute_map = {
            'name': {'key': 'name', 'type': 'str'},
            'display': {'key': 'display', 'type': 'OperationDisplay'},
        }

        def __init__(self, *, display=None, **kwargs) -> None:
            super(Operation, self).__init__(**kwargs)
            self.name = None
            self.display = display

    class OperationDisplay(Model):
        """The object that represents the operation.

        Variables are only populated by the server, and will be ignored when
        sending a request.

        :ivar provider: Service provider: Microsoft.Cdn
        :vartype provider: str
        :ivar resource: Resource on which the operation is performed: Profile,
         endpoint, etc.
        :vartype resource: str
        :ivar operation: Operation type: Read, write, delete, etc.
        :vartype operation: str
        """

        _validation = {
            'provider': {'readonly': True},
            'resource': {'readonly': True},
            'operation': {'readonly': True},
        }

        _attribute_map = {
            'provider': {'key': 'provider', 'type': 'str'},
            'resource': {'key': 'resource', 'type': 'str'},
            'operation': {'key': 'operation', 'type': 'str'},
        }

        def __init__(self, **kwargs) -> None:
            super(OperationDisplay, self).__init__(**kwargs)
            self.provider = None
            self.resource = None
            self.operation = None

    class Origin(TrackedResource):
        """CDN origin is the source of the content being delivered via CDN. When the
        edge nodes represented by an endpoint do not have the requested content
        cached, they attempt to fetch it from one or more of the configured
        origins.

        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.
        :vartype type: str
        :param location: Required. Resource location.
        :type location: str
        :param tags: Resource tags.
        :type tags: dict[str, str]
        :param host_name: Required. The address of the origin. Domain names, IPv4
         addresses, and IPv6 addresses are supported.
        :type host_name: str
        :param http_port: The value of the HTTP port. Must be between 1 and 65535.
        :type http_port: int
        :param https_port: The value of the https port. Must be between 1 and
         65535.
        :type https_port: int
        :ivar resource_state: Resource status of the origin. Possible values
         include: 'Creating', 'Active', 'Deleting'
        :vartype resource_state: str or ~azure.mgmt.cdn.models.OriginResourceState
        :ivar provisioning_state: Provisioning status of the origin.
        :vartype provisioning_state: str
        """

        _validation = {
            'id': {'readonly': True},
            'name': {'readonly': True},
            'type': {'readonly': True},
            'location': {'required': True},
            'host_name': {'required': True},
            'http_port': {'maximum': 65535, 'minimum': 1},
            'https_port': {'maximum': 65535, 'minimum': 1},
            'resource_state': {'readonly': True},
            'provisioning_state': {'readonly': True},
        }

        _attribute_map = {
            'id': {'key': 'id', 'type': 'str'},
            'name': {'key': 'name', 'type': 'str'},
            'type': {'key': 'type', 'type': 'str'},
            'location': {'key': 'location', 'type': 'str'},
            'tags': {'key': 'tags', 'type': '{str}'},
            'host_name': {'key': 'properties.hostName', 'type': 'str'},
            'http_port': {'key': 'properties.httpPort', 'type': 'int'},
            'https_port': {'key': 'properties.httpsPort', 'type': 'int'},
            'resource_state': {'key': 'properties.resourceState', 'type': 'str'},
            'provisioning_state': {'key': 'properties.provisioningState', 'type': 'str'},
        }

        def __init__(self, *, location: str, host_name: str, tags=None, http_port: int=None, https_port: int=None, **kwargs) -> None:
            super(Origin, self).__init__(location=location, tags=tags, **kwargs)
            self.host_name = host_name
            self.http_port = http_port
            self.https_port = https_port
            self.resource_state = None
            self.provisioning_state = None

    class OriginUpdateParameters(Model):
        """Origin properties needed for origin creation or update.

        :param host_name: The address of the origin. Domain names, IPv4 addresses,
         and IPv6 addresses are supported.
        :type host_name: str
        :param http_port: The value of the HTTP port. Must be between 1 and 65535.
        :type http_port: int
        :param https_port: The value of the HTTPS port. Must be between 1 and
         65535.
        :type https_port: int
        """

        _validation = {
            'http_port': {'maximum': 65535, 'minimum': 1},
            'https_port': {'maximum': 65535, 'minimum': 1},
        }

        _attribute_map = {
            'host_name': {'key': 'properties.hostName', 'type': 'str'},
            'http_port': {'key': 'properties.httpPort', 'type': 'int'},
            'https_port': {'key': 'properties.httpsPort', 'type': 'int'},
        }

        def __init__(self, *, host_name: str=None, http_port: int=None, https_port: int=None, **kwargs) -> None:
            super(OriginUpdateParameters, self).__init__(**kwargs)
            self.host_name = host_name
            self.http_port = http_port
            self.https_port = https_port

    class PolicySettings(Model):
        """Defines contents of a web application firewall global configuration.

        :param enabled_state: describes if the policy is in enabled state or
         disabled state. Possible values include: 'Disabled', 'Enabled'
        :type enabled_state: str or ~azure.mgmt.cdn.models.PolicyEnabledState
        :param mode: Describes if it is in detection mode or prevention mode at
         policy level. Possible values include: 'Prevention', 'Detection'
        :type mode: str or ~azure.mgmt.cdn.models.PolicyMode
        :param default_redirect_url: If action type is redirect, this field
         represents the default redirect URL for the client.
        :type default_redirect_url: str
        :param default_custom_block_response_status_code: If the action type is
         block, this field defines the default customer overridable http response
         status code.
        :type default_custom_block_response_status_code: int
        :param default_custom_block_response_body: If the action type is block,
         customer can override the response body. The body must be specified in
         base64 encoding.
        :type default_custom_block_response_body: str
        """

        _validation = {
            'default_custom_block_response_status_code': {'maximum': 599, 'minimum': 200},
            'default_custom_block_response_body': {'pattern': r'^(?:[A-Za-z0-9+/]{4})*(?:[A-Za-z0-9+/]{2}==|[A-Za-z0-9+/]{3}=|[A-Za-z0-9+/]{4})$'},
        }

        _attribute_map = {
            'enabled_state': {'key': 'enabledState', 'type': 'str'},
            'mode': {'key': 'mode', 'type': 'str'},
            'default_redirect_url': {'key': 'defaultRedirectUrl', 'type': 'str'},
            'default_custom_block_response_status_code': {'key': 'defaultCustomBlockResponseStatusCode', 'type': 'int'},
            'default_custom_block_response_body': {'key': 'defaultCustomBlockResponseBody', 'type': 'str'},
        }

        def __init__(self, *, enabled_state=None, mode=None, default_redirect_url: str=None, default_custom_block_response_status_code: int=None, default_custom_block_response_body: str=None, **kwargs) -> None:
            super(PolicySettings, self).__init__(**kwargs)
            self.enabled_state = enabled_state
            self.mode = mode
            self.default_redirect_url = default_redirect_url
            self.default_custom_block_response_status_code = default_custom_block_response_status_code
            self.default_custom_block_response_body = default_custom_block_response_body

    class PostArgsMatchConditionParameters(Model):
        """Defines the parameters for PostArgs match conditions.

        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 odatatype: Required.  Default value:
         "#Microsoft.Azure.Cdn.Models.DeliveryRulePostArgsConditionParameters" .
        :vartype odatatype: str
        :param selector: Required. Name of PostArg to be matched
        :type selector: str
        :param operator: Required. Describes operator to be matched. Possible
         values include: 'Any', 'Equal', 'Contains', 'BeginsWith', 'EndsWith',
         'LessThan', 'LessThanOrEqual', 'GreaterThan', 'GreaterThanOrEqual'
        :type operator: str or ~azure.mgmt.cdn.models.PostArgsOperator
        :param negate_condition: Describes if this is negate condition or not
        :type negate_condition: bool
        :param match_values: Required. The match value for the condition of the
         delivery rule
        :type match_values: list[str]
        :param transforms: List of transforms
        :type transforms: list[str or ~azure.mgmt.cdn.models.Transform]
        """

        _validation = {
            'odatatype': {'required': True, 'constant': True},
            'selector': {'required': True},
            'operator': {'required': True},
            'match_values': {'required': True},
        }

        _attribute_map = {
            'odatatype': {'key': '@odata\\.type', 'type': 'str'},
            'selector': {'key': 'selector', 'type': 'str'},
            'operator': {'key': 'operator', 'type': 'str'},
            'negate_condition': {'key': 'negateCondition', 'type': 'bool'},
            'match_values': {'key': 'matchValues', 'type': '[str]'},
            'transforms': {'key': 'transforms', 'type': '[str]'},
        }

        odatatype = "#Microsoft.Azure.Cdn.Models.DeliveryRulePostArgsConditionParameters"

        def __init__(self, *, selector: str, operator, match_values, negate_condition: bool=None, transforms=None, **kwargs) -> None:
            super(PostArgsMatchConditionParameters, self).__init__(**kwargs)
            self.selector = selector
            self.operator = operator
            self.negate_condition = negate_condition
            self.match_values = match_values
            self.transforms = transforms

    class Profile(TrackedResource):
        """CDN profile is a logical grouping of endpoints that share the same
        settings, such as CDN provider and pricing tier.

        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.
        :vartype type: str
        :param location: Required. Resource location.
        :type location: str
        :param tags: Resource tags.
        :type tags: dict[str, str]
        :param sku: Required. The pricing tier (defines a CDN provider, feature
         list and rate) of the CDN profile.
        :type sku: ~azure.mgmt.cdn.models.Sku
        :ivar resource_state: Resource status of the profile. Possible values
         include: 'Creating', 'Active', 'Deleting', 'Disabled'
        :vartype resource_state: str or
         ~azure.mgmt.cdn.models.ProfileResourceState
        :ivar provisioning_state: Provisioning status of the profile.
        :vartype provisioning_state: str
        """

        _validation = {
            'id': {'readonly': True},
            'name': {'readonly': True},
            'type': {'readonly': True},
            'location': {'required': True},
            'sku': {'required': True},
            'resource_state': {'readonly': True},
            'provisioning_state': {'readonly': True},
        }

        _attribute_map = {
            'id': {'key': 'id', 'type': 'str'},
            'name': {'key': 'name', 'type': 'str'},
            'type': {'key': 'type', 'type': 'str'},
            'location': {'key': 'location', 'type': 'str'},
            'tags': {'key': 'tags', 'type': '{str}'},
            'sku': {'key': 'sku', 'type': 'Sku'},
            'resource_state': {'key': 'properties.resourceState', 'type': 'str'},
            'provisioning_state': {'key': 'properties.provisioningState', 'type': 'str'},
        }

        def __init__(self, *, location: str, sku, tags=None, **kwargs) -> None:
            super(Profile, self).__init__(location=location, tags=tags, **kwargs)
            self.sku = sku
            self.resource_state = None
            self.provisioning_state = None

    class ProfileUpdateParameters(Model):
        """Properties required to update a profile.

        :param tags: Profile tags
        :type tags: dict[str, str]
        """

        _attribute_map = {
            'tags': {'key': 'tags', 'type': '{str}'},
        }

        def __init__(self, *, tags=None, **kwargs) -> None:
            super(ProfileUpdateParameters, self).__init__(**kwargs)
            self.tags = tags

    class PurgeParameters(Model):
        """Parameters required for content purge.

        All required parameters must be populated in order to send to Azure.

        :param content_paths: Required. The path to the content to be purged. Can
         describe a file path or a wild card directory.
        :type content_paths: list[str]
        """

        _validation = {
            'content_paths': {'required': True},
        }

        _attribute_map = {
            'content_paths': {'key': 'contentPaths', 'type': '[str]'},
        }

        def __init__(self, *, content_paths, **kwargs) -> None:
            super(PurgeParameters, self).__init__(**kwargs)
            self.content_paths = content_paths

    class QueryStringMatchConditionParameters(Model):
        """Defines the parameters for QueryString match conditions.

        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 odatatype: Required.  Default value:
         "#Microsoft.Azure.Cdn.Models.DeliveryRuleQueryStringConditionParameters" .
        :vartype odatatype: str
        :param operator: Required. Describes operator to be matched. Possible
         values include: 'Any', 'Equal', 'Contains', 'BeginsWith', 'EndsWith',
         'LessThan', 'LessThanOrEqual', 'GreaterThan', 'GreaterThanOrEqual'
        :type operator: str or ~azure.mgmt.cdn.models.QueryStringOperator
        :param negate_condition: Describes if this is negate condition or not
        :type negate_condition: bool
        :param match_values: Required. The match value for the condition of the
         delivery rule
        :type match_values: list[str]
        :param transforms: List of transforms
        :type transforms: list[str or ~azure.mgmt.cdn.models.Transform]
        """

        _validation = {
            'odatatype': {'required': True, 'constant': True},
            'operator': {'required': True},
            'match_values': {'required': True},
        }

        _attribute_map = {
            'odatatype': {'key': '@odata\\.type', 'type': 'str'},
            'operator': {'key': 'operator', 'type': 'str'},
            'negate_condition': {'key': 'negateCondition', 'type': 'bool'},
            'match_values': {'key': 'matchValues', 'type': '[str]'},
            'transforms': {'key': 'transforms', 'type': '[str]'},
        }

        odatatype = "#Microsoft.Azure.Cdn.Models.DeliveryRuleQueryStringConditionParameters"

        def __init__(self, *, operator, match_values, negate_condition: bool=None, transforms=None, **kwargs) -> None:
            super(QueryStringMatchConditionParameters, self).__init__(**kwargs)
            self.operator = operator
            self.negate_condition = negate_condition
            self.match_values = match_values
            self.transforms = transforms

    class RateLimitRule(CustomRule):
        """Defines a rate limiting rule that can be included in a waf policy.

        All required parameters must be populated in order to send to Azure.

        :param name: Required. Defines the name of the custom rule
        :type name: str
        :param enabled_state: Describes if the custom rule is in enabled or
         disabled state. Defaults to Enabled if not specified. Possible values
         include: 'Disabled', 'Enabled'
        :type enabled_state: str or ~azure.mgmt.cdn.models.CustomRuleEnabledState
        :param priority: Required. Defines in what order this rule be evaluated in
         the overall list of custom rules
        :type priority: int
        :param match_conditions: Required. List of match conditions.
        :type match_conditions: list[~azure.mgmt.cdn.models.MatchCondition]
        :param action: Required. Describes what action to be applied when rule
         matches. Possible values include: 'Allow', 'Block', 'Log', 'Redirect'
        :type action: str or ~azure.mgmt.cdn.models.ActionType
        :param rate_limit_threshold: Required. Defines rate limit threshold.
        :type rate_limit_threshold: int
        :param rate_limit_duration_in_minutes: Required. Defines rate limit
         duration. Default is 1 minute.
        :type rate_limit_duration_in_minutes: int
        """

        _validation = {
            'name': {'required': True},
            'priority': {'required': True, 'maximum': 1000, 'minimum': 0},
            'match_conditions': {'required': True},
            'action': {'required': True},
            'rate_limit_threshold': {'required': True, 'minimum': 0},
            'rate_limit_duration_in_minutes': {'required': True, 'maximum': 60, 'minimum': 0},
        }

        _attribute_map = {
            'name': {'key': 'name', 'type': 'str'},
            'enabled_state': {'key': 'enabledState', 'type': 'str'},
            'priority': {'key': 'priority', 'type': 'int'},
            'match_conditions': {'key': 'matchConditions', 'type': '[MatchCondition]'},
            'action': {'key': 'action', 'type': 'str'},
            'rate_limit_threshold': {'key': 'rateLimitThreshold', 'type': 'int'},
            'rate_limit_duration_in_minutes': {'key': 'rateLimitDurationInMinutes', 'type': 'int'},
        }

        def __init__(self, *, name: str, priority: int, match_conditions, action, rate_limit_threshold: int, rate_limit_duration_in_minutes: int, enabled_state=None, **kwargs) -> None:
            super(RateLimitRule, self).__init__(name=name, enabled_state=enabled_state, priority=priority, match_conditions=match_conditions, action=action, **kwargs)
            self.rate_limit_threshold = rate_limit_threshold
            self.rate_limit_duration_in_minutes = rate_limit_duration_in_minutes

    class RateLimitRuleList(Model):
        """Defines contents of rate limit rules.

        :param rules: List of rules
        :type rules: list[~azure.mgmt.cdn.models.RateLimitRule]
        """

        _attribute_map = {
            'rules': {'key': 'rules', 'type': '[RateLimitRule]'},
        }

        def __init__(self, *, rules=None, **kwargs) -> None:
            super(RateLimitRuleList, self).__init__(**kwargs)
            self.rules = rules

    class RemoteAddressMatchConditionParameters(Model):
        """Defines the parameters for RemoteAddress match conditions.

        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 odatatype: Required.  Default value:
         "#Microsoft.Azure.Cdn.Models.DeliveryRuleRemoteAddressConditionParameters"
         .
        :vartype odatatype: str
        :param operator: Required. Describes operator to be matched. Possible
         values include: 'Any', 'IPMatch', 'GeoMatch'
        :type operator: str or ~azure.mgmt.cdn.models.RemoteAddressOperator
        :param negate_condition: Describes if this is negate condition or not
        :type negate_condition: bool
        :param match_values: Required. Match values to match against. The operator
         will apply to each value in here with OR semantics. If any of them match
         the variable with the given operator this match condition is considered a
         match.
        :type match_values: list[str]
        :param transforms: List of transforms
        :type transforms: list[str or ~azure.mgmt.cdn.models.Transform]
        """

        _validation = {
            'odatatype': {'required': True, 'constant': True},
            'operator': {'required': True},
            'match_values': {'required': True},
        }

        _attribute_map = {
            'odatatype': {'key': '@odata\\.type', 'type': 'str'},
            'operator': {'key': 'operator', 'type': 'str'},
            'negate_condition': {'key': 'negateCondition', 'type': 'bool'},
            'match_values': {'key': 'matchValues', 'type': '[str]'},
            'transforms': {'key': 'transforms', 'type': '[str]'},
        }

        odatatype = "#Microsoft.Azure.Cdn.Models.DeliveryRuleRemoteAddressConditionParameters"

        def __init__(self, *, operator, match_values, negate_condition: bool=None, transforms=None, **kwargs) -> None:
            super(RemoteAddressMatchConditionParameters, self).__init__(**kwargs)
            self.operator = operator
            self.negate_condition = negate_condition
            self.match_values = match_values
            self.transforms = transforms

    class RequestBodyMatchConditionParameters(Model):
        """Defines the parameters for RequestBody match conditions.

        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 odatatype: Required.  Default value:
         "#Microsoft.Azure.Cdn.Models.DeliveryRuleRequestBodyConditionParameters" .
        :vartype odatatype: str
        :param operator: Required. Describes operator to be matched. Possible
         values include: 'Any', 'Equal', 'Contains', 'BeginsWith', 'EndsWith',
         'LessThan', 'LessThanOrEqual', 'GreaterThan', 'GreaterThanOrEqual'
        :type operator: str or ~azure.mgmt.cdn.models.RequestBodyOperator
        :param negate_condition: Describes if this is negate condition or not
        :type negate_condition: bool
        :param match_values: Required. The match value for the condition of the
         delivery rule
        :type match_values: list[str]
        :param transforms: List of transforms
        :type transforms: list[str or ~azure.mgmt.cdn.models.Transform]
        """

        _validation = {
            'odatatype': {'required': True, 'constant': True},
            'operator': {'required': True},
            'match_values': {'required': True},
        }

        _attribute_map = {
            'odatatype': {'key': '@odata\\.type', 'type': 'str'},
            'operator': {'key': 'operator', 'type': 'str'},
            'negate_condition': {'key': 'negateCondition', 'type': 'bool'},
            'match_values': {'key': 'matchValues', 'type': '[str]'},
            'transforms': {'key': 'transforms', 'type': '[str]'},
        }

        odatatype = "#Microsoft.Azure.Cdn.Models.DeliveryRuleRequestBodyConditionParameters"

        def __init__(self, *, operator, match_values, negate_condition: bool=None, transforms=None, **kwargs) -> None:
            super(RequestBodyMatchConditionParameters, self).__init__(**kwargs)
            self.operator = operator
            self.negate_condition = negate_condition
            self.match_values = match_values
            self.transforms = transforms

    class RequestHeaderMatchConditionParameters(Model):
        """Defines the parameters for RequestHeader match conditions.

        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 odatatype: Required.  Default value:
         "#Microsoft.Azure.Cdn.Models.DeliveryRuleRequestHeaderConditionParameters"
         .
        :vartype odatatype: str
        :param selector: Required. Name of Header to be matched
        :type selector: str
        :param operator: Required. Describes operator to be matched. Possible
         values include: 'Any', 'Equal', 'Contains', 'BeginsWith', 'EndsWith',
         'LessThan', 'LessThanOrEqual', 'GreaterThan', 'GreaterThanOrEqual'
        :type operator: str or ~azure.mgmt.cdn.models.RequestHeaderOperator
        :param negate_condition: Describes if this is negate condition or not
        :type negate_condition: bool
        :param match_values: Required. The match value for the condition of the
         delivery rule
        :type match_values: list[str]
        :param transforms: List of transforms
        :type transforms: list[str or ~azure.mgmt.cdn.models.Transform]
        """

        _validation = {
            'odatatype': {'required': True, 'constant': True},
            'selector': {'required': True},
            'operator': {'required': True},
            'match_values': {'required': True},
        }

        _attribute_map = {
            'odatatype': {'key': '@odata\\.type', 'type': 'str'},
            'selector': {'key': 'selector', 'type': 'str'},
            'operator': {'key': 'operator', 'type': 'str'},
            'negate_condition': {'key': 'negateCondition', 'type': 'bool'},
            'match_values': {'key': 'matchValues', 'type': '[str]'},
            'transforms': {'key': 'transforms', 'type': '[str]'},
        }

        odatatype = "#Microsoft.Azure.Cdn.Models.DeliveryRuleRequestHeaderConditionParameters"

        def __init__(self, *, selector: str, operator, match_values, negate_condition: bool=None, transforms=None, **kwargs) -> None:
            super(RequestHeaderMatchConditionParameters, self).__init__(**kwargs)
            self.selector = selector
            self.operator = operator
            self.negate_condition = negate_condition
            self.match_values = match_values
            self.transforms = transforms

    class RequestMethodMatchConditionParameters(Model):
        """Defines the parameters for RequestMethod match conditions.

        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 odatatype: Required.  Default value:
         "#Microsoft.Azure.Cdn.Models.DeliveryRuleRequestMethodConditionParameters"
         .
        :vartype odatatype: str
        :ivar operator: Required. Describes operator to be matched. Default value:
         "Equal" .
        :vartype operator: str
        :param negate_condition: Describes if this is negate condition or not
        :type negate_condition: bool
        :param match_values: Required. The match value for the condition of the
         delivery rule
        :type match_values: list[str]
        """

        _validation = {
            'odatatype': {'required': True, 'constant': True},
            'operator': {'required': True, 'constant': True},
            'match_values': {'required': True},
        }

        _attribute_map = {
            'odatatype': {'key': '@odata\\.type', 'type': 'str'},
            'operator': {'key': 'operator', 'type': 'str'},
            'negate_condition': {'key': 'negateCondition', 'type': 'bool'},
            'match_values': {'key': 'matchValues', 'type': '[str]'},
        }

        odatatype = "#Microsoft.Azure.Cdn.Models.DeliveryRuleRequestMethodConditionParameters"

        operator = "Equal"

        def __init__(self, *, match_values, negate_condition: bool=None, **kwargs) -> None:
            super(RequestMethodMatchConditionParameters, self).__init__(**kwargs)
            self.negate_condition = negate_condition
            self.match_values = match_values

    class RequestSchemeMatchConditionParameters(Model):
        """Defines the parameters for RequestScheme match conditions .

        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 odatatype: Required.  Default value:
         "#Microsoft.Azure.Cdn.Models.DeliveryRuleRequestSchemeConditionParameters"
         .
        :vartype odatatype: str
        :ivar operator: Required. Describes operator to be matched. Default value:
         "Equal" .
        :vartype operator: str
        :param negate_condition: Describes if this is negate condition or not
        :type negate_condition: bool
        :param match_values: Required. The match value for the condition of the
         delivery rule
        :type match_values: list[str]
        """

        _validation = {
            'odatatype': {'required': True, 'constant': True},
            'operator': {'required': True, 'constant': True},
            'match_values': {'required': True},
        }

        _attribute_map = {
            'odatatype': {'key': '@odata\\.type', 'type': 'str'},
            'operator': {'key': 'operator', 'type': 'str'},
            'negate_condition': {'key': 'negateCondition', 'type': 'bool'},
            'match_values': {'key': 'matchValues', 'type': '[str]'},
        }

        odatatype = "#Microsoft.Azure.Cdn.Models.DeliveryRuleRequestSchemeConditionParameters"

        operator = "Equal"

        def __init__(self, *, match_values, negate_condition: bool=None, **kwargs) -> None:
            super(RequestSchemeMatchConditionParameters, self).__init__(**kwargs)
            self.negate_condition = negate_condition
            self.match_values = match_values

    class RequestUriMatchConditionParameters(Model):
        """Defines the parameters for RequestUri match conditions.

        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 odatatype: Required.  Default value:
         "#Microsoft.Azure.Cdn.Models.DeliveryRuleRequestUriConditionParameters" .
        :vartype odatatype: str
        :param operator: Required. Describes operator to be matched. Possible
         values include: 'Any', 'Equal', 'Contains', 'BeginsWith', 'EndsWith',
         'LessThan', 'LessThanOrEqual', 'GreaterThan', 'GreaterThanOrEqual'
        :type operator: str or ~azure.mgmt.cdn.models.RequestUriOperator
        :param negate_condition: Describes if this is negate condition or not
        :type negate_condition: bool
        :param match_values: Required. The match value for the condition of the
         delivery rule
        :type match_values: list[str]
        :param transforms: List of transforms
        :type transforms: list[str or ~azure.mgmt.cdn.models.Transform]
        """

        _validation = {
            'odatatype': {'required': True, 'constant': True},
            'operator': {'required': True},
            'match_values': {'required': True},
        }

        _attribute_map = {
            'odatatype': {'key': '@odata\\.type', 'type': 'str'},
            'operator': {'key': 'operator', 'type': 'str'},
            'negate_condition': {'key': 'negateCondition', 'type': 'bool'},
            'match_values': {'key': 'matchValues', 'type': '[str]'},
            'transforms': {'key': 'transforms', 'type': '[str]'},
        }

        odatatype = "#Microsoft.Azure.Cdn.Models.DeliveryRuleRequestUriConditionParameters"

        def __init__(self, *, operator, match_values, negate_condition: bool=None, transforms=None, **kwargs) -> None:
            super(RequestUriMatchConditionParameters, self).__init__(**kwargs)
            self.operator = operator
            self.negate_condition = negate_condition
            self.match_values = match_values
            self.transforms = transforms

    class ResourceUsage(Model):
        """Output of check resource usage API.

        Variables are only populated by the server, and will be ignored when
        sending a request.

        :ivar resource_type: Resource type for which the usage is provided.
        :vartype resource_type: str
        :ivar unit: Unit of the usage. e.g. Count.
        :vartype unit: str
        :ivar current_value: Actual value of usage on the specified resource type.
        :vartype current_value: int
        :ivar limit: Quota of the specified resource type.
        :vartype limit: int
        """

        _validation = {
            'resource_type': {'readonly': True},
            'unit': {'readonly': True},
            'current_value': {'readonly': True},
            'limit': {'readonly': True},
        }

        _attribute_map = {
            'resource_type': {'key': 'resourceType', 'type': 'str'},
            'unit': {'key': 'unit', 'type': 'str'},
            'current_value': {'key': 'currentValue', 'type': 'int'},
            'limit': {'key': 'limit', 'type': 'int'},
        }

        def __init__(self, **kwargs) -> None:
            super(ResourceUsage, self).__init__(**kwargs)
            self.resource_type = None
            self.unit = None
            self.current_value = None
            self.limit = None

    class Sku(Model):
        """The pricing tier (defines a CDN provider, feature list and rate) of the CDN
        profile.

        :param name: Name of the pricing tier. Possible values include:
         'Standard_Verizon', 'Premium_Verizon', 'Custom_Verizon',
         'Standard_Akamai', 'Standard_ChinaCdn', 'Standard_Microsoft',
         'Premium_ChinaCdn'
        :type name: str or ~azure.mgmt.cdn.models.SkuName
        """

        _attribute_map = {
            'name': {'key': 'name', 'type': 'str'},
        }

        def __init__(self, *, name=None, **kwargs) -> None:
            super(Sku, self).__init__(**kwargs)
            self.name = name

    class SsoUri(Model):
        """The URI required to login to the supplemental portal from the Azure portal.

        Variables are only populated by the server, and will be ignored when
        sending a request.

        :ivar sso_uri_value: The URI used to login to the supplemental portal.
        :vartype sso_uri_value: str
        """

        _validation = {
            'sso_uri_value': {'readonly': True},
        }

        _attribute_map = {
            'sso_uri_value': {'key': 'ssoUriValue', 'type': 'str'},
        }

        def __init__(self, **kwargs) -> None:
            super(SsoUri, self).__init__(**kwargs)
            self.sso_uri_value = None

    class SupportedOptimizationTypesListResult(Model):
        """The result of the GetSupportedOptimizationTypes API.

        Variables are only populated by the server, and will be ignored when
        sending a request.

        :ivar supported_optimization_types: Supported optimization types for a
         profile.
        :vartype supported_optimization_types: list[str or
         ~azure.mgmt.cdn.models.OptimizationType]
        """

        _validation = {
            'supported_optimization_types': {'readonly': True},
        }

        _attribute_map = {
            'supported_optimization_types': {'key': 'supportedOptimizationTypes', 'type': '[str]'},
        }

        def __init__(self, **kwargs) -> None:
            super(SupportedOptimizationTypesListResult, self).__init__(**kwargs)
            self.supported_optimization_types = None

    class UrlFileExtensionMatchConditionParameters(Model):
        """Defines the parameters for UrlFileExtension match conditions.

        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 odatatype: Required.  Default value:
         "#Microsoft.Azure.Cdn.Models.DeliveryRuleUrlFileExtensionMatchConditionParameters"
         .
        :vartype odatatype: str
        :param operator: Required. Describes operator to be matched. Possible
         values include: 'Any', 'Equal', 'Contains', 'BeginsWith', 'EndsWith',
         'LessThan', 'LessThanOrEqual', 'GreaterThan', 'GreaterThanOrEqual'
        :type operator: str or ~azure.mgmt.cdn.models.UrlFileExtensionOperator
        :param negate_condition: Describes if this is negate condition or not
        :type negate_condition: bool
        :param match_values: Required. The match value for the condition of the
         delivery rule
        :type match_values: list[str]
        :param transforms: List of transforms
        :type transforms: list[str or ~azure.mgmt.cdn.models.Transform]
        """

        _validation = {
            'odatatype': {'required': True, 'constant': True},
            'operator': {'required': True},
            'match_values': {'required': True},
        }

        _attribute_map = {
            'odatatype': {'key': '@odata\\.type', 'type': 'str'},
            'operator': {'key': 'operator', 'type': 'str'},
            'negate_condition': {'key': 'negateCondition', 'type': 'bool'},
            'match_values': {'key': 'matchValues', 'type': '[str]'},
            'transforms': {'key': 'transforms', 'type': '[str]'},
        }

        odatatype = "#Microsoft.Azure.Cdn.Models.DeliveryRuleUrlFileExtensionMatchConditionParameters"

        def __init__(self, *, operator, match_values, negate_condition: bool=None, transforms=None, **kwargs) -> None:
            super(UrlFileExtensionMatchConditionParameters, self).__init__(**kwargs)
            self.operator = operator
            self.negate_condition = negate_condition
            self.match_values = match_values
            self.transforms = transforms

    class UrlFileNameMatchConditionParameters(Model):
        """Defines the parameters for UrlFilename match conditions.

        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 odatatype: Required.  Default value:
         "#Microsoft.Azure.Cdn.Models.DeliveryRuleUrlFilenameConditionParameters" .
        :vartype odatatype: str
        :param operator: Required. Describes operator to be matched. Possible
         values include: 'Any', 'Equal', 'Contains', 'BeginsWith', 'EndsWith',
         'LessThan', 'LessThanOrEqual', 'GreaterThan', 'GreaterThanOrEqual'
        :type operator: str or ~azure.mgmt.cdn.models.UrlFileNameOperator
        :param negate_condition: Describes if this is negate condition or not
        :type negate_condition: bool
        :param match_values: Required. The match value for the condition of the
         delivery rule
        :type match_values: list[str]
        :param transforms: List of transforms
        :type transforms: list[str or ~azure.mgmt.cdn.models.Transform]
        """

        _validation = {
            'odatatype': {'required': True, 'constant': True},
            'operator': {'required': True},
            'match_values': {'required': True},
        }

        _attribute_map = {
            'odatatype': {'key': '@odata\\.type', 'type': 'str'},
            'operator': {'key': 'operator', 'type': 'str'},
            'negate_condition': {'key': 'negateCondition', 'type': 'bool'},
            'match_values': {'key': 'matchValues', 'type': '[str]'},
            'transforms': {'key': 'transforms', 'type': '[str]'},
        }

        odatatype = "#Microsoft.Azure.Cdn.Models.DeliveryRuleUrlFilenameConditionParameters"

        def __init__(self, *, operator, match_values, negate_condition: bool=None, transforms=None, **kwargs) -> None:
            super(UrlFileNameMatchConditionParameters, self).__init__(**kwargs)
            self.operator = operator
            self.negate_condition = negate_condition
            self.match_values = match_values
            self.transforms = transforms

    class UrlPathMatchConditionParameters(Model):
        """Defines the parameters for UrlPath match conditions.

        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 odatatype: Required.  Default value:
         "#Microsoft.Azure.Cdn.Models.DeliveryRuleUrlPathMatchConditionParameters"
         .
        :vartype odatatype: str
        :param operator: Required. Describes operator to be matched. Possible
         values include: 'Any', 'Equal', 'Contains', 'BeginsWith', 'EndsWith',
         'LessThan', 'LessThanOrEqual', 'GreaterThan', 'GreaterThanOrEqual',
         'Wildcard'
        :type operator: str or ~azure.mgmt.cdn.models.UrlPathOperator
        :param negate_condition: Describes if this is negate condition or not
        :type negate_condition: bool
        :param match_values: Required. The match value for the condition of the
         delivery rule
        :type match_values: list[str]
        :param transforms: List of transforms
        :type transforms: list[str or ~azure.mgmt.cdn.models.Transform]
        """

        _validation = {
            'odatatype': {'required': True, 'constant': True},
            'operator': {'required': True},
            'match_values': {'required': True},
        }

        _attribute_map = {
            'odatatype': {'key': '@odata\\.type', 'type': 'str'},
            'operator': {'key': 'operator', 'type': 'str'},
            'negate_condition': {'key': 'negateCondition', 'type': 'bool'},
            'match_values': {'key': 'matchValues', 'type': '[str]'},
            'transforms': {'key': 'transforms', 'type': '[str]'},
        }

        odatatype = "#Microsoft.Azure.Cdn.Models.DeliveryRuleUrlPathMatchConditionParameters"

        def __init__(self, *, operator, match_values, negate_condition: bool=None, transforms=None, **kwargs) -> None:
            super(UrlPathMatchConditionParameters, self).__init__(**kwargs)
            self.operator = operator
            self.negate_condition = negate_condition
            self.match_values = match_values
            self.transforms = transforms

    class UrlRedirectAction(DeliveryRuleAction):
        """Defines the url redirect action for the delivery rule.

        All required parameters must be populated in order to send to Azure.

        :param name: Required. Constant filled by server.
        :type name: str
        :param parameters: Required. Defines the parameters for the action.
        :type parameters: ~azure.mgmt.cdn.models.UrlRedirectActionParameters
        """

        _validation = {
            'name': {'required': True},
            'parameters': {'required': True},
        }

        _attribute_map = {
            'name': {'key': 'name', 'type': 'str'},
            'parameters': {'key': 'parameters', 'type': 'UrlRedirectActionParameters'},
        }

        def __init__(self, *, parameters, **kwargs) -> None:
            super(UrlRedirectAction, self).__init__(**kwargs)
            self.parameters = parameters
            self.name = 'UrlRedirect'

    class UrlRedirectActionParameters(Model):
        """Defines the parameters for the url redirect action.

        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 odatatype: Required.  Default value:
         "#Microsoft.Azure.Cdn.Models.DeliveryRuleUrlRedirectActionParameters" .
        :vartype odatatype: str
        :param redirect_type: Required. The redirect type the rule will use when
         redirecting traffic. Possible values include: 'Moved', 'Found',
         'TemporaryRedirect', 'PermanentRedirect'
        :type redirect_type: str or ~azure.mgmt.cdn.models.RedirectType
        :param destination_protocol: Protocol to use for the redirect. The default
         value is MatchRequest. Possible values include: 'MatchRequest', 'Http',
         'Https'
        :type destination_protocol: str or
         ~azure.mgmt.cdn.models.DestinationProtocol
        :param custom_path: The full path to redirect. Path cannot be empty and
         must start with /. Leave empty to use the incoming path as destination
         path.
        :type custom_path: str
        :param custom_hostname: Host to redirect. Leave empty to use the incoming
         host as the destination host.
        :type custom_hostname: str
        :param custom_query_string: The set of query strings to be placed in the
         redirect URL. Setting this value would replace any existing query string;
         leave empty to preserve the incoming query string. Query string must be in
         <key>=<value> format. ? and & will be added automatically so do not
         include them.
        :type custom_query_string: str
        :param custom_fragment: Fragment to add to the redirect URL. Fragment is
         the part of the URL that comes after #. Do not include the #.
        :type custom_fragment: str
        """

        _validation = {
            'odatatype': {'required': True, 'constant': True},
            'redirect_type': {'required': True},
        }

        _attribute_map = {
            'odatatype': {'key': '@odata\\.type', 'type': 'str'},
            'redirect_type': {'key': 'redirectType', 'type': 'str'},
            'destination_protocol': {'key': 'destinationProtocol', 'type': 'str'},
            'custom_path': {'key': 'customPath', 'type': 'str'},
            'custom_hostname': {'key': 'customHostname', 'type': 'str'},
            'custom_query_string': {'key': 'customQueryString', 'type': 'str'},
            'custom_fragment': {'key': 'customFragment', 'type': 'str'},
        }

        odatatype = "#Microsoft.Azure.Cdn.Models.DeliveryRuleUrlRedirectActionParameters"

        def __init__(self, *, redirect_type, destination_protocol=None, custom_path: str=None, custom_hostname: str=None, custom_query_string: str=None, custom_fragment: str=None, **kwargs) -> None:
            super(UrlRedirectActionParameters, self).__init__(**kwargs)
            self.redirect_type = redirect_type
            self.destination_protocol = destination_protocol
            self.custom_path = custom_path
            self.custom_hostname = custom_hostname
            self.custom_query_string = custom_query_string
            self.custom_fragment = custom_fragment

    class UrlRewriteAction(DeliveryRuleAction):
        """Defines the url rewrite action for the delivery rule.

        All required parameters must be populated in order to send to Azure.

        :param name: Required. Constant filled by server.
        :type name: str
        :param parameters: Required. Defines the parameters for the action.
        :type parameters: ~azure.mgmt.cdn.models.UrlRewriteActionParameters
        """

        _validation = {
            'name': {'required': True},
            'parameters': {'required': True},
        }

        _attribute_map = {
            'name': {'key': 'name', 'type': 'str'},
            'parameters': {'key': 'parameters', 'type': 'UrlRewriteActionParameters'},
        }

        def __init__(self, *, parameters, **kwargs) -> None:
            super(UrlRewriteAction, self).__init__(**kwargs)
            self.parameters = parameters
            self.name = 'UrlRewrite'

    class UrlRewriteActionParameters(Model):
        """Defines the parameters for the url rewrite action.

        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 odatatype: Required.  Default value:
         "#Microsoft.Azure.Cdn.Models.DeliveryRuleUrlRewriteActionParameters" .
        :vartype odatatype: str
        :param source_pattern: Required. define a request URI pattern that
         identifies the type of requests that may be rewritten. Currently, source
         pattern uses a prefix-based match. To match all URL paths, use "/" as the
         source pattern value. To match only the root directory and re-write this
         path, use the origin path field
        :type source_pattern: str
        :param destination: Required. Define the destination path for be used in
         the rewrite. This will overwrite the source pattern
        :type destination: str
        :param preserve_unmatched_path: If True, the remaining path after the
         source pattern will be appended to the new destination path.
        :type preserve_unmatched_path: bool
        """

        _validation = {
            'odatatype': {'required': True, 'constant': True},
            'source_pattern': {'required': True},
            'destination': {'required': True},
        }

        _attribute_map = {
            'odatatype': {'key': '@odata\\.type', 'type': 'str'},
            'source_pattern': {'key': 'sourcePattern', 'type': 'str'},
            'destination': {'key': 'destination', 'type': 'str'},
            'preserve_unmatched_path': {'key': 'preserveUnmatchedPath', 'type': 'bool'},
        }

        odatatype = "#Microsoft.Azure.Cdn.Models.DeliveryRuleUrlRewriteActionParameters"

        def __init__(self, *, source_pattern: str, destination: str, preserve_unmatched_path: bool=None, **kwargs) -> None:
            super(UrlRewriteActionParameters, self).__init__(**kwargs)
            self.source_pattern = source_pattern
            self.destination = destination
            self.preserve_unmatched_path = preserve_unmatched_path

    class UserManagedHttpsParameters(CustomDomainHttpsParameters):
        """Defines the certificate source parameters using user's keyvault certificate
        for enabling SSL.

        All required parameters must be populated in order to send to Azure.

        :param protocol_type: Required. Defines the TLS extension protocol that is
         used for secure delivery. Possible values include: 'ServerNameIndication',
         'IPBased'
        :type protocol_type: str or ~azure.mgmt.cdn.models.ProtocolType
        :param minimum_tls_version: TLS protocol version that will be used for
         Https. Possible values include: 'None', 'TLS10', 'TLS12'
        :type minimum_tls_version: str or ~azure.mgmt.cdn.models.MinimumTlsVersion
        :param certificate_source: Required. Constant filled by server.
        :type certificate_source: str
        :param certificate_source_parameters: Required. Defines the certificate
         source parameters using user's keyvault certificate for enabling SSL.
        :type certificate_source_parameters:
         ~azure.mgmt.cdn.models.KeyVaultCertificateSourceParameters
        """

        _validation = {
            'protocol_type': {'required': True},
            'certificate_source': {'required': True},
            'certificate_source_parameters': {'required': True},
        }

        _attribute_map = {
            'protocol_type': {'key': 'protocolType', 'type': 'str'},
            'minimum_tls_version': {'key': 'minimumTlsVersion', 'type': 'MinimumTlsVersion'},
            'certificate_source': {'key': 'certificateSource', 'type': 'str'},
            'certificate_source_parameters': {'key': 'certificateSourceParameters', 'type': 'KeyVaultCertificateSourceParameters'},
        }

        def __init__(self, *, protocol_type, certificate_source_parameters, minimum_tls_version=None, **kwargs) -> None:
            super(UserManagedHttpsParameters, self).__init__(protocol_type=protocol_type, minimum_tls_version=minimum_tls_version, **kwargs)
            self.certificate_source_parameters = certificate_source_parameters
            self.certificate_source = 'AzureKeyVault'

    class ValidateCustomDomainInput(Model):
        """Input of the custom domain to be validated for DNS mapping.

        All required parameters must be populated in order to send to Azure.

        :param host_name: Required. The host name of the custom domain. Must be a
         domain name.
        :type host_name: str
        """

        _validation = {
            'host_name': {'required': True},
        }

        _attribute_map = {
            'host_name': {'key': 'hostName', 'type': 'str'},
        }

        def __init__(self, *, host_name: str, **kwargs) -> None:
            super(ValidateCustomDomainInput, self).__init__(**kwargs)
            self.host_name = host_name

    class ValidateCustomDomainOutput(Model):
        """Output of custom domain validation.

        Variables are only populated by the server, and will be ignored when
        sending a request.

        :ivar custom_domain_validated: Indicates whether the custom domain is
         valid or not.
        :vartype custom_domain_validated: bool
        :ivar reason: The reason why the custom domain is not valid.
        :vartype reason: str
        :ivar message: Error message describing why the custom domain is not
         valid.
        :vartype message: str
        """

        _validation = {
            'custom_domain_validated': {'readonly': True},
            'reason': {'readonly': True},
            'message': {'readonly': True},
        }

        _attribute_map = {
            'custom_domain_validated': {'key': 'customDomainValidated', 'type': 'bool'},
            'reason': {'key': 'reason', 'type': 'str'},
            'message': {'key': 'message', 'type': 'str'},
        }

        def __init__(self, **kwargs) -> None:
            super(ValidateCustomDomainOutput, self).__init__(**kwargs)
            self.custom_domain_validated = None
            self.reason = None
            self.message = None

    class ValidateProbeInput(Model):
        """Input of the validate probe API.

        All required parameters must be populated in order to send to Azure.

        :param probe_url: Required. The probe URL to validate.
        :type probe_url: str
        """

        _validation = {
            'probe_url': {'required': True},
        }

        _attribute_map = {
            'probe_url': {'key': 'probeURL', 'type': 'str'},
        }

        def __init__(self, *, probe_url: str, **kwargs) -> None:
            super(ValidateProbeInput, self).__init__(**kwargs)
            self.probe_url = probe_url

    class ValidateProbeOutput(Model):
        """Output of the validate probe API.

        Variables are only populated by the server, and will be ignored when
        sending a request.

        :ivar is_valid: Indicates whether the probe URL is accepted or not.
        :vartype is_valid: bool
        :ivar error_code: Specifies the error code when the probe url is not
         accepted.
        :vartype error_code: str
        :ivar message: The detailed error message describing why the probe URL is
         not accepted.
        :vartype message: str
        """

        _validation = {
            'is_valid': {'readonly': True},
            'error_code': {'readonly': True},
            'message': {'readonly': True},
        }

        _attribute_map = {
            'is_valid': {'key': 'isValid', 'type': 'bool'},
            'error_code': {'key': 'errorCode', 'type': 'str'},
            'message': {'key': 'message', 'type': 'str'},
        }

        def __init__(self, **kwargs) -> None:
            super(ValidateProbeOutput, self).__init__(**kwargs)
            self.is_valid = None
            self.error_code = None
            self.message = None