# coding=utf-8
# --------------------------------------------------------------------------
# Copyright (c) Microsoft Corporation. All rights reserved.
# Licensed under the MIT License. See License.txt in the project root for license information.
# Code generated by Microsoft (R) AutoRest Code Generator.
# Changes may cause incorrect behavior and will be lost if the code is regenerated.
# --------------------------------------------------------------------------

import msrest.serialization


class AccessPolicyEntry(msrest.serialization.Model):
    """An identity that have access to the key vault. All identities in the array must use the same tenant ID as the key vault's tenant ID.

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

    :param tenant_id: Required. The Azure Active Directory tenant ID that should be used for
     authenticating requests to the key vault.
    :type tenant_id: str
    :param object_id: Required. The object ID of a user, service principal or security group in the
     Azure Active Directory tenant for the vault. The object ID must be unique for the list of
     access policies.
    :type object_id: str
    :param application_id: Application ID of the client making request on behalf of a principal.
    :type application_id: str
    :param permissions: Required. Permissions the identity has for keys, secrets and certificates.
    :type permissions: ~azure.mgmt.keyvault.v2019_09_01.models.Permissions
    """

    _validation = {
        'tenant_id': {'required': True},
        'object_id': {'required': True},
        'permissions': {'required': True},
    }

    _attribute_map = {
        'tenant_id': {'key': 'tenantId', 'type': 'str'},
        'object_id': {'key': 'objectId', 'type': 'str'},
        'application_id': {'key': 'applicationId', 'type': 'str'},
        'permissions': {'key': 'permissions', 'type': 'Permissions'},
    }

    def __init__(
        self,
        **kwargs
    ):
        super(AccessPolicyEntry, self).__init__(**kwargs)
        self.tenant_id = kwargs['tenant_id']
        self.object_id = kwargs['object_id']
        self.application_id = kwargs.get('application_id', None)
        self.permissions = kwargs['permissions']


class Attributes(msrest.serialization.Model):
    """The object attributes managed by the Azure Key Vault service.

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

    :param enabled: Determines whether or not the object is enabled.
    :type enabled: bool
    :param not_before: Not before date in seconds since 1970-01-01T00:00:00Z.
    :type not_before: long
    :param expires: Expiry date in seconds since 1970-01-01T00:00:00Z.
    :type expires: long
    :ivar created: Creation time in seconds since 1970-01-01T00:00:00Z.
    :vartype created: long
    :ivar updated: Last updated time in seconds since 1970-01-01T00:00:00Z.
    :vartype updated: long
    :ivar recovery_level: The deletion recovery level currently in effect for the object. If it
     contains 'Purgeable', then the object can be permanently deleted by a privileged user;
     otherwise, only the system can purge the object at the end of the retention interval. Possible
     values include: "Purgeable", "Recoverable+Purgeable", "Recoverable",
     "Recoverable+ProtectedSubscription".
    :vartype recovery_level: str or ~azure.mgmt.keyvault.v2019_09_01.models.DeletionRecoveryLevel
    """

    _validation = {
        'created': {'readonly': True},
        'updated': {'readonly': True},
        'recovery_level': {'readonly': True},
    }

    _attribute_map = {
        'enabled': {'key': 'enabled', 'type': 'bool'},
        'not_before': {'key': 'nbf', 'type': 'long'},
        'expires': {'key': 'exp', 'type': 'long'},
        'created': {'key': 'created', 'type': 'long'},
        'updated': {'key': 'updated', 'type': 'long'},
        'recovery_level': {'key': 'recoveryLevel', 'type': 'str'},
    }

    def __init__(
        self,
        **kwargs
    ):
        super(Attributes, self).__init__(**kwargs)
        self.enabled = kwargs.get('enabled', None)
        self.not_before = kwargs.get('not_before', None)
        self.expires = kwargs.get('expires', None)
        self.created = None
        self.updated = None
        self.recovery_level = None


