Forum Discussion
Office 365 license consumption alert
- Mar 23, 2017
In terms of alerts, no. A quick glance at the Admin portal or the Reports can give you this info. If you need it automated it really takes few lines of PowerShell code to check for available licenses and fire up an email notification.
Its not pretty but this will do what you want. I have configured it for SPE_E3 sku but you can change it for which ever license type you want in the variables. it will send an email when there are 10 licenses left. Keep in mind if you use 10 licenses in between the script run cycles you might get notified too late.
$sku =Get-MsolAccountSku | where accountskuid -EQ "tennant:SPE_E3"
$skuactive=$sku | select activeunits
$skuconsumed=$sku | select consumedunits
$skuadd10 = $skuconsumed.ConsumedUnits +10
if ($skuadd10 -ge $skuactive.ActiveUnits) {Send-MailMessage -SmtpServer smtpserver01 -To geeman@maildomain.com -From geeman@maildomain.com -Body test -Subject test }
How do i add multiple SKU?
TA