@phala/cloud 0.2.8 → 0.2.10

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.
Files changed (39) hide show
  1. package/dist/actions/apps/check_app_cvms_is_allowed.d.ts +315 -5
  2. package/dist/actions/apps/check_app_is_allowed.d.ts +2 -2
  3. package/dist/actions/apps/create_app_instance.d.ts +205 -0
  4. package/dist/actions/apps/get_app_attestation.d.ts +50 -0
  5. package/dist/actions/apps/get_app_device_allowlist.d.ts +274 -5
  6. package/dist/actions/apps/get_app_filter_options.d.ts +2 -2
  7. package/dist/actions/cvms/check_cvm_is_allowed.d.ts +133 -3
  8. package/dist/actions/cvms/commit_cvm_provision.d.ts +425 -148
  9. package/dist/actions/cvms/get_cvm_compose_file.d.ts +328 -0
  10. package/dist/actions/cvms/get_prelaunch_script_upgrade_status.d.ts +93 -0
  11. package/dist/actions/cvms/provision_cvm.d.ts +243 -225
  12. package/dist/actions/cvms/provision_cvm_compose_file_update.d.ts +216 -0
  13. package/dist/actions/cvms/refresh_cvm_instance_id.d.ts +123 -5
  14. package/dist/actions/cvms/refresh_cvm_instance_ids.d.ts +236 -7
  15. package/dist/actions/cvms/replicate_cvm.d.ts +4 -4
  16. package/dist/actions/cvms/restart_cvm.d.ts +4 -4
  17. package/dist/actions/cvms/shutdown_cvm.d.ts +4 -4
  18. package/dist/actions/cvms/start_cvm.d.ts +4 -4
  19. package/dist/actions/cvms/stop_cvm.d.ts +4 -4
  20. package/dist/actions/cvms/update_cvm_visibility.d.ts +2 -2
  21. package/dist/actions/cvms/upgrade_prelaunch_script.d.ts +319 -0
  22. package/dist/actions/get_cvm_create_resources.d.ts +2412 -0
  23. package/dist/actions/index.d.ts +4 -0
  24. package/dist/actions/workspaces/get_workspace.d.ts +2 -0
  25. package/dist/actions/workspaces/list_workspaces.d.ts +18 -0
  26. package/dist/client.d.ts +5 -2
  27. package/dist/create-client.d.ts +48 -0
  28. package/dist/index.js +1648 -1208
  29. package/dist/index.mjs +1613 -1206
  30. package/dist/types/app_compose.d.ts +125 -0
  31. package/dist/types/app_info_v20251028.d.ts +8 -131
  32. package/dist/types/app_info_v20260121.d.ts +4500 -168
  33. package/dist/types/client.d.ts +2 -2
  34. package/dist/types/cvm_info.d.ts +533 -7
  35. package/dist/types/cvm_info_v20251028.d.ts +18 -18
  36. package/dist/types/cvm_info_v20260121.d.ts +1640 -89
  37. package/dist/types/version-mappings.d.ts +8 -8
  38. package/dist/utils/errors.d.ts +8 -1
  39. package/package.json +2 -2
