For those who want to administrate Intune with the help of powershell there’s been a good source of sample scripts over at https://github.com/microsoftgraph/powershell-intune-samples for quite some time now. If you want to interact with Intune, Azure, O365 and more you need to use Microsofts Graph API. To get started with Intune and Graph API I recommend you take a look at Niall Brady’s post on how to get started
During Microsoft Ignite 2018 in Orlando there was a session about a Powershell SDK for Intune which was very intressting because it removes some of the barriers for people who are used to Powershell but not might have the time to dive in to Graph API specifially. The SDK contains cmdlets that communicates through Graph API behind the scenes but you as the adminstrator doesnt have to think about doing webrequest to the API and so on.
I highly recommend wathing the session “Learn how to leverage Intune support for Microsoft Graph and Powershell to enable powerful automation and IT security” from Ignite 2018 about the SDK.
Here’s just a quick walkthrough on how to get started and use the SDK.
Download the SDK from https://github.com/Microsoft/Intune-PowerShell-SDK
Once downloaded, extract it and import the module in to Powershell
Run Connect-MSGraph and logon to the tenant
You are now connected and are able to use all the cmdlets against your tenant.
Will get all applications under MobileApps (Client Apps is the new name in the Intune console)
To list all available cmdlets in the Powershell module just do the following in powershell. As of this post there’s 1311 cmdlets which is pretty impressive I have to say for something
thats just a preview.
Get-Command -Module Microsoft.Graph.Intune
That’s all for now and until next time, cheers !
Don’t forget to follow me on twitterFollow @Timmyitdotcom
And you can also find me blogging over at http://blog.ctglobalservices.com/