@boatdev/sdk 1.9.9 → 1.10.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 (72) hide show
  1. package/.openapi-generator/FILES +8 -0
  2. package/dist/apis/BoatApi.d.ts +52 -6
  3. package/dist/apis/BoatApi.js +109 -7
  4. package/dist/esm/apis/BoatApi.d.ts +52 -6
  5. package/dist/esm/apis/BoatApi.js +108 -6
  6. package/dist/esm/models/CreateSandboxRequest.d.ts +7 -1
  7. package/dist/esm/models/CreateSandboxRequest.js +2 -0
  8. package/dist/esm/models/CreateSandboxResponse.d.ts +6 -0
  9. package/dist/esm/models/CreateSandboxResponse.js +2 -0
  10. package/dist/esm/models/CreateScopedApiKeyRequest.d.ts +1 -1
  11. package/dist/esm/models/LimitsFields.d.ts +1 -1
  12. package/dist/esm/models/LimitsResponse.d.ts +1 -1
  13. package/dist/esm/models/MeResponseAllOfUser.d.ts +1 -0
  14. package/dist/esm/models/MeResponseAllOfUser.js +1 -0
  15. package/dist/esm/models/ResumeRequest.d.ts +1 -1
  16. package/dist/esm/models/Sandbox.d.ts +28 -1
  17. package/dist/esm/models/Sandbox.js +14 -0
  18. package/dist/esm/models/SandboxCost.d.ts +44 -0
  19. package/dist/esm/models/SandboxCost.js +51 -0
  20. package/dist/esm/models/Unshare200Response.d.ts +39 -0
  21. package/dist/esm/models/Unshare200Response.js +44 -0
  22. package/dist/esm/models/UpdateOrganization200Response.d.ts +50 -0
  23. package/dist/esm/models/UpdateOrganization200Response.js +47 -0
  24. package/dist/esm/models/UpdateOrganizationRequest.d.ts +32 -0
  25. package/dist/esm/models/UpdateOrganizationRequest.js +43 -0
  26. package/dist/esm/models/index.d.ts +4 -0
  27. package/dist/esm/models/index.js +4 -0
  28. package/dist/models/CreateSandboxRequest.d.ts +7 -1
  29. package/dist/models/CreateSandboxRequest.js +2 -0
  30. package/dist/models/CreateSandboxResponse.d.ts +6 -0
  31. package/dist/models/CreateSandboxResponse.js +2 -0
  32. package/dist/models/CreateScopedApiKeyRequest.d.ts +1 -1
  33. package/dist/models/LimitsFields.d.ts +1 -1
  34. package/dist/models/LimitsResponse.d.ts +1 -1
  35. package/dist/models/MeResponseAllOfUser.d.ts +1 -0
  36. package/dist/models/MeResponseAllOfUser.js +1 -0
  37. package/dist/models/ResumeRequest.d.ts +1 -1
  38. package/dist/models/Sandbox.d.ts +28 -1
  39. package/dist/models/Sandbox.js +15 -1
  40. package/dist/models/SandboxCost.d.ts +44 -0
  41. package/dist/models/SandboxCost.js +58 -0
  42. package/dist/models/Unshare200Response.d.ts +39 -0
  43. package/dist/models/Unshare200Response.js +51 -0
  44. package/dist/models/UpdateOrganization200Response.d.ts +50 -0
  45. package/dist/models/UpdateOrganization200Response.js +54 -0
  46. package/dist/models/UpdateOrganizationRequest.d.ts +32 -0
  47. package/dist/models/UpdateOrganizationRequest.js +50 -0
  48. package/dist/models/index.d.ts +4 -0
  49. package/dist/models/index.js +4 -0
  50. package/docs/BoatApi.md +161 -4
  51. package/docs/CreateSandboxRequest.md +2 -0
  52. package/docs/CreateSandboxResponse.md +2 -0
  53. package/docs/Sandbox.md +6 -0
  54. package/docs/SandboxCost.md +37 -0
  55. package/docs/Unshare200Response.md +34 -0
  56. package/docs/UpdateOrganization200Response.md +38 -0
  57. package/docs/UpdateOrganizationRequest.md +32 -0
  58. package/package.json +1 -1
  59. package/src/apis/BoatApi.ts +163 -6
  60. package/src/models/CreateSandboxRequest.ts +9 -1
  61. package/src/models/CreateSandboxResponse.ts +8 -0
  62. package/src/models/CreateScopedApiKeyRequest.ts +1 -1
  63. package/src/models/LimitsFields.ts +1 -1
  64. package/src/models/LimitsResponse.ts +1 -1
  65. package/src/models/MeResponseAllOfUser.ts +1 -0
  66. package/src/models/ResumeRequest.ts +1 -1
  67. package/src/models/Sandbox.ts +41 -1
  68. package/src/models/SandboxCost.ts +84 -0
  69. package/src/models/Unshare200Response.ts +81 -0
  70. package/src/models/UpdateOrganization200Response.ts +89 -0
  71. package/src/models/UpdateOrganizationRequest.ts +66 -0
  72. package/src/models/index.ts +4 -0
@@ -104,8 +104,11 @@ import { StopRequestToJSON, } from '../models/StopRequest';
104
104
  import { TelemetryResponseFromJSON, } from '../models/TelemetryResponse';
105
105
  import { TelemetrySetRequestToJSON, } from '../models/TelemetrySetRequest';
106
106
  import { TelemetrySetResponseFromJSON, } from '../models/TelemetrySetResponse';
107
+ import { Unshare200ResponseFromJSON, } from '../models/Unshare200Response';
107
108
  import { UpdateAiProxyRequestToJSON, } from '../models/UpdateAiProxyRequest';
