Hi Everyone,
We have a requirement to create a remote mailbox via powershell script. Below is our understanding. Can anyone help us if we are going in the right direction?
- Create user in AD.
- Use After create rule to trigger powershell script to create the new remote mailbox.
New-RemoteMailbox -Name $sAMAccountName-Alias $sAMAccountName
-DisplayName $displayName-FirstName $firstName
-LastName $lastName-UserPrincipalName $userPrincipalName
-Password $securePassword-RemoteRoutingAddress "$($sAMAccountName)@$tenant.mail.onmicrosoft.com"
-OrganizationalUnit $onPremisesOrganizationalUnit `
-ErrorAction Stop - Azure AD connect sync with AD user object with remote mailbox attribute and assign license via SailPoint
- Exchange Online detects the licensed user with the correct remote mailbox attributes and provisions the Exchange Online mailbox.