sandbox0 0.9.8 → 0.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.
- package/README.md +0 -15
- package/dist/apispec/src/apis/FilesApi.d.ts +1 -112
- package/dist/apispec/src/apis/FilesApi.d.ts.map +1 -1
- package/dist/apispec/src/apis/FilesApi.js +1 -330
- package/dist/apispec/src/apis/index.d.ts +0 -2
- package/dist/apispec/src/apis/index.d.ts.map +1 -1
- package/dist/apispec/src/apis/index.js +0 -2
- package/dist/apispec/src/models/ClaimRequest.d.ts +0 -7
- package/dist/apispec/src/models/ClaimRequest.d.ts.map +1 -1
- package/dist/apispec/src/models/ClaimRequest.js +0 -3
- package/dist/apispec/src/models/ClaimResponse.d.ts +0 -7
- package/dist/apispec/src/models/ClaimResponse.d.ts.map +1 -1
- package/dist/apispec/src/models/ClaimResponse.js +0 -3
- package/dist/apispec/src/models/QuotaDimension.d.ts +0 -2
- package/dist/apispec/src/models/QuotaDimension.d.ts.map +1 -1
- package/dist/apispec/src/models/QuotaDimension.js +0 -2
- package/dist/apispec/src/models/ResourceQuota.d.ts +1 -1
- package/dist/apispec/src/models/Sandbox.d.ts +0 -7
- package/dist/apispec/src/models/Sandbox.d.ts.map +1 -1
- package/dist/apispec/src/models/Sandbox.js +0 -3
- package/dist/apispec/src/models/SandboxResourceConfig.d.ts +1 -1
- package/dist/apispec/src/models/SandboxTemplateSpec.d.ts +0 -7
- package/dist/apispec/src/models/SandboxTemplateSpec.d.ts.map +1 -1
- package/dist/apispec/src/models/SandboxTemplateSpec.js +0 -3
- package/dist/apispec/src/models/WebhookConfig.d.ts +1 -1
- package/dist/apispec/src/models/index.d.ts +0 -20
- package/dist/apispec/src/models/index.d.ts.map +1 -1
- package/dist/apispec/src/models/index.js +0 -20
- package/dist/client.d.ts +0 -4
- package/dist/client.d.ts.map +1 -1
- package/dist/client.js +0 -5
- package/dist/index.d.ts +0 -2
- package/dist/index.d.ts.map +1 -1
- package/dist/resources/sandboxes.d.ts +1 -2
- package/dist/resources/sandboxes.d.ts.map +1 -1
- package/dist/resources/sandboxes.js +0 -3
- package/dist/sandbox.d.ts +0 -3
- package/dist/sandbox.d.ts.map +1 -1
- package/dist/sandbox.js +0 -2
- package/dist/sessions.d.ts +0 -20
- package/dist/sessions.d.ts.map +1 -1
- package/dist/sessions.js +0 -36
- package/package.json +1 -1
- package/dist/apispec/src/apis/SandboxVolumesApi.d.ts +0 -73
- package/dist/apispec/src/apis/SandboxVolumesApi.d.ts.map +0 -1
- package/dist/apispec/src/apis/SandboxVolumesApi.js +0 -187
- package/dist/apispec/src/apis/SnapshotsApi.d.ts +0 -78
- package/dist/apispec/src/apis/SnapshotsApi.d.ts.map +0 -1
- package/dist/apispec/src/apis/SnapshotsApi.js +0 -202
- package/dist/apispec/src/models/ClaimMountRequest.d.ts +0 -39
- package/dist/apispec/src/models/ClaimMountRequest.d.ts.map +0 -1
- package/dist/apispec/src/models/ClaimMountRequest.js +0 -47
- package/dist/apispec/src/models/CreateSandboxVolumeRequest.d.ts +0 -66
- package/dist/apispec/src/models/CreateSandboxVolumeRequest.d.ts.map +0 -1
- package/dist/apispec/src/models/CreateSandboxVolumeRequest.js +0 -54
- package/dist/apispec/src/models/CreateSandboxVolumeS3Config.d.ts +0 -84
- package/dist/apispec/src/models/CreateSandboxVolumeS3Config.d.ts.map +0 -1
- package/dist/apispec/src/models/CreateSandboxVolumeS3Config.js +0 -69
- package/dist/apispec/src/models/CreateSnapshotRequest.d.ts +0 -39
- package/dist/apispec/src/models/CreateSnapshotRequest.d.ts.map +0 -1
- package/dist/apispec/src/models/CreateSnapshotRequest.js +0 -45
- package/dist/apispec/src/models/ForkVolumeRequest.d.ts +0 -46
- package/dist/apispec/src/models/ForkVolumeRequest.d.ts.map +0 -1
- package/dist/apispec/src/models/ForkVolumeRequest.js +0 -46
- package/dist/apispec/src/models/MountStatus.d.ts +0 -79
- package/dist/apispec/src/models/MountStatus.d.ts.map +0 -1
- package/dist/apispec/src/models/MountStatus.js +0 -68
- package/dist/apispec/src/models/SandboxVolume.d.ts +0 -108
- package/dist/apispec/src/models/SandboxVolume.d.ts.map +0 -1
- package/dist/apispec/src/models/SandboxVolume.js +0 -80
- package/dist/apispec/src/models/SandboxVolumeS3Config.d.ts +0 -66
- package/dist/apispec/src/models/SandboxVolumeS3Config.d.ts.map +0 -1
- package/dist/apispec/src/models/SandboxVolumeS3Config.js +0 -61
- package/dist/apispec/src/models/Snapshot.d.ts +0 -69
- package/dist/apispec/src/models/Snapshot.d.ts.map +0 -1
- package/dist/apispec/src/models/Snapshot.js +0 -63
- package/dist/apispec/src/models/SuccessSandboxVolumeListResponse.d.ts +0 -40
- package/dist/apispec/src/models/SuccessSandboxVolumeListResponse.d.ts.map +0 -1
- package/dist/apispec/src/models/SuccessSandboxVolumeListResponse.js +0 -46
- package/dist/apispec/src/models/SuccessSandboxVolumeResponse.d.ts +0 -40
- package/dist/apispec/src/models/SuccessSandboxVolumeResponse.d.ts.map +0 -1
- package/dist/apispec/src/models/SuccessSandboxVolumeResponse.js +0 -46
- package/dist/apispec/src/models/SuccessSnapshotListResponse.d.ts +0 -40
- package/dist/apispec/src/models/SuccessSnapshotListResponse.d.ts.map +0 -1
- package/dist/apispec/src/models/SuccessSnapshotListResponse.js +0 -46
- package/dist/apispec/src/models/SuccessSnapshotResponse.d.ts +0 -40
- package/dist/apispec/src/models/SuccessSnapshotResponse.d.ts.map +0 -1
- package/dist/apispec/src/models/SuccessSnapshotResponse.js +0 -46
- package/dist/apispec/src/models/SuccessVolumeFileArchiveImportResponse.d.ts +0 -40
- package/dist/apispec/src/models/SuccessVolumeFileArchiveImportResponse.d.ts.map +0 -1
- package/dist/apispec/src/models/SuccessVolumeFileArchiveImportResponse.js +0 -46
- package/dist/apispec/src/models/VolumeAccessMode.d.ts +0 -27
- package/dist/apispec/src/models/VolumeAccessMode.d.ts.map +0 -1
- package/dist/apispec/src/models/VolumeAccessMode.js +0 -44
- package/dist/apispec/src/models/VolumeBackend.d.ts +0 -26
- package/dist/apispec/src/models/VolumeBackend.d.ts.map +0 -1
- package/dist/apispec/src/models/VolumeBackend.js +0 -43
- package/dist/apispec/src/models/VolumeFileArchiveImportResponse.d.ts +0 -51
- package/dist/apispec/src/models/VolumeFileArchiveImportResponse.d.ts.map +0 -1
- package/dist/apispec/src/models/VolumeFileArchiveImportResponse.js +0 -55
- package/dist/apispec/src/models/VolumeMountSpec.d.ts +0 -45
- package/dist/apispec/src/models/VolumeMountSpec.d.ts.map +0 -1
- package/dist/apispec/src/models/VolumeMountSpec.js +0 -49
- package/dist/resources/volumes.d.ts +0 -31
- package/dist/resources/volumes.d.ts.map +0 -1
- package/dist/resources/volumes.js +0 -222
package/README.md
CHANGED
|
@@ -69,21 +69,6 @@ console.log(`exit=${done.exitCode} state=${done.state}`);
|
|
|
69
69
|
## Documentation
|
|
70
70
|
|
|
71
71
|
- [Sandbox0 docs](https://sandbox0.ai/docs)
|
|
72
|
-
- [Volume mounts](https://sandbox0.ai/docs/volume/mounts)
|
|
73
|
-
|
|
74
|
-
## Bootstrap Mounts At Claim Time
|
|
75
|
-
|
|
76
|
-
```typescript
|
|
77
|
-
const volume = await client.volumes.create({});
|
|
78
|
-
|
|
79
|
-
const sandbox = await client.sandboxes.claim("default", {
|
|
80
|
-
mounts: [{ sandboxvolumeId: volume.id, mountPoint: "/workspace/data" }],
|
|
81
|
-
});
|
|
82
|
-
|
|
83
|
-
for (const mount of sandbox.bootstrapMounts) {
|
|
84
|
-
console.log(mount.sandboxvolumeId, mount.state);
|
|
85
|
-
}
|
|
86
|
-
```
|
|
87
72
|
|
|
88
73
|
## Wait For Lifecycle Changes
|
|
89
74
|
|
|
@@ -10,7 +10,7 @@
|
|
|
10
10
|
* Do not edit the class manually.
|
|
11
11
|
*/
|
|
12
12
|
import * as runtime from '../runtime.js';
|
|
13
|
-
import type { MoveFileRequest, SuccessDeletedResponse, SuccessFileListResponse, SuccessFileStatResponse, SuccessMovedResponse,
|
|
13
|
+
import type { MoveFileRequest, SuccessDeletedResponse, SuccessFileListResponse, SuccessFileStatResponse, SuccessMovedResponse, SuccessWrittenResponse } from '../models/index.js';
|
|
14
14
|
export interface ApiV1SandboxesIdFilesDeleteRequest {
|
|
15
15
|
id: string;
|
|
16
16
|
path: string;
|
|
@@ -41,41 +41,6 @@ export interface ApiV1SandboxesIdFilesStatGetRequest {
|
|
|
41
41
|
export interface ApiV1SandboxesIdFilesWatchGetRequest {
|
|
42
42
|
id: string;
|
|
43
43
|
}
|
|
44
|
-
export interface ApiV1SandboxvolumesIdFilesArchivePutRequest {
|
|
45
|
-
id: string;
|
|
46
|
-
path: string;
|
|
47
|
-
body: Blob;
|
|
48
|
-
}
|
|
49
|
-
export interface ApiV1SandboxvolumesIdFilesDeleteRequest {
|
|
50
|
-
id: string;
|
|
51
|
-
path: string;
|
|
52
|
-
}
|
|
53
|
-
export interface ApiV1SandboxvolumesIdFilesGetRequest {
|
|
54
|
-
id: string;
|
|
55
|
-
path: string;
|
|
56
|
-
}
|
|
57
|
-
export interface ApiV1SandboxvolumesIdFilesListGetRequest {
|
|
58
|
-
id: string;
|
|
59
|
-
path: string;
|
|
60
|
-
}
|
|
61
|
-
export interface ApiV1SandboxvolumesIdFilesMovePostRequest {
|
|
62
|
-
id: string;
|
|
63
|
-
moveFileRequest: MoveFileRequest;
|
|
64
|
-
}
|
|
65
|
-
export interface ApiV1SandboxvolumesIdFilesPostRequest {
|
|
66
|
-
id: string;
|
|
67
|
-
path: string;
|
|
68
|
-
mkdir?: boolean;
|
|
69
|
-
recursive?: boolean;
|
|
70
|
-
body?: Blob;
|
|
71
|
-
}
|
|
72
|
-
export interface ApiV1SandboxvolumesIdFilesStatGetRequest {
|
|
73
|
-
id: string;
|
|
74
|
-
path: string;
|
|
75
|
-
}
|
|
76
|
-
export interface ApiV1SandboxvolumesIdFilesWatchGetRequest {
|
|
77
|
-
id: string;
|
|
78
|
-
}
|
|
79
44
|
/**
|
|
80
45
|
*
|
|
81
46
|
*/
|
|
@@ -146,81 +111,5 @@ export declare class FilesApi extends runtime.BaseAPI {
|
|
|
146
111
|
* File watch WebSocket
|
|
147
112
|
*/
|
|
148
113
|
apiV1SandboxesIdFilesWatchGet(requestParameters: ApiV1SandboxesIdFilesWatchGetRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<void>;
|
|
149
|
-
/**
|
|
150
|
-
* Streams a tar archive into a volume path. The archive is extracted under the `path` query parameter. Regular files overwrite existing files. Directories are created as needed. The import is not atomic; deployment flows should import into a fresh volume when rollback is required.
|
|
151
|
-
* Import a tar archive into a volume
|
|
152
|
-
*/
|
|
153
|
-
apiV1SandboxvolumesIdFilesArchivePutRaw(requestParameters: ApiV1SandboxvolumesIdFilesArchivePutRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<SuccessVolumeFileArchiveImportResponse>>;
|
|
154
|
-
/**
|
|
155
|
-
* Streams a tar archive into a volume path. The archive is extracted under the `path` query parameter. Regular files overwrite existing files. Directories are created as needed. The import is not atomic; deployment flows should import into a fresh volume when rollback is required.
|
|
156
|
-
* Import a tar archive into a volume
|
|
157
|
-
*/
|
|
158
|
-
apiV1SandboxvolumesIdFilesArchivePut(requestParameters: ApiV1SandboxvolumesIdFilesArchivePutRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<SuccessVolumeFileArchiveImportResponse>;
|
|
159
|
-
/**
|
|
160
|
-
* Delete volume file or directory
|
|
161
|
-
*/
|
|
162
|
-
apiV1SandboxvolumesIdFilesDeleteRaw(requestParameters: ApiV1SandboxvolumesIdFilesDeleteRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<SuccessDeletedResponse>>;
|
|
163
|
-
/**
|
|
164
|
-
* Delete volume file or directory
|
|
165
|
-
*/
|
|
166
|
-
apiV1SandboxvolumesIdFilesDelete(requestParameters: ApiV1SandboxvolumesIdFilesDeleteRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<SuccessDeletedResponse>;
|
|
167
|
-
/**
|
|
168
|
-
* Use query params: - path=/tmp/a.txt: target file path relative to the volume root When `Accept` or `Content-Type` is `application/json`, returns a base64 JSON payload.
|
|
169
|
-
* Read volume file content
|
|
170
|
-
*/
|
|
171
|
-
apiV1SandboxvolumesIdFilesGetRaw(requestParameters: ApiV1SandboxvolumesIdFilesGetRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<Blob>>;
|
|
172
|
-
/**
|
|
173
|
-
* Use query params: - path=/tmp/a.txt: target file path relative to the volume root When `Accept` or `Content-Type` is `application/json`, returns a base64 JSON payload.
|
|
174
|
-
* Read volume file content
|
|
175
|
-
*/
|
|
176
|
-
apiV1SandboxvolumesIdFilesGet(requestParameters: ApiV1SandboxvolumesIdFilesGetRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<Blob>;
|
|
177
|
-
/**
|
|
178
|
-
* Use query params: - path=/tmp: target directory path relative to the volume root
|
|
179
|
-
* List volume directory entries
|
|
180
|
-
*/
|
|
181
|
-
apiV1SandboxvolumesIdFilesListGetRaw(requestParameters: ApiV1SandboxvolumesIdFilesListGetRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<SuccessFileListResponse>>;
|
|
182
|
-
/**
|
|
183
|
-
* Use query params: - path=/tmp: target directory path relative to the volume root
|
|
184
|
-
* List volume directory entries
|
|
185
|
-
*/
|
|
186
|
-
apiV1SandboxvolumesIdFilesListGet(requestParameters: ApiV1SandboxvolumesIdFilesListGetRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<SuccessFileListResponse>;
|
|
187
|
-
/**
|
|
188
|
-
* Move a volume file or directory
|
|
189
|
-
*/
|
|
190
|
-
apiV1SandboxvolumesIdFilesMovePostRaw(requestParameters: ApiV1SandboxvolumesIdFilesMovePostRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<SuccessMovedResponse>>;
|
|
191
|
-
/**
|
|
192
|
-
* Move a volume file or directory
|
|
193
|
-
*/
|
|
194
|
-
apiV1SandboxvolumesIdFilesMovePost(requestParameters: ApiV1SandboxvolumesIdFilesMovePostRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<SuccessMovedResponse>;
|
|
195
|
-
/**
|
|
196
|
-
* Use `path` query param and `mkdir=true` to create directories, otherwise writes file content.
|
|
197
|
-
* Write volume file or create directory
|
|
198
|
-
*/
|
|
199
|
-
apiV1SandboxvolumesIdFilesPostRaw(requestParameters: ApiV1SandboxvolumesIdFilesPostRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<SuccessWrittenResponse>>;
|
|
200
|
-
/**
|
|
201
|
-
* Use `path` query param and `mkdir=true` to create directories, otherwise writes file content.
|
|
202
|
-
* Write volume file or create directory
|
|
203
|
-
*/
|
|
204
|
-
apiV1SandboxvolumesIdFilesPost(requestParameters: ApiV1SandboxvolumesIdFilesPostRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<SuccessWrittenResponse>;
|
|
205
|
-
/**
|
|
206
|
-
* Use query params: - path=/tmp/a.txt: target file path relative to the volume root
|
|
207
|
-
* Stat a volume file
|
|
208
|
-
*/
|
|
209
|
-
apiV1SandboxvolumesIdFilesStatGetRaw(requestParameters: ApiV1SandboxvolumesIdFilesStatGetRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<SuccessFileStatResponse>>;
|
|
210
|
-
/**
|
|
211
|
-
* Use query params: - path=/tmp/a.txt: target file path relative to the volume root
|
|
212
|
-
* Stat a volume file
|
|
213
|
-
*/
|
|
214
|
-
apiV1SandboxvolumesIdFilesStatGet(requestParameters: ApiV1SandboxvolumesIdFilesStatGetRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<SuccessFileStatResponse>;
|
|
215
|
-
/**
|
|
216
|
-
* Upgrades to WebSocket for volume file watch events. Client messages: - { \"action\": \"subscribe\", \"path\": \"/tmp\", \"recursive\": false } - { \"action\": \"unsubscribe\", \"watch_id\": \"watch-id\" } Server messages: - { \"type\": \"subscribed\", \"watch_id\": \"watch-id\", \"path\": \"/tmp\" } - { \"type\": \"event\", \"watch_id\": \"watch-id\", \"event\": \"write\", \"path\": \"/tmp/a.txt\" } - { \"type\": \"unsubscribed\", \"watch_id\": \"watch-id\" } - { \"type\": \"error\", \"error\": \"message\" }
|
|
217
|
-
* Volume file watch WebSocket
|
|
218
|
-
*/
|
|
219
|
-
apiV1SandboxvolumesIdFilesWatchGetRaw(requestParameters: ApiV1SandboxvolumesIdFilesWatchGetRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<void>>;
|
|
220
|
-
/**
|
|
221
|
-
* Upgrades to WebSocket for volume file watch events. Client messages: - { \"action\": \"subscribe\", \"path\": \"/tmp\", \"recursive\": false } - { \"action\": \"unsubscribe\", \"watch_id\": \"watch-id\" } Server messages: - { \"type\": \"subscribed\", \"watch_id\": \"watch-id\", \"path\": \"/tmp\" } - { \"type\": \"event\", \"watch_id\": \"watch-id\", \"event\": \"write\", \"path\": \"/tmp/a.txt\" } - { \"type\": \"unsubscribed\", \"watch_id\": \"watch-id\" } - { \"type\": \"error\", \"error\": \"message\" }
|
|
222
|
-
* Volume file watch WebSocket
|
|
223
|
-
*/
|
|
224
|
-
apiV1SandboxvolumesIdFilesWatchGet(requestParameters: ApiV1SandboxvolumesIdFilesWatchGetRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<void>;
|
|
225
114
|
}
|
|
226
115
|
//# sourceMappingURL=FilesApi.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"FilesApi.d.ts","sourceRoot":"","sources":["../../../../src/apispec/src/apis/FilesApi.ts"],"names":[],"mappings":"AAEA;;;;;;;;;;GAUG;AAGH,OAAO,KAAK,OAAO,MAAM,YAAY,CAAC;AACtC,OAAO,KAAK,EAEV,eAAe,EAEf,sBAAsB,EACtB,uBAAuB,EACvB,uBAAuB,EACvB,oBAAoB,EACpB,
|
|
1
|
+
{"version":3,"file":"FilesApi.d.ts","sourceRoot":"","sources":["../../../../src/apispec/src/apis/FilesApi.ts"],"names":[],"mappings":"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"}
|
|
@@ -12,7 +12,7 @@
|
|
|
12
12
|
* Do not edit the class manually.
|
|
13
13
|
*/
|
|
14
14
|
import * as runtime from '../runtime.js';
|
|
15
|
-
import { MoveFileRequestToJSON, SuccessDeletedResponseFromJSON, SuccessFileListResponseFromJSON, SuccessFileStatResponseFromJSON, SuccessMovedResponseFromJSON,
|
|
15
|
+
import { MoveFileRequestToJSON, SuccessDeletedResponseFromJSON, SuccessFileListResponseFromJSON, SuccessFileStatResponseFromJSON, SuccessMovedResponseFromJSON, SuccessWrittenResponseFromJSON, } from '../models/index.js';
|
|
16
16
|
/**
|
|
17
17
|
*
|
|
18
18
|
*/
|
|
@@ -300,333 +300,4 @@ export class FilesApi extends runtime.BaseAPI {
|
|
|
300
300
|
async apiV1SandboxesIdFilesWatchGet(requestParameters, initOverrides) {
|
|
301
301
|
await this.apiV1SandboxesIdFilesWatchGetRaw(requestParameters, initOverrides);
|
|
302
302
|
}
|
|
303
|
-
/**
|
|
304
|
-
* Streams a tar archive into a volume path. The archive is extracted under the `path` query parameter. Regular files overwrite existing files. Directories are created as needed. The import is not atomic; deployment flows should import into a fresh volume when rollback is required.
|
|
305
|
-
* Import a tar archive into a volume
|
|
306
|
-
*/
|
|
307
|
-
async apiV1SandboxvolumesIdFilesArchivePutRaw(requestParameters, initOverrides) {
|
|
308
|
-
if (requestParameters['id'] == null) {
|
|
309
|
-
throw new runtime.RequiredError('id', 'Required parameter "id" was null or undefined when calling apiV1SandboxvolumesIdFilesArchivePut().');
|
|
310
|
-
}
|
|
311
|
-
if (requestParameters['path'] == null) {
|
|
312
|
-
throw new runtime.RequiredError('path', 'Required parameter "path" was null or undefined when calling apiV1SandboxvolumesIdFilesArchivePut().');
|
|
313
|
-
}
|
|
314
|
-
if (requestParameters['body'] == null) {
|
|
315
|
-
throw new runtime.RequiredError('body', 'Required parameter "body" was null or undefined when calling apiV1SandboxvolumesIdFilesArchivePut().');
|
|
316
|
-
}
|
|
317
|
-
const queryParameters = {};
|
|
318
|
-
if (requestParameters['path'] != null) {
|
|
319
|
-
queryParameters['path'] = requestParameters['path'];
|
|
320
|
-
}
|
|
321
|
-
const headerParameters = {};
|
|
322
|
-
headerParameters['Content-Type'] = 'application/x-tar';
|
|
323
|
-
if (this.configuration && this.configuration.accessToken) {
|
|
324
|
-
const token = this.configuration.accessToken;
|
|
325
|
-
const tokenString = await token("bearerAuth", []);
|
|
326
|
-
if (tokenString) {
|
|
327
|
-
headerParameters["Authorization"] = `Bearer ${tokenString}`;
|
|
328
|
-
}
|
|
329
|
-
}
|
|
330
|
-
let urlPath = `/api/v1/sandboxvolumes/{id}/files/archive`;
|
|
331
|
-
urlPath = urlPath.replace(`{${"id"}}`, encodeURIComponent(String(requestParameters['id'])));
|
|
332
|
-
const response = await this.request({
|
|
333
|
-
path: urlPath,
|
|
334
|
-
method: 'PUT',
|
|
335
|
-
headers: headerParameters,
|
|
336
|
-
query: queryParameters,
|
|
337
|
-
body: requestParameters['body'],
|
|
338
|
-
}, initOverrides);
|
|
339
|
-
return new runtime.JSONApiResponse(response, (jsonValue) => SuccessVolumeFileArchiveImportResponseFromJSON(jsonValue));
|
|
340
|
-
}
|
|
341
|
-
/**
|
|
342
|
-
* Streams a tar archive into a volume path. The archive is extracted under the `path` query parameter. Regular files overwrite existing files. Directories are created as needed. The import is not atomic; deployment flows should import into a fresh volume when rollback is required.
|
|
343
|
-
* Import a tar archive into a volume
|
|
344
|
-
*/
|
|
345
|
-
async apiV1SandboxvolumesIdFilesArchivePut(requestParameters, initOverrides) {
|
|
346
|
-
const response = await this.apiV1SandboxvolumesIdFilesArchivePutRaw(requestParameters, initOverrides);
|
|
347
|
-
return await response.value();
|
|
348
|
-
}
|
|
349
|
-
/**
|
|
350
|
-
* Delete volume file or directory
|
|
351
|
-
*/
|
|
352
|
-
async apiV1SandboxvolumesIdFilesDeleteRaw(requestParameters, initOverrides) {
|
|
353
|
-
if (requestParameters['id'] == null) {
|
|
354
|
-
throw new runtime.RequiredError('id', 'Required parameter "id" was null or undefined when calling apiV1SandboxvolumesIdFilesDelete().');
|
|
355
|
-
}
|
|
356
|
-
if (requestParameters['path'] == null) {
|
|
357
|
-
throw new runtime.RequiredError('path', 'Required parameter "path" was null or undefined when calling apiV1SandboxvolumesIdFilesDelete().');
|
|
358
|
-
}
|
|
359
|
-
const queryParameters = {};
|
|
360
|
-
if (requestParameters['path'] != null) {
|
|
361
|
-
queryParameters['path'] = requestParameters['path'];
|
|
362
|
-
}
|
|
363
|
-
const headerParameters = {};
|
|
364
|
-
if (this.configuration && this.configuration.accessToken) {
|
|
365
|
-
const token = this.configuration.accessToken;
|
|
366
|
-
const tokenString = await token("bearerAuth", []);
|
|
367
|
-
if (tokenString) {
|
|
368
|
-
headerParameters["Authorization"] = `Bearer ${tokenString}`;
|
|
369
|
-
}
|
|
370
|
-
}
|
|
371
|
-
let urlPath = `/api/v1/sandboxvolumes/{id}/files`;
|
|
372
|
-
urlPath = urlPath.replace(`{${"id"}}`, encodeURIComponent(String(requestParameters['id'])));
|
|
373
|
-
const response = await this.request({
|
|
374
|
-
path: urlPath,
|
|
375
|
-
method: 'DELETE',
|
|
376
|
-
headers: headerParameters,
|
|
377
|
-
query: queryParameters,
|
|
378
|
-
}, initOverrides);
|
|
379
|
-
return new runtime.JSONApiResponse(response, (jsonValue) => SuccessDeletedResponseFromJSON(jsonValue));
|
|
380
|
-
}
|
|
381
|
-
/**
|
|
382
|
-
* Delete volume file or directory
|
|
383
|
-
*/
|
|
384
|
-
async apiV1SandboxvolumesIdFilesDelete(requestParameters, initOverrides) {
|
|
385
|
-
const response = await this.apiV1SandboxvolumesIdFilesDeleteRaw(requestParameters, initOverrides);
|
|
386
|
-
return await response.value();
|
|
387
|
-
}
|
|
388
|
-
/**
|
|
389
|
-
* Use query params: - path=/tmp/a.txt: target file path relative to the volume root When `Accept` or `Content-Type` is `application/json`, returns a base64 JSON payload.
|
|
390
|
-
* Read volume file content
|
|
391
|
-
*/
|
|
392
|
-
async apiV1SandboxvolumesIdFilesGetRaw(requestParameters, initOverrides) {
|
|
393
|
-
if (requestParameters['id'] == null) {
|
|
394
|
-
throw new runtime.RequiredError('id', 'Required parameter "id" was null or undefined when calling apiV1SandboxvolumesIdFilesGet().');
|
|
395
|
-
}
|
|
396
|
-
if (requestParameters['path'] == null) {
|
|
397
|
-
throw new runtime.RequiredError('path', 'Required parameter "path" was null or undefined when calling apiV1SandboxvolumesIdFilesGet().');
|
|
398
|
-
}
|
|
399
|
-
const queryParameters = {};
|
|
400
|
-
if (requestParameters['path'] != null) {
|
|
401
|
-
queryParameters['path'] = requestParameters['path'];
|
|
402
|
-
}
|
|
403
|
-
const headerParameters = {};
|
|
404
|
-
if (this.configuration && this.configuration.accessToken) {
|
|
405
|
-
const token = this.configuration.accessToken;
|
|
406
|
-
const tokenString = await token("bearerAuth", []);
|
|
407
|
-
if (tokenString) {
|
|
408
|
-
headerParameters["Authorization"] = `Bearer ${tokenString}`;
|
|
409
|
-
}
|
|
410
|
-
}
|
|
411
|
-
let urlPath = `/api/v1/sandboxvolumes/{id}/files`;
|
|
412
|
-
urlPath = urlPath.replace(`{${"id"}}`, encodeURIComponent(String(requestParameters['id'])));
|
|
413
|
-
const response = await this.request({
|
|
414
|
-
path: urlPath,
|
|
415
|
-
method: 'GET',
|
|
416
|
-
headers: headerParameters,
|
|
417
|
-
query: queryParameters,
|
|
418
|
-
}, initOverrides);
|
|
419
|
-
return new runtime.BlobApiResponse(response);
|
|
420
|
-
}
|
|
421
|
-
/**
|
|
422
|
-
* Use query params: - path=/tmp/a.txt: target file path relative to the volume root When `Accept` or `Content-Type` is `application/json`, returns a base64 JSON payload.
|
|
423
|
-
* Read volume file content
|
|
424
|
-
*/
|
|
425
|
-
async apiV1SandboxvolumesIdFilesGet(requestParameters, initOverrides) {
|
|
426
|
-
const response = await this.apiV1SandboxvolumesIdFilesGetRaw(requestParameters, initOverrides);
|
|
427
|
-
return await response.value();
|
|
428
|
-
}
|
|
429
|
-
/**
|
|
430
|
-
* Use query params: - path=/tmp: target directory path relative to the volume root
|
|
431
|
-
* List volume directory entries
|
|
432
|
-
*/
|
|
433
|
-
async apiV1SandboxvolumesIdFilesListGetRaw(requestParameters, initOverrides) {
|
|
434
|
-
if (requestParameters['id'] == null) {
|
|
435
|
-
throw new runtime.RequiredError('id', 'Required parameter "id" was null or undefined when calling apiV1SandboxvolumesIdFilesListGet().');
|
|
436
|
-
}
|
|
437
|
-
if (requestParameters['path'] == null) {
|
|
438
|
-
throw new runtime.RequiredError('path', 'Required parameter "path" was null or undefined when calling apiV1SandboxvolumesIdFilesListGet().');
|
|
439
|
-
}
|
|
440
|
-
const queryParameters = {};
|
|
441
|
-
if (requestParameters['path'] != null) {
|
|
442
|
-
queryParameters['path'] = requestParameters['path'];
|
|
443
|
-
}
|
|
444
|
-
const headerParameters = {};
|
|
445
|
-
if (this.configuration && this.configuration.accessToken) {
|
|
446
|
-
const token = this.configuration.accessToken;
|
|
447
|
-
const tokenString = await token("bearerAuth", []);
|
|
448
|
-
if (tokenString) {
|
|
449
|
-
headerParameters["Authorization"] = `Bearer ${tokenString}`;
|
|
450
|
-
}
|
|
451
|
-
}
|
|
452
|
-
let urlPath = `/api/v1/sandboxvolumes/{id}/files/list`;
|
|
453
|
-
urlPath = urlPath.replace(`{${"id"}}`, encodeURIComponent(String(requestParameters['id'])));
|
|
454
|
-
const response = await this.request({
|
|
455
|
-
path: urlPath,
|
|
456
|
-
method: 'GET',
|
|
457
|
-
headers: headerParameters,
|
|
458
|
-
query: queryParameters,
|
|
459
|
-
}, initOverrides);
|
|
460
|
-
return new runtime.JSONApiResponse(response, (jsonValue) => SuccessFileListResponseFromJSON(jsonValue));
|
|
461
|
-
}
|
|
462
|
-
/**
|
|
463
|
-
* Use query params: - path=/tmp: target directory path relative to the volume root
|
|
464
|
-
* List volume directory entries
|
|
465
|
-
*/
|
|
466
|
-
async apiV1SandboxvolumesIdFilesListGet(requestParameters, initOverrides) {
|
|
467
|
-
const response = await this.apiV1SandboxvolumesIdFilesListGetRaw(requestParameters, initOverrides);
|
|
468
|
-
return await response.value();
|
|
469
|
-
}
|
|
470
|
-
/**
|
|
471
|
-
* Move a volume file or directory
|
|
472
|
-
*/
|
|
473
|
-
async apiV1SandboxvolumesIdFilesMovePostRaw(requestParameters, initOverrides) {
|
|
474
|
-
if (requestParameters['id'] == null) {
|
|
475
|
-
throw new runtime.RequiredError('id', 'Required parameter "id" was null or undefined when calling apiV1SandboxvolumesIdFilesMovePost().');
|
|
476
|
-
}
|
|
477
|
-
if (requestParameters['moveFileRequest'] == null) {
|
|
478
|
-
throw new runtime.RequiredError('moveFileRequest', 'Required parameter "moveFileRequest" was null or undefined when calling apiV1SandboxvolumesIdFilesMovePost().');
|
|
479
|
-
}
|
|
480
|
-
const queryParameters = {};
|
|
481
|
-
const headerParameters = {};
|
|
482
|
-
headerParameters['Content-Type'] = 'application/json';
|
|
483
|
-
if (this.configuration && this.configuration.accessToken) {
|
|
484
|
-
const token = this.configuration.accessToken;
|
|
485
|
-
const tokenString = await token("bearerAuth", []);
|
|
486
|
-
if (tokenString) {
|
|
487
|
-
headerParameters["Authorization"] = `Bearer ${tokenString}`;
|
|
488
|
-
}
|
|
489
|
-
}
|
|
490
|
-
let urlPath = `/api/v1/sandboxvolumes/{id}/files/move`;
|
|
491
|
-
urlPath = urlPath.replace(`{${"id"}}`, encodeURIComponent(String(requestParameters['id'])));
|
|
492
|
-
const response = await this.request({
|
|
493
|
-
path: urlPath,
|
|
494
|
-
method: 'POST',
|
|
495
|
-
headers: headerParameters,
|
|
496
|
-
query: queryParameters,
|
|
497
|
-
body: MoveFileRequestToJSON(requestParameters['moveFileRequest']),
|
|
498
|
-
}, initOverrides);
|
|
499
|
-
return new runtime.JSONApiResponse(response, (jsonValue) => SuccessMovedResponseFromJSON(jsonValue));
|
|
500
|
-
}
|
|
501
|
-
/**
|
|
502
|
-
* Move a volume file or directory
|
|
503
|
-
*/
|
|
504
|
-
async apiV1SandboxvolumesIdFilesMovePost(requestParameters, initOverrides) {
|
|
505
|
-
const response = await this.apiV1SandboxvolumesIdFilesMovePostRaw(requestParameters, initOverrides);
|
|
506
|
-
return await response.value();
|
|
507
|
-
}
|
|
508
|
-
/**
|
|
509
|
-
* Use `path` query param and `mkdir=true` to create directories, otherwise writes file content.
|
|
510
|
-
* Write volume file or create directory
|
|
511
|
-
*/
|
|
512
|
-
async apiV1SandboxvolumesIdFilesPostRaw(requestParameters, initOverrides) {
|
|
513
|
-
if (requestParameters['id'] == null) {
|
|
514
|
-
throw new runtime.RequiredError('id', 'Required parameter "id" was null or undefined when calling apiV1SandboxvolumesIdFilesPost().');
|
|
515
|
-
}
|
|
516
|
-
if (requestParameters['path'] == null) {
|
|
517
|
-
throw new runtime.RequiredError('path', 'Required parameter "path" was null or undefined when calling apiV1SandboxvolumesIdFilesPost().');
|
|
518
|
-
}
|
|
519
|
-
const queryParameters = {};
|
|
520
|
-
if (requestParameters['path'] != null) {
|
|
521
|
-
queryParameters['path'] = requestParameters['path'];
|
|
522
|
-
}
|
|
523
|
-
if (requestParameters['mkdir'] != null) {
|
|
524
|
-
queryParameters['mkdir'] = requestParameters['mkdir'];
|
|
525
|
-
}
|
|
526
|
-
if (requestParameters['recursive'] != null) {
|
|
527
|
-
queryParameters['recursive'] = requestParameters['recursive'];
|
|
528
|
-
}
|
|
529
|
-
const headerParameters = {};
|
|
530
|
-
headerParameters['Content-Type'] = 'application/octet-stream';
|
|
531
|
-
if (this.configuration && this.configuration.accessToken) {
|
|
532
|
-
const token = this.configuration.accessToken;
|
|
533
|
-
const tokenString = await token("bearerAuth", []);
|
|
534
|
-
if (tokenString) {
|
|
535
|
-
headerParameters["Authorization"] = `Bearer ${tokenString}`;
|
|
536
|
-
}
|
|
537
|
-
}
|
|
538
|
-
let urlPath = `/api/v1/sandboxvolumes/{id}/files`;
|
|
539
|
-
urlPath = urlPath.replace(`{${"id"}}`, encodeURIComponent(String(requestParameters['id'])));
|
|
540
|
-
const response = await this.request({
|
|
541
|
-
path: urlPath,
|
|
542
|
-
method: 'POST',
|
|
543
|
-
headers: headerParameters,
|
|
544
|
-
query: queryParameters,
|
|
545
|
-
body: requestParameters['body'],
|
|
546
|
-
}, initOverrides);
|
|
547
|
-
return new runtime.JSONApiResponse(response, (jsonValue) => SuccessWrittenResponseFromJSON(jsonValue));
|
|
548
|
-
}
|
|
549
|
-
/**
|
|
550
|
-
* Use `path` query param and `mkdir=true` to create directories, otherwise writes file content.
|
|
551
|
-
* Write volume file or create directory
|
|
552
|
-
*/
|
|
553
|
-
async apiV1SandboxvolumesIdFilesPost(requestParameters, initOverrides) {
|
|
554
|
-
const response = await this.apiV1SandboxvolumesIdFilesPostRaw(requestParameters, initOverrides);
|
|
555
|
-
return await response.value();
|
|
556
|
-
}
|
|
557
|
-
/**
|
|
558
|
-
* Use query params: - path=/tmp/a.txt: target file path relative to the volume root
|
|
559
|
-
* Stat a volume file
|
|
560
|
-
*/
|
|
561
|
-
async apiV1SandboxvolumesIdFilesStatGetRaw(requestParameters, initOverrides) {
|
|
562
|
-
if (requestParameters['id'] == null) {
|
|
563
|
-
throw new runtime.RequiredError('id', 'Required parameter "id" was null or undefined when calling apiV1SandboxvolumesIdFilesStatGet().');
|
|
564
|
-
}
|
|
565
|
-
if (requestParameters['path'] == null) {
|
|
566
|
-
throw new runtime.RequiredError('path', 'Required parameter "path" was null or undefined when calling apiV1SandboxvolumesIdFilesStatGet().');
|
|
567
|
-
}
|
|
568
|
-
const queryParameters = {};
|
|
569
|
-
if (requestParameters['path'] != null) {
|
|
570
|
-
queryParameters['path'] = requestParameters['path'];
|
|
571
|
-
}
|
|
572
|
-
const headerParameters = {};
|
|
573
|
-
if (this.configuration && this.configuration.accessToken) {
|
|
574
|
-
const token = this.configuration.accessToken;
|
|
575
|
-
const tokenString = await token("bearerAuth", []);
|
|
576
|
-
if (tokenString) {
|
|
577
|
-
headerParameters["Authorization"] = `Bearer ${tokenString}`;
|
|
578
|
-
}
|
|
579
|
-
}
|
|
580
|
-
let urlPath = `/api/v1/sandboxvolumes/{id}/files/stat`;
|
|
581
|
-
urlPath = urlPath.replace(`{${"id"}}`, encodeURIComponent(String(requestParameters['id'])));
|
|
582
|
-
const response = await this.request({
|
|
583
|
-
path: urlPath,
|
|
584
|
-
method: 'GET',
|
|
585
|
-
headers: headerParameters,
|
|
586
|
-
query: queryParameters,
|
|
587
|
-
}, initOverrides);
|
|
588
|
-
return new runtime.JSONApiResponse(response, (jsonValue) => SuccessFileStatResponseFromJSON(jsonValue));
|
|
589
|
-
}
|
|
590
|
-
/**
|
|
591
|
-
* Use query params: - path=/tmp/a.txt: target file path relative to the volume root
|
|
592
|
-
* Stat a volume file
|
|
593
|
-
*/
|
|
594
|
-
async apiV1SandboxvolumesIdFilesStatGet(requestParameters, initOverrides) {
|
|
595
|
-
const response = await this.apiV1SandboxvolumesIdFilesStatGetRaw(requestParameters, initOverrides);
|
|
596
|
-
return await response.value();
|
|
597
|
-
}
|
|
598
|
-
/**
|
|
599
|
-
* Upgrades to WebSocket for volume file watch events. Client messages: - { \"action\": \"subscribe\", \"path\": \"/tmp\", \"recursive\": false } - { \"action\": \"unsubscribe\", \"watch_id\": \"watch-id\" } Server messages: - { \"type\": \"subscribed\", \"watch_id\": \"watch-id\", \"path\": \"/tmp\" } - { \"type\": \"event\", \"watch_id\": \"watch-id\", \"event\": \"write\", \"path\": \"/tmp/a.txt\" } - { \"type\": \"unsubscribed\", \"watch_id\": \"watch-id\" } - { \"type\": \"error\", \"error\": \"message\" }
|
|
600
|
-
* Volume file watch WebSocket
|
|
601
|
-
*/
|
|
602
|
-
async apiV1SandboxvolumesIdFilesWatchGetRaw(requestParameters, initOverrides) {
|
|
603
|
-
if (requestParameters['id'] == null) {
|
|
604
|
-
throw new runtime.RequiredError('id', 'Required parameter "id" was null or undefined when calling apiV1SandboxvolumesIdFilesWatchGet().');
|
|
605
|
-
}
|
|
606
|
-
const queryParameters = {};
|
|
607
|
-
const headerParameters = {};
|
|
608
|
-
if (this.configuration && this.configuration.accessToken) {
|
|
609
|
-
const token = this.configuration.accessToken;
|
|
610
|
-
const tokenString = await token("bearerAuth", []);
|
|
611
|
-
if (tokenString) {
|
|
612
|
-
headerParameters["Authorization"] = `Bearer ${tokenString}`;
|
|
613
|
-
}
|
|
614
|
-
}
|
|
615
|
-
let urlPath = `/api/v1/sandboxvolumes/{id}/files/watch`;
|
|
616
|
-
urlPath = urlPath.replace(`{${"id"}}`, encodeURIComponent(String(requestParameters['id'])));
|
|
617
|
-
const response = await this.request({
|
|
618
|
-
path: urlPath,
|
|
619
|
-
method: 'GET',
|
|
620
|
-
headers: headerParameters,
|
|
621
|
-
query: queryParameters,
|
|
622
|
-
}, initOverrides);
|
|
623
|
-
return new runtime.VoidApiResponse(response);
|
|
624
|
-
}
|
|
625
|
-
/**
|
|
626
|
-
* Upgrades to WebSocket for volume file watch events. Client messages: - { \"action\": \"subscribe\", \"path\": \"/tmp\", \"recursive\": false } - { \"action\": \"unsubscribe\", \"watch_id\": \"watch-id\" } Server messages: - { \"type\": \"subscribed\", \"watch_id\": \"watch-id\", \"path\": \"/tmp\" } - { \"type\": \"event\", \"watch_id\": \"watch-id\", \"event\": \"write\", \"path\": \"/tmp/a.txt\" } - { \"type\": \"unsubscribed\", \"watch_id\": \"watch-id\" } - { \"type\": \"error\", \"error\": \"message\" }
|
|
627
|
-
* Volume file watch WebSocket
|
|
628
|
-
*/
|
|
629
|
-
async apiV1SandboxvolumesIdFilesWatchGet(requestParameters, initOverrides) {
|
|
630
|
-
await this.apiV1SandboxvolumesIdFilesWatchGetRaw(requestParameters, initOverrides);
|
|
631
|
-
}
|
|
632
303
|
}
|
|
@@ -9,10 +9,8 @@ export * from './QuotasApi.js';
|
|
|
9
9
|
export * from './RegionsApi.js';
|
|
10
10
|
export * from './RegistryApi.js';
|
|
11
11
|
export * from './SandboxRootfsApi.js';
|
|
12
|
-
export * from './SandboxVolumesApi.js';
|
|
13
12
|
export * from './SandboxesApi.js';
|
|
14
13
|
export * from './SessionsApi.js';
|
|
15
|
-
export * from './SnapshotsApi.js';
|
|
16
14
|
export * from './TeamsApi.js';
|
|
17
15
|
export * from './TemplatesApi.js';
|
|
18
16
|
export * from './UsageApi.js';
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/apispec/src/apis/index.ts"],"names":[],"mappings":"AAEA,cAAc,cAAc,CAAC;AAC7B,cAAc,WAAW,CAAC;AAC1B,cAAc,eAAe,CAAC;AAC9B,cAAc,wBAAwB,CAAC;AACvC,cAAc,YAAY,CAAC;AAC3B,cAAc,aAAa,CAAC;AAC5B,cAAc,oBAAoB,CAAC;AACnC,cAAc,aAAa,CAAC;AAC5B,cAAc,cAAc,CAAC;AAC7B,cAAc,eAAe,CAAC;AAC9B,cAAc,oBAAoB,CAAC;AACnC,cAAc,
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/apispec/src/apis/index.ts"],"names":[],"mappings":"AAEA,cAAc,cAAc,CAAC;AAC7B,cAAc,WAAW,CAAC;AAC1B,cAAc,eAAe,CAAC;AAC9B,cAAc,wBAAwB,CAAC;AACvC,cAAc,YAAY,CAAC;AAC3B,cAAc,aAAa,CAAC;AAC5B,cAAc,oBAAoB,CAAC;AACnC,cAAc,aAAa,CAAC;AAC5B,cAAc,cAAc,CAAC;AAC7B,cAAc,eAAe,CAAC;AAC9B,cAAc,oBAAoB,CAAC;AACnC,cAAc,gBAAgB,CAAC;AAC/B,cAAc,eAAe,CAAC;AAC9B,cAAc,YAAY,CAAC;AAC3B,cAAc,gBAAgB,CAAC;AAC/B,cAAc,YAAY,CAAC;AAC3B,cAAc,YAAY,CAAC"}
|
|
@@ -11,10 +11,8 @@ export * from './QuotasApi.js';
|
|
|
11
11
|
export * from './RegionsApi.js';
|
|
12
12
|
export * from './RegistryApi.js';
|
|
13
13
|
export * from './SandboxRootfsApi.js';
|
|
14
|
-
export * from './SandboxVolumesApi.js';
|
|
15
14
|
export * from './SandboxesApi.js';
|
|
16
15
|
export * from './SessionsApi.js';
|
|
17
|
-
export * from './SnapshotsApi.js';
|
|
18
16
|
export * from './TeamsApi.js';
|
|
19
17
|
export * from './TemplatesApi.js';
|
|
20
18
|
export * from './UsageApi.js';
|
|
@@ -9,7 +9,6 @@
|
|
|
9
9
|
* https://openapi-generator.tech
|
|
10
10
|
* Do not edit the class manually.
|
|
11
11
|
*/
|
|
12
|
-
import type { ClaimMountRequest } from './ClaimMountRequest.js';
|
|
13
12
|
import type { SandboxConfig } from './SandboxConfig.js';
|
|
14
13
|
/**
|
|
15
14
|
*
|
|
@@ -35,12 +34,6 @@ export interface ClaimRequest {
|
|
|
35
34
|
* @memberof ClaimRequest
|
|
36
35
|
*/
|
|
37
36
|
config?: SandboxConfig;
|
|
38
|
-
/**
|
|
39
|
-
* Optional claim-time Sandbox Volume bindings. A claim may bind any subset of template-declared mount points; omitted declared mount points remain writable rootfs-backed directories and are included in rootfs checkpoints.
|
|
40
|
-
* @type {Array<ClaimMountRequest>}
|
|
41
|
-
* @memberof ClaimRequest
|
|
42
|
-
*/
|
|
43
|
-
mounts?: Array<ClaimMountRequest>;
|
|
44
37
|
}
|
|
45
38
|
/**
|
|
46
39
|
* Check if a given object implements the ClaimRequest interface.
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ClaimRequest.d.ts","sourceRoot":"","sources":["../../../../src/apispec/src/models/ClaimRequest.ts"],"names":[],"mappings":"AAEA;;;;;;;;;;GAUG;AAGH,OAAO,KAAK,EAAE,
|
|
1
|
+
{"version":3,"file":"ClaimRequest.d.ts","sourceRoot":"","sources":["../../../../src/apispec/src/models/ClaimRequest.ts"],"names":[],"mappings":"AAEA;;;;;;;;;;GAUG;AAGH,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,iBAAiB,CAAC;AAQrD;;;;GAIG;AACH,MAAM,WAAW,YAAY;IACzB;;;;OAIG;IACH,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB;;;;OAIG;IACH,UAAU,CAAC,EAAE,MAAM,CAAC;IACpB;;;;OAIG;IACH,MAAM,CAAC,EAAE,aAAa,CAAC;CAC1B;AAED;;GAEG;AACH,wBAAgB,sBAAsB,CAAC,KAAK,EAAE,MAAM,GAAG,KAAK,IAAI,YAAY,CAE3E;AAED,wBAAgB,oBAAoB,CAAC,IAAI,EAAE,GAAG,GAAG,YAAY,CAE5D;AAED,wBAAgB,yBAAyB,CAAC,IAAI,EAAE,GAAG,EAAE,mBAAmB,EAAE,OAAO,GAAG,YAAY,CAU/F;AAED,wBAAgB,kBAAkB,CAAC,IAAI,EAAE,GAAG,GAAG,YAAY,CAE1D;AAED,wBAAgB,uBAAuB,CAAC,KAAK,CAAC,EAAE,YAAY,GAAG,IAAI,EAAE,mBAAmB,GAAE,OAAe,GAAG,GAAG,CAW9G"}
|
|
@@ -11,7 +11,6 @@
|
|
|
11
11
|
* https://openapi-generator.tech
|
|
12
12
|
* Do not edit the class manually.
|
|
13
13
|
*/
|
|
14
|
-
import { ClaimMountRequestFromJSON, ClaimMountRequestToJSON, } from './ClaimMountRequest.js';
|
|
15
14
|
import { SandboxConfigFromJSON, SandboxConfigToJSON, } from './SandboxConfig.js';
|
|
16
15
|
/**
|
|
17
16
|
* Check if a given object implements the ClaimRequest interface.
|
|
@@ -30,7 +29,6 @@ export function ClaimRequestFromJSONTyped(json, ignoreDiscriminator) {
|
|
|
30
29
|
'template': json['template'] == null ? undefined : json['template'],
|
|
31
30
|
'snapshotId': json['snapshot_id'] == null ? undefined : json['snapshot_id'],
|
|
32
31
|
'config': json['config'] == null ? undefined : SandboxConfigFromJSON(json['config']),
|
|
33
|
-
'mounts': json['mounts'] == null ? undefined : (json['mounts'].map(ClaimMountRequestFromJSON)),
|
|
34
32
|
};
|
|
35
33
|
}
|
|
36
34
|
export function ClaimRequestToJSON(json) {
|
|
@@ -44,6 +42,5 @@ export function ClaimRequestToJSONTyped(value, ignoreDiscriminator = false) {
|
|
|
44
42
|
'template': value['template'],
|
|
45
43
|
'snapshot_id': value['snapshotId'],
|
|
46
44
|
'config': SandboxConfigToJSON(value['config']),
|
|
47
|
-
'mounts': value['mounts'] == null ? undefined : (value['mounts'].map(ClaimMountRequestToJSON)),
|
|
48
45
|
};
|
|
49
46
|
}
|
|
@@ -10,7 +10,6 @@
|
|
|
10
10
|
* Do not edit the class manually.
|
|
11
11
|
*/
|
|
12
12
|
import type { SandboxLifecycleStatus } from './SandboxLifecycleStatus.js';
|
|
13
|
-
import type { MountStatus } from './MountStatus.js';
|
|
14
13
|
/**
|
|
15
14
|
*
|
|
16
15
|
* @export
|
|
@@ -47,12 +46,6 @@ export interface ClaimResponse {
|
|
|
47
46
|
* @memberof ClaimResponse
|
|
48
47
|
*/
|
|
49
48
|
clusterId?: string | null;
|
|
50
|
-
/**
|
|
51
|
-
*
|
|
52
|
-
* @type {Array<MountStatus>}
|
|
53
|
-
* @memberof ClaimResponse
|
|
54
|
-
*/
|
|
55
|
-
bootstrapMounts?: Array<MountStatus>;
|
|
56
49
|
}
|
|
57
50
|
/**
|
|
58
51
|
* Check if a given object implements the ClaimResponse interface.
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ClaimResponse.d.ts","sourceRoot":"","sources":["../../../../src/apispec/src/models/ClaimResponse.ts"],"names":[],"mappings":"AAEA;;;;;;;;;;GAUG;AAGH,OAAO,KAAK,EAAE,sBAAsB,EAAE,MAAM,0BAA0B,CAAC;
|
|
1
|
+
{"version":3,"file":"ClaimResponse.d.ts","sourceRoot":"","sources":["../../../../src/apispec/src/models/ClaimResponse.ts"],"names":[],"mappings":"AAEA;;;;;;;;;;GAUG;AAGH,OAAO,KAAK,EAAE,sBAAsB,EAAE,MAAM,0BAA0B,CAAC;AAQvE;;;;GAIG;AACH,MAAM,WAAW,aAAa;IAC1B;;;;OAIG;IACH,SAAS,EAAE,MAAM,CAAC;IAClB;;;;OAIG;IACH,MAAM,EAAE,sBAAsB,CAAC;IAC/B;;;;OAIG;IACH,OAAO,EAAE,MAAM,CAAC;IAChB;;;;OAIG;IACH,QAAQ,EAAE,MAAM,CAAC;IACjB;;;;OAIG;IACH,SAAS,CAAC,EAAE,MAAM,GAAG,IAAI,CAAC;CAC7B;AAID;;GAEG;AACH,wBAAgB,uBAAuB,CAAC,KAAK,EAAE,MAAM,GAAG,KAAK,IAAI,aAAa,CAM7E;AAED,wBAAgB,qBAAqB,CAAC,IAAI,EAAE,GAAG,GAAG,aAAa,CAE9D;AAED,wBAAgB,0BAA0B,CAAC,IAAI,EAAE,GAAG,EAAE,mBAAmB,EAAE,OAAO,GAAG,aAAa,CAYjG;AAED,wBAAgB,mBAAmB,CAAC,IAAI,EAAE,GAAG,GAAG,aAAa,CAE5D;AAED,wBAAgB,wBAAwB,CAAC,KAAK,CAAC,EAAE,aAAa,GAAG,IAAI,EAAE,mBAAmB,GAAE,OAAe,GAAG,GAAG,CAahH"}
|