hostinger-api-mcp 0.0.3 → 0.0.5
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/.github/workflows/publish-release.yaml +53 -0
- package/README.md +98 -1
- package/build.js +55 -0
- package/package.json +2 -1
- package/server.js +1990 -1811
- package/server.ts +2100 -0
- package/tsconfig.json +14 -0
- package/types.d.ts +1131 -0
package/types.d.ts
ADDED
|
@@ -0,0 +1,1131 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Type definitions for the API endpoints
|
|
3
|
+
* Auto-generated from OpenAPI specification
|
|
4
|
+
*/
|
|
5
|
+
|
|
6
|
+
export interface APITools {
|
|
7
|
+
/**
|
|
8
|
+
* This endpoint retrieves a list of catalog items available for order.
|
|
9
|
+
|
|
10
|
+
Prices in catalog items is displayed as cents (without floating point), e.g: float `17.99` is displayed as integer `1799`.
|
|
11
|
+
*/
|
|
12
|
+
"undefined": {
|
|
13
|
+
params: {
|
|
14
|
+
|
|
15
|
+
};
|
|
16
|
+
response: any; // Response structure will depend on the API
|
|
17
|
+
};
|
|
18
|
+
|
|
19
|
+
/**
|
|
20
|
+
* This endpoint creates a new service order.
|
|
21
|
+
|
|
22
|
+
To place order, you need to provide payment method ID and list of price items from the catalog endpoint together with quantity.
|
|
23
|
+
Coupons also can be provided during order creation.
|
|
24
|
+
|
|
25
|
+
Orders created using this endpoint will be set for automatically renewal.
|
|
26
|
+
*/
|
|
27
|
+
"undefined": {
|
|
28
|
+
params: {
|
|
29
|
+
/**
|
|
30
|
+
* Payment method ID
|
|
31
|
+
*/
|
|
32
|
+
payment_method_id: number;
|
|
33
|
+
/**
|
|
34
|
+
* items property
|
|
35
|
+
*/
|
|
36
|
+
items: array;
|
|
37
|
+
/**
|
|
38
|
+
* coupons property
|
|
39
|
+
*/
|
|
40
|
+
coupons?: array;
|
|
41
|
+
};
|
|
42
|
+
response: any; // Response structure will depend on the API
|
|
43
|
+
};
|
|
44
|
+
|
|
45
|
+
/**
|
|
46
|
+
* This endpoint sets default payment method for your account.
|
|
47
|
+
*/
|
|
48
|
+
"undefined": {
|
|
49
|
+
params: {
|
|
50
|
+
/**
|
|
51
|
+
* Payment method ID
|
|
52
|
+
*/
|
|
53
|
+
paymentMethodId: number;
|
|
54
|
+
};
|
|
55
|
+
response: any; // Response structure will depend on the API
|
|
56
|
+
};
|
|
57
|
+
|
|
58
|
+
/**
|
|
59
|
+
* This endpoint deletes a payment method from your account.
|
|
60
|
+
*/
|
|
61
|
+
"undefined": {
|
|
62
|
+
params: {
|
|
63
|
+
/**
|
|
64
|
+
* Payment method ID
|
|
65
|
+
*/
|
|
66
|
+
paymentMethodId: number;
|
|
67
|
+
};
|
|
68
|
+
response: any; // Response structure will depend on the API
|
|
69
|
+
};
|
|
70
|
+
|
|
71
|
+
/**
|
|
72
|
+
* This endpoint retrieves a list of available payment methods that can be used for placing new orders.
|
|
73
|
+
|
|
74
|
+
If you want to add new payment method, please use [hPanel](https://hpanel.hostinger.com/billing/payment-methods).
|
|
75
|
+
*/
|
|
76
|
+
"undefined": {
|
|
77
|
+
params: {
|
|
78
|
+
|
|
79
|
+
};
|
|
80
|
+
response: any; // Response structure will depend on the API
|
|
81
|
+
};
|
|
82
|
+
|
|
83
|
+
/**
|
|
84
|
+
* This endpoint cancels a subscription and stops any further billing.
|
|
85
|
+
*/
|
|
86
|
+
"undefined": {
|
|
87
|
+
params: {
|
|
88
|
+
/**
|
|
89
|
+
* Subscription ID
|
|
90
|
+
*/
|
|
91
|
+
subscriptionId: string;
|
|
92
|
+
};
|
|
93
|
+
response: any; // Response structure will depend on the API
|
|
94
|
+
};
|
|
95
|
+
|
|
96
|
+
/**
|
|
97
|
+
* This endpoint retrieves a list of all subscriptions associated with your account.
|
|
98
|
+
*/
|
|
99
|
+
"undefined": {
|
|
100
|
+
params: {
|
|
101
|
+
|
|
102
|
+
};
|
|
103
|
+
response: any; // Response structure will depend on the API
|
|
104
|
+
};
|
|
105
|
+
|
|
106
|
+
/**
|
|
107
|
+
* This endpoint retrieves particular DNS snapshot with the contents of DNS zone records.
|
|
108
|
+
*/
|
|
109
|
+
"undefined": {
|
|
110
|
+
params: {
|
|
111
|
+
/**
|
|
112
|
+
* Domain name
|
|
113
|
+
*/
|
|
114
|
+
domain: string;
|
|
115
|
+
/**
|
|
116
|
+
* Snapshot ID
|
|
117
|
+
*/
|
|
118
|
+
snapshotId: number;
|
|
119
|
+
};
|
|
120
|
+
response: any; // Response structure will depend on the API
|
|
121
|
+
};
|
|
122
|
+
|
|
123
|
+
/**
|
|
124
|
+
* This endpoint restores DNS zone to the selected snapshot.
|
|
125
|
+
*/
|
|
126
|
+
"undefined": {
|
|
127
|
+
params: {
|
|
128
|
+
/**
|
|
129
|
+
* Domain name
|
|
130
|
+
*/
|
|
131
|
+
domain: string;
|
|
132
|
+
/**
|
|
133
|
+
* Snapshot ID
|
|
134
|
+
*/
|
|
135
|
+
snapshotId: number;
|
|
136
|
+
};
|
|
137
|
+
response: any; // Response structure will depend on the API
|
|
138
|
+
};
|
|
139
|
+
|
|
140
|
+
/**
|
|
141
|
+
* This endpoint retrieves list of DNS snapshots.
|
|
142
|
+
*/
|
|
143
|
+
"undefined": {
|
|
144
|
+
params: {
|
|
145
|
+
/**
|
|
146
|
+
* Domain name
|
|
147
|
+
*/
|
|
148
|
+
domain: string;
|
|
149
|
+
};
|
|
150
|
+
response: any; // Response structure will depend on the API
|
|
151
|
+
};
|
|
152
|
+
|
|
153
|
+
/**
|
|
154
|
+
* This endpoint retrieves DNS zone records for a specific domain.
|
|
155
|
+
*/
|
|
156
|
+
"undefined": {
|
|
157
|
+
params: {
|
|
158
|
+
/**
|
|
159
|
+
* Domain name
|
|
160
|
+
*/
|
|
161
|
+
domain: string;
|
|
162
|
+
};
|
|
163
|
+
response: any; // Response structure will depend on the API
|
|
164
|
+
};
|
|
165
|
+
|
|
166
|
+
/**
|
|
167
|
+
* This endpoint resets DNS zone to the default records.
|
|
168
|
+
*/
|
|
169
|
+
"undefined": {
|
|
170
|
+
params: {
|
|
171
|
+
/**
|
|
172
|
+
* Domain name
|
|
173
|
+
*/
|
|
174
|
+
domain: string;
|
|
175
|
+
/**
|
|
176
|
+
* Determines if operation should be run synchronously
|
|
177
|
+
*/
|
|
178
|
+
sync?: boolean;
|
|
179
|
+
/**
|
|
180
|
+
* Determines if email records should be reset
|
|
181
|
+
*/
|
|
182
|
+
reset_email_records?: boolean;
|
|
183
|
+
/**
|
|
184
|
+
* Specifies which record types to not reset
|
|
185
|
+
*/
|
|
186
|
+
whitelisted_record_types?: array;
|
|
187
|
+
};
|
|
188
|
+
response: any; // Response structure will depend on the API
|
|
189
|
+
};
|
|
190
|
+
|
|
191
|
+
/**
|
|
192
|
+
* This endpoint retrieves a list of all domains associated with your account.
|
|
193
|
+
*/
|
|
194
|
+
"undefined": {
|
|
195
|
+
params: {
|
|
196
|
+
|
|
197
|
+
};
|
|
198
|
+
response: any; // Response structure will depend on the API
|
|
199
|
+
};
|
|
200
|
+
|
|
201
|
+
/**
|
|
202
|
+
* This endpoint retrieves a list of all data centers available.
|
|
203
|
+
*/
|
|
204
|
+
"undefined": {
|
|
205
|
+
params: {
|
|
206
|
+
|
|
207
|
+
};
|
|
208
|
+
response: any; // Response structure will depend on the API
|
|
209
|
+
};
|
|
210
|
+
|
|
211
|
+
/**
|
|
212
|
+
* This endpoint activates a firewall for a specified virtual machine.
|
|
213
|
+
|
|
214
|
+
Only one firewall can be active for a virtual machine at a time.
|
|
215
|
+
*/
|
|
216
|
+
"undefined": {
|
|
217
|
+
params: {
|
|
218
|
+
/**
|
|
219
|
+
* Firewall ID
|
|
220
|
+
*/
|
|
221
|
+
firewallId: number;
|
|
222
|
+
/**
|
|
223
|
+
* Virtual Machine ID
|
|
224
|
+
*/
|
|
225
|
+
virtualMachineId: number;
|
|
226
|
+
};
|
|
227
|
+
response: any; // Response structure will depend on the API
|
|
228
|
+
};
|
|
229
|
+
|
|
230
|
+
/**
|
|
231
|
+
* This endpoint deactivates a firewall for a specified virtual machine.
|
|
232
|
+
*/
|
|
233
|
+
"undefined": {
|
|
234
|
+
params: {
|
|
235
|
+
/**
|
|
236
|
+
* Firewall ID
|
|
237
|
+
*/
|
|
238
|
+
firewallId: number;
|
|
239
|
+
/**
|
|
240
|
+
* Virtual Machine ID
|
|
241
|
+
*/
|
|
242
|
+
virtualMachineId: number;
|
|
243
|
+
};
|
|
244
|
+
response: any; // Response structure will depend on the API
|
|
245
|
+
};
|
|
246
|
+
|
|
247
|
+
/**
|
|
248
|
+
* This endpoint retrieves firewall by its ID and rules associated with it.
|
|
249
|
+
*/
|
|
250
|
+
"undefined": {
|
|
251
|
+
params: {
|
|
252
|
+
/**
|
|
253
|
+
* Firewall ID
|
|
254
|
+
*/
|
|
255
|
+
firewallId: number;
|
|
256
|
+
};
|
|
257
|
+
response: any; // Response structure will depend on the API
|
|
258
|
+
};
|
|
259
|
+
|
|
260
|
+
/**
|
|
261
|
+
* This endpoint deletes a specified firewall.
|
|
262
|
+
|
|
263
|
+
Any virtual machine that has this firewall activated will automatically have it deactivated.
|
|
264
|
+
*/
|
|
265
|
+
"undefined": {
|
|
266
|
+
params: {
|
|
267
|
+
/**
|
|
268
|
+
* Firewall ID
|
|
269
|
+
*/
|
|
270
|
+
firewallId: number;
|
|
271
|
+
};
|
|
272
|
+
response: any; // Response structure will depend on the API
|
|
273
|
+
};
|
|
274
|
+
|
|
275
|
+
/**
|
|
276
|
+
* This endpoint retrieves a list of all firewalls available.
|
|
277
|
+
*/
|
|
278
|
+
"undefined": {
|
|
279
|
+
params: {
|
|
280
|
+
/**
|
|
281
|
+
* Page number
|
|
282
|
+
*/
|
|
283
|
+
page?: number;
|
|
284
|
+
};
|
|
285
|
+
response: any; // Response structure will depend on the API
|
|
286
|
+
};
|
|
287
|
+
|
|
288
|
+
/**
|
|
289
|
+
* This endpoint creates a new firewall.
|
|
290
|
+
*/
|
|
291
|
+
"undefined": {
|
|
292
|
+
params: {
|
|
293
|
+
/**
|
|
294
|
+
* name property
|
|
295
|
+
*/
|
|
296
|
+
name: string;
|
|
297
|
+
};
|
|
298
|
+
response: any; // Response structure will depend on the API
|
|
299
|
+
};
|
|
300
|
+
|
|
301
|
+
/**
|
|
302
|
+
* This endpoint updates a specific firewall rule from a specified firewall.
|
|
303
|
+
|
|
304
|
+
Any virtual machine that has this firewall activated will loose sync with the firewall and will have to be synced again manually.
|
|
305
|
+
*/
|
|
306
|
+
"undefined": {
|
|
307
|
+
params: {
|
|
308
|
+
/**
|
|
309
|
+
* Firewall ID
|
|
310
|
+
*/
|
|
311
|
+
firewallId: number;
|
|
312
|
+
/**
|
|
313
|
+
* Firewall Rule ID
|
|
314
|
+
*/
|
|
315
|
+
ruleId: number;
|
|
316
|
+
/**
|
|
317
|
+
* protocol property
|
|
318
|
+
*/
|
|
319
|
+
protocol: string;
|
|
320
|
+
/**
|
|
321
|
+
* Port or port range, ex: 1024:2048
|
|
322
|
+
*/
|
|
323
|
+
port: string;
|
|
324
|
+
/**
|
|
325
|
+
* source property
|
|
326
|
+
*/
|
|
327
|
+
source: string;
|
|
328
|
+
/**
|
|
329
|
+
* IP range, CIDR, single IP or `any`
|
|
330
|
+
*/
|
|
331
|
+
source_detail: string;
|
|
332
|
+
};
|
|
333
|
+
response: any; // Response structure will depend on the API
|
|
334
|
+
};
|
|
335
|
+
|
|
336
|
+
/**
|
|
337
|
+
* This endpoint deletes a specific firewall rule from a specified firewall.
|
|
338
|
+
|
|
339
|
+
Any virtual machine that has this firewall activated will loose sync with the firewall and will have to be synced again manually.
|
|
340
|
+
*/
|
|
341
|
+
"undefined": {
|
|
342
|
+
params: {
|
|
343
|
+
/**
|
|
344
|
+
* Firewall ID
|
|
345
|
+
*/
|
|
346
|
+
firewallId: number;
|
|
347
|
+
/**
|
|
348
|
+
* Firewall Rule ID
|
|
349
|
+
*/
|
|
350
|
+
ruleId: number;
|
|
351
|
+
};
|
|
352
|
+
response: any; // Response structure will depend on the API
|
|
353
|
+
};
|
|
354
|
+
|
|
355
|
+
/**
|
|
356
|
+
* This endpoint creates new firewall rule from a specified firewall.
|
|
357
|
+
By default, the firewall drops all incoming traffic, which means you must add accept rules for all ports you want to use.
|
|
358
|
+
|
|
359
|
+
Any virtual machine that has this firewall activated will loose sync with the firewall and will have to be synced again manually.
|
|
360
|
+
*/
|
|
361
|
+
"undefined": {
|
|
362
|
+
params: {
|
|
363
|
+
/**
|
|
364
|
+
* Firewall ID
|
|
365
|
+
*/
|
|
366
|
+
firewallId: number;
|
|
367
|
+
/**
|
|
368
|
+
* protocol property
|
|
369
|
+
*/
|
|
370
|
+
protocol: string;
|
|
371
|
+
/**
|
|
372
|
+
* Port or port range, ex: 1024:2048
|
|
373
|
+
*/
|
|
374
|
+
port: string;
|
|
375
|
+
/**
|
|
376
|
+
* source property
|
|
377
|
+
*/
|
|
378
|
+
source: string;
|
|
379
|
+
/**
|
|
380
|
+
* IP range, CIDR, single IP or `any`
|
|
381
|
+
*/
|
|
382
|
+
source_detail: string;
|
|
383
|
+
};
|
|
384
|
+
response: any; // Response structure will depend on the API
|
|
385
|
+
};
|
|
386
|
+
|
|
387
|
+
/**
|
|
388
|
+
* This endpoint syncs a firewall for a specified virtual machine.
|
|
389
|
+
|
|
390
|
+
Firewall can loose sync with virtual machine if the firewall has new rules added, removed or updated.
|
|
391
|
+
*/
|
|
392
|
+
"undefined": {
|
|
393
|
+
params: {
|
|
394
|
+
/**
|
|
395
|
+
* Firewall ID
|
|
396
|
+
*/
|
|
397
|
+
firewallId: number;
|
|
398
|
+
/**
|
|
399
|
+
* Virtual Machine ID
|
|
400
|
+
*/
|
|
401
|
+
virtualMachineId: number;
|
|
402
|
+
};
|
|
403
|
+
response: any; // Response structure will depend on the API
|
|
404
|
+
};
|
|
405
|
+
|
|
406
|
+
/**
|
|
407
|
+
* This endpoint retrieves post-install script by its ID.
|
|
408
|
+
*/
|
|
409
|
+
"undefined": {
|
|
410
|
+
params: {
|
|
411
|
+
/**
|
|
412
|
+
* Post-install script ID
|
|
413
|
+
*/
|
|
414
|
+
postInstallScriptId: number;
|
|
415
|
+
};
|
|
416
|
+
response: any; // Response structure will depend on the API
|
|
417
|
+
};
|
|
418
|
+
|
|
419
|
+
/**
|
|
420
|
+
* This endpoint updates a specific post-install script.
|
|
421
|
+
*/
|
|
422
|
+
"undefined": {
|
|
423
|
+
params: {
|
|
424
|
+
/**
|
|
425
|
+
* Post-install script ID
|
|
426
|
+
*/
|
|
427
|
+
postInstallScriptId: number;
|
|
428
|
+
/**
|
|
429
|
+
* Name of the script
|
|
430
|
+
*/
|
|
431
|
+
name: string;
|
|
432
|
+
/**
|
|
433
|
+
* Content of the script
|
|
434
|
+
*/
|
|
435
|
+
content: string;
|
|
436
|
+
};
|
|
437
|
+
response: any; // Response structure will depend on the API
|
|
438
|
+
};
|
|
439
|
+
|
|
440
|
+
/**
|
|
441
|
+
* This endpoint deletes a post-install script from your account.
|
|
442
|
+
*/
|
|
443
|
+
"undefined": {
|
|
444
|
+
params: {
|
|
445
|
+
/**
|
|
446
|
+
* Post-install script ID
|
|
447
|
+
*/
|
|
448
|
+
postInstallScriptId: number;
|
|
449
|
+
};
|
|
450
|
+
response: any; // Response structure will depend on the API
|
|
451
|
+
};
|
|
452
|
+
|
|
453
|
+
/**
|
|
454
|
+
* This endpoint retrieves a list of post-install scripts associated with your account.
|
|
455
|
+
*/
|
|
456
|
+
"undefined": {
|
|
457
|
+
params: {
|
|
458
|
+
/**
|
|
459
|
+
* Page number
|
|
460
|
+
*/
|
|
461
|
+
page?: number;
|
|
462
|
+
};
|
|
463
|
+
response: any; // Response structure will depend on the API
|
|
464
|
+
};
|
|
465
|
+
|
|
466
|
+
/**
|
|
467
|
+
* This endpoint allows you to add a new post-install script to your account,
|
|
468
|
+
which can then be used run after the installation of a virtual machine instance.
|
|
469
|
+
|
|
470
|
+
The script contents will be saved to the file `/post_install` with executable attribute set and will be executed once virtual machine is installed.
|
|
471
|
+
The output of the script will be redirected to `/post_install.log`. Maximum script size is 48KB.
|
|
472
|
+
*/
|
|
473
|
+
"undefined": {
|
|
474
|
+
params: {
|
|
475
|
+
/**
|
|
476
|
+
* Name of the script
|
|
477
|
+
*/
|
|
478
|
+
name: string;
|
|
479
|
+
/**
|
|
480
|
+
* Content of the script
|
|
481
|
+
*/
|
|
482
|
+
content: string;
|
|
483
|
+
};
|
|
484
|
+
response: any; // Response structure will depend on the API
|
|
485
|
+
};
|
|
486
|
+
|
|
487
|
+
/**
|
|
488
|
+
* This endpoint attaches an existing public keys from your account to a specified virtual machine.
|
|
489
|
+
|
|
490
|
+
Multiple keys can be attached to a single virtual machine.
|
|
491
|
+
*/
|
|
492
|
+
"undefined": {
|
|
493
|
+
params: {
|
|
494
|
+
/**
|
|
495
|
+
* Virtual Machine ID
|
|
496
|
+
*/
|
|
497
|
+
virtualMachineId: number;
|
|
498
|
+
/**
|
|
499
|
+
* Public Key IDs to attach
|
|
500
|
+
*/
|
|
501
|
+
ids: array;
|
|
502
|
+
};
|
|
503
|
+
response: any; // Response structure will depend on the API
|
|
504
|
+
};
|
|
505
|
+
|
|
506
|
+
/**
|
|
507
|
+
* This endpoint deletes a public key from your account.
|
|
508
|
+
|
|
509
|
+
**Deleting public key from account does not remove it from virtual machine**
|
|
510
|
+
*/
|
|
511
|
+
"undefined": {
|
|
512
|
+
params: {
|
|
513
|
+
/**
|
|
514
|
+
* Public Key ID
|
|
515
|
+
*/
|
|
516
|
+
publicKeyId: number;
|
|
517
|
+
};
|
|
518
|
+
response: any; // Response structure will depend on the API
|
|
519
|
+
};
|
|
520
|
+
|
|
521
|
+
/**
|
|
522
|
+
* This endpoint retrieves a list of public keys associated with your account.
|
|
523
|
+
*/
|
|
524
|
+
"undefined": {
|
|
525
|
+
params: {
|
|
526
|
+
/**
|
|
527
|
+
* Page number
|
|
528
|
+
*/
|
|
529
|
+
page?: number;
|
|
530
|
+
};
|
|
531
|
+
response: any; // Response structure will depend on the API
|
|
532
|
+
};
|
|
533
|
+
|
|
534
|
+
/**
|
|
535
|
+
* This endpoint allows you to add a new public key to your account,
|
|
536
|
+
which can then be attached to virtual machine instances for secure access.
|
|
537
|
+
*/
|
|
538
|
+
"undefined": {
|
|
539
|
+
params: {
|
|
540
|
+
/**
|
|
541
|
+
* name property
|
|
542
|
+
*/
|
|
543
|
+
name: string;
|
|
544
|
+
/**
|
|
545
|
+
* key property
|
|
546
|
+
*/
|
|
547
|
+
key: string;
|
|
548
|
+
};
|
|
549
|
+
response: any; // Response structure will depend on the API
|
|
550
|
+
};
|
|
551
|
+
|
|
552
|
+
/**
|
|
553
|
+
* This endpoint retrieves details of a specific OS template for virtual machines.
|
|
554
|
+
*/
|
|
555
|
+
"undefined": {
|
|
556
|
+
params: {
|
|
557
|
+
/**
|
|
558
|
+
* Template ID
|
|
559
|
+
*/
|
|
560
|
+
templateId: number;
|
|
561
|
+
};
|
|
562
|
+
response: any; // Response structure will depend on the API
|
|
563
|
+
};
|
|
564
|
+
|
|
565
|
+
/**
|
|
566
|
+
* This endpoint retrieves a list of available OS templates for virtual machines.
|
|
567
|
+
*/
|
|
568
|
+
"undefined": {
|
|
569
|
+
params: {
|
|
570
|
+
|
|
571
|
+
};
|
|
572
|
+
response: any; // Response structure will depend on the API
|
|
573
|
+
};
|
|
574
|
+
|
|
575
|
+
/**
|
|
576
|
+
* This endpoint retrieves details of a specific action performed on a specified virtual machine.
|
|
577
|
+
|
|
578
|
+
This endpoint allows you to view detailed information about a particular action, including the action name, timestamp, and status.
|
|
579
|
+
*/
|
|
580
|
+
"undefined": {
|
|
581
|
+
params: {
|
|
582
|
+
/**
|
|
583
|
+
* Virtual Machine ID
|
|
584
|
+
*/
|
|
585
|
+
virtualMachineId: number;
|
|
586
|
+
/**
|
|
587
|
+
* Action ID
|
|
588
|
+
*/
|
|
589
|
+
actionId: number;
|
|
590
|
+
};
|
|
591
|
+
response: any; // Response structure will depend on the API
|
|
592
|
+
};
|
|
593
|
+
|
|
594
|
+
/**
|
|
595
|
+
* This endpoint retrieves a list of actions performed on a specified virtual machine.
|
|
596
|
+
|
|
597
|
+
Actions are operations or events that have been executed on the virtual machine, such as starting, stopping, or modifying
|
|
598
|
+
the machine. This endpoint allows you to view the history of these actions, providing details about each action,
|
|
599
|
+
such as the action name, timestamp, and status.
|
|
600
|
+
*/
|
|
601
|
+
"undefined": {
|
|
602
|
+
params: {
|
|
603
|
+
/**
|
|
604
|
+
* Virtual Machine ID
|
|
605
|
+
*/
|
|
606
|
+
virtualMachineId: number;
|
|
607
|
+
/**
|
|
608
|
+
* Page number
|
|
609
|
+
*/
|
|
610
|
+
page?: number;
|
|
611
|
+
};
|
|
612
|
+
response: any; // Response structure will depend on the API
|
|
613
|
+
};
|
|
614
|
+
|
|
615
|
+
/**
|
|
616
|
+
* This endpoint retrieves a list of public keys attached to a specified virtual machine.
|
|
617
|
+
*/
|
|
618
|
+
"undefined": {
|
|
619
|
+
params: {
|
|
620
|
+
/**
|
|
621
|
+
* Virtual Machine ID
|
|
622
|
+
*/
|
|
623
|
+
virtualMachineId: number;
|
|
624
|
+
/**
|
|
625
|
+
* Page number
|
|
626
|
+
*/
|
|
627
|
+
page?: number;
|
|
628
|
+
};
|
|
629
|
+
response: any; // Response structure will depend on the API
|
|
630
|
+
};
|
|
631
|
+
|
|
632
|
+
/**
|
|
633
|
+
* This endpoint deletes a specified backup for a virtual machine.
|
|
634
|
+
*/
|
|
635
|
+
"undefined": {
|
|
636
|
+
params: {
|
|
637
|
+
/**
|
|
638
|
+
* Virtual Machine ID
|
|
639
|
+
*/
|
|
640
|
+
virtualMachineId: number;
|
|
641
|
+
/**
|
|
642
|
+
* Backup ID
|
|
643
|
+
*/
|
|
644
|
+
backupId: number;
|
|
645
|
+
};
|
|
646
|
+
response: any; // Response structure will depend on the API
|
|
647
|
+
};
|
|
648
|
+
|
|
649
|
+
/**
|
|
650
|
+
* This endpoint retrieves a list of backups for a specified virtual machine.
|
|
651
|
+
*/
|
|
652
|
+
"undefined": {
|
|
653
|
+
params: {
|
|
654
|
+
/**
|
|
655
|
+
* Page number
|
|
656
|
+
*/
|
|
657
|
+
page?: number;
|
|
658
|
+
/**
|
|
659
|
+
* Virtual Machine ID
|
|
660
|
+
*/
|
|
661
|
+
virtualMachineId: number;
|
|
662
|
+
};
|
|
663
|
+
response: any; // Response structure will depend on the API
|
|
664
|
+
};
|
|
665
|
+
|
|
666
|
+
/**
|
|
667
|
+
* This endpoint restores a backup for a specified virtual machine.
|
|
668
|
+
|
|
669
|
+
The system will then initiate the restore process, which may take some time depending on the size of the backup.
|
|
670
|
+
|
|
671
|
+
**All data on the virtual machine will be overwritten with the data from the backup.**
|
|
672
|
+
*/
|
|
673
|
+
"undefined": {
|
|
674
|
+
params: {
|
|
675
|
+
/**
|
|
676
|
+
* Virtual Machine ID
|
|
677
|
+
*/
|
|
678
|
+
virtualMachineId: number;
|
|
679
|
+
/**
|
|
680
|
+
* Backup ID
|
|
681
|
+
*/
|
|
682
|
+
backupId: number;
|
|
683
|
+
};
|
|
684
|
+
response: any; // Response structure will depend on the API
|
|
685
|
+
};
|
|
686
|
+
|
|
687
|
+
/**
|
|
688
|
+
* This endpoint sets the hostname for a specified virtual machine.
|
|
689
|
+
Changing hostname does not update PTR record automatically.
|
|
690
|
+
If you want your virtual machine to be reachable by a hostname,
|
|
691
|
+
you need to point your domain A/AAAA records to virtual machine IP as well.
|
|
692
|
+
*/
|
|
693
|
+
"undefined": {
|
|
694
|
+
params: {
|
|
695
|
+
/**
|
|
696
|
+
* Virtual Machine ID
|
|
697
|
+
*/
|
|
698
|
+
virtualMachineId: number;
|
|
699
|
+
/**
|
|
700
|
+
* hostname property
|
|
701
|
+
*/
|
|
702
|
+
hostname: string;
|
|
703
|
+
};
|
|
704
|
+
response: any; // Response structure will depend on the API
|
|
705
|
+
};
|
|
706
|
+
|
|
707
|
+
/**
|
|
708
|
+
* This endpoint resets the hostname and PTR record of a specified virtual machine to the default value.
|
|
709
|
+
*/
|
|
710
|
+
"undefined": {
|
|
711
|
+
params: {
|
|
712
|
+
/**
|
|
713
|
+
* Virtual Machine ID
|
|
714
|
+
*/
|
|
715
|
+
virtualMachineId: number;
|
|
716
|
+
};
|
|
717
|
+
response: any; // Response structure will depend on the API
|
|
718
|
+
};
|
|
719
|
+
|
|
720
|
+
/**
|
|
721
|
+
* This endpoint retrieves detailed information about a specified virtual machine.
|
|
722
|
+
*/
|
|
723
|
+
"undefined": {
|
|
724
|
+
params: {
|
|
725
|
+
/**
|
|
726
|
+
* Virtual Machine ID
|
|
727
|
+
*/
|
|
728
|
+
virtualMachineId: number;
|
|
729
|
+
};
|
|
730
|
+
response: any; // Response structure will depend on the API
|
|
731
|
+
};
|
|
732
|
+
|
|
733
|
+
/**
|
|
734
|
+
* This endpoint retrieves a list of all available virtual machines.
|
|
735
|
+
*/
|
|
736
|
+
"undefined": {
|
|
737
|
+
params: {
|
|
738
|
+
|
|
739
|
+
};
|
|
740
|
+
response: any; // Response structure will depend on the API
|
|
741
|
+
};
|
|
742
|
+
|
|
743
|
+
/**
|
|
744
|
+
* This endpoint retrieves the scan metrics for the [Monarx](https://www.monarx.com/) malware scanner installed on a specified virtual machine.
|
|
745
|
+
The scan metrics provide detailed information about the malware scans performed by Monarx, including the number of scans,
|
|
746
|
+
detected threats, and other relevant statistics. This information is useful for monitoring the security status of the
|
|
747
|
+
virtual machine and assessing the effectiveness of the malware scanner.
|
|
748
|
+
*/
|
|
749
|
+
"undefined": {
|
|
750
|
+
params: {
|
|
751
|
+
/**
|
|
752
|
+
* Virtual Machine ID
|
|
753
|
+
*/
|
|
754
|
+
virtualMachineId: number;
|
|
755
|
+
};
|
|
756
|
+
response: any; // Response structure will depend on the API
|
|
757
|
+
};
|
|
758
|
+
|
|
759
|
+
/**
|
|
760
|
+
* This endpoint installs the Monarx malware scanner on a specified virtual machine.
|
|
761
|
+
|
|
762
|
+
[Monarx](https://www.monarx.com/) is a security tool designed to detect and prevent malware infections on virtual machines.
|
|
763
|
+
By installing Monarx, users can enhance the security of their virtual machines, ensuring that they are protected against malicious software.
|
|
764
|
+
*/
|
|
765
|
+
"undefined": {
|
|
766
|
+
params: {
|
|
767
|
+
/**
|
|
768
|
+
* Virtual Machine ID
|
|
769
|
+
*/
|
|
770
|
+
virtualMachineId: number;
|
|
771
|
+
};
|
|
772
|
+
response: any; // Response structure will depend on the API
|
|
773
|
+
};
|
|
774
|
+
|
|
775
|
+
/**
|
|
776
|
+
* This endpoint uninstalls the Monarx malware scanner on a specified virtual machine.
|
|
777
|
+
If Monarx is not installed, the request will still be processed without any effect.
|
|
778
|
+
*/
|
|
779
|
+
"undefined": {
|
|
780
|
+
params: {
|
|
781
|
+
/**
|
|
782
|
+
* Virtual Machine ID
|
|
783
|
+
*/
|
|
784
|
+
virtualMachineId: number;
|
|
785
|
+
};
|
|
786
|
+
response: any; // Response structure will depend on the API
|
|
787
|
+
};
|
|
788
|
+
|
|
789
|
+
/**
|
|
790
|
+
* This endpoint retrieves the historical metrics for a specified virtual machine.
|
|
791
|
+
It includes the following metrics:
|
|
792
|
+
- CPU usage
|
|
793
|
+
- Memory usage
|
|
794
|
+
- Disk usage
|
|
795
|
+
- Network usage
|
|
796
|
+
- Uptime
|
|
797
|
+
*/
|
|
798
|
+
"undefined": {
|
|
799
|
+
params: {
|
|
800
|
+
/**
|
|
801
|
+
* Virtual Machine ID
|
|
802
|
+
*/
|
|
803
|
+
virtualMachineId: number;
|
|
804
|
+
/**
|
|
805
|
+
* the date-time notation as defined by RFC 3339, section 5.6
|
|
806
|
+
*/
|
|
807
|
+
date_from: string;
|
|
808
|
+
/**
|
|
809
|
+
* the date-time notation as defined by RFC 3339, section 5.6
|
|
810
|
+
*/
|
|
811
|
+
date_to: string;
|
|
812
|
+
};
|
|
813
|
+
response: any; // Response structure will depend on the API
|
|
814
|
+
};
|
|
815
|
+
|
|
816
|
+
/**
|
|
817
|
+
* This endpoint sets the nameservers for a specified virtual machine.
|
|
818
|
+
Be aware, that improper nameserver configuration can lead to the virtual machine being unable to resolve domain names.
|
|
819
|
+
*/
|
|
820
|
+
"undefined": {
|
|
821
|
+
params: {
|
|
822
|
+
/**
|
|
823
|
+
* Virtual Machine ID
|
|
824
|
+
*/
|
|
825
|
+
virtualMachineId: number;
|
|
826
|
+
/**
|
|
827
|
+
* ns1 property
|
|
828
|
+
*/
|
|
829
|
+
ns1: string;
|
|
830
|
+
/**
|
|
831
|
+
* ns2 property
|
|
832
|
+
*/
|
|
833
|
+
ns2?: string;
|
|
834
|
+
};
|
|
835
|
+
response: any; // Response structure will depend on the API
|
|
836
|
+
};
|
|
837
|
+
|
|
838
|
+
/**
|
|
839
|
+
* This endpoint creates or updates a PTR (Pointer) record for a specified virtual machine.
|
|
840
|
+
*/
|
|
841
|
+
"undefined": {
|
|
842
|
+
params: {
|
|
843
|
+
/**
|
|
844
|
+
* Virtual Machine ID
|
|
845
|
+
*/
|
|
846
|
+
virtualMachineId: number;
|
|
847
|
+
};
|
|
848
|
+
response: any; // Response structure will depend on the API
|
|
849
|
+
};
|
|
850
|
+
|
|
851
|
+
/**
|
|
852
|
+
* This endpoint deletes a PTR (Pointer) record for a specified virtual machine.
|
|
853
|
+
|
|
854
|
+
Once deleted, reverse DNS lookups to the virtual machine's IP address will no longer return the previously configured hostname.
|
|
855
|
+
*/
|
|
856
|
+
"undefined": {
|
|
857
|
+
params: {
|
|
858
|
+
/**
|
|
859
|
+
* Virtual Machine ID
|
|
860
|
+
*/
|
|
861
|
+
virtualMachineId: number;
|
|
862
|
+
};
|
|
863
|
+
response: any; // Response structure will depend on the API
|
|
864
|
+
};
|
|
865
|
+
|
|
866
|
+
/**
|
|
867
|
+
* This endpoint sets the panel password for a specified virtual machine.
|
|
868
|
+
If virtual machine does not use panel OS, the request will still be processed without any effect.
|
|
869
|
+
Requirements for the password is the same as in the [recreate virtual machine endpoint](/#tag/vps-virtual-machine/POST/api/vps/v1/virtual-machines/{virtualMachineId}/recreate).
|
|
870
|
+
*/
|
|
871
|
+
"undefined": {
|
|
872
|
+
params: {
|
|
873
|
+
/**
|
|
874
|
+
* Virtual Machine ID
|
|
875
|
+
*/
|
|
876
|
+
virtualMachineId: number;
|
|
877
|
+
/**
|
|
878
|
+
* Panel password for the virtual machine
|
|
879
|
+
*/
|
|
880
|
+
password: string;
|
|
881
|
+
};
|
|
882
|
+
response: any; // Response structure will depend on the API
|
|
883
|
+
};
|
|
884
|
+
|
|
885
|
+
/**
|
|
886
|
+
* This endpoint initiates the recovery mode for a specified virtual machine.
|
|
887
|
+
Recovery mode is a special state that allows users to perform system rescue operations,
|
|
888
|
+
such as repairing file systems, recovering data, or troubleshooting issues that prevent the virtual machine
|
|
889
|
+
from booting normally.
|
|
890
|
+
|
|
891
|
+
Virtual machine will boot recovery disk image and original disk image will be mounted in `/mnt` directory.
|
|
892
|
+
*/
|
|
893
|
+
"undefined": {
|
|
894
|
+
params: {
|
|
895
|
+
/**
|
|
896
|
+
* Virtual Machine ID
|
|
897
|
+
*/
|
|
898
|
+
virtualMachineId: number;
|
|
899
|
+
/**
|
|
900
|
+
* Temporary root password for recovery mode
|
|
901
|
+
*/
|
|
902
|
+
root_password: string;
|
|
903
|
+
};
|
|
904
|
+
response: any; // Response structure will depend on the API
|
|
905
|
+
};
|
|
906
|
+
|
|
907
|
+
/**
|
|
908
|
+
* This endpoint stops the recovery mode for a specified virtual machine.
|
|
909
|
+
If virtual machine is not in recovery mode, this operation will fail.
|
|
910
|
+
*/
|
|
911
|
+
"undefined": {
|
|
912
|
+
params: {
|
|
913
|
+
/**
|
|
914
|
+
* Virtual Machine ID
|
|
915
|
+
*/
|
|
916
|
+
virtualMachineId: number;
|
|
917
|
+
};
|
|
918
|
+
response: any; // Response structure will depend on the API
|
|
919
|
+
};
|
|
920
|
+
|
|
921
|
+
/**
|
|
922
|
+
* This endpoint will recreate a virtual machine from scratch.
|
|
923
|
+
The recreation process involves reinstalling the operating system and resetting the virtual machine to its initial state.
|
|
924
|
+
Snapshots, if there are any, will be deleted.
|
|
925
|
+
|
|
926
|
+
## Password Requirements
|
|
927
|
+
Password will be checked against leaked password databases.
|
|
928
|
+
Requirements for the password are:
|
|
929
|
+
- At least 8 characters long
|
|
930
|
+
- At least one uppercase letter
|
|
931
|
+
- At least one lowercase letter
|
|
932
|
+
- At least one number
|
|
933
|
+
- Is not leaked publicly
|
|
934
|
+
|
|
935
|
+
**This operation is irreversible and will result in the loss of all data stored on the virtual machine!**
|
|
936
|
+
*/
|
|
937
|
+
"undefined": {
|
|
938
|
+
params: {
|
|
939
|
+
/**
|
|
940
|
+
* Virtual Machine ID
|
|
941
|
+
*/
|
|
942
|
+
virtualMachineId: number;
|
|
943
|
+
/**
|
|
944
|
+
* Template ID
|
|
945
|
+
*/
|
|
946
|
+
template_id: number;
|
|
947
|
+
/**
|
|
948
|
+
* Password for the virtual machine. If not provided, random password will be generated. Password will not be shown in the response.
|
|
949
|
+
*/
|
|
950
|
+
password?: string;
|
|
951
|
+
/**
|
|
952
|
+
* Post-install script ID
|
|
953
|
+
*/
|
|
954
|
+
post_install_script_id?: number;
|
|
955
|
+
};
|
|
956
|
+
response: any; // Response structure will depend on the API
|
|
957
|
+
};
|
|
958
|
+
|
|
959
|
+
/**
|
|
960
|
+
* This endpoint restarts a specified virtual machine. This is equivalent to fully stopping and starting the virtual machine.
|
|
961
|
+
If the virtual machine was stopped, it will be started.
|
|
962
|
+
*/
|
|
963
|
+
"undefined": {
|
|
964
|
+
params: {
|
|
965
|
+
/**
|
|
966
|
+
* Virtual Machine ID
|
|
967
|
+
*/
|
|
968
|
+
virtualMachineId: number;
|
|
969
|
+
};
|
|
970
|
+
response: any; // Response structure will depend on the API
|
|
971
|
+
};
|
|
972
|
+
|
|
973
|
+
/**
|
|
974
|
+
* This endpoint sets the root password for a specified virtual machine.
|
|
975
|
+
Requirements for the password is the same as in the [recreate virtual machine endpoint](/#tag/vps-virtual-machine/POST/api/vps/v1/virtual-machines/{virtualMachineId}/recreate).
|
|
976
|
+
*/
|
|
977
|
+
"undefined": {
|
|
978
|
+
params: {
|
|
979
|
+
/**
|
|
980
|
+
* Virtual Machine ID
|
|
981
|
+
*/
|
|
982
|
+
virtualMachineId: number;
|
|
983
|
+
/**
|
|
984
|
+
* Root password for the virtual machine
|
|
985
|
+
*/
|
|
986
|
+
password: string;
|
|
987
|
+
};
|
|
988
|
+
response: any; // Response structure will depend on the API
|
|
989
|
+
};
|
|
990
|
+
|
|
991
|
+
/**
|
|
992
|
+
* This endpoint will setup newly purchased virtual machine. Such virtual machines has `initial` state.
|
|
993
|
+
New virtual machine can be purchased using [`/api/billing/v1/orders`](/#tag/billing-orders/POST/api/billing/v1/orders) endpoint.
|
|
994
|
+
*/
|
|
995
|
+
"undefined": {
|
|
996
|
+
params: {
|
|
997
|
+
/**
|
|
998
|
+
* Virtual Machine ID
|
|
999
|
+
*/
|
|
1000
|
+
virtualMachineId: number;
|
|
1001
|
+
/**
|
|
1002
|
+
* Template ID
|
|
1003
|
+
*/
|
|
1004
|
+
template_id: number;
|
|
1005
|
+
/**
|
|
1006
|
+
* Data center ID
|
|
1007
|
+
*/
|
|
1008
|
+
data_center_id: number;
|
|
1009
|
+
/**
|
|
1010
|
+
* Post-install script ID
|
|
1011
|
+
*/
|
|
1012
|
+
post_install_script_id?: number;
|
|
1013
|
+
/**
|
|
1014
|
+
* Password for the virtual machine. If not provided, random password will be generated. Password will not be shown in the response.
|
|
1015
|
+
*/
|
|
1016
|
+
password?: string;
|
|
1017
|
+
/**
|
|
1018
|
+
* Override default hostname of the virtual machine
|
|
1019
|
+
*/
|
|
1020
|
+
hostname?: string;
|
|
1021
|
+
/**
|
|
1022
|
+
* Install Monarx malware scanner (if supported)
|
|
1023
|
+
*/
|
|
1024
|
+
install_monarx?: boolean;
|
|
1025
|
+
/**
|
|
1026
|
+
* Enable weekly backup schedule
|
|
1027
|
+
*/
|
|
1028
|
+
enable_backups?: boolean;
|
|
1029
|
+
/**
|
|
1030
|
+
* ns1 property
|
|
1031
|
+
*/
|
|
1032
|
+
ns1?: string;
|
|
1033
|
+
/**
|
|
1034
|
+
* ns2 property
|
|
1035
|
+
*/
|
|
1036
|
+
ns2?: string;
|
|
1037
|
+
/**
|
|
1038
|
+
* public_key property
|
|
1039
|
+
*/
|
|
1040
|
+
public_key?: object;
|
|
1041
|
+
};
|
|
1042
|
+
response: any; // Response structure will depend on the API
|
|
1043
|
+
};
|
|
1044
|
+
|
|
1045
|
+
/**
|
|
1046
|
+
* This endpoint retrieves a snapshot for a specified virtual machine.
|
|
1047
|
+
*/
|
|
1048
|
+
"undefined": {
|
|
1049
|
+
params: {
|
|
1050
|
+
/**
|
|
1051
|
+
* Virtual Machine ID
|
|
1052
|
+
*/
|
|
1053
|
+
virtualMachineId: number;
|
|
1054
|
+
};
|
|
1055
|
+
response: any; // Response structure will depend on the API
|
|
1056
|
+
};
|
|
1057
|
+
|
|
1058
|
+
/**
|
|
1059
|
+
* This endpoint creates a snapshot of a specified virtual machine.
|
|
1060
|
+
A snapshot captures the state and data of the virtual machine at a specific point in time,
|
|
1061
|
+
allowing users to restore the virtual machine to that state if needed.
|
|
1062
|
+
This operation is useful for backup purposes, system recovery,
|
|
1063
|
+
and testing changes without affecting the current state of the virtual machine.
|
|
1064
|
+
|
|
1065
|
+
**Creating new snapshot will overwrite the existing snapshot!**
|
|
1066
|
+
*/
|
|
1067
|
+
"undefined": {
|
|
1068
|
+
params: {
|
|
1069
|
+
/**
|
|
1070
|
+
* Virtual Machine ID
|
|
1071
|
+
*/
|
|
1072
|
+
virtualMachineId: number;
|
|
1073
|
+
};
|
|
1074
|
+
response: any; // Response structure will depend on the API
|
|
1075
|
+
};
|
|
1076
|
+
|
|
1077
|
+
/**
|
|
1078
|
+
* This endpoint deletes a snapshot of a specified virtual machine.
|
|
1079
|
+
*/
|
|
1080
|
+
"undefined": {
|
|
1081
|
+
params: {
|
|
1082
|
+
/**
|
|
1083
|
+
* Virtual Machine ID
|
|
1084
|
+
*/
|
|
1085
|
+
virtualMachineId: number;
|
|
1086
|
+
};
|
|
1087
|
+
response: any; // Response structure will depend on the API
|
|
1088
|
+
};
|
|
1089
|
+
|
|
1090
|
+
/**
|
|
1091
|
+
* This endpoint restores a specified virtual machine to a previous state using a snapshot.
|
|
1092
|
+
Restoring from a snapshot allows users to revert the virtual machine to that state, which is useful for system recovery, undoing changes, or testing.
|
|
1093
|
+
*/
|
|
1094
|
+
"undefined": {
|
|
1095
|
+
params: {
|
|
1096
|
+
/**
|
|
1097
|
+
* Virtual Machine ID
|
|
1098
|
+
*/
|
|
1099
|
+
virtualMachineId: number;
|
|
1100
|
+
};
|
|
1101
|
+
response: any; // Response structure will depend on the API
|
|
1102
|
+
};
|
|
1103
|
+
|
|
1104
|
+
/**
|
|
1105
|
+
* This endpoint starts a specified virtual machine.
|
|
1106
|
+
If the virtual machine is already running, the request will still be processed without any effect.
|
|
1107
|
+
*/
|
|
1108
|
+
"undefined": {
|
|
1109
|
+
params: {
|
|
1110
|
+
/**
|
|
1111
|
+
* Virtual Machine ID
|
|
1112
|
+
*/
|
|
1113
|
+
virtualMachineId: number;
|
|
1114
|
+
};
|
|
1115
|
+
response: any; // Response structure will depend on the API
|
|
1116
|
+
};
|
|
1117
|
+
|
|
1118
|
+
/**
|
|
1119
|
+
* This endpoint stops a specified virtual machine.
|
|
1120
|
+
If the virtual machine is already stopped, the request will still be processed without any effect.
|
|
1121
|
+
*/
|
|
1122
|
+
"undefined": {
|
|
1123
|
+
params: {
|
|
1124
|
+
/**
|
|
1125
|
+
* Virtual Machine ID
|
|
1126
|
+
*/
|
|
1127
|
+
virtualMachineId: number;
|
|
1128
|
+
};
|
|
1129
|
+
response: any; // Response structure will depend on the API
|
|
1130
|
+
};
|
|
1131
|
+
}
|