DenyAssignmentsOperations Class
DenyAssignmentsOperations async operations.
You should not instantiate this class directly. Instead, you should create a Client instance that instantiates it for you and attaches it as an attribute.
- Inheritance
-
builtins.objectDenyAssignmentsOperations
Constructor
DenyAssignmentsOperations(client, config, serializer, deserializer)
Parameters
- client
Client for service requests.
- config
Configuration of service client.
- serializer
An object model serializer.
- deserializer
An object model deserializer.
Variables
- models
Alias to model classes used in this operation group.
Methods
| get |
Get the specified deny assignment. |
| get_by_id |
Gets a deny assignment by ID. |
| list |
Gets all deny assignments for the subscription. |
| list_for_resource |
Gets deny assignments for a resource. |
| list_for_resource_group |
Gets deny assignments for a resource group. |
| list_for_scope |
Gets deny assignments for a scope. |
get
Get the specified deny assignment.
async get(scope: str, deny_assignment_id: str, **kwargs: Any) -> azure.mgmt.authorization.v2018_07_01_preview.models._models_py3.DenyAssignment
Parameters
- cls
- callable
A custom type or function that will be passed the direct response
Returns
DenyAssignment, or the result of cls(response)
Return type
Exceptions
get_by_id
Gets a deny assignment by ID.
async get_by_id(deny_assignment_id: str, **kwargs: Any) -> azure.mgmt.authorization.v2018_07_01_preview.models._models_py3.DenyAssignment
Parameters
- deny_assignment_id
- str
The fully qualified deny assignment ID. For example, use the format, /subscriptions/{guid}/providers/Microsoft.Authorization/denyAssignments/{denyAssignmentId} for subscription level deny assignments, or /providers/Microsoft.Authorization/denyAssignments/{denyAssignmentId} for tenant level deny assignments.
- cls
- callable
A custom type or function that will be passed the direct response
Returns
DenyAssignment, or the result of cls(response)
Return type
Exceptions
list
Gets all deny assignments for the subscription.
list(filter: Optional[str] = None, **kwargs: Any) -> AsyncIterable[azure.mgmt.authorization.v2018_07_01_preview.models._models_py3.DenyAssignmentListResult]
Parameters
- filter
- str
The filter to apply on the operation. Use $filter=atScope() to return all deny assignments at or above the scope. Use $filter=denyAssignmentName eq '{name}' to search deny assignments by name at specified scope. Use $filter=principalId eq '{id}' to return all deny assignments at, above and below the scope for the specified principal. Use $filter=gdprExportPrincipalId eq '{id}' to return all deny assignments at, above and below the scope for the specified principal. This filter is different from the principalId filter as it returns not only those deny assignments that contain the specified principal is the Principals list but also those deny assignments that contain the specified principal is the ExcludePrincipals list. Additionally, when gdprExportPrincipalId filter is used, only the deny assignment name and description properties are returned.
- cls
- callable
A custom type or function that will be passed the direct response
Returns
An iterator like instance of either DenyAssignmentListResult or the result of cls(response)
Return type
Exceptions
list_for_resource
Gets deny assignments for a resource.
list_for_resource(resource_group_name: str, resource_provider_namespace: str, parent_resource_path: str, resource_type: str, resource_name: str, filter: Optional[str] = None, **kwargs: Any) -> AsyncIterable[azure.mgmt.authorization.v2018_07_01_preview.models._models_py3.DenyAssignmentListResult]
Parameters
- filter
- str
The filter to apply on the operation. Use $filter=atScope() to return all deny assignments at or above the scope. Use $filter=denyAssignmentName eq '{name}' to search deny assignments by name at specified scope. Use $filter=principalId eq '{id}' to return all deny assignments at, above and below the scope for the specified principal. Use $filter=gdprExportPrincipalId eq '{id}' to return all deny assignments at, above and below the scope for the specified principal. This filter is different from the principalId filter as it returns not only those deny assignments that contain the specified principal is the Principals list but also those deny assignments that contain the specified principal is the ExcludePrincipals list. Additionally, when gdprExportPrincipalId filter is used, only the deny assignment name and description properties are returned.
- cls
- callable
A custom type or function that will be passed the direct response
Returns
An iterator like instance of either DenyAssignmentListResult or the result of cls(response)
Return type
Exceptions
list_for_resource_group
Gets deny assignments for a resource group.
list_for_resource_group(resource_group_name: str, filter: Optional[str] = None, **kwargs: Any) -> AsyncIterable[azure.mgmt.authorization.v2018_07_01_preview.models._models_py3.DenyAssignmentListResult]
Parameters
- filter
- str
The filter to apply on the operation. Use $filter=atScope() to return all deny assignments at or above the scope. Use $filter=denyAssignmentName eq '{name}' to search deny assignments by name at specified scope. Use $filter=principalId eq '{id}' to return all deny assignments at, above and below the scope for the specified principal. Use $filter=gdprExportPrincipalId eq '{id}' to return all deny assignments at, above and below the scope for the specified principal. This filter is different from the principalId filter as it returns not only those deny assignments that contain the specified principal is the Principals list but also those deny assignments that contain the specified principal is the ExcludePrincipals list. Additionally, when gdprExportPrincipalId filter is used, only the deny assignment name and description properties are returned.
- cls
- callable
A custom type or function that will be passed the direct response
Returns
An iterator like instance of either DenyAssignmentListResult or the result of cls(response)
Return type
Exceptions
list_for_scope
Gets deny assignments for a scope.
list_for_scope(scope: str, filter: Optional[str] = None, **kwargs: Any) -> AsyncIterable[azure.mgmt.authorization.v2018_07_01_preview.models._models_py3.DenyAssignmentListResult]
Parameters
- filter
- str
The filter to apply on the operation. Use $filter=atScope() to return all deny assignments at or above the scope. Use $filter=denyAssignmentName eq '{name}' to search deny assignments by name at specified scope. Use $filter=principalId eq '{id}' to return all deny assignments at, above and below the scope for the specified principal. Use $filter=gdprExportPrincipalId eq '{id}' to return all deny assignments at, above and below the scope for the specified principal. This filter is different from the principalId filter as it returns not only those deny assignments that contain the specified principal is the Principals list but also those deny assignments that contain the specified principal is the ExcludePrincipals list. Additionally, when gdprExportPrincipalId filter is used, only the deny assignment name and description properties are returned.
- cls
- callable
A custom type or function that will be passed the direct response
Returns
An iterator like instance of either DenyAssignmentListResult or the result of cls(response)
Return type
Exceptions
Attributes
models
models = <module 'azure.mgmt.authorization.v2018_07_01_preview.models' from 'C:\\hostedtoolcache\\windows\\Python\\3.9.13\\x64\\lib\\site-packages\\azure\\mgmt\\authorization\\v2018_07_01_preview\\models\\__init__.py'>
Feedback
Submit and view feedback for