UNPKG

tencentcloud-sdk-nodejs-intl-en

Version:
1,612 lines (1,353 loc) 428 kB
/* * Copyright (c) 2018 THL A29 Limited, a Tencent company. All Rights Reserved. * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, * software distributed under the License is distributed on an * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY * KIND, either express or implied. See the License for the * specific language governing permissions and limitations * under the License. */ const AbstractModel = require("../../common/abstract_model"); /** * Parameters related to the prepaid billing method, including the subscription period, the auto renewal logic, etc. * @class */ class ChargePrepaid extends AbstractModel { constructor(){ super(); /** * Purchased usage period, in month. Valid values: 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 24, 36 * @type {number || null} */ this.Period = null; /** * Auto renewal flag. Valid values: <br><li>NOTIFY_AND_AUTO_RENEW: notify upon expiration and renew automatically <br><li>NOTIFY_AND_MANUAL_RENEW: notify upon expiration but do not renew automatically <br><li>DISABLE_NOTIFY_AND_MANUAL_RENEW: neither notify upon expiration nor renew automatically <br><br>Default value: NOTIFY_AND_AUTO_RENEW. If this parameter is specified as NOTIFY_AND_AUTO_RENEW, the instance will be automatically renewed on a monthly basis if the account balance is sufficient. * @type {string || null} */ this.RenewFlag = null; } /** * @private */ deserialize(params) { if (!params) { return; } this.Period = 'Period' in params ? params.Period : null; this.RenewFlag = 'RenewFlag' in params ? params.RenewFlag : null; } } /** * Describes local disk specifications. * @class */ class LocalDiskType extends AbstractModel { constructor(){ super(); /** * Type of a local disk. * @type {string || null} */ this.Type = null; /** * Attributes of a local disk. * @type {string || null} */ this.PartitionType = null; /** * Minimum size of a local disk. * @type {number || null} */ this.MinSize = null; /** * Maximum size of a local disk. * @type {number || null} */ this.MaxSize = null; /** * Whether a local disk is required during purchase. Valid values:<br><li>REQUIRED: required<br><li>OPTIONAL: optional * @type {string || null} */ this.Required = null; } /** * @private */ deserialize(params) { if (!params) { return; } this.Type = 'Type' in params ? params.Type : null; this.PartitionType = 'PartitionType' in params ? params.PartitionType : null; this.MinSize = 'MinSize' in params ? params.MinSize : null; this.MaxSize = 'MaxSize' in params ? params.MaxSize : null; this.Required = 'Required' in params ? params.Required : null; } } /** * AssociateInstancesKeyPairs response structure. * @class */ class AssociateInstancesKeyPairsResponse extends AbstractModel { constructor(){ super(); /** * The unique request ID, generated by the server, will be returned for every request (if the request fails to reach the server for other reasons, the request will not obtain a RequestId). RequestId is required for locating a problem. * @type {string || null} */ this.RequestId = null; } /** * @private */ deserialize(params) { if (!params) { return; } this.RequestId = 'RequestId' in params ? params.RequestId : null; } } /** * DescribeImageQuota response structure. * @class */ class DescribeImageQuotaResponse extends AbstractModel { constructor(){ super(); /** * The image quota of an account * @type {number || null} */ this.ImageNumQuota = null; /** * The unique request ID, generated by the server, will be returned for every request (if the request fails to reach the server for other reasons, the request will not obtain a RequestId). RequestId is required for locating a problem. * @type {string || null} */ this.RequestId = null; } /** * @private */ deserialize(params) { if (!params) { return; } this.ImageNumQuota = 'ImageNumQuota' in params ? params.ImageNumQuota : null; this.RequestId = 'RequestId' in params ? params.RequestId : null; } } /** * ModifyInstancesProject request structure. * @class */ class ModifyInstancesProjectRequest extends AbstractModel { constructor(){ super(); /** * Instance IDs. To obtain the instance IDs, you can call [`DescribeInstances`](https://intl.cloud.tencent.com/document/api/213/15728?from_cn_redirect=1) and look for `InstanceId` in the response. You can operate up to 100 instances in each request. * @type {Array.<string> || null} */ this.InstanceIds = null; /** * Project ID. You can use the API `AddProject` to create projects, and obtain the `projectId` field in the response of the `DescribeProject` API. When using the [DescribeInstances](https://intl.cloud.tencent.com/document/api/213/15728?from_cn_redirect=1) API to query instances later, you can filter the results by the project ID. * @type {number || null} */ this.ProjectId = null; } /** * @private */ deserialize(params) { if (!params) { return; } this.InstanceIds = 'InstanceIds' in params ? params.InstanceIds : null; this.ProjectId = 'ProjectId' in params ? params.ProjectId : null; } } /** * ConfigureChcDeployVpc response structure. * @class */ class ConfigureChcDeployVpcResponse extends AbstractModel { constructor(){ super(); /** * The unique request ID, generated by the server, will be returned for every request (if the request fails to reach the server for other reasons, the request will not obtain a RequestId). RequestId is required for locating a problem. * @type {string || null} */ this.RequestId = null; } /** * @private */ deserialize(params) { if (!params) { return; } this.RequestId = 'RequestId' in params ? params.RequestId : null; } } /** * ResetInstancesType response structure. * @class */ class ResetInstancesTypeResponse extends AbstractModel { constructor(){ super(); /** * The unique request ID, generated by the server, will be returned for every request (if the request fails to reach the server for other reasons, the request will not obtain a RequestId). RequestId is required for locating a problem. * @type {string || null} */ this.RequestId = null; } /** * @private */ deserialize(params) { if (!params) { return; } this.RequestId = 'RequestId' in params ? params.RequestId : null; } } /** * Resource information of the CDH instance * @class */ class HostResource extends AbstractModel { constructor(){ super(); /** * Total number of CPU cores in the CDH instance * @type {number || null} */ this.CpuTotal = null; /** * Number of available CPU cores in the CDH instance * @type {number || null} */ this.CpuAvailable = null; /** * Total memory size of the CDH instance (unit: GiB) * @type {number || null} */ this.MemTotal = null; /** * Available memory size of the CDH instance (unit: GiB) * @type {number || null} */ this.MemAvailable = null; /** * Total disk size of the CDH instance (unit: GiB) * @type {number || null} */ this.DiskTotal = null; /** * Available disk size of the CDH instance (unit: GiB) * @type {number || null} */ this.DiskAvailable = null; /** * Disk type of the CDH instance * @type {string || null} */ this.DiskType = null; /** * Total number of GPU cards in the CDH instance * @type {number || null} */ this.GpuTotal = null; /** * Number of available GPU cards in the CDH instance * @type {number || null} */ this.GpuAvailable = null; } /** * @private */ deserialize(params) { if (!params) { return; } this.CpuTotal = 'CpuTotal' in params ? params.CpuTotal : null; this.CpuAvailable = 'CpuAvailable' in params ? params.CpuAvailable : null; this.MemTotal = 'MemTotal' in params ? params.MemTotal : null; this.MemAvailable = 'MemAvailable' in params ? params.MemAvailable : null; this.DiskTotal = 'DiskTotal' in params ? params.DiskTotal : null; this.DiskAvailable = 'DiskAvailable' in params ? params.DiskAvailable : null; this.DiskType = 'DiskType' in params ? params.DiskType : null; this.GpuTotal = 'GpuTotal' in params ? params.GpuTotal : null; this.GpuAvailable = 'GpuAvailable' in params ? params.GpuAvailable : null; } } /** * DeleteDisasterRecoverGroups request structure. * @class */ class DeleteDisasterRecoverGroupsRequest extends AbstractModel { constructor(){ super(); /** * ID list of spread placement groups, obtainable via the [DescribeDisasterRecoverGroups](https://intl.cloud.tencent.com/document/api/213/17810?from_cn_redirect=1) API. You can operate up to 10 spread placement groups in each request. * @type {Array.<string> || null} */ this.DisasterRecoverGroupIds = null; } /** * @private */ deserialize(params) { if (!params) { return; } this.DisasterRecoverGroupIds = 'DisasterRecoverGroupIds' in params ? params.DisasterRecoverGroupIds : null; } } /** * DescribeInstancesOperationLimit request structure. * @class */ class DescribeInstancesOperationLimitRequest extends AbstractModel { constructor(){ super(); /** * Query by instance ID(s). You can obtain the instance IDs from the value of `InstanceId` returned by the [DescribeInstances](https://intl.cloud.tencent.com/document/api/213/15728?from_cn_redirect=1) API. For example, instance ID: ins-xxxxxxxx. (For the specific format, refer to section `ids.N` of the API [Introduction](https://intl.cloud.tencent.com/document/api/213/15688?from_cn_redirect=1).) You can query up to 100 instances in each request. * @type {Array.<string> || null} */ this.InstanceIds = null; /** * Operation on the instance(s). <li> INSTANCE_DEGRADE: downgrade the instance configurations</li> * @type {string || null} */ this.Operation = null; } /** * @private */ deserialize(params) { if (!params) { return; } this.InstanceIds = 'InstanceIds' in params ? params.InstanceIds : null; this.Operation = 'Operation' in params ? params.Operation : null; } } /** * TerminateInstances response structure. * @class */ class TerminateInstancesResponse extends AbstractModel { constructor(){ super(); /** * The unique request ID, generated by the server, will be returned for every request (if the request fails to reach the server for other reasons, the request will not obtain a RequestId). RequestId is required for locating a problem. * @type {string || null} */ this.RequestId = null; } /** * @private */ deserialize(params) { if (!params) { return; } this.RequestId = 'RequestId' in params ? params.RequestId : null; } } /** * ResetInstancesInternetMaxBandwidth response structure. * @class */ class ResetInstancesInternetMaxBandwidthResponse extends AbstractModel { constructor(){ super(); /** * The unique request ID, generated by the server, will be returned for every request (if the request fails to reach the server for other reasons, the request will not obtain a RequestId). RequestId is required for locating a problem. * @type {string || null} */ this.RequestId = null; } /** * @private */ deserialize(params) { if (!params) { return; } this.RequestId = 'RequestId' in params ? params.RequestId : null; } } /** * DescribeZones request structure. * @class */ class DescribeZonesRequest extends AbstractModel { constructor(){ super(); } /** * @private */ deserialize(params) { if (!params) { return; } } } /** * InquiryPriceResetInstancesInternetMaxBandwidth response structure. * @class */ class InquiryPriceResetInstancesInternetMaxBandwidthResponse extends AbstractModel { constructor(){ super(); /** * Price of the new bandwidth * @type {Price || null} */ this.Price = null; /** * The unique request ID, generated by the server, will be returned for every request (if the request fails to reach the server for other reasons, the request will not obtain a RequestId). RequestId is required for locating a problem. * @type {string || null} */ this.RequestId = null; } /** * @private */ deserialize(params) { if (!params) { return; } if (params.Price) { let obj = new Price(); obj.deserialize(params.Price) this.Price = obj; } this.RequestId = 'RequestId' in params ? params.RequestId : null; } } /** * ModifyKeyPairAttribute request structure. * @class */ class ModifyKeyPairAttributeRequest extends AbstractModel { constructor(){ super(); /** * Key pair ID in the format of `skey-xxxxxxxx`. <br><br>You can obtain the available key pair IDs in two ways: <br><li>Log in to the [console](https://console.cloud.tencent.com/cvm/sshkey) to query the key pair IDs. <br><li>Call [DescribeKeyPairs](https://intl.cloud.tencent.com/document/api/213/15699?from_cn_redirect=1) and look for `KeyId` in the response. * @type {string || null} */ this.KeyId = null; /** * New key pair name, which can contain numbers, letters, and underscores, with a maximum length of 25 characters. * @type {string || null} */ this.KeyName = null; /** * New key pair description. You can specify any name you like, but its length cannot exceed 60 characters. * @type {string || null} */ this.Description = null; } /** * @private */ deserialize(params) { if (!params) { return; } this.KeyId = 'KeyId' in params ? params.KeyId : null; this.KeyName = 'KeyName' in params ? params.KeyName : null; this.Description = 'Description' in params ? params.Description : null; } } /** * AssociateSecurityGroups request structure. * @class */ class AssociateSecurityGroupsRequest extends AbstractModel { constructor(){ super(); /** * ID of the security group to be associated, such as `sg-efil73jd`. Only one security group can be associated. * @type {Array.<string> || null} */ this.SecurityGroupIds = null; /** * ID of the instance bound in the format of ins-lesecurk. You can specify up to 100 instances in each request. * @type {Array.<string> || null} */ this.InstanceIds = null; } /** * @private */ deserialize(params) { if (!params) { return; } this.SecurityGroupIds = 'SecurityGroupIds' in params ? params.SecurityGroupIds : null; this.InstanceIds = 'InstanceIds' in params ? params.InstanceIds : null; } } /** * ResetInstancesType request structure. * @class */ class ResetInstancesTypeRequest extends AbstractModel { constructor(){ super(); /** * Instance ID(s). To obtain the instance IDs, you can call the [`DescribeInstances`](https://intl.cloud.tencent.com/document/api/213/15728?from_cn_redirect=1) API and find the value `InstanceId` in the response. The maximum number of instances in each request is 1. * @type {Array.<string> || null} */ this.InstanceIds = null; /** * Instance model. Different resource specifications are specified for different models. For specific values, call [DescribeInstanceTypeConfigs](https://intl.cloud.tencent.com/document/api/213/15749?from_cn_redirect=1) to get the latest specification list or refer to [Instance Types](https://intl.cloud.tencent.com/document/product/213/11518?from_cn_redirect=1). * @type {string || null} */ this.InstanceType = null; /** * Forced shutdown of a running instances. We recommend you firstly try to shut down a running instance manually. Valid values: <br><li>TRUE: forced shutdown of an instance after a normal shutdown fails.<br><li>FALSE: no forced shutdown of an instance after a normal shutdown fails.<br><br>Default value: FALSE.<br><br>A forced shutdown is similar to switching off the power of a physical computer. It may cause data loss or file system corruption. Be sure to only force a CVM to shut off if the normal shutdown fails. * @type {boolean || null} */ this.ForceStop = null; } /** * @private */ deserialize(params) { if (!params) { return; } this.InstanceIds = 'InstanceIds' in params ? params.InstanceIds : null; this.InstanceType = 'InstanceType' in params ? params.InstanceType : null; this.ForceStop = 'ForceStop' in params ? params.ForceStop : null; } } /** * CHC host information * @class */ class ChcHost extends AbstractModel { constructor(){ super(); /** * CHC host ID * @type {string || null} */ this.ChcId = null; /** * Instance name * @type {string || null} */ this.InstanceName = null; /** * Server serial number * @type {string || null} */ this.SerialNumber = null; /** * CHC host status<br/> <ul> <li>REGISTERED: The CHC host is registered, but the out-of-band network and deployment network are not configured.</li> <li>VPC_READY: The out-of-band network and deployment network are configured.</li> <li>PREPARED: It’s ready and can be associated with a CVM.</li> <li>ONLINE: It’s already associated with a CVM.</li> </ul> * @type {string || null} */ this.InstanceState = null; /** * Device type Note: This field may return `null`, indicating that no valid values can be obtained. * @type {string || null} */ this.DeviceType = null; /** * Availability zone * @type {Placement || null} */ this.Placement = null; /** * Out-of-band network Note: This field may return `null`, indicating that no valid values can be obtained. * @type {VirtualPrivateCloud || null} */ this.BmcVirtualPrivateCloud = null; /** * Out-of-band network IP Note: This field may return `null`, indicating that no valid values can be obtained. * @type {string || null} */ this.BmcIp = null; /** * Out-of-band network security group ID Note: This field may return `null`, indicating that no valid values can be obtained. * @type {Array.<string> || null} */ this.BmcSecurityGroupIds = null; /** * Deployment network Note: This field may return `null`, indicating that no valid values can be obtained. * @type {VirtualPrivateCloud || null} */ this.DeployVirtualPrivateCloud = null; /** * Deployment network IP Note: This field may return `null`, indicating that no valid values can be obtained. * @type {string || null} */ this.DeployIp = null; /** * Deployment network security group ID Note: This field may return `null`, indicating that no valid values can be obtained. * @type {Array.<string> || null} */ this.DeploySecurityGroupIds = null; /** * ID of the associated CVM Note: This field may return `null`, indicating that no valid values can be obtained. * @type {string || null} */ this.CvmInstanceId = null; /** * Server creation time * @type {string || null} */ this.CreatedTime = null; /** * Instance hardware description, including CPU cores, memory capacity and disk capacity. Note: This field may return `null`, indicating that no valid values can be obtained. * @type {string || null} */ this.HardwareDescription = null; /** * CPU cores of the CHC host Note: This field may return `null`, indicating that no valid values can be obtained. * @type {number || null} */ this.CPU = null; /** * Memory capacity of the CHC host (unit: GB) Note: This field may return `null`, indicating that no valid values can be obtained. * @type {number || null} */ this.Memory = null; /** * Disk capacity of the CHC host Note: This field may return `null`, indicating that no valid values can be obtained. * @type {string || null} */ this.Disk = null; /** * MAC address assigned under the out-of-band network Note: This field may return `null`, indicating that no valid values can be obtained. * @type {string || null} */ this.BmcMAC = null; /** * MAC address assigned under the deployment network Note: This field may return `null`, indicating that no valid values can be obtained. * @type {string || null} */ this.DeployMAC = null; /** * Management type HOSTING: Hosting TENANT: Leasing Note: This field may return `null`, indicating that no valid values can be obtained. * @type {string || null} */ this.TenantType = null; /** * CHC DHCP option, which is used for MiniOS debugging. Note: This field may return `null`, indicating that no valid values can be obtained. * @type {ChcDeployExtraConfig || null} */ this.DeployExtraConfig = null; } /** * @private */ deserialize(params) { if (!params) { return; } this.ChcId = 'ChcId' in params ? params.ChcId : null; this.InstanceName = 'InstanceName' in params ? params.InstanceName : null; this.SerialNumber = 'SerialNumber' in params ? params.SerialNumber : null; this.InstanceState = 'InstanceState' in params ? params.InstanceState : null; this.DeviceType = 'DeviceType' in params ? params.DeviceType : null; if (params.Placement) { let obj = new Placement(); obj.deserialize(params.Placement) this.Placement = obj; } if (params.BmcVirtualPrivateCloud) { let obj = new VirtualPrivateCloud(); obj.deserialize(params.BmcVirtualPrivateCloud) this.BmcVirtualPrivateCloud = obj; } this.BmcIp = 'BmcIp' in params ? params.BmcIp : null; this.BmcSecurityGroupIds = 'BmcSecurityGroupIds' in params ? params.BmcSecurityGroupIds : null; if (params.DeployVirtualPrivateCloud) { let obj = new VirtualPrivateCloud(); obj.deserialize(params.DeployVirtualPrivateCloud) this.DeployVirtualPrivateCloud = obj; } this.DeployIp = 'DeployIp' in params ? params.DeployIp : null; this.DeploySecurityGroupIds = 'DeploySecurityGroupIds' in params ? params.DeploySecurityGroupIds : null; this.CvmInstanceId = 'CvmInstanceId' in params ? params.CvmInstanceId : null; this.CreatedTime = 'CreatedTime' in params ? params.CreatedTime : null; this.HardwareDescription = 'HardwareDescription' in params ? params.HardwareDescription : null; this.CPU = 'CPU' in params ? params.CPU : null; this.Memory = 'Memory' in params ? params.Memory : null; this.Disk = 'Disk' in params ? params.Disk : null; this.BmcMAC = 'BmcMAC' in params ? params.BmcMAC : null; this.DeployMAC = 'DeployMAC' in params ? params.DeployMAC : null; this.TenantType = 'TenantType' in params ? params.TenantType : null; if (params.DeployExtraConfig) { let obj = new ChcDeployExtraConfig(); obj.deserialize(params.DeployExtraConfig) this.DeployExtraConfig = obj; } } } /** * DeleteLaunchTemplateVersions request structure. * @class */ class DeleteLaunchTemplateVersionsRequest extends AbstractModel { constructor(){ super(); /** * The launch template ID * @type {string || null} */ this.LaunchTemplateId = null; /** * List of instance launch template versions. * @type {Array.<number> || null} */ this.LaunchTemplateVersions = null; } /** * @private */ deserialize(params) { if (!params) { return; } this.LaunchTemplateId = 'LaunchTemplateId' in params ? params.LaunchTemplateId : null; this.LaunchTemplateVersions = 'LaunchTemplateVersions' in params ? params.LaunchTemplateVersions : null; } } /** * DeleteImages request structure. * @class */ class DeleteImagesRequest extends AbstractModel { constructor(){ super(); /** * List of the IDs of the instances to be deleted. * @type {Array.<string> || null} */ this.ImageIds = null; /** * Whether to delete the snapshot associated with the image * @type {boolean || null} */ this.DeleteBindedSnap = null; /** * Check whether deleting an image is supported * @type {boolean || null} */ this.DryRun = null; } /** * @private */ deserialize(params) { if (!params) { return; } this.ImageIds = 'ImageIds' in params ? params.ImageIds : null; this.DeleteBindedSnap = 'DeleteBindedSnap' in params ? params.DeleteBindedSnap : null; this.DryRun = 'DryRun' in params ? params.DryRun : null; } } /** * DeleteLaunchTemplate request structure. * @class */ class DeleteLaunchTemplateRequest extends AbstractModel { constructor(){ super(); /** * The launch template ID * @type {string || null} */ this.LaunchTemplateId = null; } /** * @private */ deserialize(params) { if (!params) { return; } this.LaunchTemplateId = 'LaunchTemplateId' in params ? params.LaunchTemplateId : null; } } /** * DescribeInstances response structure. * @class */ class DescribeInstancesResponse extends AbstractModel { constructor(){ super(); /** * Number of instances meeting the filtering conditions. * @type {number || null} */ this.TotalCount = null; /** * Detailed instance information. * @type {Array.<Instance> || null} */ this.InstanceSet = null; /** * The unique request ID, generated by the server, will be returned for every request (if the request fails to reach the server for other reasons, the request will not obtain a RequestId). RequestId is required for locating a problem. * @type {string || null} */ this.RequestId = null; } /** * @private */ deserialize(params) { if (!params) { return; } this.TotalCount = 'TotalCount' in params ? params.TotalCount : null; if (params.InstanceSet) { this.InstanceSet = new Array(); for (let z in params.InstanceSet) { let obj = new Instance(); obj.deserialize(params.InstanceSet[z]); this.InstanceSet.push(obj); } } this.RequestId = 'RequestId' in params ? params.RequestId : null; } } /** * DescribeHosts response structure. * @class */ class DescribeHostsResponse extends AbstractModel { constructor(){ super(); /** * Total number of CDH instances meeting the query conditions * @type {number || null} */ this.TotalCount = null; /** * Information on CDH instances * @type {Array.<HostItem> || null} */ this.HostSet = null; /** * The unique request ID, generated by the server, will be returned for every request (if the request fails to reach the server for other reasons, the request will not obtain a RequestId). RequestId is required for locating a problem. * @type {string || null} */ this.RequestId = null; } /** * @private */ deserialize(params) { if (!params) { return; } this.TotalCount = 'TotalCount' in params ? params.TotalCount : null; if (params.HostSet) { this.HostSet = new Array(); for (let z in params.HostSet) { let obj = new HostItem(); obj.deserialize(params.HostSet[z]); this.HostSet.push(obj); } } this.RequestId = 'RequestId' in params ? params.RequestId : null; } } /** * DeleteKeyPairs request structure. * @class */ class DeleteKeyPairsRequest extends AbstractModel { constructor(){ super(); /** * One or more key pair IDs to be operated. The maximum number of key pairs per request is 100.<br>You can obtain an available key pair ID in the following ways:<br><li>Log in to the [console](https://console.cloud.tencent.com/cvm/sshkey) to query the key pair ID.</li><br><li>Call the [DescribeKeyPairs](https://intl.cloud.tencent.com/document/api/213/15699?from_cn_redirect=1) API and obtain the key pair ID from the `KeyId` in the response.</li> * @type {Array.<string> || null} */ this.KeyIds = null; } /** * @private */ deserialize(params) { if (!params) { return; } this.KeyIds = 'KeyIds' in params ? params.KeyIds : null; } } /** * Describes information on the block device where the operating system is stored, i.e., the system disk. * @class */ class SystemDisk extends AbstractModel { constructor(){ super(); /** * System disk type. For the restrictions on the system disk type, refer to [Storage Overview](https://intl.cloud.tencent.com/document/product/213/4952?from_cn_redirect=1). Value values:<br> <li>LOCAL_BASIC: Local Disk</li> <li>LOCAL_SSD: Local SSD</li> <li>CLOUD_BASIC: Basic Cloud Disk</li> <li>CLOUD_SSD: Cloud SSD</li> <li>CLOUD_PREMIUM: Premium Disk</li> <li>CLOUD_BSSD: Balanced SSD</li> <li>CLOUD_HSSD: Enhanced SSD</li> <li>CLOUD_TSSD: Tremendous SSD</li><br> Default value: Current disk types with inventory available. * @type {string || null} */ this.DiskType = null; /** * System disk ID. System disks whose type is `LOCAL_BASIC` or `LOCAL_SSD` do not have an ID and do not support this parameter. It is only used as a response parameter for APIs such as `DescribeInstances`, and cannot be used as a request parameter for APIs such as `RunInstances`. * @type {string || null} */ this.DiskId = null; /** * System disk size; unit: GB; default value: 50 GB. * @type {number || null} */ this.DiskSize = null; /** * ID of the dedicated cluster to which the instance belongs. * @type {string || null} */ this.CdcId = null; /** * Disk name, with a length of not more than 128 characters. This parameter is in invite-only testing and is not yet open for use. Note: This field may return null, indicating that no valid value is found. * @type {string || null} */ this.DiskName = null; } /** * @private */ deserialize(params) { if (!params) { return; } this.DiskType = 'DiskType' in params ? params.DiskType : null; this.DiskId = 'DiskId' in params ? params.DiskId : null; this.DiskSize = 'DiskSize' in params ? params.DiskSize : null; this.CdcId = 'CdcId' in params ? params.CdcId : null; this.DiskName = 'DiskName' in params ? params.DiskName : null; } } /** * ResetInstance request structure. * @class */ class ResetInstanceRequest extends AbstractModel { constructor(){ super(); /** * Instance ID. To obtain the instance IDs, you can call [`DescribeInstances`](https://intl.cloud.tencent.com/document/api/213/15728?from_cn_redirect=1) and look for `InstanceId` in the response. * @type {string || null} */ this.InstanceId = null; /** * Specified effective [image](https://intl.cloud.tencent.com/document/product/213/4940?from_cn_redirect=1) ID in the format of `img-xxx`. There are four types of images:<br/><li>Public images</li><li>Custom images</li><li>Shared images</li><li>Marketplace images </li><br/>You can obtain the available image IDs in the following ways:<br/><li>for IDs of `public images`, `custom images`, and `shared images`, log in to the [CVM console](https://console.cloud.tencent.com/cvm/image?rid=1&imageType=PUBLIC_IMAGE); for IDs of `marketplace images`, go to [Cloud Marketplace](https://market.cloud.tencent.com/list).</li><li>Call the API [DescribeImages](https://intl.cloud.tencent.com/document/api/213/15715?from_cn_redirect=1) and look for `ImageId` in the response.</li> <br>Default value: current image. * @type {string || null} */ this.ImageId = null; /** * Configurations of the system disk. For an instance whose system disk is a cloud disk, this parameter can be used to expand the system disk by specifying a new capacity after reinstallation. The system disk capacity can only be expanded but not shrunk. Reinstalling the system can only resize rather than changing the type of the system disk. * @type {SystemDisk || null} */ this.SystemDisk = null; /** * Login settings of the instance. You can use this parameter to set the login method, password, and key of the instance or keep the login settings of the original image. By default, a random password will be generated and sent to you via the Message Center. * @type {LoginSettings || null} */ this.LoginSettings = null; /** * Enhanced services. You can specify whether to enable services such as Cloud Security and Cloud Monitor through this parameter. If this parameter is not specified, Cloud Monitor and Cloud Security are enabled for public images by default, but not enabled for custom images and marketplace images by default. Instead, they use services retained in the images. * @type {EnhancedService || null} */ this.EnhancedService = null; /** * When reinstalling a system, you can modify an instance's hostname.<br><li>Period (.) and hyphen (-) should not be used as the first or last character of the hostname, and should not be used consecutively.</li><br><li>Windows instances: The hostname should contain 2 to 15 characters, including letters (case insensitive), digits, and hyphens (-), does not support periods (.), and should not be all digits.</li><br><li>Instances of other types (such as Linux instances): The hostname should contain 2 to 60 characters, including multiple periods (.), with each segment between periods considered as one section. Each section can contain letters (case insensitive), digits, and hyphens (-).</li> * @type {string || null} */ this.HostName = null; /** * User data provided to the instance. This parameter needs to be encoded in base64 format with the maximum size of 16 KB. For more information on how to get the value of this parameter, see the commands you need to execute on startup for [Windows](https://intl.cloud.tencent.com/document/product/213/17526) or [Linux](https://intl.cloud.tencent.com/document/product/213/17525). * @type {string || null} */ this.UserData = null; } /** * @private */ deserialize(params) { if (!params) { return; } this.InstanceId = 'InstanceId' in params ? params.InstanceId : null; this.ImageId = 'ImageId' in params ? params.ImageId : null; if (params.SystemDisk) { let obj = new SystemDisk(); obj.deserialize(params.SystemDisk) this.SystemDisk = obj; } if (params.LoginSettings) { let obj = new LoginSettings(); obj.deserialize(params.LoginSettings) this.LoginSettings = obj; } if (params.EnhancedService) { let obj = new EnhancedService(); obj.deserialize(params.EnhancedService) this.EnhancedService = obj; } this.HostName = 'HostName' in params ? params.HostName : null; this.UserData = 'UserData' in params ? params.UserData : null; } } /** * ExitRescueMode response structure. * @class */ class ExitRescueModeResponse extends AbstractModel { constructor(){ super(); /** * The unique request ID, generated by the server, will be returned for every request (if the request fails to reach the server for other reasons, the request will not obtain a RequestId). RequestId is required for locating a problem. * @type {string || null} */ this.RequestId = null; } /** * @private */ deserialize(params) { if (!params) { return; } this.RequestId = 'RequestId' in params ? params.RequestId : null; } } /** * DescribeChcHosts response structure. * @class */ class DescribeChcHostsResponse extends AbstractModel { constructor(){ super(); /** * Number of eligible instances * @type {number || null} */ this.TotalCount = null; /** * List of returned instances * @type {Array.<ChcHost> || null} */ this.ChcHostSet = null; /** * The unique request ID, generated by the server, will be returned for every request (if the request fails to reach the server for other reasons, the request will not obtain a RequestId). RequestId is required for locating a problem. * @type {string || null} */ this.RequestId = null; } /** * @private */ deserialize(params) { if (!params) { return; } this.TotalCount = 'TotalCount' in params ? params.TotalCount : null; if (params.ChcHostSet) { this.ChcHostSet = new Array(); for (let z in params.ChcHostSet) { let obj = new ChcHost(); obj.deserialize(params.ChcHostSet[z]); this.ChcHostSet.push(obj); } } this.RequestId = 'RequestId' in params ? params.RequestId : null; } } /** * AllocateHosts request structure. * @class */ class AllocateHostsRequest extends AbstractModel { constructor(){ super(); /** * Instance location. This parameter is used to specify the attributes of an instance, such as its availability zone and project. * @type {Placement || null} */ this.Placement = null; /** * A string used to ensure the idempotency of the request. * @type {string || null} */ this.ClientToken = null; /** * Configuration of prepaid instances. You can use the parameter to specify the attributes of prepaid instances, such as the subscription period and the auto-renewal plan. This parameter is required for prepaid instances. * @type {ChargePrepaid || null} */ this.HostChargePrepaid = null; /** * Instance billing model, only monthly or yearly subscription supported. Default value: `PREPAID'. * @type {string || null} */ this.HostChargeType = null; /** * CDH instance model. Default value: `HS1`. * @type {string || null} */ this.HostType = null; /** * Quantity of CDH instances purchased. Default value: 1. * @type {number || null} */ this.HostCount = null; /** * Tag description. You can specify the parameter to associate a tag with an instance. * @type {Array.<TagSpecification> || null} */ this.TagSpecification = null; } /** * @private */ deserialize(params) { if (!params) { return; } if (params.Placement) { let obj = new Placement(); obj.deserialize(params.Placement) this.Placement = obj; } this.ClientToken = 'ClientToken' in params ? params.ClientToken : null; if (params.HostChargePrepaid) { let obj = new ChargePrepaid(); obj.deserialize(params.HostChargePrepaid) this.HostChargePrepaid = obj; } this.HostChargeType = 'HostChargeType' in params ? params.HostChargeType : null; this.HostType = 'HostType' in params ? params.HostType : null; this.HostCount = 'HostCount' in params ? params.HostCount : null; if (params.TagSpecification) { this.TagSpecification = new Array(); for (let z in params.TagSpecification) { let obj = new TagSpecification(); obj.deserialize(params.TagSpecification[z]); this.TagSpecification.push(obj); } } } } /** * DescribeImageFromFamily request structure. * @class */ class DescribeImageFromFamilyRequest extends AbstractModel { constructor(){ super(); /** * Image family * @type {string || null} */ this.ImageFamily = null; } /** * @private */ deserialize(params) { if (!params) { return; } this.ImageFamily = 'ImageFamily' in params ? params.ImageFamily : null; } } /** * DescribeRegions response structure. * @class */ class DescribeRegionsResponse extends AbstractModel { constructor(){ super(); /** * Number of regions * @type {number || null} */ this.TotalCount = null; /** * List of regions * @type {Array.<RegionInfo> || null} */ this.RegionSet = null; /** * The unique request ID, generated by the server, will be returned for every request (if the request fails to reach the server for other reasons, the request will not obtain a RequestId). RequestId is required for locating a problem. * @type {string || null} */ this.RequestId = null; } /** * @private */ deserialize(params) { if (!params) { return; } this.TotalCount = 'TotalCount' in params ? params.TotalCount : null; if (params.RegionSet) { this.RegionSet = new Array(); for (let z in params.RegionSet) { let obj = new RegionInfo(); obj.deserialize(params.RegionSet[z]); this.RegionSet.push(obj); } } this.RequestId = 'RequestId' in params ? params.RequestId : null; } } /** * PurchaseReservedInstancesOffering request structure. * @class */ class PurchaseReservedInstancesOfferingRequest extends AbstractModel { constructor(){ super(); /** * The number of the Reserved Instance you are purchasing. * @type {number || null} */ this.InstanceCount = null; /** * The ID of the Reserved Instance. * @type {string || null} */ this.ReservedInstancesOfferingId = null; /** * Dry run * @type {boolean || null} */ this.DryRun = null; /** * A unique string supplied by the client to ensure that the request is idempotent. Its maximum length is 64 ASCII characters. If this parameter is not specified, the idempotency of the request cannot be guaranteed.<br>For more information, see Ensuring Idempotency. * @type {string || null} */ this.ClientToken = null; /** * Reserved instance name.<br><li>The RI name defaults to “unnamed” if this parameter is left empty.</li><li>You can enter any name within 60 characters (including the pattern string).</li> * @type {string || null} */ this.ReservedInstanceName = null; } /** * @private */ deserialize(params) { if (!params) { return; } this.InstanceCount = 'InstanceCount' in params ? params.InstanceCount : null; this.ReservedInstancesOfferingId = 'ReservedInstancesOfferingId' in params ? params.ReservedInstancesOfferingId : null; this.DryRun = 'DryRun' in params ? params.DryRun : null; this.ClientToken = 'ClientToken' in params ? params.ClientToken : null; this.ReservedInstanceName = 'ReservedInstanceName' in params ? params.ReservedInstanceName : null; } } /** * RebootInstances request structure. * @class */ class RebootInstancesRequest extends AbstractModel { constructor(){ super(); /** * Instance IDs. To obtain the instance IDs, you can call [`DescribeInstances`](https://intl.cloud.tencent.com/document/api/213/15728?from_cn_redirect=1) and look for `InstanceId` in the response. You can operate up to 100 instances in each request. * @type {Array.<string> || null} */ this.InstanceIds = null; /** * Whether to forcibly restart an instance after a normal restart fails. Valid values: <br><li>`TRUE`: yes;<br><li>`FALSE`: no<br><br>Default value: `FALSE`. This parameter has been disused. We recommend using `StopType` instead. Note that `ForceReboot` and `StopType` parameters cannot be specified at the same time. * @type {boolean || null} */ this.ForceReboot = null; /** * Shutdown type. Valid values: <br><li>SOFT: soft shutdown<br><li>HARD: hard shutdown<br><li>SOFT_FIRST: perform a soft shutdown first, and perform a hard shutdown if the soft shutdown fails<br><br>Default value: SOFT. * @type {string || null} */ this.StopType = null; } /** * @private */ deserialize(params) { if (!params) { return; } this.InstanceIds = 'InstanceIds' in params ? params.InstanceIds : null; this.ForceReboot = 'ForceReboot' in params ? params.ForceReboot : null; this.StopType = 'StopType' in params ? params.StopType : null; } } /** * AssociateInstancesKeyPairs request structure. * @class */ class AssociateInstancesKeyPairsRequest extends AbstractModel { constructor(){ super(); /** * Instance ID(s). The maximum number of instances in each request is 100. <br>You can obtain the available instance IDs in two ways: <br><li>Log in to the [console](https://console.cloud.tencent.com/cvm/index) to query the instance IDs. <br><li>Call [DescribeInstances](https://intl.cloud.tencent.com/document/api/213/15728?from_cn_redirect=1) and look for `InstanceId` in the response. * @type {Array.<string> || null} */ this.InstanceIds = null; /** * Key ID(s). The maximum number of key pairs in each request is 100. The key pair ID is in the format of `skey-3glfot13`. <br>You can obtain the available key pair IDs in two ways: <br><li>Log in to the [console](https://console.cloud.tencent.com/cvm/sshkey) to query the key pair IDs. <br><li>Call [DescribeKeyPairs](https://intl.cloud.tencent.com/document/api/213/15699?from_cn_redirect=1) and look