@phala/cloud 0.4.0 → 0.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.
Files changed (114) hide show
  1. package/README.md +20 -0
  2. package/dist/actions/api_tokens/revoke_current_api_token.d.ts +47 -0
  3. package/dist/actions/apps/app_launch_token.d.ts +121 -0
  4. package/dist/actions/apps/check_app_cvms_is_allowed.d.ts +17 -311
  5. package/dist/actions/apps/check_app_is_allowed.d.ts +20 -32
  6. package/dist/actions/apps/create_app_instance.d.ts +43 -63
  7. package/dist/actions/apps/get_app_attestation.d.ts +113 -779
  8. package/dist/actions/apps/get_app_cvms.d.ts +1 -5
  9. package/dist/actions/apps/get_app_device_allowlist.d.ts +26 -272
  10. package/dist/actions/apps/get_app_filter_options.d.ts +8 -24
  11. package/dist/actions/apps/get_app_info.d.ts +1 -5
  12. package/dist/actions/apps/get_app_list.d.ts +2 -26
  13. package/dist/actions/apps/get_app_revision_detail.d.ts +1 -9
  14. package/dist/actions/apps/get_app_revisions.d.ts +1 -9
  15. package/dist/actions/blockchains/add_compose_hash.d.ts +1 -13
  16. package/dist/actions/blockchains/add_device.d.ts +1 -13
  17. package/dist/actions/blockchains/deploy_app_auth.d.ts +3 -95
  18. package/dist/actions/blockchains/get_allowed_devices.d.ts +2 -12
  19. package/dist/actions/blockchains/remove_device.d.ts +1 -13
  20. package/dist/actions/blockchains/set_allow_any_device.d.ts +1 -13
  21. package/dist/actions/cvms/check_cvm_is_allowed.d.ts +13 -138
  22. package/dist/actions/cvms/commit_cvm_compose_file_update.d.ts +9 -45
  23. package/dist/actions/cvms/commit_cvm_provision.d.ts +32 -422
  24. package/dist/actions/cvms/commit_cvm_update.d.ts +70 -41
  25. package/dist/actions/cvms/confirm_cvm_patch.d.ts +62 -35
  26. package/dist/actions/cvms/cvm_annotations.d.ts +152 -0
  27. package/dist/actions/cvms/delete_cvm.d.ts +8 -14
  28. package/dist/actions/cvms/get_available_os_images.d.ts +70 -111
  29. package/dist/actions/cvms/get_cvm_attestation.d.ts +34 -392
  30. package/dist/actions/cvms/get_cvm_compose_file.d.ts +384 -614
  31. package/dist/actions/cvms/get_cvm_containers_stats.d.ts +25 -91
  32. package/dist/actions/cvms/get_cvm_docker_compose.d.ts +8 -14
  33. package/dist/actions/cvms/get_cvm_info.d.ts +6 -12
  34. package/dist/actions/cvms/get_cvm_init_scripts.d.ts +92 -0
  35. package/dist/actions/cvms/get_cvm_list.d.ts +7 -13
  36. package/dist/actions/cvms/get_cvm_network.d.ts +18 -50
  37. package/dist/actions/cvms/get_cvm_prelaunch_script.d.ts +8 -14
  38. package/dist/actions/cvms/get_cvm_state.d.ts +11 -37
  39. package/dist/actions/cvms/get_cvm_stats.d.ts +23 -149
  40. package/dist/actions/cvms/get_cvm_status_batch.d.ts +19 -209
  41. package/dist/actions/cvms/get_cvm_user_config.d.ts +13 -24
  42. package/dist/actions/cvms/get_prelaunch_script_upgrade_status.d.ts +9 -27
  43. package/dist/actions/cvms/log-time.d.ts +5 -0
  44. package/dist/actions/cvms/logs.d.ts +64 -0
  45. package/dist/actions/cvms/patch_cvm.d.ts +665 -295
  46. package/dist/actions/cvms/provision_cvm.d.ts +329 -1561
  47. package/dist/actions/cvms/provision_cvm_compose_file_update.d.ts +550 -953
  48. package/dist/actions/cvms/put_cvm_init_scripts.d.ts +150 -0
  49. package/dist/actions/cvms/refresh_cvm_instance_id.d.ts +74 -131
  50. package/dist/actions/cvms/refresh_cvm_instance_ids.d.ts +77 -297
  51. package/dist/actions/cvms/replicate_cvm.d.ts +7 -21
  52. package/dist/actions/cvms/restart_cvm.d.ts +3 -18
  53. package/dist/actions/cvms/shutdown_cvm.d.ts +6 -12
  54. package/dist/actions/cvms/start_cvm.d.ts +6 -12
  55. package/dist/actions/cvms/stop_cvm.d.ts +6 -12
  56. package/dist/actions/cvms/update_cvm_envs.d.ts +136 -203
  57. package/dist/actions/cvms/update_cvm_resources.d.ts +82 -48
  58. package/dist/actions/cvms/update_cvm_visibility.d.ts +90 -132
  59. package/dist/actions/cvms/update_docker_compose.d.ts +127 -202
  60. package/dist/actions/cvms/update_os_image.d.ts +55 -28
  61. package/dist/actions/cvms/update_prelaunch_script.d.ts +127 -202
  62. package/dist/actions/cvms/upgrade_prelaunch_script.d.ts +118 -193
  63. package/dist/actions/cvms/watch_cvm_state.d.ts +5 -15
  64. package/dist/actions/get_available_nodes.d.ts +186 -1067
  65. package/dist/actions/get_cvm_create_resources.d.ts +138 -2489
  66. package/dist/actions/index.d.ts +9 -2
  67. package/dist/actions/kms/get_app_env_encrypt_pubkey.d.ts +11 -23
  68. package/dist/actions/kms/get_kms_contract.d.ts +25 -27
  69. package/dist/actions/kms/get_kms_info.d.ts +3 -7
  70. package/dist/actions/kms/get_kms_list.d.ts +34 -88
  71. package/dist/actions/kms/get_kms_onchain_detail.d.ts +66 -664
  72. package/dist/actions/kms/list_kms_contract_nodes.d.ts +21 -53
  73. package/dist/actions/kms/list_kms_contracts.d.ts +33 -87
  74. package/dist/actions/kms/next_app_ids.d.ts +5 -25
  75. package/dist/actions/list-instance-types.d.ts +77 -257
  76. package/dist/actions/os_images/get_os_images.d.ts +38 -152
  77. package/dist/actions/ssh_keys/create_ssh_key.d.ts +11 -17
  78. package/dist/actions/ssh_keys/delete_ssh_key.d.ts +3 -7
  79. package/dist/actions/ssh_keys/get_cvm_ssh_keys.d.ts +113 -0
  80. package/dist/actions/ssh_keys/import_github_profile.d.ts +7 -21
  81. package/dist/actions/ssh_keys/list_ssh_keys.d.ts +2 -50
  82. package/dist/actions/ssh_keys/sync_github_ssh_keys.d.ts +8 -20
  83. package/dist/actions/ssh_keys/update_cvm_ssh_keys.d.ts +140 -0
  84. package/dist/actions/workspaces/get_workspace.d.ts +32 -28
  85. package/dist/actions/workspaces/get_workspace_nodes.d.ts +34 -321
  86. package/dist/actions/workspaces/get_workspace_quotas.d.ts +107 -1021
  87. package/dist/actions/workspaces/list_workspaces.d.ts +67 -369
  88. package/dist/client.d.ts +23 -4
  89. package/dist/create-client.d.ts +1900 -1
  90. package/dist/credentials/current_user_v20251028.d.ts +1 -17
  91. package/dist/credentials/current_user_v20260121.d.ts +22 -227
  92. package/dist/index.d.ts +1 -1
  93. package/dist/index.js +6004 -4537
  94. package/dist/index.mjs +6033 -4625
  95. package/dist/types/app_compose.d.ts +108 -221
  96. package/dist/types/app_info_v20251028.d.ts +22 -1067
  97. package/dist/types/app_info_v20260121.d.ts +442 -8900
  98. package/dist/types/app_revision.d.ts +15 -371
  99. package/dist/types/client.d.ts +16 -0
  100. package/dist/types/common.d.ts +6 -0
  101. package/dist/types/cvm_id.d.ts +12 -57
  102. package/dist/types/cvm_info.d.ts +33 -460
  103. package/dist/types/cvm_info_v20251028.d.ts +100 -821
  104. package/dist/types/cvm_info_v20260121.d.ts +254 -3160
  105. package/dist/types/kms_contract.d.ts +2 -32
  106. package/dist/types/kms_info.d.ts +34 -68
  107. package/dist/user-agent.d.ts +30 -0
  108. package/dist/utils/define-action.d.ts +4 -4
  109. package/dist/utils/errors.d.ts +4 -36
  110. package/dist/utils/get_compose_hash.d.ts +36 -5
  111. package/dist/utils/get_mr_config_id.d.ts +94 -3
  112. package/dist/utils/index.d.ts +1 -1
  113. package/dist/utils/placement-request.d.ts +3 -0
  114. package/package.json +4 -4
