New-MsolDomain

Add a domain to Azure Active Directory.

Syntax

New-MsolDomain
   [-Name <String>]
   [-Authentication <DomainAuthenticationType>]
   [-VerificationMethod <DomainVerificationMethod>]
   [-TenantId <Guid>]
   [<CommonParameters>]

Description

The New-MsolDomain cmdlet adds a domain to Azure Active Directory. This cmdlet can create domains with managed or federated identities. To ensure proper setup, use the New-MsolFederatedDomain cmdlet for federated domains.

Examples

Example 1: Create a domain

PS C:\> New-MsolDomain -Name "contoso.com"

This command creates a domain named contoso.com. You must verify the domain before it can be used.

Parameters

-Authentication

Specifies the authentication type of the domain. Valid values are: managed and federated. All users created in this domain have this authentication type.

Type:DomainAuthenticationType
Position:Named
Default value:None
Required:False
Accept pipeline input:True
Accept wildcard characters:False

-Name

Specifies the fully qualified domain name of the domain.

Type:String
Position:Named
Default value:None
Required:False
Accept pipeline input:True
Accept wildcard characters:False

-TenantId

Specifies the unique ID of the tenant on which to perform the operation. The default value is the tenant of the current user. This parameter applies only to partner users.

Type:Guid
Position:Named
Default value:None
Required:False
Accept pipeline input:True
Accept wildcard characters:False

-VerificationMethod

Specifies the verification method for the domain.

Type:DomainVerificationMethod
Position:Named
Default value:None
Required:False
Accept pipeline input:True
Accept wildcard characters:False

Outputs

Microsoft.Online.Administration.Domain

This cmdlet returns the details about the new domain.