All Products
Search
Document Center

Elastic Compute Service:DeleteLaunchTemplateVersion

Last Updated:Mar 19, 2024

Deletes a version of an instance launch template. This operation cannot delete the default version of an instance launch template. To delete the default version, you must call the DeleteLaunchTemplate operation to delete the instance launch template and all of its versions.

Debugging

OpenAPI Explorer automatically calculates the signature value. For your convenience, we recommend that you call this operation in OpenAPI Explorer.

Authorization information

There is currently no authorization information disclosed in the API.

Request parameters

ParameterTypeRequiredDescriptionExample
RegionIdstringYes

The ID of the region to which the instance lauch template belongs. You can call the DescribeRegions operation to query the most recent region list.

cn-hangzhou
DeleteVersionarrayYes

The version numbers of instance launch templates that to be deleted. You can specify at most 29 version numbers.

longYes

The version number of the instance launch template. You can call the DescribeLaunchTemplateVersions operation to query all versions of an instance launch template.

2
LaunchTemplateIdstringNo

The ID of the instance launch template. For more information, call the DescribeLaunchTemplates operation.

lt-bp1apo0bbbkuy0rj****
LaunchTemplateNamestringNo

The name of the instance launch template.

testLaunchTemplateName

Response parameters

ParameterTypeDescriptionExample
object
RequestIdstring

The ID of the request.

473469C7-AA6F-4DC5-B3DB-A3DC0DE3C83E

Examples

Sample success responses

JSONformat

{
  "RequestId": "473469C7-AA6F-4DC5-B3DB-A3DC0DE3C83E",
  "LaunchTemplateVersions": {
    "LaunchTemplateVersion": [
      {
        "LaunchTemplateId": "lt-m5eiaupmvm2op9d****",
        "LaunchTemplateVersionNumber": 2
      }
    ]
  }
}

Error codes

HTTP status codeError codeError messageDescription
400InvalidRegion.NotExist%sThe specified region does not exist.
400MissingParameter%sA parameter is not specified.
400InvalidParameter%sThe specified parameter is invalid.
403InvalidOperation.DeleteDefaultVersion%sThe operation is invalid. The default version cannot be deleted.
403InnerServiceFailed%sAn internal service cannot be called.

For a list of error codes, visit the Service error codes.

Change history

Change timeSummary of changesOperation
2023-03-10The Error code has changed. The response structure of the API has changedsee changesets
Change itemChange content
Error CodesThe Error code has changed.
    delete Error Codes: 400
    delete Error Codes: 403
Output ParametersThe response structure of the API has changed.