Powershell script to AAD join with login user credentials in Windows 10/11

Vij 321 Reputation points
2023-02-12T15:53:24.5933333+00:00

Hi Team,

I am looking a powershell script which is joined the machine to AAD with user credentials. Is there any similar script?

Requirement :

The requirement is, there are multiple machines some are workgroup & others with on-prem domain joined. in the environment there is no Azure AD sync.

Note: Automatic enrolment has been targeted to all users. So once any user/machine joined to AAD, the machine will be there in Intune right?

Microsoft Security | Intune | Enrollment
Microsoft Security | Microsoft Entra | Microsoft Entra ID
Microsoft Security | Intune | Other
0 comments No comments
{count} votes

1 answer

Sort by: Most helpful
  1. Lu Dai-MSFT 28,496 Reputation points
    2023-02-13T05:42:55.97+00:00

    @Vij Thanks for posting in our Q&A.

    Honestly, I'm not familiar with Powershell script. Based on my research, the "New-AzureADDevice" cmdlet can create a device in Azure AD. Please refer to the following article:

    https://learn.microsoft.com/en-us/powershell/module/azuread/new-azureaddevice?view=azureadps-2.0

    No. It doesn't mean that the device will be managed by intune once the device is joined to Azure AD. Azure AD join and intune enrollment are different things.

    Hope it will clarify something.


    If the answer is the right solution, please click "Accept Answer" and kindly upvote it. If you have extra questions about this answer, please click "Comment".

    Note: Please follow the steps in our documentation to enable e-mail notifications if you want to receive the related email notification for this thread.

    0 comments No comments

Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.