class CheckNameAvailabilityResult(msrest.serialization.Model):
    """The CheckNameAvailability operation response.

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

    :ivar name_available: A boolean value that indicates whether the name is available for you to
     use. If true, the name is available. If false, the name has already been taken or is invalid
     and cannot be used.
    :vartype name_available: bool
    :ivar reason: The reason that a vault name could not be used. The Reason element is only
     returned if NameAvailable is false. Possible values include: "AccountNameInvalid",
     "AlreadyExists".
    :vartype reason: str or ~azure.mgmt.keyvault.v2019_09_01.models.Reason
    :ivar message: An error message explaining the Reason value in more detail.
    :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
    ):
        super(CheckNameAvailabilityResult, self).__init__(**kwargs)
        self.name_available = None
        self.reason = None
        self.message = None


class CloudErrorBody(msrest.serialization.Model):
    """An error response from Key Vault resource provider.

    :param code: Error code. This is a mnemonic that can be consumed programmatically.
    :type code: str
    :param message: User friendly error message. The message is typically localized and may vary
     with service version.
    :type message: str
    """

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

    def __init__(
        self,
        **kwargs
    ):
        super(CloudErrorBody, self).__init__(**kwargs)
        self.code = kwargs.get('code', None)
        self.message = kwargs.get('message', None)


class DeletedVault(msrest.serialization.Model):
    """Deleted vault information with extended details.

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

    :ivar id: The resource ID for the deleted key vault.
    :vartype id: str
    :ivar name: The name of the key vault.
    :vartype name: str
    :ivar type: The resource type of the key vault.
    :vartype type: str
    :param properties: Properties of the vault.
    :type properties: ~azure.mgmt.keyvault.v2019_09_01.models.DeletedVaultProperties
    """

    _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'},
        'properties': {'key': 'properties', 'type': 'DeletedVaultProperties'},
    }

    def __init__(
        self,
        **kwargs
    ):
        super(DeletedVault, self).__init__(**kwargs)
        self.id = None
        self.name = None
        self.type = None
        self.properties = kwargs.get('properties', None)


class DeletedVaultListResult(msrest.serialization.Model):
    """List of vaults.

    :param value: The list of deleted vaults.
    :type value: list[~azure.mgmt.keyvault.v2019_09_01.models.DeletedVault]
    :param next_link: The URL to get the next set of deleted vaults.
    :type next_link: str
    """

    _attribute_map = {
        'value': {'key': 'value', 'type': '[DeletedVault]'},
        'next_link': {'key': 'nextLink', 'type': 'str'},
    }

    def __init__(
        self,
        **kwargs
    ):
        super(DeletedVaultListResult, self).__init__(**kwargs)
        self.value = kwargs.get('value', None)
        self.next_link = kwargs.get('next_link', None)


class DeletedVaultProperties(msrest.serialization.Model):
    """Properties of the deleted vault.

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

    :ivar vault_id: The resource id of the original vault.
    :vartype vault_id: str
    :ivar location: The location of the original vault.
    :vartype location: str
    :ivar deletion_date: The deleted date.
    :vartype deletion_date: ~datetime.datetime
    :ivar scheduled_purge_date: The scheduled purged date.
    :vartype scheduled_purge_date: ~datetime.datetime
    :ivar tags: A set of tags. Tags of the original vault.
    :vartype tags: dict[str, str]
    :ivar purge_protection_enabled: Purge protection status of the original vault.
    :vartype purge_protection_enabled: bool
    """

    _validation = {
        'vault_id': {'readonly': True},
        'location': {'readonly': True},
        'deletion_date': {'readonly': True},
        'scheduled_purge_date': {'readonly': True},
        'tags': {'readonly': True},
        'purge_protection_enabled': {'readonly': True},
    }

    _attribute_map = {
        'vault_id': {'key': 'vaultId', 'type': 'str'},
        'location': {'key': 'location', 'type': 'str'},
        'deletion_date': {'key': 'deletionDate', 'type': 'iso-8601'},
        'scheduled_purge_date': {'key': 'scheduledPurgeDate', 'type': 'iso-8601'},
        'tags': {'key': 'tags', 'type': '{str}'},
        'purge_protection_enabled': {'key': 'purgeProtectionEnabled', 'type': 'bool'},
    }

    def __init__(
        self,
        **kwargs
    ):
        super(DeletedVaultProperties, self).__init__(**kwargs)
        self.vault_id = None
        self.location = None
        self.deletion_date = None
        self.scheduled_purge_date = None
        self.tags = None
        self.purge_protection_enabled = None


class DimensionProperties(msrest.serialization.Model):
    """Type of operation: get, read, delete, etc.

    :param name: Name of dimension.
    :type name: str
    :param display_name: Display name of dimension.
    :type display_name: str
    :param to_be_exported_for_shoebox: Property to specify whether the dimension should be exported
     for shoebox.
    :type to_be_exported_for_shoebox: bool
    """

    _attribute_map = {
        'name': {'key': 'name', 'type': 'str'},
        'display_name': {'key': 'displayName', 'type': 'str'},
        'to_be_exported_for_shoebox': {'key': 'toBeExportedForShoebox', 'type': 'bool'},
    }

    def __init__(
        self,
        **kwargs
    ):
        super(DimensionProperties, self).__init__(**kwargs)
        self.name = kwargs.get('name', None)
        self.display_name = kwargs.get('display_name', None)
        self.to_be_exported_for_shoebox = kwargs.get('to_be_exported_for_shoebox', None)


class IPRule(msrest.serialization.Model):
    """A rule governing the accessibility of a vault from a specific ip address or ip range.

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

    :param value: Required. An IPv4 address range in CIDR notation, such as '124.56.78.91' (simple
     IP address) or '124.56.78.0/24' (all addresses that start with 124.56.78).
    :type value: str
    """

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

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

    def __init__(
        self,
        **kwargs
    ):
        super(IPRule, self).__init__(**kwargs)
        self.value = kwargs['value']


class Resource(msrest.serialization.Model):
    """Key Vault resource.

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

    :ivar id: Fully qualified identifier of the key vault resource.
    :vartype id: str
    :ivar name: Name of the key vault resource.
    :vartype name: str
    :ivar type: Resource type of the key vault resource.
    :vartype type: str
    :ivar location: Azure location of the key vault resource.
    :vartype location: str
    :ivar tags: A set of tags. Tags assigned to the key vault resource.
    :vartype tags: dict[str, str]
    """

    _validation = {
        'id': {'readonly': True},
        'name': {'readonly': True},
        'type': {'readonly': True},
        'location': {'readonly': True},
        'tags': {'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}'},
    }

    def __init__(
        self,
        **kwargs
    ):
        super(Resource, self).__init__(**kwargs)
        self.id = None
        self.name = None
        self.type = None
        self.location = None
        self.tags = None


class Key(Resource):
    """The key resource.

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

    :ivar id: Fully qualified identifier of the key vault resource.
    :vartype id: str
    :ivar name: Name of the key vault resource.
    :vartype name: str
    :ivar type: Resource type of the key vault resource.
    :vartype type: str
    :ivar location: Azure location of the key vault resource.
    :vartype location: str
    :ivar tags: A set of tags. Tags assigned to the key vault resource.
    :vartype tags: dict[str, str]
    :param attributes: The attributes of the key.
    :type attributes: ~azure.mgmt.keyvault.v2019_09_01.models.KeyAttributes
    :param kty: The type of the key. For valid values, see JsonWebKeyType. Possible values include:
     "EC", "EC-HSM", "RSA", "RSA-HSM".
    :type kty: str or ~azure.mgmt.keyvault.v2019_09_01.models.JsonWebKeyType
    :param key_ops:
    :type key_ops: list[str or ~azure.mgmt.keyvault.v2019_09_01.models.JsonWebKeyOperation]
    :param key_size: The key size in bits. For example: 2048, 3072, or 4096 for RSA.
    :type key_size: int
    :param curve_name: The elliptic curve name. For valid values, see JsonWebKeyCurveName. Possible
     values include: "P-256", "P-384", "P-521", "P-256K".
    :type curve_name: str or ~azure.mgmt.keyvault.v2019_09_01.models.JsonWebKeyCurveName
    :ivar key_uri: The URI to retrieve the current version of the key.
    :vartype key_uri: str
    :ivar key_uri_with_version: The URI to retrieve the specific version of the key.
    :vartype key_uri_with_version: str
    """

    _validation = {
        'id': {'readonly': True},
        'name': {'readonly': True},
        'type': {'readonly': True},
        'location': {'readonly': True},
        'tags': {'readonly': True},
        'key_uri': {'readonly': True},
        'key_uri_with_version': {'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}'},
        'attributes': {'key': 'properties.attributes', 'type': 'KeyAttributes'},
        'kty': {'key': 'properties.kty', 'type': 'str'},
        'key_ops': {'key': 'properties.keyOps', 'type': '[str]'},
        'key_size': {'key': 'properties.keySize', 'type': 'int'},
        'curve_name': {'key': 'properties.curveName', 'type': 'str'},
        'key_uri': {'key': 'properties.keyUri', 'type': 'str'},
        'key_uri_with_version': {'key': 'properties.keyUriWithVersion', 'type': 'str'},
    }

    def __init__(
        self,
        **kwargs
    ):
        super(Key, self).__init__(**kwargs)
        self.attributes = kwargs.get('attributes', None)
        self.kty = kwargs.get('kty', None)
        self.key_ops = kwargs.get('key_ops', None)
        self.key_size = kwargs.get('key_size', None)
        self.curve_name = kwargs.get('curve_name', None)
        self.key_uri = None
        self.key_uri_with_version = None


class KeyAttributes(Attributes):
    """The attributes of the key.

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

    :param enabled: Determines whether or not the object is enabled.
    :type enabled: bool
    :param not_before: Not before date in seconds since 1970-01-01T00:00:00Z.
    :type not_before: long
    :param expires: Expiry date in seconds since 1970-01-01T00:00:00Z.
    :type expires: long
    :ivar created: Creation time in seconds since 1970-01-01T00:00:00Z.
    :vartype created: long
    :ivar updated: Last updated time in seconds since 1970-01-01T00:00:00Z.
    :vartype updated: long
    :ivar recovery_level: The deletion recovery level currently in effect for the object. If it
     contains 'Purgeable', then the object can be permanently deleted by a privileged user;
     otherwise, only the system can purge the object at the end of the retention interval. Possible
     values include: "Purgeable", "Recoverable+Purgeable", "Recoverable",
     "Recoverable+ProtectedSubscription".
    :vartype recovery_level: str or ~azure.mgmt.keyvault.v2019_09_01.models.DeletionRecoveryLevel
    """

    _validation = {
        'created': {'readonly': True},
        'updated': {'readonly': True},
        'recovery_level': {'readonly': True},
    }

    _attribute_map = {
        'enabled': {'key': 'enabled', 'type': 'bool'},
        'not_before': {'key': 'nbf', 'type': 'long'},
        'expires': {'key': 'exp', 'type': 'long'},
        'created': {'key': 'created', 'type': 'long'},
        'updated': {'key': 'updated', 'type': 'long'},
        'recovery_level': {'key': 'recoveryLevel', 'type': 'str'},
    }

    def __init__(
        self,
        **kwargs
    ):
        super(KeyAttributes, self).__init__(**kwargs)


class KeyCreateParameters(msrest.serialization.Model):
    """The parameters used to create a key.

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

    :param tags: A set of tags. The tags that will be assigned to the key.
    :type tags: dict[str, str]
    :param properties: Required. The properties of the key to be created.
    :type properties: ~azure.mgmt.keyvault.v2019_09_01.models.KeyProperties
    """

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

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

    def __init__(
        self,
        **kwargs
    ):
        super(KeyCreateParameters, self).__init__(**kwargs)
        self.tags = kwargs.get('tags', None)
        self.properties = kwargs['properties']


class KeyListResult(msrest.serialization.Model):
    """The page of keys.

    :param value: The key resources.
    :type value: list[~azure.mgmt.keyvault.v2019_09_01.models.Key]
    :param next_link: The URL to get the next page of keys.
    :type next_link: str
    """

    _attribute_map = {
        'value': {'key': 'value', 'type': '[Key]'},
        'next_link': {'key': 'nextLink', 'type': 'str'},
    }

    def __init__(
        self,
        **kwargs
    ):
        super(KeyListResult, self).__init__(**kwargs)
        self.value = kwargs.get('value', None)
        self.next_link = kwargs.get('next_link', None)


class KeyProperties(msrest.serialization.Model):
    """The properties of the key.

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

    :param attributes: The attributes of the key.
    :type attributes: ~azure.mgmt.keyvault.v2019_09_01.models.KeyAttributes
    :param kty: The type of the key. For valid values, see JsonWebKeyType. Possible values include:
     "EC", "EC-HSM", "RSA", "RSA-HSM".
    :type kty: str or ~azure.mgmt.keyvault.v2019_09_01.models.JsonWebKeyType
    :param key_ops:
    :type key_ops: list[str or ~azure.mgmt.keyvault.v2019_09_01.models.JsonWebKeyOperation]
    :param key_size: The key size in bits. For example: 2048, 3072, or 4096 for RSA.
    :type key_size: int
    :param curve_name: The elliptic curve name. For valid values, see JsonWebKeyCurveName. Possible
     values include: "P-256", "P-384", "P-521", "P-256K".
    :type curve_name: str or ~azure.mgmt.keyvault.v2019_09_01.models.JsonWebKeyCurveName
    :ivar key_uri: The URI to retrieve the current version of the key.
    :vartype key_uri: str
    :ivar key_uri_with_version: The URI to retrieve the specific version of the key.
    :vartype key_uri_with_version: str
    """

    _validation = {
        'key_uri': {'readonly': True},
        'key_uri_with_version': {'readonly': True},
    }

    _attribute_map = {
        'attributes': {'key': 'attributes', 'type': 'KeyAttributes'},
        'kty': {'key': 'kty', 'type': 'str'},
        'key_ops': {'key': 'keyOps', 'type': '[str]'},
        'key_size': {'key': 'keySize', 'type': 'int'},
        'curve_name': {'key': 'curveName', 'type': 'str'},
        'key_uri': {'key': 'keyUri', 'type': 'str'},
        'key_uri_with_version': {'key': 'keyUriWithVersion', 'type': 'str'},
    }

    def __init__(
        self,
        **kwargs
    ):
        super(KeyProperties, self).__init__(**kwargs)
        self.attributes = kwargs.get('attributes', None)
        self.kty = kwargs.get('kty', None)
        self.key_ops = kwargs.get('key_ops', None)
        self.key_size = kwargs.get('key_size', None)
        self.curve_name = kwargs.get('curve_name', None)
        self.key_uri = None
        self.key_uri_with_version = None


class LogSpecification(msrest.serialization.Model):
    """Log specification of operation.

    :param name: Name of log specification.
    :type name: str
    :param display_name: Display name of log specification.
    :type display_name: str
    :param blob_duration: Blob duration of specification.
    :type blob_duration: str
    """

    _attribute_map = {
        'name': {'key': 'name', 'type': 'str'},
        'display_name': {'key': 'displayName', 'type': 'str'},
        'blob_duration': {'key': 'blobDuration', 'type': 'str'},
    }

    def __init__(
        self,
        **kwargs
    ):
        super(LogSpecification, self).__init__(**kwargs)
        self.name = kwargs.get('name', None)
        self.display_name = kwargs.get('display_name', None)
        self.blob_duration = kwargs.get('blob_duration', None)


class MetricSpecification(msrest.serialization.Model):
    """Metric specification of operation.

    :param name: Name of metric specification.
    :type name: str
    :param display_name: Display name of Metric specification.
    :type display_name: str
    :param display_description: Display description of Metric specification.
    :type display_description: str
    :param unit: The metric unit. Possible values include: 'Bytes', 'Count', 'Milliseconds'.
    :type unit: str
    :param aggregation_type: The metric aggregation type. Possible values include: 'Average',
     'Count', 'Total'.
    :type aggregation_type: str
    :param supported_aggregation_types: The supported aggregation types for the metrics.
    :type supported_aggregation_types: list[str]
    :param supported_time_grain_types: The supported time grain types for the metrics.
    :type supported_time_grain_types: list[str]
    :param lock_aggregation_type: The metric lock aggregation type.
    :type lock_aggregation_type: str
    :param dimensions: The dimensions of metric.
    :type dimensions: list[~azure.mgmt.keyvault.v2019_09_01.models.DimensionProperties]
    :param fill_gap_with_zero: Property to specify whether to fill gap with zero.
    :type fill_gap_with_zero: bool
    :param internal_metric_name: The internal metric name.
    :type internal_metric_name: str
    """

    _attribute_map = {
        'name': {'key': 'name', 'type': 'str'},
        'display_name': {'key': 'displayName', 'type': 'str'},
        'display_description': {'key': 'displayDescription', 'type': 'str'},
        'unit': {'key': 'unit', 'type': 'str'},
        'aggregation_type': {'key': 'aggregationType', 'type': 'str'},
        'supported_aggregation_types': {'key': 'supportedAggregationTypes', 'type': '[str]'},
        'supported_time_grain_types': {'key': 'supportedTimeGrainTypes', 'type': '[str]'},
        'lock_aggregation_type': {'key': 'lockAggregationType', 'type': 'str'},
        'dimensions': {'key': 'dimensions', 'type': '[DimensionProperties]'},
        'fill_gap_with_zero': {'key': 'fillGapWithZero', 'type': 'bool'},
        'internal_metric_name': {'key': 'internalMetricName', 'type': 'str'},
    }

    def __init__(
        self,
        **kwargs
    ):
        super(MetricSpecification, self).__init__(**kwargs)
        self.name = kwargs.get('name', None)
        self.display_name = kwargs.get('display_name', None)
        self.display_description = kwargs.get('display_description', None)
        self.unit = kwargs.get('unit', None)
        self.aggregation_type = kwargs.get('aggregation_type', None)
        self.supported_aggregation_types = kwargs.get('supported_aggregation_types', None)
        self.supported_time_grain_types = kwargs.get('supported_time_grain_types', None)
        self.lock_aggregation_type = kwargs.get('lock_aggregation_type', None)
        self.dimensions = kwargs.get('dimensions', None)
        self.fill_gap_with_zero = kwargs.get('fill_gap_with_zero', None)
        self.internal_metric_name = kwargs.get('internal_metric_name', None)


class NetworkRuleSet(msrest.serialization.Model):
    """A set of rules governing the network accessibility of a vault.

    :param bypass: Tells what traffic can bypass network rules. This can be 'AzureServices' or
     'None'.  If not specified the default is 'AzureServices'. Possible values include:
     "AzureServices", "None".
    :type bypass: str or ~azure.mgmt.keyvault.v2019_09_01.models.NetworkRuleBypassOptions
    :param default_action: The default action when no rule from ipRules and from
     virtualNetworkRules match. This is only used after the bypass property has been evaluated.
     Possible values include: "Allow", "Deny".
    :type default_action: str or ~azure.mgmt.keyvault.v2019_09_01.models.NetworkRuleAction
    :param ip_rules: The list of IP address rules.
    :type ip_rules: list[~azure.mgmt.keyvault.v2019_09_01.models.IPRule]
    :param virtual_network_rules: The list of virtual network rules.
    :type virtual_network_rules: list[~azure.mgmt.keyvault.v2019_09_01.models.VirtualNetworkRule]
    """

    _attribute_map = {
        'bypass': {'key': 'bypass', 'type': 'str'},
        'default_action': {'key': 'defaultAction', 'type': 'str'},
        'ip_rules': {'key': 'ipRules', 'type': '[IPRule]'},
        'virtual_network_rules': {'key': 'virtualNetworkRules', 'type': '[VirtualNetworkRule]'},
    }

    def __init__(
        self,
        **kwargs
    ):
        super(NetworkRuleSet, self).__init__(**kwargs)
        self.bypass = kwargs.get('bypass', None)
        self.default_action = kwargs.get('default_action', None)
        self.ip_rules = kwargs.get('ip_rules', None)
        self.virtual_network_rules = kwargs.get('virtual_network_rules', None)


class Operation(msrest.serialization.Model):
    """Key Vault REST API operation definition.

    :param name: Operation name: {provider}/{resource}/{operation}.
    :type name: str
    :param display: Display metadata associated with the operation.
    :type display: ~azure.mgmt.keyvault.v2019_09_01.models.OperationDisplay
    :param origin: The origin of operations.
    :type origin: str
    :param is_data_action: Property to specify whether the action is a data action.
    :type is_data_action: bool
    :param service_specification: One property of operation, include metric specifications.
    :type service_specification: ~azure.mgmt.keyvault.v2019_09_01.models.ServiceSpecification
    """

    _attribute_map = {
        'name': {'key': 'name', 'type': 'str'},
        'display': {'key': 'display', 'type': 'OperationDisplay'},
        'origin': {'key': 'origin', 'type': 'str'},
        'is_data_action': {'key': 'isDataAction', 'type': 'bool'},
        'service_specification': {'key': 'properties.serviceSpecification', 'type': 'ServiceSpecification'},
    }

    def __init__(
        self,
        **kwargs
    ):
        super(Operation, self).__init__(**kwargs)
        self.name = kwargs.get('name', None)
        self.display = kwargs.get('display', None)
        self.origin = kwargs.get('origin', None)
        self.is_data_action = kwargs.get('is_data_action', None)
        self.service_specification = kwargs.get('service_specification', None)


class OperationDisplay(msrest.serialization.Model):
    """Display metadata associated with the operation.

    :param provider: Service provider: Microsoft Key Vault.
    :type provider: str
    :param resource: Resource on which the operation is performed etc.
    :type resource: str
    :param operation: Type of operation: get, read, delete, etc.
    :type operation: str
    :param description: Description of operation.
    :type description: str
    """

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

    def __init__(
        self,
        **kwargs
    ):
        super(OperationDisplay, self).__init__(**kwargs)
        self.provider = kwargs.get('provider', None)
        self.resource = kwargs.get('resource', None)
        self.operation = kwargs.get('operation', None)
        self.description = kwargs.get('description', None)


class OperationListResult(msrest.serialization.Model):
    """Result of the request to list Storage operations. It contains a list of operations and a URL link to get the next set of results.

    :param value: List of Storage operations supported by the Storage resource provider.
    :type value: list[~azure.mgmt.keyvault.v2019_09_01.models.Operation]
    :param next_link: The URL to get the next set of operations.
    :type next_link: str
    """

    _attribute_map = {
        'value': {'key': 'value', 'type': '[Operation]'},
        'next_link': {'key': 'nextLink', 'type': 'str'},
    }

    def __init__(
        self,
        **kwargs
    ):
        super(OperationListResult, self).__init__(**kwargs)
        self.value = kwargs.get('value', None)
        self.next_link = kwargs.get('next_link', None)


class Permissions(msrest.serialization.Model):
    """Permissions the identity has for keys, secrets, certificates and storage.

    :param keys: Permissions to keys.
    :type keys: list[str or ~azure.mgmt.keyvault.v2019_09_01.models.KeyPermissions]
    :param secrets: Permissions to secrets.
    :type secrets: list[str or ~azure.mgmt.keyvault.v2019_09_01.models.SecretPermissions]
    :param certificates: Permissions to certificates.
    :type certificates: list[str or ~azure.mgmt.keyvault.v2019_09_01.models.CertificatePermissions]
    :param storage: Permissions to storage accounts.
    :type storage: list[str or ~azure.mgmt.keyvault.v2019_09_01.models.StoragePermissions]
    """

    _attribute_map = {
        'keys': {'key': 'keys', 'type': '[str]'},
        'secrets': {'key': 'secrets', 'type': '[str]'},
        'certificates': {'key': 'certificates', 'type': '[str]'},
        'storage': {'key': 'storage', 'type': '[str]'},
    }

    def __init__(
        self,
        **kwargs
    ):
        super(Permissions, self).__init__(**kwargs)
        self.keys = kwargs.get('keys', None)
        self.secrets = kwargs.get('secrets', None)
        self.certificates = kwargs.get('certificates', None)
        self.storage = kwargs.get('storage', None)


class PrivateEndpoint(msrest.serialization.Model):
    """Private endpoint object properties.

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

    :ivar id: Full identifier of the private endpoint resource.
    :vartype id: str
    """

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

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

    def __init__(
        self,
        **kwargs
    ):
        super(PrivateEndpoint, self).__init__(**kwargs)
        self.id = None


class PrivateEndpointConnection(Resource):
    """Private endpoint connection resource.

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

    :ivar id: Fully qualified identifier of the key vault resource.
    :vartype id: str
    :ivar name: Name of the key vault resource.
    :vartype name: str
    :ivar type: Resource type of the key vault resource.
    :vartype type: str
    :ivar location: Azure location of the key vault resource.
    :vartype location: str
    :ivar tags: A set of tags. Tags assigned to the key vault resource.
    :vartype tags: dict[str, str]
    :param etag: Modified whenever there is a change in the state of private endpoint connection.
    :type etag: str
    :param private_endpoint: Properties of the private endpoint object.
    :type private_endpoint: ~azure.mgmt.keyvault.v2019_09_01.models.PrivateEndpoint
    :param private_link_service_connection_state: Approval state of the private link connection.
    :type private_link_service_connection_state:
     ~azure.mgmt.keyvault.v2019_09_01.models.PrivateLinkServiceConnectionState
    :ivar provisioning_state: Provisioning state of the private endpoint connection. Possible
     values include: "Succeeded", "Creating", "Updating", "Deleting", "Failed", "Disconnected".
    :vartype provisioning_state: str or
     ~azure.mgmt.keyvault.v2019_09_01.models.PrivateEndpointConnectionProvisioningState
    """

    _validation = {
        'id': {'readonly': True},
        'name': {'readonly': True},
        'type': {'readonly': True},
        'location': {'readonly': True},
        'tags': {'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}'},
        'etag': {'key': 'etag', 'type': 'str'},
        'private_endpoint': {'key': 'properties.privateEndpoint', 'type': 'PrivateEndpoint'},
        'private_link_service_connection_state': {'key': 'properties.privateLinkServiceConnectionState', 'type': 'PrivateLinkServiceConnectionState'},
        'provisioning_state': {'key': 'properties.provisioningState', 'type': 'str'},
    }

    def __init__(
        self,
        **kwargs
    ):
        super(PrivateEndpointConnection, self).__init__(**kwargs)
        self.etag = kwargs.get('etag', None)
        self.private_endpoint = kwargs.get('private_endpoint', None)
        self.private_link_service_connection_state = kwargs.get('private_link_service_connection_state', None)
        self.provisioning_state = None


class PrivateEndpointConnectionItem(msrest.serialization.Model):
    """Private endpoint connection item.

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

    :param id: Id of private endpoint connection.
    :type id: str
    :param etag: Modified whenever there is a change in the state of private endpoint connection.
    :type etag: str
    :param private_endpoint: Properties of the private endpoint object.
    :type private_endpoint: ~azure.mgmt.keyvault.v2019_09_01.models.PrivateEndpoint
    :param private_link_service_connection_state: Approval state of the private link connection.
    :type private_link_service_connection_state:
     ~azure.mgmt.keyvault.v2019_09_01.models.PrivateLinkServiceConnectionState
    :ivar provisioning_state: Provisioning state of the private endpoint connection. Possible
     values include: "Succeeded", "Creating", "Updating", "Deleting", "Failed", "Disconnected".
    :vartype provisioning_state: str or
     ~azure.mgmt.keyvault.v2019_09_01.models.PrivateEndpointConnectionProvisioningState
    """

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

    _attribute_map = {
        'id': {'key': 'id', 'type': 'str'},
        'etag': {'key': 'etag', 'type': 'str'},
        'private_endpoint': {'key': 'properties.privateEndpoint', 'type': 'PrivateEndpoint'},
        'private_link_service_connection_state': {'key': 'properties.privateLinkServiceConnectionState', 'type': 'PrivateLinkServiceConnectionState'},
        'provisioning_state': {'key': 'properties.provisioningState', 'type': 'str'},
    }

    def __init__(
        self,
        **kwargs
    ):
        super(PrivateEndpointConnectionItem, self).__init__(**kwargs)
        self.id = kwargs.get('id', None)
        self.etag = kwargs.get('etag', None)
        self.private_endpoint = kwargs.get('private_endpoint', None)
        self.private_link_service_connection_state = kwargs.get('private_link_service_connection_state', None)
        self.provisioning_state = None


class PrivateLinkResource(Resource):
    """A private link resource.

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

    :ivar id: Fully qualified identifier of the key vault resource.
    :vartype id: str
    :ivar name: Name of the key vault resource.
    :vartype name: str
    :ivar type: Resource type of the key vault resource.
    :vartype type: str
    :ivar location: Azure location of the key vault resource.
    :vartype location: str
    :ivar tags: A set of tags. Tags assigned to the key vault resource.
    :vartype tags: dict[str, str]
    :ivar group_id: Group identifier of private link resource.
    :vartype group_id: str
    :ivar required_members: Required member names of private link resource.
    :vartype required_members: list[str]
    :param required_zone_names: Required DNS zone names of the the private link resource.
    :type required_zone_names: list[str]
    """

    _validation = {
        'id': {'readonly': True},
        'name': {'readonly': True},
        'type': {'readonly': True},
        'location': {'readonly': True},
        'tags': {'readonly': True},
        'group_id': {'readonly': True},
        'required_members': {'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}'},
        'group_id': {'key': 'properties.groupId', 'type': 'str'},
        'required_members': {'key': 'properties.requiredMembers', 'type': '[str]'},
        'required_zone_names': {'key': 'properties.requiredZoneNames', 'type': '[str]'},
    }

    def __init__(
        self,
        **kwargs
    ):
        super(PrivateLinkResource, self).__init__(**kwargs)
        self.group_id = None
        self.required_members = None
        self.required_zone_names = kwargs.get('required_zone_names', None)


class PrivateLinkResourceListResult(msrest.serialization.Model):
    """A list of private link resources.

    :param value: Array of private link resources.
    :type value: list[~azure.mgmt.keyvault.v2019_09_01.models.PrivateLinkResource]
    """

    _attribute_map = {
        'value': {'key': 'value', 'type': '[PrivateLinkResource]'},
    }

    def __init__(
        self,
        **kwargs
    ):
        super(PrivateLinkResourceListResult, self).__init__(**kwargs)
        self.value = kwargs.get('value', None)


class PrivateLinkServiceConnectionState(msrest.serialization.Model):
    """An object that represents the approval state of the private link connection.

    :param status: Indicates whether the connection has been approved, rejected or removed by the
     key vault owner. Possible values include: "Pending", "Approved", "Rejected", "Disconnected".
    :type status: str or
     ~azure.mgmt.keyvault.v2019_09_01.models.PrivateEndpointServiceConnectionStatus
    :param description: The reason for approval or rejection.
    :type description: str
    :param actions_required: A message indicating if changes on the service provider require any
     updates on the consumer.
    :type actions_required: str
    """

    _attribute_map = {
        'status': {'key': 'status', 'type': 'str'},
        'description': {'key': 'description', 'type': 'str'},
        'actions_required': {'key': 'actionsRequired', 'type': 'str'},
    }

    def __init__(
        self,
        **kwargs
    ):
        super(PrivateLinkServiceConnectionState, self).__init__(**kwargs)
        self.status = kwargs.get('status', None)
        self.description = kwargs.get('description', None)
        self.actions_required = kwargs.get('actions_required', None)


class ResourceListResult(msrest.serialization.Model):
    """List of vault resources.

    :param value: The list of vault resources.
    :type value: list[~azure.mgmt.keyvault.v2019_09_01.models.Resource]
    :param next_link: The URL to get the next set of vault resources.
    :type next_link: str
    """

    _attribute_map = {
        'value': {'key': 'value', 'type': '[Resource]'},
        'next_link': {'key': 'nextLink', 'type': 'str'},
    }

    def __init__(
        self,
        **kwargs
    ):
        super(ResourceListResult, self).__init__(**kwargs)
        self.value = kwargs.get('value', None)
        self.next_link = kwargs.get('next_link', None)


class ServiceSpecification(msrest.serialization.Model):
    """One property of operation, include log specifications.

    :param log_specifications: Log specifications of operation.
    :type log_specifications: list[~azure.mgmt.keyvault.v2019_09_01.models.LogSpecification]
    :param metric_specifications: Metric specifications of operation.
    :type metric_specifications: list[~azure.mgmt.keyvault.v2019_09_01.models.MetricSpecification]
    """

    _attribute_map = {
        'log_specifications': {'key': 'logSpecifications', 'type': '[LogSpecification]'},
        'metric_specifications': {'key': 'metricSpecifications', 'type': '[MetricSpecification]'},
    }

    def __init__(
        self,
        **kwargs
    ):
        super(ServiceSpecification, self).__init__(**kwargs)
        self.log_specifications = kwargs.get('log_specifications', None)
        self.metric_specifications = kwargs.get('metric_specifications', None)


class Sku(msrest.serialization.Model):
    """SKU details.

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

    :param family: Required. SKU family name. Possible values include: "A".
    :type family: str or ~azure.mgmt.keyvault.v2019_09_01.models.SkuFamily
    :param name: Required. SKU name to specify whether the key vault is a standard vault or a
     premium vault. Possible values include: "standard", "premium".
    :type name: str or ~azure.mgmt.keyvault.v2019_09_01.models.SkuName
    """

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

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

    def __init__(
        self,
        **kwargs
    ):
        super(Sku, self).__init__(**kwargs)
        self.family = kwargs.get('family', "A")
        self.name = kwargs['name']


class Vault(msrest.serialization.Model):
    """Resource information with extended details.

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

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

    :ivar id: Fully qualified identifier of the key vault resource.
    :vartype id: str
    :ivar name: Name of the key vault resource.
    :vartype name: str
    :ivar type: Resource type of the key vault resource.
    :vartype type: str
    :param location: Azure location of the key vault resource.
    :type location: str
    :param tags: A set of tags. Tags assigned to the key vault resource.
    :type tags: dict[str, str]
    :param properties: Required. Properties of the vault.
    :type properties: ~azure.mgmt.keyvault.v2019_09_01.models.VaultProperties
    """

    _validation = {
        'id': {'readonly': True},
        'name': {'readonly': True},
        'type': {'readonly': True},
        'properties': {'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}'},
        'properties': {'key': 'properties', 'type': 'VaultProperties'},
    }

    def __init__(
        self,
        **kwargs
    ):
        super(Vault, self).__init__(**kwargs)
        self.id = None
        self.name = None
        self.type = None
        self.location = kwargs.get('location', None)
        self.tags = kwargs.get('tags', None)
        self.properties = kwargs['properties']


class VaultAccessPolicyParameters(msrest.serialization.Model):
    """Parameters for updating the access policy in a vault.

    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: The resource id of the access policy.
    :vartype id: str
    :ivar name: The resource name of the access policy.
    :vartype name: str
    :ivar type: The resource name of the access policy.
    :vartype type: str
    :ivar location: The resource type of the access policy.
    :vartype location: str
    :param properties: Required. Properties of the access policy.
    :type properties: ~azure.mgmt.keyvault.v2019_09_01.models.VaultAccessPolicyProperties
    """

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

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

    def __init__(
        self,
        **kwargs
    ):
        super(VaultAccessPolicyParameters, self).__init__(**kwargs)
        self.id = None
        self.name = None
        self.type = None
        self.location = None
        self.properties = kwargs['properties']


class VaultAccessPolicyProperties(msrest.serialization.Model):
    """Properties of the vault access policy.

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

    :param access_policies: Required. An array of 0 to 16 identities that have access to the key
     vault. All identities in the array must use the same tenant ID as the key vault's tenant ID.
    :type access_policies: list[~azure.mgmt.keyvault.v2019_09_01.models.AccessPolicyEntry]
    """

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

    _attribute_map = {
        'access_policies': {'key': 'accessPolicies', 'type': '[AccessPolicyEntry]'},
    }

    def __init__(
        self,
        **kwargs
    ):
        super(VaultAccessPolicyProperties, self).__init__(**kwargs)
        self.access_policies = kwargs['access_policies']


class VaultCheckNameAvailabilityParameters(msrest.serialization.Model):
    """The parameters used to check the availability of the vault name.

    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 vault name.
    :type name: str
    :ivar type: The type of resource, Microsoft.KeyVault/vaults. Has constant value:
     "Microsoft.KeyVault/vaults".
    :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.KeyVault/vaults"

    def __init__(
        self,
        **kwargs
    ):
        super(VaultCheckNameAvailabilityParameters, self).__init__(**kwargs)
        self.name = kwargs['name']


