All Products
Search
Document Center

CloudOps Orchestration Service:ListTemplateVersions

Last Updated:Mar 03, 2024

Queries a list of versions of a template.

Debugging

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

Authorization information

The following table shows the authorization information corresponding to the API. The authorization information can be used in the Action policy element to grant a RAM user or RAM role the permissions to call this API operation. Description:

  • Operation: the value that you can use in the Action element to specify the operation on a resource.
  • Access level: the access level of each operation. The levels are read, write, and list.
  • Resource type: the type of the resource on which you can authorize the RAM user or the RAM role to perform the operation. Take note of the following items:
    • The required resource types are displayed in bold characters.
    • If the permissions cannot be granted at the resource level, All Resources is used in the Resource type column of the operation.
  • Condition Key: the condition key that is defined by the cloud service.
  • Associated operation: other operations that the RAM user or the RAM role must have permissions to perform to complete the operation. To complete the operation, the RAM user or the RAM role must have the permissions to perform the associated operations.
OperationAccess levelResource typeCondition keyAssociated operation
oos:ListTemplateVersionsLIST
  • Template
    acs:oos:{#regionId}:{#accountId}:template/{#templateName}
    none
none

Request parameters

ParameterTypeRequiredDescriptionExample
RegionIdstringNo

The region ID.

cn-hangzhou
TemplateNamestringYes

The name of the template.

describeinstances
MaxResultsintegerNo

The number of entries per page. Valid values: 10 to 100

50
NextTokenstringNo

A pagination token. It can be used in the next request to retrieve a new page of results.

H8xj9c-398djs9-39ajd9asdjjJ
ShareTypestringNo

The type of the template. Valid values: Private and Public.

Private

Response parameters

ParameterTypeDescriptionExample
object
NextTokenstring

A pagination token. It can be used in the next request to retrieve a new page of results.

NJSNDKLJS-SJKJDO090k30-JSDK232
RequestIdstring

The request ID.

E6CD612B-5889-4F1A-823F-8A4029E46
MaxResultsinteger

The number of entries per page.

50
TemplateVersionsobject []

The versions of the template.

Descriptionstring

The description of the version.

Detach the eip from the special instance.
UpdatedDatestring

The time when the version was last updated.

2020-05-19T06:05:41Z
UpdatedBystring

The user who last updated the version.

foo
VersionNamestring

The name of the version.

baz
TemplateVersionstring

The number of the version.

v2
TemplateFormatstring

The format of the template content. Valid values: YAML and JSON.

YAML

Examples

Sample success responses

JSONformat

{
  "NextToken": "NJSNDKLJS-SJKJDO090k30-JSDK232",
  "RequestId": "E6CD612B-5889-4F1A-823F-8A4029E46",
  "MaxResults": 50,
  "TemplateVersions": [
    {
      "Description": "Detach the eip from the special instance.",
      "UpdatedDate": "2020-05-19T06:05:41Z",
      "UpdatedBy": "foo",
      "VersionName": "baz",
      "TemplateVersion": "v2",
      "TemplateFormat": "YAML"
    }
  ]
}

Error codes

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