azure.mgmt.authorization.v2022_05_01_preview.operations module¶
Bases:
objectWarning
DO NOT instantiate this class directly.
Instead, you should access the following operations through
AuthorizationManagementClient’spermissionsattribute.Gets all permissions the caller has for a resource.
- Parameters
resource_group_name (str) – The name of the resource group. The name is case insensitive. Required.
resource_provider_namespace (str) – The namespace of the resource provider. Required.
parent_resource_path (str) – The parent resource identity. Required.
resource_type (str) – The resource type of the resource. Required.
resource_name (str) – The name of the resource to get the permissions for. Required.
- Keyword Arguments
cls (callable) – A custom type or function that will be passed the direct response
- Returns
An iterator like instance of either Permission or the result of cls(response)
- Return type
- Raises
Gets all permissions the caller has for a resource group.
- Parameters
resource_group_name (str) – The name of the resource group. The name is case insensitive. Required.
- Keyword Arguments
cls (callable) – A custom type or function that will be passed the direct response
- Returns
An iterator like instance of either Permission or the result of cls(response)
- Return type
- Raises
Bases:
objectWarning
DO NOT instantiate this class directly.
Instead, you should access the following operations through
AuthorizationManagementClient’srole_definitionsattribute.-
create_or_update(scope: str, role_definition_id: str, role_definition: IO, *, content_type: str = "'application/json'", **kwargs: Any) → _models.RoleDefinition Creates or updates a role definition.
- Parameters
scope (str) – The scope of the operation or resource. Valid scopes are: subscription (format: ‘/subscriptions/{subscriptionId}’), resource group (format: ‘/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}’, or resource (format: ‘/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/[{parentResourcePath}/]{resourceType}/{resourceName}’. Required.
role_definition_id (str) – The ID of the role definition. Required.
role_definition (RoleDefinition or IO) – The values for the role definition. Is either a RoleDefinition type or a IO type. Required.
- Keyword Arguments
- Returns
RoleDefinition or the result of cls(response)
- Return type
- Raises
Deletes a role definition.
- Parameters
scope (str) – The scope of the operation or resource. Valid scopes are: subscription (format: ‘/subscriptions/{subscriptionId}’), resource group (format: ‘/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}’, or resource (format: ‘/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/[{parentResourcePath}/]{resourceType}/{resourceName}’. Required.
role_definition_id (str) – The ID of the role definition to delete. Required.
- Keyword Arguments
cls (callable) – A custom type or function that will be passed the direct response
- Returns
RoleDefinition or None or the result of cls(response)
- Return type
- Raises
Get role definition by ID (GUID).
- Parameters
scope (str) – The scope of the operation or resource. Valid scopes are: subscription (format: ‘/subscriptions/{subscriptionId}’), resource group (format: ‘/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}’, or resource (format: ‘/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/[{parentResourcePath}/]{resourceType}/{resourceName}’. Required.
role_definition_id (str) – The ID of the role definition. Required.
- Keyword Arguments
cls (callable) – A custom type or function that will be passed the direct response
- Returns
RoleDefinition or the result of cls(response)
- Return type
- Raises
Gets a role definition by ID.
- Parameters
role_id (str) – The fully qualified role definition ID. Use the format, /subscriptions/{guid}/providers/Microsoft.Authorization/roleDefinitions/{roleDefinitionId} for subscription level role definitions, or /providers/Microsoft.Authorization/roleDefinitions/{roleDefinitionId} for tenant level role definitions. Required.
- Keyword Arguments
cls (callable) – A custom type or function that will be passed the direct response
- Returns
RoleDefinition or the result of cls(response)
- Return type
- Raises
Get all role definitions that are applicable at scope and above.
- Parameters
scope (str) – The scope of the operation or resource. Valid scopes are: subscription (format: ‘/subscriptions/{subscriptionId}’), resource group (format: ‘/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}’, or resource (format: ‘/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/[{parentResourcePath}/]{resourceType}/{resourceName}’. Required.
filter (str) – The filter to apply on the operation. Use atScopeAndBelow filter to search below the given scope as well. Default value is None.
- Keyword Arguments
cls (callable) – A custom type or function that will be passed the direct response
- Returns
An iterator like instance of either RoleDefinition or the result of cls(response)
- Return type
- Raises
-