class VaultCreateOrUpdateParameters(msrest.serialization.Model):
    """Parameters for creating or updating a vault.

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

    :param location: Required. The supported Azure location where the key vault should be created.
    :type location: str
    :param tags: A set of tags. The tags that will be assigned to the key vault.
    :type tags: dict[str, str]
    :param properties: Required. Properties of the vault.
    :type properties: ~azure.mgmt.keyvault.v2019_09_01.models.VaultProperties
    """

    _validation = {
        'location': {'required': True},
        'properties': {'required': True},
    }

    _attribute_map = {
        'location': {'key': 'location', 'type': 'str'},
        'tags': {'key': 'tags', 'type': '{str}'},
        'properties': {'key': 'properties', 'type': 'VaultProperties'},
    }

    def __init__(
        self,
        **kwargs
    ):
        super(VaultCreateOrUpdateParameters, self).__init__(**kwargs)
        self.location = kwargs['location']
        self.tags = kwargs.get('tags', None)
        self.properties = kwargs['properties']


class VaultListResult(msrest.serialization.Model):
    """List of vaults.

    :param value: The list of vaults.
    :type value: list[~azure.mgmt.keyvault.v2019_09_01.models.Vault]
    :param next_link: The URL to get the next set of vaults.
    :type next_link: str
    """

    _attribute_map = {
        'value': {'key': 'value', 'type': '[Vault]'},
        'next_link': {'key': 'nextLink', 'type': 'str'},
    }

    def __init__(
        self,
        **kwargs
    ):
        super(VaultListResult, self).__init__(**kwargs)
        self.value = kwargs.get('value', None)
        self.next_link = kwargs.get('next_link', None)


