调用RenewDedicatedHosts续费一台或者多台包年包月专有宿主机。

接口说明

续费付款时,优先使用可抵扣的代金券,且您的账号必须支持账号余额支付或信用支付。

请求参数

名称 类型 是否必选 示例值 描述
Action String RenewDedicatedHosts

系统规定参数。取值:RenewDedicatedHosts。

DedicatedHostIds String dh-bp199lyny9b3****

专有宿主机的编号列表。最多可以输入100个预付费专有宿主机ID。多个专有宿主机ID用一个格式类似["dh-xxxxxxxxx", "dh-yyyyyyyyy", … "dh-zzzzzzzzz"]的JSON数组表示,ID之间用半角逗号(,)隔开。

RegionId String cn-hangzhou

专有宿主机所属的地域ID。您可以调用DescribeRegions查看最新的阿里云地域列表。

Period Integer 1

续费周期。取值范围:

  • PeriodUnit=Month时:1、2、3、4、5、6、7、8、9、12、24、36、48、60。
  • PeriodUnit=Year时:1、2、3、4、5。
PeriodUnit String Month

续费时长单位。取值范围:

  • Month
  • Year

默认值:Month。

ClientToken String 123e4567-e89b-12d3-a456-426655440000

保证请求幂等性。从您的客户端生成一个参数值,确保不同请求间该参数值唯一。只支持ASCII字符,且不能超过64个字符。更多详情,请参见如何保证幂等性

返回数据

名称 类型 示例值 描述
RequestId String 2A4EA075-CB5B-41B7-B0EB-70D339F6****

请求ID。

示例

请求示例

http(s)://ecs.aliyuncs.com/?Action=RenewDedicatedHosts
&DedicatedHostIds=dh-bp199lyny9b3****
&Period=1
&PeriodUnit=Month
&RegionId=cn-hangzhou
&<公共请求参数>

正常返回示例

XML格式

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

<RenewDedicatedHostsResponse>
    <RequestId>2A4EA075-CB5B-41B7-B0EB-70D339F6****</RequestId>
</RenewDedicatedHostsResponse>

JSON格式

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

{
  "RequestId" : "2A4EA075-CB5B-41B7-B0EB-70D339F6****"
}

错误码

HttpCode 错误码 错误信息 描述
400 IdempotenceParamNotMatch Request uses a client token in a previous request but is not identical to that request. 与相同 ClientToken 的请求参数不符合。
400 InvalidClientToken.ValueNotSupported The ClientToken provided is invalid. 指定的 ClientToken 不合法。
400 InvalidPeriod The specified period is not valid. 指定的时段不合法。
400 InvalidPeriodUnit.ValueNotSupported The specified parameter PeriodUnit is not valid. 参数 PeriodUnit 无效。
400 InvalidDedicatedHostId.NotFound The specified DedicatedHostId does not exist. 指定的专有宿主机不存在。
400 InvalidStatus.Upgrading The dedicated host is upgrading, please try it later. 指定的专有宿主机正在升级,请稍后操作。
400 LastOrderProcessing The previous order is still processing, please try again later. 订单正在处理中,稍后重试。
500 InternalError The request processing has failed due to some unknown error. 内部错误,请重试。
403 IncorrectHostStatus The current status of the resource does not support this operation. 当前资源的状态不支持此操作。
403 LastTokenProcessing The last token request is processing. 正在处理上一条令牌请求,请您稍后再试。

访问错误中心查看更多错误码。