@@ -10,6 +10,11 @@ import { z } from "zod";
10
10
  * with the compose hash to register on-chain. After registration, call
11
11
  * `confirmCvmPatch` with the compose hash and transaction hash.
12
12
  *
13
+ * GPU assignment goes in `gpus` as a `GpuConfig` object, not a bare array:
14
+ * `{ gpus: [{ slot, product_id? }], attach_mode? }`. `slot` identifies the
15
+ * device, `product_id` is optional, and `attach_mode: "all"` attaches every
16
+ * GPU on the node instead of the listed slots.
17
+ *
13
18
  * @example
14
19
  * ```typescript
15
20
  * import { createClient, patchCvm, confirmCvmPatch, addComposeHash } from '@phala/cloud'
@@ -25,6 +30,20 @@ import { z } from "zod";
25
30
  * // result.requiresOnChainHash === false
26
31
  * console.log(result.correlationId)
27
32
  *
33
+ * // Attach GPUs
34
+ * await patchCvm(client, {
35
+ * id: 'my-cvm',
36
+ * gpus: { gpus: [{ slot: '0000:3b:00.0' }] },
37
+ * })
38
+ *
39
+ * // Compose fields go in `compose` as a JSON Merge Patch; null removes a key
40
+ * await patchCvm(client, {
41
+ * id: 'my-cvm',
42
+ * compose: { secure_time: true, requirements: { health_check: null } },
43
+ * init_scripts: ['docker_cleanup'],
44
+ * confirm_data_wipe: true, // docker_cleanup wipes container stores on every boot
45
+ * })
46
+ *
28
47
  * // On-chain KMS compose update (two-phase)
29
48
  * const result = await patchCvm(client, {
30
49
  * id: 'my-cvm',
@@ -45,368 +64,360 @@ import { z } from "zod";
45
64
  * }
46
65
  * ```
47
66
  */
