All Products
Search
Document Center

Direct Mail:CreateDomain

Last Updated:Oct 28, 2022

Creates a domain name.

Debugging

OpenAPI Explorer automatically calculates the signature value. For your convenience, we recommend that you call this operation in OpenAPI Explorer. OpenAPI Explorer dynamically generates the sample code of the operation for different SDKs.

Request parameters

Parameter

Type

Required

Example

Description

DomainName

String

Yes

example.com

The domain name. It must be 1 to 50 characters in length and can contain digits, letters, periods (.), and hyphens (-).

AccessKeyId

String

No

xxxx

The AccessKey ID provided to you by Alibaba Cloud.

Action

String

No

CreateDomain

The operation that you want to perform. Set the value to CreateDomain.

Response parameters

Parameter

Type

Example

Description

DomainId

String

158910

The ID of the domain name.

RequestId

String

B49AD828-25D1-488C-90B7-8853C1944486

The ID of the request.

Examples

Sample requests

http(s)://dm.aliyuncs.com/? Action=CreateDomain
&DomainName=example.com
&<Common request parameters>

Sample success responses

XML format

<CreateDomainResponse>
      <RequestId>B49AD828-25D1-488C-90B7-8853C1944486</RequestId>
      <DomainId>158910</DomainId>
</CreateDomainResponse>

JSON format

{
	"RequestId":"B49AD828-25D1-488C-90B7-8853C1944486",
	"DomainId":158910
}

Error codes

For a list of error codes, visit the API Error Center.