class VaultPatchParameters(msrest.serialization.Model):
    """Parameters for creating or updating a vault.

    :param tags: A set of tags. The tags that will be assigned to the key vault.
    :type tags: dict[str, str]
    :param properties: Properties of the vault.
    :type properties: ~azure.mgmt.keyvault.v2019_09_01.models.VaultPatchProperties
    """

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

    def __init__(
        self,
        **kwargs
    ):
        super(VaultPatchParameters, self).__init__(**kwargs)
        self.tags = kwargs.get('tags', None)
        self.properties = kwargs.get('properties', None)


class VaultPatchProperties(msrest.serialization.Model):
    """Properties of the vault.

    :param tenant_id: The Azure Active Directory tenant ID that should be used for authenticating
     requests to the key vault.
    :type tenant_id: str
    :param sku: SKU details.
    :type sku: ~azure.mgmt.keyvault.v2019_09_01.models.Sku
    :param access_policies: An array of 0 to 16 identities that have access to the key vault. All
     identities in the array must use the same tenant ID as the key vault's tenant ID.
    :type access_policies: list[~azure.mgmt.keyvault.v2019_09_01.models.AccessPolicyEntry]
    :param enabled_for_deployment: Property to specify whether Azure Virtual Machines are permitted
     to retrieve certificates stored as secrets from the key vault.
    :type enabled_for_deployment: bool
    :param enabled_for_disk_encryption: Property to specify whether Azure Disk Encryption is
     permitted to retrieve secrets from the vault and unwrap keys.
    :type enabled_for_disk_encryption: bool
    :param enabled_for_template_deployment: Property to specify whether Azure Resource Manager is
     permitted to retrieve secrets from the key vault.
    :type enabled_for_template_deployment: bool
    :param enable_soft_delete: Property to specify whether the 'soft delete' functionality is
     enabled for this key vault. Once set to true, it cannot be reverted to false.
    :type enable_soft_delete: bool
    :param enable_rbac_authorization: Property that controls how data actions are authorized. When
     true, the key vault will use Role Based Access Control (RBAC) for authorization of data
     actions, and the access policies specified in vault properties will be  ignored. When false,
     the key vault will use the access policies specified in vault properties, and any policy stored
     on Azure Resource Manager will be ignored. If null or not specified, the value of this property
     will not change.
    :type enable_rbac_authorization: bool
    :param soft_delete_retention_in_days: softDelete data retention days. It accepts >=7 and <=90.
    :type soft_delete_retention_in_days: int
    :param create_mode: The vault's create mode to indicate whether the vault need to be recovered
     or not. Possible values include: "recover", "default".
    :type create_mode: str or ~azure.mgmt.keyvault.v2019_09_01.models.CreateMode
    :param enable_purge_protection: Property specifying whether protection against purge is enabled
     for this vault. Setting this property to true activates protection against purge for this vault
     and its content - only the Key Vault service may initiate a hard, irrecoverable deletion. The
     setting is effective only if soft delete is also enabled. Enabling this functionality is
     irreversible - that is, the property does not accept false as its value.
    :type enable_purge_protection: bool
    :param network_acls: A collection of rules governing the accessibility of the vault from
     specific network locations.
    :type network_acls: ~azure.mgmt.keyvault.v2019_09_01.models.NetworkRuleSet
    """

    _attribute_map = {
        'tenant_id': {'key': 'tenantId', 'type': 'str'},
        'sku': {'key': 'sku', 'type': 'Sku'},
        'access_policies': {'key': 'accessPolicies', 'type': '[AccessPolicyEntry]'},
        'enabled_for_deployment': {'key': 'enabledForDeployment', 'type': 'bool'},
        'enabled_for_disk_encryption': {'key': 'enabledForDiskEncryption', 'type': 'bool'},
        'enabled_for_template_deployment': {'key': 'enabledForTemplateDeployment', 'type': 'bool'},
        'enable_soft_delete': {'key': 'enableSoftDelete', 'type': 'bool'},
        'enable_rbac_authorization': {'key': 'enableRbacAuthorization', 'type': 'bool'},
        'soft_delete_retention_in_days': {'key': 'softDeleteRetentionInDays', 'type': 'int'},
        'create_mode': {'key': 'createMode', 'type': 'str'},
        'enable_purge_protection': {'key': 'enablePurgeProtection', 'type': 'bool'},
        'network_acls': {'key': 'networkAcls', 'type': 'NetworkRuleSet'},
    }

    def __init__(
        self,
        **kwargs
    ):
        super(VaultPatchProperties, self).__init__(**kwargs)
        self.tenant_id = kwargs.get('tenant_id', None)
        self.sku = kwargs.get('sku', None)
        self.access_policies = kwargs.get('access_policies', None)
        self.enabled_for_deployment = kwargs.get('enabled_for_deployment', None)
        self.enabled_for_disk_encryption = kwargs.get('enabled_for_disk_encryption', None)
        self.enabled_for_template_deployment = kwargs.get('enabled_for_template_deployment', None)
        self.enable_soft_delete = kwargs.get('enable_soft_delete', None)
        self.enable_rbac_authorization = kwargs.get('enable_rbac_authorization', None)
        self.soft_delete_retention_in_days = kwargs.get('soft_delete_retention_in_days', None)
        self.create_mode = kwargs.get('create_mode', None)
        self.enable_purge_protection = kwargs.get('enable_purge_protection', None)
        self.network_acls = kwargs.get('network_acls', None)


