调用ListTemplateVersions查询一个模版的多个版本对象。

调试

您可以在OpenAPI Explorer中直接运行该接口,免去您计算签名的困扰。运行成功后,OpenAPI Explorer可以自动生成SDK代码示例。

请求参数

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

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

TemplateName String describeinstances

模版名称。

RegionId String cn-hangzhou

地域ID。

MaxResults Integer 50

最大结果数。取值范围10-100。

NextToken String H8xj9c-398djs9-39ajd9asdjjJ

用来翻页的Token字符串。

ShareType String Private

模版类型。取值范围Private或Public。

返回数据

名称 类型 示例值 描述
MaxResults Integer 50

最大结果数。

NextToken String NJSNDKLJS-SJKJDO090k30-JSDK232

翻向下一页的Token字符串。

RequestId String E6CD612B-5889-4F1A-823F-8A4029E46

请求ID。

TemplateVersions Array

模版的多个版本对象。

Description String Detach the eip from the special instance.

该版本描述。

TemplateFormat String YAML

模版内容格式。YAML或JSON。

TemplateVersion String v2

该版本号。

UpdatedBy String foo

该版本模版最近更新人。

UpdatedDate String 2020-05-19T06:05:41Z

该版本模版最近更新时间。

VersionName String baz

版本名称

示例

请求示例

http(s)://oos.cn-hangzhou.aliyuncs.com?Action=ListTemplateVersions
&TemplateName=describeinstances
&<公共请求参数>

正常返回示例

XML 格式

<ListTemplateVersionsResponse>
  <RequestId>E6CD612B-5889-4F1A-823F-8A4029E4667F</RequestId>
  <MaxResults>20</MaxResults>
  <TemplateVersions>
        <UpdatedBy>sub:239325550833674852:wb-kxy520087</UpdatedBy>
        <Description>Detach the eip from the special instance.</Description>
        <TemplateFormat>YAML</TemplateFormat>
        <UpdatedDate>2020-05-19T06:05:41Z</UpdatedDate>
        <TemplateVersion>v3</TemplateVersion>
  </TemplateVersions>
  <TemplateVersions>
        <UpdatedBy>sub:239325550833674852:wb-kxy520087</UpdatedBy>
        <Description>Detach the eip from the special instance.</Description>
        <TemplateFormat>YAML</TemplateFormat>
        <UpdatedDate>2020-05-19T02:48:16Z</UpdatedDate>
        <TemplateVersion>v2</TemplateVersion>
  </TemplateVersions>
  <TemplateVersions>
        <UpdatedBy>sub:239325550833674852:wb-kxy520087</UpdatedBy>
        <Description>Detach the eip from the special instance.</Description>
        <TemplateFormat>YAML</TemplateFormat>
        <UpdatedDate>2020-05-19T02:41:09Z</UpdatedDate>
        <TemplateVersion>v1</TemplateVersion>
  </TemplateVersions>
</ListTemplateVersionsResponse>

JSON 格式

{
	"RequestId": "E6CD612B-5889-4F1A-823F-8A4029E4667F",
	"MaxResults": 20,
	"TemplateVersions": [
		{
			"UpdatedBy": "sub:239325550833674852:wb-kxy520087",
			"Description": "Detach the eip from the special instance.",
			"TemplateFormat": "YAML",
			"UpdatedDate": "2020-05-19T06:05:41Z",
			"TemplateVersion": "v3"
		},
		{
			"UpdatedBy": "sub:239325550833674852:wb-kxy520087",
			"Description": "Detach the eip from the special instance.",
			"TemplateFormat": "YAML",
			"UpdatedDate": "2020-05-19T02:48:16Z",
			"TemplateVersion": "v2"
		},
		{
			"UpdatedBy": "sub:239325550833674852:wb-kxy520087",
			"Description": "Detach the eip from the special instance.",
			"TemplateFormat": "YAML",
			"UpdatedDate": "2020-05-19T02:41:09Z",
			"TemplateVersion": "v1"
		}
	]
}

错误码

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