Private/PartnerMenu/Start-PartnerMenuTenantCreation.ps1
function Start-PartnerMenuTenantInitilization() { $TenantDomain = Read-Host "Please enter the tenant default domain (e.g. customerdomain.onmicrosoft.com)" $Tenant = Get-Tenants | Where-Object { $_.DefaultDomainName -eq $TenantDomain } | Select-Object -First 1 if(!$Tenant) { Write-Error "Failed to find tenant with default domain: $($TenantDomain)" Read-Host "Press any key to continue.." Start-PartnerMenu } Clear-Host Get-PartnerMenuHeader -SectionString "($($Tenant.displayName)) - Tenant Initilization" Initialize-Tenant -TenantId $Tenant.CustomerId Read-Host "Press any key to continue.." } |