azure.mgmt.resource.policy.v2018_05_01.models module
- class azure.mgmt.resource.policy.v2018_05_01.models.ErrorResponse(*, http_status: str | None = None, error_code: str | None = None, error_message: str | None = None, **kwargs: Any)[source]
Bases:
Model
Error response indicates Azure Resource Manager is not able to process the incoming request. The reason is provided in the error message.
- Variables:
- Keyword Arguments:
- class azure.mgmt.resource.policy.v2018_05_01.models.Identity(*, type: str | _models.ResourceIdentityType | None = None, **kwargs: Any)[source]
Bases:
Model
Identity for the resource.
Variables are only populated by the server, and will be ignored when sending a request.
- Variables:
principal_id (str) – The principal ID of the resource identity.
tenant_id (str) – The tenant ID of the resource identity.
type (str or ResourceIdentityType) – The identity type. Known values are: “SystemAssigned” and “None”.
- Keyword Arguments:
type (str or ResourceIdentityType) – The identity type. Known values are: “SystemAssigned” and “None”.
- class azure.mgmt.resource.policy.v2018_05_01.models.PolicyAssignment(*, sku: _models.PolicySku | None = None, location: str | None = None, identity: _models.Identity | None = None, display_name: str | None = None, policy_definition_id: str | None = None, scope: str | None = None, not_scopes: List[str] | None = None, parameters: MutableMapping[str, Any] | None = None, description: str | None = None, metadata: MutableMapping[str, Any] | None = None, **kwargs: Any)[source]
Bases:
Model
The policy assignment.
Variables are only populated by the server, and will be ignored when sending a request.
- Variables:
id (str) – The ID of the policy assignment.
type (str) – The type of the policy assignment.
name (str) – The name of the policy assignment.
sku (PolicySku) – The policy sku. This property is optional, obsolete, and will be ignored.
location (str) – The location of the policy assignment. Only required when utilizing managed identity.
identity (Identity) – The managed identity associated with the policy assignment.
display_name (str) – The display name of the policy assignment.
policy_definition_id (str) – The ID of the policy definition or policy set definition being assigned.
scope (str) – The scope for the policy assignment.
parameters (JSON) – Required if a parameter is used in policy rule.
description (str) – This message will be part of response in case of policy violation.
metadata (JSON) – The policy assignment metadata.
- Keyword Arguments:
sku (PolicySku) – The policy sku. This property is optional, obsolete, and will be ignored.
location (str) – The location of the policy assignment. Only required when utilizing managed identity.
identity (Identity) – The managed identity associated with the policy assignment.
display_name (str) – The display name of the policy assignment.
policy_definition_id (str) – The ID of the policy definition or policy set definition being assigned.
scope (str) – The scope for the policy assignment.
parameters (JSON) – Required if a parameter is used in policy rule.
description (str) – This message will be part of response in case of policy violation.
metadata (JSON) – The policy assignment metadata.
- class azure.mgmt.resource.policy.v2018_05_01.models.PolicyAssignmentListResult(*, value: List[_models.PolicyAssignment] | None = None, next_link: str | None = None, **kwargs: Any)[source]
Bases:
Model
List of policy assignments.
- Variables:
value (list[PolicyAssignment]) – An array of policy assignments.
next_link (str) – The URL to use for getting the next set of results.
- Keyword Arguments:
value (list[PolicyAssignment]) – An array of policy assignments.
next_link (str) – The URL to use for getting the next set of results.
- class azure.mgmt.resource.policy.v2018_05_01.models.PolicyDefinition(*, policy_type: str | _models.PolicyType | None = None, mode: str | _models.PolicyMode | None = None, display_name: str | None = None, description: str | None = None, policy_rule: MutableMapping[str, Any] | None = None, metadata: MutableMapping[str, Any] | None = None, parameters: MutableMapping[str, Any] | None = None, **kwargs: Any)[source]
Bases:
Model
The policy definition.
Variables are only populated by the server, and will be ignored when sending a request.
- Variables:
id (str) – The ID of the policy definition.
name (str) – The name of the policy definition.
type (str) – The type of the resource (Microsoft.Authorization/policyDefinitions).
policy_type (str or PolicyType) – The type of policy definition. Possible values are NotSpecified, BuiltIn, and Custom. Known values are: “NotSpecified”, “BuiltIn”, and “Custom”.
mode (str or PolicyMode) – The policy definition mode. Possible values are NotSpecified, Indexed, and All. Known values are: “NotSpecified”, “Indexed”, and “All”.
display_name (str) – The display name of the policy definition.
description (str) – The policy definition description.
policy_rule (JSON) – The policy rule.
metadata (JSON) – The policy definition metadata.
parameters (JSON) – Required if a parameter is used in policy rule.
- Keyword Arguments:
policy_type (str or PolicyType) – The type of policy definition. Possible values are NotSpecified, BuiltIn, and Custom. Known values are: “NotSpecified”, “BuiltIn”, and “Custom”.
mode (str or PolicyMode) – The policy definition mode. Possible values are NotSpecified, Indexed, and All. Known values are: “NotSpecified”, “Indexed”, and “All”.
display_name (str) – The display name of the policy definition.
description (str) – The policy definition description.
policy_rule (JSON) – The policy rule.
metadata (JSON) – The policy definition metadata.
parameters (JSON) – Required if a parameter is used in policy rule.
- class azure.mgmt.resource.policy.v2018_05_01.models.PolicyDefinitionListResult(*, value: List[_models.PolicyDefinition] | None = None, next_link: str | None = None, **kwargs: Any)[source]
Bases:
Model
List of policy definitions.
- Variables:
value (list[PolicyDefinition]) – An array of policy definitions.
next_link (str) – The URL to use for getting the next set of results.
- Keyword Arguments:
value (list[PolicyDefinition]) – An array of policy definitions.
next_link (str) – The URL to use for getting the next set of results.
- class azure.mgmt.resource.policy.v2018_05_01.models.PolicyDefinitionReference(*, policy_definition_id: str | None = None, parameters: MutableMapping[str, Any] | None = None, **kwargs: Any)[source]
Bases:
Model
The policy definition reference.
- Variables:
policy_definition_id (str) – The ID of the policy definition or policy set definition.
parameters (JSON) – Required if a parameter is used in policy rule.
- Keyword Arguments:
policy_definition_id (str) – The ID of the policy definition or policy set definition.
parameters (JSON) – Required if a parameter is used in policy rule.
- class azure.mgmt.resource.policy.v2018_05_01.models.PolicyMode(value, names=None, *, module=None, qualname=None, type=None, start=1, boundary=None)[source]
-
The policy definition mode. Possible values are NotSpecified, Indexed, and All.
- ALL = 'All'
- INDEXED = 'Indexed'
- NOT_SPECIFIED = 'NotSpecified'
- class azure.mgmt.resource.policy.v2018_05_01.models.PolicySetDefinition(*, policy_type: str | _models.PolicyType | None = None, display_name: str | None = None, description: str | None = None, metadata: MutableMapping[str, Any] | None = None, parameters: MutableMapping[str, Any] | None = None, policy_definitions: List[_models.PolicyDefinitionReference] | None = None, **kwargs: Any)[source]
Bases:
Model
The policy set definition.
Variables are only populated by the server, and will be ignored when sending a request.
- Variables:
id (str) – The ID of the policy set definition.
name (str) – The name of the policy set definition.
type (str) – The type of the resource (Microsoft.Authorization/policySetDefinitions).
policy_type (str or PolicyType) – The type of policy definition. Possible values are NotSpecified, BuiltIn, and Custom. Known values are: “NotSpecified”, “BuiltIn”, and “Custom”.
display_name (str) – The display name of the policy set definition.
description (str) – The policy set definition description.
metadata (JSON) – The policy set definition metadata.
parameters (JSON) – The policy set definition parameters that can be used in policy definition references.
policy_definitions (list[PolicyDefinitionReference]) – An array of policy definition references.
- Keyword Arguments:
policy_type (str or PolicyType) – The type of policy definition. Possible values are NotSpecified, BuiltIn, and Custom. Known values are: “NotSpecified”, “BuiltIn”, and “Custom”.
display_name (str) – The display name of the policy set definition.
description (str) – The policy set definition description.
metadata (JSON) – The policy set definition metadata.
parameters (JSON) – The policy set definition parameters that can be used in policy definition references.
policy_definitions (list[PolicyDefinitionReference]) – An array of policy definition references.
- class azure.mgmt.resource.policy.v2018_05_01.models.PolicySetDefinitionListResult(*, value: List[_models.PolicySetDefinition] | None = None, next_link: str | None = None, **kwargs: Any)[source]
Bases:
Model
List of policy set definitions.
- Variables:
value (list[PolicySetDefinition]) – An array of policy set definitions.
next_link (str) – The URL to use for getting the next set of results.
- Keyword Arguments:
value (list[PolicySetDefinition]) – An array of policy set definitions.
next_link (str) – The URL to use for getting the next set of results.
- class azure.mgmt.resource.policy.v2018_05_01.models.PolicySku(*, name: str, tier: str | None = None, **kwargs: Any)[source]
Bases:
Model
The policy sku. This property is optional, obsolete, and will be ignored.
All required parameters must be populated in order to send to server.
- Variables:
- Keyword Arguments:
- class azure.mgmt.resource.policy.v2018_05_01.models.PolicyType(value, names=None, *, module=None, qualname=None, type=None, start=1, boundary=None)[source]
-
The type of policy definition. Possible values are NotSpecified, BuiltIn, and Custom.
- BUILT_IN = 'BuiltIn'
- CUSTOM = 'Custom'
- NOT_SPECIFIED = 'NotSpecified'