The Set-AdminPowerAppConnectorRoleAssignment cmdlet sets up permission to custom connectors depending on the parameters.
Use Get-Help Set-AdminPowerAppConnectorRoleAssignment -Examples for more detail.
Gives the specified user CanView permissions to the connector with ID shared_testapi.5f0629412a7d1fe83e.5f6f049093c9b7a698.
Parameters
-ApiVersion
The api version to call with.
Parameter properties
Type:
String
Default value:
2017-06-01
Supports wildcards:
False
DontShow:
False
Parameter sets
(All)
Position:
Named
Mandatory:
False
Value from pipeline:
False
Value from pipeline by property name:
False
Value from remaining arguments:
False
-ConnectorName
The custom connector's identifier.
Parameter properties
Type:
String
Default value:
None
Supports wildcards:
False
DontShow:
False
Parameter sets
(All)
Position:
Named
Mandatory:
True
Value from pipeline:
False
Value from pipeline by property name:
True
Value from remaining arguments:
False
-EnvironmentName
The connectors's environment ID.
Parameter properties
Type:
String
Default value:
None
Supports wildcards:
False
DontShow:
False
Parameter sets
(All)
Position:
Named
Mandatory:
True
Value from pipeline:
False
Value from pipeline by property name:
True
Value from remaining arguments:
False
-PrincipalObjectId
If this connector is being shared with a user or security group principal, this field specifies the ObjectId for that principal.
Use the Get-UsersOrGroupsFromGraph cmdlet to look-up the ObjectId for a user or group in Microsoft Entra ID.
Parameter properties
Type:
String
Default value:
None
Supports wildcards:
False
DontShow:
False
Parameter sets
User
Position:
Named
Mandatory:
True
Value from pipeline:
False
Value from pipeline by property name:
False
Value from remaining arguments:
False
-PrincipalType
Specifies the type of principal this connector is being shared with; a user, a security group, or the entire tenant.
Parameter properties
Type:
String
Default value:
None
Supports wildcards:
False
DontShow:
False
Parameter sets
(All)
Position:
Named
Mandatory:
True
Value from pipeline:
False
Value from pipeline by property name:
True
Value from remaining arguments:
False
-RoleName
Specifies the permission level given to the connector: CanView, CanViewWithShare, CanEdit.
Sharing with the entire tenant is only supported for CanView.
Parameter properties
Type:
String
Default value:
None
Supports wildcards:
False
DontShow:
False
Parameter sets
(All)
Position:
Named
Mandatory:
True
Value from pipeline:
False
Value from pipeline by property name:
True
Value from remaining arguments:
False
CommonParameters
This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable,
-InformationAction, -InformationVariable, -OutBuffer, -OutVariable, -PipelineVariable,
-ProgressAction, -Verbose, -WarningAction, and -WarningVariable. For more information, see
about_CommonParameters.