@phala/cloud 0.6.4 → 0.6.6-beta.1

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 (95) hide show
  1. package/README.md +6 -6
  2. package/dist/actions/api_tokens/revoke_current_api_token.d.ts +2 -2
  3. package/dist/actions/apps/app_launch_token.d.ts +4 -4
  4. package/dist/actions/apps/check_app_is_allowed.d.ts +4 -4
  5. package/dist/actions/apps/create_app_instance.d.ts +20 -20
  6. package/dist/actions/apps/get_app_attestation.d.ts +4 -4
  7. package/dist/actions/blockchains/abi/dstack_app.d.ts +403 -1
  8. package/dist/actions/blockchains/add_compose_hash.d.ts +7 -0
  9. package/dist/actions/blockchains/add_device.d.ts +7 -0
  10. package/dist/actions/blockchains/check_compose_hash_allowed.d.ts +4 -1
  11. package/dist/actions/blockchains/check_device_allowed.d.ts +5 -2
  12. package/dist/actions/blockchains/check_on_chain_prerequisites.d.ts +7 -2
  13. package/dist/actions/blockchains/epoch_compat.d.ts +106 -0
  14. package/dist/actions/blockchains/get_allowed_devices.d.ts +10 -2
  15. package/dist/actions/blockchains/remove_device.d.ts +7 -0
  16. package/dist/actions/cvms/commit_cvm_compose_file_update.d.ts +4 -4
  17. package/dist/actions/cvms/commit_cvm_update.d.ts +20 -20
  18. package/dist/actions/cvms/confirm_cvm_patch.d.ts +14 -14
  19. package/dist/actions/cvms/cvm_annotations.d.ts +10 -10
  20. package/dist/actions/cvms/delete_cvm.d.ts +2 -2
  21. package/dist/actions/cvms/get_available_os_images.d.ts +2 -2
  22. package/dist/actions/cvms/get_cvm_attestation.d.ts +4 -4
  23. package/dist/actions/cvms/get_cvm_compose_file.d.ts +10 -10
  24. package/dist/actions/cvms/get_cvm_containers_stats.d.ts +4 -4
  25. package/dist/actions/cvms/get_cvm_docker_compose.d.ts +2 -2
  26. package/dist/actions/cvms/get_cvm_info.d.ts +24 -8
  27. package/dist/actions/cvms/get_cvm_init_scripts.d.ts +2 -2
  28. package/dist/actions/cvms/get_cvm_network.d.ts +2 -2
  29. package/dist/actions/cvms/get_cvm_prelaunch_script.d.ts +2 -2
  30. package/dist/actions/cvms/get_cvm_state.d.ts +6 -6
  31. package/dist/actions/cvms/get_cvm_stats.d.ts +2 -2
  32. package/dist/actions/cvms/get_cvm_status_batch.d.ts +10 -10
  33. package/dist/actions/cvms/get_cvm_user_config.d.ts +4 -4
  34. package/dist/actions/cvms/get_prelaunch_script_upgrade_status.d.ts +2 -2
  35. package/dist/actions/cvms/logs.d.ts +10 -9
  36. package/dist/actions/cvms/patch_cvm.d.ts +10 -10
  37. package/dist/actions/cvms/provision_cvm.d.ts +23 -20
  38. package/dist/actions/cvms/provision_cvm_compose_file_update.d.ts +49 -49
  39. package/dist/actions/cvms/put_cvm_init_scripts.d.ts +8 -8
  40. package/dist/actions/cvms/refresh_cvm_instance_id.d.ts +25 -25
  41. package/dist/actions/cvms/refresh_cvm_instance_ids.d.ts +25 -25
  42. package/dist/actions/cvms/update_cvm_envs.d.ts +10 -10
  43. package/dist/actions/cvms/update_cvm_resources.d.ts +2 -2
  44. package/dist/actions/cvms/update_cvm_visibility.d.ts +14 -14
  45. package/dist/actions/cvms/update_docker_compose.d.ts +10 -10
  46. package/dist/actions/cvms/update_os_image.d.ts +8 -8
  47. package/dist/actions/cvms/update_prelaunch_script.d.ts +10 -10
  48. package/dist/actions/cvms/upgrade_prelaunch_script.d.ts +2 -2
  49. package/dist/actions/cvms/watch_cvm_state.d.ts +2 -2
  50. package/dist/actions/domains/create_app_domain.d.ts +139 -0
  51. package/dist/actions/domains/delete_app_domain.d.ts +120 -0
  52. package/dist/actions/domains/get_app_domain_guide.d.ts +67 -0
  53. package/dist/actions/domains/list_app_domains.d.ts +107 -0
  54. package/dist/actions/domains/list_domains.d.ts +157 -0
  55. package/dist/actions/domains/merge_app_domain_ingress.d.ts +120 -0
  56. package/dist/actions/domains/preflight_app_domain.d.ts +110 -0
  57. package/dist/actions/domains/schemas.d.ts +82 -0
  58. package/dist/actions/domains/verify_app_domain.d.ts +142 -0
  59. package/dist/actions/get_available_nodes.d.ts +16 -16
  60. package/dist/actions/index.d.ts +11 -1
  61. package/dist/actions/kms/get_app_env_encrypt_pubkey.d.ts +2 -2
  62. package/dist/actions/kms/get_kms_contract.d.ts +2 -2
  63. package/dist/actions/kms/get_kms_info.d.ts +2 -2
  64. package/dist/actions/kms/get_kms_list.d.ts +2 -2
  65. package/dist/actions/kms/get_kms_onchain_detail.d.ts +10 -10
  66. package/dist/actions/kms/list_kms_contract_nodes.d.ts +2 -2
  67. package/dist/actions/kms/list_kms_contracts.d.ts +2 -2
  68. package/dist/actions/kms/next_app_ids.d.ts +2 -2
  69. package/dist/actions/list-instance-types.d.ts +8 -8
  70. package/dist/actions/os_images/get_os_images.d.ts +2 -2
  71. package/dist/actions/ssh_keys/create_ssh_key.d.ts +6 -6
  72. package/dist/actions/ssh_keys/delete_ssh_key.d.ts +2 -2
  73. package/dist/actions/ssh_keys/get_cvm_ssh_keys.d.ts +2 -2
  74. package/dist/actions/ssh_keys/import_github_profile.d.ts +2 -2
  75. package/dist/actions/ssh_keys/sync_github_ssh_keys.d.ts +2 -2
  76. package/dist/actions/ssh_keys/update_cvm_ssh_keys.d.ts +8 -8
  77. package/dist/actions/workspaces/get_workspace.d.ts +8 -8
  78. package/dist/actions/workspaces/get_workspace_nodes.d.ts +12 -12
  79. package/dist/actions/workspaces/get_workspace_quotas.d.ts +2 -2
  80. package/dist/actions/workspaces/list_workspaces.d.ts +10 -10
  81. package/dist/client.d.ts +1 -1
  82. package/dist/create-client.d.ts +263 -134
  83. package/dist/index.js +2468 -1497
  84. package/dist/index.mjs +2447 -1520
  85. package/dist/types/app_compose.d.ts +2 -2
  86. package/dist/types/app_info_v20260121.d.ts +84 -36
  87. package/dist/types/client.d.ts +3 -3
  88. package/dist/types/cvm_info_v20251028.d.ts +1 -0
  89. package/dist/types/cvm_info_v20260121.d.ts +225 -22
  90. package/dist/types/version-mappings.d.ts +11 -11
  91. package/dist/utils/define-action.d.ts +4 -4
  92. package/dist/utils/errors.d.ts +4 -0
  93. package/dist/utils/network.d.ts +6 -6
  94. package/dist/version.d.ts +1 -0
  95. package/package.json +25 -12
