@scaleway/sdk-dedibox 2.5.0 → 2.6.0
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/dist/.vite/license.md +3 -0
- package/dist/metadata.gen.d.ts +6 -6
- package/dist/metadata.gen.js +6 -2
- package/dist/v1/api.gen.d.ts +5 -5
- package/dist/v1/api.gen.js +564 -874
- package/dist/v1/content.gen.js +9 -9
- package/dist/v1/marshalling.gen.js +123 -123
- package/dist/v1/metadata.gen.js +1 -1
- package/dist/v1/validation-rules.gen.js +85 -85
- package/package.json +8 -6
- package/LICENSE +0 -191
- package/dist/metadata.gen.json +0 -6
- package/dist/metadata2.gen.js +0 -8
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { isJSONObject, unmarshalArrayOfObject, unmarshalDate, unmarshalMoney } from "@scaleway/sdk-client";
|
|
2
2
|
//#region src/v1/marshalling.gen.ts
|
|
3
|
-
|
|
3
|
+
const unmarshalIP = (data) => {
|
|
4
4
|
if (!isJSONObject(data)) throw new TypeError(`Unmarshalling the type 'IP' failed as data isn't a dictionary.`);
|
|
5
5
|
return {
|
|
6
6
|
address: data.address,
|
|
@@ -14,7 +14,7 @@ var unmarshalIP = (data) => {
|
|
|
14
14
|
version: data.version
|
|
15
15
|
};
|
|
16
16
|
};
|
|
17
|
-
|
|
17
|
+
const unmarshalCPU = (data) => {
|
|
18
18
|
if (!isJSONObject(data)) throw new TypeError(`Unmarshalling the type 'CPU' failed as data isn't a dictionary.`);
|
|
19
19
|
return {
|
|
20
20
|
coreCount: data.core_count,
|
|
@@ -23,14 +23,14 @@ var unmarshalCPU = (data) => {
|
|
|
23
23
|
threadCount: data.thread_count
|
|
24
24
|
};
|
|
25
25
|
};
|
|
26
|
-
|
|
26
|
+
const unmarshalDisk = (data) => {
|
|
27
27
|
if (!isJSONObject(data)) throw new TypeError(`Unmarshalling the type 'Disk' failed as data isn't a dictionary.`);
|
|
28
28
|
return {
|
|
29
29
|
capacity: data.capacity,
|
|
30
30
|
type: data.type
|
|
31
31
|
};
|
|
32
32
|
};
|
|
33
|
-
|
|
33
|
+
const unmarshalMemory = (data) => {
|
|
34
34
|
if (!isJSONObject(data)) throw new TypeError(`Unmarshalling the type 'Memory' failed as data isn't a dictionary.`);
|
|
35
35
|
return {
|
|
36
36
|
capacity: data.capacity,
|
|
@@ -39,7 +39,7 @@ var unmarshalMemory = (data) => {
|
|
|
39
39
|
type: data.type
|
|
40
40
|
};
|
|
41
41
|
};
|
|
42
|
-
|
|
42
|
+
const unmarshalPersistentMemory = (data) => {
|
|
43
43
|
if (!isJSONObject(data)) throw new TypeError(`Unmarshalling the type 'PersistentMemory' failed as data isn't a dictionary.`);
|
|
44
44
|
return {
|
|
45
45
|
capacity: data.capacity,
|
|
@@ -47,42 +47,42 @@ var unmarshalPersistentMemory = (data) => {
|
|
|
47
47
|
model: data.model
|
|
48
48
|
};
|
|
49
49
|
};
|
|
50
|
-
|
|
50
|
+
const unmarshalRaidController = (data) => {
|
|
51
51
|
if (!isJSONObject(data)) throw new TypeError(`Unmarshalling the type 'RaidController' failed as data isn't a dictionary.`);
|
|
52
52
|
return {
|
|
53
53
|
model: data.model,
|
|
54
54
|
raidLevel: data.raid_level
|
|
55
55
|
};
|
|
56
56
|
};
|
|
57
|
-
|
|
57
|
+
const unmarshalOfferAntiDosInfo = (data) => {
|
|
58
58
|
if (!isJSONObject(data)) throw new TypeError(`Unmarshalling the type 'OfferAntiDosInfo' failed as data isn't a dictionary.`);
|
|
59
59
|
return { type: data.type };
|
|
60
60
|
};
|
|
61
|
-
|
|
61
|
+
const unmarshalOfferBackupInfo = (data) => {
|
|
62
62
|
if (!isJSONObject(data)) throw new TypeError(`Unmarshalling the type 'OfferBackupInfo' failed as data isn't a dictionary.`);
|
|
63
63
|
return { size: data.size };
|
|
64
64
|
};
|
|
65
|
-
|
|
65
|
+
const unmarshalOfferBandwidthInfo = (data) => {
|
|
66
66
|
if (!isJSONObject(data)) throw new TypeError(`Unmarshalling the type 'OfferBandwidthInfo' failed as data isn't a dictionary.`);
|
|
67
67
|
return { speed: data.speed };
|
|
68
68
|
};
|
|
69
|
-
|
|
69
|
+
const unmarshalOfferFailoverBlockInfo = (data) => {
|
|
70
70
|
if (!isJSONObject(data)) throw new TypeError(`Unmarshalling the type 'OfferFailoverBlockInfo' failed as data isn't a dictionary.`);
|
|
71
71
|
return { onetimeFees: data.onetime_fees ? unmarshalOffer(data.onetime_fees) : void 0 };
|
|
72
72
|
};
|
|
73
|
-
|
|
73
|
+
const unmarshalOfferFailoverIpInfo = (data) => {
|
|
74
74
|
if (!isJSONObject(data)) throw new TypeError(`Unmarshalling the type 'OfferFailoverIpInfo' failed as data isn't a dictionary.`);
|
|
75
75
|
return { onetimeFees: data.onetime_fees ? unmarshalOffer(data.onetime_fees) : void 0 };
|
|
76
76
|
};
|
|
77
|
-
|
|
77
|
+
const unmarshalOfferLicenseInfo = (data) => {
|
|
78
78
|
if (!isJSONObject(data)) throw new TypeError(`Unmarshalling the type 'OfferLicenseInfo' failed as data isn't a dictionary.`);
|
|
79
79
|
return { boundToIp: data.bound_to_ip };
|
|
80
80
|
};
|
|
81
|
-
|
|
81
|
+
const unmarshalOfferRPNInfo = (data) => {
|
|
82
82
|
if (!isJSONObject(data)) throw new TypeError(`Unmarshalling the type 'OfferRPNInfo' failed as data isn't a dictionary.`);
|
|
83
83
|
return { speed: data.speed };
|
|
84
84
|
};
|
|
85
|
-
|
|
85
|
+
const unmarshalOfferSANInfo = (data) => {
|
|
86
86
|
if (!isJSONObject(data)) throw new TypeError(`Unmarshalling the type 'OfferSANInfo' failed as data isn't a dictionary.`);
|
|
87
87
|
return {
|
|
88
88
|
deviceType: data.device_type,
|
|
@@ -90,7 +90,7 @@ var unmarshalOfferSANInfo = (data) => {
|
|
|
90
90
|
size: data.size
|
|
91
91
|
};
|
|
92
92
|
};
|
|
93
|
-
|
|
93
|
+
const unmarshalOfferServerInfo = (data) => {
|
|
94
94
|
if (!isJSONObject(data)) throw new TypeError(`Unmarshalling the type 'OfferServerInfo' failed as data isn't a dictionary.`);
|
|
95
95
|
return {
|
|
96
96
|
availableOptions: unmarshalArrayOfObject(data.available_options, unmarshalOffer),
|
|
@@ -108,7 +108,7 @@ var unmarshalOfferServerInfo = (data) => {
|
|
|
108
108
|
stockByDatacenter: data.stock_by_datacenter
|
|
109
109
|
};
|
|
110
110
|
};
|
|
111
|
-
|
|
111
|
+
const unmarshalOfferServiceLevelInfo = (data) => {
|
|
112
112
|
if (!isJSONObject(data)) throw new TypeError(`Unmarshalling the type 'OfferServiceLevelInfo' failed as data isn't a dictionary.`);
|
|
113
113
|
return {
|
|
114
114
|
antidos: data.antidos,
|
|
@@ -124,14 +124,14 @@ var unmarshalOfferServiceLevelInfo = (data) => {
|
|
|
124
124
|
supportTicket: data.support_ticket
|
|
125
125
|
};
|
|
126
126
|
};
|
|
127
|
-
|
|
127
|
+
const unmarshalOfferStorageInfo = (data) => {
|
|
128
128
|
if (!isJSONObject(data)) throw new TypeError(`Unmarshalling the type 'OfferStorageInfo' failed as data isn't a dictionary.`);
|
|
129
129
|
return {
|
|
130
130
|
maxQuota: data.max_quota,
|
|
131
131
|
size: data.size
|
|
132
132
|
};
|
|
133
133
|
};
|
|
134
|
-
|
|
134
|
+
const unmarshalOffer = (data) => {
|
|
135
135
|
if (!isJSONObject(data)) throw new TypeError(`Unmarshalling the type 'Offer' failed as data isn't a dictionary.`);
|
|
136
136
|
return {
|
|
137
137
|
antidosInfo: data.antidos_info ? unmarshalOfferAntiDosInfo(data.antidos_info) : void 0,
|
|
@@ -153,7 +153,7 @@ var unmarshalOffer = (data) => {
|
|
|
153
153
|
usbStorageInfo: data.usb_storage_info ? unmarshalOfferStorageInfo(data.usb_storage_info) : void 0
|
|
154
154
|
};
|
|
155
155
|
};
|
|
156
|
-
|
|
156
|
+
const unmarshalOS = (data) => {
|
|
157
157
|
if (!isJSONObject(data)) throw new TypeError(`Unmarshalling the type 'OS' failed as data isn't a dictionary.`);
|
|
158
158
|
return {
|
|
159
159
|
allowCustomPartitioning: data.allow_custom_partitioning,
|
|
@@ -179,7 +179,7 @@ var unmarshalOS = (data) => {
|
|
|
179
179
|
version: data.version
|
|
180
180
|
};
|
|
181
181
|
};
|
|
182
|
-
|
|
182
|
+
const unmarshalRpnSan = (data) => {
|
|
183
183
|
if (!isJSONObject(data)) throw new TypeError(`Unmarshalling the type 'RpnSan' failed as data isn't a dictionary.`);
|
|
184
184
|
return {
|
|
185
185
|
createdAt: unmarshalDate(data.created_at),
|
|
@@ -202,7 +202,7 @@ var unmarshalRpnSan = (data) => {
|
|
|
202
202
|
terminatedAt: unmarshalDate(data.terminated_at)
|
|
203
203
|
};
|
|
204
204
|
};
|
|
205
|
-
|
|
205
|
+
const unmarshalRpnGroup = (data) => {
|
|
206
206
|
if (!isJSONObject(data)) throw new TypeError(`Unmarshalling the type 'RpnGroup' failed as data isn't a dictionary.`);
|
|
207
207
|
return {
|
|
208
208
|
active: data.active,
|
|
@@ -216,7 +216,7 @@ var unmarshalRpnGroup = (data) => {
|
|
|
216
216
|
type: data.type
|
|
217
217
|
};
|
|
218
218
|
};
|
|
219
|
-
|
|
219
|
+
const unmarshalNetworkInterface = (data) => {
|
|
220
220
|
if (!isJSONObject(data)) throw new TypeError(`Unmarshalling the type 'NetworkInterface' failed as data isn't a dictionary.`);
|
|
221
221
|
return {
|
|
222
222
|
cardId: data.card_id,
|
|
@@ -226,7 +226,7 @@ var unmarshalNetworkInterface = (data) => {
|
|
|
226
226
|
type: data.type
|
|
227
227
|
};
|
|
228
228
|
};
|
|
229
|
-
|
|
229
|
+
const unmarshalServerLocation = (data) => {
|
|
230
230
|
if (!isJSONObject(data)) throw new TypeError(`Unmarshalling the type 'ServerLocation' failed as data isn't a dictionary.`);
|
|
231
231
|
return {
|
|
232
232
|
datacenterName: data.datacenter_name,
|
|
@@ -234,7 +234,7 @@ var unmarshalServerLocation = (data) => {
|
|
|
234
234
|
room: data.room
|
|
235
235
|
};
|
|
236
236
|
};
|
|
237
|
-
|
|
237
|
+
const unmarshalServerOption = (data) => {
|
|
238
238
|
if (!isJSONObject(data)) throw new TypeError(`Unmarshalling the type 'ServerOption' failed as data isn't a dictionary.`);
|
|
239
239
|
return {
|
|
240
240
|
createdAt: unmarshalDate(data.created_at),
|
|
@@ -244,14 +244,14 @@ var unmarshalServerOption = (data) => {
|
|
|
244
244
|
updatedAt: unmarshalDate(data.updated_at)
|
|
245
245
|
};
|
|
246
246
|
};
|
|
247
|
-
|
|
247
|
+
const unmarshalServiceLevel = (data) => {
|
|
248
248
|
if (!isJSONObject(data)) throw new TypeError(`Unmarshalling the type 'ServiceLevel' failed as data isn't a dictionary.`);
|
|
249
249
|
return {
|
|
250
250
|
level: data.level,
|
|
251
251
|
offerId: data.offer_id
|
|
252
252
|
};
|
|
253
253
|
};
|
|
254
|
-
|
|
254
|
+
const unmarshalServer = (data) => {
|
|
255
255
|
if (!isJSONObject(data)) throw new TypeError(`Unmarshalling the type 'Server' failed as data isn't a dictionary.`);
|
|
256
256
|
return {
|
|
257
257
|
abuseContact: data.abuse_contact,
|
|
@@ -281,14 +281,14 @@ var unmarshalServer = (data) => {
|
|
|
281
281
|
zone: data.zone
|
|
282
282
|
};
|
|
283
283
|
};
|
|
284
|
-
|
|
284
|
+
const unmarshalRpnV2GroupSubnet = (data) => {
|
|
285
285
|
if (!isJSONObject(data)) throw new TypeError(`Unmarshalling the type 'RpnV2GroupSubnet' failed as data isn't a dictionary.`);
|
|
286
286
|
return {
|
|
287
287
|
address: data.address,
|
|
288
288
|
cidr: data.cidr
|
|
289
289
|
};
|
|
290
290
|
};
|
|
291
|
-
|
|
291
|
+
const unmarshalRpnV2Group = (data) => {
|
|
292
292
|
if (!isJSONObject(data)) throw new TypeError(`Unmarshalling the type 'RpnV2Group' failed as data isn't a dictionary.`);
|
|
293
293
|
return {
|
|
294
294
|
compatibleRpnv1: data.compatible_rpnv1,
|
|
@@ -305,7 +305,7 @@ var unmarshalRpnV2Group = (data) => {
|
|
|
305
305
|
type: data.type
|
|
306
306
|
};
|
|
307
307
|
};
|
|
308
|
-
|
|
308
|
+
const unmarshalService = (data) => {
|
|
309
309
|
if (!isJSONObject(data)) throw new TypeError(`Unmarshalling the type 'Service' failed as data isn't a dictionary.`);
|
|
310
310
|
return {
|
|
311
311
|
createdAt: unmarshalDate(data.created_at),
|
|
@@ -319,7 +319,7 @@ var unmarshalService = (data) => {
|
|
|
319
319
|
type: data.type
|
|
320
320
|
};
|
|
321
321
|
};
|
|
322
|
-
|
|
322
|
+
const unmarshalFailoverBlock = (data) => {
|
|
323
323
|
if (!isJSONObject(data)) throw new TypeError(`Unmarshalling the type 'FailoverBlock' failed as data isn't a dictionary.`);
|
|
324
324
|
return {
|
|
325
325
|
address: data.address,
|
|
@@ -331,7 +331,7 @@ var unmarshalFailoverBlock = (data) => {
|
|
|
331
331
|
netmask: data.netmask
|
|
332
332
|
};
|
|
333
333
|
};
|
|
334
|
-
|
|
334
|
+
const unmarshalFailoverIP = (data) => {
|
|
335
335
|
if (!isJSONObject(data)) throw new TypeError(`Unmarshalling the type 'FailoverIP' failed as data isn't a dictionary.`);
|
|
336
336
|
return {
|
|
337
337
|
address: data.address,
|
|
@@ -349,7 +349,7 @@ var unmarshalFailoverIP = (data) => {
|
|
|
349
349
|
type: data.type
|
|
350
350
|
};
|
|
351
351
|
};
|
|
352
|
-
|
|
352
|
+
const unmarshalIPv6Block = (data) => {
|
|
353
353
|
if (!isJSONObject(data)) throw new TypeError(`Unmarshalling the type 'IPv6Block' failed as data isn't a dictionary.`);
|
|
354
354
|
return {
|
|
355
355
|
address: data.address,
|
|
@@ -361,7 +361,7 @@ var unmarshalIPv6Block = (data) => {
|
|
|
361
361
|
subnets: unmarshalArrayOfObject(data.subnets, unmarshalIPv6Block)
|
|
362
362
|
};
|
|
363
363
|
};
|
|
364
|
-
|
|
364
|
+
const unmarshalBMCAccess = (data) => {
|
|
365
365
|
if (!isJSONObject(data)) throw new TypeError(`Unmarshalling the type 'BMCAccess' failed as data isn't a dictionary.`);
|
|
366
366
|
return {
|
|
367
367
|
expiresAt: unmarshalDate(data.expires_at),
|
|
@@ -371,7 +371,7 @@ var unmarshalBMCAccess = (data) => {
|
|
|
371
371
|
url: data.url
|
|
372
372
|
};
|
|
373
373
|
};
|
|
374
|
-
|
|
374
|
+
const unmarshalBackup = (data) => {
|
|
375
375
|
if (!isJSONObject(data)) throw new TypeError(`Unmarshalling the type 'Backup' failed as data isn't a dictionary.`);
|
|
376
376
|
return {
|
|
377
377
|
aclEnabled: data.acl_enabled,
|
|
@@ -386,7 +386,7 @@ var unmarshalBackup = (data) => {
|
|
|
386
386
|
status: data.status
|
|
387
387
|
};
|
|
388
388
|
};
|
|
389
|
-
|
|
389
|
+
const unmarshalCanOrderResponse = (data) => {
|
|
390
390
|
if (!isJSONObject(data)) throw new TypeError(`Unmarshalling the type 'CanOrderResponse' failed as data isn't a dictionary.`);
|
|
391
391
|
return {
|
|
392
392
|
billingOk: data.billing_ok,
|
|
@@ -399,28 +399,28 @@ var unmarshalCanOrderResponse = (data) => {
|
|
|
399
399
|
userConfirmed: data.user_confirmed
|
|
400
400
|
};
|
|
401
401
|
};
|
|
402
|
-
|
|
402
|
+
const unmarshalCreateFailoverIPsResponse = (data) => {
|
|
403
403
|
if (!isJSONObject(data)) throw new TypeError(`Unmarshalling the type 'CreateFailoverIPsResponse' failed as data isn't a dictionary.`);
|
|
404
404
|
return {
|
|
405
405
|
services: unmarshalArrayOfObject(data.services, unmarshalService),
|
|
406
406
|
totalCount: data.total_count
|
|
407
407
|
};
|
|
408
408
|
};
|
|
409
|
-
|
|
409
|
+
const unmarshalGetIPv6BlockQuotasResponseQuota = (data) => {
|
|
410
410
|
if (!isJSONObject(data)) throw new TypeError(`Unmarshalling the type 'GetIPv6BlockQuotasResponseQuota' failed as data isn't a dictionary.`);
|
|
411
411
|
return {
|
|
412
412
|
cidr: data.cidr,
|
|
413
413
|
quota: data.quota
|
|
414
414
|
};
|
|
415
415
|
};
|
|
416
|
-
|
|
416
|
+
const unmarshalGetIPv6BlockQuotasResponse = (data) => {
|
|
417
417
|
if (!isJSONObject(data)) throw new TypeError(`Unmarshalling the type 'GetIPv6BlockQuotasResponse' failed as data isn't a dictionary.`);
|
|
418
418
|
return {
|
|
419
419
|
quotas: unmarshalArrayOfObject(data.quotas, unmarshalGetIPv6BlockQuotasResponseQuota),
|
|
420
420
|
totalCount: data.total_count
|
|
421
421
|
};
|
|
422
422
|
};
|
|
423
|
-
|
|
423
|
+
const unmarshalGetRemainingQuotaResponse = (data) => {
|
|
424
424
|
if (!isJSONObject(data)) throw new TypeError(`Unmarshalling the type 'GetRemainingQuotaResponse' failed as data isn't a dictionary.`);
|
|
425
425
|
return {
|
|
426
426
|
failoverBlockQuota: data.failover_block_quota,
|
|
@@ -429,14 +429,14 @@ var unmarshalGetRemainingQuotaResponse = (data) => {
|
|
|
429
429
|
failoverIpRemainingQuota: data.failover_ip_remaining_quota
|
|
430
430
|
};
|
|
431
431
|
};
|
|
432
|
-
|
|
432
|
+
const unmarshalGetRpnStatusResponse = (data) => {
|
|
433
433
|
if (!isJSONObject(data)) throw new TypeError(`Unmarshalling the type 'GetRpnStatusResponse' failed as data isn't a dictionary.`);
|
|
434
434
|
return {
|
|
435
435
|
operationsLeft: data.operations_left,
|
|
436
436
|
status: data.status
|
|
437
437
|
};
|
|
438
438
|
};
|
|
439
|
-
|
|
439
|
+
const unmarshalInvoice = (data) => {
|
|
440
440
|
if (!isJSONObject(data)) throw new TypeError(`Unmarshalling the type 'Invoice' failed as data isn't a dictionary.`);
|
|
441
441
|
return {
|
|
442
442
|
content: data.content,
|
|
@@ -450,35 +450,35 @@ var unmarshalInvoice = (data) => {
|
|
|
450
450
|
transactionId: data.transaction_id
|
|
451
451
|
};
|
|
452
452
|
};
|
|
453
|
-
|
|
453
|
+
const unmarshalListFailoverIPsResponse = (data) => {
|
|
454
454
|
if (!isJSONObject(data)) throw new TypeError(`Unmarshalling the type 'ListFailoverIPsResponse' failed as data isn't a dictionary.`);
|
|
455
455
|
return {
|
|
456
456
|
failoverIps: unmarshalArrayOfObject(data.failover_ips, unmarshalFailoverIP),
|
|
457
457
|
totalCount: data.total_count
|
|
458
458
|
};
|
|
459
459
|
};
|
|
460
|
-
|
|
460
|
+
const unmarshalListIPv6BlockSubnetsAvailableResponseSubnet = (data) => {
|
|
461
461
|
if (!isJSONObject(data)) throw new TypeError(`Unmarshalling the type 'ListIPv6BlockSubnetsAvailableResponseSubnet' failed as data isn't a dictionary.`);
|
|
462
462
|
return {
|
|
463
463
|
address: data.address,
|
|
464
464
|
cidr: data.cidr
|
|
465
465
|
};
|
|
466
466
|
};
|
|
467
|
-
|
|
467
|
+
const unmarshalListIPv6BlockSubnetsAvailableResponse = (data) => {
|
|
468
468
|
if (!isJSONObject(data)) throw new TypeError(`Unmarshalling the type 'ListIPv6BlockSubnetsAvailableResponse' failed as data isn't a dictionary.`);
|
|
469
469
|
return {
|
|
470
470
|
subnetAvailables: unmarshalArrayOfObject(data.subnet_availables, unmarshalListIPv6BlockSubnetsAvailableResponseSubnet),
|
|
471
471
|
totalCount: data.total_count
|
|
472
472
|
};
|
|
473
473
|
};
|
|
474
|
-
|
|
474
|
+
const unmarshalListIPv6BlocksResponse = (data) => {
|
|
475
475
|
if (!isJSONObject(data)) throw new TypeError(`Unmarshalling the type 'ListIPv6BlocksResponse' failed as data isn't a dictionary.`);
|
|
476
476
|
return {
|
|
477
477
|
ipv6Blocks: unmarshalArrayOfObject(data.ipv6_blocks, unmarshalIPv6Block),
|
|
478
478
|
totalCount: data.total_count
|
|
479
479
|
};
|
|
480
480
|
};
|
|
481
|
-
|
|
481
|
+
const unmarshalInvoiceSummary = (data) => {
|
|
482
482
|
if (!isJSONObject(data)) throw new TypeError(`Unmarshalling the type 'InvoiceSummary' failed as data isn't a dictionary.`);
|
|
483
483
|
return {
|
|
484
484
|
createdAt: unmarshalDate(data.created_at),
|
|
@@ -491,21 +491,21 @@ var unmarshalInvoiceSummary = (data) => {
|
|
|
491
491
|
transactionId: data.transaction_id
|
|
492
492
|
};
|
|
493
493
|
};
|
|
494
|
-
|
|
494
|
+
const unmarshalListInvoicesResponse = (data) => {
|
|
495
495
|
if (!isJSONObject(data)) throw new TypeError(`Unmarshalling the type 'ListInvoicesResponse' failed as data isn't a dictionary.`);
|
|
496
496
|
return {
|
|
497
497
|
invoices: unmarshalArrayOfObject(data.invoices, unmarshalInvoiceSummary),
|
|
498
498
|
totalCount: data.total_count
|
|
499
499
|
};
|
|
500
500
|
};
|
|
501
|
-
|
|
501
|
+
const unmarshalRpnSanIpRpnV2Group = (data) => {
|
|
502
502
|
if (!isJSONObject(data)) throw new TypeError(`Unmarshalling the type 'RpnSanIpRpnV2Group' failed as data isn't a dictionary.`);
|
|
503
503
|
return {
|
|
504
504
|
id: data.id,
|
|
505
505
|
name: data.name
|
|
506
506
|
};
|
|
507
507
|
};
|
|
508
|
-
|
|
508
|
+
const unmarshalRpnSanIpServer = (data) => {
|
|
509
509
|
if (!isJSONObject(data)) throw new TypeError(`Unmarshalling the type 'RpnSanIpServer' failed as data isn't a dictionary.`);
|
|
510
510
|
return {
|
|
511
511
|
datacenterName: data.datacenter_name,
|
|
@@ -513,7 +513,7 @@ var unmarshalRpnSanIpServer = (data) => {
|
|
|
513
513
|
id: data.id
|
|
514
514
|
};
|
|
515
515
|
};
|
|
516
|
-
|
|
516
|
+
const unmarshalRpnSanIp = (data) => {
|
|
517
517
|
if (!isJSONObject(data)) throw new TypeError(`Unmarshalling the type 'RpnSanIp' failed as data isn't a dictionary.`);
|
|
518
518
|
return {
|
|
519
519
|
ip: data.ip ? unmarshalIP(data.ip) : void 0,
|
|
@@ -522,28 +522,28 @@ var unmarshalRpnSanIp = (data) => {
|
|
|
522
522
|
type: data.type
|
|
523
523
|
};
|
|
524
524
|
};
|
|
525
|
-
|
|
525
|
+
const unmarshalListIpsResponse = (data) => {
|
|
526
526
|
if (!isJSONObject(data)) throw new TypeError(`Unmarshalling the type 'ListIpsResponse' failed as data isn't a dictionary.`);
|
|
527
527
|
return {
|
|
528
528
|
ips: unmarshalArrayOfObject(data.ips, unmarshalRpnSanIp),
|
|
529
529
|
totalCount: data.total_count
|
|
530
530
|
};
|
|
531
531
|
};
|
|
532
|
-
|
|
532
|
+
const unmarshalListOSResponse = (data) => {
|
|
533
533
|
if (!isJSONObject(data)) throw new TypeError(`Unmarshalling the type 'ListOSResponse' failed as data isn't a dictionary.`);
|
|
534
534
|
return {
|
|
535
535
|
os: unmarshalArrayOfObject(data.os, unmarshalOS),
|
|
536
536
|
totalCount: data.total_count
|
|
537
537
|
};
|
|
538
538
|
};
|
|
539
|
-
|
|
539
|
+
const unmarshalListOffersResponse = (data) => {
|
|
540
540
|
if (!isJSONObject(data)) throw new TypeError(`Unmarshalling the type 'ListOffersResponse' failed as data isn't a dictionary.`);
|
|
541
541
|
return {
|
|
542
542
|
offers: unmarshalArrayOfObject(data.offers, unmarshalOffer),
|
|
543
543
|
totalCount: data.total_count
|
|
544
544
|
};
|
|
545
545
|
};
|
|
546
|
-
|
|
546
|
+
const unmarshalRefundSummary = (data) => {
|
|
547
547
|
if (!isJSONObject(data)) throw new TypeError(`Unmarshalling the type 'RefundSummary' failed as data isn't a dictionary.`);
|
|
548
548
|
return {
|
|
549
549
|
createdAt: unmarshalDate(data.created_at),
|
|
@@ -555,14 +555,14 @@ var unmarshalRefundSummary = (data) => {
|
|
|
555
555
|
totalWithoutTaxes: data.total_without_taxes ? unmarshalMoney(data.total_without_taxes) : void 0
|
|
556
556
|
};
|
|
557
557
|
};
|
|
558
|
-
|
|
558
|
+
const unmarshalListRefundsResponse = (data) => {
|
|
559
559
|
if (!isJSONObject(data)) throw new TypeError(`Unmarshalling the type 'ListRefundsResponse' failed as data isn't a dictionary.`);
|
|
560
560
|
return {
|
|
561
561
|
refunds: unmarshalArrayOfObject(data.refunds, unmarshalRefundSummary),
|
|
562
562
|
totalCount: data.total_count
|
|
563
563
|
};
|
|
564
564
|
};
|
|
565
|
-
|
|
565
|
+
const unmarshalRpnSanServer = (data) => {
|
|
566
566
|
if (!isJSONObject(data)) throw new TypeError(`Unmarshalling the type 'RpnSanServer' failed as data isn't a dictionary.`);
|
|
567
567
|
return {
|
|
568
568
|
datacenterName: data.datacenter_name,
|
|
@@ -572,21 +572,21 @@ var unmarshalRpnSanServer = (data) => {
|
|
|
572
572
|
zone: data.zone
|
|
573
573
|
};
|
|
574
574
|
};
|
|
575
|
-
|
|
575
|
+
const unmarshalListRpnCapableSanServersResponse = (data) => {
|
|
576
576
|
if (!isJSONObject(data)) throw new TypeError(`Unmarshalling the type 'ListRpnCapableSanServersResponse' failed as data isn't a dictionary.`);
|
|
577
577
|
return {
|
|
578
578
|
sanServers: unmarshalArrayOfObject(data.san_servers, unmarshalRpnSanServer),
|
|
579
579
|
totalCount: data.total_count
|
|
580
580
|
};
|
|
581
581
|
};
|
|
582
|
-
|
|
582
|
+
const unmarshalListRpnCapableServersResponse = (data) => {
|
|
583
583
|
if (!isJSONObject(data)) throw new TypeError(`Unmarshalling the type 'ListRpnCapableServersResponse' failed as data isn't a dictionary.`);
|
|
584
584
|
return {
|
|
585
585
|
servers: unmarshalArrayOfObject(data.servers, unmarshalServer),
|
|
586
586
|
totalCount: data.total_count
|
|
587
587
|
};
|
|
588
588
|
};
|
|
589
|
-
|
|
589
|
+
const unmarshalRpnGroupMember = (data) => {
|
|
590
590
|
if (!isJSONObject(data)) throw new TypeError(`Unmarshalling the type 'RpnGroupMember' failed as data isn't a dictionary.`);
|
|
591
591
|
return {
|
|
592
592
|
groupId: data.group_id,
|
|
@@ -600,28 +600,28 @@ var unmarshalRpnGroupMember = (data) => {
|
|
|
600
600
|
status: data.status
|
|
601
601
|
};
|
|
602
602
|
};
|
|
603
|
-
|
|
603
|
+
const unmarshalListRpnGroupMembersResponse = (data) => {
|
|
604
604
|
if (!isJSONObject(data)) throw new TypeError(`Unmarshalling the type 'ListRpnGroupMembersResponse' failed as data isn't a dictionary.`);
|
|
605
605
|
return {
|
|
606
606
|
members: unmarshalArrayOfObject(data.members, unmarshalRpnGroupMember),
|
|
607
607
|
totalCount: data.total_count
|
|
608
608
|
};
|
|
609
609
|
};
|
|
610
|
-
|
|
610
|
+
const unmarshalListRpnGroupsResponse = (data) => {
|
|
611
611
|
if (!isJSONObject(data)) throw new TypeError(`Unmarshalling the type 'ListRpnGroupsResponse' failed as data isn't a dictionary.`);
|
|
612
612
|
return {
|
|
613
613
|
rpnGroups: unmarshalArrayOfObject(data.rpn_groups, unmarshalRpnGroup),
|
|
614
614
|
totalCount: data.total_count
|
|
615
615
|
};
|
|
616
616
|
};
|
|
617
|
-
|
|
617
|
+
const unmarshalListRpnInvitesResponse = (data) => {
|
|
618
618
|
if (!isJSONObject(data)) throw new TypeError(`Unmarshalling the type 'ListRpnInvitesResponse' failed as data isn't a dictionary.`);
|
|
619
619
|
return {
|
|
620
620
|
members: unmarshalArrayOfObject(data.members, unmarshalRpnGroupMember),
|
|
621
621
|
totalCount: data.total_count
|
|
622
622
|
};
|
|
623
623
|
};
|
|
624
|
-
|
|
624
|
+
const unmarshalRpnSanSummary = (data) => {
|
|
625
625
|
if (!isJSONObject(data)) throw new TypeError(`Unmarshalling the type 'RpnSanSummary' failed as data isn't a dictionary.`);
|
|
626
626
|
return {
|
|
627
627
|
createdAt: unmarshalDate(data.created_at),
|
|
@@ -642,14 +642,14 @@ var unmarshalRpnSanSummary = (data) => {
|
|
|
642
642
|
terminatedAt: unmarshalDate(data.terminated_at)
|
|
643
643
|
};
|
|
644
644
|
};
|
|
645
|
-
|
|
645
|
+
const unmarshalListRpnSansResponse = (data) => {
|
|
646
646
|
if (!isJSONObject(data)) throw new TypeError(`Unmarshalling the type 'ListRpnSansResponse' failed as data isn't a dictionary.`);
|
|
647
647
|
return {
|
|
648
648
|
rpnSans: unmarshalArrayOfObject(data.rpn_sans, unmarshalRpnSanSummary),
|
|
649
649
|
totalCount: data.total_count
|
|
650
650
|
};
|
|
651
651
|
};
|
|
652
|
-
|
|
652
|
+
const unmarshalRpnServerCapability = (data) => {
|
|
653
653
|
if (!isJSONObject(data)) throw new TypeError(`Unmarshalling the type 'RpnServerCapability' failed as data isn't a dictionary.`);
|
|
654
654
|
return {
|
|
655
655
|
canJoinQinqGroup: data.can_join_qinq_group,
|
|
@@ -665,21 +665,21 @@ var unmarshalRpnServerCapability = (data) => {
|
|
|
665
665
|
zone: data.zone
|
|
666
666
|
};
|
|
667
667
|
};
|
|
668
|
-
|
|
668
|
+
const unmarshalListRpnServerCapabilitiesResponse = (data) => {
|
|
669
669
|
if (!isJSONObject(data)) throw new TypeError(`Unmarshalling the type 'ListRpnServerCapabilitiesResponse' failed as data isn't a dictionary.`);
|
|
670
670
|
return {
|
|
671
671
|
servers: unmarshalArrayOfObject(data.servers, unmarshalRpnServerCapability),
|
|
672
672
|
totalCount: data.total_count
|
|
673
673
|
};
|
|
674
674
|
};
|
|
675
|
-
|
|
675
|
+
const unmarshalListRpnV2CapableResourcesResponse = (data) => {
|
|
676
676
|
if (!isJSONObject(data)) throw new TypeError(`Unmarshalling the type 'ListRpnV2CapableResourcesResponse' failed as data isn't a dictionary.`);
|
|
677
677
|
return {
|
|
678
678
|
servers: unmarshalArrayOfObject(data.servers, unmarshalServer),
|
|
679
679
|
totalCount: data.total_count
|
|
680
680
|
};
|
|
681
681
|
};
|
|
682
|
-
|
|
682
|
+
const unmarshalRpnV2Member = (data) => {
|
|
683
683
|
if (!isJSONObject(data)) throw new TypeError(`Unmarshalling the type 'RpnV2Member' failed as data isn't a dictionary.`);
|
|
684
684
|
return {
|
|
685
685
|
id: data.id,
|
|
@@ -690,7 +690,7 @@ var unmarshalRpnV2Member = (data) => {
|
|
|
690
690
|
vlan: data.vlan
|
|
691
691
|
};
|
|
692
692
|
};
|
|
693
|
-
|
|
693
|
+
const unmarshalLog = (data) => {
|
|
694
694
|
if (!isJSONObject(data)) throw new TypeError(`Unmarshalling the type 'Log' failed as data isn't a dictionary.`);
|
|
695
695
|
return {
|
|
696
696
|
action: data.action,
|
|
@@ -702,28 +702,28 @@ var unmarshalLog = (data) => {
|
|
|
702
702
|
status: data.status
|
|
703
703
|
};
|
|
704
704
|
};
|
|
705
|
-
|
|
705
|
+
const unmarshalListRpnV2GroupLogsResponse = (data) => {
|
|
706
706
|
if (!isJSONObject(data)) throw new TypeError(`Unmarshalling the type 'ListRpnV2GroupLogsResponse' failed as data isn't a dictionary.`);
|
|
707
707
|
return {
|
|
708
708
|
logs: unmarshalArrayOfObject(data.logs, unmarshalLog),
|
|
709
709
|
totalCount: data.total_count
|
|
710
710
|
};
|
|
711
711
|
};
|
|
712
|
-
|
|
712
|
+
const unmarshalListRpnV2GroupsResponse = (data) => {
|
|
713
713
|
if (!isJSONObject(data)) throw new TypeError(`Unmarshalling the type 'ListRpnV2GroupsResponse' failed as data isn't a dictionary.`);
|
|
714
714
|
return {
|
|
715
715
|
rpnGroups: unmarshalArrayOfObject(data.rpn_groups, unmarshalRpnV2Group),
|
|
716
716
|
totalCount: data.total_count
|
|
717
717
|
};
|
|
718
718
|
};
|
|
719
|
-
|
|
719
|
+
const unmarshalListRpnV2MembersResponse = (data) => {
|
|
720
720
|
if (!isJSONObject(data)) throw new TypeError(`Unmarshalling the type 'ListRpnV2MembersResponse' failed as data isn't a dictionary.`);
|
|
721
721
|
return {
|
|
722
722
|
members: unmarshalArrayOfObject(data.members, unmarshalRpnV2Member),
|
|
723
723
|
totalCount: data.total_count
|
|
724
724
|
};
|
|
725
725
|
};
|
|
726
|
-
|
|
726
|
+
const unmarshalServerDisk = (data) => {
|
|
727
727
|
if (!isJSONObject(data)) throw new TypeError(`Unmarshalling the type 'ServerDisk' failed as data isn't a dictionary.`);
|
|
728
728
|
return {
|
|
729
729
|
capacity: data.capacity,
|
|
@@ -733,14 +733,14 @@ var unmarshalServerDisk = (data) => {
|
|
|
733
733
|
type: data.type
|
|
734
734
|
};
|
|
735
735
|
};
|
|
736
|
-
|
|
736
|
+
const unmarshalListServerDisksResponse = (data) => {
|
|
737
737
|
if (!isJSONObject(data)) throw new TypeError(`Unmarshalling the type 'ListServerDisksResponse' failed as data isn't a dictionary.`);
|
|
738
738
|
return {
|
|
739
739
|
disks: unmarshalArrayOfObject(data.disks, unmarshalServerDisk),
|
|
740
740
|
totalCount: data.total_count
|
|
741
741
|
};
|
|
742
742
|
};
|
|
743
|
-
|
|
743
|
+
const unmarshalServerEvent = (data) => {
|
|
744
744
|
if (!isJSONObject(data)) throw new TypeError(`Unmarshalling the type 'ServerEvent' failed as data isn't a dictionary.`);
|
|
745
745
|
return {
|
|
746
746
|
date: unmarshalDate(data.date),
|
|
@@ -748,14 +748,14 @@ var unmarshalServerEvent = (data) => {
|
|
|
748
748
|
eventId: data.event_id
|
|
749
749
|
};
|
|
750
750
|
};
|
|
751
|
-
|
|
751
|
+
const unmarshalListServerEventsResponse = (data) => {
|
|
752
752
|
if (!isJSONObject(data)) throw new TypeError(`Unmarshalling the type 'ListServerEventsResponse' failed as data isn't a dictionary.`);
|
|
753
753
|
return {
|
|
754
754
|
events: unmarshalArrayOfObject(data.events, unmarshalServerEvent),
|
|
755
755
|
totalCount: data.total_count
|
|
756
756
|
};
|
|
757
757
|
};
|
|
758
|
-
|
|
758
|
+
const unmarshalServerSummary = (data) => {
|
|
759
759
|
if (!isJSONObject(data)) throw new TypeError(`Unmarshalling the type 'ServerSummary' failed as data isn't a dictionary.`);
|
|
760
760
|
return {
|
|
761
761
|
createdAt: unmarshalDate(data.created_at),
|
|
@@ -779,39 +779,39 @@ var unmarshalServerSummary = (data) => {
|
|
|
779
779
|
zone: data.zone
|
|
780
780
|
};
|
|
781
781
|
};
|
|
782
|
-
|
|
782
|
+
const unmarshalListServersResponse = (data) => {
|
|
783
783
|
if (!isJSONObject(data)) throw new TypeError(`Unmarshalling the type 'ListServersResponse' failed as data isn't a dictionary.`);
|
|
784
784
|
return {
|
|
785
785
|
servers: unmarshalArrayOfObject(data.servers, unmarshalServerSummary),
|
|
786
786
|
totalCount: data.total_count
|
|
787
787
|
};
|
|
788
788
|
};
|
|
789
|
-
|
|
789
|
+
const unmarshalListServicesResponse = (data) => {
|
|
790
790
|
if (!isJSONObject(data)) throw new TypeError(`Unmarshalling the type 'ListServicesResponse' failed as data isn't a dictionary.`);
|
|
791
791
|
return {
|
|
792
792
|
services: unmarshalArrayOfObject(data.services, unmarshalService),
|
|
793
793
|
totalCount: data.total_count
|
|
794
794
|
};
|
|
795
795
|
};
|
|
796
|
-
|
|
796
|
+
const unmarshalListSubscribableServerOptionsResponse = (data) => {
|
|
797
797
|
if (!isJSONObject(data)) throw new TypeError(`Unmarshalling the type 'ListSubscribableServerOptionsResponse' failed as data isn't a dictionary.`);
|
|
798
798
|
return {
|
|
799
799
|
serverOptions: unmarshalArrayOfObject(data.server_options, unmarshalOffer),
|
|
800
800
|
totalCount: data.total_count
|
|
801
801
|
};
|
|
802
802
|
};
|
|
803
|
-
|
|
803
|
+
const unmarshalRaidArray = (data) => {
|
|
804
804
|
if (!isJSONObject(data)) throw new TypeError(`Unmarshalling the type 'RaidArray' failed as data isn't a dictionary.`);
|
|
805
805
|
return {
|
|
806
806
|
disks: unmarshalArrayOfObject(data.disks, unmarshalServerDisk),
|
|
807
807
|
raidLevel: data.raid_level
|
|
808
808
|
};
|
|
809
809
|
};
|
|
810
|
-
|
|
810
|
+
const unmarshalRaid = (data) => {
|
|
811
811
|
if (!isJSONObject(data)) throw new TypeError(`Unmarshalling the type 'Raid' failed as data isn't a dictionary.`);
|
|
812
812
|
return { raidArrays: unmarshalArrayOfObject(data.raid_arrays, unmarshalRaidArray) };
|
|
813
813
|
};
|
|
814
|
-
|
|
814
|
+
const unmarshalRefund = (data) => {
|
|
815
815
|
if (!isJSONObject(data)) throw new TypeError(`Unmarshalling the type 'Refund' failed as data isn't a dictionary.`);
|
|
816
816
|
return {
|
|
817
817
|
content: data.content,
|
|
@@ -824,7 +824,7 @@ var unmarshalRefund = (data) => {
|
|
|
824
824
|
totalWithoutTaxes: data.total_without_taxes ? unmarshalMoney(data.total_without_taxes) : void 0
|
|
825
825
|
};
|
|
826
826
|
};
|
|
827
|
-
|
|
827
|
+
const unmarshalRescue = (data) => {
|
|
828
828
|
if (!isJSONObject(data)) throw new TypeError(`Unmarshalling the type 'Rescue' failed as data isn't a dictionary.`);
|
|
829
829
|
return {
|
|
830
830
|
login: data.login,
|
|
@@ -833,7 +833,7 @@ var unmarshalRescue = (data) => {
|
|
|
833
833
|
protocol: data.protocol
|
|
834
834
|
};
|
|
835
835
|
};
|
|
836
|
-
|
|
836
|
+
const unmarshalPartition = (data) => {
|
|
837
837
|
if (!isJSONObject(data)) throw new TypeError(`Unmarshalling the type 'Partition' failed as data isn't a dictionary.`);
|
|
838
838
|
return {
|
|
839
839
|
capacity: data.capacity,
|
|
@@ -844,11 +844,11 @@ var unmarshalPartition = (data) => {
|
|
|
844
844
|
type: data.type
|
|
845
845
|
};
|
|
846
846
|
};
|
|
847
|
-
|
|
847
|
+
const unmarshalServerDefaultPartitioning = (data) => {
|
|
848
848
|
if (!isJSONObject(data)) throw new TypeError(`Unmarshalling the type 'ServerDefaultPartitioning' failed as data isn't a dictionary.`);
|
|
849
849
|
return { partitions: unmarshalArrayOfObject(data.partitions, unmarshalPartition) };
|
|
850
850
|
};
|
|
851
|
-
|
|
851
|
+
const unmarshalServerInstall = (data) => {
|
|
852
852
|
if (!isJSONObject(data)) throw new TypeError(`Unmarshalling the type 'ServerInstall' failed as data isn't a dictionary.`);
|
|
853
853
|
return {
|
|
854
854
|
hostname: data.hostname,
|
|
@@ -860,44 +860,44 @@ var unmarshalServerInstall = (data) => {
|
|
|
860
860
|
userLogin: data.user_login
|
|
861
861
|
};
|
|
862
862
|
};
|
|
863
|
-
|
|
863
|
+
const unmarshalSubscribeStorageOptionsResponse = (data) => {
|
|
864
864
|
if (!isJSONObject(data)) throw new TypeError(`Unmarshalling the type 'SubscribeStorageOptionsResponse' failed as data isn't a dictionary.`);
|
|
865
865
|
return { services: unmarshalArrayOfObject(data.services, unmarshalService) };
|
|
866
866
|
};
|
|
867
|
-
|
|
867
|
+
const marshalAttachFailoverIPToMacAddressRequest = (request, defaults) => ({
|
|
868
868
|
mac: request.mac,
|
|
869
869
|
type: request.type
|
|
870
870
|
});
|
|
871
|
-
|
|
871
|
+
const marshalAttachFailoverIPsRequest = (request, defaults) => ({
|
|
872
872
|
fips_ids: request.fipsIds,
|
|
873
873
|
server_id: request.serverId
|
|
874
874
|
});
|
|
875
|
-
|
|
875
|
+
const marshalCreateFailoverIPsRequest = (request, defaults) => ({
|
|
876
876
|
offer_id: request.offerId,
|
|
877
877
|
project_id: request.projectId ?? defaults.defaultProjectId,
|
|
878
878
|
quantity: request.quantity
|
|
879
879
|
});
|
|
880
|
-
|
|
880
|
+
const marshalCreateServerRequest = (request, defaults) => ({
|
|
881
881
|
datacenter_name: request.datacenterName,
|
|
882
882
|
offer_id: request.offerId,
|
|
883
883
|
project_id: request.projectId ?? defaults.defaultProjectId,
|
|
884
884
|
server_option_ids: request.serverOptionIds
|
|
885
885
|
});
|
|
886
|
-
|
|
887
|
-
|
|
888
|
-
|
|
886
|
+
const marshalDetachFailoverIPsRequest = (request, defaults) => ({ fips_ids: request.fipsIds });
|
|
887
|
+
const marshalIPv6BlockApiCreateIPv6BlockRequest = (request, defaults) => ({ project_id: request.projectId ?? defaults.defaultProjectId });
|
|
888
|
+
const marshalIPv6BlockApiCreateIPv6BlockSubnetRequest = (request, defaults) => ({
|
|
889
889
|
address: request.address,
|
|
890
890
|
cidr: request.cidr
|
|
891
891
|
});
|
|
892
|
-
|
|
893
|
-
|
|
892
|
+
const marshalIPv6BlockApiUpdateIPv6BlockRequest = (request, defaults) => ({ nameservers: request.nameservers });
|
|
893
|
+
const marshalInstallPartition = (request, defaults) => ({
|
|
894
894
|
capacity: request.capacity,
|
|
895
895
|
connectors: request.connectors,
|
|
896
896
|
file_system: request.fileSystem,
|
|
897
897
|
mount_point: request.mountPoint,
|
|
898
898
|
raid_level: request.raidLevel
|
|
899
899
|
});
|
|
900
|
-
|
|
900
|
+
const marshalInstallServerRequest = (request, defaults) => ({
|
|
901
901
|
hostname: request.hostname,
|
|
902
902
|
ip_id: request.ipId,
|
|
903
903
|
license_offer_id: request.licenseOfferId,
|
|
@@ -909,62 +909,62 @@ var marshalInstallServerRequest = (request, defaults) => ({
|
|
|
909
909
|
user_login: request.userLogin,
|
|
910
910
|
user_password: request.userPassword
|
|
911
911
|
});
|
|
912
|
-
|
|
913
|
-
|
|
912
|
+
const marshalRpnSanApiAddIpRequest = (request, defaults) => ({ ip_ids: request.ipIds });
|
|
913
|
+
const marshalRpnSanApiCreateRpnSanRequest = (request, defaults) => ({
|
|
914
914
|
offer_id: request.offerId,
|
|
915
915
|
project_id: request.projectId ?? defaults.defaultProjectId
|
|
916
916
|
});
|
|
917
|
-
|
|
918
|
-
|
|
917
|
+
const marshalRpnSanApiRemoveIpRequest = (request, defaults) => ({ ip_ids: request.ipIds });
|
|
918
|
+
const marshalRpnV1ApiAddRpnGroupMembersRequest = (request, defaults) => ({
|
|
919
919
|
san_server_ids: request.sanServerIds,
|
|
920
920
|
server_ids: request.serverIds
|
|
921
921
|
});
|
|
922
|
-
|
|
922
|
+
const marshalRpnV1ApiCreateRpnGroupRequest = (request, defaults) => ({
|
|
923
923
|
name: request.name,
|
|
924
924
|
project_id: request.projectId ?? defaults.defaultProjectId,
|
|
925
925
|
san_server_ids: request.sanServerIds,
|
|
926
926
|
server_ids: request.serverIds
|
|
927
927
|
});
|
|
928
|
-
|
|
929
|
-
|
|
930
|
-
|
|
928
|
+
const marshalRpnV1ApiDeleteRpnGroupMembersRequest = (request, defaults) => ({ member_ids: request.memberIds });
|
|
929
|
+
const marshalRpnV1ApiLeaveRpnGroupRequest = (request, defaults) => ({ member_ids: request.memberIds });
|
|
930
|
+
const marshalRpnV1ApiRpnGroupInviteRequest = (request, defaults) => ({
|
|
931
931
|
project_id: request.projectId ?? defaults.defaultProjectId,
|
|
932
932
|
server_ids: request.serverIds
|
|
933
933
|
});
|
|
934
|
-
|
|
935
|
-
|
|
936
|
-
|
|
934
|
+
const marshalRpnV1ApiUpdateRpnGroupNameRequest = (request, defaults) => ({ name: request.name });
|
|
935
|
+
const marshalRpnV2ApiAddRpnV2MembersRequest = (request, defaults) => ({ servers: request.servers });
|
|
936
|
+
const marshalRpnV2ApiCreateRpnV2GroupRequest = (request, defaults) => ({
|
|
937
937
|
name: request.name,
|
|
938
938
|
project_id: request.projectId ?? defaults.defaultProjectId,
|
|
939
939
|
servers: request.servers,
|
|
940
940
|
type: request.type
|
|
941
941
|
});
|
|
942
|
-
|
|
943
|
-
|
|
944
|
-
|
|
945
|
-
|
|
942
|
+
const marshalRpnV2ApiDeleteRpnV2MembersRequest = (request, defaults) => ({ member_ids: request.memberIds });
|
|
943
|
+
const marshalRpnV2ApiEnableRpnV2GroupCompatibilityRequest = (request, defaults) => ({ rpnv1_group_id: request.rpnv1GroupId });
|
|
944
|
+
const marshalRpnV2ApiUpdateRpnV2GroupNameRequest = (request, defaults) => ({ name: request.name });
|
|
945
|
+
const marshalRpnV2ApiUpdateRpnV2VlanForMembersRequest = (request, defaults) => ({
|
|
946
946
|
member_ids: request.memberIds,
|
|
947
947
|
vlan: request.vlan
|
|
948
948
|
});
|
|
949
|
-
|
|
950
|
-
|
|
951
|
-
|
|
952
|
-
|
|
953
|
-
|
|
949
|
+
const marshalStartBMCAccessRequest = (request, defaults) => ({ ip: request.ip });
|
|
950
|
+
const marshalStartRescueRequest = (request, defaults) => ({ os_id: request.osId });
|
|
951
|
+
const marshalSubscribeServerOptionRequest = (request, defaults) => ({ option_id: request.optionId });
|
|
952
|
+
const marshalSubscribeStorageOptionsRequest = (request, defaults) => ({ options_ids: request.optionsIds });
|
|
953
|
+
const marshalUpdatableRaidArray = (request, defaults) => ({
|
|
954
954
|
disk_ids: request.diskIds,
|
|
955
955
|
raid_level: request.raidLevel
|
|
956
956
|
});
|
|
957
|
-
|
|
958
|
-
|
|
959
|
-
|
|
957
|
+
const marshalUpdateRaidRequest = (request, defaults) => ({ raid_arrays: request.raidArrays.map((elt) => marshalUpdatableRaidArray(elt, defaults)) });
|
|
958
|
+
const marshalUpdateReverseRequest = (request, defaults) => ({ reverse: request.reverse });
|
|
959
|
+
const marshalUpdateServerBackupRequest = (request, defaults) => ({
|
|
960
960
|
acl_enabled: request.aclEnabled,
|
|
961
961
|
autologin: request.autologin,
|
|
962
962
|
password: request.password
|
|
963
963
|
});
|
|
964
|
-
|
|
964
|
+
const marshalUpdateServerRequest = (request, defaults) => ({
|
|
965
965
|
enable_ipv6: request.enableIpv6,
|
|
966
966
|
hostname: request.hostname
|
|
967
967
|
});
|
|
968
|
-
|
|
968
|
+
const marshalUpdateServerTagsRequest = (request, defaults) => ({ tags: request.tags });
|
|
969
969
|
//#endregion
|
|
970
970
|
export { marshalAttachFailoverIPToMacAddressRequest, marshalAttachFailoverIPsRequest, marshalCreateFailoverIPsRequest, marshalCreateServerRequest, marshalDetachFailoverIPsRequest, marshalIPv6BlockApiCreateIPv6BlockRequest, marshalIPv6BlockApiCreateIPv6BlockSubnetRequest, marshalIPv6BlockApiUpdateIPv6BlockRequest, marshalInstallServerRequest, marshalRpnSanApiAddIpRequest, marshalRpnSanApiCreateRpnSanRequest, marshalRpnSanApiRemoveIpRequest, marshalRpnV1ApiAddRpnGroupMembersRequest, marshalRpnV1ApiCreateRpnGroupRequest, marshalRpnV1ApiDeleteRpnGroupMembersRequest, marshalRpnV1ApiLeaveRpnGroupRequest, marshalRpnV1ApiRpnGroupInviteRequest, marshalRpnV1ApiUpdateRpnGroupNameRequest, marshalRpnV2ApiAddRpnV2MembersRequest, marshalRpnV2ApiCreateRpnV2GroupRequest, marshalRpnV2ApiDeleteRpnV2MembersRequest, marshalRpnV2ApiEnableRpnV2GroupCompatibilityRequest, marshalRpnV2ApiUpdateRpnV2GroupNameRequest, marshalRpnV2ApiUpdateRpnV2VlanForMembersRequest, marshalStartBMCAccessRequest, marshalStartRescueRequest, marshalSubscribeServerOptionRequest, marshalSubscribeStorageOptionsRequest, marshalUpdateRaidRequest, marshalUpdateReverseRequest, marshalUpdateServerBackupRequest, marshalUpdateServerRequest, marshalUpdateServerTagsRequest, unmarshalBMCAccess, unmarshalBackup, unmarshalCanOrderResponse, unmarshalCreateFailoverIPsResponse, unmarshalFailoverIP, unmarshalGetIPv6BlockQuotasResponse, unmarshalGetRemainingQuotaResponse, unmarshalGetRpnStatusResponse, unmarshalIP, unmarshalIPv6Block, unmarshalInvoice, unmarshalListFailoverIPsResponse, unmarshalListIPv6BlockSubnetsAvailableResponse, unmarshalListIPv6BlocksResponse, unmarshalListInvoicesResponse, unmarshalListIpsResponse, unmarshalListOSResponse, unmarshalListOffersResponse, unmarshalListRefundsResponse, unmarshalListRpnCapableSanServersResponse, unmarshalListRpnCapableServersResponse, unmarshalListRpnGroupMembersResponse, unmarshalListRpnGroupsResponse, unmarshalListRpnInvitesResponse, unmarshalListRpnSansResponse, unmarshalListRpnServerCapabilitiesResponse, unmarshalListRpnV2CapableResourcesResponse, unmarshalListRpnV2GroupLogsResponse, unmarshalListRpnV2GroupsResponse, unmarshalListRpnV2MembersResponse, unmarshalListServerDisksResponse, unmarshalListServerEventsResponse, unmarshalListServersResponse, unmarshalListServicesResponse, unmarshalListSubscribableServerOptionsResponse, unmarshalOS, unmarshalOffer, unmarshalRaid, unmarshalRefund, unmarshalRescue, unmarshalRpnGroup, unmarshalRpnSan, unmarshalRpnV2Group, unmarshalServer, unmarshalServerDefaultPartitioning, unmarshalServerInstall, unmarshalService, unmarshalSubscribeStorageOptionsResponse };
|