Add-FabricDomainWorkspaceRoleAssignment
Bulk assigns roles to principals for workspaces in a Fabric domain.
Syntax
Add-FabricDomainWorkspaceRoleAssignment [-DomainId] <guid> [-DomainRole] <string>
[-PrincipalIds] <array> [<CommonParameters>]Description
The AssignFabricDomainWorkspaceRoleAssignment function performs bulk role assignments for principals in a specific Fabric domain. It sends a POST request to the relevant API endpoint.
Aliases: Assign-FabricDomainWorkspaceRoleAssignment
Examples
Example 1
Assign the Admins role to the specified principals in the domain with ID "12345".
Assign-FabricDomainWorkspaceRoleAssignment -DomainId "12345" -DomainRole "Admins" -PrincipalIds @(@{id="user1"; type="User"}, @{id="group1"; type="Group"})Parameters
| Name | Type | Req. | Pos. | Pipeline | Description |
|---|---|---|---|---|---|
| -DomainId | guid | ✓Required | 0 | – | The unique identifier of the Fabric domain where roles will be assigned. |
| -DomainRole | string | ✓Required | 1 | – | The role to assign to the principals. Must be one of the following:
|
| -PrincipalIds | array | ✓Required | 2 | – | An array of principals to assign roles to. Each principal must include:
|
This cmdlet also supports the common parameters, such as -Verbose and -ErrorAction. See about_CommonParameters.
Notes
- Calls
Confirm-TokenStateto ensure token validity before making the API request.
Author: Tiago Balabuch, Kamil Nowinski