Creates a dedicated host cluster.

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

ParameterTypeRequiredExampleDescription
ActionStringYesCreateDedicatedHostCluster

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

RegionIdStringYescn-hangzhou

The ID of the region in which to create the dedicated host cluster. You can call the DescribeRegions operation to query the most recent region list.

DryRunBooleanNofalse

Specifies whether to check the validity of the request without actually making the request. Valid values:

  • true: The validity of the request is checked but the request is not made. Check items include whether your AccessKey pair is valid, whether Resource Access Management (RAM) users are granted required permissions, and whether the required parameters are specified. If the check fails, the corresponding error is returned. If the check succeeds, the DryRunOperation error code is returned.
  • false: The validity of the request is checked. If the check succeeds, a 2XX HTTP status code is returned, and the request is made.

Default value: false.

Tag.N.KeyStringNoTestKey

The key of tag N to add to the dedicated host cluster. Valid values of N: 1 to 20. The tag key cannot be an empty string. It can be up to 64 characters in length and cannot start with acs: or aliyun. It cannot contain http:// or https://.

Tag.N.ValueStringNoTestValue

The value of tag N to add to the dedicated host cluster. Valid values of N: 1 to 20. The tag value cannot be an empty string. It can be up to 64 characters in length and cannot start with acs: or aliyun. It cannot contain http:// or https://.

ResourceGroupIdStringNorg-bp67acfmxazb4p****

The ID of the resource group to which to assign the dedicated host cluster.

ZoneIdStringYescn-hangzhou-f

The ID of the zone in which to create the dedicated host cluster. You can call the DescribeZones operation to query the most recent zone list.

DedicatedHostClusterNameStringNomyDDHCluster

The name of the dedicated host cluster. The name must be 2 to 128 characters in length and can contain letters, digits, periods (.), underscores (_), and hyphens (-). The name must start with a letter. It cannot contain http:// or https://.

This parameter is empty by default.

DescriptionStringNoThis-is-my-DDHCluster

The description of the dedicated host cluster. The description must be 2 to 256 characters in length. It cannot start with http:// or https://.

This parameter is empty by default.

Response parameters

ParameterTypeExampleDescription
DedicatedHostClusterIdStringdc-bp12wlf6bw0vz9v2****

The ID of the dedicated host cluster.

RequestIdStringE2A664A6-2933-4C64-88AE-5033D003****

The ID of the request.

Examples

Sample requests

http(s)://ecs.aliyuncs.com/?Action=CreateDedicatedHostCluster
&RegionId=cn-hangzhou
&ZoneId=cn-hangzhou-f
&DedicatedHostClusterName=myDDHCluster
&PageNumber=1
&PageSize=5
&Common request parameters

Sample success responses

XML format

HTTP/1.1 200 OK
Content-Type:application/xml

<CreateDedicatedHostClusterResponse>
    <DedicatedHostClusterId>dc-bp12wlf6bw0vz9v2****</DedicatedHostClusterId>
    <RequestId>E2A664A6-2933-4C64-88AE-5033D003****</RequestId>
</CreateDedicatedHostClusterResponse>

JSON format

HTTP/1.1 200 OK
Content-Type:application/json

{
  "DedicatedHostClusterId" : "dc-bp12wlf6bw0vz9v2****",
  "RequestId" : "E2A664A6-2933-4C64-88AE-5033D003****"
}

Error codes

HTTP status codeError codeError messageDescription
400InvalidTagKey.MalformedThe specified Tag.n.Key is not valid.The error message returns because the specified Tag.N.Key parameter is invalid.
400InvalidTagValue.MalformedThe specified Tag.n.Value is not valid.The error message returns because the specified Tag.N.Value parameter is invalid.
400Duplicate.TagKeyThe Tag.N.Key contains duplicate key.The error message returns because the specified tag key already exists. Tag keys must be unique.
404InvalidResourceGroup.NotFoundThe ResourceGroup provided does not exist in our records.The error message returns because the specified resource group does not exist.

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