You need to enable JavaScript to run this app.
文档中心
云服务器

云服务器

复制全文
下载 pdf
镜像
DeleteImages - 删除镜像
复制全文
下载 pdf
DeleteImages - 删除镜像
调用 DeleteImages 接口,删除自定义镜像。​
注意事项​
使用本功能的前提条件及注意事项,可查看操作说明。​
调试​
API Explorer
您可以通过 API Explorer 在线发起调用,无需关注签名生成过程,快速获取调用结果。
​
请求参数​
下方仅列出该接口特有的请求参数和部分公共参数。更多信息请见公共参数。​
Action string 必选 示例值:DeleteImages​
要执行的操作,取值:DeleteImages。​
​
Version string 必选 示例值:2020-04-01​
API的版本,取值:2020-04-01。​
​
DeleteBindedSnapshots boolean 可选 示例值:true​
删除镜像是否同时删除快照或快照一致性组。取值:​
  • true:默认,删除。​
  • false:不删除。​
​
ImageIds.N string[] 必选 示例值:ImageIds.1=image-ebgy1og99tfct0******&ImageIds.2=image-2asdv4n6ay3vj0******​
自定义镜像ID,最多支持100个ID。您可以调用DescribeImages接口并传入Visibility=private参数,查询获取自定义镜像ID。​
  • 参数 -N:表示镜像的序号。​
  • 多个Image ID之间用&分隔。​
​
​
​
返回参数​
下表仅列出本接口特有的返回参数。更多信息请参见返回结构。​
说明​
仅当请求参数输入不合法时返回下文中的接口错误码。当请求参数输入无误时,接口返回状态码为200且不会返回接口错误码,但并不代表对镜像的操作均已成功,单个镜像的操作结果请参见如下返回参数中的信息。​
OperationDetails object[] 示例值:--​
自定义镜像操作详情。​
Error object 示例值:--​
某个镜像删除失败的错误信息。​
Code string 示例值:InvalidImage.NotFound​
批量请求处理中,单个请求操作失败的错误码。取值:​
  • InvalidImage.NotFound:表示指定的镜像不存在。​
  • InvalidImageStatus:表示当前镜像状态不支持此操作。​
  • InvalidImage.Shared:表示指定的镜像已被共享给其他用户。​
  • OperationDenied.ImageIsCopying:表示指定的操作被拒绝,因为该镜像正在复制。​
  • OperationDenied.ImageIsExporting:表示指定的操作被拒绝,因为该镜像正在导出。​
  • InternalError:表示内部错误,请重试。如果多次尝试失败,请提交工单。​
说明​
Code与Message一一对应。​
​
Message string 示例值:The specified image does not exist.​
批量请求处理中,单个请求的异常信息。取值:​
  • The specified image does not exist.:表示指定的镜像不存在。​
  • The specified image is not in the correct status for the request.:表示当前镜像状态不支持此操作。​
  • The specified image has already been shared and may be in use by other users. :表示指定的镜像已被共享给其他用户。​
  • The specified operation is denied as your image is copying.:表示指定的操作被拒绝,因为该镜像正在复制。​
  • The specified operation is denied as your image is exporting.:表示指定的操作被拒绝,因为该镜像正在导出。​
  • An internal error has occurred.:表示内部错误,请重试。如果多次尝试失败,请提交工单。​
​
​
ImageId string 示例值:image-ebgy1og99tfct0******​
镜像ID。​
​
​
​
​
请求示例​
​
GET /?Action=DeleteImages&Version=2020-04-01&ImageIds.1=image-ebgy1og99tfct0****** HTTP/1.1​
Host: ecs.cn-beijing.volcengineapi.com​
Region: cn-beijing​
Service: ecs​
​
返回示例​
​
{​
"ResponseMetadata": {​
"RequestId": "20210611144510010225243100005******",​
"Action": "DeleteImages",​
"Version": "2020-04-01",​
"Service": "ecs",​
"Region": "cn-beijing"​
},​
"Result": {​
"OperationDetails": [​
{​
"ImageId": "image-ebgy1og99tfct0******",​
"Error": {​
"Code": "InvalidImage.NotFound",​
"Message": "The specified image does not exist."​
}​
}​
]​
}​
}​
​
错误码​
下表为您列举了该接口与业务逻辑相关的错误码。公共错误码请参见公共错误码文档。​
​
状态码​
错误码​
错误信息​
说明​
400​
InvalidArgument​
The specified argument is invalid.​
指定的参数不合法。​
400​
LimitExceeded.MaximumImageIds​
You've reached the limit on the number of ImageIds that you can set.​
指定的镜像ID数量超过限制。​
400​
MissingParameter.ImageId​
The required parameter ImageId is not supplied.​
镜像ID不能为空。​
500​
InternalError​
An internal error has occurred.​
内部错误,请重试。如果多次尝试失败,请提交工单。​
​
​
最近更新时间:2025.09.04 16:02:53
这个页面对您有帮助吗?
有用
有用
无用
无用