@@ -16,6 +16,31 @@ export declare const LooseAppComposeSchema: z.ZodEffects<z.ZodObject<{
16
16
  public_logs: z.ZodOptional<z.ZodBoolean>;
17
17
  public_sysinfo: z.ZodOptional<z.ZodBoolean>;
18
18
  tproxy_enabled: z.ZodOptional<z.ZodBoolean>;
19
+ port_policy: z.ZodOptional<z.ZodObject<{
20
+ ports: z.ZodArray<z.ZodObject<{
21
+ port: z.ZodNumber;
22
+ pp: z.ZodBoolean;
23
+ }, "strip", z.ZodTypeAny, {
24
+ port: number;
25
+ pp: boolean;
26
+ }, {
27
+ port: number;
28
+ pp: boolean;
29
+ }>, "many">;
30
+ restrict_mode: z.ZodBoolean;
31
+ }, "strip", z.ZodTypeAny, {
32
+ ports: {
33
+ port: number;
34
+ pp: boolean;
35
+ }[];
36
+ restrict_mode: boolean;
37
+ }, {
38
+ ports: {
39
+ port: number;
40
+ pp: boolean;
41
+ }[];
42
+ restrict_mode: boolean;
43
+ }>>;
19
44
  storage_fs: z.ZodOptional<z.ZodEnum<["ext4", "zfs"]>>;
20
45
  pre_launch_script: z.ZodOptional<z.ZodString>;
21
46
  env_pubkey: z.ZodOptional<z.ZodString>;
@@ -30,6 +55,31 @@ export declare const LooseAppComposeSchema: z.ZodEffects<z.ZodObject<{
30
55
  public_logs: z.ZodOptional<z.ZodBoolean>;
31
56
  public_sysinfo: z.ZodOptional<z.ZodBoolean>;
32
57
  tproxy_enabled: z.ZodOptional<z.ZodBoolean>;
58
+ port_policy: z.ZodOptional<z.ZodObject<{
59
+ ports: z.ZodArray<z.ZodObject<{
60
+ port: z.ZodNumber;
61
+ pp: z.ZodBoolean;
62
+ }, "strip", z.ZodTypeAny, {
63
+ port: number;
64
+ pp: boolean;
65
+ }, {
66
+ port: number;
67
+ pp: boolean;
68
+ }>, "many">;
69
+ restrict_mode: z.ZodBoolean;
70
+ }, "strip", z.ZodTypeAny, {
71
+ ports: {
72
+ port: number;
73
+ pp: boolean;
74
+ }[];
75
+ restrict_mode: boolean;
76
+ }, {
77
+ ports: {
78
+ port: number;
79
+ pp: boolean;
80
+ }[];
81
+ restrict_mode: boolean;
82
+ }>>;
33
83
  storage_fs: z.ZodOptional<z.ZodEnum<["ext4", "zfs"]>>;
34
84
  pre_launch_script: z.ZodOptional<z.ZodString>;
35
85
  env_pubkey: z.ZodOptional<z.ZodString>;
@@ -44,6 +94,31 @@ export declare const LooseAppComposeSchema: z.ZodEffects<z.ZodObject<{
44
94
  public_logs: z.ZodOptional<z.ZodBoolean>;
45
95
  public_sysinfo: z.ZodOptional<z.ZodBoolean>;
46
96
  tproxy_enabled: z.ZodOptional<z.ZodBoolean>;
97
+ port_policy: z.ZodOptional<z.ZodObject<{
98
+ ports: z.ZodArray<z.ZodObject<{
99
+ port: z.ZodNumber;
100
+ pp: z.ZodBoolean;
101
+ }, "strip", z.ZodTypeAny, {
102
+ port: number;
103
+ pp: boolean;
104
+ }, {
105
+ port: number;
106
+ pp: boolean;
107
+ }>, "many">;
108
+ restrict_mode: z.ZodBoolean;
109
+ }, "strip", z.ZodTypeAny, {
110
+ ports: {
111
+ port: number;
112
+ pp: boolean;
113
+ }[];
114
+ restrict_mode: boolean;
115
+ }, {
116
+ ports: {
117
+ port: number;
118
+ pp: boolean;
119
+ }[];
120
+ restrict_mode: boolean;
121
+ }>>;
47
122
  storage_fs: z.ZodOptional<z.ZodEnum<["ext4", "zfs"]>>;
48
123
  pre_launch_script: z.ZodOptional<z.ZodString>;
49
124
  env_pubkey: z.ZodOptional<z.ZodString>;
@@ -58,6 +133,31 @@ export declare const LooseAppComposeSchema: z.ZodEffects<z.ZodObject<{
58
133
  public_logs: z.ZodOptional<z.ZodBoolean>;
59
134
  public_sysinfo: z.ZodOptional<z.ZodBoolean>;
60
135
  tproxy_enabled: z.ZodOptional<z.ZodBoolean>;
136
+ port_policy: z.ZodOptional<z.ZodObject<{
137
+ ports: z.ZodArray<z.ZodObject<{
138
+ port: z.ZodNumber;
139
+ pp: z.ZodBoolean;
140
+ }, "strip", z.ZodTypeAny, {
141
+ port: number;
142
+ pp: boolean;
143
+ }, {
144
+ port: number;
145
+ pp: boolean;
146
+ }>, "many">;
147
+ restrict_mode: z.ZodBoolean;
148
+ }, "strip", z.ZodTypeAny, {
149
+ ports: {
150
+ port: number;
151
+ pp: boolean;
152
+ }[];
153
+ restrict_mode: boolean;
154
+ }, {
155
+ ports: {
156
+ port: number;
157
+ pp: boolean;
158
+ }[];
159
+ restrict_mode: boolean;
160
+ }>>;
61
161
  storage_fs: z.ZodOptional<z.ZodEnum<["ext4", "zfs"]>>;
62
162
  pre_launch_script: z.ZodOptional<z.ZodString>;
63
163
  env_pubkey: z.ZodOptional<z.ZodString>;
@@ -72,6 +172,31 @@ export declare const LooseAppComposeSchema: z.ZodEffects<z.ZodObject<{
72
172
  public_logs: z.ZodOptional<z.ZodBoolean>;
73
173
  public_sysinfo: z.ZodOptional<z.ZodBoolean>;
74
174
  tproxy_enabled: z.ZodOptional<z.ZodBoolean>;
175
+ port_policy: z.ZodOptional<z.ZodObject<{
176
+ ports: z.ZodArray<z.ZodObject<{
177
+ port: z.ZodNumber;
178
+ pp: z.ZodBoolean;
179
+ }, "strip", z.ZodTypeAny, {
180
+ port: number;
181
+ pp: boolean;
182
+ }, {
183
+ port: number;
184
+ pp: boolean;
185
+ }>, "many">;
186
+ restrict_mode: z.ZodBoolean;
187
+ }, "strip", z.ZodTypeAny, {
188
+ ports: {
189
+ port: number;
190
+ pp: boolean;
191
+ }[];
192
+ restrict_mode: boolean;
193
+ }, {
194
+ ports: {
195
+ port: number;
196
+ pp: boolean;
197
+ }[];
198
+ restrict_mode: boolean;
199
+ }>>;
75
200
  storage_fs: z.ZodOptional<z.ZodEnum<["ext4", "zfs"]>>;
76
201
  pre_launch_script: z.ZodOptional<z.ZodString>;
77
202
  env_pubkey: z.ZodOptional<z.ZodString>;
@@ -436,42 +436,7 @@ export declare const DstackAppFullResponseV20251028Schema: z.ZodObject<{
436
436
  cvm_count?: number | undefined;
437
437
  }>;
438
438
  export type DstackAppFullResponseV20251028 = z.infer<typeof DstackAppFullResponseV20251028Schema>;
439
- export declare const DstackAppMinimalResponseV20251028Schema: z.ZodObject<{
440
- id: z.ZodOptional<z.ZodNull>;
441
- app_id: z.ZodString;
442
- name: z.ZodOptional<z.ZodNull>;
443
- app_provision_type: z.ZodOptional<z.ZodNull>;
444
- app_icon_url: z.ZodOptional<z.ZodNull>;
445
- created_at: z.ZodOptional<z.ZodNull>;
446
- kms_type: z.ZodOptional<z.ZodNull>;
447
- current_cvm: z.ZodOptional<z.ZodNull>;
448
- cvms: z.ZodOptional<z.ZodNull>;
449
- cvm_count: z.ZodOptional<z.ZodNull>;
450
- }, "strip", z.ZodTypeAny, {
451
- app_id: string;
452
- name?: null | undefined;
453
- id?: null | undefined;
454
- kms_type?: null | undefined;
455
- app_provision_type?: null | undefined;
456
- app_icon_url?: null | undefined;
457
- created_at?: null | undefined;
458
- current_cvm?: null | undefined;
459
- cvms?: null | undefined;
460
- cvm_count?: null | undefined;
461
- }, {
462
- app_id: string;
463
- name?: null | undefined;
464
- id?: null | undefined;
465
- kms_type?: null | undefined;
466
- app_provision_type?: null | undefined;
467
- app_icon_url?: null | undefined;
468
- created_at?: null | undefined;
469
- current_cvm?: null | undefined;
470
- cvms?: null | undefined;
471
- cvm_count?: null | undefined;
472
- }>;
473
- export type DstackAppMinimalResponseV20251028 = z.infer<typeof DstackAppMinimalResponseV20251028Schema>;
474
- export declare const DstackAppWithCvmResponseV20251028Schema: z.ZodUnion<[z.ZodObject<{
439
+ export declare const DstackAppWithCvmResponseV20251028Schema: z.ZodObject<{
475
440
  id: z.ZodString;
476
441
  name: z.ZodString;
477
442
  app_id: z.ZodString;
@@ -802,43 +767,10 @@ export declare const DstackAppWithCvmResponseV20251028Schema: z.ZodUnion<[z.ZodO
802
767
  kms_id?: string | null | undefined;
803
768
  }[] | undefined;
804
769
  cvm_count?: number | undefined;
805
- }>, z.ZodObject<{
806
- id: z.ZodOptional<z.ZodNull>;
807
- app_id: z.ZodString;
808
- name: z.ZodOptional<z.ZodNull>;
809
- app_provision_type: z.ZodOptional<z.ZodNull>;
810
- app_icon_url: z.ZodOptional<z.ZodNull>;
811
- created_at: z.ZodOptional<z.ZodNull>;
812
- kms_type: z.ZodOptional<z.ZodNull>;
813
- current_cvm: z.ZodOptional<z.ZodNull>;
814
- cvms: z.ZodOptional<z.ZodNull>;
815
- cvm_count: z.ZodOptional<z.ZodNull>;
816
- }, "strip", z.ZodTypeAny, {
817
- app_id: string;
818
- name?: null | undefined;
819
- id?: null | undefined;
820
- kms_type?: null | undefined;
821
- app_provision_type?: null | undefined;
822
- app_icon_url?: null | undefined;
823
- created_at?: null | undefined;
824
- current_cvm?: null | undefined;
825
- cvms?: null | undefined;
826
- cvm_count?: null | undefined;
827
- }, {
828
- app_id: string;
829
- name?: null | undefined;
830
- id?: null | undefined;
831
- kms_type?: null | undefined;
832
- app_provision_type?: null | undefined;
833
- app_icon_url?: null | undefined;
834
- created_at?: null | undefined;
835
- current_cvm?: null | undefined;
836
- cvms?: null | undefined;
837
- cvm_count?: null | undefined;
838
- }>]>;
770
+ }>;
839
771
  export type DstackAppWithCvmResponseV20251028 = z.infer<typeof DstackAppWithCvmResponseV20251028Schema>;
840
772
  export declare const DstackAppListResponseV20251028Schema: z.ZodObject<{
841
- dstack_apps: z.ZodArray<z.ZodUnion<[z.ZodObject<{
773
+ dstack_apps: z.ZodArray<z.ZodObject<{
842
774
  id: z.ZodString;
843
775
  name: z.ZodString;
844
776
  app_id: z.ZodString;
@@ -1169,40 +1101,7 @@ export declare const DstackAppListResponseV20251028Schema: z.ZodObject<{
1169
1101
  kms_id?: string | null | undefined;
1170
1102
  }[] | undefined;
1171
1103
  cvm_count?: number | undefined;
1172
- }>, z.ZodObject<{
1173
- id: z.ZodOptional<z.ZodNull>;
1174
- app_id: z.ZodString;
1175
- name: z.ZodOptional<z.ZodNull>;
1176
- app_provision_type: z.ZodOptional<z.ZodNull>;
1177
- app_icon_url: z.ZodOptional<z.ZodNull>;
1178
- created_at: z.ZodOptional<z.ZodNull>;
1179
- kms_type: z.ZodOptional<z.ZodNull>;
1180
- current_cvm: z.ZodOptional<z.ZodNull>;
1181
- cvms: z.ZodOptional<z.ZodNull>;
1182
- cvm_count: z.ZodOptional<z.ZodNull>;
1183
- }, "strip", z.ZodTypeAny, {
1184
- app_id: string;
1185
- name?: null | undefined;
1186
- id?: null | undefined;
1187
- kms_type?: null | undefined;
1188
- app_provision_type?: null | undefined;
1189
- app_icon_url?: null | undefined;
1190
- created_at?: null | undefined;
1191
- current_cvm?: null | undefined;
1192
- cvms?: null | undefined;
1193
- cvm_count?: null | undefined;
1194
- }, {
1195
- app_id: string;
1196
- name?: null | undefined;
1197
- id?: null | undefined;
1198
- kms_type?: null | undefined;
1199
- app_provision_type?: null | undefined;
1200
- app_icon_url?: null | undefined;
1201
- created_at?: null | undefined;
1202
- current_cvm?: null | undefined;
1203
- cvms?: null | undefined;
1204
- cvm_count?: null | undefined;
1205
- }>]>, "many">;
1104
+ }>, "many">;
1206
1105
  page: z.ZodNumber;
1207
1106
  page_size: z.ZodNumber;
1208
1107
  total: z.ZodNumber;
@@ -1211,7 +1110,7 @@ export declare const DstackAppListResponseV20251028Schema: z.ZodObject<{
1211
1110
  total: number;
1212
1111
  page: number;
1213
1112
  page_size: number;
1214
- dstack_apps: ({
1113
+ dstack_apps: {
1215
1114
  name: string;
1216
1115
  id: string;
1217
1116
  app_id: string;
@@ -1278,24 +1177,13 @@ export declare const DstackAppListResponseV20251028Schema: z.ZodObject<{
1278
1177
  kms_slug?: string | null | undefined;
1279
1178
  kms_id?: string | null | undefined;
1280
1179
  } | null | undefined;
1281
- } | {
1282
- app_id: string;
1283
- name?: null | undefined;
1284
- id?: null | undefined;
1285
- kms_type?: null | undefined;
1286
- app_provision_type?: null | undefined;
1287
- app_icon_url?: null | undefined;
1288
- created_at?: null | undefined;
1289
- current_cvm?: null | undefined;
1290
- cvms?: null | undefined;
1291
- cvm_count?: null | undefined;
1292
- })[];
1180
+ }[];
1293
1181
  total_pages: number;
1294
1182
  }, {
1295
1183
  total: number;
1296
1184
  page: number;
1297
1185
  page_size: number;
1298
- dstack_apps: ({
1186
+ dstack_apps: {
1299
1187
  name: string;
1300
1188
  id: string;
1301
1189
  app_id: string;
@@ -1362,18 +1250,7 @@ export declare const DstackAppListResponseV20251028Schema: z.ZodObject<{
1362
1250
  kms_id?: string | null | undefined;
1363
1251
  }[] | undefined;
1364
1252
  cvm_count?: number | undefined;
1365
- } | {
1366
- app_id: string;
1367
- name?: null | undefined;
1368
- id?: null | undefined;
1369
- kms_type?: null | undefined;
1370
- app_provision_type?: null | undefined;
1371
- app_icon_url?: null | undefined;
1372
- created_at?: null | undefined;
1373
- current_cvm?: null | undefined;
1374
- cvms?: null | undefined;
1375
- cvm_count?: null | undefined;
1376
- })[];
1253
+ }[];
1377
1254
  total_pages: number;
1378
1255
  }>;
1379
1256
  export type DstackAppListResponseV20251028 = z.infer<typeof DstackAppListResponseV20251028Schema>;