Remove-EntraServicePrincipal
Removes a service principal.
Syntax
Remove-EntraServicePrincipal
-ServicePrincipalId <String>
[<CommonParameters>]
Description
The Remove-EntraServicePrincipal
cmdlet removes a service principal in Microsoft Entra ID.
Examples
Example 1: Removes a service principal
Connect-Entra -Scopes 'Application.ReadWrite.All','Application.ReadWrite.OwnedBy'
Get-EntraServicePrincipal -Filter "displayName eq 'Helpdesk Application'" | Remove-EntraServicePrincipal
This example demonstrates how to remove a service principal in Microsoft Entra ID.
-ServicePrincipalId
parameter specifies the service principal Id.
Parameters
-ServicePrincipalId
Specifies the ID of a service principal in Microsoft Entra ID.
Type: | System.String |
Aliases: | ObjectId |
Position: | Named |
Default value: | None |
Required: | True |
Accept pipeline input: | True |
Accept wildcard characters: | False |