User management functions
This commit is contained in:
28
Azure/User-Management/README.md
Normal file
28
Azure/User-Management/README.md
Normal file
@@ -0,0 +1,28 @@
|
||||
# User Management Modules
|
||||
These script were written with the use of Gemini and are provided as is. Please test them before using anything in production
|
||||
|
||||
## Prerequisites
|
||||
For running the Modules you need the MSGraph Powershell module installed. Use the command below to install it if not already present on your system
|
||||
```
|
||||
Install-Module -Name Microsoft.Graph
|
||||
```
|
||||
|
||||
## Export Active user
|
||||
Use the following commands to connect to the Graph APi and to export all active users including their attributes.
|
||||
```
|
||||
# Authenticate
|
||||
Connect-MgGraph -Scopes "User.Read.All"
|
||||
|
||||
# Run the function with Verbose output to see progress
|
||||
Export-EntraActiveUsers -Verbose
|
||||
```
|
||||
|
||||
## Update Users
|
||||
In order to update the users, change all attributes you want to change in the CSV and run the following commands. Change the path of the source file.
|
||||
```
|
||||
# Authenticate
|
||||
Connect-MgGraph -Scopes "User.ReadWrite.All"
|
||||
|
||||
# Run the update with overwrite capability
|
||||
Update-EntraUsersOverwrite -CsvPath "$PSScriptRoot\Exports\MasterUserList.csv" -Verbose
|
||||
```
|
||||
Reference in New Issue
Block a user