ListWuyingServerWorkloadTemplate

Updated at:

Queries the Wuying workstation workload templates available for a specified virtual node pool.

Operation description

Queries the workload templates available for existing virtual node pools under the current account.

Prerequisites and invocation sequence

You must provide a valid virtual node pool ID that exists under the current account. Querying templates does not require the node pool to be attached to a workstation.

  1. If you already have a node pool ID, you can directly pass it as VirtualNodePoolId to invoke this operation.

  2. If a workstation is already associated with a node pool, you can also invoke ListWuyingServer to obtain a non-empty VirtualNodePoolId from the corresponding record. This is one way to obtain the ID, but it is not a mandatory step for querying templates.

  3. If an empty ID is returned, do not use this value to continue querying. You must obtain a valid node pool ID under the current account before invoking this operation. Do not use a workstation ID, cluster ID, the character string null, or a self-constructed ID.

This operation does not create node pools. CreateWuyingServer only associates existing node pools and does not support automatic creation of node pools. If the node pool does not exist or does not belong to the current account, InvalidParameter.VirtualNodePoolId is returned.

Response

Returns the first 100 records sorted by template configuration order. The template content is Base64-encoded after UTF-8 encoding. You must perform Base64 decoding before use. The current version does not use MaxResults and NextToken for pagination.

Try it now

Try this API in OpenAPI Explorer, no manual signing needed. Successful calls auto-generate SDK code matching your parameters. Download it with built-in credential security for local usage.

Test

RAM authorization

The table below describes the authorization required to call this API. You can define it in a Resource Access Management (RAM) policy. The table's columns are detailed below:

  • Action: The actions can be used in the Action element of RAM permission policy statements to grant permissions to perform the operation.

  • API: The API that you can call to perform the action.

  • Access level: The predefined level of access granted for each API. Valid values: create, list, get, update, and delete.

  • Resource type: The type of the resource that supports authorization to perform the action. It indicates if the action supports resource-level permission. The specified resource must be compatible with the action. Otherwise, the policy will be ineffective.

    • For APIs with resource-level permissions, required resource types are marked with an asterisk (*). Specify the corresponding Alibaba Cloud Resource Name (ARN) in the Resource element of the policy.

    • For APIs without resource-level permissions, it is shown as All Resources. Use an asterisk (*) in the Resource element of the policy.

  • Condition key: The condition keys defined by the service. The key allows for granular control, applying to either actions alone or actions associated with specific resources. In addition to service-specific condition keys, Alibaba Cloud provides a set of common condition keys applicable across all RAM-supported services.

  • Dependent action: The dependent actions required to run the action. To complete the action, the RAM user or the RAM role must have the permissions to perform all dependent actions.

Action

Access level

Resource type

Condition key

Dependent action

appstreaming:ListWuyingServerWorkloadTemplate

list

*All Resource

*

None None

Request parameters

Parameter

Type

Required

Description

Example

VirtualNodePoolId

string

Yes

The virtual node pool ID. Required. The node pool must already exist and belong to the current account, but it is not required to be attached to a workstation.

If you already have a valid node pool ID, you can directly pass it. If a workstation is already associated with a node pool, you can also obtain the corresponding non-empty VirtualNodePoolId by invoking ListWuyingServer. If you do not have a valid ID, do not use an empty value, workstation ID, cluster ID, or the character string null as a substitute.

CreateWuyingServer only associates existing node pools and does not support automatic creation of node pools. If the node pool does not exist or does not belong to the current account, InvalidParameter.VirtualNodePoolId is returned.

vnp-bp1234567890abcde

MaxResults

integer

No

A compatibility field. The current version does not read this parameter. The operation returns a maximum of the first 100 templates.

100

NextToken

string

No

A compatibility field. The current version does not read this parameter and does not support token-based pagination.

unused

Response elements

Element

Type

Description

Example

object

The operation response.

MaxResults

integer

A compatibility field. The current version does not use this field to indicate the number of returned entries.

100

NextToken

string

A compatibility field. The current version does not generate a next page token.

unused

RequestId

string

The unique identifier of the request, which can be used to troubleshoot request issues.

1CBAFFAB-B697-4049-A9B1-67E1FC5F****

WorkloadTemplates

array<object>

The list of workload templates. A maximum of 100 templates are returned, sorted by template configuration order.

object

The workload template object.

Content

string

The rendered template content. The original text is Base64-encoded after UTF-8 encoding. You must perform Base64 decoding before use.

IyB3b3JrbG9hZCB0ZW1wbGF0ZQo=

Description

string

The purpose description of the workload template.

Used to submit general-purpose computing workloads

Name

string

The name of the workload template.

General-purpose computing task template

Examples

Success response

JSON format

{
  "MaxResults": 100,
  "NextToken": "unused",
  "RequestId": "1CBAFFAB-B697-4049-A9B1-67E1FC5F****",
  "WorkloadTemplates": [
    {
      "Content": "IyB3b3JrbG9hZCB0ZW1wbGF0ZQo=",
      "Description": "Used to submit general-purpose computing workloads",
      "Name": "General-purpose computing task template"
    }
  ]
}

Error codes

See Error Codes for a complete list.

Release notes

See Release Notes for a complete list.