Interactively enroll Windows Device with Autopilot
To enroll a Windows device into Intune via Windows Autopilot, it is needed to register the serial number and hardware id in the tenant via an interactive login. The user has to log in as "Intune Administrator" and upload the information via Graph API into Intune. A GroupTag can also be set in the same step.
Guide
Open CMD window with "SHIFT" + "F10".
Then enter the following commands in this order. Important: Change the values for your GroupTag and tenant name.
powershell
Set-ExecutionPolicy Unrestricted
Install-Script -Name "Get-WindowsAutopilotInfo" -Force
Get-WindowsAutopilotInfo.ps1 -Online -GroupTag "MW_BKWPRD_CH"<yourgrouptagname>" -TenantId "bkwfmbenergie.<yourtenantname>.onmicrosoft.com”
Then you have to login with an account that has Intune Administrator activated.
Restart-Computer
After