Skip to main content

role_management_policy_assignments

Creates, updates, deletes, gets or lists a role_management_policy_assignments resource.

Overview

Namerole_management_policy_assignments
TypeResource
Identra_id.policies.role_management_policy_assignments

Fields

The following fields are returned by SELECT queries:

Retrieved navigation property

NameDatatypeDescription
idstringThe unique identifier for an entity. Read-only.
policyThe policy that's associated with a policy assignment. Supports $expand and a nested $expand of the rules and effectiveRules relationships for the policy.
policyIdstringThe id of the policy. Inherited from entity.
roleDefinitionIdstringFor Microsoft Entra roles policy, it's the identifier of the role definition object where the policy applies. For PIM for Groups membership and ownership, it's either member or owner. Supports $filter (eq).
scopeIdstringThe identifier of the scope where the policy is assigned. Can be / for the tenant or a group ID. Required.
scopeTypestringThe type of the scope where the policy is assigned. One of Directory, DirectoryRole, Group. Required.

Methods

The following methods are available for this resource:

NameAccessible byRequired ParamsOptional ParamsDescription
getselectunified_role_management_policy_assignment_idGet the details of a policy assignment in PIM that's assigned to Microsoft Entra roles or group membership or ownership.
listselectGet the details of all role management policy assignments made in PIM for Microsoft Entra roles and PIM for Groups.
insertinsert
updateupdateunified_role_management_policy_assignment_id
deletedeleteunified_role_management_policy_assignment_idIf-Match

Parameters

Parameters can be passed in the WHERE clause of a query. Check the Methods section to see which parameters are required or optional for each operation.

NameDatatypeDescription
unified_role_management_policy_assignment_idstringThe unique identifier of unifiedRoleManagementPolicyAssignment
If-MatchstringETag

SELECT examples

Get the details of a policy assignment in PIM that's assigned to Microsoft Entra roles or group membership or ownership.

SELECT
id,
policy,
policyId,
roleDefinitionId,
scopeId,
scopeType
FROM entra_id.policies.role_management_policy_assignments
WHERE unified_role_management_policy_assignment_id = '{{ unified_role_management_policy_assignment_id }}' -- required
;

INSERT examples

No description available.

INSERT INTO entra_id.policies.role_management_policy_assignments (
id,
policyId,
roleDefinitionId,
scopeId,
scopeType,
policy
)
SELECT
'{{ id }}',
'{{ policyId }}',
'{{ roleDefinitionId }}',
'{{ scopeId }}',
'{{ scopeType }}',
'{{ policy }}'
RETURNING
id,
policy,
policyId,
roleDefinitionId,
scopeId,
scopeType
;

UPDATE examples

No description available.

UPDATE entra_id.policies.role_management_policy_assignments
SET
id = '{{ id }}',
policyId = '{{ policyId }}',
roleDefinitionId = '{{ roleDefinitionId }}',
scopeId = '{{ scopeId }}',
scopeType = '{{ scopeType }}',
policy = '{{ policy }}'
WHERE
unified_role_management_policy_assignment_id = '{{ unified_role_management_policy_assignment_id }}' --required
RETURNING
id,
policy,
policyId,
roleDefinitionId,
scopeId,
scopeType;

DELETE examples

No description available.

DELETE FROM entra_id.policies.role_management_policy_assignments
WHERE unified_role_management_policy_assignment_id = '{{ unified_role_management_policy_assignment_id }}' --required
AND If-Match = '{{ If-Match }}'
;