48
- export declare const PatchCvmRequestSchema: z.ZodEffects<z.ZodObject<{
67
+ /**
68
+ * GPU assignment for a CVM update. `gpus` lists the device slots to attach
69
+ * (`product_id` is optional), and `attach_mode: "all"` attaches every GPU on
70
+ * the node instead of the listed slots.
71
+ */
72
+ export declare const PatchCvmGpuConfigSchema: z.ZodObject<{
73
+ gpus: z.ZodArray<z.ZodObject<{
74
+ slot: z.ZodString;
75
+ product_id: z.ZodOptional<z.ZodString>;
76
+ }, z.core.$strip>>;
77
+ attach_mode: z.ZodOptional<z.ZodString>;
78
+ }, z.core.$strip>;
79
+ export type PatchCvmGpuConfig = z.input<typeof PatchCvmGpuConfigSchema>;
80
+ /**
81
+ * `requirements` keys a PATCH may set; `null` removes the key. `gpu_policy` is
82
+ * not patchable: the stored value is kept.
83
+ */
84
+ export declare const ComposeRequirementsPatchSchema: z.ZodObject<{
85
+ ephemeral_data_disk: z.ZodOptional<z.ZodNullable<z.ZodBoolean>>;
86
+ health_check: z.ZodOptional<z.ZodNullable<z.ZodBoolean>>;
87
+ health_status_file: z.ZodOptional<z.ZodNullable<z.ZodString>>;
88
+ launch_token_hash: z.ZodOptional<z.ZodNullable<z.ZodString>>;
89
+ platforms: z.ZodOptional<z.ZodNullable<z.ZodArray<z.ZodString>>>;
90
+ tdx_measure_acpi_tables: z.ZodOptional<z.ZodNullable<z.ZodBoolean>>;
91
+ }, z.core.$loose>;
92
+ /**
93
+ * JSON Merge Patch of the CVM's app compose: a sent key sets the value, a sent
94
+ * `null` removes the key, an absent key is unchanged. `requirements` merges per key.
95
+ */
96
+ export declare const ComposePatchSchema: z.ZodObject<{
97
+ secure_time: z.ZodOptional<z.ZodNullable<z.ZodBoolean>>;
98
+ swap_size: z.ZodOptional<z.ZodNullable<z.ZodString>>;
99
+ storage_discard: z.ZodOptional<z.ZodNullable<z.ZodBoolean>>;
100
+ snapshotter: z.ZodOptional<z.ZodNullable<z.ZodEnum<{
101
+ overlayfs: "overlayfs";
102
+ stargz: "stargz";
103
+ }>>>;
104
+ gateway_enabled: z.ZodOptional<z.ZodNullable<z.ZodBoolean>>;
105
+ port_policy: z.ZodOptional<z.ZodNullable<z.ZodObject<{
106
+ ports: z.ZodOptional<z.ZodArray<z.ZodObject<{
107
+ port: z.ZodNumber;
108
+ pp: z.ZodOptional<z.ZodBoolean>;
109
+ }, z.core.$strip>>>;
110
+ restrict_mode: z.ZodOptional<z.ZodBoolean>;
111
+ }, z.core.$strip>>>;
112
+ event_log_version: z.ZodOptional<z.ZodNullable<z.ZodUnion<readonly [z.ZodLiteral<1>, z.ZodLiteral<2>]>>>;
113
+ requirements: z.ZodOptional<z.ZodNullable<z.ZodObject<{
114
+ ephemeral_data_disk: z.ZodOptional<z.ZodNullable<z.ZodBoolean>>;
115
+ health_check: z.ZodOptional<z.ZodNullable<z.ZodBoolean>>;
116
+ health_status_file: z.ZodOptional<z.ZodNullable<z.ZodString>>;
117
+ launch_token_hash: z.ZodOptional<z.ZodNullable<z.ZodString>>;
118
+ platforms: z.ZodOptional<z.ZodNullable<z.ZodArray<z.ZodString>>>;
119
+ tdx_measure_acpi_tables: z.ZodOptional<z.ZodNullable<z.ZodBoolean>>;
120
+ }, z.core.$loose>>>;
121
+ kms_enabled: z.ZodOptional<z.ZodNullable<z.ZodBoolean>>;
122
+ key_provider: z.ZodOptional<z.ZodNullable<z.ZodEnum<{
123
+ none: "none";
124
+ kms: "kms";
125
+ local: "local";
126
+ tpm: "tpm";
127
+ }>>>;
128
+ key_provider_id: z.ZodOptional<z.ZodNullable<z.ZodString>>;
129
+ local_key_provider_enabled: z.ZodOptional<z.ZodNullable<z.ZodBoolean>>;
130
+ manifest_version: z.ZodOptional<z.ZodNullable<z.ZodUnion<readonly [z.ZodNumber, z.ZodString]>>>;
131
+ no_instance_id: z.ZodOptional<z.ZodNullable<z.ZodBoolean>>;
132
+ runner: z.ZodOptional<z.ZodNullable<z.ZodString>>;
133
+ storage_fs: z.ZodOptional<z.ZodNullable<z.ZodEnum<{
134
+ ext4: "ext4";
135
+ zfs: "zfs";
136
+ }>>>;
137
+ verity_volumes: z.ZodOptional<z.ZodNullable<z.ZodArray<z.ZodObject<{
138
+ source: z.ZodString;
139
+ target: z.ZodString;
140
+ verity_root: z.ZodString;
141
+ }, z.core.$strip>>>>;
142
+ tproxy_enabled: z.ZodOptional<z.ZodNullable<z.ZodBoolean>>;
143
+ features: z.ZodOptional<z.ZodNullable<z.ZodArray<z.ZodString>>>;
144
+ }, z.core.$loose>;
145
+ export type ComposePatch = z.input<typeof ComposePatchSchema>;
146
+ export declare const PatchCvmRequestSchema: z.ZodObject<{
49
147
  id: z.ZodOptional<z.ZodString>;
50
148
  uuid: z.ZodOptional<z.ZodString>;
51
149
  app_id: z.ZodOptional<z.ZodString>;
52
150
  instance_id: z.ZodOptional<z.ZodString>;
53
- name: z.ZodOptional<z.ZodEffects<z.ZodString, string, string>>;
54
- } & {
151
+ name: z.ZodOptional<z.ZodString>;
55
152
  docker_compose_file: z.ZodOptional<z.ZodString>;
56
153
  pre_launch_script: z.ZodOptional<z.ZodString>;
57
- allowed_envs: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
154
+ allowed_envs: z.ZodOptional<z.ZodArray<z.ZodString>>;
58
155
  public_logs: z.ZodOptional<z.ZodBoolean>;
59
156
  public_sysinfo: z.ZodOptional<z.ZodBoolean>;
60
157
  public_tcbinfo: z.ZodOptional<z.ZodBoolean>;
158
+ compose: z.ZodOptional<z.ZodObject<{
159
+ secure_time: z.ZodOptional<z.ZodNullable<z.ZodBoolean>>;
160
+ swap_size: z.ZodOptional<z.ZodNullable<z.ZodString>>;
161
+ storage_discard: z.ZodOptional<z.ZodNullable<z.ZodBoolean>>;
162
+ snapshotter: z.ZodOptional<z.ZodNullable<z.ZodEnum<{
163
+ overlayfs: "overlayfs";
164
+ stargz: "stargz";
165
+ }>>>;
166
+ gateway_enabled: z.ZodOptional<z.ZodNullable<z.ZodBoolean>>;
167
+ port_policy: z.ZodOptional<z.ZodNullable<z.ZodObject<{
168
+ ports: z.ZodOptional<z.ZodArray<z.ZodObject<{
169
+ port: z.ZodNumber;
170
+ pp: z.ZodOptional<z.ZodBoolean>;
171
+ }, z.core.$strip>>>;
172
+ restrict_mode: z.ZodOptional<z.ZodBoolean>;
173
+ }, z.core.$strip>>>;
174
+ event_log_version: z.ZodOptional<z.ZodNullable<z.ZodUnion<readonly [z.ZodLiteral<1>, z.ZodLiteral<2>]>>>;
175
+ requirements: z.ZodOptional<z.ZodNullable<z.ZodObject<{
176
+ ephemeral_data_disk: z.ZodOptional<z.ZodNullable<z.ZodBoolean>>;
177
+ health_check: z.ZodOptional<z.ZodNullable<z.ZodBoolean>>;
178
+ health_status_file: z.ZodOptional<z.ZodNullable<z.ZodString>>;
179
+ launch_token_hash: z.ZodOptional<z.ZodNullable<z.ZodString>>;
180
+ platforms: z.ZodOptional<z.ZodNullable<z.ZodArray<z.ZodString>>>;
181
+ tdx_measure_acpi_tables: z.ZodOptional<z.ZodNullable<z.ZodBoolean>>;
182
+ }, z.core.$loose>>>;
183
+ kms_enabled: z.ZodOptional<z.ZodNullable<z.ZodBoolean>>;
184
+ key_provider: z.ZodOptional<z.ZodNullable<z.ZodEnum<{
185
+ none: "none";
186
+ kms: "kms";
187
+ local: "local";
188
+ tpm: "tpm";
189
+ }>>>;
190
+ key_provider_id: z.ZodOptional<z.ZodNullable<z.ZodString>>;
191
+ local_key_provider_enabled: z.ZodOptional<z.ZodNullable<z.ZodBoolean>>;
192
+ manifest_version: z.ZodOptional<z.ZodNullable<z.ZodUnion<readonly [z.ZodNumber, z.ZodString]>>>;
193
+ no_instance_id: z.ZodOptional<z.ZodNullable<z.ZodBoolean>>;
194
+ runner: z.ZodOptional<z.ZodNullable<z.ZodString>>;
195
+ storage_fs: z.ZodOptional<z.ZodNullable<z.ZodEnum<{
196
+ ext4: "ext4";
197
+ zfs: "zfs";
198
+ }>>>;
199
+ verity_volumes: z.ZodOptional<z.ZodNullable<z.ZodArray<z.ZodObject<{
200
+ source: z.ZodString;
201
+ target: z.ZodString;
202
+ verity_root: z.ZodString;
203
+ }, z.core.$strip>>>>;
204
+ tproxy_enabled: z.ZodOptional<z.ZodNullable<z.ZodBoolean>>;
205
+ features: z.ZodOptional<z.ZodNullable<z.ZodArray<z.ZodString>>>;
206
+ }, z.core.$loose>>;
207
+ init_scripts: z.ZodOptional<z.ZodArray<z.ZodEnum<{
208
+ docker_cleanup: "docker_cleanup";
209
+ env_merge: "env_merge";
210
+ }>>>;
211
+ init_script: z.ZodOptional<z.ZodArray<z.ZodString>>;
212
+ confirm_data_wipe: z.ZodOptional<z.ZodBoolean>;
61
213
  encrypted_env: z.ZodOptional<z.ZodString>;
62
214
  user_config: z.ZodOptional<z.ZodString>;
63
215
  gpus: z.ZodOptional<z.ZodObject<{
64
- count: z.ZodNumber;
65
- product_name: z.ZodOptional<z.ZodString>;
66
- }, "strip", z.ZodTypeAny, {
67
- count: number;
68
- product_name?: string | undefined;
69
- }, {
70
- count: number;
71
- product_name?: string | undefined;
72
- }>>;
216
+ gpus: z.ZodArray<z.ZodObject<{
217
+ slot: z.ZodString;
218
+ product_id: z.ZodOptional<z.ZodString>;
219
+ }, z.core.$strip>>;
220
+ attach_mode: z.ZodOptional<z.ZodString>;
221
+ }, z.core.$strip>>;
73
222
  vcpu: z.ZodOptional<z.ZodNumber>;
74
223
  memory: z.ZodOptional<z.ZodNumber>;
75
224
  disk_size: z.ZodOptional<z.ZodNumber>;
225
+ instance_type: z.ZodOptional<z.ZodString>;
76
226
  image: z.ZodOptional<z.ZodString>;
77
227
  shutdown_timeout: z.ZodOptional<z.ZodNumber>;
78
228
  allow_force_stop: z.ZodOptional<z.ZodBoolean>;
79
229
  prepareOnly: z.ZodOptional<z.ZodBoolean>;
80
- }, "strip", z.ZodTypeAny, {
81
- name?: string | undefined;
82
- image?: string | undefined;
83
- id?: string | undefined;
84
- uuid?: string | undefined;
85
- app_id?: string | undefined;
86
- instance_id?: string | undefined;
87
- vcpu?: number | undefined;
88
- memory?: number | undefined;
89
- disk_size?: number | undefined;
90
- docker_compose_file?: string | undefined;
91
- encrypted_env?: string | undefined;
92
- public_sysinfo?: boolean | undefined;
93
- public_logs?: boolean | undefined;
94
- gpus?: {
95
- count: number;
96
- product_name?: string | undefined;
97
- } | undefined;
98
- public_tcbinfo?: boolean | undefined;
99
- allowed_envs?: string[] | undefined;
100
- pre_launch_script?: string | undefined;
101
- user_config?: string | undefined;
102
- shutdown_timeout?: number | undefined;
103
- allow_force_stop?: boolean | undefined;
104
- prepareOnly?: boolean | undefined;
105
- }, {
106
- name?: string | undefined;
107
- image?: string | undefined;
108
- id?: string | undefined;
109
- uuid?: string | undefined;
110
- app_id?: string | undefined;
111
- instance_id?: string | undefined;
112
- vcpu?: number | undefined;
113
- memory?: number | undefined;
114
- disk_size?: number | undefined;
115
- docker_compose_file?: string | undefined;
116
- encrypted_env?: string | undefined;
117
- public_sysinfo?: boolean | undefined;
118
- public_logs?: boolean | undefined;
119
- gpus?: {
120
- count: number;
121
- product_name?: string | undefined;
122
- } | undefined;
123
- public_tcbinfo?: boolean | undefined;
124
- allowed_envs?: string[] | undefined;
125
- pre_launch_script?: string | undefined;
126
- user_config?: string | undefined;
127
- shutdown_timeout?: number | undefined;
128
- allow_force_stop?: boolean | undefined;
129
- prepareOnly?: boolean | undefined;
130
- }>, any, any>;
230
+ }, z.core.$strip>;
131
231
  export type PatchCvmRequest = z.input<typeof PatchCvmRequestSchema>;
