@Abner
Thank you for your post and I apologize for the delayed response!
Error Message:
Failed to delete application. Error detail: Insufficient privileges to complete the operation.
From your error message and as mentioned by @Dillon Silzer, you'll need the correct delete permissions to delete your Azure AD App Registration. I'll share some steps below to hopefully point you in the right direction.
Prerequisite:
To remove an Azure AD App Registration, you'll need the microsoft.directory/applications/delete
permission. This can be found in the roles below. For more info - Azure AD built-in roles.
- Global Administrator
- Application Administrator
- Cloud Application Administrator
- Hybrid Identity Administrator
- Directory Synchronization Accounts
Confirm user permissions:
To start off, you'll need to confirm your user's permissions/role within Azure AD, to ensure it matches the correct role above.
Note: If you already have the correct permissions and are running into issues deleting your app, please let me know.
- Navigate to Azure Active Directory
- On the right-hand side, there should be a "My Feed" section where you should be able to see your user's role.
Note: You can also view your permissions/role by navigating to Azure Active Directory -> Users -> Select your user -> Assigned Roles
Assign the correct role:
If your user doesn't have the correct permission(s)/role to delete your Azure AD App Registration, you'll need to assign one on the roles above to your user. To do this, you'll need to be a Privileged Role Administrator or Global Administrator.
Assign a Role:
If you can't assign roles, you'll need to reach out to a Privileged Role Admin or Global Admin within your tenant.
- Within Azure Active Directory, select Roles and administrators.
- Find the role you need for example - Global Administrator.
- Select the role name to open the role.
- Select Add assignments and then select the users you want to assign to this role.
- Select Add to assign the role.
Remove Azure AD App Registration:
Once you have the correct permissions to delete your Azure AD App Registration, you can retry the delete operation.
- Within Azure Active Directory, under Manage, select App registrations.
- Select the app that you want to delete.
- From the Overview page, select Delete.
- Read the deletion consequences. Check the box if one appears at the bottom of the pane.
- Select Delete to confirm that you want to delete the app.
I hope this helps!
If you have any other questions, please let me know.