108
109
  import { UpdateCredentialProfileRequestToJSON, } from '../models/UpdateCredentialProfileRequest';
110
+ import { UpdateOrganization200ResponseFromJSON, } from '../models/UpdateOrganization200Response';
111
+ import { UpdateOrganizationRequestToJSON, } from '../models/UpdateOrganizationRequest';
109
112
  import { UpdateSandboxEnvironmentRequestToJSON, } from '../models/UpdateSandboxEnvironmentRequest';
110
113
  import { UpdateSandboxRequestToJSON, } from '../models/UpdateSandboxRequest';
111
114
  import { UpgradeSandboxEnvironmentRequestToJSON, } from '../models/UpgradeSandboxEnvironmentRequest';
@@ -2239,7 +2242,7 @@ export class BoatApi extends runtime.BaseAPI {
2239
2242
  };
2240
2243
  }
2241
2244
  /**
2242
- * One sandbox\'s proxied AI usage per UTC day, credential and model, and whether it is blocked. Needs an API key with `box.read` on the sandbox.
2245
+ * One sandbox\'s proxied AI usage per UTC day, credential and model, and whether it is blocked. Needs an API key with `sandbox.read` on the sandbox.
2243
2246
  * Get sandbox AI usage
2244
2247
  */
2245
2248
  async getSandboxAiUsageRaw(requestParameters, initOverrides) {
@@ -2248,7 +2251,7 @@ export class BoatApi extends runtime.BaseAPI {
2248
2251
  return new runtime.JSONApiResponse(response, (jsonValue) => SandboxAiUsageResponseFromJSON(jsonValue));
2249
2252
  }
2250
2253
  /**
2251
- * One sandbox\'s proxied AI usage per UTC day, credential and model, and whether it is blocked. Needs an API key with `box.read` on the sandbox.
2254
+ * One sandbox\'s proxied AI usage per UTC day, credential and model, and whether it is blocked. Needs an API key with `sandbox.read` on the sandbox.
2252
2255
  * Get sandbox AI usage
2253
2256
  */
2254
2257
  async getSandboxAiUsage(requestParameters, initOverrides) {
@@ -3239,7 +3242,7 @@ export class BoatApi extends runtime.BaseAPI {
3239
3242
  };
3240
3243
  }
3241
3244
  /**
3242
- * Power-cycle the machine of a sandbox that stopped answering. The disk is not touched. The sandbox usually answers again within 1-2 minutes and then saves your work by itself; `sandbox.recovered` fires when it does. Refused with `409`: - `sandbox_is_reachable`: the sandbox answers normally. - `too_soon`: a recover started less than 10 minutes ago. - `no_machine`: the sandbox has no machine. Resume it instead. - `recover_unsupported`: its machine cannot be power-cycled. Wait for it to answer, or resume it from its last snapshot. - `reset_failed`: the power-cycle failed. Reply to the incident email.
3245
+ * Power-cycle the machine of a sandbox that stopped answering. The disk is not touched. The sandbox usually answers again within 1-2 minutes and then saves your work by itself; `sandbox.recovered` fires when it does. Refused with `409`: - `sandbox_is_reachable`: the sandbox answers normally. - `too_soon`: a recover started less than 10 minutes ago. - `no_machine`: the sandbox has no machine. Resume it instead. - `recover_unsupported`: its machine cannot be power-cycled. Wait for it to answer, or stop it with `{\"force\": true}` and resume it from its last good snapshot. With no snapshot, a forced stop loses everything. - `reset_failed`: the power-cycle failed. Reply to the incident email.
3243
3246
  * Recover a sandbox that stopped responding
3244
3247
  */
3245
3248
  async recoverRaw(requestParameters, initOverrides) {
@@ -3248,7 +3251,7 @@ export class BoatApi extends runtime.BaseAPI {
3248
3251
  return new runtime.JSONApiResponse(response, (jsonValue) => Recover200ResponseFromJSON(jsonValue));
3249
3252
  }
3250
3253
  /**
3251
- * Power-cycle the machine of a sandbox that stopped answering. The disk is not touched. The sandbox usually answers again within 1-2 minutes and then saves your work by itself; `sandbox.recovered` fires when it does. Refused with `409`: - `sandbox_is_reachable`: the sandbox answers normally. - `too_soon`: a recover started less than 10 minutes ago. - `no_machine`: the sandbox has no machine. Resume it instead. - `recover_unsupported`: its machine cannot be power-cycled. Wait for it to answer, or resume it from its last snapshot. - `reset_failed`: the power-cycle failed. Reply to the incident email.
3254
+ * Power-cycle the machine of a sandbox that stopped answering. The disk is not touched. The sandbox usually answers again within 1-2 minutes and then saves your work by itself; `sandbox.recovered` fires when it does. Refused with `409`: - `sandbox_is_reachable`: the sandbox answers normally. - `too_soon`: a recover started less than 10 minutes ago. - `no_machine`: the sandbox has no machine. Resume it instead. - `recover_unsupported`: its machine cannot be power-cycled. Wait for it to answer, or stop it with `{\"force\": true}` and resume it from its last good snapshot. With no snapshot, a forced stop loses everything. - `reset_failed`: the power-cycle failed. Reply to the incident email.
3252
3255
  * Recover a sandbox that stopped responding
3253
3256
  */
3254
3257
  async recover(requestParameters, initOverrides) {
@@ -3546,6 +3549,9 @@ export class BoatApi extends runtime.BaseAPI {
3546
3549
  if (requestParameters['state'] != null) {
3547
3550
  queryParameters['state'] = requestParameters['state'];
3548
3551
  }
3552
+ if (requestParameters['include'] != null) {
3553
+ queryParameters['include'] = requestParameters['include'];
3554
+ }
3549
3555
  const headerParameters = {};
3550
3556
  if (requestParameters['xBoatOrg'] != null) {
3551
3557
  headerParameters['X-Boat-Org'] = String(requestParameters['xBoatOrg']);
@@ -4080,7 +4086,7 @@ export class BoatApi extends runtime.BaseAPI {
4080
4086
  };
4081
4087
  }
4082
4088
  /**
4083
- * Let every member of the organization that pays for this sandbox use it. Your personal logins (GitHub token, Claude and Codex logins, environment secrets, the sandbox\'s own CLI key) are never pushed to it again and are wiped off its disk at its next start, so a teammate never acts as you. Files you wrote stay. One-way: the sandbox stays like a `noEnv` sandbox from then on. A running sandbox stays `view` for the organization until you stop and resume it (`restartRequired`). Only the person who created the sandbox can share it, and only a sandbox billed to an organization. Sharing an already shared sandbox is a no-op.
4089
+ * Let every member of the organization that pays for this sandbox use it. A sandbox that holds none of your personal logins is shared at once. A sandbox that holds them: your personal logins (GitHub token, Claude and Codex logins, environment secrets, the sandbox\'s own CLI key) are never pushed to it again and are wiped off its disk at its next start, so a teammate never acts as you. Files you wrote stay. The wipe is one-way: the sandbox stays like a `noEnv` sandbox from then on. A running sandbox stays `view` for the organization until you stop and resume it (`restartRequired`): its running programs hold your logins in memory. Teammates never read history recorded before the share. Only the person who created the sandbox can share it, and only a sandbox billed to an organization. Sharing an already shared sandbox is a no-op. Undo with `POST /sandboxes/{sandboxId}/unshare`.
4084
4090
  * Share sandbox with the organization
4085
4091
  */
4086
4092
  async shareRaw(requestParameters, initOverrides) {
@@ -4089,7 +4095,7 @@ export class BoatApi extends runtime.BaseAPI {
4089
4095
  return new runtime.JSONApiResponse(response, (jsonValue) => Share200ResponseFromJSON(jsonValue));
4090
4096
  }
4091
4097
  /**
4092
- * Let every member of the organization that pays for this sandbox use it. Your personal logins (GitHub token, Claude and Codex logins, environment secrets, the sandbox\'s own CLI key) are never pushed to it again and are wiped off its disk at its next start, so a teammate never acts as you. Files you wrote stay. One-way: the sandbox stays like a `noEnv` sandbox from then on. A running sandbox stays `view` for the organization until you stop and resume it (`restartRequired`). Only the person who created the sandbox can share it, and only a sandbox billed to an organization. Sharing an already shared sandbox is a no-op.
4098
+ * Let every member of the organization that pays for this sandbox use it. A sandbox that holds none of your personal logins is shared at once. A sandbox that holds them: your personal logins (GitHub token, Claude and Codex logins, environment secrets, the sandbox\'s own CLI key) are never pushed to it again and are wiped off its disk at its next start, so a teammate never acts as you. Files you wrote stay. The wipe is one-way: the sandbox stays like a `noEnv` sandbox from then on. A running sandbox stays `view` for the organization until you stop and resume it (`restartRequired`): its running programs hold your logins in memory. Teammates never read history recorded before the share. Only the person who created the sandbox can share it, and only a sandbox billed to an organization. Sharing an already shared sandbox is a no-op. Undo with `POST /sandboxes/{sandboxId}/unshare`.
4093
4099
  * Share sandbox with the organization
4094
4100
  */
4095
4101
  async share(requestParameters, initOverrides) {
@@ -4336,6 +4342,48 @@ export class BoatApi extends runtime.BaseAPI {
4336
4342
  const response = await this.switchCredentialAccountRaw(requestParameters, initOverrides);
4337
4343
  return await response.value();
4338
4344
  }
4345
+ /**
4346
+ * Creates request options for unshare without sending the request
4347
+ */
4348
+ async unshareRequestOpts(requestParameters) {
4349
+ if (requestParameters['sandboxId'] == null) {
4350
+ throw new runtime.RequiredError('sandboxId', 'Required parameter "sandboxId" was null or undefined when calling unshare().');
4351
+ }
4352
+ const queryParameters = {};
4353
+ const headerParameters = {};
4354
+ if (this.configuration && this.configuration.accessToken) {
4355
+ const token = this.configuration.accessToken;
4356
+ const tokenString = await token("BoatBearerAuth", []);
4357
+ if (tokenString) {
4358
+ headerParameters["Authorization"] = `Bearer ${tokenString}`;
4359
+ }
4360
+ }
4361
+ let urlPath = `/sandboxes/{sandboxId}/unshare`;
4362
+ urlPath = urlPath.replace('{sandboxId}', encodeURIComponent(String(requestParameters['sandboxId'])));
4363
+ return {
4364
+ path: urlPath,
4365
+ method: 'POST',
4366
+ headers: headerParameters,
4367
+ query: queryParameters,
4368
+ };
4369
+ }
4370
+ /**
4371
+ * Make a shared organization sandbox private again, at once. Only you can then use it. Teammates still see it in their list and can stop it. Their SSH keys are removed from the running machine. Nothing on the sandbox changes: files, installs and its environment stay. Undo with `POST /sandboxes/{sandboxId}/share`. Only the person who created the sandbox can make it private, and only a sandbox billed to an organization. Making a private sandbox private is a no-op.
4372
+ * Make an organization sandbox private
4373
+ */
4374
+ async unshareRaw(requestParameters, initOverrides) {
4375
+ const requestOptions = await this.unshareRequestOpts(requestParameters);
4376
+ const response = await this.request(requestOptions, initOverrides);
4377
+ return new runtime.JSONApiResponse(response, (jsonValue) => Unshare200ResponseFromJSON(jsonValue));
4378
+ }
4379
+ /**
4380
+ * Make a shared organization sandbox private again, at once. Only you can then use it. Teammates still see it in their list and can stop it. Their SSH keys are removed from the running machine. Nothing on the sandbox changes: files, installs and its environment stay. Undo with `POST /sandboxes/{sandboxId}/share`. Only the person who created the sandbox can make it private, and only a sandbox billed to an organization. Making a private sandbox private is a no-op.
4381
+ * Make an organization sandbox private
4382
+ */
4383
+ async unshare(requestParameters, initOverrides) {
4384
+ const response = await this.unshareRaw(requestParameters, initOverrides);
4385
+ return await response.value();
4386
+ }
4339
4387
  /**
4340
4388
  * Creates request options for update without sending the request
4341
4389
  */
@@ -4575,6 +4623,54 @@ export class BoatApi extends runtime.BaseAPI {
4575
4623
  const response = await this.updateEnvironmentRaw(requestParameters, initOverrides);
4576
4624
  return await response.value();
4577
4625
  }
4626
+ /**
4627
+ * Creates request options for updateOrganization without sending the request
4628
+ */
4629
+ async updateOrganizationRequestOpts(input) {
4630
+ const requestParameters = runtime.unflattenBody(input, 'updateOrganizationRequest', ['org'], []);
4631
+ if (requestParameters['org'] == null) {
4632
+ throw new runtime.RequiredError('org', 'Required parameter "org" was null or undefined when calling updateOrganization().');
4633
+ }
4634
+ if (requestParameters['updateOrganizationRequest'] == null) {
4635
+ throw new runtime.RequiredError('updateOrganizationRequest', 'Required parameter "updateOrganizationRequest" was null or undefined when calling updateOrganization().');
4636
+ }
4637
+ const queryParameters = {};
4638
+ const headerParameters = {};
4639
+ headerParameters['Content-Type'] = 'application/json';
4640
+ if (this.configuration && this.configuration.accessToken) {
4641
+ const token = this.configuration.accessToken;
4642
+ const tokenString = await token("BoatBearerAuth", []);
4643
+ if (tokenString) {
4644
+ headerParameters["Authorization"] = `Bearer ${tokenString}`;
4645
+ }
4646
+ }
4647
+ let urlPath = `/orgs/{org}`;
4648
+ urlPath = urlPath.replace('{org}', encodeURIComponent(String(requestParameters['org'])));
4649
+ return {
4650
+ path: urlPath,
4651
+ method: 'PATCH',
4652
+ headers: headerParameters,
4653
+ query: queryParameters,
4654
+ body: UpdateOrganizationRequestToJSON(requestParameters['updateOrganizationRequest']),
4655
+ };
4656
+ }
4657
+ /**
4658
+ * Owners and admins set whether new sandboxes of the organization start private (only their creator can use them) or shared (every member can use those that hold none of their creator\'s logins). The default is shared. Existing sandboxes keep their setting; their creators change it with `POST /sandboxes/{sandboxId}/share` and `POST /sandboxes/{sandboxId}/unshare`. A fork of a private sandbox is private.
4659
+ * Update organization settings
4660
+ */
4661
+ async updateOrganizationRaw(requestParameters, initOverrides) {
4662
+ const requestOptions = await this.updateOrganizationRequestOpts(requestParameters);
4663
+ const response = await this.request(requestOptions, initOverrides);
4664
+ return new runtime.JSONApiResponse(response, (jsonValue) => UpdateOrganization200ResponseFromJSON(jsonValue));
4665
+ }
4666
+ /**
4667
+ * Owners and admins set whether new sandboxes of the organization start private (only their creator can use them) or shared (every member can use those that hold none of their creator\'s logins). The default is shared. Existing sandboxes keep their setting; their creators change it with `POST /sandboxes/{sandboxId}/share` and `POST /sandboxes/{sandboxId}/unshare`. A fork of a private sandbox is private.
4668
+ * Update organization settings
4669
+ */
4670
+ async updateOrganization(requestParameters, initOverrides) {
4671
+ const response = await this.updateOrganizationRaw(requestParameters, initOverrides);
4672
+ return await response.value();
4673
+ }
4578
4674
  /**
4579
4675
  * Creates request options for updateSecrets without sending the request
4580
4676
  */
@@ -4879,3 +4975,9 @@ export const SandboxesSortEnum = {
4879
4975
  Asc: 'asc',
4880
4976
  Desc: 'desc'
4881
4977
  };
4978
+ /**
4979
+ * @export
4980
+ */
4981
+ export const SandboxesIncludeEnum = {
4982
+ Cost: 'cost'
4983
+ };
@@ -16,7 +16,7 @@
16
16
  */
17
17
  export interface CreateSandboxRequest {
18
18
  /**
19
- * Machine size. `small` consumes machine time at half rate and `large` at twice the default rate (see the Billing guide). `xlarge` needs the $100/month plan or higher; lower plans get a 403 `machine_class_plan_required` on create, resume and fork. A fork inherits the source sandbox's type unless the fork request passes its own, and resume and fork can move a sandbox between sizes.
19
+ * Machine size. `small` consumes machine time at half rate and `large` at twice the default rate (see the Billing guide). `xlarge` needs the $100/month plan or higher, or an account access grant from an administrator. Otherwise, create, resume and fork return 403 `machine_class_plan_required`. A fork inherits the source sandbox's type unless the fork request passes its own, and resume and fork can move a sandbox between sizes.
20
20
  * @type {CreateSandboxRequestTypeEnum}
21
21
  * @memberof CreateSandboxRequest
22
22
  */
@@ -65,6 +65,12 @@ export interface CreateSandboxRequest {
65
65
  * @memberof CreateSandboxRequest
66
66
  */
67
67
  failFast?: boolean;
68
+ /**
69
+ * With `from`: create this many sandboxes from the named snapshot in one request. Boat creates them together, which is faster than separate creates when you need many sandboxes at once. Start limits and the active-sandbox limit count every sandbox of the batch; if the batch does not fit, nothing is created. The answer lists all of them in `sandboxes` (and the first one in `sandbox`). Refused with 400 `count_requires_from` without `from`, and with 400 `count_with_fail_fast` together with `failFast`.
70
+ * @type {number}
71
+ * @memberof CreateSandboxRequest
72
+ */
73
+ count?: number;
68
74
  /**
69
75
  * Shell script that runs on the sandbox after it is ready. Ready means "ready to accept the user", not "setup done": the script starts in the background once provisioning completes and never blocks the sandbox becoming usable. It runs as the sandbox user (`user`, not root; `sudo` needs no password) via `bash`, with the sandbox's environment applied, and its output goes to a log file on the sandbox. Observe the outcome as `setupStatus` (pending/running/done/failed) and `setupError` on the sandbox. Rejected with a 400 `invalid_setup_script` error when it is not a string or exceeds 64KB.
70
76
  * @type {string}
@@ -42,6 +42,7 @@ export function CreateSandboxRequestFromJSONTyped(json, ignoreDiscriminator) {
42
42
  'snapshots': json['snapshots'] == null ? undefined : json['snapshots'],
43
43
  'monitoring': json['monitoring'] == null ? undefined : json['monitoring'],
44
44
  'failFast': json['failFast'] == null ? undefined : json['failFast'],
45
+ 'count': json['count'] == null ? undefined : json['count'],
45
46
  'setupScript': json['setupScript'] == null ? undefined : json['setupScript'],
46
47
  'org': json['org'] == null ? undefined : json['org'],
47
48
  'teamId': json['teamId'] == null ? undefined : json['teamId'],
@@ -64,6 +65,7 @@ export function CreateSandboxRequestToJSONTyped(value, ignoreDiscriminator = fal
64
65
  'snapshots': value['snapshots'],
65
66
  'monitoring': value['monitoring'],
66
67
  'failFast': value['failFast'],
68
+ 'count': value['count'],
67
69
  'setupScript': value['setupScript'],
68
70
  'org': value['org'],
69
71
  'teamId': value['teamId'],
@@ -46,6 +46,12 @@ export interface CreateSandboxResponse {
46
46
  * @memberof CreateSandboxResponse
47
47
  */
48
48
  sandbox: Sandbox;
49
+ /**
50
+ * Present when the request set `count` above 1. Every sandbox of the batch, in creation order.
51
+ * @type {Array<Sandbox>}
52
+ * @memberof CreateSandboxResponse
53
+ */
54
+ sandboxes?: Array<Sandbox>;
49
55
  /**
50
56
  * Present when a fair-use cap on a gifted account shortened the requested auto-stop time.
51
57
  * @type {string}
@@ -54,6 +54,7 @@ export function CreateSandboxResponseFromJSONTyped(json, ignoreDiscriminator) {
54
54
  'status': json['status'],
55
55
  'ttlSeconds': json['ttlSeconds'],
56
56
  'sandbox': SandboxFromJSON(json['sandbox']),
57
+ 'sandboxes': json['sandboxes'] == null ? undefined : (json['sandboxes'].map(SandboxFromJSON)),
57
58
  'giftLimitNotice': json['giftLimitNotice'] == null ? undefined : json['giftLimitNotice'],
58
59
  };
59
60
  }
@@ -70,6 +71,7 @@ export function CreateSandboxResponseToJSONTyped(value, ignoreDiscriminator = fa
70
71
  'status': value['status'],
71
72
  'ttlSeconds': value['ttlSeconds'],
72
73
  'sandbox': SandboxToJSON(value['sandbox']),
74
+ 'sandboxes': value['sandboxes'] == null ? undefined : (value['sandboxes'].map(SandboxToJSON)),
73
75
  'giftLimitNotice': value['giftLimitNotice'],
74
76
  };
75
77
  }
@@ -22,7 +22,7 @@ export interface CreateScopedApiKeyRequest {
22
22
  */
23
23
  name?: string;
24
24
  /**
25
- * Duration such as 90d, 24h, or seconds. Max 365d.
25
+ * Duration such as 90d, 24h, or seconds, up to 365d; or `never` for a key that works until revoked. Default 90d.
26
26
  * @type {string}
27
27
  * @memberof CreateScopedApiKeyRequest
28
28
  */
@@ -261,7 +261,7 @@ export interface LimitsFields {
261
261
  */
262
262
  last24hUsageSeconds?: number;
263
263
  /**
264
- * Lifetime machine-time allowance for a trial that never paid. Null once the account has paid or has a plan.
264
+ * Lifetime Boat-time allowance for new sandboxes while the account has not paid, a plan trial included. Every charge on the wallet counts. Null once the account has paid.
265
265
  * @type {number}
266
266
  * @memberof LimitsFields
267
267
  */
@@ -272,7 +272,7 @@ export interface LimitsResponse {
272
272
  */
273
273
  last24hUsageSeconds?: number;
274
274
  /**
275
- * Lifetime machine-time allowance for a trial that never paid. Null once the account has paid or has a plan.
275
+ * Lifetime Boat-time allowance for new sandboxes while the account has not paid, a plan trial included. Every charge on the wallet counts. Null once the account has paid.
276
276
  * @type {number}
277
277
  * @memberof LimitsResponse
278
278
  */
@@ -137,6 +137,7 @@ export declare const MeResponseAllOfUserConnectionMethodEnum: {
137
137
  readonly Github: 'github';
138
138
  readonly Google: 'google';
139
139
  readonly Email: 'email';
140
+ readonly Agentid: 'agentid';
140
141
  readonly Service: 'service';
141
142
  };
142
143
  export type MeResponseAllOfUserConnectionMethodEnum = typeof MeResponseAllOfUserConnectionMethodEnum[keyof typeof MeResponseAllOfUserConnectionMethodEnum];
@@ -18,6 +18,7 @@ export const MeResponseAllOfUserConnectionMethodEnum = {
18
18
  Github: 'github',
19
19
  Google: 'google',
20
20
  Email: 'email',
21
+ Agentid: 'agentid',
21
22
  Service: 'service'
22
23
  };
23
24
  /**
@@ -22,7 +22,7 @@ export interface ResumeRequest {
22
22
  */
23
23
  failFast?: boolean;
24
24
  /**
25
- * Resume onto a different machine size. Omit to keep the sandbox's current type. `xlarge` needs the $100/month plan or higher (403 `machine_class_plan_required`). A resume already restores onto a fresh machine, so changing size costs nothing extra. Shrinking is rejected with `type_too_small` when the sandbox's data would not fit the smaller disk.
25
+ * Resume onto a different machine size. Omit to keep the sandbox's current type. `xlarge` needs the $100/month plan or higher, or an account access grant from an administrator (403 `machine_class_plan_required` otherwise). A resume already restores onto a fresh machine, so changing size costs nothing extra. Shrinking is rejected with `type_too_small` when the sandbox's data would not fit the smaller disk.
26
26
  * @type {ResumeRequestTypeEnum}
27
27
  * @memberof ResumeRequest
28
28
  */
@@ -11,6 +11,7 @@
11
11
  */
12
12
  import type { SandboxTeam } from './SandboxTeam';
13
13
  import type { StopOperation } from './StopOperation';
14
+ import type { SandboxCost } from './SandboxCost';
14
15
  import type { SandboxHydration } from './SandboxHydration';
15
16
  /**
16
17
  *
@@ -42,6 +43,12 @@ export interface Sandbox {
42
43
  * @memberof Sandbox
43
44
  */
44
45
  error?: string | null;
46
+ /**
47
+ * When Boat deleted the snapshot data of this stopped sandbox, 14 days after it stopped. Resume and fork then fail with `409 snapshot_data_expired`. Null while the data is kept.
48
+ * @type {Date}
49
+ * @memberof Sandbox
50
+ */
51
+ dataExpiredAt?: Date | null;
45
52
  /**
46
53
  * `degraded` when the machine is alive but Boat cannot fully reach it (for example a firewall rule inside the sandbox blocks the tunnel). The sandbox keeps running.
47
54
  * @type {SandboxHealthEnum}
@@ -211,7 +218,7 @@ export interface Sandbox {
211
218
  */
212
219
  createdById?: string | null;
213
220
  /**
214
- * What you may do with this sandbox. `owner`: you created it. `use`: a teammate's organization sandbox that never received their personal logins (`noEnv`, shared and restarted, or created on an environment that passes nothing), so you can open, run commands in, prompt, resume and stop it. `view`: a teammate's organization sandbox that still holds their personal logins, so you can see it and stop it until they share it (`POST /sandboxes/{sandboxId}/share`).
221
+ * What you may do with this sandbox. `owner`: you created it. `use`: a teammate's organization sandbox that is `shared` (see `visibility`), so you can open, run commands in, prompt, resume and stop it. `view`: a teammate's organization sandbox that is `private`, so you can see it and stop it until they share it (`POST /sandboxes/{sandboxId}/share`).
215
222
  * @type {SandboxAccessEnum}
216
223
  * @memberof Sandbox
217
224
  */
@@ -222,6 +229,18 @@ export interface Sandbox {
222
229
  * @memberof Sandbox
223
230
  */
224
231
  holdsCreatorLogins?: boolean;
232
+ /**
233
+ * Organization sandboxes only; null for a personal sandbox. `shared`: every member can use it. It holds none of its creator's personal logins (`noEnv`, shared and restarted, or created on an environment that passes nothing) and its creator did not make it private. `private`: only its creator can use it. It holds their logins, or its creator made it private (`POST /sandboxes/{sandboxId}/unshare`, or the organization's `newSandboxesPrivate` default).
234
+ * @type {SandboxVisibilityEnum}
235
+ * @memberof Sandbox
236
+ */
237
+ visibility?: SandboxVisibilityEnum | null;
238
+ /**
239
+ *
240
+ * @type {SandboxCost}
241
+ * @memberof Sandbox
242
+ */
243
+ cost?: SandboxCost;
225
244
  /**
226
245
  * True once the sandbox is shared but not restarted yet. Its creator's logins are wiped at its next start, and the organization can use it from then on.
227
246
  * @type {boolean}
@@ -329,6 +348,14 @@ export declare const SandboxAccessEnum: {
329
348
  readonly View: 'view';
330
349
  };
331
350
  export type SandboxAccessEnum = typeof SandboxAccessEnum[keyof typeof SandboxAccessEnum];
351
+ /**
352
+ * @export
353
+ */
354
+ export declare const SandboxVisibilityEnum: {
355
+ readonly Shared: 'shared';
356
+ readonly Private: 'private';
357
+ };
358
+ export type SandboxVisibilityEnum = typeof SandboxVisibilityEnum[keyof typeof SandboxVisibilityEnum];
332
359
  /**
333
360
  * @export
334
361
  */
@@ -13,6 +13,7 @@
13
13
  */
14
14
  import { SandboxTeamFromJSON, SandboxTeamToJSON, } from './SandboxTeam';
15
15
  import { StopOperationFromJSON, StopOperationToJSON, } from './StopOperation';
16
+ import { SandboxCostFromJSON, SandboxCostToJSON, } from './SandboxCost';
16
17
  import { SandboxHydrationFromJSON, SandboxHydrationToJSON, } from './SandboxHydration';
17
18
  /**
18
19
  * @export
@@ -61,6 +62,13 @@ export const SandboxAccessEnum = {
61
62
  Use: 'use',
62
63
  View: 'view'
63
64
  };
65
+ /**
66
+ * @export
67
+ */
68
+ export const SandboxVisibilityEnum = {
69
+ Shared: 'shared',
70
+ Private: 'private'
71
+ };
64
72
  /**
65
73
  * @export
66
74
  */
@@ -108,6 +116,7 @@ export function SandboxFromJSONTyped(json, ignoreDiscriminator) {
108
116
  'name': json['name'],
109
117
  'state': json['state'],
110
118
  'error': json['error'] == null ? undefined : json['error'],
119
+ 'dataExpiredAt': json['dataExpiredAt'] == null ? undefined : (new Date(json['dataExpiredAt'])),
111
120
  'health': json['health'] == null ? undefined : json['health'],
112
121
  'healthReason': json['healthReason'] == null ? undefined : json['healthReason'],
113
122
  'degradedSince': json['degradedSince'] == null ? undefined : (new Date(json['degradedSince'])),
@@ -138,6 +147,8 @@ export function SandboxFromJSONTyped(json, ignoreDiscriminator) {
138
147
  'createdById': json['createdById'] == null ? undefined : json['createdById'],
139
148
  'access': json['access'] == null ? undefined : json['access'],
140
149
  'holdsCreatorLogins': json['holdsCreatorLogins'] == null ? undefined : json['holdsCreatorLogins'],
150
+ 'visibility': json['visibility'] == null ? undefined : json['visibility'],
151
+ 'cost': json['cost'] == null ? undefined : SandboxCostFromJSON(json['cost']),
141
152
  'wipePendingUntilRestart': json['wipePendingUntilRestart'] == null ? undefined : json['wipePendingUntilRestart'],
142
153
  'subdomain': json['subdomain'] == null ? undefined : json['subdomain'],
143
154
  'lastSnapshotAttemptAt': json['lastSnapshotAttemptAt'] == null ? undefined : (new Date(json['lastSnapshotAttemptAt'])),
@@ -161,6 +172,7 @@ export function SandboxToJSONTyped(value, ignoreDiscriminator = false) {
161
172
  'name': value['name'],
162
173
  'state': value['state'],
163
174
  'error': value['error'],
175
+ 'dataExpiredAt': value['dataExpiredAt'] == null ? value['dataExpiredAt'] : value['dataExpiredAt'].toISOString(),
164
176
  'health': value['health'],
165
177
  'healthReason': value['healthReason'],
166
178
  'degradedSince': value['degradedSince'] == null ? value['degradedSince'] : value['degradedSince'].toISOString(),
@@ -191,6 +203,8 @@ export function SandboxToJSONTyped(value, ignoreDiscriminator = false) {
191
203
  'createdById': value['createdById'],
192
204
  'access': value['access'],
193
205
  'holdsCreatorLogins': value['holdsCreatorLogins'],
206
+ 'visibility': value['visibility'],
207
+ 'cost': SandboxCostToJSON(value['cost']),
194
208
  'wipePendingUntilRestart': value['wipePendingUntilRestart'],
195
209
  'subdomain': value['subdomain'],
196
210
  'lastSnapshotAttemptAt': value['lastSnapshotAttemptAt'] == null ? value['lastSnapshotAttemptAt'] : value['lastSnapshotAttemptAt'].toISOString(),
@@ -0,0 +1,44 @@
1
+ /**
2
+ * Boat Public API v1
3
+ * Public JSON API for creating, operating, prompting, observing, and exposing sandboxes from backend services, CI jobs, hosted workers, and Boat automation products. The v1 reference intentionally documents the developer integration surface only. Dashboard billing actions are not part of v1.
4
+ *
5
+ * The version of the OpenAPI document: 1.0.0
6
+ *
7
+ *
8
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
9
+ * https://openapi-generator.tech
10
+ * Do not edit the class manually.
11
+ */
12
+ /**
13
+ * Only with `include=cost` on `GET /sandboxes`. Machine time this sandbox used this calendar month (UTC), at list price. Same meter as `GET /sandboxes/{sandboxId}/usage`.
14
+ * @export
15
+ * @interface SandboxCost
16
+ */
17
+ export interface SandboxCost {
18
+ /**
19
+ * The 1st of this month, 00:00 UTC.
20
+ * @type {Date}
21
+ * @memberof SandboxCost
22
+ */
23
+ since: Date;
24
+ /**
25
+ * Billable machine-seconds, size multiplier applied.
26
+ * @type {number}
27
+ * @memberof SandboxCost
28
+ */
29
+ seconds: number;
30
+ /**
31
+ * seconds / secondsPerDollar, at list price.
32
+ * @type {number}
33
+ * @memberof SandboxCost
34
+ */
35
+ dollars: number;
36
+ }
37
+ /**
38
+ * Check if a given object implements the SandboxCost interface.
39
+ */
40
+ export declare function instanceOfSandboxCost(value: object): value is SandboxCost;
41
+ export declare function SandboxCostFromJSON(json: any): SandboxCost;
42
+ export declare function SandboxCostFromJSONTyped(json: any, ignoreDiscriminator: boolean): SandboxCost;
43
+ export declare function SandboxCostToJSON(json: any): SandboxCost;
44
+ export declare function SandboxCostToJSONTyped(value?: SandboxCost | null, ignoreDiscriminator?: boolean): any;
@@ -0,0 +1,51 @@
1
+ /* tslint:disable */
2
+ /* eslint-disable */
3
+ /**
4
+ * Boat Public API v1
5
+ * Public JSON API for creating, operating, prompting, observing, and exposing sandboxes from backend services, CI jobs, hosted workers, and Boat automation products. The v1 reference intentionally documents the developer integration surface only. Dashboard billing actions are not part of v1.
6
+ *
7
+ * The version of the OpenAPI document: 1.0.0
8
+ *
9
+ *
10
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
11
+ * https://openapi-generator.tech
12
+ * Do not edit the class manually.
13
+ */
14
+ /**
15
+ * Check if a given object implements the SandboxCost interface.
16
+ */
17
+ export function instanceOfSandboxCost(value) {
18
+ if (!('since' in value) || value['since'] === undefined)
19
+ return false;
20
+ if (!('seconds' in value) || value['seconds'] === undefined)
21
+ return false;
22
+ if (!('dollars' in value) || value['dollars'] === undefined)
23
+ return false;
24
+ return true;
25
+ }
26
+ export function SandboxCostFromJSON(json) {
27
+ return SandboxCostFromJSONTyped(json, false);
28
+ }
29
+ export function SandboxCostFromJSONTyped(json, ignoreDiscriminator) {
30
+ if (json == null) {
31
+ return json;
32
+ }
33
+ return {
34
+ 'since': (new Date(json['since'])),
35
+ 'seconds': json['seconds'],
36
+ 'dollars': json['dollars'],
37
+ };
38
+ }
39
+ export function SandboxCostToJSON(json) {
40
+ return SandboxCostToJSONTyped(json, false);
41
+ }
42
+ export function SandboxCostToJSONTyped(value, ignoreDiscriminator = false) {
43
+ if (value == null) {
44
+ return value;
45
+ }
46
+ return {
47
+ 'since': value['since'].toISOString(),
48
+ 'seconds': value['seconds'],
49
+ 'dollars': value['dollars'],
50
+ };
51
+ }
@@ -0,0 +1,39 @@
1
+ /**
2
+ * Boat Public API v1
3
+ * Public JSON API for creating, operating, prompting, observing, and exposing sandboxes from backend services, CI jobs, hosted workers, and Boat automation products. The v1 reference intentionally documents the developer integration surface only. Dashboard billing actions are not part of v1.
4
+ *
5
+ * The version of the OpenAPI document: 1.0.0
6
+ *
7
+ *
8
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
9
+ * https://openapi-generator.tech
10
+ * Do not edit the class manually.
11
+ */
12
+ import type { Sandbox } from './Sandbox';
13
+ /**
14
+ *
15
+ * @export
16
+ * @interface Unshare200Response
17
+ */
18
+ export interface Unshare200Response {
19
+ /**
20
+ *
21
+ * @type {Sandbox}
22
+ * @memberof Unshare200Response
23
+ */
24
+ sandbox?: Sandbox;
25
+ /**
26
+ *
27
+ * @type {string}
28
+ * @memberof Unshare200Response
29
+ */
30
+ message?: string;
31
+ }
32
+ /**
33
+ * Check if a given object implements the Unshare200Response interface.
34
+ */
35
+ export declare function instanceOfUnshare200Response(value: object): value is Unshare200Response;
36
+ export declare function Unshare200ResponseFromJSON(json: any): Unshare200Response;
37
+ export declare function Unshare200ResponseFromJSONTyped(json: any, ignoreDiscriminator: boolean): Unshare200Response;
38
+ export declare function Unshare200ResponseToJSON(json: any): Unshare200Response;
39
+ export declare function Unshare200ResponseToJSONTyped(value?: Unshare200Response | null, ignoreDiscriminator?: boolean): any;
@@ -0,0 +1,44 @@
1
+ /* tslint:disable */
2
+ /* eslint-disable */
3
+ /**
4
+ * Boat Public API v1
5
+ * Public JSON API for creating, operating, prompting, observing, and exposing sandboxes from backend services, CI jobs, hosted workers, and Boat automation products. The v1 reference intentionally documents the developer integration surface only. Dashboard billing actions are not part of v1.
6
+ *
7
+ * The version of the OpenAPI document: 1.0.0
8
+ *
9
+ *
10
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
11
+ * https://openapi-generator.tech
12
+ * Do not edit the class manually.
13
+ */
14
+ import { SandboxFromJSON, SandboxToJSON, } from './Sandbox';
15
+ /**
16
+ * Check if a given object implements the Unshare200Response interface.
17
+ */
18
+ export function instanceOfUnshare200Response(value) {
19
+ return true;
20
+ }
21
+ export function Unshare200ResponseFromJSON(json) {
22
+ return Unshare200ResponseFromJSONTyped(json, false);
23
+ }
24
+ export function Unshare200ResponseFromJSONTyped(json, ignoreDiscriminator) {
25
+ if (json == null) {
26
+ return json;
27
+ }
28
+ return {
29
+ 'sandbox': json['sandbox'] == null ? undefined : SandboxFromJSON(json['sandbox']),
30
+ 'message': json['message'] == null ? undefined : json['message'],
31
+ };
32
+ }
33
+ export function Unshare200ResponseToJSON(json) {
34
+ return Unshare200ResponseToJSONTyped(json, false);
35
+ }
36
+ export function Unshare200ResponseToJSONTyped(value, ignoreDiscriminator = false) {
37
+ if (value == null) {
38
+ return value;
39
+ }
40
+ return {
41
+ 'sandbox': SandboxToJSON(value['sandbox']),
42
+ 'message': value['message'],
43
+ };
44
+ }