Script repository
Assign Microsoft 365 license based on availability
The script assigns Microsoft 365 licenses based on their availability. For example, you can try assigning the Enterprise E5 license, and if there are no available E5 licenses, assign an Enterprise E3 one.
Updated on: Jan 18, 2026, Views: 8462
Assign Microsoft 365 licenses after adding to a group
The scripts assign Microsoft 365 licenses after adding to a group.
Updated on: Jan 18, 2026, Views: 4146
Assign/revoke Microsoft 365 licenses based on group membership priority
The script assigns/revokes Microsoft 365 licenses from a user based on their AD group membership.
Updated on: Jan 18, 2026, Views: 7289
Assigned Microsoft 365 licenses and services per OU
The script generates a report containing OUs directly located in a domain with the number of Microsoft 365 licenses and services assigned to users in the OUs.
Updated on: Jan 18, 2026, Views: 2259
Cancel user creation if there are no available Microsoft 365 licenses
The script cancels creation of a new user if the number of available Microsoft 365 licenses in tenant associated with the user is below limit.
Updated on: Jan 18, 2026, Views: 3576
Check Entra account last logon
The script checks whether the last logon date of the related Entra user account equals the current date.
Updated on: Jan 18, 2026, Views: 2185
Check Microsoft 365 license being assigned
The script checks whether the specified Microsoft 365 license is being assigned to a user within the current operation.
Updated on: Jan 18, 2026, Views: 7586
Check if number of unused Microsoft 365 licenses is below limit
The script returns true if the number of Microsoft 365 licenses is below limit.
Updated on: Jan 18, 2026, Views: 2857
Check whether Microsoft 365 user account is blocked
The script checks whether a user is blocked from signing in to Microsoft 365.
Updated on: Jan 18, 2026, Views: 3118
Connect to Microsoft Teams
The script establishes connection to Microsoft Teams.
Updated on: Jan 18, 2026, Views: 8861