latitudesh-typescript-sdk 0.8.1 → 0.8.3
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/bin/mcp-server.js +728 -510
- package/bin/mcp-server.js.map +19 -18
- package/dist/commonjs/funcs/plansListStorage.d.ts +2 -1
- package/dist/commonjs/funcs/plansListStorage.d.ts.map +1 -1
- package/dist/commonjs/funcs/plansListStorage.js +18 -3
- package/dist/commonjs/funcs/plansListStorage.js.map +1 -1
- package/dist/commonjs/lib/config.d.ts +3 -3
- package/dist/commonjs/lib/config.js +3 -3
- package/dist/commonjs/mcp-server/mcp-server.js +1 -1
- package/dist/commonjs/mcp-server/server.js +1 -1
- package/dist/commonjs/mcp-server/tools/plansListStorage.d.ts +6 -1
- package/dist/commonjs/mcp-server/tools/plansListStorage.d.ts.map +1 -1
- package/dist/commonjs/mcp-server/tools/plansListStorage.js +40 -2
- package/dist/commonjs/mcp-server/tools/plansListStorage.js.map +1 -1
- package/dist/commonjs/models/eventdata.d.ts +2 -2
- package/dist/commonjs/models/eventdata.d.ts.map +1 -1
- package/dist/commonjs/models/eventdata.js +2 -2
- package/dist/commonjs/models/eventdata.js.map +1 -1
- package/dist/commonjs/models/operations/getstorageplans.d.ts +25 -0
- package/dist/commonjs/models/operations/getstorageplans.d.ts.map +1 -0
- package/dist/commonjs/models/operations/getstorageplans.js +71 -0
- package/dist/commonjs/models/operations/getstorageplans.js.map +1 -0
- package/dist/commonjs/models/operations/index.d.ts +1 -0
- package/dist/commonjs/models/operations/index.d.ts.map +1 -1
- package/dist/commonjs/models/operations/index.js +1 -0
- package/dist/commonjs/models/operations/index.js.map +1 -1
- package/dist/commonjs/models/operations/updateproject.d.ts +4 -4
- package/dist/commonjs/models/operations/updateproject.d.ts.map +1 -1
- package/dist/commonjs/models/operations/updateproject.js +8 -8
- package/dist/commonjs/models/operations/updateproject.js.map +1 -1
- package/dist/commonjs/models/outofbandconnection.d.ts +8 -8
- package/dist/commonjs/models/outofbandconnection.d.ts.map +1 -1
- package/dist/commonjs/models/outofbandconnection.js +11 -12
- package/dist/commonjs/models/outofbandconnection.js.map +1 -1
- package/dist/commonjs/models/storageplandata.d.ts +70 -5
- package/dist/commonjs/models/storageplandata.d.ts.map +1 -1
- package/dist/commonjs/models/storageplandata.js +101 -5
- package/dist/commonjs/models/storageplandata.js.map +1 -1
- package/dist/commonjs/models/userteam.d.ts +53 -0
- package/dist/commonjs/models/userteam.d.ts.map +1 -1
- package/dist/commonjs/models/userteam.js +79 -1
- package/dist/commonjs/models/userteam.js.map +1 -1
- package/dist/commonjs/models/virtualmachineattributes.d.ts +32 -9
- package/dist/commonjs/models/virtualmachineattributes.d.ts.map +1 -1
- package/dist/commonjs/models/virtualmachineattributes.js +47 -9
- package/dist/commonjs/models/virtualmachineattributes.js.map +1 -1
- package/dist/commonjs/models/virtualmachinepayload.d.ts +21 -0
- package/dist/commonjs/models/virtualmachinepayload.d.ts.map +1 -1
- package/dist/commonjs/models/virtualmachinepayload.js +15 -1
- package/dist/commonjs/models/virtualmachinepayload.js.map +1 -1
- package/dist/commonjs/models/virtualmachineupdatepayload.d.ts +5 -5
- package/dist/commonjs/models/virtualmachineupdatepayload.d.ts.map +1 -1
- package/dist/commonjs/models/virtualmachineupdatepayload.js +6 -7
- package/dist/commonjs/models/virtualmachineupdatepayload.js.map +1 -1
- package/dist/commonjs/models/volumedata.d.ts +15 -0
- package/dist/commonjs/models/volumedata.d.ts.map +1 -1
- package/dist/commonjs/models/volumedata.js +10 -0
- package/dist/commonjs/models/volumedata.js.map +1 -1
- package/dist/commonjs/sdk/plans.d.ts +1 -1
- package/dist/commonjs/sdk/plans.d.ts.map +1 -1
- package/dist/commonjs/sdk/plans.js +2 -2
- package/dist/commonjs/sdk/plans.js.map +1 -1
- package/dist/esm/funcs/plansListStorage.d.ts +2 -1
- package/dist/esm/funcs/plansListStorage.d.ts.map +1 -1
- package/dist/esm/funcs/plansListStorage.js +18 -3
- package/dist/esm/funcs/plansListStorage.js.map +1 -1
- package/dist/esm/lib/config.d.ts +3 -3
- package/dist/esm/lib/config.js +3 -3
- package/dist/esm/mcp-server/mcp-server.js +1 -1
- package/dist/esm/mcp-server/server.js +1 -1
- package/dist/esm/mcp-server/tools/plansListStorage.d.ts +6 -1
- package/dist/esm/mcp-server/tools/plansListStorage.d.ts.map +1 -1
- package/dist/esm/mcp-server/tools/plansListStorage.js +7 -2
- package/dist/esm/mcp-server/tools/plansListStorage.js.map +1 -1
- package/dist/esm/models/eventdata.d.ts +2 -2
- package/dist/esm/models/eventdata.d.ts.map +1 -1
- package/dist/esm/models/eventdata.js +2 -2
- package/dist/esm/models/eventdata.js.map +1 -1
- package/dist/esm/models/operations/getstorageplans.d.ts +25 -0
- package/dist/esm/models/operations/getstorageplans.d.ts.map +1 -0
- package/dist/esm/models/operations/getstorageplans.js +33 -0
- package/dist/esm/models/operations/getstorageplans.js.map +1 -0
- package/dist/esm/models/operations/index.d.ts +1 -0
- package/dist/esm/models/operations/index.d.ts.map +1 -1
- package/dist/esm/models/operations/index.js +1 -0
- package/dist/esm/models/operations/index.js.map +1 -1
- package/dist/esm/models/operations/updateproject.d.ts +4 -4
- package/dist/esm/models/operations/updateproject.d.ts.map +1 -1
- package/dist/esm/models/operations/updateproject.js +8 -8
- package/dist/esm/models/operations/updateproject.js.map +1 -1
- package/dist/esm/models/outofbandconnection.d.ts +8 -8
- package/dist/esm/models/outofbandconnection.d.ts.map +1 -1
- package/dist/esm/models/outofbandconnection.js +8 -9
- package/dist/esm/models/outofbandconnection.js.map +1 -1
- package/dist/esm/models/storageplandata.d.ts +70 -5
- package/dist/esm/models/storageplandata.d.ts.map +1 -1
- package/dist/esm/models/storageplandata.js +94 -4
- package/dist/esm/models/storageplandata.js.map +1 -1
- package/dist/esm/models/userteam.d.ts +53 -0
- package/dist/esm/models/userteam.d.ts.map +1 -1
- package/dist/esm/models/userteam.js +76 -0
- package/dist/esm/models/userteam.js.map +1 -1
- package/dist/esm/models/virtualmachineattributes.d.ts +32 -9
- package/dist/esm/models/virtualmachineattributes.d.ts.map +1 -1
- package/dist/esm/models/virtualmachineattributes.js +44 -8
- package/dist/esm/models/virtualmachineattributes.js.map +1 -1
- package/dist/esm/models/virtualmachinepayload.d.ts +21 -0
- package/dist/esm/models/virtualmachinepayload.d.ts.map +1 -1
- package/dist/esm/models/virtualmachinepayload.js +14 -0
- package/dist/esm/models/virtualmachinepayload.js.map +1 -1
- package/dist/esm/models/virtualmachineupdatepayload.d.ts +5 -5
- package/dist/esm/models/virtualmachineupdatepayload.d.ts.map +1 -1
- package/dist/esm/models/virtualmachineupdatepayload.js +5 -6
- package/dist/esm/models/virtualmachineupdatepayload.js.map +1 -1
- package/dist/esm/models/volumedata.d.ts +15 -0
- package/dist/esm/models/volumedata.d.ts.map +1 -1
- package/dist/esm/models/volumedata.js +10 -0
- package/dist/esm/models/volumedata.js.map +1 -1
- package/dist/esm/sdk/plans.d.ts +1 -1
- package/dist/esm/sdk/plans.d.ts.map +1 -1
- package/dist/esm/sdk/plans.js +2 -2
- package/dist/esm/sdk/plans.js.map +1 -1
- package/jsr.json +1 -1
- package/package.json +3 -3
- package/src/funcs/plansListStorage.ts +25 -0
- package/src/lib/config.ts +3 -3
- package/src/mcp-server/mcp-server.ts +1 -1
- package/src/mcp-server/server.ts +1 -1
- package/src/mcp-server/tools/plansListStorage.ts +9 -2
- package/src/models/eventdata.ts +4 -4
- package/src/models/operations/getstorageplans.ts +72 -0
- package/src/models/operations/index.ts +1 -0
- package/src/models/operations/updateproject.ts +12 -16
- package/src/models/outofbandconnection.ts +28 -21
- package/src/models/storageplandata.ts +211 -10
- package/src/models/userteam.ts +142 -0
- package/src/models/virtualmachineattributes.ts +98 -17
- package/src/models/virtualmachinepayload.ts +31 -0
- package/src/models/virtualmachineupdatepayload.ts +13 -9
- package/src/models/volumedata.ts +25 -0
- package/src/sdk/plans.ts +2 -0
- package/tests/integration/projects.test.ts +3 -0
|
@@ -98,17 +98,26 @@ export type VirtualMachineAttributesOperatingSystem = {
|
|
|
98
98
|
distro?: VirtualMachineAttributesDistro | undefined;
|
|
99
99
|
};
|
|
100
100
|
|
|
101
|
+
export type VirtualMachineAttributesSshKey = {
|
|
102
|
+
id?: string | undefined;
|
|
103
|
+
name?: string | undefined;
|
|
104
|
+
fingerprint?: string | undefined;
|
|
105
|
+
publicKey?: string | undefined;
|
|
106
|
+
createdAt?: string | undefined;
|
|
107
|
+
updatedAt?: string | undefined;
|
|
108
|
+
};
|
|
109
|
+
|
|
101
110
|
/**
|
|
102
111
|
* SSH credentials for connecting to the virtual machine. Only available when the VM is running. Opt-in extra field: request via `extra_fields[virtual_machines]=credentials`.
|
|
103
112
|
*/
|
|
104
113
|
export type VirtualMachineAttributesCredentials = {
|
|
105
114
|
/**
|
|
106
|
-
* The SSH username for the VM, determined by the operating system (e.g., ubuntu, centos, ec2-user). Defaults to ubuntu if not specified by the OS.
|
|
115
|
+
* The SSH username for the VM, determined by the operating system (e.g., ubuntu, centos, ec2-user). Defaults to ubuntu if not specified by the OS. Returns null when the VM is not running.
|
|
107
116
|
*/
|
|
108
|
-
username?: string | undefined;
|
|
109
|
-
host?: string | undefined;
|
|
110
|
-
password?: string | undefined;
|
|
111
|
-
sshKeys?: Array<
|
|
117
|
+
username?: string | null | undefined;
|
|
118
|
+
host?: string | null | undefined;
|
|
119
|
+
password?: string | null | undefined;
|
|
120
|
+
sshKeys?: Array<VirtualMachineAttributesSshKey> | null | undefined;
|
|
112
121
|
};
|
|
113
122
|
|
|
114
123
|
export type VirtualMachineAttributesPlan = {
|
|
@@ -352,16 +361,86 @@ export function virtualMachineAttributesOperatingSystemFromJSON(
|
|
|
352
361
|
);
|
|
353
362
|
}
|
|
354
363
|
|
|
364
|
+
/** @internal */
|
|
365
|
+
export const VirtualMachineAttributesSshKey$inboundSchema: z.ZodType<
|
|
366
|
+
VirtualMachineAttributesSshKey,
|
|
367
|
+
z.ZodTypeDef,
|
|
368
|
+
unknown
|
|
369
|
+
> = z.object({
|
|
370
|
+
id: z.string().optional(),
|
|
371
|
+
name: z.string().optional(),
|
|
372
|
+
fingerprint: z.string().optional(),
|
|
373
|
+
public_key: z.string().optional(),
|
|
374
|
+
created_at: z.string().optional(),
|
|
375
|
+
updated_at: z.string().optional(),
|
|
376
|
+
}).transform((v) => {
|
|
377
|
+
return remap$(v, {
|
|
378
|
+
"public_key": "publicKey",
|
|
379
|
+
"created_at": "createdAt",
|
|
380
|
+
"updated_at": "updatedAt",
|
|
381
|
+
});
|
|
382
|
+
});
|
|
383
|
+
/** @internal */
|
|
384
|
+
export type VirtualMachineAttributesSshKey$Outbound = {
|
|
385
|
+
id?: string | undefined;
|
|
386
|
+
name?: string | undefined;
|
|
387
|
+
fingerprint?: string | undefined;
|
|
388
|
+
public_key?: string | undefined;
|
|
389
|
+
created_at?: string | undefined;
|
|
390
|
+
updated_at?: string | undefined;
|
|
391
|
+
};
|
|
392
|
+
|
|
393
|
+
/** @internal */
|
|
394
|
+
export const VirtualMachineAttributesSshKey$outboundSchema: z.ZodType<
|
|
395
|
+
VirtualMachineAttributesSshKey$Outbound,
|
|
396
|
+
z.ZodTypeDef,
|
|
397
|
+
VirtualMachineAttributesSshKey
|
|
398
|
+
> = z.object({
|
|
399
|
+
id: z.string().optional(),
|
|
400
|
+
name: z.string().optional(),
|
|
401
|
+
fingerprint: z.string().optional(),
|
|
402
|
+
publicKey: z.string().optional(),
|
|
403
|
+
createdAt: z.string().optional(),
|
|
404
|
+
updatedAt: z.string().optional(),
|
|
405
|
+
}).transform((v) => {
|
|
406
|
+
return remap$(v, {
|
|
407
|
+
publicKey: "public_key",
|
|
408
|
+
createdAt: "created_at",
|
|
409
|
+
updatedAt: "updated_at",
|
|
410
|
+
});
|
|
411
|
+
});
|
|
412
|
+
|
|
413
|
+
export function virtualMachineAttributesSshKeyToJSON(
|
|
414
|
+
virtualMachineAttributesSshKey: VirtualMachineAttributesSshKey,
|
|
415
|
+
): string {
|
|
416
|
+
return JSON.stringify(
|
|
417
|
+
VirtualMachineAttributesSshKey$outboundSchema.parse(
|
|
418
|
+
virtualMachineAttributesSshKey,
|
|
419
|
+
),
|
|
420
|
+
);
|
|
421
|
+
}
|
|
422
|
+
export function virtualMachineAttributesSshKeyFromJSON(
|
|
423
|
+
jsonString: string,
|
|
424
|
+
): SafeParseResult<VirtualMachineAttributesSshKey, SDKValidationError> {
|
|
425
|
+
return safeParse(
|
|
426
|
+
jsonString,
|
|
427
|
+
(x) => VirtualMachineAttributesSshKey$inboundSchema.parse(JSON.parse(x)),
|
|
428
|
+
`Failed to parse 'VirtualMachineAttributesSshKey' from JSON`,
|
|
429
|
+
);
|
|
430
|
+
}
|
|
431
|
+
|
|
355
432
|
/** @internal */
|
|
356
433
|
export const VirtualMachineAttributesCredentials$inboundSchema: z.ZodType<
|
|
357
434
|
VirtualMachineAttributesCredentials,
|
|
358
435
|
z.ZodTypeDef,
|
|
359
436
|
unknown
|
|
360
437
|
> = z.object({
|
|
361
|
-
username: z.string().optional(),
|
|
362
|
-
host: z.string().optional(),
|
|
363
|
-
password: z.string().optional(),
|
|
364
|
-
ssh_keys: z.
|
|
438
|
+
username: z.nullable(z.string()).optional(),
|
|
439
|
+
host: z.nullable(z.string()).optional(),
|
|
440
|
+
password: z.nullable(z.string()).optional(),
|
|
441
|
+
ssh_keys: z.nullable(
|
|
442
|
+
z.array(z.lazy(() => VirtualMachineAttributesSshKey$inboundSchema)),
|
|
443
|
+
).optional(),
|
|
365
444
|
}).transform((v) => {
|
|
366
445
|
return remap$(v, {
|
|
367
446
|
"ssh_keys": "sshKeys",
|
|
@@ -369,10 +448,10 @@ export const VirtualMachineAttributesCredentials$inboundSchema: z.ZodType<
|
|
|
369
448
|
});
|
|
370
449
|
/** @internal */
|
|
371
450
|
export type VirtualMachineAttributesCredentials$Outbound = {
|
|
372
|
-
username?: string | undefined;
|
|
373
|
-
host?: string | undefined;
|
|
374
|
-
password?: string | undefined;
|
|
375
|
-
ssh_keys?: Array<
|
|
451
|
+
username?: string | null | undefined;
|
|
452
|
+
host?: string | null | undefined;
|
|
453
|
+
password?: string | null | undefined;
|
|
454
|
+
ssh_keys?: Array<VirtualMachineAttributesSshKey$Outbound> | null | undefined;
|
|
376
455
|
};
|
|
377
456
|
|
|
378
457
|
/** @internal */
|
|
@@ -381,10 +460,12 @@ export const VirtualMachineAttributesCredentials$outboundSchema: z.ZodType<
|
|
|
381
460
|
z.ZodTypeDef,
|
|
382
461
|
VirtualMachineAttributesCredentials
|
|
383
462
|
> = z.object({
|
|
384
|
-
username: z.string().optional(),
|
|
385
|
-
host: z.string().optional(),
|
|
386
|
-
password: z.string().optional(),
|
|
387
|
-
sshKeys: z.
|
|
463
|
+
username: z.nullable(z.string()).optional(),
|
|
464
|
+
host: z.nullable(z.string()).optional(),
|
|
465
|
+
password: z.nullable(z.string()).optional(),
|
|
466
|
+
sshKeys: z.nullable(
|
|
467
|
+
z.array(z.lazy(() => VirtualMachineAttributesSshKey$outboundSchema)),
|
|
468
|
+
).optional(),
|
|
388
469
|
}).transform((v) => {
|
|
389
470
|
return remap$(v, {
|
|
390
471
|
sshKeys: "ssh_keys",
|
|
@@ -16,6 +16,21 @@ export type VirtualMachinePayloadType = ClosedEnum<
|
|
|
16
16
|
typeof VirtualMachinePayloadType
|
|
17
17
|
>;
|
|
18
18
|
|
|
19
|
+
/**
|
|
20
|
+
* Billing cycle for the VM. The supported set is validated per-project (on_demand vs reserved). Defaults to the project's default billing when omitted.
|
|
21
|
+
*/
|
|
22
|
+
export const VirtualMachinePayloadBilling = {
|
|
23
|
+
Hourly: "hourly",
|
|
24
|
+
Monthly: "monthly",
|
|
25
|
+
Yearly: "yearly",
|
|
26
|
+
} as const;
|
|
27
|
+
/**
|
|
28
|
+
* Billing cycle for the VM. The supported set is validated per-project (on_demand vs reserved). Defaults to the project's default billing when omitted.
|
|
29
|
+
*/
|
|
30
|
+
export type VirtualMachinePayloadBilling = ClosedEnum<
|
|
31
|
+
typeof VirtualMachinePayloadBilling
|
|
32
|
+
>;
|
|
33
|
+
|
|
19
34
|
/**
|
|
20
35
|
* A user data record reference (encoded id_hash, e.g. 'ud_xxx', or raw integer id) to apply as cloud-init configuration
|
|
21
36
|
*/
|
|
@@ -23,6 +38,10 @@ export type UserDataUnion = number | string;
|
|
|
23
38
|
|
|
24
39
|
export type VirtualMachinePayloadAttributes = {
|
|
25
40
|
name?: string | undefined;
|
|
41
|
+
/**
|
|
42
|
+
* Billing cycle for the VM. The supported set is validated per-project (on_demand vs reserved). Defaults to the project's default billing when omitted.
|
|
43
|
+
*/
|
|
44
|
+
billing?: VirtualMachinePayloadBilling | undefined;
|
|
26
45
|
/**
|
|
27
46
|
* The plan ID or Slug for the Virtual Machine
|
|
28
47
|
*/
|
|
@@ -65,6 +84,15 @@ export const VirtualMachinePayloadType$outboundSchema: z.ZodNativeEnum<
|
|
|
65
84
|
typeof VirtualMachinePayloadType
|
|
66
85
|
> = VirtualMachinePayloadType$inboundSchema;
|
|
67
86
|
|
|
87
|
+
/** @internal */
|
|
88
|
+
export const VirtualMachinePayloadBilling$inboundSchema: z.ZodNativeEnum<
|
|
89
|
+
typeof VirtualMachinePayloadBilling
|
|
90
|
+
> = z.nativeEnum(VirtualMachinePayloadBilling);
|
|
91
|
+
/** @internal */
|
|
92
|
+
export const VirtualMachinePayloadBilling$outboundSchema: z.ZodNativeEnum<
|
|
93
|
+
typeof VirtualMachinePayloadBilling
|
|
94
|
+
> = VirtualMachinePayloadBilling$inboundSchema;
|
|
95
|
+
|
|
68
96
|
/** @internal */
|
|
69
97
|
export const UserDataUnion$inboundSchema: z.ZodType<
|
|
70
98
|
UserDataUnion,
|
|
@@ -101,6 +129,7 @@ export const VirtualMachinePayloadAttributes$inboundSchema: z.ZodType<
|
|
|
101
129
|
unknown
|
|
102
130
|
> = z.object({
|
|
103
131
|
name: z.string().default("my-vm"),
|
|
132
|
+
billing: VirtualMachinePayloadBilling$inboundSchema.optional(),
|
|
104
133
|
plan: z.nullable(z.string()).optional(),
|
|
105
134
|
ssh_keys: z.nullable(z.array(z.string())).optional(),
|
|
106
135
|
project: z.string().default("my-project"),
|
|
@@ -118,6 +147,7 @@ export const VirtualMachinePayloadAttributes$inboundSchema: z.ZodType<
|
|
|
118
147
|
/** @internal */
|
|
119
148
|
export type VirtualMachinePayloadAttributes$Outbound = {
|
|
120
149
|
name: string;
|
|
150
|
+
billing?: string | undefined;
|
|
121
151
|
plan?: string | null | undefined;
|
|
122
152
|
ssh_keys?: Array<string> | null | undefined;
|
|
123
153
|
project: string;
|
|
@@ -134,6 +164,7 @@ export const VirtualMachinePayloadAttributes$outboundSchema: z.ZodType<
|
|
|
134
164
|
VirtualMachinePayloadAttributes
|
|
135
165
|
> = z.object({
|
|
136
166
|
name: z.string().default("my-vm"),
|
|
167
|
+
billing: VirtualMachinePayloadBilling$outboundSchema.optional(),
|
|
137
168
|
plan: z.nullable(z.string()).optional(),
|
|
138
169
|
sshKeys: z.nullable(z.array(z.string())).optional(),
|
|
139
170
|
project: z.string().default("my-project"),
|
|
@@ -18,7 +18,7 @@ export type VirtualMachineUpdatePayloadType = ClosedEnum<
|
|
|
18
18
|
/**
|
|
19
19
|
* Target billing cycle. Upgrades only (hourly → monthly → yearly); downgrades and reserved-project changes return 422.
|
|
20
20
|
*/
|
|
21
|
-
export const
|
|
21
|
+
export const VirtualMachineUpdatePayloadBilling = {
|
|
22
22
|
Hourly: "hourly",
|
|
23
23
|
Monthly: "monthly",
|
|
24
24
|
Yearly: "yearly",
|
|
@@ -26,7 +26,9 @@ export const BillingEnum = {
|
|
|
26
26
|
/**
|
|
27
27
|
* Target billing cycle. Upgrades only (hourly → monthly → yearly); downgrades and reserved-project changes return 422.
|
|
28
28
|
*/
|
|
29
|
-
export type
|
|
29
|
+
export type VirtualMachineUpdatePayloadBilling = ClosedEnum<
|
|
30
|
+
typeof VirtualMachineUpdatePayloadBilling
|
|
31
|
+
>;
|
|
30
32
|
|
|
31
33
|
export type VirtualMachineUpdatePayloadAttributes = {
|
|
32
34
|
/**
|
|
@@ -40,7 +42,7 @@ export type VirtualMachineUpdatePayloadAttributes = {
|
|
|
40
42
|
/**
|
|
41
43
|
* Target billing cycle. Upgrades only (hourly → monthly → yearly); downgrades and reserved-project changes return 422.
|
|
42
44
|
*/
|
|
43
|
-
billing?:
|
|
45
|
+
billing?: VirtualMachineUpdatePayloadBilling | undefined;
|
|
44
46
|
/**
|
|
45
47
|
* Target plan slug for a vertical upgrade. Upgrades only (cpu, memory, and/or storage must scale up; nothing may shrink). The VM is powered off to apply the new resources and powered back on. Must be sent on its own (cannot be combined with name, tags, or billing). Returns 202 Accepted.
|
|
46
48
|
*/
|
|
@@ -67,11 +69,13 @@ export const VirtualMachineUpdatePayloadType$outboundSchema: z.ZodNativeEnum<
|
|
|
67
69
|
> = VirtualMachineUpdatePayloadType$inboundSchema;
|
|
68
70
|
|
|
69
71
|
/** @internal */
|
|
70
|
-
export const
|
|
71
|
-
|
|
72
|
+
export const VirtualMachineUpdatePayloadBilling$inboundSchema: z.ZodNativeEnum<
|
|
73
|
+
typeof VirtualMachineUpdatePayloadBilling
|
|
74
|
+
> = z.nativeEnum(VirtualMachineUpdatePayloadBilling);
|
|
72
75
|
/** @internal */
|
|
73
|
-
export const
|
|
74
|
-
|
|
76
|
+
export const VirtualMachineUpdatePayloadBilling$outboundSchema: z.ZodNativeEnum<
|
|
77
|
+
typeof VirtualMachineUpdatePayloadBilling
|
|
78
|
+
> = VirtualMachineUpdatePayloadBilling$inboundSchema;
|
|
75
79
|
|
|
76
80
|
/** @internal */
|
|
77
81
|
export const VirtualMachineUpdatePayloadAttributes$inboundSchema: z.ZodType<
|
|
@@ -81,7 +85,7 @@ export const VirtualMachineUpdatePayloadAttributes$inboundSchema: z.ZodType<
|
|
|
81
85
|
> = z.object({
|
|
82
86
|
name: z.string().optional(),
|
|
83
87
|
tags: z.nullable(z.array(z.string())).optional(),
|
|
84
|
-
billing:
|
|
88
|
+
billing: VirtualMachineUpdatePayloadBilling$inboundSchema.optional(),
|
|
85
89
|
plan: z.string().optional(),
|
|
86
90
|
});
|
|
87
91
|
/** @internal */
|
|
@@ -100,7 +104,7 @@ export const VirtualMachineUpdatePayloadAttributes$outboundSchema: z.ZodType<
|
|
|
100
104
|
> = z.object({
|
|
101
105
|
name: z.string().optional(),
|
|
102
106
|
tags: z.nullable(z.array(z.string())).optional(),
|
|
103
|
-
billing:
|
|
107
|
+
billing: VirtualMachineUpdatePayloadBilling$outboundSchema.optional(),
|
|
104
108
|
plan: z.string().optional(),
|
|
105
109
|
});
|
|
106
110
|
|
package/src/models/volumedata.ts
CHANGED
|
@@ -37,6 +37,18 @@ export type VolumeDataAttributes = {
|
|
|
37
37
|
namespaceId?: string | null | undefined;
|
|
38
38
|
connectorId?: string | null | undefined;
|
|
39
39
|
initiators?: Array<Initiator> | null | undefined;
|
|
40
|
+
/**
|
|
41
|
+
* Cephx keyring secret used to connect to the volume. Returned only for dashboard-origin requests; null until the volume is provisioned.
|
|
42
|
+
*/
|
|
43
|
+
keyring?: string | null | undefined;
|
|
44
|
+
/**
|
|
45
|
+
* Ceph cluster user used to connect to the volume. Returned only for dashboard-origin requests; null until the volume is provisioned.
|
|
46
|
+
*/
|
|
47
|
+
clusterUser?: string | null | undefined;
|
|
48
|
+
/**
|
|
49
|
+
* Path of the volume inside the cluster. Returned only for dashboard-origin requests; null until the volume is provisioned.
|
|
50
|
+
*/
|
|
51
|
+
volumePath?: string | null | undefined;
|
|
40
52
|
project?: ProjectInclude | undefined;
|
|
41
53
|
team?: TeamInclude | undefined;
|
|
42
54
|
};
|
|
@@ -106,6 +118,9 @@ export const VolumeDataAttributes$inboundSchema: z.ZodType<
|
|
|
106
118
|
connector_id: z.nullable(z.string()).optional(),
|
|
107
119
|
initiators: z.nullable(z.array(z.lazy(() => Initiator$inboundSchema)))
|
|
108
120
|
.optional(),
|
|
121
|
+
keyring: z.nullable(z.string()).optional(),
|
|
122
|
+
cluster_user: z.nullable(z.string()).optional(),
|
|
123
|
+
volume_path: z.nullable(z.string()).optional(),
|
|
109
124
|
project: ProjectInclude$inboundSchema.optional(),
|
|
110
125
|
team: TeamInclude$inboundSchema.optional(),
|
|
111
126
|
}).transform((v) => {
|
|
@@ -114,6 +129,8 @@ export const VolumeDataAttributes$inboundSchema: z.ZodType<
|
|
|
114
129
|
"created_at": "createdAt",
|
|
115
130
|
"namespace_id": "namespaceId",
|
|
116
131
|
"connector_id": "connectorId",
|
|
132
|
+
"cluster_user": "clusterUser",
|
|
133
|
+
"volume_path": "volumePath",
|
|
117
134
|
});
|
|
118
135
|
});
|
|
119
136
|
/** @internal */
|
|
@@ -124,6 +141,9 @@ export type VolumeDataAttributes$Outbound = {
|
|
|
124
141
|
namespace_id?: string | null | undefined;
|
|
125
142
|
connector_id?: string | null | undefined;
|
|
126
143
|
initiators?: Array<Initiator$Outbound> | null | undefined;
|
|
144
|
+
keyring?: string | null | undefined;
|
|
145
|
+
cluster_user?: string | null | undefined;
|
|
146
|
+
volume_path?: string | null | undefined;
|
|
127
147
|
project?: ProjectInclude$Outbound | undefined;
|
|
128
148
|
team?: TeamInclude$Outbound | undefined;
|
|
129
149
|
};
|
|
@@ -141,6 +161,9 @@ export const VolumeDataAttributes$outboundSchema: z.ZodType<
|
|
|
141
161
|
connectorId: z.nullable(z.string()).optional(),
|
|
142
162
|
initiators: z.nullable(z.array(z.lazy(() => Initiator$outboundSchema)))
|
|
143
163
|
.optional(),
|
|
164
|
+
keyring: z.nullable(z.string()).optional(),
|
|
165
|
+
clusterUser: z.nullable(z.string()).optional(),
|
|
166
|
+
volumePath: z.nullable(z.string()).optional(),
|
|
144
167
|
project: ProjectInclude$outboundSchema.optional(),
|
|
145
168
|
team: TeamInclude$outboundSchema.optional(),
|
|
146
169
|
}).transform((v) => {
|
|
@@ -149,6 +172,8 @@ export const VolumeDataAttributes$outboundSchema: z.ZodType<
|
|
|
149
172
|
createdAt: "created_at",
|
|
150
173
|
namespaceId: "namespace_id",
|
|
151
174
|
connectorId: "connector_id",
|
|
175
|
+
clusterUser: "cluster_user",
|
|
176
|
+
volumePath: "volume_path",
|
|
152
177
|
});
|
|
153
178
|
});
|
|
154
179
|
|
package/src/sdk/plans.ts
CHANGED
|
@@ -92,10 +92,12 @@ export class Plans extends ClientSDK {
|
|
|
92
92
|
* List storage plans
|
|
93
93
|
*/
|
|
94
94
|
async listStorage(
|
|
95
|
+
request?: operations.GetStoragePlansRequest | undefined,
|
|
95
96
|
options?: RequestOptions,
|
|
96
97
|
): Promise<models.StoragePlans> {
|
|
97
98
|
return unwrapAsync(plansListStorage(
|
|
98
99
|
this,
|
|
100
|
+
request,
|
|
99
101
|
options,
|
|
100
102
|
));
|
|
101
103
|
}
|
|
@@ -293,6 +293,7 @@ describe('Projects - Core CRUD Operations', () => {
|
|
|
293
293
|
projectId: 'proj_test123',
|
|
294
294
|
requestBody: {
|
|
295
295
|
data: {
|
|
296
|
+
id: 'proj_test123',
|
|
296
297
|
type: 'projects',
|
|
297
298
|
attributes: {
|
|
298
299
|
name: 'Updated Project Name',
|
|
@@ -331,6 +332,7 @@ describe('Projects - Core CRUD Operations', () => {
|
|
|
331
332
|
projectId: 'proj_test123',
|
|
332
333
|
requestBody: {
|
|
333
334
|
data: {
|
|
335
|
+
id: 'proj_test123',
|
|
334
336
|
type: 'projects',
|
|
335
337
|
attributes: {
|
|
336
338
|
environment: 'Production',
|
|
@@ -364,6 +366,7 @@ describe('Projects - Core CRUD Operations', () => {
|
|
|
364
366
|
projectId: 'proj_nonexistent',
|
|
365
367
|
requestBody: {
|
|
366
368
|
data: {
|
|
369
|
+
id: 'proj_nonexistent',
|
|
367
370
|
type: 'projects',
|
|
368
371
|
attributes: {
|
|
369
372
|
name: 'Updated Name',
|