132
232
  declare const PatchCvmAcceptedSchema: z.ZodObject<{
133
233
  requiresOnChainHash: z.ZodLiteral<false>;
134
234
  correlationId: z.ZodString;
135
- }, "strip", z.ZodTypeAny, {
136
- requiresOnChainHash: false;
137
- correlationId: string;
138
- }, {
139
- requiresOnChainHash: false;
140
- correlationId: string;
141
- }>;
235
+ }, z.core.$strip>;
142
236
  declare const PatchCvmHashRequiredSchema: z.ZodObject<{
143
237
  requiresOnChainHash: z.ZodLiteral<true>;
144
238
  composeHash: z.ZodString;
145
239
  appId: z.ZodString;
146
240
  deviceId: z.ZodString;
147
- kmsInfo: z.ZodEffects<z.ZodObject<{
148
- id: z.ZodString;
149
- slug: z.ZodNullable<z.ZodString>;
150
- url: z.ZodString;
151
- version: z.ZodString;
152
- chain_id: z.ZodNullable<z.ZodNumber>;
153
- kms_contract_address: z.ZodEffects<z.ZodNullable<z.ZodString>, `0x${string}`, string | null>;
154
- gateway_app_id: z.ZodEffects<z.ZodNullable<z.ZodString>, `0x${string}`, string | null>;
155
- k256_pubkey: z.ZodOptional<z.ZodNullable<z.ZodString>>;
156
- }, "passthrough", z.ZodTypeAny, z.objectOutputType<{
157
- id: z.ZodString;
158
- slug: z.ZodNullable<z.ZodString>;
159
- url: z.ZodString;
160
- version: z.ZodString;
161
- chain_id: z.ZodNullable<z.ZodNumber>;
162
- kms_contract_address: z.ZodEffects<z.ZodNullable<z.ZodString>, `0x${string}`, string | null>;
163
- gateway_app_id: z.ZodEffects<z.ZodNullable<z.ZodString>, `0x${string}`, string | null>;
164
- k256_pubkey: z.ZodOptional<z.ZodNullable<z.ZodString>>;
165
- }, z.ZodTypeAny, "passthrough">, z.objectInputType<{
166
- id: z.ZodString;
167
- slug: z.ZodNullable<z.ZodString>;
168
- url: z.ZodString;
169
- version: z.ZodString;
170
- chain_id: z.ZodNullable<z.ZodNumber>;
171
- kms_contract_address: z.ZodEffects<z.ZodNullable<z.ZodString>, `0x${string}`, string | null>;
172
- gateway_app_id: z.ZodEffects<z.ZodNullable<z.ZodString>, `0x${string}`, string | null>;
173
- k256_pubkey: z.ZodOptional<z.ZodNullable<z.ZodString>>;
174
- }, z.ZodTypeAny, "passthrough">>, z.objectOutputType<{
175
- id: z.ZodString;
176
- slug: z.ZodNullable<z.ZodString>;
177
- url: z.ZodString;
178
- version: z.ZodString;
179
- chain_id: z.ZodNullable<z.ZodNumber>;
180
- kms_contract_address: z.ZodEffects<z.ZodNullable<z.ZodString>, `0x${string}`, string | null>;
181
- gateway_app_id: z.ZodEffects<z.ZodNullable<z.ZodString>, `0x${string}`, string | null>;
182
- k256_pubkey: z.ZodOptional<z.ZodNullable<z.ZodString>>;
183
- }, z.ZodTypeAny, "passthrough">, z.objectInputType<{
241
+ kmsInfo: z.ZodPipe<z.ZodObject<{
184
242
  id: z.ZodString;
185
243
  slug: z.ZodNullable<z.ZodString>;
186
244
  url: z.ZodString;
187
245
  version: z.ZodString;
188
246
  chain_id: z.ZodNullable<z.ZodNumber>;
189
- kms_contract_address: z.ZodEffects<z.ZodNullable<z.ZodString>, `0x${string}`, string | null>;
190
- gateway_app_id: z.ZodEffects<z.ZodNullable<z.ZodString>, `0x${string}`, string | null>;
247
+ kms_contract_address: z.ZodPipe<z.ZodNullable<z.ZodString>, z.ZodTransform<`0x${string}`, string | null>>;
248
+ gateway_app_id: z.ZodPipe<z.ZodNullable<z.ZodString>, z.ZodTransform<`0x${string}`, string | null>>;
191
249
  k256_pubkey: z.ZodOptional<z.ZodNullable<z.ZodString>>;
192
- }, z.ZodTypeAny, "passthrough">>;
193
- commitToken: z.ZodOptional<z.ZodString>;
194
- commitUrl: z.ZodOptional<z.ZodString>;
195
- apiCommitUrl: z.ZodOptional<z.ZodString>;
196
- onchainStatus: z.ZodOptional<z.ZodObject<{
197
- compose_hash_allowed: z.ZodBoolean;
198
- device_id_allowed: z.ZodBoolean;
199
- is_allowed: z.ZodBoolean;
200
- }, "strip", z.ZodTypeAny, {
201
- compose_hash_allowed: boolean;
202
- device_id_allowed: boolean;
203
- is_allowed: boolean;
204
- }, {
205
- compose_hash_allowed: boolean;
206
- device_id_allowed: boolean;
207
- is_allowed: boolean;
208
- }>>;
209
- }, "strip", z.ZodTypeAny, {
210
- appId: string;
211
- deviceId: string;
212
- composeHash: string;
213
- requiresOnChainHash: true;
214
- kmsInfo: {
215
- version: string;
250
+ }, z.core.$loose>, z.ZodTransform<{
251
+ [x: string]: unknown;
216
252
  id: string;
217
253
  slug: string | null;
218
- chain_id: number | null;
219
254
  url: string;
255
+ version: string;
256
+ chain_id: number | null;
220
257
  kms_contract_address: `0x${string}`;
221
258
  gateway_app_id: `0x${string}`;
222
259
  k256_pubkey?: string | null | undefined;
223
- } & {
224
- [k: string]: unknown;
225
- };
226
- commitToken?: string | undefined;
227
- commitUrl?: string | undefined;
228
- apiCommitUrl?: string | undefined;
229
- onchainStatus?: {
230
- compose_hash_allowed: boolean;
231
- device_id_allowed: boolean;
232
- is_allowed: boolean;
233
- } | undefined;
234
- }, {
235
- appId: string;
236
- deviceId: string;
237
- composeHash: string;
238
- requiresOnChainHash: true;
239
- kmsInfo: {
240
- version: string;
260
+ }, {
261
+ [x: string]: unknown;
241
262
  id: string;
242
263
  slug: string | null;
243
- chain_id: number | null;
244
264
  url: string;
245
- kms_contract_address: string | null;
246
- gateway_app_id: string | null;
265
+ version: string;
266
+ chain_id: number | null;
267
+ kms_contract_address: `0x${string}`;
268
+ gateway_app_id: `0x${string}`;
247
269
  k256_pubkey?: string | null | undefined;
248
- } & {
249
- [k: string]: unknown;
250
- };
251
- commitToken?: string | undefined;
252
- commitUrl?: string | undefined;
253
- apiCommitUrl?: string | undefined;
254
- onchainStatus?: {
255
- compose_hash_allowed: boolean;
256
- device_id_allowed: boolean;
257
- is_allowed: boolean;
258
- } | undefined;
259
- }>;
260
- export declare const PatchCvmResultSchema: z.ZodDiscriminatedUnion<"requiresOnChainHash", [z.ZodObject<{
270
+ }>>;
271
+ commitToken: z.ZodOptional<z.ZodString>;
272
+ commitUrl: z.ZodOptional<z.ZodString>;
273
+ apiCommitUrl: z.ZodOptional<z.ZodString>;
274
+ onchainStatus: z.ZodOptional<z.ZodObject<{
275
+ compose_hash_allowed: z.ZodBoolean;
276
+ device_id_allowed: z.ZodBoolean;
277
+ is_allowed: z.ZodBoolean;
278
+ }, z.core.$strip>>;
279
+ }, z.core.$strip>;
280
+ export declare const PatchCvmResultSchema: z.ZodDiscriminatedUnion<[z.ZodObject<{
261
281
  requiresOnChainHash: z.ZodLiteral<false>;
262
282
  correlationId: z.ZodString;
263
- }, "strip", z.ZodTypeAny, {
264
- requiresOnChainHash: false;
265
- correlationId: string;
266
- }, {
267
- requiresOnChainHash: false;
268
- correlationId: string;
269
- }>, z.ZodObject<{
283
+ }, z.core.$strip>, z.ZodObject<{
270
284
  requiresOnChainHash: z.ZodLiteral<true>;
271
285
  composeHash: z.ZodString;
272
286
  appId: z.ZodString;
273
287
  deviceId: z.ZodString;
274
- kmsInfo: z.ZodEffects<z.ZodObject<{
288
+ kmsInfo: z.ZodPipe<z.ZodObject<{
275
289
  id: z.ZodString;
276
290
  slug: z.ZodNullable<z.ZodString>;
277
291
  url: z.ZodString;
278
292
  version: z.ZodString;
279
293
  chain_id: z.ZodNullable<z.ZodNumber>;
280
- kms_contract_address: z.ZodEffects<z.ZodNullable<z.ZodString>, `0x${string}`, string | null>;
281
- gateway_app_id: z.ZodEffects<z.ZodNullable<z.ZodString>, `0x${string}`, string | null>;
294
+ kms_contract_address: z.ZodPipe<z.ZodNullable<z.ZodString>, z.ZodTransform<`0x${string}`, string | null>>;
295
+ gateway_app_id: z.ZodPipe<z.ZodNullable<z.ZodString>, z.ZodTransform<`0x${string}`, string | null>>;
282
296
  k256_pubkey: z.ZodOptional<z.ZodNullable<z.ZodString>>;
283
- }, "passthrough", z.ZodTypeAny, z.objectOutputType<{
284
- id: z.ZodString;
285
- slug: z.ZodNullable<z.ZodString>;
286
- url: z.ZodString;
287
- version: z.ZodString;
288
- chain_id: z.ZodNullable<z.ZodNumber>;
289
- kms_contract_address: z.ZodEffects<z.ZodNullable<z.ZodString>, `0x${string}`, string | null>;
290
- gateway_app_id: z.ZodEffects<z.ZodNullable<z.ZodString>, `0x${string}`, string | null>;
291
- k256_pubkey: z.ZodOptional<z.ZodNullable<z.ZodString>>;
292
- }, z.ZodTypeAny, "passthrough">, z.objectInputType<{
293
- id: z.ZodString;
294
- slug: z.ZodNullable<z.ZodString>;
295
- url: z.ZodString;
296
- version: z.ZodString;
297
- chain_id: z.ZodNullable<z.ZodNumber>;
298
- kms_contract_address: z.ZodEffects<z.ZodNullable<z.ZodString>, `0x${string}`, string | null>;
299
- gateway_app_id: z.ZodEffects<z.ZodNullable<z.ZodString>, `0x${string}`, string | null>;
300
- k256_pubkey: z.ZodOptional<z.ZodNullable<z.ZodString>>;
301
- }, z.ZodTypeAny, "passthrough">>, z.objectOutputType<{
302
- id: z.ZodString;
303
- slug: z.ZodNullable<z.ZodString>;
304
- url: z.ZodString;
305
- version: z.ZodString;
306
- chain_id: z.ZodNullable<z.ZodNumber>;
307
- kms_contract_address: z.ZodEffects<z.ZodNullable<z.ZodString>, `0x${string}`, string | null>;
308
- gateway_app_id: z.ZodEffects<z.ZodNullable<z.ZodString>, `0x${string}`, string | null>;
309
- k256_pubkey: z.ZodOptional<z.ZodNullable<z.ZodString>>;
310
- }, z.ZodTypeAny, "passthrough">, z.objectInputType<{
311
- id: z.ZodString;
312
- slug: z.ZodNullable<z.ZodString>;
313
- url: z.ZodString;
314
- version: z.ZodString;
315
- chain_id: z.ZodNullable<z.ZodNumber>;
316
- kms_contract_address: z.ZodEffects<z.ZodNullable<z.ZodString>, `0x${string}`, string | null>;
317
- gateway_app_id: z.ZodEffects<z.ZodNullable<z.ZodString>, `0x${string}`, string | null>;
318
- k256_pubkey: z.ZodOptional<z.ZodNullable<z.ZodString>>;
319
- }, z.ZodTypeAny, "passthrough">>;
320
- commitToken: z.ZodOptional<z.ZodString>;
321
- commitUrl: z.ZodOptional<z.ZodString>;
322
- apiCommitUrl: z.ZodOptional<z.ZodString>;
323
- onchainStatus: z.ZodOptional<z.ZodObject<{
324
- compose_hash_allowed: z.ZodBoolean;
325
- device_id_allowed: z.ZodBoolean;
326
- is_allowed: z.ZodBoolean;
327
- }, "strip", z.ZodTypeAny, {
328
- compose_hash_allowed: boolean;
329
- device_id_allowed: boolean;
330
- is_allowed: boolean;
331
- }, {
332
- compose_hash_allowed: boolean;
333
- device_id_allowed: boolean;
334
- is_allowed: boolean;
335
- }>>;
336
- }, "strip", z.ZodTypeAny, {
337
- appId: string;
338
- deviceId: string;
339
- composeHash: string;
340
- requiresOnChainHash: true;
341
- kmsInfo: {
342
- version: string;
297
+ }, z.core.$loose>, z.ZodTransform<{
298
+ [x: string]: unknown;
343
299
  id: string;
344
300
  slug: string | null;
345
- chain_id: number | null;
346
301
  url: string;
302
+ version: string;
303
+ chain_id: number | null;
347
304
  kms_contract_address: `0x${string}`;
348
305
  gateway_app_id: `0x${string}`;
349
306
  k256_pubkey?: string | null | undefined;
350
- } & {
351
- [k: string]: unknown;
352
- };
353
- commitToken?: string | undefined;
354
- commitUrl?: string | undefined;
355
- apiCommitUrl?: string | undefined;
356
- onchainStatus?: {
357
- compose_hash_allowed: boolean;
358
- device_id_allowed: boolean;
359
- is_allowed: boolean;
360
- } | undefined;
361
- }, {
362
- appId: string;
363
- deviceId: string;
364
- composeHash: string;
365
- requiresOnChainHash: true;
366
- kmsInfo: {
367
- version: string;
307
+ }, {
308
+ [x: string]: unknown;
368
309
  id: string;
369
310
  slug: string | null;
370
- chain_id: number | null;
371
311
  url: string;
372
- kms_contract_address: string | null;
373
- gateway_app_id: string | null;
312
+ version: string;
313
+ chain_id: number | null;
314
+ kms_contract_address: `0x${string}`;
315
+ gateway_app_id: `0x${string}`;
374
316
  k256_pubkey?: string | null | undefined;
375
- } & {
376
- [k: string]: unknown;
377
- };
378
- commitToken?: string | undefined;
379
- commitUrl?: string | undefined;
380
- apiCommitUrl?: string | undefined;
381
- onchainStatus?: {
382
- compose_hash_allowed: boolean;
383
- device_id_allowed: boolean;
384
- is_allowed: boolean;
385
- } | undefined;
386
- }>]>;
317
+ }>>;
318
+ commitToken: z.ZodOptional<z.ZodString>;
319
+ commitUrl: z.ZodOptional<z.ZodString>;
320
+ apiCommitUrl: z.ZodOptional<z.ZodString>;
321
+ onchainStatus: z.ZodOptional<z.ZodObject<{
322
+ compose_hash_allowed: z.ZodBoolean;
323
+ device_id_allowed: z.ZodBoolean;
324
+ is_allowed: z.ZodBoolean;
325
+ }, z.core.$strip>>;
326
+ }, z.core.$strip>], "requiresOnChainHash">;
387
327
  export type PatchCvmResult = z.infer<typeof PatchCvmResultSchema>;
