scripts related to Microsoft 365
PowerShell script that swaps Microsoft 365 licences using Microsoft Graph.
- Change
remove_LICandadd_LICvarriable to what you need. - Finds all the users that have the
remove_LICSKU. - For-each loop of the results and removes the license and outputs the license removed and the UPN of the user it was removed from. Then it adds the
add_LICSKU to the user and outputs the license added and the UPN of the user it was added to.
Prerequisites
- MS Graph PowerShell Module needs to be installed