class VaultProperties(msrest.serialization.Model):
    """Properties of the vault.

    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 tenant_id: Required. The Azure Active Directory tenant ID that should be used for
     authenticating requests to the key vault.
    :type tenant_id: str
    :param sku: Required. SKU details.
    :type sku: ~azure.mgmt.keyvault.v2019_09_01.models.Sku
    :param access_policies: An array of 0 to 1024 identities that have access to the key vault. All
     identities in the array must use the same tenant ID as the key vault's tenant ID. When
     ``createMode`` is set to ``recover``\ , access policies are not required. Otherwise, access
     policies are required.
    :type access_policies: list[~azure.mgmt.keyvault.v2019_09_01.models.AccessPolicyEntry]
    :param vault_uri: The URI of the vault for performing operations on keys and secrets. This
     property is readonly.
    :type vault_uri: str
    :ivar hsm_pool_resource_id: The resource id of HSM Pool.
    :vartype hsm_pool_resource_id: str
    :param enabled_for_deployment: Property to specify whether Azure Virtual Machines are permitted
     to retrieve certificates stored as secrets from the key vault.
    :type enabled_for_deployment: bool
    :param enabled_for_disk_encryption: Property to specify whether Azure Disk Encryption is
     permitted to retrieve secrets from the vault and unwrap keys.
    :type enabled_for_disk_encryption: bool
    :param enabled_for_template_deployment: Property to specify whether Azure Resource Manager is
     permitted to retrieve secrets from the key vault.
    :type enabled_for_template_deployment: bool
    :param enable_soft_delete: Property to specify whether the 'soft delete' functionality is
     enabled for this key vault. If it's not set to any value(true or false) when creating new key
     vault, it will be set to true by default. Once set to true, it cannot be reverted to false.
    :type enable_soft_delete: bool
    :param soft_delete_retention_in_days: softDelete data retention days. It accepts >=7 and <=90.
    :type soft_delete_retention_in_days: int
    :param enable_rbac_authorization: Property that controls how data actions are authorized. When
     true, the key vault will use Role Based Access Control (RBAC) for authorization of data
     actions, and the access policies specified in vault properties will be  ignored. When false,
     the key vault will use the access policies specified in vault properties, and any policy stored
     on Azure Resource Manager will be ignored. If null or not specified, the vault is created with
     the default value of false. Note that management actions are always authorized with RBAC.
    :type enable_rbac_authorization: bool
    :param create_mode: The vault's create mode to indicate whether the vault need to be recovered
     or not. Possible values include: "recover", "default".
    :type create_mode: str or ~azure.mgmt.keyvault.v2019_09_01.models.CreateMode
    :param enable_purge_protection: Property specifying whether protection against purge is enabled
     for this vault. Setting this property to true activates protection against purge for this vault
     and its content - only the Key Vault service may initiate a hard, irrecoverable deletion. The
     setting is effective only if soft delete is also enabled. Enabling this functionality is
     irreversible - that is, the property does not accept false as its value.
    :type enable_purge_protection: bool
    :param network_acls: Rules governing the accessibility of the key vault from specific network
     locations.
    :type network_acls: ~azure.mgmt.keyvault.v2019_09_01.models.NetworkRuleSet
    :param provisioning_state: Provisioning state of the vault. Possible values include:
     "Succeeded", "RegisteringDns".
    :type provisioning_state: str or ~azure.mgmt.keyvault.v2019_09_01.models.VaultProvisioningState
    :ivar private_endpoint_connections: List of private endpoint connections associated with the
     key vault.
    :vartype private_endpoint_connections:
     list[~azure.mgmt.keyvault.v2019_09_01.models.PrivateEndpointConnectionItem]
    """

    _validation = {
        'tenant_id': {'required': True},
        'sku': {'required': True},
        'hsm_pool_resource_id': {'readonly': True},
        'private_endpoint_connections': {'readonly': True},
    }

    _attribute_map = {
        'tenant_id': {'key': 'tenantId', 'type': 'str'},
        'sku': {'key': 'sku', 'type': 'Sku'},
        'access_policies': {'key': 'accessPolicies', 'type': '[AccessPolicyEntry]'},
        'vault_uri': {'key': 'vaultUri', 'type': 'str'},
        'hsm_pool_resource_id': {'key': 'hsmPoolResourceId', 'type': 'str'},
        'enabled_for_deployment': {'key': 'enabledForDeployment', 'type': 'bool'},
        'enabled_for_disk_encryption': {'key': 'enabledForDiskEncryption', 'type': 'bool'},
        'enabled_for_template_deployment': {'key': 'enabledForTemplateDeployment', 'type': 'bool'},
        'enable_soft_delete': {'key': 'enableSoftDelete', 'type': 'bool'},
        'soft_delete_retention_in_days': {'key': 'softDeleteRetentionInDays', 'type': 'int'},
        'enable_rbac_authorization': {'key': 'enableRbacAuthorization', 'type': 'bool'},
        'create_mode': {'key': 'createMode', 'type': 'str'},
        'enable_purge_protection': {'key': 'enablePurgeProtection', 'type': 'bool'},
        'network_acls': {'key': 'networkAcls', 'type': 'NetworkRuleSet'},
        'provisioning_state': {'key': 'provisioningState', 'type': 'str'},
        'private_endpoint_connections': {'key': 'privateEndpointConnections', 'type': '[PrivateEndpointConnectionItem]'},
    }

    def __init__(
        self,
        **kwargs
    ):
        super(VaultProperties, self).__init__(**kwargs)
        self.tenant_id = kwargs['tenant_id']
        self.sku = kwargs['sku']
        self.access_policies = kwargs.get('access_policies', None)
        self.vault_uri = kwargs.get('vault_uri', None)
        self.hsm_pool_resource_id = None
        self.enabled_for_deployment = kwargs.get('enabled_for_deployment', None)
        self.enabled_for_disk_encryption = kwargs.get('enabled_for_disk_encryption', None)
        self.enabled_for_template_deployment = kwargs.get('enabled_for_template_deployment', None)
        self.enable_soft_delete = kwargs.get('enable_soft_delete', True)
        self.soft_delete_retention_in_days = kwargs.get('soft_delete_retention_in_days', 90)
        self.enable_rbac_authorization = kwargs.get('enable_rbac_authorization', False)
        self.create_mode = kwargs.get('create_mode', None)
        self.enable_purge_protection = kwargs.get('enable_purge_protection', None)
        self.network_acls = kwargs.get('network_acls', None)
        self.provisioning_state = kwargs.get('provisioning_state', None)
        self.private_endpoint_connections = None


class VirtualNetworkRule(msrest.serialization.Model):
    """A rule governing the accessibility of a vault from a specific virtual network.

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

    :param id: Required. Full resource id of a vnet subnet, such as
     '/subscriptions/subid/resourceGroups/rg1/providers/Microsoft.Network/virtualNetworks/test-vnet/subnets/subnet1'.
    :type id: str
    :param ignore_missing_vnet_service_endpoint: Property to specify whether NRP will ignore the
     check if parent subnet has serviceEndpoints configured.
    :type ignore_missing_vnet_service_endpoint: bool
    """

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

    _attribute_map = {
        'id': {'key': 'id', 'type': 'str'},
        'ignore_missing_vnet_service_endpoint': {'key': 'ignoreMissingVnetServiceEndpoint', 'type': 'bool'},
    }

    def __init__(
        self,
        **kwargs
    ):
        super(VirtualNetworkRule, self).__init__(**kwargs)
        self.id = kwargs['id']
        self.ignore_missing_vnet_service_endpoint = kwargs.get('ignore_missing_vnet_service_endpoint', None)
