Creates a custom cloud computer template. A cloud computer template (or simply "template") simplifies the process of creating cloud computers by providing a predefined set of configurations. This eliminates the need to manually configure each setting, saving significant time and effort.
Operation description
When you call this operation, take note of the following item:
Most parameters in templates are optional. When you create a template, Elastic Desktop Service (EDS) does not validate the existence or correctness of the parameter values you specify. The parameter values in the template are only verified when you use the template to create cloud computers.
For parameters that include the region attribute in the template, it's important to note that if the specified region doesn't match the region where the template is used to create a cloud computer, those parameters will not take effect.
Try it now
Test
RAM authorization
Action | Access level | Resource type | Condition key | Dependent action |
ecd:CreateTemplate | create | *All Resource
| None | None |
Request parameters
Parameter | Type | Required | Description | Example |
TemplateName | string | Yes | The template name. It must meet the following criteria:
| 我的云电脑模板001 |
Description | string | No | The template description. It must meet the following criteria:
| 设计部模板 |
ProductType | string | No | The service type. Set the value to Valid values:
| CloudDesktop |
BizType | string | No | Note This parameter is not publicly available. Valid values:
| 1 |
SystemDiskSize | integer | No | The size of the system disk. Unit: GiB. Valid values: 40 to 500. Increments: 10 GiB. Note The system disk size must be at least as large as the configured image size. | 80 |
SystemDiskPerformanceLevel | string | No | The performance level (PL) of the system disk. Note Only cloud computers of the Graphics or High Frequency type support Enterprise SSDs (ESSDs). Valid values:
| AutoPL |
| DataDiskList | array<object> | No | The data disks. | |
object | No | |||
Size | integer | No | The size of the data disk. Unit: GiB. Valid values: 40 to 2040. Increments: 10 GiB. Important The larger the ESSD disk capacity, the higher the available PL (for example, PL2 is available for disks larger than 460 GiB). A higher PL comes with a higher cost. Select an ESSD based on your specific needs. | 40 |
PerformanceLevel | string | No | The PL of the data disk. Default value: | AutoPL |
ImageId | string | No | The ID of the cloud computer image. You can query image IDs on the Images page. System images and custom images are supported. | desktopimage-windows-server-2022-64-asp |
DefaultLanguage | string | No | The default language of cloud computers during startup. This parameter takes effect only when cloud computers are created from system images. | zh-CN |
PolicyGroupId | string | No | The ID of the policy group. | pg-8hlryfn331****** |
TimerGroupId | string | No | The ID of the scheduled task group. | ccg-0caoeogrk9m5**** |
ResourceGroupId | string | No | The ID of the resource group. | rg-4knxmfneq1e****** |
| ResourceTagList | array<object> | No | The tags added to cloud computers. Specify tags in key-value pairs. You can specify up to 20 tags. | |
object | No | |||
Key | string | No | The tag key. | department |
Value | string | No | The tag value. | design |
| RegionConfigList | array<object> | No | The regions of the template. You can create cloud computers by using a template only within the same region as the template itself. Note You can specify up to 20 regions. | |
object | No | |||
RegionId | string | No | The region ID. You can call the DescribeRegions operation to query the list of regions where Elastic Desktop Service (EDS) Enterprise is available. | cn-hangzhou |
SnapshotPolicyId | string | No | The ID of the automatic snapshot policy. | sp-35fvn8m21pnx2**** |
ResourceInstanceType | string | No | The ID of the cloud computer type. | eds.enterprise_office.8c16g |
VolumeEncryptionEnable | boolean | No | Specifies whether to enable disk encryption. Valid values:
| false |
VolumeEncryptionKey | string | No | The ID of the Key Management Service (KMS) key that you want to use to encrypt disks. You can call the ListKeys operation to query KMS keys. | a7b3c0c8-b3a2-4876-b1cc-********* |
OfficeSiteId | string | No | The office network ID. | cn-hangzhou+dir-709****** |
SubnetId | string | No | The subnet ID. | vsw-bp1yiu********** |
| SiteConfigList | array<object> | No | The site configurations. | |
object | No | |||
SiteId | string | No | The site ID. Valid values:
| mainland |
AppRuleId | string | No | The application control policy ID. | bwr-5a5371e0db954d******** |
ChargeType | string | No | ||
Period | integer | No | ||
PeriodUnit | string | No | ||
AutoPay | boolean | No | ||
AutoRenew | boolean | No | ||
UserDuration | integer | No | ||
PostPaidAfterUsedUp | boolean | No |
Response elements
Element | Type | Description | Example |
object | The response elements. | ||
Data | string | The template ID. | b-0cc7rx533***** |
Success | boolean | Indicates whether the request was successful. | True |
Code | string | The execution result of the operation. If the request was successful, | success |
Message | string | The creation result. | success |
HttpStatusCode | integer | The HTTP status code returned. | 200 |
RequestId | string | The request ID. | 791CC0D3-1A38-573B-8F5F-******** |
Examples
Success response
JSON format
{
"Data": "b-0cc7rx533*****",
"Success": true,
"Code": "success",
"Message": "success",
"HttpStatusCode": 200,
"RequestId": "791CC0D3-1A38-573B-8F5F-********"
}Error codes
See Error Codes for a complete list.
Release notes
See Release Notes for a complete list.