Skip to content

New command: aad user remove #4494

@milanholemans

Description

@milanholemans

Usage

m365 aad user remove [options]

Description

Removes a specific user

Options

Option Description
--id [id] The ID of the user. Specify either id or userName but not both.
--userName [userName] User principal name of the user. Specify either id or userName but not both.
--confirm Don't prompt for confirmation.

Examples

Removes a specific user by id

m365 aad user remove --id a33bd401-9117-4e0e-bb7b-3f61c1539e10

Removes a specific user by its UPN

m365 aad user remove --name [email protected]

Default properties

No response

Additional Info

API info: https://learn.microsoft.com/en-us/graph/api/user-delete?view=graph-rest-1.0&tabs=http

Let's specify in the docs which roles you need to remove a user:

  • User Administrator
  • Privileged Authentication Administrator
  • Global Administrator

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions