Forum Discussion
Carlos Gomez
Mar 23, 2017Brass Contributor
Office 365 license consumption alert
Hi, Does Microsoft provides any alerting on the case that availabe licenses to assign are\near to be 0? I already see that several blogs provide details for creating your own alerting\report ...
- 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.
SimBur2365
Sep 11, 2021Brass Contributor
There are quite a few scripts available now but I wanted to create my own to alert when the count of consumed licenses is getting close to or at 0. I wouldn't expect anyone to be keeping more than 1 or 2 licenses free in a tenant (depending on the size of the org of course). Who wants to pay for stuff you are not using? In fact I think MS should look at allowing a negative buffer so that clients do not have to always have '1 or more spare'; let's face it that is forcing someone to pay for something they are not using yet right? Anyway...
The best way to run this is by creating an Azure Automation account (the future of task scheduler =). In my script I use a free SendGrid account to send the email alert on port 587 (you cannot use outbound 25 from Azure without special permission), although now you can also add the SendGrid solution in Azure, then call it with variables as a playbook from an automation script (I haven't crossed that bridge yet!). The email is not very pretty in basic text format, but it does the job. You can easily schedule it in the automation account to run every hour or whatever suits your requirement. As in the notes it is easily modifiable to alert when free licenses get low or high or both. Hope it helps someone.
https://www.howdoiuseacomputer.com/index.php/2021/09/12/azure-microsoft-365-licensing-alert/
The best way to run this is by creating an Azure Automation account (the future of task scheduler =). In my script I use a free SendGrid account to send the email alert on port 587 (you cannot use outbound 25 from Azure without special permission), although now you can also add the SendGrid solution in Azure, then call it with variables as a playbook from an automation script (I haven't crossed that bridge yet!). The email is not very pretty in basic text format, but it does the job. You can easily schedule it in the automation account to run every hour or whatever suits your requirement. As in the notes it is easily modifiable to alert when free licenses get low or high or both. Hope it helps someone.
https://www.howdoiuseacomputer.com/index.php/2021/09/12/azure-microsoft-365-licensing-alert/