New-Domain cmdlet  creates a new domain.

This cmdlet supports risk-mitigation parameters.

Input parameters

#
Parameter
Type

Mandatory (R/O)

Description
Restrictions/Valid Values
1  Authentication Information (all parameters)  
2 Name string R

Domain name

Max length is 253 symbols

3 IsExcluded bool O

The parameter specifies whether the domain is excluded (won't be used for generating Email addresses for mail-enabled objects) or not

  • True - the domain is excluded. 
  • False - the domain is not excluded. This is the default value.
4 SendNotification bool O

The parameter specifies whether the EMail for repoint DNS instructions will be sent to administrators with Dns/MSExchange role

  • True - the Email will be sent.
  • False - the Email will not be sent. This is the default value.
5 UpdateDns bool O

The parameter specifies whether DNS records will be updated

  • True - the records will be updated.
  • False - the records will not be updated. This is the default value.
6 UpdateRecipients bool O The parameter specifies whether new addresses will be generated in this domain for existing recipients
  • True - the addresses will be generated.
  • False - the addresses will not be generated. This is the default value.

Output parameters

When the new domain is created, the object with the properties, described below returns. All properties have values.

#PropertyTypeDescriptionValid Values
DomainInfo:
1 AllSettingsTypes DomainSettingsType[] Types of domain settings (in terms of different services)
  • Dns
  • MSExchange
  • Split
2 IsAutoDomain bool

This property specifies whether it is an autodomain* or not

* Autodomain is a domain of the third level: account name + domain (hostpilot.com), for example, testaccount.hostpilot.com

  • True - it is an autodomain. 
  • False - it is not an autodomain.
3 IsDefault bool

This property specifies whether it is a default** domain or not

** Default domain is a domain that is marked as a default domain in CP

  • True - it is a default domain.
  • False - it is not a default domain.
4 IsOwnedByDifferentAccount bool This property defines, whether this domain is owned by another account or not (see the article)
  • True  - the domain is owned by another account .
  • False - the domain is not owned by another account.
5 Name string Domain name  
6 OwnerPlatformType HostingApplicationType Type of the platform owner
  • Unknown
  • Web
  • Exchange
  • Fax
  • Reseller
7 Settings DomainSettingsInfo[]

Domain settings (in terms of different services), see the example how to display details of settings.

 

Types of Domain Settings

#PropertyTypeDescriptionValid Values
DnsDomainSettingsInfo:
1 Records DnsRecordInfo[] DNS records  
MSExchangeDomainSettingsInfo:
1 IsAuthoritative bool This property specifies whether the domain is authoritive or not (relates to split domains, see the article)
  • True - the domain is authoritive. This is the default value.
  • False - the domain is not authoritive.
2 IsExcluded bool This property specifies whether the domain is excluded (won't be used for generating Email addresses for mail-enabled objects) or not
  • True - the domain is excluded.
  • False - the domain is not excluded. This is the default value.
SplitDomainSettingsInfo:
1 Options SplitDomainOption Split option
  • None
  • Internal
  • External
InternalSplitDomainSettingsInfo:
1 Target UserAccountIdentityInfo
Target accoun t, the domain is splited with  
2 TargetPlatform HostingApplicationInfo

Target platform

 

Type DnsRecordInfo

Available types of DNS record are described in the table.

#PropertyTypeDescriptionAdditional Information
1 ARecordInfo A Address record RFC 1035
2 CNAMERecordInfo CNAME Canonical name record RFC 1035
3 MXRecordInfo MX Mail exchange record RFC 1035  and RFC 7505
4 NAPTRRecordInfo NAPTR Naming Authority Pointer RFC 3403
5 NSRecordInfo NS Name server record RFC 1035  
6 PTRRecordInfo PTR Pointer record RFC 1035  
7 SOARecordInfo SOA Start of [a zone of] authority record RFC 1035  and RFC 2308
8 SPFRecordInfo SPF

Antispam record

SPF 7208
9 SRVRecordInfo SRV Service locator RFC 2782
10 TXTRecordInfo TXT Text record RFC 1035

Type HostingApplicationInfo

#PropertyDescriptionValid Values
1 Name Platform name
  • Shared
  • Dedicated
  • Exchange
  • Dedicatedexchange
  • Fax
  • Plrexchange
2 PrettyName Displayed platform name
  • Web Hosting
  • Dedicated Web
  • Exchange Hosting
  • Dedicated Exchange
  • Fax via Email
  • PLR Exchange Hosting

Type UserAccountIdentityInfo

#PropertyDescription
1 AccountID Account identifier
2 PLR_ID Partner identifier
3 UserName Account name

Example of using New-Domain cmdlet 

New-Domain -Name "accountname.com" -UpdateRecipients:$false