阅读145 返回首页    go 微信


设置实例自动释放时间__实例相关接口_API 参考_云服务器 ECS-阿里云

设置实例自动释放时间

描述

对给定的实例设定自动释放时间。

  • 实例必须满足付费类型为:按量付费,才能调用该接口。
  • 设置自动释放时请谨慎操作,配置的时间到期后将自动进行释放操作。

请求参数

名称 类型 是否必须 描述
Action String 系统规定参数,取值:ModifyInstanceAutoReleaseTime
InstanceId String 指定启动的实例 ID
AutoReleaseTime String 自动释放时间。按照 ISO8601 标准表示,并需要使用 UTC 时间。 格式为:yyyy-MM-ddTHH:mm:ssZ。 如果秒不是 00,则自动取为当前分钟开始时。最少在当前时间之后半小时;最多不能超过当前时间起三年。

返回参数

全是公共返回参数,详见 公共返回参数

错误码

错误代码 描述 Http 状态码 语义
MissingParamter.InstanceId InstanceId should not be null. 400 指定的 InstanceId 不能为空
InvalidAutoReleaseTime.Malformed The specified paramter autoReleaseTime is not valid. 400 指定的时间不正确
UnsupportedParameter The parameters is unsupported. 400 不支持的参数
InternalError The request processing has failed due to some unknown error. 500 内部错误
ChargeTypeViolation The operation is not permitted due to charge type of the instance. 403 付费类型不对
NoSuchResource The specified resource is not found. 404 找不到指定资源

示例

请求示例

  1. https://ecs.aliyuncs.com/?Action=ModifyInstanceAutoReleaseTime&InstanceId=i-instance1 &<公共请求参数>

返回示例

JSON格式

  1. { "RequestId": "C0003E8B-B930-4F59-ADC0-0E209A9012A8" }

最后更新:2016-11-23 17:16:11

  上一篇:go 续费实例__实例相关接口_API 参考_云服务器 ECS-阿里云
  下一篇:go 创建磁盘__磁盘相关接口_API 参考_云服务器 ECS-阿里云