@@ -133,23 +133,23 @@ export declare const UpdateCvmEnvsRequestSchema: z.ZodPipe<z.ZodObject<{
133
133
  transaction_hash: string | undefined;
134
134
  };
135
135
  _raw: {
136
- encrypted_env: string;
137
136
  id?: string | undefined;
138
137
  uuid?: string | undefined;
139
138
  app_id?: string | undefined;
140
139
  instance_id?: string | undefined;
141
140
  name?: string | undefined;
141
+ encrypted_env: string;
142
142
  env_keys?: string[] | undefined;
143
143
  compose_hash?: string | undefined;
144
144
  transaction_hash?: string | undefined;
145
145
  };
146
146
  }, {
147
- encrypted_env: string;
148
147
  id?: string | undefined;
149
148
  uuid?: string | undefined;
150
149
  app_id?: string | undefined;
151
150
  instance_id?: string | undefined;
152
151
  name?: string | undefined;
152
+ encrypted_env: string;
153
153
  env_keys?: string[] | undefined;
154
154
  compose_hash?: string | undefined;
155
155
  transaction_hash?: string | undefined;
@@ -253,12 +253,12 @@ export type UpdateCvmEnvsPreconditionRequired = z.infer<typeof UpdateCvmEnvsPrec
253
253
  */
254
254
  declare const updateCvmEnvs: {
255
255
  (client: Client<import("../..").ApiVersion>, params: {
256
- encrypted_env: string;
257
256
  id?: string | undefined;
258
257
  uuid?: string | undefined;
259
258
  app_id?: string | undefined;
260
259
  instance_id?: string | undefined;
261
260
  name?: string | undefined;
261
+ encrypted_env: string;
262
262
  env_keys?: string[] | undefined;
263
263
  compose_hash?: string | undefined;
264
264
  transaction_hash?: string | undefined;
@@ -286,25 +286,25 @@ declare const updateCvmEnvs: {
286
286
  };
287
287
  }>;
288
288
  <T extends z.ZodTypeAny>(client: Client<import("../..").ApiVersion>, params: {
289
- encrypted_env: string;
290
289
  id?: string | undefined;
291
290
  uuid?: string | undefined;
292
291
  app_id?: string | undefined;
293
292
  instance_id?: string | undefined;
294
293
  name?: string | undefined;
294
+ encrypted_env: string;
295
295
  env_keys?: string[] | undefined;
296
296
  compose_hash?: string | undefined;
297
297
  transaction_hash?: string | undefined;
298
298
  }, parameters: {
299
299
  schema: T;
300
- }): Promise<z.core.output<T>>;
300
+ }): Promise<z.infer<T>>;
301
301
  (client: Client<import("../..").ApiVersion>, params: {
302
- encrypted_env: string;
303
302
  id?: string | undefined;
304
303
  uuid?: string | undefined;
305
304
  app_id?: string | undefined;
306
305
  instance_id?: string | undefined;
307
306
  name?: string | undefined;
307
+ encrypted_env: string;
308
308
  env_keys?: string[] | undefined;
309
309
  compose_hash?: string | undefined;
310
310
  transaction_hash?: string | undefined;
@@ -313,12 +313,12 @@ declare const updateCvmEnvs: {
313
313
  }): Promise<unknown>;
314
314
  }, safeUpdateCvmEnvs: {
315
315
  (client: Client<import("../..").ApiVersion>, params: {
316
- encrypted_env: string;
317
316
  id?: string | undefined;
318
317
  uuid?: string | undefined;
319
318
  app_id?: string | undefined;
320
319
  instance_id?: string | undefined;
321
320
  name?: string | undefined;
321
+ encrypted_env: string;
322
322
  env_keys?: string[] | undefined;
323
323
  compose_hash?: string | undefined;
324
324
  transaction_hash?: string | undefined;
@@ -346,25 +346,25 @@ declare const updateCvmEnvs: {
346
346
  };
347
347
  }>>;
348
348
  <T extends z.ZodTypeAny>(client: Client<import("../..").ApiVersion>, params: {
349
- encrypted_env: string;
350
349
  id?: string | undefined;
351
350
  uuid?: string | undefined;
352
351
  app_id?: string | undefined;
353
352
  instance_id?: string | undefined;
354
353
  name?: string | undefined;
354
+ encrypted_env: string;
355
355
  env_keys?: string[] | undefined;
356
356
  compose_hash?: string | undefined;
357
357
  transaction_hash?: string | undefined;
358
358
  }, parameters: {
359
359
  schema: T;
360
- }): Promise<import("../..").SafeResult<z.core.output<T>>>;
360
+ }): Promise<import("../..").SafeResult<z.infer<T>>>;
361
361
  (client: Client<import("../..").ApiVersion>, params: {
362
- encrypted_env: string;
363
362
  id?: string | undefined;
364
363
  uuid?: string | undefined;
365
364
  app_id?: string | undefined;
366
365
  instance_id?: string | undefined;
367
366
  name?: string | undefined;
367
+ encrypted_env: string;
368
368
  env_keys?: string[] | undefined;
369
369
  compose_hash?: string | undefined;
370
370
  transaction_hash?: string | undefined;
@@ -68,7 +68,7 @@ declare const updateCvmResources: {
68
68
  allow_restart?: boolean | undefined;
69
69
  }, parameters: {
70
70
  schema: T;
71
- }): Promise<z.core.output<T>>;
71
+ }): Promise<z.infer<T>>;
72
72
  (client: import("../..").BaseClient<import("../..").ApiVersion>, params: {
73
73
  id?: string | undefined;
74
74
  uuid?: string | undefined;
@@ -113,7 +113,7 @@ declare const updateCvmResources: {
113
113
  allow_restart?: boolean | undefined;
114
114
  }, parameters: {
115
115
  schema: T;
116
- }): Promise<import("../..").SafeResult<z.core.output<T>>>;
116
+ }): Promise<import("../..").SafeResult<z.infer<T>>>;
117
117
  (client: import("../..").BaseClient<import("../..").ApiVersion>, params: {
118
118
  id?: string | undefined;
119
119
  uuid?: string | undefined;
@@ -49,13 +49,13 @@ export declare const UpdateCvmVisibilityResponseSchema: z.ZodObject<{
49
49
  export type UpdateCvmVisibilityResponse = z.infer<typeof UpdateCvmVisibilityResponseSchema>;
50
50
  declare const updateCvmVisibility: {
51
51
  (client: import("../..").BaseClient<import("../..").ApiVersion>, params: {
52
- public_sysinfo: boolean;
53
- public_logs: boolean;
54
52
  id?: string | undefined;
55
53
  uuid?: string | undefined;
56
54
  app_id?: string | undefined;
57
55
  instance_id?: string | undefined;
58
56
  name?: string | undefined;
57
+ public_sysinfo: boolean;
58
+ public_logs: boolean;
59
59
  public_tcbinfo?: boolean | undefined;
60
60
  }): Promise<{
61
61
  message: string;
@@ -63,38 +63,38 @@ declare const updateCvmVisibility: {
63
63
  status: string;
64
64
  }>;
65
65
  <T extends z.ZodTypeAny>(client: import("../..").BaseClient<import("../..").ApiVersion>, params: {
66
- public_sysinfo: boolean;
67
- public_logs: boolean;
68
66
  id?: string | undefined;
69
67
  uuid?: string | undefined;
70
68
  app_id?: string | undefined;
71
69
  instance_id?: string | undefined;
72
70
  name?: string | undefined;
71
+ public_sysinfo: boolean;
72
+ public_logs: boolean;
73
73
  public_tcbinfo?: boolean | undefined;
74
74
  }, parameters: {
75
75
  schema: T;
76
- }): Promise<z.core.output<T>>;
76
+ }): Promise<z.infer<T>>;
77
77
  (client: import("../..").BaseClient<import("../..").ApiVersion>, params: {
78
- public_sysinfo: boolean;
79
- public_logs: boolean;
80
78
  id?: string | undefined;
81
79
  uuid?: string | undefined;
82
80
  app_id?: string | undefined;
83
81
  instance_id?: string | undefined;
84
82
  name?: string | undefined;
83
+ public_sysinfo: boolean;
84
+ public_logs: boolean;
85
85
  public_tcbinfo?: boolean | undefined;
86
86
  }, parameters: {
87
87
  schema: false;
88
88
  }): Promise<unknown>;
89
89
  }, safeUpdateCvmVisibility: {
90
90
  (client: import("../..").BaseClient<import("../..").ApiVersion>, params: {
91
- public_sysinfo: boolean;
92
- public_logs: boolean;
93
91
  id?: string | undefined;
94
92
  uuid?: string | undefined;
95
93
  app_id?: string | undefined;
96
94
  instance_id?: string | undefined;
97
95
  name?: string | undefined;
96
+ public_sysinfo: boolean;
97
+ public_logs: boolean;
98
98
  public_tcbinfo?: boolean | undefined;
99
99
  }): Promise<import("../..").SafeResult<{
100
100
  message: string;
@@ -102,25 +102,25 @@ declare const updateCvmVisibility: {
102
102
  status: string;
103
103
  }>>;
104
104
  <T extends z.ZodTypeAny>(client: import("../..").BaseClient<import("../..").ApiVersion>, params: {
105
- public_sysinfo: boolean;
106
- public_logs: boolean;
107
105
  id?: string | undefined;
108
106
  uuid?: string | undefined;
109
107
  app_id?: string | undefined;
110
108
  instance_id?: string | undefined;
111
109
  name?: string | undefined;
110
+ public_sysinfo: boolean;
111
+ public_logs: boolean;
112
112
  public_tcbinfo?: boolean | undefined;
113
113
  }, parameters: {
114
114
  schema: T;
115
- }): Promise<import("../..").SafeResult<z.core.output<T>>>;
115
+ }): Promise<import("../..").SafeResult<z.infer<T>>>;
116
116
  (client: import("../..").BaseClient<import("../..").ApiVersion>, params: {
117
- public_sysinfo: boolean;
118
- public_logs: boolean;
119
117
  id?: string | undefined;
120
118
  uuid?: string | undefined;
121
119
  app_id?: string | undefined;
122
120
  instance_id?: string | undefined;
123
121
  name?: string | undefined;
122
+ public_sysinfo: boolean;
123
+ public_logs: boolean;
124
124
  public_tcbinfo?: boolean | undefined;
125
125
  }, parameters: {
126
126
  schema: false;
@@ -137,22 +137,22 @@ export declare const UpdateDockerComposeRequestSchema: z.ZodPipe<z.ZodObject<{
137
137
  transaction_hash: string | undefined;
138
138
  };
139
139
  _raw: {
140
- docker_compose_file: string;
141
140
  id?: string | undefined;
142
141
  uuid?: string | undefined;
143
142
  app_id?: string | undefined;
144
143
  instance_id?: string | undefined;
145
144
  name?: string | undefined;
145
+ docker_compose_file: string;
146
146
  compose_hash?: string | undefined;
147
147
  transaction_hash?: string | undefined;
148
148
  };
149
149
  }, {
150
- docker_compose_file: string;
151
150
  id?: string | undefined;
152
151
  uuid?: string | undefined;
153
152
  app_id?: string | undefined;
154
153
  instance_id?: string | undefined;
155
154
  name?: string | undefined;
155
+ docker_compose_file: string;
156
156
  compose_hash?: string | undefined;
157
157
  transaction_hash?: string | undefined;
158
158
  }>>;
@@ -256,12 +256,12 @@ export type UpdateDockerComposePreconditionRequired = z.infer<typeof UpdateDocke
256
256
  */
257
257
  declare const updateDockerCompose: {
258
258
  (client: Client<import("../..").ApiVersion>, params: {
259
- docker_compose_file: string;
260
259
  id?: string | undefined;
261
260
  uuid?: string | undefined;
262
261
  app_id?: string | undefined;
263
262
  instance_id?: string | undefined;
264
263
  name?: string | undefined;
264
+ docker_compose_file: string;
265
265
  compose_hash?: string | undefined;
266
266
  transaction_hash?: string | undefined;
267
267
  }): Promise<{
@@ -290,24 +290,24 @@ declare const updateDockerCompose: {
290
290
  message: string;
291
291
  }>;
292
292
  <T extends z.ZodTypeAny>(client: Client<import("../..").ApiVersion>, params: {
293
- docker_compose_file: string;
294
293
  id?: string | undefined;
295
294
  uuid?: string | undefined;
296
295
  app_id?: string | undefined;
297
296
  instance_id?: string | undefined;
298
297
  name?: string | undefined;
298
+ docker_compose_file: string;
299
299
  compose_hash?: string | undefined;
300
300
  transaction_hash?: string | undefined;
301
301
  }, parameters: {
302
302
  schema: T;
303
- }): Promise<z.core.output<T>>;
303
+ }): Promise<z.infer<T>>;
304
304
  (client: Client<import("../..").ApiVersion>, params: {
305
- docker_compose_file: string;
306
305
  id?: string | undefined;
307
306
  uuid?: string | undefined;
308
307
  app_id?: string | undefined;
309
308
  instance_id?: string | undefined;
310
309
  name?: string | undefined;
310
+ docker_compose_file: string;
311
311
  compose_hash?: string | undefined;
312
312
  transaction_hash?: string | undefined;
313
313
  }, parameters: {
@@ -315,12 +315,12 @@ declare const updateDockerCompose: {
315
315
  }): Promise<unknown>;
316
316
  }, safeUpdateDockerCompose: {
317
317
  (client: Client<import("../..").ApiVersion>, params: {
318
- docker_compose_file: string;
319
318
  id?: string | undefined;
320
319
  uuid?: string | undefined;
321
320
  app_id?: string | undefined;
322
321
  instance_id?: string | undefined;
323
322
  name?: string | undefined;
323
+ docker_compose_file: string;
324
324
  compose_hash?: string | undefined;
325
325
  transaction_hash?: string | undefined;
326
326
  }): Promise<import("../..").SafeResult<{
@@ -349,24 +349,24 @@ declare const updateDockerCompose: {
349
349
  message: string;
350
350
  }>>;
351
351
  <T extends z.ZodTypeAny>(client: Client<import("../..").ApiVersion>, params: {
352
- docker_compose_file: string;
353
352
  id?: string | undefined;
354
353
  uuid?: string | undefined;
355
354
  app_id?: string | undefined;
356
355
  instance_id?: string | undefined;
357
356
  name?: string | undefined;
357
+ docker_compose_file: string;
358
358
  compose_hash?: string | undefined;
359
359
  transaction_hash?: string | undefined;
360
360
  }, parameters: {
361
361
  schema: T;
362
- }): Promise<import("../..").SafeResult<z.core.output<T>>>;
362
+ }): Promise<import("../..").SafeResult<z.infer<T>>>;
363
363
  (client: Client<import("../..").ApiVersion>, params: {
364
- docker_compose_file: string;
365
364
  id?: string | undefined;
366
365
  uuid?: string | undefined;
367
366
  app_id?: string | undefined;
368
367
  instance_id?: string | undefined;
369
368
  name?: string | undefined;
369
+ docker_compose_file: string;
370
370
  compose_hash?: string | undefined;
371
371
  transaction_hash?: string | undefined;
372
372
  }, parameters: {
@@ -31,59 +31,59 @@ export declare const UpdateOsImageRequestSchema: z.ZodObject<{
31
31
  export type UpdateOsImageRequest = z.infer<typeof UpdateOsImageRequestSchema>;
32
32
  declare const updateOsImage: {
33
33
  (client: import("../..").BaseClient<import("../..").ApiVersion>, params: {
34
- os_image_name: string;
35
34
  id?: string | undefined;
36
35
  uuid?: string | undefined;
37
36
  app_id?: string | undefined;
38
37
  instance_id?: string | undefined;
39
38
  name?: string | undefined;
39
+ os_image_name: string;
40
40
  }): Promise<void>;
41
41
  <T extends z.ZodTypeAny>(client: import("../..").BaseClient<import("../..").ApiVersion>, params: {
42
- os_image_name: string;
43
42
  id?: string | undefined;
44
43
  uuid?: string | undefined;
45
44
  app_id?: string | undefined;
46
45
  instance_id?: string | undefined;
47
46
  name?: string | undefined;
47
+ os_image_name: string;
48
48
  }, parameters: {
49
49
  schema: T;
50
- }): Promise<z.core.output<T>>;
50
+ }): Promise<z.infer<T>>;
51
51
  (client: import("../..").BaseClient<import("../..").ApiVersion>, params: {
52
- os_image_name: string;
53
52
  id?: string | undefined;
54
53
  uuid?: string | undefined;
55
54
  app_id?: string | undefined;
56
55
  instance_id?: string | undefined;
57
56
  name?: string | undefined;
57
+ os_image_name: string;
58
58
  }, parameters: {
59
59
  schema: false;
60
60
  }): Promise<unknown>;
61
61
  }, safeUpdateOsImage: {
62
62
  (client: import("../..").BaseClient<import("../..").ApiVersion>, params: {
63
- os_image_name: string;
64
63
  id?: string | undefined;
65
64
  uuid?: string | undefined;
66
65
  app_id?: string | undefined;
67
66
  instance_id?: string | undefined;
68
67
  name?: string | undefined;
68
+ os_image_name: string;
69
69
  }): Promise<import("../..").SafeResult<void>>;
70
70
  <T extends z.ZodTypeAny>(client: import("../..").BaseClient<import("../..").ApiVersion>, params: {
71
- os_image_name: string;
72
71
  id?: string | undefined;
73
72
  uuid?: string | undefined;
74
73
  app_id?: string | undefined;
75
74
  instance_id?: string | undefined;
76
75
  name?: string | undefined;
76
+ os_image_name: string;
77
77
  }, parameters: {
78
78
  schema: T;
79
- }): Promise<import("../..").SafeResult<z.core.output<T>>>;
79
+ }): Promise<import("../..").SafeResult<z.infer<T>>>;
80
80
  (client: import("../..").BaseClient<import("../..").ApiVersion>, params: {
81
- os_image_name: string;
82
81
  id?: string | undefined;
83
82
  uuid?: string | undefined;
84
83
  app_id?: string | undefined;
85
84
  instance_id?: string | undefined;
86
85
  name?: string | undefined;
86
+ os_image_name: string;
87
87
  }, parameters: {
88
88
  schema: false;
89
89
  }): Promise<import("../..").SafeResult<unknown>>;
@@ -134,22 +134,22 @@ export declare const UpdatePreLaunchScriptRequestSchema: z.ZodPipe<z.ZodObject<{
134
134
  transaction_hash: string | undefined;
135
135
  };
136
136
  _raw: {
137
- pre_launch_script: string;
138
137
  id?: string | undefined;
139
138
  uuid?: string | undefined;
140
139
  app_id?: string | undefined;
141
140
  instance_id?: string | undefined;
142
141
  name?: string | undefined;
142
+ pre_launch_script: string;
143
143
  compose_hash?: string | undefined;
144
144
  transaction_hash?: string | undefined;
145
145
  };
146
146
  }, {
147
- pre_launch_script: string;
148
147
  id?: string | undefined;
149
148
  uuid?: string | undefined;
150
149
  app_id?: string | undefined;
151
150
  instance_id?: string | undefined;
152
151
  name?: string | undefined;
152
+ pre_launch_script: string;
153
153
  compose_hash?: string | undefined;
154
154
  transaction_hash?: string | undefined;
155
155
  }>>;
@@ -253,12 +253,12 @@ export type UpdatePreLaunchScriptPreconditionRequired = z.infer<typeof UpdatePre
253
253
  */
254
254
  declare const updatePreLaunchScript: {
255
255
  (client: Client<import("../..").ApiVersion>, params: {
256
- pre_launch_script: string;
257
256
  id?: string | undefined;
258
257
  uuid?: string | undefined;
259
258
  app_id?: string | undefined;
260
259
  instance_id?: string | undefined;
261
260
  name?: string | undefined;
261
+ pre_launch_script: string;
262
262
  compose_hash?: string | undefined;
263
263
  transaction_hash?: string | undefined;
264
264
  }): Promise<{
@@ -287,24 +287,24 @@ declare const updatePreLaunchScript: {
287
287
  message: string;
288
288
  }>;
289
289
  <T extends z.ZodTypeAny>(client: Client<import("../..").ApiVersion>, params: {
290
- pre_launch_script: string;
291
290
  id?: string | undefined;
292
291
  uuid?: string | undefined;
293
292
  app_id?: string | undefined;
294
293
  instance_id?: string | undefined;
295
294
  name?: string | undefined;
295
+ pre_launch_script: string;
296
296
  compose_hash?: string | undefined;
297
297
  transaction_hash?: string | undefined;
298
298
  }, parameters: {
299
299
  schema: T;
300
- }): Promise<z.core.output<T>>;
300
+ }): Promise<z.infer<T>>;
301
301
  (client: Client<import("../..").ApiVersion>, params: {
302
- pre_launch_script: string;
303
302
  id?: string | undefined;
304
303
  uuid?: string | undefined;
305
304
  app_id?: string | undefined;
306
305
  instance_id?: string | undefined;
307
306
  name?: string | undefined;
307
+ pre_launch_script: string;
308
308
  compose_hash?: string | undefined;
309
309
  transaction_hash?: string | undefined;
310
310
  }, parameters: {
@@ -312,12 +312,12 @@ declare const updatePreLaunchScript: {
312
312
  }): Promise<unknown>;
313
313
  }, safeUpdatePreLaunchScript: {
314
314
  (client: Client<import("../..").ApiVersion>, params: {
315
- pre_launch_script: string;
316
315
  id?: string | undefined;
317
316
  uuid?: string | undefined;
318
317
  app_id?: string | undefined;
319
318
  instance_id?: string | undefined;
320
319
  name?: string | undefined;
320
+ pre_launch_script: string;
321
321
  compose_hash?: string | undefined;
322
322
  transaction_hash?: string | undefined;
323
323
  }): Promise<import("../..").SafeResult<{
@@ -346,24 +346,24 @@ declare const updatePreLaunchScript: {
346
346
  message: string;
347
347
  }>>;
348
348
  <T extends z.ZodTypeAny>(client: Client<import("../..").ApiVersion>, params: {
349
- pre_launch_script: string;
350
349
  id?: string | undefined;
351
350
  uuid?: string | undefined;
352
351
  app_id?: string | undefined;
353
352
  instance_id?: string | undefined;
354
353
  name?: string | undefined;
354
+ pre_launch_script: string;
355
355
  compose_hash?: string | undefined;
356
356
  transaction_hash?: string | undefined;
357
357
  }, parameters: {
358
358
  schema: T;
359
- }): Promise<import("../..").SafeResult<z.core.output<T>>>;
359
+ }): Promise<import("../..").SafeResult<z.infer<T>>>;
360
360
  (client: Client<import("../..").ApiVersion>, params: {
361
- pre_launch_script: string;
362
361
  id?: string | undefined;
363
362
  uuid?: string | undefined;
364
363
  app_id?: string | undefined;
365
364
  instance_id?: string | undefined;
366
365
  name?: string | undefined;
366
+ pre_launch_script: string;
367
367
  compose_hash?: string | undefined;
368
368
  transaction_hash?: string | undefined;
369
369
  }, parameters: {
@@ -191,7 +191,7 @@ declare const upgradePreLaunchScript: {
191
191
  transaction_hash?: string | undefined;
192
192
  }, parameters: {
193
193
  schema: T;
194
- }): Promise<z.core.output<T>>;
194
+ }): Promise<z.infer<T>>;
195
195
  (client: import("../..").BaseClient<import("../..").ApiVersion>, params: {
196
196
  id?: string | undefined;
197
197
  uuid?: string | undefined;
@@ -244,7 +244,7 @@ declare const upgradePreLaunchScript: {
244
244
  transaction_hash?: string | undefined;
245
245
  }, parameters: {
246
246
  schema: T;
247
- }): Promise<import("../..").SafeResult<z.core.output<T>>>;
247
+ }): Promise<import("../..").SafeResult<z.infer<T>>>;
248
248
  (client: import("../..").BaseClient<import("../..").ApiVersion>, params: {
249
249
  id?: string | undefined;
250
250
  uuid?: string | undefined;
@@ -70,8 +70,8 @@ export declare class WatchAbortedError extends Error {
70
70
  export declare class MaxRetriesExceededError extends Error {
71
71
  readonly attempts: number;
72
72
  readonly lastServerError?: SSEErrorEvent["data"] | undefined;
73
- readonly lastAttemptError?: unknown | undefined;
74
- constructor(attempts: number, lastServerError?: SSEErrorEvent["data"] | undefined, lastAttemptError?: unknown | undefined);
73
+ readonly lastAttemptError?: unknown;
74
+ constructor(attempts: number, lastServerError?: SSEErrorEvent["data"] | undefined, lastAttemptError?: unknown);
75
75
  }
76
76
  /**
77
77
  * Watch CVM state changes using Server-Sent Events (SSE)
@@ -0,0 +1,139 @@
1
+ import { z } from "zod";
2
+ export declare const CreateAppDomainRequestSchema: z.ZodObject<{
3
+ appId: z.ZodString;
4
+ domain: z.ZodString;
5
+ port: z.ZodNumber;
6
+ turnstile_token: z.ZodOptional<z.ZodString>;
7
+ }, z.core.$strict>;
8
+ export type CreateAppDomainRequest = z.infer<typeof CreateAppDomainRequestSchema>;
9
+ export declare const CreateAppDomainResponseSchema: z.ZodObject<{
10
+ id: z.ZodString;
11
+ domain: z.ZodString;
12
+ port: z.ZodNumber;
13
+ dns_verified_at: z.ZodOptional<z.ZodNullable<z.ZodString>>;
14
+ dns_error: z.ZodOptional<z.ZodNullable<z.ZodString>>;
15
+ routing_status: z.ZodOptional<z.ZodNullable<z.ZodEnum<{
16
+ fail: "fail";
17
+ ok: "ok";
18
+ skipped: "skipped";
19
+ }>>>;
20
+ routing_checked_at: z.ZodOptional<z.ZodNullable<z.ZodString>>;
21
+ dns_zone: z.ZodOptional<z.ZodNullable<z.ZodString>>;
22
+ dns_provider: z.ZodOptional<z.ZodNullable<z.ZodString>>;
23
+ created_at: z.ZodString;
24
+ expected_records: z.ZodDefault<z.ZodArray<z.ZodObject<{
25
+ record_type: z.ZodString;
26
+ query_name: z.ZodString;
27
+ expected_value: z.ZodString;
28
+ }, z.core.$strip>>>;
29
+ sync: z.ZodObject<{
30
+ nodes: z.ZodDefault<z.ZodArray<z.ZodUnknown>>;
31
+ warnings: z.ZodDefault<z.ZodArray<z.ZodUnknown>>;
32
+ }, z.core.$strip>;
33
+ }, z.core.$strip>;
34
+ export type CreateAppDomainResponse = z.infer<typeof CreateAppDomainResponseSchema>;
35
+ /**
36
+ * Bind a custom domain to an app
37
+ *
38
+ * Fails with 409 when the domain is registered elsewhere and with 422 when the
39
+ * app cannot take a domain yet. Shares a per-user throttle with
40
+ * `preflightAppDomain` and `verifyAppDomain`.
41
+ *
42
+ * @example
43
+ * ```typescript
44
+ * const domain = await createAppDomain(client, { appId, domain: 'app.example.com', port: 443 })
45
+ * console.log(domain.expected_records)
46
+ * ```
47
+ *
48
+ * ## Safe Version
49
+ *
50
+ * Use `safeCreateAppDomain` to get a `SafeResult` instead of an exception.
51
+ */
52
+ declare const createAppDomain: {
53
+ (client: import("../..").BaseClient<import("../..").ApiVersion>, params: {
54
+ appId: string;
55
+ domain: string;
56
+ port: number;
57
+ turnstile_token?: string | undefined;
58
+ }): Promise<{
59
+ id: string;
60
+ domain: string;
61
+ port: number;
62
+ dns_verified_at?: string | null | undefined;
63
+ dns_error?: string | null | undefined;
64
+ routing_status?: "fail" | "ok" | "skipped" | null | undefined;
65
+ routing_checked_at?: string | null | undefined;
66
+ dns_zone?: string | null | undefined;
67
+ dns_provider?: string | null | undefined;
68
+ created_at: string;
69
+ expected_records: {
70
+ record_type: string;
71
+ query_name: string;
72
+ expected_value: string;
73
+ }[];
74
+ sync: {
75
+ nodes: unknown[];
76
+ warnings: unknown[];
77
+ };
78
+ }>;
79
+ <T extends z.ZodTypeAny>(client: import("../..").BaseClient<import("../..").ApiVersion>, params: {
80
+ appId: string;
81
+ domain: string;
82
+ port: number;
83
+ turnstile_token?: string | undefined;
84
+ }, parameters: {
85
+ schema: T;
86
+ }): Promise<z.infer<T>>;
87
+ (client: import("../..").BaseClient<import("../..").ApiVersion>, params: {
88
+ appId: string;
89
+ domain: string;
90
+ port: number;
91
+ turnstile_token?: string | undefined;
92
+ }, parameters: {
93
+ schema: false;
94
+ }): Promise<unknown>;
95
+ }, safeCreateAppDomain: {
96
+ (client: import("../..").BaseClient<import("../..").ApiVersion>, params: {
97
+ appId: string;
98
+ domain: string;
99
+ port: number;
100
+ turnstile_token?: string | undefined;
101
+ }): Promise<import("../..").SafeResult<{
102
+ id: string;
103
+ domain: string;
104
+ port: number;
105
+ dns_verified_at?: string | null | undefined;
106
+ dns_error?: string | null | undefined;
107
+ routing_status?: "fail" | "ok" | "skipped" | null | undefined;
108
+ routing_checked_at?: string | null | undefined;
109
+ dns_zone?: string | null | undefined;
110
+ dns_provider?: string | null | undefined;
111
+ created_at: string;
112
+ expected_records: {
113
+ record_type: string;
114
+ query_name: string;
115
+ expected_value: string;
116
+ }[];
117
+ sync: {
118
+ nodes: unknown[];
119
+ warnings: unknown[];
120
+ };
121
+ }>>;
122
+ <T extends z.ZodTypeAny>(client: import("../..").BaseClient<import("../..").ApiVersion>, params: {
123
+ appId: string;
124
+ domain: string;
125
+ port: number;
126
+ turnstile_token?: string | undefined;
127
+ }, parameters: {
128
+ schema: T;
129
+ }): Promise<import("../..").SafeResult<z.infer<T>>>;
130
+ (client: import("../..").BaseClient<import("../..").ApiVersion>, params: {
131
+ appId: string;
132
+ domain: string;
133
+ port: number;
134
+ turnstile_token?: string | undefined;
135
+ }, parameters: {
136
+ schema: false;
137
+ }): Promise<import("../..").SafeResult<unknown>>;
138
+ };
139
+ export { createAppDomain, safeCreateAppDomain };