Now you can run the script to invite guests to your Azure Active Directory!

1

2

3

4

New-CustomAzureADMSInvitation.ps1-InvitedUserDisplayName"John Doe"`

-InvitedUserEmailAddress"john.doe@outlook.com"`

-InviteRedirectUrl"http://myapps.onmicrosoft.com"`

-InviteMessage"Are you coming to my tea party?"

Result

That’s it! You are now sending invites with PowerShell to external guest users using a custom email template. If you are using the basic HTML template provided in the script, the output will result in something like this: