@boatdev/sdk 1.5.0 → 1.7.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.
- package/.openapi-generator/FILES +4 -0
- package/dist/apis/BoatApi.d.ts +2 -2
- package/dist/apis/BoatApi.js +2 -2
- package/dist/boat-helpers.d.ts +6 -0
- package/dist/boat-helpers.js +28 -4
- package/dist/esm/apis/BoatApi.d.ts +2 -2
- package/dist/esm/apis/BoatApi.js +2 -2
- package/dist/esm/boat-helpers.d.ts +6 -0
- package/dist/esm/boat-helpers.js +28 -4
- package/dist/esm/models/Conversation.d.ts +1 -1
- package/dist/esm/models/NamedSnapshotAllowance.d.ts +74 -0
- package/dist/esm/models/NamedSnapshotAllowance.js +55 -0
- package/dist/esm/models/NamedSnapshotListResponse.d.ts +7 -0
- package/dist/esm/models/NamedSnapshotListResponse.js +3 -0
- package/dist/esm/models/PromptRequest.d.ts +2 -1
- package/dist/esm/models/PromptRequest.js +2 -1
- package/dist/esm/models/Sandbox.d.ts +19 -0
- package/dist/esm/models/Sandbox.js +7 -0
- package/dist/esm/models/StopOperation.d.ts +72 -0
- package/dist/esm/models/StopOperation.js +72 -0
- package/dist/esm/models/index.d.ts +2 -0
- package/dist/esm/models/index.js +2 -0
- package/dist/models/Conversation.d.ts +1 -1
- package/dist/models/NamedSnapshotAllowance.d.ts +74 -0
- package/dist/models/NamedSnapshotAllowance.js +62 -0
- package/dist/models/NamedSnapshotListResponse.d.ts +7 -0
- package/dist/models/NamedSnapshotListResponse.js +3 -0
- package/dist/models/PromptRequest.d.ts +2 -1
- package/dist/models/PromptRequest.js +2 -1
- package/dist/models/Sandbox.d.ts +19 -0
- package/dist/models/Sandbox.js +7 -0
- package/dist/models/StopOperation.d.ts +72 -0
- package/dist/models/StopOperation.js +80 -0
- package/dist/models/index.d.ts +2 -0
- package/dist/models/index.js +2 -0
- package/docs/BoatApi.md +3 -2
- package/docs/NamedSnapshotAllowance.md +47 -0
- package/docs/NamedSnapshotListResponse.md +2 -0
- package/docs/PromptRequest.md +1 -1
- package/docs/Sandbox.md +6 -0
- package/docs/StopOperation.md +42 -0
- package/package.json +1 -1
- package/src/apis/BoatApi.ts +2 -2
- package/src/boat-helpers.ts +27 -5
- package/src/models/Conversation.ts +1 -1
- package/src/models/NamedSnapshotAllowance.ts +121 -0
- package/src/models/NamedSnapshotListResponse.ts +15 -0
- package/src/models/PromptRequest.ts +3 -2
- package/src/models/Sandbox.ts +31 -0
- package/src/models/StopOperation.ts +124 -0
- package/src/models/index.ts +2 -0
|
@@ -0,0 +1,72 @@
|
|
|
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
|
+
* @export
|
|
16
|
+
*/
|
|
17
|
+
export const StopOperationStatusEnum = {
|
|
18
|
+
Pending: 'pending',
|
|
19
|
+
Failing: 'failing',
|
|
20
|
+
Completed: 'completed',
|
|
21
|
+
Superseded: 'superseded'
|
|
22
|
+
};
|
|
23
|
+
/**
|
|
24
|
+
* Check if a given object implements the StopOperation interface.
|
|
25
|
+
*/
|
|
26
|
+
export function instanceOfStopOperation(value) {
|
|
27
|
+
if (!('id' in value) || value['id'] === undefined)
|
|
28
|
+
return false;
|
|
29
|
+
if (!('status' in value) || value['status'] === undefined)
|
|
30
|
+
return false;
|
|
31
|
+
if (!('requestedAt' in value) || value['requestedAt'] === undefined)
|
|
32
|
+
return false;
|
|
33
|
+
if (!('lastAttemptAt' in value) || value['lastAttemptAt'] === undefined)
|
|
34
|
+
return false;
|
|
35
|
+
if (!('error' in value) || value['error'] === undefined)
|
|
36
|
+
return false;
|
|
37
|
+
if (!('endedAt' in value) || value['endedAt'] === undefined)
|
|
38
|
+
return false;
|
|
39
|
+
return true;
|
|
40
|
+
}
|
|
41
|
+
export function StopOperationFromJSON(json) {
|
|
42
|
+
return StopOperationFromJSONTyped(json, false);
|
|
43
|
+
}
|
|
44
|
+
export function StopOperationFromJSONTyped(json, ignoreDiscriminator) {
|
|
45
|
+
if (json == null) {
|
|
46
|
+
return json;
|
|
47
|
+
}
|
|
48
|
+
return {
|
|
49
|
+
'id': json['id'],
|
|
50
|
+
'status': json['status'],
|
|
51
|
+
'requestedAt': (json['requestedAt'] == null ? null : new Date(json['requestedAt'])),
|
|
52
|
+
'lastAttemptAt': (json['lastAttemptAt'] == null ? null : new Date(json['lastAttemptAt'])),
|
|
53
|
+
'error': json['error'],
|
|
54
|
+
'endedAt': (json['endedAt'] == null ? null : new Date(json['endedAt'])),
|
|
55
|
+
};
|
|
56
|
+
}
|
|
57
|
+
export function StopOperationToJSON(json) {
|
|
58
|
+
return StopOperationToJSONTyped(json, false);
|
|
59
|
+
}
|
|
60
|
+
export function StopOperationToJSONTyped(value, ignoreDiscriminator = false) {
|
|
61
|
+
if (value == null) {
|
|
62
|
+
return value;
|
|
63
|
+
}
|
|
64
|
+
return {
|
|
65
|
+
'id': value['id'],
|
|
66
|
+
'status': value['status'],
|
|
67
|
+
'requestedAt': value['requestedAt'] == null ? value['requestedAt'] : value['requestedAt'].toISOString(),
|
|
68
|
+
'lastAttemptAt': value['lastAttemptAt'] == null ? value['lastAttemptAt'] : value['lastAttemptAt'].toISOString(),
|
|
69
|
+
'error': value['error'],
|
|
70
|
+
'endedAt': value['endedAt'] == null ? value['endedAt'] : value['endedAt'].toISOString(),
|
|
71
|
+
};
|
|
72
|
+
}
|
|
@@ -57,6 +57,7 @@ export * from './LimitsResponse';
|
|
|
57
57
|
export * from './MeResponse';
|
|
58
58
|
export * from './MeResponseAllOfUser';
|
|
59
59
|
export * from './NamedSnapshot';
|
|
60
|
+
export * from './NamedSnapshotAllowance';
|
|
60
61
|
export * from './NamedSnapshotDeletedResponse';
|
|
61
62
|
export * from './NamedSnapshotInfoResponse';
|
|
62
63
|
export * from './NamedSnapshotListResponse';
|
|
@@ -115,6 +116,7 @@ export * from './SteerEvent';
|
|
|
115
116
|
export * from './SteerEventData';
|
|
116
117
|
export * from './SteerRequest';
|
|
117
118
|
export * from './SteerResponse';
|
|
119
|
+
export * from './StopOperation';
|
|
118
120
|
export * from './StopRequest';
|
|
119
121
|
export * from './SuccessBase';
|
|
120
122
|
export * from './UnknownEvent';
|
package/dist/esm/models/index.js
CHANGED
|
@@ -59,6 +59,7 @@ export * from './LimitsResponse';
|
|
|
59
59
|
export * from './MeResponse';
|
|
60
60
|
export * from './MeResponseAllOfUser';
|
|
61
61
|
export * from './NamedSnapshot';
|
|
62
|
+
export * from './NamedSnapshotAllowance';
|
|
62
63
|
export * from './NamedSnapshotDeletedResponse';
|
|
63
64
|
export * from './NamedSnapshotInfoResponse';
|
|
64
65
|
export * from './NamedSnapshotListResponse';
|
|
@@ -117,6 +118,7 @@ export * from './SteerEvent';
|
|
|
117
118
|
export * from './SteerEventData';
|
|
118
119
|
export * from './SteerRequest';
|
|
119
120
|
export * from './SteerResponse';
|
|
121
|
+
export * from './StopOperation';
|
|
120
122
|
export * from './StopRequest';
|
|
121
123
|
export * from './SuccessBase';
|
|
122
124
|
export * from './UnknownEvent';
|
|
@@ -46,7 +46,7 @@ export interface Conversation {
|
|
|
46
46
|
*/
|
|
47
47
|
running: boolean;
|
|
48
48
|
/**
|
|
49
|
-
* Harness the most recent prompt ran on (`claude`, `codex`, `pi`, `opencode`, `prime-agent`, `kimi`).
|
|
49
|
+
* Harness the most recent prompt ran on (`claude`, `codex`, `pi`, `opencode`, `prime-agent`, `kimi`, `mistral`).
|
|
50
50
|
* @type {string}
|
|
51
51
|
* @memberof Conversation
|
|
52
52
|
*/
|
|
@@ -0,0 +1,74 @@
|
|
|
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
|
+
* What the request's wallet (your active organization, `?org=`, or personal) pays for named snapshots. 10 are free per wallet; each one above costs $1.70 a month, charged daily from usage. An organization's count includes every member's names billed to it.
|
|
14
|
+
* @export
|
|
15
|
+
* @interface NamedSnapshotAllowance
|
|
16
|
+
*/
|
|
17
|
+
export interface NamedSnapshotAllowance {
|
|
18
|
+
/**
|
|
19
|
+
* Organization the numbers are for. null = personal.
|
|
20
|
+
* @type {string}
|
|
21
|
+
* @memberof NamedSnapshotAllowance
|
|
22
|
+
*/
|
|
23
|
+
org?: string | null;
|
|
24
|
+
/**
|
|
25
|
+
* That organization's name.
|
|
26
|
+
* @type {string}
|
|
27
|
+
* @memberof NamedSnapshotAllowance
|
|
28
|
+
*/
|
|
29
|
+
orgName?: string | null;
|
|
30
|
+
/**
|
|
31
|
+
* Named snapshots kept for free.
|
|
32
|
+
* @type {number}
|
|
33
|
+
* @memberof NamedSnapshotAllowance
|
|
34
|
+
*/
|
|
35
|
+
free?: number;
|
|
36
|
+
/**
|
|
37
|
+
* Named snapshots this wallet keeps.
|
|
38
|
+
* @type {number}
|
|
39
|
+
* @memberof NamedSnapshotAllowance
|
|
40
|
+
*/
|
|
41
|
+
used?: number;
|
|
42
|
+
/**
|
|
43
|
+
* Named snapshots above the free ones.
|
|
44
|
+
* @type {number}
|
|
45
|
+
* @memberof NamedSnapshotAllowance
|
|
46
|
+
*/
|
|
47
|
+
extra?: number;
|
|
48
|
+
/**
|
|
49
|
+
* What the extra ones cost per month.
|
|
50
|
+
* @type {number}
|
|
51
|
+
* @memberof NamedSnapshotAllowance
|
|
52
|
+
*/
|
|
53
|
+
extraMonthlyDollars?: number;
|
|
54
|
+
/**
|
|
55
|
+
* Boat time the extra ones take per day, in dollars (the daily charge).
|
|
56
|
+
* @type {number}
|
|
57
|
+
* @memberof NamedSnapshotAllowance
|
|
58
|
+
*/
|
|
59
|
+
extraDailyDollars?: number;
|
|
60
|
+
/**
|
|
61
|
+
* Monthly price of one extra named snapshot.
|
|
62
|
+
* @type {number}
|
|
63
|
+
* @memberof NamedSnapshotAllowance
|
|
64
|
+
*/
|
|
65
|
+
pricePerExtraMonthlyDollars?: number;
|
|
66
|
+
}
|
|
67
|
+
/**
|
|
68
|
+
* Check if a given object implements the NamedSnapshotAllowance interface.
|
|
69
|
+
*/
|
|
70
|
+
export declare function instanceOfNamedSnapshotAllowance(value: object): value is NamedSnapshotAllowance;
|
|
71
|
+
export declare function NamedSnapshotAllowanceFromJSON(json: any): NamedSnapshotAllowance;
|
|
72
|
+
export declare function NamedSnapshotAllowanceFromJSONTyped(json: any, ignoreDiscriminator: boolean): NamedSnapshotAllowance;
|
|
73
|
+
export declare function NamedSnapshotAllowanceToJSON(json: any): NamedSnapshotAllowance;
|
|
74
|
+
export declare function NamedSnapshotAllowanceToJSONTyped(value?: NamedSnapshotAllowance | null, ignoreDiscriminator?: boolean): any;
|
|
@@ -0,0 +1,62 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
/* tslint:disable */
|
|
3
|
+
/* eslint-disable */
|
|
4
|
+
/**
|
|
5
|
+
* Boat Public API v1
|
|
6
|
+
* 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.
|
|
7
|
+
*
|
|
8
|
+
* The version of the OpenAPI document: 1.0.0
|
|
9
|
+
*
|
|
10
|
+
*
|
|
11
|
+
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
12
|
+
* https://openapi-generator.tech
|
|
13
|
+
* Do not edit the class manually.
|
|
14
|
+
*/
|
|
15
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
16
|
+
exports.instanceOfNamedSnapshotAllowance = instanceOfNamedSnapshotAllowance;
|
|
17
|
+
exports.NamedSnapshotAllowanceFromJSON = NamedSnapshotAllowanceFromJSON;
|
|
18
|
+
exports.NamedSnapshotAllowanceFromJSONTyped = NamedSnapshotAllowanceFromJSONTyped;
|
|
19
|
+
exports.NamedSnapshotAllowanceToJSON = NamedSnapshotAllowanceToJSON;
|
|
20
|
+
exports.NamedSnapshotAllowanceToJSONTyped = NamedSnapshotAllowanceToJSONTyped;
|
|
21
|
+
/**
|
|
22
|
+
* Check if a given object implements the NamedSnapshotAllowance interface.
|
|
23
|
+
*/
|
|
24
|
+
function instanceOfNamedSnapshotAllowance(value) {
|
|
25
|
+
return true;
|
|
26
|
+
}
|
|
27
|
+
function NamedSnapshotAllowanceFromJSON(json) {
|
|
28
|
+
return NamedSnapshotAllowanceFromJSONTyped(json, false);
|
|
29
|
+
}
|
|
30
|
+
function NamedSnapshotAllowanceFromJSONTyped(json, ignoreDiscriminator) {
|
|
31
|
+
if (json == null) {
|
|
32
|
+
return json;
|
|
33
|
+
}
|
|
34
|
+
return {
|
|
35
|
+
'org': json['org'] == null ? undefined : json['org'],
|
|
36
|
+
'orgName': json['orgName'] == null ? undefined : json['orgName'],
|
|
37
|
+
'free': json['free'] == null ? undefined : json['free'],
|
|
38
|
+
'used': json['used'] == null ? undefined : json['used'],
|
|
39
|
+
'extra': json['extra'] == null ? undefined : json['extra'],
|
|
40
|
+
'extraMonthlyDollars': json['extraMonthlyDollars'] == null ? undefined : json['extraMonthlyDollars'],
|
|
41
|
+
'extraDailyDollars': json['extraDailyDollars'] == null ? undefined : json['extraDailyDollars'],
|
|
42
|
+
'pricePerExtraMonthlyDollars': json['pricePerExtraMonthlyDollars'] == null ? undefined : json['pricePerExtraMonthlyDollars'],
|
|
43
|
+
};
|
|
44
|
+
}
|
|
45
|
+
function NamedSnapshotAllowanceToJSON(json) {
|
|
46
|
+
return NamedSnapshotAllowanceToJSONTyped(json, false);
|
|
47
|
+
}
|
|
48
|
+
function NamedSnapshotAllowanceToJSONTyped(value, ignoreDiscriminator = false) {
|
|
49
|
+
if (value == null) {
|
|
50
|
+
return value;
|
|
51
|
+
}
|
|
52
|
+
return {
|
|
53
|
+
'org': value['org'],
|
|
54
|
+
'orgName': value['orgName'],
|
|
55
|
+
'free': value['free'],
|
|
56
|
+
'used': value['used'],
|
|
57
|
+
'extra': value['extra'],
|
|
58
|
+
'extraMonthlyDollars': value['extraMonthlyDollars'],
|
|
59
|
+
'extraDailyDollars': value['extraDailyDollars'],
|
|
60
|
+
'pricePerExtraMonthlyDollars': value['pricePerExtraMonthlyDollars'],
|
|
61
|
+
};
|
|
62
|
+
}
|
|
@@ -9,6 +9,7 @@
|
|
|
9
9
|
* https://openapi-generator.tech
|
|
10
10
|
* Do not edit the class manually.
|
|
11
11
|
*/
|
|
12
|
+
import type { NamedSnapshotAllowance } from './NamedSnapshotAllowance';
|
|
12
13
|
import type { NamedSnapshot } from './NamedSnapshot';
|
|
13
14
|
/**
|
|
14
15
|
*
|
|
@@ -34,6 +35,12 @@ export interface NamedSnapshotListResponse {
|
|
|
34
35
|
* @memberof NamedSnapshotListResponse
|
|
35
36
|
*/
|
|
36
37
|
snapshots: Array<NamedSnapshot>;
|
|
38
|
+
/**
|
|
39
|
+
*
|
|
40
|
+
* @type {NamedSnapshotAllowance}
|
|
41
|
+
* @memberof NamedSnapshotListResponse
|
|
42
|
+
*/
|
|
43
|
+
allowance?: NamedSnapshotAllowance;
|
|
37
44
|
}
|
|
38
45
|
/**
|
|
39
46
|
* @export
|
|
@@ -19,6 +19,7 @@ exports.NamedSnapshotListResponseFromJSON = NamedSnapshotListResponseFromJSON;
|
|
|
19
19
|
exports.NamedSnapshotListResponseFromJSONTyped = NamedSnapshotListResponseFromJSONTyped;
|
|
20
20
|
exports.NamedSnapshotListResponseToJSON = NamedSnapshotListResponseToJSON;
|
|
21
21
|
exports.NamedSnapshotListResponseToJSONTyped = NamedSnapshotListResponseToJSONTyped;
|
|
22
|
+
const NamedSnapshotAllowance_1 = require("./NamedSnapshotAllowance");
|
|
22
23
|
const NamedSnapshot_1 = require("./NamedSnapshot");
|
|
23
24
|
/**
|
|
24
25
|
* @export
|
|
@@ -49,6 +50,7 @@ function NamedSnapshotListResponseFromJSONTyped(json, ignoreDiscriminator) {
|
|
|
49
50
|
'ok': json['ok'],
|
|
50
51
|
'type': json['type'],
|
|
51
52
|
'snapshots': (json['snapshots'].map(NamedSnapshot_1.NamedSnapshotFromJSON)),
|
|
53
|
+
'allowance': json['allowance'] == null ? undefined : (0, NamedSnapshotAllowance_1.NamedSnapshotAllowanceFromJSON)(json['allowance']),
|
|
52
54
|
};
|
|
53
55
|
}
|
|
54
56
|
function NamedSnapshotListResponseToJSON(json) {
|
|
@@ -62,5 +64,6 @@ function NamedSnapshotListResponseToJSONTyped(value, ignoreDiscriminator = false
|
|
|
62
64
|
'ok': value['ok'],
|
|
63
65
|
'type': value['type'],
|
|
64
66
|
'snapshots': (value['snapshots'].map(NamedSnapshot_1.NamedSnapshotToJSON)),
|
|
67
|
+
'allowance': (0, NamedSnapshotAllowance_1.NamedSnapshotAllowanceToJSON)(value['allowance']),
|
|
65
68
|
};
|
|
66
69
|
}
|
|
@@ -12,7 +12,7 @@
|
|
|
12
12
|
/**
|
|
13
13
|
* Work item to queue inside an existing sandbox. Provider credentials must already be configured in the Boat dashboard.
|
|
14
14
|
*
|
|
15
|
-
* **Providers (harnesses):** `codex`, `claude-code` (alias `claude`), `pi`, `opencode`, `prime-agent` (alias `prime`), `kimi` (Kimi Code CLI, alias `kimi-code`). Omit `provider` to use the harness the user selected on the Agents dashboard.
|
|
15
|
+
* **Providers (harnesses):** `codex`, `claude-code` (alias `claude`), `pi`, `opencode`, `prime-agent` (alias `prime`), `kimi` (Kimi Code CLI, alias `kimi-code`), `mistral` (Mistral Vibe). Omit `provider` to use the harness the user selected on the Agents dashboard.
|
|
16
16
|
*
|
|
17
17
|
* **Models & reasoning effort** are harness- and model-specific and change over time. Fetch the live catalog (every provider's models and which reasoning-effort levels each accepts) from `GET /provider-models`. Some models accept no reasoning control. `pi`, `opencode` and `prime-agent` also expose models routed through OpenRouter and llmgateway (ids like `openrouter:anthropic/claude-sonnet-4.5`).
|
|
18
18
|
*
|
|
@@ -78,6 +78,7 @@ export declare const PromptRequestProviderEnum: {
|
|
|
78
78
|
readonly Prime: 'prime';
|
|
79
79
|
readonly Kimi: 'kimi';
|
|
80
80
|
readonly KimiCode: 'kimi-code';
|
|
81
|
+
readonly Mistral: 'mistral';
|
|
81
82
|
};
|
|
82
83
|
export type PromptRequestProviderEnum = typeof PromptRequestProviderEnum[keyof typeof PromptRequestProviderEnum];
|
|
83
84
|
/**
|
|
@@ -31,7 +31,8 @@ exports.PromptRequestProviderEnum = {
|
|
|
31
31
|
PrimeAgent: 'prime-agent',
|
|
32
32
|
Prime: 'prime',
|
|
33
33
|
Kimi: 'kimi',
|
|
34
|
-
KimiCode: 'kimi-code'
|
|
34
|
+
KimiCode: 'kimi-code',
|
|
35
|
+
Mistral: 'mistral'
|
|
35
36
|
};
|
|
36
37
|
/**
|
|
37
38
|
* Check if a given object implements the PromptRequest interface.
|
package/dist/models/Sandbox.d.ts
CHANGED
|
@@ -10,6 +10,7 @@
|
|
|
10
10
|
* Do not edit the class manually.
|
|
11
11
|
*/
|
|
12
12
|
import type { SandboxTeam } from './SandboxTeam';
|
|
13
|
+
import type { StopOperation } from './StopOperation';
|
|
13
14
|
/**
|
|
14
15
|
*
|
|
15
16
|
* @export
|
|
@@ -58,6 +59,18 @@ export interface Sandbox {
|
|
|
58
59
|
* @memberof Sandbox
|
|
59
60
|
*/
|
|
60
61
|
degradedSince?: Date | null;
|
|
62
|
+
/**
|
|
63
|
+
* True once every file of the sandbox's snapshot is on its disk. A resumed or forked sandbox is usable before that: its files keep copying in the background, and its docker volumes move onto the real disk near the end. Its docker containers start earlier; at that point their volume mounts move onto the real disk in place, without a restart. The `sandbox.hydrated` webhook fires at the same moment this turns true. A sandbox that restored nothing is hydrated from the start.
|
|
64
|
+
* @type {boolean}
|
|
65
|
+
* @memberof Sandbox
|
|
66
|
+
*/
|
|
67
|
+
hydrated?: boolean;
|
|
68
|
+
/**
|
|
69
|
+
* When the last resume or fork finished copying files in, or null.
|
|
70
|
+
* @type {Date}
|
|
71
|
+
* @memberof Sandbox
|
|
72
|
+
*/
|
|
73
|
+
hydratedAt?: Date | null;
|
|
61
74
|
/**
|
|
62
75
|
* Current machine size: what the sandbox was created with, or the size it was last resumed or forked onto.
|
|
63
76
|
* @type {SandboxTypeEnum}
|
|
@@ -238,6 +251,12 @@ export interface Sandbox {
|
|
|
238
251
|
* @memberof Sandbox
|
|
239
252
|
*/
|
|
240
253
|
environmentVersion?: number | null;
|
|
254
|
+
/**
|
|
255
|
+
* The last stop you requested (`POST /sandboxes/{sandboxId}/stop`), or null if you never stopped this sandbox.
|
|
256
|
+
* @type {StopOperation}
|
|
257
|
+
* @memberof Sandbox
|
|
258
|
+
*/
|
|
259
|
+
stop?: StopOperation | null;
|
|
241
260
|
}
|
|
242
261
|
/**
|
|
243
262
|
* @export
|
package/dist/models/Sandbox.js
CHANGED
|
@@ -20,6 +20,7 @@ exports.SandboxFromJSONTyped = SandboxFromJSONTyped;
|
|
|
20
20
|
exports.SandboxToJSON = SandboxToJSON;
|
|
21
21
|
exports.SandboxToJSONTyped = SandboxToJSONTyped;
|
|
22
22
|
const SandboxTeam_1 = require("./SandboxTeam");
|
|
23
|
+
const StopOperation_1 = require("./StopOperation");
|
|
23
24
|
/**
|
|
24
25
|
* @export
|
|
25
26
|
*/
|
|
@@ -116,6 +117,8 @@ function SandboxFromJSONTyped(json, ignoreDiscriminator) {
|
|
|
116
117
|
'health': json['health'] == null ? undefined : json['health'],
|
|
117
118
|
'healthReason': json['healthReason'] == null ? undefined : json['healthReason'],
|
|
118
119
|
'degradedSince': json['degradedSince'] == null ? undefined : (new Date(json['degradedSince'])),
|
|
120
|
+
'hydrated': json['hydrated'] == null ? undefined : json['hydrated'],
|
|
121
|
+
'hydratedAt': json['hydratedAt'] == null ? undefined : (new Date(json['hydratedAt'])),
|
|
119
122
|
'type': json['type'] == null ? undefined : json['type'],
|
|
120
123
|
'vcpu': json['vcpu'] == null ? undefined : json['vcpu'],
|
|
121
124
|
'memoryGB': json['memoryGB'] == null ? undefined : json['memoryGB'],
|
|
@@ -146,6 +149,7 @@ function SandboxFromJSONTyped(json, ignoreDiscriminator) {
|
|
|
146
149
|
'setupError': json['setupError'] == null ? undefined : json['setupError'],
|
|
147
150
|
'environment': json['environment'] == null ? undefined : json['environment'],
|
|
148
151
|
'environmentVersion': json['environmentVersion'] == null ? undefined : json['environmentVersion'],
|
|
152
|
+
'stop': json['stop'] == null ? undefined : (0, StopOperation_1.StopOperationFromJSON)(json['stop']),
|
|
149
153
|
};
|
|
150
154
|
}
|
|
151
155
|
function SandboxToJSON(json) {
|
|
@@ -163,6 +167,8 @@ function SandboxToJSONTyped(value, ignoreDiscriminator = false) {
|
|
|
163
167
|
'health': value['health'],
|
|
164
168
|
'healthReason': value['healthReason'],
|
|
165
169
|
'degradedSince': value['degradedSince'] == null ? value['degradedSince'] : value['degradedSince'].toISOString(),
|
|
170
|
+
'hydrated': value['hydrated'],
|
|
171
|
+
'hydratedAt': value['hydratedAt'] == null ? value['hydratedAt'] : value['hydratedAt'].toISOString(),
|
|
166
172
|
'type': value['type'],
|
|
167
173
|
'vcpu': value['vcpu'],
|
|
168
174
|
'memoryGB': value['memoryGB'],
|
|
@@ -193,5 +199,6 @@ function SandboxToJSONTyped(value, ignoreDiscriminator = false) {
|
|
|
193
199
|
'setupError': value['setupError'],
|
|
194
200
|
'environment': value['environment'],
|
|
195
201
|
'environmentVersion': value['environmentVersion'],
|
|
202
|
+
'stop': (0, StopOperation_1.StopOperationToJSON)(value['stop']),
|
|
196
203
|
};
|
|
197
204
|
}
|
|
@@ -0,0 +1,72 @@
|
|
|
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
|
+
*
|
|
14
|
+
* @export
|
|
15
|
+
* @interface StopOperation
|
|
16
|
+
*/
|
|
17
|
+
export interface StopOperation {
|
|
18
|
+
/**
|
|
19
|
+
* Stable id of this stop. Calling stop again while it is pending returns the same id.
|
|
20
|
+
* @type {string}
|
|
21
|
+
* @memberof StopOperation
|
|
22
|
+
*/
|
|
23
|
+
id: string;
|
|
24
|
+
/**
|
|
25
|
+
* `pending`: accepted, the sandbox is archiving. `failing`: the last attempt failed (see `error`); it is retried automatically until the sandbox archives. Running commands or prompts does not cancel it. `completed`: the sandbox is archived. `superseded`: a resume ended it before it completed.
|
|
26
|
+
* @type {StopOperationStatusEnum}
|
|
27
|
+
* @memberof StopOperation
|
|
28
|
+
*/
|
|
29
|
+
status: StopOperationStatusEnum;
|
|
30
|
+
/**
|
|
31
|
+
* When the stop was accepted. Null once it has ended.
|
|
32
|
+
* @type {Date}
|
|
33
|
+
* @memberof StopOperation
|
|
34
|
+
*/
|
|
35
|
+
requestedAt: Date | null;
|
|
36
|
+
/**
|
|
37
|
+
* When the last archival attempt ended.
|
|
38
|
+
* @type {Date}
|
|
39
|
+
* @memberof StopOperation
|
|
40
|
+
*/
|
|
41
|
+
lastAttemptAt: Date | null;
|
|
42
|
+
/**
|
|
43
|
+
* Why the last attempt failed, while `status` is `failing`. Otherwise null.
|
|
44
|
+
* @type {string}
|
|
45
|
+
* @memberof StopOperation
|
|
46
|
+
*/
|
|
47
|
+
error: string | null;
|
|
48
|
+
/**
|
|
49
|
+
* When the stop completed or was superseded.
|
|
50
|
+
* @type {Date}
|
|
51
|
+
* @memberof StopOperation
|
|
52
|
+
*/
|
|
53
|
+
endedAt: Date | null;
|
|
54
|
+
}
|
|
55
|
+
/**
|
|
56
|
+
* @export
|
|
57
|
+
*/
|
|
58
|
+
export declare const StopOperationStatusEnum: {
|
|
59
|
+
readonly Pending: 'pending';
|
|
60
|
+
readonly Failing: 'failing';
|
|
61
|
+
readonly Completed: 'completed';
|
|
62
|
+
readonly Superseded: 'superseded';
|
|
63
|
+
};
|
|
64
|
+
export type StopOperationStatusEnum = typeof StopOperationStatusEnum[keyof typeof StopOperationStatusEnum];
|
|
65
|
+
/**
|
|
66
|
+
* Check if a given object implements the StopOperation interface.
|
|
67
|
+
*/
|
|
68
|
+
export declare function instanceOfStopOperation(value: object): value is StopOperation;
|
|
69
|
+
export declare function StopOperationFromJSON(json: any): StopOperation;
|
|
70
|
+
export declare function StopOperationFromJSONTyped(json: any, ignoreDiscriminator: boolean): StopOperation;
|
|
71
|
+
export declare function StopOperationToJSON(json: any): StopOperation;
|
|
72
|
+
export declare function StopOperationToJSONTyped(value?: StopOperation | null, ignoreDiscriminator?: boolean): any;
|
|
@@ -0,0 +1,80 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
/* tslint:disable */
|
|
3
|
+
/* eslint-disable */
|
|
4
|
+
/**
|
|
5
|
+
* Boat Public API v1
|
|
6
|
+
* 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.
|
|
7
|
+
*
|
|
8
|
+
* The version of the OpenAPI document: 1.0.0
|
|
9
|
+
*
|
|
10
|
+
*
|
|
11
|
+
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
12
|
+
* https://openapi-generator.tech
|
|
13
|
+
* Do not edit the class manually.
|
|
14
|
+
*/
|
|
15
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
16
|
+
exports.StopOperationStatusEnum = void 0;
|
|
17
|
+
exports.instanceOfStopOperation = instanceOfStopOperation;
|
|
18
|
+
exports.StopOperationFromJSON = StopOperationFromJSON;
|
|
19
|
+
exports.StopOperationFromJSONTyped = StopOperationFromJSONTyped;
|
|
20
|
+
exports.StopOperationToJSON = StopOperationToJSON;
|
|
21
|
+
exports.StopOperationToJSONTyped = StopOperationToJSONTyped;
|
|
22
|
+
/**
|
|
23
|
+
* @export
|
|
24
|
+
*/
|
|
25
|
+
exports.StopOperationStatusEnum = {
|
|
26
|
+
Pending: 'pending',
|
|
27
|
+
Failing: 'failing',
|
|
28
|
+
Completed: 'completed',
|
|
29
|
+
Superseded: 'superseded'
|
|
30
|
+
};
|
|
31
|
+
/**
|
|
32
|
+
* Check if a given object implements the StopOperation interface.
|
|
33
|
+
*/
|
|
34
|
+
function instanceOfStopOperation(value) {
|
|
35
|
+
if (!('id' in value) || value['id'] === undefined)
|
|
36
|
+
return false;
|
|
37
|
+
if (!('status' in value) || value['status'] === undefined)
|
|
38
|
+
return false;
|
|
39
|
+
if (!('requestedAt' in value) || value['requestedAt'] === undefined)
|
|
40
|
+
return false;
|
|
41
|
+
if (!('lastAttemptAt' in value) || value['lastAttemptAt'] === undefined)
|
|
42
|
+
return false;
|
|
43
|
+
if (!('error' in value) || value['error'] === undefined)
|
|
44
|
+
return false;
|
|
45
|
+
if (!('endedAt' in value) || value['endedAt'] === undefined)
|
|
46
|
+
return false;
|
|
47
|
+
return true;
|
|
48
|
+
}
|
|
49
|
+
function StopOperationFromJSON(json) {
|
|
50
|
+
return StopOperationFromJSONTyped(json, false);
|
|
51
|
+
}
|
|
52
|
+
function StopOperationFromJSONTyped(json, ignoreDiscriminator) {
|
|
53
|
+
if (json == null) {
|
|
54
|
+
return json;
|
|
55
|
+
}
|
|
56
|
+
return {
|
|
57
|
+
'id': json['id'],
|
|
58
|
+
'status': json['status'],
|
|
59
|
+
'requestedAt': (json['requestedAt'] == null ? null : new Date(json['requestedAt'])),
|
|
60
|
+
'lastAttemptAt': (json['lastAttemptAt'] == null ? null : new Date(json['lastAttemptAt'])),
|
|
61
|
+
'error': json['error'],
|
|
62
|
+
'endedAt': (json['endedAt'] == null ? null : new Date(json['endedAt'])),
|
|
63
|
+
};
|
|
64
|
+
}
|
|
65
|
+
function StopOperationToJSON(json) {
|
|
66
|
+
return StopOperationToJSONTyped(json, false);
|
|
67
|
+
}
|
|
68
|
+
function StopOperationToJSONTyped(value, ignoreDiscriminator = false) {
|
|
69
|
+
if (value == null) {
|
|
70
|
+
return value;
|
|
71
|
+
}
|
|
72
|
+
return {
|
|
73
|
+
'id': value['id'],
|
|
74
|
+
'status': value['status'],
|
|
75
|
+
'requestedAt': value['requestedAt'] == null ? value['requestedAt'] : value['requestedAt'].toISOString(),
|
|
76
|
+
'lastAttemptAt': value['lastAttemptAt'] == null ? value['lastAttemptAt'] : value['lastAttemptAt'].toISOString(),
|
|
77
|
+
'error': value['error'],
|
|
78
|
+
'endedAt': value['endedAt'] == null ? value['endedAt'] : value['endedAt'].toISOString(),
|
|
79
|
+
};
|
|
80
|
+
}
|
package/dist/models/index.d.ts
CHANGED
|
@@ -57,6 +57,7 @@ export * from './LimitsResponse';
|
|
|
57
57
|
export * from './MeResponse';
|
|
58
58
|
export * from './MeResponseAllOfUser';
|
|
59
59
|
export * from './NamedSnapshot';
|
|
60
|
+
export * from './NamedSnapshotAllowance';
|
|
60
61
|
export * from './NamedSnapshotDeletedResponse';
|
|
61
62
|
export * from './NamedSnapshotInfoResponse';
|
|
62
63
|
export * from './NamedSnapshotListResponse';
|
|
@@ -115,6 +116,7 @@ export * from './SteerEvent';
|
|
|
115
116
|
export * from './SteerEventData';
|
|
116
117
|
export * from './SteerRequest';
|
|
117
118
|
export * from './SteerResponse';
|
|
119
|
+
export * from './StopOperation';
|
|
118
120
|
export * from './StopRequest';
|
|
119
121
|
export * from './SuccessBase';
|
|
120
122
|
export * from './UnknownEvent';
|
package/dist/models/index.js
CHANGED
|
@@ -75,6 +75,7 @@ __exportStar(require("./LimitsResponse"), exports);
|
|
|
75
75
|
__exportStar(require("./MeResponse"), exports);
|
|
76
76
|
__exportStar(require("./MeResponseAllOfUser"), exports);
|
|
77
77
|
__exportStar(require("./NamedSnapshot"), exports);
|
|
78
|
+
__exportStar(require("./NamedSnapshotAllowance"), exports);
|
|
78
79
|
__exportStar(require("./NamedSnapshotDeletedResponse"), exports);
|
|
79
80
|
__exportStar(require("./NamedSnapshotInfoResponse"), exports);
|
|
80
81
|
__exportStar(require("./NamedSnapshotListResponse"), exports);
|
|
@@ -133,6 +134,7 @@ __exportStar(require("./SteerEvent"), exports);
|
|
|
133
134
|
__exportStar(require("./SteerEventData"), exports);
|
|
134
135
|
__exportStar(require("./SteerRequest"), exports);
|
|
135
136
|
__exportStar(require("./SteerResponse"), exports);
|
|
137
|
+
__exportStar(require("./StopOperation"), exports);
|
|
136
138
|
__exportStar(require("./StopRequest"), exports);
|
|
137
139
|
__exportStar(require("./SuccessBase"), exports);
|
|
138
140
|
__exportStar(require("./UnknownEvent"), exports);
|
package/docs/BoatApi.md
CHANGED
|
@@ -3983,7 +3983,8 @@ example().catch(console.error);
|
|
|
3983
3983
|
| **400** | Invalid request body or parameters. | - |
|
|
3984
3984
|
| **401** | Missing or invalid bearer token. | - |
|
|
3985
3985
|
| **404** | Resource not found. | - |
|
|
3986
|
-
| **
|
|
3986
|
+
| **402** | `credit_required`: the wallet already keeps 10 or more named snapshots and has no credit left. Each named snapshot above the free 10 costs $1.70 a month, charged daily. Add credit or remove one. | - |
|
|
3987
|
+
| **409** | `save_in_progress` when a save under this name is already running; wait for it to settle rather than retrying immediately. | - |
|
|
3987
3988
|
|
|
3988
3989
|
[[Back to top]](#) [[Back to API list]](../README.md#api-endpoints) [[Back to Model list]](../README.md#models) [[Back to README]](../README.md)
|
|
3989
3990
|
|
|
@@ -4599,7 +4600,7 @@ example().catch(console.error);
|
|
|
4599
4600
|
|
|
4600
4601
|
Stop and archive sandbox
|
|
4601
4602
|
|
|
4602
|
-
Stop active work and archive/snapshot the sandbox for later resume or fork. A stop always saves the sandbox\'s disk first. If that save is failing, the stop is refused and the sandbox keeps running so your work is not discarded, we retry automatically and email you. You are not billed for time spent in that state. Set `force: true` to stop anyway, accepting the loss of everything written since the last successful snapshot. This is irreversible; only reach for it after a stop has already failed.
|
|
4603
|
+
Stop active work and archive/snapshot the sandbox for later resume or fork. A stop always saves the sandbox\'s disk first. If that save is failing, the stop is refused and the sandbox keeps running so your work is not discarded, we retry automatically and email you. You are not billed for time spent in that state. The stop is an operation: the response and the sandbox carry it as `stop`, with an `id` and a `status`. Poll `GET /sandboxes/{sandboxId}` until `stop.status` is `completed`. A failed attempt shows `failing` with its `error` and is retried until the sandbox archives; commands and prompts you send meanwhile do not cancel it. Only a resume ends it early (`superseded`). Calling stop again while one is pending returns the same `id`. Set `force: true` to stop anyway, accepting the loss of everything written since the last successful snapshot. This is irreversible; only reach for it after a stop has already failed.
|
|
4603
4604
|
|
|
4604
4605
|
### Example
|
|
4605
4606
|
|
|
@@ -0,0 +1,47 @@
|
|
|
1
|
+
|
|
2
|
+
# NamedSnapshotAllowance
|
|
3
|
+
|
|
4
|
+
What the request\'s wallet (your active organization, `?org=`, or personal) pays for named snapshots. 10 are free per wallet; each one above costs $1.70 a month, charged daily from usage. An organization\'s count includes every member\'s names billed to it.
|
|
5
|
+
|
|
6
|
+
## Properties
|
|
7
|
+
|
|
8
|
+
Name | Type
|
|
9
|
+
------------ | -------------
|
|
10
|
+
`org` | string
|
|
11
|
+
`orgName` | string
|
|
12
|
+
`free` | number
|
|
13
|
+
`used` | number
|
|
14
|
+
`extra` | number
|
|
15
|
+
`extraMonthlyDollars` | number
|
|
16
|
+
`extraDailyDollars` | number
|
|
17
|
+
`pricePerExtraMonthlyDollars` | number
|
|
18
|
+
|
|
19
|
+
## Example
|
|
20
|
+
|
|
21
|
+
```typescript
|
|
22
|
+
import type { NamedSnapshotAllowance } from '@boatdev/sdk'
|
|
23
|
+
|
|
24
|
+
// TODO: Update the object below with actual values
|
|
25
|
+
const example = {
|
|
26
|
+
"org": null,
|
|
27
|
+
"orgName": null,
|
|
28
|
+
"free": null,
|
|
29
|
+
"used": null,
|
|
30
|
+
"extra": null,
|
|
31
|
+
"extraMonthlyDollars": null,
|
|
32
|
+
"extraDailyDollars": null,
|
|
33
|
+
"pricePerExtraMonthlyDollars": null,
|
|
34
|
+
} satisfies NamedSnapshotAllowance
|
|
35
|
+
|
|
36
|
+
console.log(example)
|
|
37
|
+
|
|
38
|
+
// Convert the instance to a JSON string
|
|
39
|
+
const exampleJSON: string = JSON.stringify(example)
|
|
40
|
+
console.log(exampleJSON)
|
|
41
|
+
|
|
42
|
+
// Parse the JSON string back to an object
|
|
43
|
+
const exampleParsed = JSON.parse(exampleJSON) as NamedSnapshotAllowance
|
|
44
|
+
console.log(exampleParsed)
|
|
45
|
+
```
|
|
46
|
+
|
|
47
|
+
[[Back to top]](#) [[Back to API list]](../README.md#api-endpoints) [[Back to Model list]](../README.md#models) [[Back to README]](../README.md)
|