What it is
A PowerShell script (BlockUsersWithoutLicense.ps1) that calls the Viva Engage network REST API with a Microsoft Entra access token to read the current per-user license enforcement state or to enforce per-user licensing for the network. Enforcement is irreversible, so confirm that the required service plans are provisioned to all users first.
Why use it
- Check whether per-user licensing is already enforced for your Viva Engage network.
- Enforce per-user licensing with the supported script instead of building your own REST calls.
How to use it
- Provision Viva Engage Core (recommended) or Yammer Enterprise service plans to all users. Enforcement can't be reversed.
- Get a valid Microsoft Entra access token for a Global Administrator of the Viva Engage network.
- Check the current state, then enforce when ready:
./BlockUsersWithoutLicense.ps1 fetch_current_license_state "<ENTRA_ACCESS_TOKEN>"
./BlockUsersWithoutLicense.ps1 enforce_user_license "<ENTRA_ACCESS_TOKEN>"Prerequisites
- Global administrator access to the Viva Engage network
- Viva Engage Core (recommended) or Yammer Enterprise service plans provisioned to all users before enforcing
- PowerShell 5.1 or later and network access to Viva Engage
- Applies to networks that have not previously enforced per-user licensing through the legacy Yammer admin center