388
328
  export type PatchCvmAccepted = z.infer<typeof PatchCvmAcceptedSchema>;
389
329
  export type PatchCvmHashRequired = z.infer<typeof PatchCvmHashRequiredSchema>;
390
330
  declare const patchCvm: {
391
- (client: import("../..").BaseClient<import("../..").ApiVersion>, params?: any): Promise<{
331
+ (client: import("../..").BaseClient<import("../..").ApiVersion>, params: {
332
+ id?: string | undefined;
333
+ uuid?: string | undefined;
334
+ app_id?: string | undefined;
335
+ instance_id?: string | undefined;
336
+ name?: string | undefined;
337
+ docker_compose_file?: string | undefined;
338
+ pre_launch_script?: string | undefined;
339
+ allowed_envs?: string[] | undefined;
340
+ public_logs?: boolean | undefined;
341
+ public_sysinfo?: boolean | undefined;
342
+ public_tcbinfo?: boolean | undefined;
343
+ compose?: {
344
+ [x: string]: unknown;
345
+ secure_time?: boolean | null | undefined;
346
+ swap_size?: string | null | undefined;
347
+ storage_discard?: boolean | null | undefined;
348
+ snapshotter?: "overlayfs" | "stargz" | null | undefined;
349
+ gateway_enabled?: boolean | null | undefined;
350
+ port_policy?: {
351
+ ports?: {
352
+ port: number;
353
+ pp?: boolean | undefined;
354
+ }[] | undefined;
355
+ restrict_mode?: boolean | undefined;
356
+ } | null | undefined;
357
+ event_log_version?: 1 | 2 | null | undefined;
358
+ requirements?: {
359
+ [x: string]: unknown;
360
+ ephemeral_data_disk?: boolean | null | undefined;
361
+ health_check?: boolean | null | undefined;
362
+ health_status_file?: string | null | undefined;
363
+ launch_token_hash?: string | null | undefined;
364
+ platforms?: string[] | null | undefined;
365
+ tdx_measure_acpi_tables?: boolean | null | undefined;
366
+ } | null | undefined;
367
+ kms_enabled?: boolean | null | undefined;
368
+ key_provider?: "none" | "kms" | "local" | "tpm" | null | undefined;
369
+ key_provider_id?: string | null | undefined;
370
+ local_key_provider_enabled?: boolean | null | undefined;
371
+ manifest_version?: string | number | null | undefined;
372
+ no_instance_id?: boolean | null | undefined;
373
+ runner?: string | null | undefined;
374
+ storage_fs?: "ext4" | "zfs" | null | undefined;
375
+ verity_volumes?: {
376
+ source: string;
377
+ target: string;
378
+ verity_root: string;
379
+ }[] | null | undefined;
380
+ tproxy_enabled?: boolean | null | undefined;
381
+ features?: string[] | null | undefined;
382
+ } | undefined;
383
+ init_scripts?: ("docker_cleanup" | "env_merge")[] | undefined;
384
+ init_script?: string[] | undefined;
385
+ confirm_data_wipe?: boolean | undefined;
386
+ encrypted_env?: string | undefined;
387
+ user_config?: string | undefined;
388
+ gpus?: {
389
+ gpus: {
390
+ slot: string;
391
+ product_id?: string | undefined;
392
+ }[];
393
+ attach_mode?: string | undefined;
394
+ } | undefined;
395
+ vcpu?: number | undefined;
396
+ memory?: number | undefined;
397
+ disk_size?: number | undefined;
398
+ instance_type?: string | undefined;
399
+ image?: string | undefined;
400
+ shutdown_timeout?: number | undefined;
401
+ allow_force_stop?: boolean | undefined;
402
+ prepareOnly?: boolean | undefined;
403
+ }): Promise<{
392
404
  requiresOnChainHash: false;
393
405
  correlationId: string;
394
406
  } | {
407
+ requiresOnChainHash: true;
408
+ composeHash: string;
395
409
  appId: string;
396
410
  deviceId: string;
397
- composeHash: string;
398
- requiresOnChainHash: true;
399
411
  kmsInfo: {
400
- version: string;
412
+ [x: string]: unknown;
401
413
  id: string;
402
414
  slug: string | null;
403
- chain_id: number | null;
404
415
  url: string;
416
+ version: string;
417
+ chain_id: number | null;
405
418
  kms_contract_address: `0x${string}`;
406
419
  gateway_app_id: `0x${string}`;
407
420
  k256_pubkey?: string | null | undefined;
408
- } & {
409
- [k: string]: unknown;
410
421
  };
411
422
  commitToken?: string | undefined;
412
423
  commitUrl?: string | undefined;
@@ -417,32 +428,247 @@ declare const patchCvm: {
417
428
  is_allowed: boolean;
418
429
  } | undefined;
419
430
  }>;
420
- <T extends z.ZodTypeAny>(client: import("../..").BaseClient<import("../..").ApiVersion>, params?: any, parameters?: {
431
+ <T extends z.ZodTypeAny>(client: import("../..").BaseClient<import("../..").ApiVersion>, params: {
432
+ id?: string | undefined;
433
+ uuid?: string | undefined;
434
+ app_id?: string | undefined;
435
+ instance_id?: string | undefined;
436
+ name?: string | undefined;
437
+ docker_compose_file?: string | undefined;
438
+ pre_launch_script?: string | undefined;
439
+ allowed_envs?: string[] | undefined;
440
+ public_logs?: boolean | undefined;
441
+ public_sysinfo?: boolean | undefined;
442
+ public_tcbinfo?: boolean | undefined;
443
+ compose?: {
444
+ [x: string]: unknown;
445
+ secure_time?: boolean | null | undefined;
446
+ swap_size?: string | null | undefined;
447
+ storage_discard?: boolean | null | undefined;
448
+ snapshotter?: "overlayfs" | "stargz" | null | undefined;
449
+ gateway_enabled?: boolean | null | undefined;
450
+ port_policy?: {
451
+ ports?: {
452
+ port: number;
453
+ pp?: boolean | undefined;
454
+ }[] | undefined;
455
+ restrict_mode?: boolean | undefined;
456
+ } | null | undefined;
457
+ event_log_version?: 1 | 2 | null | undefined;
458
+ requirements?: {
459
+ [x: string]: unknown;
460
+ ephemeral_data_disk?: boolean | null | undefined;
461
+ health_check?: boolean | null | undefined;
462
+ health_status_file?: string | null | undefined;
463
+ launch_token_hash?: string | null | undefined;
464
+ platforms?: string[] | null | undefined;
465
+ tdx_measure_acpi_tables?: boolean | null | undefined;
466
+ } | null | undefined;
467
+ kms_enabled?: boolean | null | undefined;
468
+ key_provider?: "none" | "kms" | "local" | "tpm" | null | undefined;
469
+ key_provider_id?: string | null | undefined;
470
+ local_key_provider_enabled?: boolean | null | undefined;
471
+ manifest_version?: string | number | null | undefined;
472
+ no_instance_id?: boolean | null | undefined;
473
+ runner?: string | null | undefined;
474
+ storage_fs?: "ext4" | "zfs" | null | undefined;
475
+ verity_volumes?: {
476
+ source: string;
477
+ target: string;
478
+ verity_root: string;
479
+ }[] | null | undefined;
480
+ tproxy_enabled?: boolean | null | undefined;
481
+ features?: string[] | null | undefined;
482
+ } | undefined;
483
+ init_scripts?: ("docker_cleanup" | "env_merge")[] | undefined;
484
+ init_script?: string[] | undefined;
485
+ confirm_data_wipe?: boolean | undefined;
486
+ encrypted_env?: string | undefined;
487
+ user_config?: string | undefined;
488
+ gpus?: {
489
+ gpus: {
490
+ slot: string;
491
+ product_id?: string | undefined;
492
+ }[];
493
+ attach_mode?: string | undefined;
494
+ } | undefined;
495
+ vcpu?: number | undefined;
496
+ memory?: number | undefined;
497
+ disk_size?: number | undefined;
498
+ instance_type?: string | undefined;
499
+ image?: string | undefined;
500
+ shutdown_timeout?: number | undefined;
501
+ allow_force_stop?: boolean | undefined;
502
+ prepareOnly?: boolean | undefined;
503
+ }, parameters: {
421
504
  schema: T;
422
- } | undefined): Promise<z.TypeOf<T>>;
423
- (client: import("../..").BaseClient<import("../..").ApiVersion>, params?: any, parameters?: {
505
+ }): Promise<z.core.output<T>>;
506
+ (client: import("../..").BaseClient<import("../..").ApiVersion>, params: {
507
+ id?: string | undefined;
508
+ uuid?: string | undefined;
509
+ app_id?: string | undefined;
510
+ instance_id?: string | undefined;
511
+ name?: string | undefined;
512
+ docker_compose_file?: string | undefined;
513
+ pre_launch_script?: string | undefined;
514
+ allowed_envs?: string[] | undefined;
515
+ public_logs?: boolean | undefined;
516
+ public_sysinfo?: boolean | undefined;
517
+ public_tcbinfo?: boolean | undefined;
518
+ compose?: {
519
+ [x: string]: unknown;
520
+ secure_time?: boolean | null | undefined;
521
+ swap_size?: string | null | undefined;
522
+ storage_discard?: boolean | null | undefined;
523
+ snapshotter?: "overlayfs" | "stargz" | null | undefined;
524
+ gateway_enabled?: boolean | null | undefined;
525
+ port_policy?: {
526
+ ports?: {
527
+ port: number;
528
+ pp?: boolean | undefined;
529
+ }[] | undefined;
530
+ restrict_mode?: boolean | undefined;
531
+ } | null | undefined;
532
+ event_log_version?: 1 | 2 | null | undefined;
533
+ requirements?: {
534
+ [x: string]: unknown;
535
+ ephemeral_data_disk?: boolean | null | undefined;
536
+ health_check?: boolean | null | undefined;
537
+ health_status_file?: string | null | undefined;
538
+ launch_token_hash?: string | null | undefined;
539
+ platforms?: string[] | null | undefined;
540
+ tdx_measure_acpi_tables?: boolean | null | undefined;
541
+ } | null | undefined;
542
+ kms_enabled?: boolean | null | undefined;
543
+ key_provider?: "none" | "kms" | "local" | "tpm" | null | undefined;
544
+ key_provider_id?: string | null | undefined;
545
+ local_key_provider_enabled?: boolean | null | undefined;
546
+ manifest_version?: string | number | null | undefined;
547
+ no_instance_id?: boolean | null | undefined;
548
+ runner?: string | null | undefined;
549
+ storage_fs?: "ext4" | "zfs" | null | undefined;
550
+ verity_volumes?: {
551
+ source: string;
552
+ target: string;
553
+ verity_root: string;
554
+ }[] | null | undefined;
555
+ tproxy_enabled?: boolean | null | undefined;
556
+ features?: string[] | null | undefined;
557
+ } | undefined;
558
+ init_scripts?: ("docker_cleanup" | "env_merge")[] | undefined;
559
+ init_script?: string[] | undefined;
560
+ confirm_data_wipe?: boolean | undefined;
561
+ encrypted_env?: string | undefined;
562
+ user_config?: string | undefined;
563
+ gpus?: {
564
+ gpus: {
565
+ slot: string;
566
+ product_id?: string | undefined;
567
+ }[];
568
+ attach_mode?: string | undefined;
569
+ } | undefined;
570
+ vcpu?: number | undefined;
571
+ memory?: number | undefined;
572
+ disk_size?: number | undefined;
573
+ instance_type?: string | undefined;
574
+ image?: string | undefined;
575
+ shutdown_timeout?: number | undefined;
576
+ allow_force_stop?: boolean | undefined;
577
+ prepareOnly?: boolean | undefined;
578
+ }, parameters: {
424
579
  schema: false;
425
- } | undefined): Promise<unknown>;
580
+ }): Promise<unknown>;
426
581
  }, safePatchCvm: {
427
- (client: import("../..").BaseClient<import("../..").ApiVersion>, params?: any): Promise<import("../..").SafeResult<{
582
+ (client: import("../..").BaseClient<import("../..").ApiVersion>, params: {
583
+ id?: string | undefined;
584
+ uuid?: string | undefined;
585
+ app_id?: string | undefined;
586
+ instance_id?: string | undefined;
587
+ name?: string | undefined;
588
+ docker_compose_file?: string | undefined;
589
+ pre_launch_script?: string | undefined;
590
+ allowed_envs?: string[] | undefined;
591
+ public_logs?: boolean | undefined;
592
+ public_sysinfo?: boolean | undefined;
593
+ public_tcbinfo?: boolean | undefined;
594
+ compose?: {
595
+ [x: string]: unknown;
596
+ secure_time?: boolean | null | undefined;
597
+ swap_size?: string | null | undefined;
598
+ storage_discard?: boolean | null | undefined;
599
+ snapshotter?: "overlayfs" | "stargz" | null | undefined;
600
+ gateway_enabled?: boolean | null | undefined;
601
+ port_policy?: {
602
+ ports?: {
603
+ port: number;
604
+ pp?: boolean | undefined;
605
+ }[] | undefined;
606
+ restrict_mode?: boolean | undefined;
607
+ } | null | undefined;
608
+ event_log_version?: 1 | 2 | null | undefined;
609
+ requirements?: {
610
+ [x: string]: unknown;
611
+ ephemeral_data_disk?: boolean | null | undefined;
612
+ health_check?: boolean | null | undefined;
613
+ health_status_file?: string | null | undefined;
614
+ launch_token_hash?: string | null | undefined;
615
+ platforms?: string[] | null | undefined;
616
+ tdx_measure_acpi_tables?: boolean | null | undefined;
617
+ } | null | undefined;
618
+ kms_enabled?: boolean | null | undefined;
619
+ key_provider?: "none" | "kms" | "local" | "tpm" | null | undefined;
620
+ key_provider_id?: string | null | undefined;
621
+ local_key_provider_enabled?: boolean | null | undefined;
622
+ manifest_version?: string | number | null | undefined;
623
+ no_instance_id?: boolean | null | undefined;
624
+ runner?: string | null | undefined;
625
+ storage_fs?: "ext4" | "zfs" | null | undefined;
626
+ verity_volumes?: {
627
+ source: string;
628
+ target: string;
629
+ verity_root: string;
630
+ }[] | null | undefined;
631
+ tproxy_enabled?: boolean | null | undefined;
632
+ features?: string[] | null | undefined;
633
+ } | undefined;
634
+ init_scripts?: ("docker_cleanup" | "env_merge")[] | undefined;
635
+ init_script?: string[] | undefined;
636
+ confirm_data_wipe?: boolean | undefined;
637
+ encrypted_env?: string | undefined;
638
+ user_config?: string | undefined;
639
+ gpus?: {
640
+ gpus: {
641
+ slot: string;
642
+ product_id?: string | undefined;
643
+ }[];
644
+ attach_mode?: string | undefined;
645
+ } | undefined;
646
+ vcpu?: number | undefined;
647
+ memory?: number | undefined;
648
+ disk_size?: number | undefined;
649
+ instance_type?: string | undefined;
650
+ image?: string | undefined;
651
+ shutdown_timeout?: number | undefined;
652
+ allow_force_stop?: boolean | undefined;
653
+ prepareOnly?: boolean | undefined;
654
+ }): Promise<import("../..").SafeResult<{
428
655
  requiresOnChainHash: false;
429
656
  correlationId: string;
430
657
  } | {
658
+ requiresOnChainHash: true;
659
+ composeHash: string;
431
660
  appId: string;
432
661
  deviceId: string;
433
- composeHash: string;
434
- requiresOnChainHash: true;
435
662
  kmsInfo: {
436
- version: string;
663
+ [x: string]: unknown;
437
664
  id: string;
438
665
  slug: string | null;
439
- chain_id: number | null;
440
666
  url: string;
667
+ version: string;
668
+ chain_id: number | null;
441
669
  kms_contract_address: `0x${string}`;
442
670
  gateway_app_id: `0x${string}`;
443
671
  k256_pubkey?: string | null | undefined;
444
- } & {
445
- [k: string]: unknown;
446
672
  };
447
673
  commitToken?: string | undefined;
448
674
  commitUrl?: string | undefined;
@@ -453,11 +679,155 @@ declare const patchCvm: {
453
679
  is_allowed: boolean;
454
680
  } | undefined;
455
681
  }>>;
456
- <T extends z.ZodTypeAny>(client: import("../..").BaseClient<import("../..").ApiVersion>, params?: any, parameters?: {
682
+ <T extends z.ZodTypeAny>(client: import("../..").BaseClient<import("../..").ApiVersion>, params: {
683
+ id?: string | undefined;
684
+ uuid?: string | undefined;
685
+ app_id?: string | undefined;
686
+ instance_id?: string | undefined;
687
+ name?: string | undefined;
688
+ docker_compose_file?: string | undefined;
689
+ pre_launch_script?: string | undefined;
690
+ allowed_envs?: string[] | undefined;
691
+ public_logs?: boolean | undefined;
692
+ public_sysinfo?: boolean | undefined;
693
+ public_tcbinfo?: boolean | undefined;
694
+ compose?: {
695
+ [x: string]: unknown;
696
+ secure_time?: boolean | null | undefined;
697
+ swap_size?: string | null | undefined;
698
+ storage_discard?: boolean | null | undefined;
699
+ snapshotter?: "overlayfs" | "stargz" | null | undefined;
700
+ gateway_enabled?: boolean | null | undefined;
701
+ port_policy?: {
702
+ ports?: {
703
+ port: number;
704
+ pp?: boolean | undefined;
705
+ }[] | undefined;
706
+ restrict_mode?: boolean | undefined;
707
+ } | null | undefined;
708
+ event_log_version?: 1 | 2 | null | undefined;
709
+ requirements?: {
710
+ [x: string]: unknown;
711
+ ephemeral_data_disk?: boolean | null | undefined;
712
+ health_check?: boolean | null | undefined;
713
+ health_status_file?: string | null | undefined;
714
+ launch_token_hash?: string | null | undefined;
715
+ platforms?: string[] | null | undefined;
716
+ tdx_measure_acpi_tables?: boolean | null | undefined;
717
+ } | null | undefined;
718
+ kms_enabled?: boolean | null | undefined;
719
+ key_provider?: "none" | "kms" | "local" | "tpm" | null | undefined;
720
+ key_provider_id?: string | null | undefined;
721
+ local_key_provider_enabled?: boolean | null | undefined;
722
+ manifest_version?: string | number | null | undefined;
723
+ no_instance_id?: boolean | null | undefined;
724
+ runner?: string | null | undefined;
725
+ storage_fs?: "ext4" | "zfs" | null | undefined;
726
+ verity_volumes?: {
727
+ source: string;
728
+ target: string;
729
+ verity_root: string;
730
+ }[] | null | undefined;
731
+ tproxy_enabled?: boolean | null | undefined;
732
+ features?: string[] | null | undefined;
733
+ } | undefined;
734
+ init_scripts?: ("docker_cleanup" | "env_merge")[] | undefined;
735
+ init_script?: string[] | undefined;
736
+ confirm_data_wipe?: boolean | undefined;
737
+ encrypted_env?: string | undefined;
738
+ user_config?: string | undefined;
739
+ gpus?: {
740
+ gpus: {
741
+ slot: string;
742
+ product_id?: string | undefined;
743
+ }[];
744
+ attach_mode?: string | undefined;
745
+ } | undefined;
746
+ vcpu?: number | undefined;
747
+ memory?: number | undefined;
748
+ disk_size?: number | undefined;
749
+ instance_type?: string | undefined;
750
+ image?: string | undefined;
751
+ shutdown_timeout?: number | undefined;
752
+ allow_force_stop?: boolean | undefined;
753
+ prepareOnly?: boolean | undefined;
754
+ }, parameters: {
457
755
  schema: T;
458
- } | undefined): Promise<import("../..").SafeResult<z.TypeOf<T>>>;
459
- (client: import("../..").BaseClient<import("../..").ApiVersion>, params?: any, parameters?: {
756
+ }): Promise<import("../..").SafeResult<z.core.output<T>>>;
757
+ (client: import("../..").BaseClient<import("../..").ApiVersion>, params: {
758
+ id?: string | undefined;
759
+ uuid?: string | undefined;
760
+ app_id?: string | undefined;
761
+ instance_id?: string | undefined;
762
+ name?: string | undefined;
763
+ docker_compose_file?: string | undefined;
764
+ pre_launch_script?: string | undefined;
765
+ allowed_envs?: string[] | undefined;
766
+ public_logs?: boolean | undefined;
767
+ public_sysinfo?: boolean | undefined;
768
+ public_tcbinfo?: boolean | undefined;
769
+ compose?: {
770
+ [x: string]: unknown;
771
+ secure_time?: boolean | null | undefined;
772
+ swap_size?: string | null | undefined;
773
+ storage_discard?: boolean | null | undefined;
774
+ snapshotter?: "overlayfs" | "stargz" | null | undefined;
775
+ gateway_enabled?: boolean | null | undefined;
776
+ port_policy?: {
777
+ ports?: {
778
+ port: number;
779
+ pp?: boolean | undefined;
780
+ }[] | undefined;
781
+ restrict_mode?: boolean | undefined;
782
+ } | null | undefined;
783
+ event_log_version?: 1 | 2 | null | undefined;
784
+ requirements?: {
785
+ [x: string]: unknown;
786
+ ephemeral_data_disk?: boolean | null | undefined;
787
+ health_check?: boolean | null | undefined;
788
+ health_status_file?: string | null | undefined;
789
+ launch_token_hash?: string | null | undefined;
790
+ platforms?: string[] | null | undefined;
791
+ tdx_measure_acpi_tables?: boolean | null | undefined;
792
+ } | null | undefined;
793
+ kms_enabled?: boolean | null | undefined;
794
+ key_provider?: "none" | "kms" | "local" | "tpm" | null | undefined;
795
+ key_provider_id?: string | null | undefined;
796
+ local_key_provider_enabled?: boolean | null | undefined;
797
+ manifest_version?: string | number | null | undefined;
798
+ no_instance_id?: boolean | null | undefined;
799
+ runner?: string | null | undefined;
800
+ storage_fs?: "ext4" | "zfs" | null | undefined;
801
+ verity_volumes?: {
802
+ source: string;
803
+ target: string;
804
+ verity_root: string;
805
+ }[] | null | undefined;
806
+ tproxy_enabled?: boolean | null | undefined;
807
+ features?: string[] | null | undefined;
808
+ } | undefined;
809
+ init_scripts?: ("docker_cleanup" | "env_merge")[] | undefined;
810
+ init_script?: string[] | undefined;
811
+ confirm_data_wipe?: boolean | undefined;
812
+ encrypted_env?: string | undefined;
813
+ user_config?: string | undefined;
814
+ gpus?: {
815
+ gpus: {
816
+ slot: string;
817
+ product_id?: string | undefined;
818
+ }[];
819
+ attach_mode?: string | undefined;
820
+ } | undefined;
821
+ vcpu?: number | undefined;
822
+ memory?: number | undefined;
823
+ disk_size?: number | undefined;
824
+ instance_type?: string | undefined;
825
+ image?: string | undefined;
826
+ shutdown_timeout?: number | undefined;
827
+ allow_force_stop?: boolean | undefined;
828
+ prepareOnly?: boolean | undefined;
829
+ }, parameters: {
460
830
  schema: false;
461
- } | undefined): Promise<import("../..").SafeResult<unknown>>;
831
+ }): Promise<import("../..").SafeResult<unknown>>;
462
832
  };
463
833
  export { patchCvm, safePatchCvm };