@ucloud-sdks/ucloud-sdk-js 0.2.3 → 0.2.4
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/lib/services/index.d.ts
CHANGED
package/lib/services/index.js
CHANGED
|
@@ -18,6 +18,7 @@ const UFSClient = require('./ufs').default;
|
|
|
18
18
|
const UHostClient = require('./uhost').default;
|
|
19
19
|
const UK8SClient = require('./uk8s').default;
|
|
20
20
|
const ULBClient = require('./ulb').default;
|
|
21
|
+
const ULightHostClient = require('./ulight_host').default;
|
|
21
22
|
const UMemClient = require('./umem').default;
|
|
22
23
|
const UNetClient = require('./unet').default;
|
|
23
24
|
const UPhoneClient = require('./uphone').default;
|
|
@@ -30,7 +31,10 @@ class Client extends BaseClient {
|
|
|
30
31
|
super({ config, credential });
|
|
31
32
|
}
|
|
32
33
|
cube() {
|
|
33
|
-
return new CubeClient({
|
|
34
|
+
return new CubeClient({
|
|
35
|
+
config: this.config,
|
|
36
|
+
credential: this.credential,
|
|
37
|
+
});
|
|
34
38
|
}
|
|
35
39
|
ipsecvpn() {
|
|
36
40
|
return new IPSecVPNClient({
|
|
@@ -57,13 +61,22 @@ class Client extends BaseClient {
|
|
|
57
61
|
});
|
|
58
62
|
}
|
|
59
63
|
ucdn() {
|
|
60
|
-
return new UCDNClient({
|
|
64
|
+
return new UCDNClient({
|
|
65
|
+
config: this.config,
|
|
66
|
+
credential: this.credential,
|
|
67
|
+
});
|
|
61
68
|
}
|
|
62
69
|
udb() {
|
|
63
|
-
return new UDBClient({
|
|
70
|
+
return new UDBClient({
|
|
71
|
+
config: this.config,
|
|
72
|
+
credential: this.credential,
|
|
73
|
+
});
|
|
64
74
|
}
|
|
65
75
|
uddb() {
|
|
66
|
-
return new UDDBClient({
|
|
76
|
+
return new UDDBClient({
|
|
77
|
+
config: this.config,
|
|
78
|
+
credential: this.credential,
|
|
79
|
+
});
|
|
67
80
|
}
|
|
68
81
|
udisk() {
|
|
69
82
|
return new UDiskClient({
|
|
@@ -72,10 +85,16 @@ class Client extends BaseClient {
|
|
|
72
85
|
});
|
|
73
86
|
}
|
|
74
87
|
udpn() {
|
|
75
|
-
return new UDPNClient({
|
|
88
|
+
return new UDPNClient({
|
|
89
|
+
config: this.config,
|
|
90
|
+
credential: this.credential,
|
|
91
|
+
});
|
|
76
92
|
}
|
|
77
93
|
uec() {
|
|
78
|
-
return new UECClient({
|
|
94
|
+
return new UECClient({
|
|
95
|
+
config: this.config,
|
|
96
|
+
credential: this.credential,
|
|
97
|
+
});
|
|
79
98
|
}
|
|
80
99
|
ufile() {
|
|
81
100
|
return new UFileClient({
|
|
@@ -84,7 +103,10 @@ class Client extends BaseClient {
|
|
|
84
103
|
});
|
|
85
104
|
}
|
|
86
105
|
ufs() {
|
|
87
|
-
return new UFSClient({
|
|
106
|
+
return new UFSClient({
|
|
107
|
+
config: this.config,
|
|
108
|
+
credential: this.credential,
|
|
109
|
+
});
|
|
88
110
|
}
|
|
89
111
|
uhost() {
|
|
90
112
|
return new UHostClient({
|
|
@@ -93,16 +115,34 @@ class Client extends BaseClient {
|
|
|
93
115
|
});
|
|
94
116
|
}
|
|
95
117
|
uk8s() {
|
|
96
|
-
return new UK8SClient({
|
|
118
|
+
return new UK8SClient({
|
|
119
|
+
config: this.config,
|
|
120
|
+
credential: this.credential,
|
|
121
|
+
});
|
|
97
122
|
}
|
|
98
123
|
ulb() {
|
|
99
|
-
return new ULBClient({
|
|
124
|
+
return new ULBClient({
|
|
125
|
+
config: this.config,
|
|
126
|
+
credential: this.credential,
|
|
127
|
+
});
|
|
128
|
+
}
|
|
129
|
+
ulight_host() {
|
|
130
|
+
return new ULightHostClient({
|
|
131
|
+
config: this.config,
|
|
132
|
+
credential: this.credential,
|
|
133
|
+
});
|
|
100
134
|
}
|
|
101
135
|
umem() {
|
|
102
|
-
return new UMemClient({
|
|
136
|
+
return new UMemClient({
|
|
137
|
+
config: this.config,
|
|
138
|
+
credential: this.credential,
|
|
139
|
+
});
|
|
103
140
|
}
|
|
104
141
|
unet() {
|
|
105
|
-
return new UNetClient({
|
|
142
|
+
return new UNetClient({
|
|
143
|
+
config: this.config,
|
|
144
|
+
credential: this.credential,
|
|
145
|
+
});
|
|
106
146
|
}
|
|
107
147
|
uphone() {
|
|
108
148
|
return new UPhoneClient({
|
|
@@ -117,13 +157,22 @@ class Client extends BaseClient {
|
|
|
117
157
|
});
|
|
118
158
|
}
|
|
119
159
|
usms() {
|
|
120
|
-
return new USMSClient({
|
|
160
|
+
return new USMSClient({
|
|
161
|
+
config: this.config,
|
|
162
|
+
credential: this.credential,
|
|
163
|
+
});
|
|
121
164
|
}
|
|
122
165
|
uvms() {
|
|
123
|
-
return new UVMSClient({
|
|
166
|
+
return new UVMSClient({
|
|
167
|
+
config: this.config,
|
|
168
|
+
credential: this.credential,
|
|
169
|
+
});
|
|
124
170
|
}
|
|
125
171
|
vpc() {
|
|
126
|
-
return new VPCClient({
|
|
172
|
+
return new VPCClient({
|
|
173
|
+
config: this.config,
|
|
174
|
+
credential: this.credential,
|
|
175
|
+
});
|
|
127
176
|
}
|
|
128
177
|
}
|
|
129
178
|
exports.Client = Client;
|
|
@@ -0,0 +1,824 @@
|
|
|
1
|
+
import Client from '../../core/client';
|
|
2
|
+
import { ConfigOptions } from '../../core/config';
|
|
3
|
+
import { CredentialOptions } from '../../core/credential';
|
|
4
|
+
/**
|
|
5
|
+
* This client is used to call actions of **ulight_host** service
|
|
6
|
+
*/
|
|
7
|
+
export default class ULightHostClient extends Client {
|
|
8
|
+
constructor({ config, credential, }: {
|
|
9
|
+
config: ConfigOptions;
|
|
10
|
+
credential: CredentialOptions;
|
|
11
|
+
});
|
|
12
|
+
/**
|
|
13
|
+
* CheckULHostResourceCapacity - 检查轻量应用云主机资源余量
|
|
14
|
+
*
|
|
15
|
+
* See also: https://docs.ucloud.cn/api/ulighthost-api/check_ul_host_resource_capacity
|
|
16
|
+
*/
|
|
17
|
+
checkULHostResourceCapacity(request?: CheckULHostResourceCapacityRequest): Promise<CheckULHostResourceCapacityResponse>;
|
|
18
|
+
/**
|
|
19
|
+
* CreateULHostInstance - 创建轻量应用云主机
|
|
20
|
+
*
|
|
21
|
+
* See also: https://docs.ucloud.cn/api/ulighthost-api/create_ul_host_instance
|
|
22
|
+
*/
|
|
23
|
+
createULHostInstance(request?: CreateULHostInstanceRequest): Promise<CreateULHostInstanceResponse>;
|
|
24
|
+
/**
|
|
25
|
+
* DescribeULHostBundles - 获取轻量应用云主机套餐列表
|
|
26
|
+
*
|
|
27
|
+
* See also: https://docs.ucloud.cn/api/ulighthost-api/describe_ul_host_bundles
|
|
28
|
+
*/
|
|
29
|
+
describeULHostBundles(request?: DescribeULHostBundlesRequest): Promise<DescribeULHostBundlesResponse>;
|
|
30
|
+
/**
|
|
31
|
+
* DescribeULHostImage - 获取指定数据中心镜像列表
|
|
32
|
+
*
|
|
33
|
+
* See also: https://docs.ucloud.cn/api/ulighthost-api/describe_ul_host_image
|
|
34
|
+
*/
|
|
35
|
+
describeULHostImage(request?: DescribeULHostImageRequest): Promise<DescribeULHostImageResponse>;
|
|
36
|
+
/**
|
|
37
|
+
* DescribeULHostInstance - 获取轻量应用云主机列表
|
|
38
|
+
*
|
|
39
|
+
* See also: https://docs.ucloud.cn/api/ulighthost-api/describe_ul_host_instance
|
|
40
|
+
*/
|
|
41
|
+
describeULHostInstance(request?: DescribeULHostInstanceRequest): Promise<DescribeULHostInstanceResponse>;
|
|
42
|
+
/**
|
|
43
|
+
* GetULHostInstancePrice - 获取轻量应用云主机套餐价格
|
|
44
|
+
*
|
|
45
|
+
* See also: https://docs.ucloud.cn/api/ulighthost-api/get_ul_host_instance_price
|
|
46
|
+
*/
|
|
47
|
+
getULHostInstancePrice(request?: GetULHostInstancePriceRequest): Promise<GetULHostInstancePriceResponse>;
|
|
48
|
+
/**
|
|
49
|
+
* GetULHostRenewPrice - 获取主机续费价格
|
|
50
|
+
*
|
|
51
|
+
* See also: https://docs.ucloud.cn/api/ulighthost-api/get_ul_host_renew_price
|
|
52
|
+
*/
|
|
53
|
+
getULHostRenewPrice(request?: GetULHostRenewPriceRequest): Promise<GetULHostRenewPriceResponse>;
|
|
54
|
+
/**
|
|
55
|
+
* ModifyULHostAttribute - 修改指定ULHost实例属性信息,包含名称和备注
|
|
56
|
+
*
|
|
57
|
+
* See also: https://docs.ucloud.cn/api/ulighthost-api/modify_ul_host_attribute
|
|
58
|
+
*/
|
|
59
|
+
modifyULHostAttribute(request?: ModifyULHostAttributeRequest): Promise<ModifyULHostAttributeResponse>;
|
|
60
|
+
/**
|
|
61
|
+
* PoweroffULHostInstance - 直接关闭UHost实例电源,无需等待实例正常关闭。
|
|
62
|
+
*
|
|
63
|
+
* See also: https://docs.ucloud.cn/api/ulighthost-api/poweroff_ul_host_instance
|
|
64
|
+
*/
|
|
65
|
+
poweroffULHostInstance(request?: PoweroffULHostInstanceRequest): Promise<PoweroffULHostInstanceResponse>;
|
|
66
|
+
/**
|
|
67
|
+
* RebootULHostInstance - 重新启动UHost实例。
|
|
68
|
+
*
|
|
69
|
+
* See also: https://docs.ucloud.cn/api/ulighthost-api/reboot_ul_host_instance
|
|
70
|
+
*/
|
|
71
|
+
rebootULHostInstance(request?: RebootULHostInstanceRequest): Promise<RebootULHostInstanceResponse>;
|
|
72
|
+
/**
|
|
73
|
+
* ReinstallULHostInstance - 重装轻量应用云主机
|
|
74
|
+
*
|
|
75
|
+
* See also: https://docs.ucloud.cn/api/ulighthost-api/reinstall_ul_host_instance
|
|
76
|
+
*/
|
|
77
|
+
reinstallULHostInstance(request?: ReinstallULHostInstanceRequest): Promise<ReinstallULHostInstanceResponse>;
|
|
78
|
+
/**
|
|
79
|
+
* ResetULHostInstancePassword - 重置轻量应用云主机管理员密码。
|
|
80
|
+
*
|
|
81
|
+
* See also: https://docs.ucloud.cn/api/ulighthost-api/reset_ul_host_instance_password
|
|
82
|
+
*/
|
|
83
|
+
resetULHostInstancePassword(request?: ResetULHostInstancePasswordRequest): Promise<ResetULHostInstancePasswordResponse>;
|
|
84
|
+
/**
|
|
85
|
+
* StartULHostInstance - 启动处于关闭状态的UHost实例。
|
|
86
|
+
*
|
|
87
|
+
* See also: https://docs.ucloud.cn/api/ulighthost-api/start_ul_host_instance
|
|
88
|
+
*/
|
|
89
|
+
startULHostInstance(request?: StartULHostInstanceRequest): Promise<StartULHostInstanceResponse>;
|
|
90
|
+
/**
|
|
91
|
+
* StopULHostInstance - 指停止处于运行状态的ULHost实例
|
|
92
|
+
*
|
|
93
|
+
* See also: https://docs.ucloud.cn/api/ulighthost-api/stop_ul_host_instance
|
|
94
|
+
*/
|
|
95
|
+
stopULHostInstance(request?: StopULHostInstanceRequest): Promise<StopULHostInstanceResponse>;
|
|
96
|
+
/**
|
|
97
|
+
* TerminateULHostInstance - 删除指定数据中心的ULHost实例。
|
|
98
|
+
*
|
|
99
|
+
* See also: https://docs.ucloud.cn/api/ulighthost-api/terminate_ul_host_instance
|
|
100
|
+
*/
|
|
101
|
+
terminateULHostInstance(request?: TerminateULHostInstanceRequest): Promise<TerminateULHostInstanceResponse>;
|
|
102
|
+
}
|
|
103
|
+
/**
|
|
104
|
+
* CheckULHostResourceCapacity - 检查轻量应用云主机资源余量
|
|
105
|
+
*/
|
|
106
|
+
export interface CheckULHostResourceCapacityRequest {
|
|
107
|
+
/**
|
|
108
|
+
* 镜像ID。 请通过 [DescribeImage](describe_image.html)获取
|
|
109
|
+
*/
|
|
110
|
+
ImageId: string;
|
|
111
|
+
/**
|
|
112
|
+
* 套餐ID。如:"ulh.c1m1s40b30t800"
|
|
113
|
+
*/
|
|
114
|
+
BundleId: string;
|
|
115
|
+
/**
|
|
116
|
+
* 轻量应用主机名称。默认:套餐ID。请遵照[[api:uhost-api:specification|字段规范]]设定实例名称。
|
|
117
|
+
*/
|
|
118
|
+
Name?: string;
|
|
119
|
+
/**
|
|
120
|
+
* 计费模式。枚举值: \\ > Year,按年付费; \\ > Month,按月付费;\\ > ThirtyDay,30天期付费,跨境电商相关套餐使用此计费方式;默认:Month
|
|
121
|
+
*/
|
|
122
|
+
ChargeType?: string;
|
|
123
|
+
/**
|
|
124
|
+
* 购买时长。默认:1。不支持购买到月末
|
|
125
|
+
*/
|
|
126
|
+
Quantity?: number;
|
|
127
|
+
/**
|
|
128
|
+
* VPC ID。默认为当前地域的默认VPC。
|
|
129
|
+
*/
|
|
130
|
+
VPCId?: string;
|
|
131
|
+
/**
|
|
132
|
+
* 子网 ID。默认为当前地域的默认子网。
|
|
133
|
+
*/
|
|
134
|
+
SubnetId?: string;
|
|
135
|
+
/**
|
|
136
|
+
* 防火墙ID,默认:Web推荐防火墙。如何查询SecurityGroupId请参见 [DescribeFirewall](api/unet-api/describe_firewall.html)。
|
|
137
|
+
*/
|
|
138
|
+
SecurityGroupId?: string;
|
|
139
|
+
/**
|
|
140
|
+
* 主机代金券ID。请通过DescribeCoupon接口查询,或登录用户中心查看
|
|
141
|
+
*/
|
|
142
|
+
CouponId?: string;
|
|
143
|
+
}
|
|
144
|
+
/**
|
|
145
|
+
* CheckULHostResourceCapacity - 检查轻量应用云主机资源余量
|
|
146
|
+
*/
|
|
147
|
+
export interface CheckULHostResourceCapacityResponse {
|
|
148
|
+
/**
|
|
149
|
+
* 资源是否充足
|
|
150
|
+
*/
|
|
151
|
+
ResourceEnough: boolean;
|
|
152
|
+
}
|
|
153
|
+
/**
|
|
154
|
+
* CreateULHostInstance - 创建轻量应用云主机
|
|
155
|
+
*/
|
|
156
|
+
export interface CreateULHostInstanceRequest {
|
|
157
|
+
/**
|
|
158
|
+
* 镜像ID。 请通过 [DescribeImage](describe_image.html)获取
|
|
159
|
+
*/
|
|
160
|
+
ImageId: string;
|
|
161
|
+
/**
|
|
162
|
+
* 套餐ID。如:"ulh.c1m1s40b30t800"
|
|
163
|
+
*/
|
|
164
|
+
BundleId: string;
|
|
165
|
+
/**
|
|
166
|
+
* ULHost密码。请遵照[[api:uhost-api:specification|字段规范]]设定密码。密码需使用base64进行编码,举例如下:# echo -n Password1 | base64
|
|
167
|
+
*/
|
|
168
|
+
Password: string;
|
|
169
|
+
/**
|
|
170
|
+
* 轻量应用主机名称。默认:套餐ID。请遵照[[api:uhost-api:specification|字段规范]]设定实例名称。
|
|
171
|
+
*/
|
|
172
|
+
Name?: string;
|
|
173
|
+
/**
|
|
174
|
+
* 计费模式。枚举值: \\ > Year,按年付费; \\ > Month,按月付费;\\ > ThirtyDay,30天期付费,跨境电商相关套餐使用此计费方式;默认:Month
|
|
175
|
+
*/
|
|
176
|
+
ChargeType?: string;
|
|
177
|
+
/**
|
|
178
|
+
* 购买时长。默认:1。不支持购买到月末
|
|
179
|
+
*/
|
|
180
|
+
Quantity?: number;
|
|
181
|
+
/**
|
|
182
|
+
* VPC ID。默认为当前地域的默认VPC。
|
|
183
|
+
*/
|
|
184
|
+
VPCId?: string;
|
|
185
|
+
/**
|
|
186
|
+
* 子网 ID。默认为当前地域的默认子网。
|
|
187
|
+
*/
|
|
188
|
+
SubnetId?: string;
|
|
189
|
+
/**
|
|
190
|
+
* 防火墙ID,默认:Web推荐防火墙。如何查询SecurityGroupId请参见 [DescribeFirewall](api/unet-api/describe_firewall.html)。
|
|
191
|
+
*/
|
|
192
|
+
SecurityGroupId?: string;
|
|
193
|
+
/**
|
|
194
|
+
* 主机代金券ID。请通过DescribeCoupon接口查询,或登录用户中心查看
|
|
195
|
+
*/
|
|
196
|
+
CouponId?: string;
|
|
197
|
+
}
|
|
198
|
+
/**
|
|
199
|
+
* CreateULHostInstance - 创建轻量应用云主机
|
|
200
|
+
*/
|
|
201
|
+
export interface CreateULHostInstanceResponse {
|
|
202
|
+
/**
|
|
203
|
+
* 实例ID
|
|
204
|
+
*/
|
|
205
|
+
ULHostId: string;
|
|
206
|
+
}
|
|
207
|
+
/**
|
|
208
|
+
* DescribeULHostBundles - 获取轻量应用云主机套餐列表
|
|
209
|
+
*/
|
|
210
|
+
export interface DescribeULHostBundlesRequest {
|
|
211
|
+
}
|
|
212
|
+
/**
|
|
213
|
+
* DescribeULHostBundles - 获取轻量应用云主机套餐列表
|
|
214
|
+
*/
|
|
215
|
+
export interface DescribeULHostBundlesResponse {
|
|
216
|
+
/**
|
|
217
|
+
* 套餐列表
|
|
218
|
+
*/
|
|
219
|
+
Bundles: {
|
|
220
|
+
/**
|
|
221
|
+
* 套餐ID。
|
|
222
|
+
*/
|
|
223
|
+
BundleId?: string;
|
|
224
|
+
/**
|
|
225
|
+
* CPU核数。
|
|
226
|
+
*/
|
|
227
|
+
CPU?: number;
|
|
228
|
+
/**
|
|
229
|
+
* 内存大小。单位:MB。
|
|
230
|
+
*/
|
|
231
|
+
Memory?: number;
|
|
232
|
+
/**
|
|
233
|
+
* 系统盘大小。单位:GB。
|
|
234
|
+
*/
|
|
235
|
+
SysDiskSpace?: number;
|
|
236
|
+
/**
|
|
237
|
+
* 外网带宽。单位:Mbps。
|
|
238
|
+
*/
|
|
239
|
+
Bandwidth?: number;
|
|
240
|
+
/**
|
|
241
|
+
* 流量包大小。单位:GB。
|
|
242
|
+
*/
|
|
243
|
+
TrafficPacket?: number;
|
|
244
|
+
}[];
|
|
245
|
+
}
|
|
246
|
+
/**
|
|
247
|
+
* DescribeULHostImage - 获取指定数据中心镜像列表
|
|
248
|
+
*/
|
|
249
|
+
export interface DescribeULHostImageRequest {
|
|
250
|
+
/**
|
|
251
|
+
* 可用区。参见 [可用区列表](https://docs.ucloud.cn/api/summary/regionlist)
|
|
252
|
+
*/
|
|
253
|
+
Zone?: string;
|
|
254
|
+
/**
|
|
255
|
+
* 镜像类型。标准镜像:Base,应用镜像:App, 自定义镜像:Custom,默认返回所有类型
|
|
256
|
+
*/
|
|
257
|
+
ImageType?: string;
|
|
258
|
+
/**
|
|
259
|
+
* 使用场景,当ImageType为"App"时生效。- Normal 常规专区- CrossBorder 跨境专区默认返回所有
|
|
260
|
+
*/
|
|
261
|
+
Scene?: string;
|
|
262
|
+
/**
|
|
263
|
+
* 操作系统类型:Linux, Windows 默认返回所有类型
|
|
264
|
+
*/
|
|
265
|
+
OsType?: string;
|
|
266
|
+
/**
|
|
267
|
+
* 镜像Id
|
|
268
|
+
*/
|
|
269
|
+
ImageId?: string;
|
|
270
|
+
/**
|
|
271
|
+
* 镜像Id列表
|
|
272
|
+
*/
|
|
273
|
+
ImageIds?: string[];
|
|
274
|
+
/**
|
|
275
|
+
* 业务组Id。默认:Default
|
|
276
|
+
*/
|
|
277
|
+
Tag?: string;
|
|
278
|
+
/**
|
|
279
|
+
* 列表起始位置偏移量,默认为0
|
|
280
|
+
*/
|
|
281
|
+
Offset?: number;
|
|
282
|
+
/**
|
|
283
|
+
* 返回数据长度,默认为20
|
|
284
|
+
*/
|
|
285
|
+
Limit?: number;
|
|
286
|
+
}
|
|
287
|
+
/**
|
|
288
|
+
* DescribeULHostImage - 获取指定数据中心镜像列表
|
|
289
|
+
*/
|
|
290
|
+
export interface DescribeULHostImageResponse {
|
|
291
|
+
/**
|
|
292
|
+
* 满足条件的镜像总数
|
|
293
|
+
*/
|
|
294
|
+
TotalCount?: number;
|
|
295
|
+
/**
|
|
296
|
+
* 镜像列表详见 UHostImageSet
|
|
297
|
+
*/
|
|
298
|
+
ImageSet?: {
|
|
299
|
+
/**
|
|
300
|
+
* 可用区,参见 [可用区列表](../summary/regionlist.html)
|
|
301
|
+
*/
|
|
302
|
+
Zone?: string;
|
|
303
|
+
/**
|
|
304
|
+
* 镜像ID
|
|
305
|
+
*/
|
|
306
|
+
ImageId?: string;
|
|
307
|
+
/**
|
|
308
|
+
* 镜像名称
|
|
309
|
+
*/
|
|
310
|
+
ImageName?: string;
|
|
311
|
+
/**
|
|
312
|
+
* 用于控制台显示的名称
|
|
313
|
+
*/
|
|
314
|
+
DisplayName?: string;
|
|
315
|
+
/**
|
|
316
|
+
* 业务组
|
|
317
|
+
*/
|
|
318
|
+
Tag?: string;
|
|
319
|
+
/**
|
|
320
|
+
* 操作系统类型:Linux,Windows
|
|
321
|
+
*/
|
|
322
|
+
OsType?: string;
|
|
323
|
+
/**
|
|
324
|
+
* 操作系统名称
|
|
325
|
+
*/
|
|
326
|
+
OsName?: string;
|
|
327
|
+
/**
|
|
328
|
+
* 镜像类型 标准镜像:Base, 行业镜像:Business,自定义镜像:Custom
|
|
329
|
+
*/
|
|
330
|
+
ImageType?: string;
|
|
331
|
+
/**
|
|
332
|
+
* 特殊状态标识,目前包含NetEnhnced(网络增强1.0), NetEnhanced_Ultra(网络增强2.0), NetEnhanced_Extreme(网络增强3.0), HotPlug(热升级), GPU(GPU镜像),CloudInit, IPv6(支持IPv6网络),RssdAttachable(支持RSSD云盘),Vgpu_AMD(支持AMD的vgpu),Vgpu_NVIDIA(支持NVIDIA的vgpu),Aarch64_Type(支持arm64架构)
|
|
333
|
+
*/
|
|
334
|
+
Features?: string[];
|
|
335
|
+
/**
|
|
336
|
+
* 集成软件名称(仅行业镜像将返回这个值)
|
|
337
|
+
*/
|
|
338
|
+
IntegratedSoftware?: string;
|
|
339
|
+
/**
|
|
340
|
+
* 镜像状态, 可用:Available,制作中:Making, 不可用:Unavailable,复制中:Copying
|
|
341
|
+
*/
|
|
342
|
+
State?: string;
|
|
343
|
+
/**
|
|
344
|
+
* 镜像描述
|
|
345
|
+
*/
|
|
346
|
+
ImageDescription?: string;
|
|
347
|
+
/**
|
|
348
|
+
* 创建时间,格式为Unix时间戳
|
|
349
|
+
*/
|
|
350
|
+
CreateTime?: number;
|
|
351
|
+
/**
|
|
352
|
+
* 镜像大小
|
|
353
|
+
*/
|
|
354
|
+
ImageSize?: number;
|
|
355
|
+
/**
|
|
356
|
+
* 默认值为空'''。当CentOS 7.3/7.4/7.5等镜像会标记为“Broadwell”
|
|
357
|
+
*/
|
|
358
|
+
MinimalCPU?: string;
|
|
359
|
+
/**
|
|
360
|
+
* 系统EOL的时间,格式:YYYY/MM/DD
|
|
361
|
+
*/
|
|
362
|
+
MaintainEol?: string;
|
|
363
|
+
/**
|
|
364
|
+
* 场景分类,目前包含Featured(精选),PreInstalledDrivers(预装驱动),AIPainting(AI绘画),AIModels(AI模型),HPC(高性能计算)
|
|
365
|
+
*/
|
|
366
|
+
SceneCategories?: string[];
|
|
367
|
+
/**
|
|
368
|
+
* 应用镜像图标url
|
|
369
|
+
*/
|
|
370
|
+
ImageLogoLink?: string;
|
|
371
|
+
}[];
|
|
372
|
+
}
|
|
373
|
+
/**
|
|
374
|
+
* DescribeULHostInstance - 获取轻量应用云主机列表
|
|
375
|
+
*/
|
|
376
|
+
export interface DescribeULHostInstanceRequest {
|
|
377
|
+
/**
|
|
378
|
+
* 【数组】轻量应用云主机ID。
|
|
379
|
+
*/
|
|
380
|
+
ULHostIds?: string[];
|
|
381
|
+
/**
|
|
382
|
+
* 列表起始位置偏移量,默认为0
|
|
383
|
+
*/
|
|
384
|
+
Offset?: number;
|
|
385
|
+
/**
|
|
386
|
+
* 返回数据长度,默认为20,最大100
|
|
387
|
+
*/
|
|
388
|
+
Limit?: number;
|
|
389
|
+
}
|
|
390
|
+
/**
|
|
391
|
+
* DescribeULHostInstance - 获取轻量应用云主机列表
|
|
392
|
+
*/
|
|
393
|
+
export interface DescribeULHostInstanceResponse {
|
|
394
|
+
/**
|
|
395
|
+
* 实例列表
|
|
396
|
+
*/
|
|
397
|
+
ULHostInstanceSets: {
|
|
398
|
+
/**
|
|
399
|
+
* 可用区。
|
|
400
|
+
*/
|
|
401
|
+
Zone?: string;
|
|
402
|
+
/**
|
|
403
|
+
* 实例Id。
|
|
404
|
+
*/
|
|
405
|
+
ULHostId?: string;
|
|
406
|
+
/**
|
|
407
|
+
* 实例名称。默认套餐Id
|
|
408
|
+
*/
|
|
409
|
+
Name?: string;
|
|
410
|
+
/**
|
|
411
|
+
* 业务组。
|
|
412
|
+
*/
|
|
413
|
+
Tag?: string;
|
|
414
|
+
/**
|
|
415
|
+
* 备注。
|
|
416
|
+
*/
|
|
417
|
+
Remark?: string;
|
|
418
|
+
/**
|
|
419
|
+
* 镜像Id。
|
|
420
|
+
*/
|
|
421
|
+
ImageId?: string;
|
|
422
|
+
/**
|
|
423
|
+
* 镜像名称。
|
|
424
|
+
*/
|
|
425
|
+
ImageName?: string;
|
|
426
|
+
/**
|
|
427
|
+
* 【数组】镜像包含的应用列表。
|
|
428
|
+
*/
|
|
429
|
+
Apps?: string[];
|
|
430
|
+
/**
|
|
431
|
+
* CPU核数。
|
|
432
|
+
*/
|
|
433
|
+
CPU?: number;
|
|
434
|
+
/**
|
|
435
|
+
* 内存。单位:MB
|
|
436
|
+
*/
|
|
437
|
+
Memory?: number;
|
|
438
|
+
/**
|
|
439
|
+
* 实例状态。枚举值:\\ >初始化: Initializing; \\ >启动中: Starting; \\> 运行中: Running; \\> 关机中: Stopping; \\ >关机: Stopped \\ >安装失败: Install Fail; \\ >重启中: Rebooting; \\ > 未知(空字符串,获取状态超时或出错):""
|
|
440
|
+
*/
|
|
441
|
+
State?: string;
|
|
442
|
+
/**
|
|
443
|
+
* 计费模式。枚举值:Month/Year
|
|
444
|
+
*/
|
|
445
|
+
ChargeType?: string;
|
|
446
|
+
/**
|
|
447
|
+
* IP信息
|
|
448
|
+
*/
|
|
449
|
+
IPSet?: {
|
|
450
|
+
/**
|
|
451
|
+
* IPv4/IPv6;
|
|
452
|
+
*/
|
|
453
|
+
IPMode: string;
|
|
454
|
+
/**
|
|
455
|
+
* 内网 Private 类型下,表示是否为默认网卡。true: 是默认网卡;其他值:不是。
|
|
456
|
+
*/
|
|
457
|
+
Default?: string;
|
|
458
|
+
/**
|
|
459
|
+
* 内网 Private 类型下,当前网卡的Mac。
|
|
460
|
+
*/
|
|
461
|
+
Mac?: string;
|
|
462
|
+
/**
|
|
463
|
+
* 当前EIP的权重。权重最大的为当前的出口IP。
|
|
464
|
+
*/
|
|
465
|
+
Weight?: number;
|
|
466
|
+
/**
|
|
467
|
+
* 国际: Internation,BGP: Bgp,内网: Private
|
|
468
|
+
*/
|
|
469
|
+
Type?: string;
|
|
470
|
+
/**
|
|
471
|
+
* 外网IP资源ID 。(内网IP无对应的资源ID)
|
|
472
|
+
*/
|
|
473
|
+
IPId?: string;
|
|
474
|
+
/**
|
|
475
|
+
* IP地址
|
|
476
|
+
*/
|
|
477
|
+
IP?: string;
|
|
478
|
+
/**
|
|
479
|
+
* IP对应的带宽, 单位: Mb (内网IP不显示带宽信息)
|
|
480
|
+
*/
|
|
481
|
+
Bandwidth?: number;
|
|
482
|
+
/**
|
|
483
|
+
* IP地址对应的VPC ID。(北京一不支持,字段返回为空)
|
|
484
|
+
*/
|
|
485
|
+
VPCId?: string;
|
|
486
|
+
/**
|
|
487
|
+
* IP地址对应的子网 ID。(北京一不支持,字段返回为空)
|
|
488
|
+
*/
|
|
489
|
+
SubnetId?: string;
|
|
490
|
+
/**
|
|
491
|
+
* 弹性网卡为默认网卡时,返回对应的 ID 值
|
|
492
|
+
*/
|
|
493
|
+
NetworkInterfaceId?: string;
|
|
494
|
+
}[];
|
|
495
|
+
/**
|
|
496
|
+
* 磁盘信息
|
|
497
|
+
*/
|
|
498
|
+
DiskSet?: {
|
|
499
|
+
/**
|
|
500
|
+
* 磁盘Id
|
|
501
|
+
*/
|
|
502
|
+
DiskId?: string;
|
|
503
|
+
/**
|
|
504
|
+
* 磁盘类型。如:"CLOUD_RSSD"、"CLOUD_SSD"
|
|
505
|
+
*/
|
|
506
|
+
DiskType?: string;
|
|
507
|
+
/**
|
|
508
|
+
* 磁盘类型。系统盘:"Boot";数据盘:"Data"
|
|
509
|
+
*/
|
|
510
|
+
Type?: string;
|
|
511
|
+
/**
|
|
512
|
+
* 磁盘大小。单位:GB
|
|
513
|
+
*/
|
|
514
|
+
Size?: number;
|
|
515
|
+
/**
|
|
516
|
+
* 是否为系统盘。是:"True";否:"False"
|
|
517
|
+
*/
|
|
518
|
+
IsBoot?: string;
|
|
519
|
+
/**
|
|
520
|
+
* 磁盘盘符。系统盘:"vda"
|
|
521
|
+
*/
|
|
522
|
+
Drive?: string;
|
|
523
|
+
}[];
|
|
524
|
+
/**
|
|
525
|
+
* 流量包详情信息
|
|
526
|
+
*/
|
|
527
|
+
EIPExclusiveUTPInfo?: {
|
|
528
|
+
/**
|
|
529
|
+
* 当前周期总流量
|
|
530
|
+
*/
|
|
531
|
+
TotalSize?: number;
|
|
532
|
+
/**
|
|
533
|
+
* 当前周期剩余流量
|
|
534
|
+
*/
|
|
535
|
+
AvailableSize?: number;
|
|
536
|
+
/**
|
|
537
|
+
* 当前周期已使用流量
|
|
538
|
+
*/
|
|
539
|
+
UsedSize?: number;
|
|
540
|
+
/**
|
|
541
|
+
* 当前周期超出限额的流量
|
|
542
|
+
*/
|
|
543
|
+
ExcessSize?: number;
|
|
544
|
+
/**
|
|
545
|
+
* 上次重置时间
|
|
546
|
+
*/
|
|
547
|
+
LastResetTime?: number;
|
|
548
|
+
/**
|
|
549
|
+
* 下次重置时间
|
|
550
|
+
*/
|
|
551
|
+
NextResetTime?: number;
|
|
552
|
+
/**
|
|
553
|
+
* 创建时间
|
|
554
|
+
*/
|
|
555
|
+
CreateTime?: number;
|
|
556
|
+
};
|
|
557
|
+
/**
|
|
558
|
+
* 是否自动续费。枚举值:Yes/No
|
|
559
|
+
*/
|
|
560
|
+
AutoRenew?: string;
|
|
561
|
+
/**
|
|
562
|
+
* 是否过期。枚举值:Yes/No
|
|
563
|
+
*/
|
|
564
|
+
IsExpire?: string;
|
|
565
|
+
/**
|
|
566
|
+
* 过期时间。Unix时间戳
|
|
567
|
+
*/
|
|
568
|
+
ExpireTime?: number;
|
|
569
|
+
/**
|
|
570
|
+
* 创建时间。Unix时间戳
|
|
571
|
+
*/
|
|
572
|
+
CreateTime?: number;
|
|
573
|
+
}[];
|
|
574
|
+
}
|
|
575
|
+
/**
|
|
576
|
+
* GetULHostInstancePrice - 获取轻量应用云主机套餐价格
|
|
577
|
+
*/
|
|
578
|
+
export interface GetULHostInstancePriceRequest {
|
|
579
|
+
/**
|
|
580
|
+
* 套餐ID
|
|
581
|
+
*/
|
|
582
|
+
BundleId: string;
|
|
583
|
+
/**
|
|
584
|
+
* 获取指定计费模式的价格。枚举值:\\ > Year,按年付费; \\ > Month。未指定时,返回所有计费模式价格
|
|
585
|
+
*/
|
|
586
|
+
ChargeType?: string;
|
|
587
|
+
/**
|
|
588
|
+
* 购买台数,范围[1,5]。默认:1
|
|
589
|
+
*/
|
|
590
|
+
Count?: number;
|
|
591
|
+
/**
|
|
592
|
+
* 购买时长。默认: 1。不支持购买到月末
|
|
593
|
+
*/
|
|
594
|
+
Quantity?: number;
|
|
595
|
+
}
|
|
596
|
+
/**
|
|
597
|
+
* GetULHostInstancePrice - 获取轻量应用云主机套餐价格
|
|
598
|
+
*/
|
|
599
|
+
export interface GetULHostInstancePriceResponse {
|
|
600
|
+
/**
|
|
601
|
+
* 价格
|
|
602
|
+
*/
|
|
603
|
+
PriceSet: {
|
|
604
|
+
/**
|
|
605
|
+
* 计费模式
|
|
606
|
+
*/
|
|
607
|
+
ChargeType?: string;
|
|
608
|
+
/**
|
|
609
|
+
* 价格
|
|
610
|
+
*/
|
|
611
|
+
Price?: number;
|
|
612
|
+
/**
|
|
613
|
+
* 原价
|
|
614
|
+
*/
|
|
615
|
+
OriginalPrice?: number;
|
|
616
|
+
}[];
|
|
617
|
+
}
|
|
618
|
+
/**
|
|
619
|
+
* GetULHostRenewPrice - 获取主机续费价格
|
|
620
|
+
*/
|
|
621
|
+
export interface GetULHostRenewPriceRequest {
|
|
622
|
+
/**
|
|
623
|
+
* ULHost实例ID
|
|
624
|
+
*/
|
|
625
|
+
ULHostId: string;
|
|
626
|
+
/**
|
|
627
|
+
* 计费类型。支持:Year/Month;默认:Month
|
|
628
|
+
*/
|
|
629
|
+
ChargeType?: string;
|
|
630
|
+
}
|
|
631
|
+
/**
|
|
632
|
+
* GetULHostRenewPrice - 获取主机续费价格
|
|
633
|
+
*/
|
|
634
|
+
export interface GetULHostRenewPriceResponse {
|
|
635
|
+
/**
|
|
636
|
+
* 价格
|
|
637
|
+
*/
|
|
638
|
+
PriceSet: {
|
|
639
|
+
/**
|
|
640
|
+
* 计费模式
|
|
641
|
+
*/
|
|
642
|
+
ChargeType?: string;
|
|
643
|
+
/**
|
|
644
|
+
* 价格
|
|
645
|
+
*/
|
|
646
|
+
Price?: number;
|
|
647
|
+
/**
|
|
648
|
+
* 原价
|
|
649
|
+
*/
|
|
650
|
+
OriginalPrice?: number;
|
|
651
|
+
}[];
|
|
652
|
+
}
|
|
653
|
+
/**
|
|
654
|
+
* ModifyULHostAttribute - 修改指定ULHost实例属性信息,包含名称和备注
|
|
655
|
+
*/
|
|
656
|
+
export interface ModifyULHostAttributeRequest {
|
|
657
|
+
/**
|
|
658
|
+
* ULHost实例Id
|
|
659
|
+
*/
|
|
660
|
+
ULHostId: string;
|
|
661
|
+
/**
|
|
662
|
+
* 名称。和Remark至少选择一个进行修改
|
|
663
|
+
*/
|
|
664
|
+
Name?: string;
|
|
665
|
+
/**
|
|
666
|
+
* 备注。和Name至少选择一个进行修改
|
|
667
|
+
*/
|
|
668
|
+
Remark?: string;
|
|
669
|
+
}
|
|
670
|
+
/**
|
|
671
|
+
* ModifyULHostAttribute - 修改指定ULHost实例属性信息,包含名称和备注
|
|
672
|
+
*/
|
|
673
|
+
export interface ModifyULHostAttributeResponse {
|
|
674
|
+
/**
|
|
675
|
+
* ULHost实例Id
|
|
676
|
+
*/
|
|
677
|
+
ULHostId: string;
|
|
678
|
+
}
|
|
679
|
+
/**
|
|
680
|
+
* PoweroffULHostInstance - 直接关闭UHost实例电源,无需等待实例正常关闭。
|
|
681
|
+
*/
|
|
682
|
+
export interface PoweroffULHostInstanceRequest {
|
|
683
|
+
/**
|
|
684
|
+
* ULHost实例ID
|
|
685
|
+
*/
|
|
686
|
+
ULHostId: string;
|
|
687
|
+
}
|
|
688
|
+
/**
|
|
689
|
+
* PoweroffULHostInstance - 直接关闭UHost实例电源,无需等待实例正常关闭。
|
|
690
|
+
*/
|
|
691
|
+
export interface PoweroffULHostInstanceResponse {
|
|
692
|
+
/**
|
|
693
|
+
* ULHost实例ID
|
|
694
|
+
*/
|
|
695
|
+
ULHostId: string;
|
|
696
|
+
}
|
|
697
|
+
/**
|
|
698
|
+
* RebootULHostInstance - 重新启动UHost实例。
|
|
699
|
+
*/
|
|
700
|
+
export interface RebootULHostInstanceRequest {
|
|
701
|
+
/**
|
|
702
|
+
* ULHost实例ID
|
|
703
|
+
*/
|
|
704
|
+
ULHostId: string;
|
|
705
|
+
}
|
|
706
|
+
/**
|
|
707
|
+
* RebootULHostInstance - 重新启动UHost实例。
|
|
708
|
+
*/
|
|
709
|
+
export interface RebootULHostInstanceResponse {
|
|
710
|
+
/**
|
|
711
|
+
* ULHost实例ID
|
|
712
|
+
*/
|
|
713
|
+
ULHostId?: string;
|
|
714
|
+
}
|
|
715
|
+
/**
|
|
716
|
+
* ReinstallULHostInstance - 重装轻量应用云主机
|
|
717
|
+
*/
|
|
718
|
+
export interface ReinstallULHostInstanceRequest {
|
|
719
|
+
/**
|
|
720
|
+
* 镜像Id。暂不支持使用自定义镜像重装
|
|
721
|
+
*/
|
|
722
|
+
ImageId: string;
|
|
723
|
+
/**
|
|
724
|
+
* 实例Id
|
|
725
|
+
*/
|
|
726
|
+
ULHostId: string;
|
|
727
|
+
/**
|
|
728
|
+
* 登陆密码。密码需使用base64进行编码,举例如下:# echo -n Password1 | base64 UGFzc3dvcmQx
|
|
729
|
+
*/
|
|
730
|
+
Password: string;
|
|
731
|
+
}
|
|
732
|
+
/**
|
|
733
|
+
* ReinstallULHostInstance - 重装轻量应用云主机
|
|
734
|
+
*/
|
|
735
|
+
export interface ReinstallULHostInstanceResponse {
|
|
736
|
+
/**
|
|
737
|
+
* 实例Id
|
|
738
|
+
*/
|
|
739
|
+
ULHostId: string;
|
|
740
|
+
}
|
|
741
|
+
/**
|
|
742
|
+
* ResetULHostInstancePassword - 重置轻量应用云主机管理员密码。
|
|
743
|
+
*/
|
|
744
|
+
export interface ResetULHostInstancePasswordRequest {
|
|
745
|
+
/**
|
|
746
|
+
* ULHost实例ID
|
|
747
|
+
*/
|
|
748
|
+
ULHostId: string;
|
|
749
|
+
/**
|
|
750
|
+
* ULHost新密码(密码格式使用BASE64编码)
|
|
751
|
+
*/
|
|
752
|
+
Password: string;
|
|
753
|
+
}
|
|
754
|
+
/**
|
|
755
|
+
* ResetULHostInstancePassword - 重置轻量应用云主机管理员密码。
|
|
756
|
+
*/
|
|
757
|
+
export interface ResetULHostInstancePasswordResponse {
|
|
758
|
+
/**
|
|
759
|
+
* ULHost实例ID
|
|
760
|
+
*/
|
|
761
|
+
ULHostId: string;
|
|
762
|
+
}
|
|
763
|
+
/**
|
|
764
|
+
* StartULHostInstance - 启动处于关闭状态的UHost实例。
|
|
765
|
+
*/
|
|
766
|
+
export interface StartULHostInstanceRequest {
|
|
767
|
+
/**
|
|
768
|
+
* ULHost实例ID
|
|
769
|
+
*/
|
|
770
|
+
ULHostId: string;
|
|
771
|
+
}
|
|
772
|
+
/**
|
|
773
|
+
* StartULHostInstance - 启动处于关闭状态的UHost实例。
|
|
774
|
+
*/
|
|
775
|
+
export interface StartULHostInstanceResponse {
|
|
776
|
+
/**
|
|
777
|
+
* ULHost实例ID
|
|
778
|
+
*/
|
|
779
|
+
ULHostId?: string;
|
|
780
|
+
}
|
|
781
|
+
/**
|
|
782
|
+
* StopULHostInstance - 指停止处于运行状态的ULHost实例
|
|
783
|
+
*/
|
|
784
|
+
export interface StopULHostInstanceRequest {
|
|
785
|
+
/**
|
|
786
|
+
* ULHost实例ID。
|
|
787
|
+
*/
|
|
788
|
+
ULHostId: string;
|
|
789
|
+
}
|
|
790
|
+
/**
|
|
791
|
+
* StopULHostInstance - 指停止处于运行状态的ULHost实例
|
|
792
|
+
*/
|
|
793
|
+
export interface StopULHostInstanceResponse {
|
|
794
|
+
/**
|
|
795
|
+
* ULHost实例ID
|
|
796
|
+
*/
|
|
797
|
+
ULHostId?: string;
|
|
798
|
+
}
|
|
799
|
+
/**
|
|
800
|
+
* TerminateULHostInstance - 删除指定数据中心的ULHost实例。
|
|
801
|
+
*/
|
|
802
|
+
export interface TerminateULHostInstanceRequest {
|
|
803
|
+
/**
|
|
804
|
+
* ULHost资源Id
|
|
805
|
+
*/
|
|
806
|
+
ULHostId: string;
|
|
807
|
+
/**
|
|
808
|
+
* 删除主机时是否同时删除挂载的数据盘。默认为false。
|
|
809
|
+
*/
|
|
810
|
+
ReleaseUDisk?: boolean;
|
|
811
|
+
}
|
|
812
|
+
/**
|
|
813
|
+
* TerminateULHostInstance - 删除指定数据中心的ULHost实例。
|
|
814
|
+
*/
|
|
815
|
+
export interface TerminateULHostInstanceResponse {
|
|
816
|
+
/**
|
|
817
|
+
* 用于判断主机删除时是否进入回收站。放入回收站:"Yes", 彻底删除:“No”。
|
|
818
|
+
*/
|
|
819
|
+
InRecycle: string;
|
|
820
|
+
/**
|
|
821
|
+
* ULHost 实例 Id
|
|
822
|
+
*/
|
|
823
|
+
ULHostId?: string;
|
|
824
|
+
}
|
|
@@ -0,0 +1,151 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
3
|
+
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
4
|
+
};
|
|
5
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
|
+
const client_1 = __importDefault(require("../../core/client"));
|
|
7
|
+
const request_1 = __importDefault(require("../../core/request"));
|
|
8
|
+
/**
|
|
9
|
+
* This client is used to call actions of **ulight_host** service
|
|
10
|
+
*/
|
|
11
|
+
class ULightHostClient extends client_1.default {
|
|
12
|
+
constructor({ config, credential, }) {
|
|
13
|
+
super({ config, credential });
|
|
14
|
+
}
|
|
15
|
+
/**
|
|
16
|
+
* CheckULHostResourceCapacity - 检查轻量应用云主机资源余量
|
|
17
|
+
*
|
|
18
|
+
* See also: https://docs.ucloud.cn/api/ulighthost-api/check_ul_host_resource_capacity
|
|
19
|
+
*/
|
|
20
|
+
checkULHostResourceCapacity(request) {
|
|
21
|
+
const args = Object.assign({ Action: 'CheckULHostResourceCapacity' }, (request || {}));
|
|
22
|
+
return this.invoke(new request_1.default(args)).then((resp) => resp.toObject());
|
|
23
|
+
}
|
|
24
|
+
/**
|
|
25
|
+
* CreateULHostInstance - 创建轻量应用云主机
|
|
26
|
+
*
|
|
27
|
+
* See also: https://docs.ucloud.cn/api/ulighthost-api/create_ul_host_instance
|
|
28
|
+
*/
|
|
29
|
+
createULHostInstance(request) {
|
|
30
|
+
const args = Object.assign({ Action: 'CreateULHostInstance' }, (request || {}));
|
|
31
|
+
return this.invoke(new request_1.default(args)).then((resp) => resp.toObject());
|
|
32
|
+
}
|
|
33
|
+
/**
|
|
34
|
+
* DescribeULHostBundles - 获取轻量应用云主机套餐列表
|
|
35
|
+
*
|
|
36
|
+
* See also: https://docs.ucloud.cn/api/ulighthost-api/describe_ul_host_bundles
|
|
37
|
+
*/
|
|
38
|
+
describeULHostBundles(request) {
|
|
39
|
+
const args = Object.assign({ Action: 'DescribeULHostBundles' }, (request || {}));
|
|
40
|
+
return this.invoke(new request_1.default(args)).then((resp) => resp.toObject());
|
|
41
|
+
}
|
|
42
|
+
/**
|
|
43
|
+
* DescribeULHostImage - 获取指定数据中心镜像列表
|
|
44
|
+
*
|
|
45
|
+
* See also: https://docs.ucloud.cn/api/ulighthost-api/describe_ul_host_image
|
|
46
|
+
*/
|
|
47
|
+
describeULHostImage(request) {
|
|
48
|
+
const args = Object.assign({ Action: 'DescribeULHostImage' }, (request || {}));
|
|
49
|
+
return this.invoke(new request_1.default(args)).then((resp) => resp.toObject());
|
|
50
|
+
}
|
|
51
|
+
/**
|
|
52
|
+
* DescribeULHostInstance - 获取轻量应用云主机列表
|
|
53
|
+
*
|
|
54
|
+
* See also: https://docs.ucloud.cn/api/ulighthost-api/describe_ul_host_instance
|
|
55
|
+
*/
|
|
56
|
+
describeULHostInstance(request) {
|
|
57
|
+
const args = Object.assign({ Action: 'DescribeULHostInstance' }, (request || {}));
|
|
58
|
+
return this.invoke(new request_1.default(args)).then((resp) => resp.toObject());
|
|
59
|
+
}
|
|
60
|
+
/**
|
|
61
|
+
* GetULHostInstancePrice - 获取轻量应用云主机套餐价格
|
|
62
|
+
*
|
|
63
|
+
* See also: https://docs.ucloud.cn/api/ulighthost-api/get_ul_host_instance_price
|
|
64
|
+
*/
|
|
65
|
+
getULHostInstancePrice(request) {
|
|
66
|
+
const args = Object.assign({ Action: 'GetULHostInstancePrice' }, (request || {}));
|
|
67
|
+
return this.invoke(new request_1.default(args)).then((resp) => resp.toObject());
|
|
68
|
+
}
|
|
69
|
+
/**
|
|
70
|
+
* GetULHostRenewPrice - 获取主机续费价格
|
|
71
|
+
*
|
|
72
|
+
* See also: https://docs.ucloud.cn/api/ulighthost-api/get_ul_host_renew_price
|
|
73
|
+
*/
|
|
74
|
+
getULHostRenewPrice(request) {
|
|
75
|
+
const args = Object.assign({ Action: 'GetULHostRenewPrice' }, (request || {}));
|
|
76
|
+
return this.invoke(new request_1.default(args)).then((resp) => resp.toObject());
|
|
77
|
+
}
|
|
78
|
+
/**
|
|
79
|
+
* ModifyULHostAttribute - 修改指定ULHost实例属性信息,包含名称和备注
|
|
80
|
+
*
|
|
81
|
+
* See also: https://docs.ucloud.cn/api/ulighthost-api/modify_ul_host_attribute
|
|
82
|
+
*/
|
|
83
|
+
modifyULHostAttribute(request) {
|
|
84
|
+
const args = Object.assign({ Action: 'ModifyULHostAttribute' }, (request || {}));
|
|
85
|
+
return this.invoke(new request_1.default(args)).then((resp) => resp.toObject());
|
|
86
|
+
}
|
|
87
|
+
/**
|
|
88
|
+
* PoweroffULHostInstance - 直接关闭UHost实例电源,无需等待实例正常关闭。
|
|
89
|
+
*
|
|
90
|
+
* See also: https://docs.ucloud.cn/api/ulighthost-api/poweroff_ul_host_instance
|
|
91
|
+
*/
|
|
92
|
+
poweroffULHostInstance(request) {
|
|
93
|
+
const args = Object.assign({ Action: 'PoweroffULHostInstance' }, (request || {}));
|
|
94
|
+
return this.invoke(new request_1.default(args)).then((resp) => resp.toObject());
|
|
95
|
+
}
|
|
96
|
+
/**
|
|
97
|
+
* RebootULHostInstance - 重新启动UHost实例。
|
|
98
|
+
*
|
|
99
|
+
* See also: https://docs.ucloud.cn/api/ulighthost-api/reboot_ul_host_instance
|
|
100
|
+
*/
|
|
101
|
+
rebootULHostInstance(request) {
|
|
102
|
+
const args = Object.assign({ Action: 'RebootULHostInstance' }, (request || {}));
|
|
103
|
+
return this.invoke(new request_1.default(args)).then((resp) => resp.toObject());
|
|
104
|
+
}
|
|
105
|
+
/**
|
|
106
|
+
* ReinstallULHostInstance - 重装轻量应用云主机
|
|
107
|
+
*
|
|
108
|
+
* See also: https://docs.ucloud.cn/api/ulighthost-api/reinstall_ul_host_instance
|
|
109
|
+
*/
|
|
110
|
+
reinstallULHostInstance(request) {
|
|
111
|
+
const args = Object.assign({ Action: 'ReinstallULHostInstance' }, (request || {}));
|
|
112
|
+
return this.invoke(new request_1.default(args)).then((resp) => resp.toObject());
|
|
113
|
+
}
|
|
114
|
+
/**
|
|
115
|
+
* ResetULHostInstancePassword - 重置轻量应用云主机管理员密码。
|
|
116
|
+
*
|
|
117
|
+
* See also: https://docs.ucloud.cn/api/ulighthost-api/reset_ul_host_instance_password
|
|
118
|
+
*/
|
|
119
|
+
resetULHostInstancePassword(request) {
|
|
120
|
+
const args = Object.assign({ Action: 'ResetULHostInstancePassword' }, (request || {}));
|
|
121
|
+
return this.invoke(new request_1.default(args)).then((resp) => resp.toObject());
|
|
122
|
+
}
|
|
123
|
+
/**
|
|
124
|
+
* StartULHostInstance - 启动处于关闭状态的UHost实例。
|
|
125
|
+
*
|
|
126
|
+
* See also: https://docs.ucloud.cn/api/ulighthost-api/start_ul_host_instance
|
|
127
|
+
*/
|
|
128
|
+
startULHostInstance(request) {
|
|
129
|
+
const args = Object.assign({ Action: 'StartULHostInstance' }, (request || {}));
|
|
130
|
+
return this.invoke(new request_1.default(args)).then((resp) => resp.toObject());
|
|
131
|
+
}
|
|
132
|
+
/**
|
|
133
|
+
* StopULHostInstance - 指停止处于运行状态的ULHost实例
|
|
134
|
+
*
|
|
135
|
+
* See also: https://docs.ucloud.cn/api/ulighthost-api/stop_ul_host_instance
|
|
136
|
+
*/
|
|
137
|
+
stopULHostInstance(request) {
|
|
138
|
+
const args = Object.assign({ Action: 'StopULHostInstance' }, (request || {}));
|
|
139
|
+
return this.invoke(new request_1.default(args)).then((resp) => resp.toObject());
|
|
140
|
+
}
|
|
141
|
+
/**
|
|
142
|
+
* TerminateULHostInstance - 删除指定数据中心的ULHost实例。
|
|
143
|
+
*
|
|
144
|
+
* See also: https://docs.ucloud.cn/api/ulighthost-api/terminate_ul_host_instance
|
|
145
|
+
*/
|
|
146
|
+
terminateULHostInstance(request) {
|
|
147
|
+
const args = Object.assign({ Action: 'TerminateULHostInstance' }, (request || {}));
|
|
148
|
+
return this.invoke(new request_1.default(args)).then((resp) => resp.toObject());
|
|
149
|
+
}
|
|
150
|
+
}
|
|
151
|
+
exports.default = ULightHostClient;
|