@daytonaio/api-client 0.17.1 → 0.18.0-alpha.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/.openapi-generator/FILES +8 -0
- package/api/images-api.ts +207 -0
- package/api/object-storage-api.ts +161 -0
- package/api/volumes-api.ts +584 -0
- package/api.ts +2 -0
- package/dist/api/images-api.d.ts +75 -0
- package/dist/api/images-api.js +164 -0
- package/dist/api/object-storage-api.d.ts +74 -0
- package/dist/api/object-storage-api.js +140 -0
- package/dist/api/volumes-api.d.ts +227 -0
- package/dist/api/volumes-api.js +465 -0
- package/dist/api.d.ts +2 -0
- package/dist/api.js +2 -0
- package/dist/esm/api/images-api.d.ts +75 -0
- package/dist/esm/api/images-api.js +164 -0
- package/dist/esm/api/object-storage-api.d.ts +74 -0
- package/dist/esm/api/object-storage-api.js +133 -0
- package/dist/esm/api/volumes-api.d.ts +227 -0
- package/dist/esm/api/volumes-api.js +458 -0
- package/dist/esm/api.d.ts +2 -0
- package/dist/esm/api.js +2 -0
- package/dist/esm/models/api-key-list.d.ts +3 -0
- package/dist/esm/models/api-key-list.js +3 -0
- package/dist/esm/models/api-key-response.d.ts +3 -0
- package/dist/esm/models/api-key-response.js +3 -0
- package/dist/esm/models/build-image.d.ts +31 -0
- package/dist/esm/models/build-image.js +14 -0
- package/dist/esm/models/create-api-key.d.ts +3 -0
- package/dist/esm/models/create-api-key.js +3 -0
- package/dist/esm/models/create-build-info.d.ts +30 -0
- package/dist/esm/models/create-build-info.js +14 -0
- package/dist/esm/models/create-organization-role.d.ts +3 -0
- package/dist/esm/models/create-organization-role.js +3 -0
- package/dist/esm/models/create-user.d.ts +6 -0
- package/dist/esm/models/create-volume.d.ts +24 -0
- package/dist/esm/models/create-volume.js +14 -0
- package/dist/esm/models/create-workspace.d.ts +14 -0
- package/dist/esm/models/image-state.d.ts +2 -0
- package/dist/esm/models/image-state.js +2 -0
- package/dist/esm/models/index.d.ts +6 -0
- package/dist/esm/models/index.js +6 -0
- package/dist/esm/models/organization-role.d.ts +3 -0
- package/dist/esm/models/organization-role.js +3 -0
- package/dist/esm/models/storage-access-dto.d.ts +54 -0
- package/dist/esm/models/storage-access-dto.js +14 -0
- package/dist/esm/models/update-organization-role.d.ts +3 -0
- package/dist/esm/models/update-organization-role.js +3 -0
- package/dist/esm/models/volume-dto.d.ts +70 -0
- package/dist/esm/models/volume-dto.js +22 -0
- package/dist/esm/models/volume-mount-dto.d.ts +30 -0
- package/dist/esm/models/volume-mount-dto.js +2 -0
- package/dist/esm/models/workspace-state.d.ts +2 -0
- package/dist/esm/models/workspace-state.js +2 -0
- package/dist/esm/models/workspace-volume.d.ts +30 -0
- package/dist/esm/models/workspace-volume.js +14 -0
- package/dist/esm/models/workspace.d.ts +8 -1
- package/dist/models/api-key-list.d.ts +3 -0
- package/dist/models/api-key-list.js +3 -0
- package/dist/models/api-key-response.d.ts +3 -0
- package/dist/models/api-key-response.js +3 -0
- package/dist/models/build-image.d.ts +31 -0
- package/dist/models/build-image.js +15 -0
- package/dist/models/create-api-key.d.ts +3 -0
- package/dist/models/create-api-key.js +3 -0
- package/dist/models/create-build-info.d.ts +30 -0
- package/dist/models/create-build-info.js +15 -0
- package/dist/models/create-organization-role.d.ts +3 -0
- package/dist/models/create-organization-role.js +3 -0
- package/dist/models/create-user.d.ts +6 -0
- package/dist/models/create-volume.d.ts +24 -0
- package/dist/models/create-volume.js +15 -0
- package/dist/models/create-workspace.d.ts +14 -0
- package/dist/models/image-state.d.ts +2 -0
- package/dist/models/image-state.js +2 -0
- package/dist/models/index.d.ts +6 -0
- package/dist/models/index.js +6 -0
- package/dist/models/organization-role.d.ts +3 -0
- package/dist/models/organization-role.js +3 -0
- package/dist/models/storage-access-dto.d.ts +54 -0
- package/dist/models/storage-access-dto.js +15 -0
- package/dist/models/update-organization-role.d.ts +3 -0
- package/dist/models/update-organization-role.js +3 -0
- package/dist/models/volume-dto.d.ts +70 -0
- package/dist/models/volume-dto.js +25 -0
- package/dist/models/volume-mount-dto.d.ts +30 -0
- package/dist/models/volume-mount-dto.js +3 -0
- package/dist/models/workspace-state.d.ts +2 -0
- package/dist/models/workspace-state.js +2 -0
- package/dist/models/workspace-volume.d.ts +30 -0
- package/dist/models/workspace-volume.js +15 -0
- package/dist/models/workspace.d.ts +8 -1
- package/models/api-key-list.ts +3 -0
- package/models/api-key-response.ts +3 -0
- package/models/build-image.ts +37 -0
- package/models/create-api-key.ts +3 -0
- package/models/create-build-info.ts +33 -0
- package/models/create-organization-role.ts +3 -0
- package/models/create-user.ts +6 -0
- package/models/create-volume.ts +27 -0
- package/models/create-workspace.ts +19 -0
- package/models/image-state.ts +2 -0
- package/models/index.ts +6 -0
- package/models/organization-role.ts +3 -0
- package/models/storage-access-dto.ts +57 -0
- package/models/update-organization-role.ts +3 -0
- package/models/volume-dto.ts +75 -0
- package/models/volume-mount-dto.ts +33 -0
- package/models/workspace-state.ts +2 -0
- package/models/workspace-volume.ts +33 -0
- package/models/workspace.ts +10 -1
- package/package.json +1 -1
package/.openapi-generator/FILES
CHANGED
|
@@ -5,10 +5,12 @@ api/api-keys-api.ts
|
|
|
5
5
|
api/docker-registry-api.ts
|
|
6
6
|
api/images-api.ts
|
|
7
7
|
api/nodes-api.ts
|
|
8
|
+
api/object-storage-api.ts
|
|
8
9
|
api/organizations-api.ts
|
|
9
10
|
api/preview-api.ts
|
|
10
11
|
api/toolbox-api.ts
|
|
11
12
|
api/users-api.ts
|
|
13
|
+
api/volumes-api.ts
|
|
12
14
|
api/workspace-api.ts
|
|
13
15
|
base.ts
|
|
14
16
|
common.ts
|
|
@@ -16,11 +18,13 @@ configuration.ts
|
|
|
16
18
|
index.ts
|
|
17
19
|
models/api-key-list.ts
|
|
18
20
|
models/api-key-response.ts
|
|
21
|
+
models/build-image.ts
|
|
19
22
|
models/command.ts
|
|
20
23
|
models/completion-context.ts
|
|
21
24
|
models/completion-item.ts
|
|
22
25
|
models/completion-list.ts
|
|
23
26
|
models/create-api-key.ts
|
|
27
|
+
models/create-build-info.ts
|
|
24
28
|
models/create-docker-registry.ts
|
|
25
29
|
models/create-image.ts
|
|
26
30
|
models/create-node.ts
|
|
@@ -30,6 +34,7 @@ models/create-organization-role.ts
|
|
|
30
34
|
models/create-organization.ts
|
|
31
35
|
models/create-session-request.ts
|
|
32
36
|
models/create-user.ts
|
|
37
|
+
models/create-volume.ts
|
|
33
38
|
models/create-workspace.ts
|
|
34
39
|
models/docker-registry.ts
|
|
35
40
|
models/execute-request.ts
|
|
@@ -72,6 +77,7 @@ models/session-execute-request.ts
|
|
|
72
77
|
models/session-execute-response.ts
|
|
73
78
|
models/session.ts
|
|
74
79
|
models/set-image-general-status.ts
|
|
80
|
+
models/storage-access-dto.ts
|
|
75
81
|
models/toggle-state.ts
|
|
76
82
|
models/update-assigned-organization-roles.ts
|
|
77
83
|
models/update-docker-registry.ts
|
|
@@ -82,9 +88,11 @@ models/update-organization-role.ts
|
|
|
82
88
|
models/usage-overview.ts
|
|
83
89
|
models/user-public-key.ts
|
|
84
90
|
models/user.ts
|
|
91
|
+
models/volume-dto.ts
|
|
85
92
|
models/workspace-info.ts
|
|
86
93
|
models/workspace-labels.ts
|
|
87
94
|
models/workspace-state.ts
|
|
95
|
+
models/workspace-volume.ts
|
|
88
96
|
models/workspace.ts
|
|
89
97
|
package.json
|
|
90
98
|
tsconfig.esm.json
|
package/api/images-api.ts
CHANGED
|
@@ -32,6 +32,8 @@ import {
|
|
|
32
32
|
// @ts-ignore
|
|
33
33
|
import { BASE_PATH, COLLECTION_FORMATS, type RequestArgs, BaseAPI, RequiredError, operationServerMap } from '../base'
|
|
34
34
|
// @ts-ignore
|
|
35
|
+
import type { BuildImage } from '../models'
|
|
36
|
+
// @ts-ignore
|
|
35
37
|
import type { CreateImage } from '../models'
|
|
36
38
|
// @ts-ignore
|
|
37
39
|
import type { ImageDto } from '../models'
|
|
@@ -47,6 +49,56 @@ import type { ToggleState } from '../models'
|
|
|
47
49
|
*/
|
|
48
50
|
export const ImagesApiAxiosParamCreator = function (configuration?: Configuration) {
|
|
49
51
|
return {
|
|
52
|
+
/**
|
|
53
|
+
*
|
|
54
|
+
* @summary Build a Docker image
|
|
55
|
+
* @param {BuildImage} buildImage
|
|
56
|
+
* @param {string} [xDaytonaOrganizationID] Use with JWT to specify the organization ID
|
|
57
|
+
* @param {*} [options] Override http request option.
|
|
58
|
+
* @throws {RequiredError}
|
|
59
|
+
*/
|
|
60
|
+
buildImage: async (
|
|
61
|
+
buildImage: BuildImage,
|
|
62
|
+
xDaytonaOrganizationID?: string,
|
|
63
|
+
options: RawAxiosRequestConfig = {},
|
|
64
|
+
): Promise<RequestArgs> => {
|
|
65
|
+
// verify required parameter 'buildImage' is not null or undefined
|
|
66
|
+
assertParamExists('buildImage', 'buildImage', buildImage)
|
|
67
|
+
const localVarPath = `/images/build`
|
|
68
|
+
// use dummy base URL string because the URL constructor only accepts absolute URLs.
|
|
69
|
+
const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL)
|
|
70
|
+
let baseOptions
|
|
71
|
+
if (configuration) {
|
|
72
|
+
baseOptions = configuration.baseOptions
|
|
73
|
+
}
|
|
74
|
+
|
|
75
|
+
const localVarRequestOptions = { method: 'POST', ...baseOptions, ...options }
|
|
76
|
+
const localVarHeaderParameter = {} as any
|
|
77
|
+
const localVarQueryParameter = {} as any
|
|
78
|
+
|
|
79
|
+
// authentication bearer required
|
|
80
|
+
// http bearer authentication required
|
|
81
|
+
await setBearerAuthToObject(localVarHeaderParameter, configuration)
|
|
82
|
+
|
|
83
|
+
// authentication oauth2 required
|
|
84
|
+
// oauth required
|
|
85
|
+
await setOAuthToObject(localVarHeaderParameter, 'oauth2', ['openid', 'profile', 'email'], configuration)
|
|
86
|
+
|
|
87
|
+
localVarHeaderParameter['Content-Type'] = 'application/json'
|
|
88
|
+
|
|
89
|
+
if (xDaytonaOrganizationID != null) {
|
|
90
|
+
localVarHeaderParameter['X-Daytona-Organization-ID'] = String(xDaytonaOrganizationID)
|
|
91
|
+
}
|
|
92
|
+
setSearchParams(localVarUrlObj, localVarQueryParameter)
|
|
93
|
+
let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {}
|
|
94
|
+
localVarRequestOptions.headers = { ...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers }
|
|
95
|
+
localVarRequestOptions.data = serializeDataIfNeeded(buildImage, localVarRequestOptions, configuration)
|
|
96
|
+
|
|
97
|
+
return {
|
|
98
|
+
url: toPathString(localVarUrlObj),
|
|
99
|
+
options: localVarRequestOptions,
|
|
100
|
+
}
|
|
101
|
+
},
|
|
50
102
|
/**
|
|
51
103
|
*
|
|
52
104
|
* @summary Create a new image
|
|
@@ -152,6 +204,53 @@ export const ImagesApiAxiosParamCreator = function (configuration?: Configuratio
|
|
|
152
204
|
options: localVarRequestOptions,
|
|
153
205
|
}
|
|
154
206
|
},
|
|
207
|
+
/**
|
|
208
|
+
*
|
|
209
|
+
* @summary Get image by ID
|
|
210
|
+
* @param {string} id Image ID
|
|
211
|
+
* @param {string} [xDaytonaOrganizationID] Use with JWT to specify the organization ID
|
|
212
|
+
* @param {*} [options] Override http request option.
|
|
213
|
+
* @throws {RequiredError}
|
|
214
|
+
*/
|
|
215
|
+
getImage: async (
|
|
216
|
+
id: string,
|
|
217
|
+
xDaytonaOrganizationID?: string,
|
|
218
|
+
options: RawAxiosRequestConfig = {},
|
|
219
|
+
): Promise<RequestArgs> => {
|
|
220
|
+
// verify required parameter 'id' is not null or undefined
|
|
221
|
+
assertParamExists('getImage', 'id', id)
|
|
222
|
+
const localVarPath = `/images/{id}`.replace(`{${'id'}}`, encodeURIComponent(String(id)))
|
|
223
|
+
// use dummy base URL string because the URL constructor only accepts absolute URLs.
|
|
224
|
+
const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL)
|
|
225
|
+
let baseOptions
|
|
226
|
+
if (configuration) {
|
|
227
|
+
baseOptions = configuration.baseOptions
|
|
228
|
+
}
|
|
229
|
+
|
|
230
|
+
const localVarRequestOptions = { method: 'GET', ...baseOptions, ...options }
|
|
231
|
+
const localVarHeaderParameter = {} as any
|
|
232
|
+
const localVarQueryParameter = {} as any
|
|
233
|
+
|
|
234
|
+
// authentication bearer required
|
|
235
|
+
// http bearer authentication required
|
|
236
|
+
await setBearerAuthToObject(localVarHeaderParameter, configuration)
|
|
237
|
+
|
|
238
|
+
// authentication oauth2 required
|
|
239
|
+
// oauth required
|
|
240
|
+
await setOAuthToObject(localVarHeaderParameter, 'oauth2', ['openid', 'profile', 'email'], configuration)
|
|
241
|
+
|
|
242
|
+
if (xDaytonaOrganizationID != null) {
|
|
243
|
+
localVarHeaderParameter['X-Daytona-Organization-ID'] = String(xDaytonaOrganizationID)
|
|
244
|
+
}
|
|
245
|
+
setSearchParams(localVarUrlObj, localVarQueryParameter)
|
|
246
|
+
let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {}
|
|
247
|
+
localVarRequestOptions.headers = { ...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers }
|
|
248
|
+
|
|
249
|
+
return {
|
|
250
|
+
url: toPathString(localVarUrlObj),
|
|
251
|
+
options: localVarRequestOptions,
|
|
252
|
+
}
|
|
253
|
+
},
|
|
155
254
|
/**
|
|
156
255
|
*
|
|
157
256
|
* @summary Delete image
|
|
@@ -317,6 +416,31 @@ export const ImagesApiAxiosParamCreator = function (configuration?: Configuratio
|
|
|
317
416
|
export const ImagesApiFp = function (configuration?: Configuration) {
|
|
318
417
|
const localVarAxiosParamCreator = ImagesApiAxiosParamCreator(configuration)
|
|
319
418
|
return {
|
|
419
|
+
/**
|
|
420
|
+
*
|
|
421
|
+
* @summary Build a Docker image
|
|
422
|
+
* @param {BuildImage} buildImage
|
|
423
|
+
* @param {string} [xDaytonaOrganizationID] Use with JWT to specify the organization ID
|
|
424
|
+
* @param {*} [options] Override http request option.
|
|
425
|
+
* @throws {RequiredError}
|
|
426
|
+
*/
|
|
427
|
+
async buildImage(
|
|
428
|
+
buildImage: BuildImage,
|
|
429
|
+
xDaytonaOrganizationID?: string,
|
|
430
|
+
options?: RawAxiosRequestConfig,
|
|
431
|
+
): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<ImageDto>> {
|
|
432
|
+
const localVarAxiosArgs = await localVarAxiosParamCreator.buildImage(buildImage, xDaytonaOrganizationID, options)
|
|
433
|
+
const localVarOperationServerIndex = configuration?.serverIndex ?? 0
|
|
434
|
+
const localVarOperationServerBasePath =
|
|
435
|
+
operationServerMap['ImagesApi.buildImage']?.[localVarOperationServerIndex]?.url
|
|
436
|
+
return (axios, basePath) =>
|
|
437
|
+
createRequestFunction(
|
|
438
|
+
localVarAxiosArgs,
|
|
439
|
+
globalAxios,
|
|
440
|
+
BASE_PATH,
|
|
441
|
+
configuration,
|
|
442
|
+
)(axios, localVarOperationServerBasePath || basePath)
|
|
443
|
+
},
|
|
320
444
|
/**
|
|
321
445
|
*
|
|
322
446
|
* @summary Create a new image
|
|
@@ -378,6 +502,31 @@ export const ImagesApiFp = function (configuration?: Configuration) {
|
|
|
378
502
|
configuration,
|
|
379
503
|
)(axios, localVarOperationServerBasePath || basePath)
|
|
380
504
|
},
|
|
505
|
+
/**
|
|
506
|
+
*
|
|
507
|
+
* @summary Get image by ID
|
|
508
|
+
* @param {string} id Image ID
|
|
509
|
+
* @param {string} [xDaytonaOrganizationID] Use with JWT to specify the organization ID
|
|
510
|
+
* @param {*} [options] Override http request option.
|
|
511
|
+
* @throws {RequiredError}
|
|
512
|
+
*/
|
|
513
|
+
async getImage(
|
|
514
|
+
id: string,
|
|
515
|
+
xDaytonaOrganizationID?: string,
|
|
516
|
+
options?: RawAxiosRequestConfig,
|
|
517
|
+
): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<ImageDto>> {
|
|
518
|
+
const localVarAxiosArgs = await localVarAxiosParamCreator.getImage(id, xDaytonaOrganizationID, options)
|
|
519
|
+
const localVarOperationServerIndex = configuration?.serverIndex ?? 0
|
|
520
|
+
const localVarOperationServerBasePath =
|
|
521
|
+
operationServerMap['ImagesApi.getImage']?.[localVarOperationServerIndex]?.url
|
|
522
|
+
return (axios, basePath) =>
|
|
523
|
+
createRequestFunction(
|
|
524
|
+
localVarAxiosArgs,
|
|
525
|
+
globalAxios,
|
|
526
|
+
BASE_PATH,
|
|
527
|
+
configuration,
|
|
528
|
+
)(axios, localVarOperationServerBasePath || basePath)
|
|
529
|
+
},
|
|
381
530
|
/**
|
|
382
531
|
*
|
|
383
532
|
* @summary Delete image
|
|
@@ -477,6 +626,23 @@ export const ImagesApiFp = function (configuration?: Configuration) {
|
|
|
477
626
|
export const ImagesApiFactory = function (configuration?: Configuration, basePath?: string, axios?: AxiosInstance) {
|
|
478
627
|
const localVarFp = ImagesApiFp(configuration)
|
|
479
628
|
return {
|
|
629
|
+
/**
|
|
630
|
+
*
|
|
631
|
+
* @summary Build a Docker image
|
|
632
|
+
* @param {BuildImage} buildImage
|
|
633
|
+
* @param {string} [xDaytonaOrganizationID] Use with JWT to specify the organization ID
|
|
634
|
+
* @param {*} [options] Override http request option.
|
|
635
|
+
* @throws {RequiredError}
|
|
636
|
+
*/
|
|
637
|
+
buildImage(
|
|
638
|
+
buildImage: BuildImage,
|
|
639
|
+
xDaytonaOrganizationID?: string,
|
|
640
|
+
options?: RawAxiosRequestConfig,
|
|
641
|
+
): AxiosPromise<ImageDto> {
|
|
642
|
+
return localVarFp
|
|
643
|
+
.buildImage(buildImage, xDaytonaOrganizationID, options)
|
|
644
|
+
.then((request) => request(axios, basePath))
|
|
645
|
+
},
|
|
480
646
|
/**
|
|
481
647
|
*
|
|
482
648
|
* @summary Create a new image
|
|
@@ -513,6 +679,17 @@ export const ImagesApiFactory = function (configuration?: Configuration, basePat
|
|
|
513
679
|
.getAllImages(xDaytonaOrganizationID, limit, page, options)
|
|
514
680
|
.then((request) => request(axios, basePath))
|
|
515
681
|
},
|
|
682
|
+
/**
|
|
683
|
+
*
|
|
684
|
+
* @summary Get image by ID
|
|
685
|
+
* @param {string} id Image ID
|
|
686
|
+
* @param {string} [xDaytonaOrganizationID] Use with JWT to specify the organization ID
|
|
687
|
+
* @param {*} [options] Override http request option.
|
|
688
|
+
* @throws {RequiredError}
|
|
689
|
+
*/
|
|
690
|
+
getImage(id: string, xDaytonaOrganizationID?: string, options?: RawAxiosRequestConfig): AxiosPromise<ImageDto> {
|
|
691
|
+
return localVarFp.getImage(id, xDaytonaOrganizationID, options).then((request) => request(axios, basePath))
|
|
692
|
+
},
|
|
516
693
|
/**
|
|
517
694
|
*
|
|
518
695
|
* @summary Delete image
|
|
@@ -572,6 +749,21 @@ export const ImagesApiFactory = function (configuration?: Configuration, basePat
|
|
|
572
749
|
* @extends {BaseAPI}
|
|
573
750
|
*/
|
|
574
751
|
export class ImagesApi extends BaseAPI {
|
|
752
|
+
/**
|
|
753
|
+
*
|
|
754
|
+
* @summary Build a Docker image
|
|
755
|
+
* @param {BuildImage} buildImage
|
|
756
|
+
* @param {string} [xDaytonaOrganizationID] Use with JWT to specify the organization ID
|
|
757
|
+
* @param {*} [options] Override http request option.
|
|
758
|
+
* @throws {RequiredError}
|
|
759
|
+
* @memberof ImagesApi
|
|
760
|
+
*/
|
|
761
|
+
public buildImage(buildImage: BuildImage, xDaytonaOrganizationID?: string, options?: RawAxiosRequestConfig) {
|
|
762
|
+
return ImagesApiFp(this.configuration)
|
|
763
|
+
.buildImage(buildImage, xDaytonaOrganizationID, options)
|
|
764
|
+
.then((request) => request(this.axios, this.basePath))
|
|
765
|
+
}
|
|
766
|
+
|
|
575
767
|
/**
|
|
576
768
|
*
|
|
577
769
|
* @summary Create a new image
|
|
@@ -603,6 +795,21 @@ export class ImagesApi extends BaseAPI {
|
|
|
603
795
|
.then((request) => request(this.axios, this.basePath))
|
|
604
796
|
}
|
|
605
797
|
|
|
798
|
+
/**
|
|
799
|
+
*
|
|
800
|
+
* @summary Get image by ID
|
|
801
|
+
* @param {string} id Image ID
|
|
802
|
+
* @param {string} [xDaytonaOrganizationID] Use with JWT to specify the organization ID
|
|
803
|
+
* @param {*} [options] Override http request option.
|
|
804
|
+
* @throws {RequiredError}
|
|
805
|
+
* @memberof ImagesApi
|
|
806
|
+
*/
|
|
807
|
+
public getImage(id: string, xDaytonaOrganizationID?: string, options?: RawAxiosRequestConfig) {
|
|
808
|
+
return ImagesApiFp(this.configuration)
|
|
809
|
+
.getImage(id, xDaytonaOrganizationID, options)
|
|
810
|
+
.then((request) => request(this.axios, this.basePath))
|
|
811
|
+
}
|
|
812
|
+
|
|
606
813
|
/**
|
|
607
814
|
*
|
|
608
815
|
* @summary Delete image
|
|
@@ -0,0 +1,161 @@
|
|
|
1
|
+
/* tslint:disable */
|
|
2
|
+
/* eslint-disable */
|
|
3
|
+
/**
|
|
4
|
+
* Daytona Workspaces
|
|
5
|
+
* Daytona Workspaces API Docs
|
|
6
|
+
*
|
|
7
|
+
* The version of the OpenAPI document: 1.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
|
+
import type { Configuration } from '../configuration'
|
|
16
|
+
import type { AxiosPromise, AxiosInstance, RawAxiosRequestConfig } from 'axios'
|
|
17
|
+
import globalAxios from 'axios'
|
|
18
|
+
// Some imports not used depending on template conditions
|
|
19
|
+
// @ts-ignore
|
|
20
|
+
import {
|
|
21
|
+
DUMMY_BASE_URL,
|
|
22
|
+
assertParamExists,
|
|
23
|
+
setApiKeyToObject,
|
|
24
|
+
setBasicAuthToObject,
|
|
25
|
+
setBearerAuthToObject,
|
|
26
|
+
setOAuthToObject,
|
|
27
|
+
setSearchParams,
|
|
28
|
+
serializeDataIfNeeded,
|
|
29
|
+
toPathString,
|
|
30
|
+
createRequestFunction,
|
|
31
|
+
} from '../common'
|
|
32
|
+
// @ts-ignore
|
|
33
|
+
import { BASE_PATH, COLLECTION_FORMATS, type RequestArgs, BaseAPI, RequiredError, operationServerMap } from '../base'
|
|
34
|
+
// @ts-ignore
|
|
35
|
+
import type { StorageAccessDto } from '../models'
|
|
36
|
+
/**
|
|
37
|
+
* ObjectStorageApi - axios parameter creator
|
|
38
|
+
* @export
|
|
39
|
+
*/
|
|
40
|
+
export const ObjectStorageApiAxiosParamCreator = function (configuration?: Configuration) {
|
|
41
|
+
return {
|
|
42
|
+
/**
|
|
43
|
+
*
|
|
44
|
+
* @summary Get temporary storage access for pushing objects
|
|
45
|
+
* @param {string} [xDaytonaOrganizationID] Use with JWT to specify the organization ID
|
|
46
|
+
* @param {*} [options] Override http request option.
|
|
47
|
+
* @throws {RequiredError}
|
|
48
|
+
*/
|
|
49
|
+
getPushAccess: async (
|
|
50
|
+
xDaytonaOrganizationID?: string,
|
|
51
|
+
options: RawAxiosRequestConfig = {},
|
|
52
|
+
): Promise<RequestArgs> => {
|
|
53
|
+
const localVarPath = `/object-storage/push-access`
|
|
54
|
+
// use dummy base URL string because the URL constructor only accepts absolute URLs.
|
|
55
|
+
const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL)
|
|
56
|
+
let baseOptions
|
|
57
|
+
if (configuration) {
|
|
58
|
+
baseOptions = configuration.baseOptions
|
|
59
|
+
}
|
|
60
|
+
|
|
61
|
+
const localVarRequestOptions = { method: 'GET', ...baseOptions, ...options }
|
|
62
|
+
const localVarHeaderParameter = {} as any
|
|
63
|
+
const localVarQueryParameter = {} as any
|
|
64
|
+
|
|
65
|
+
// authentication oauth2 required
|
|
66
|
+
// oauth required
|
|
67
|
+
await setOAuthToObject(localVarHeaderParameter, 'oauth2', ['openid', 'profile', 'email'], configuration)
|
|
68
|
+
|
|
69
|
+
if (xDaytonaOrganizationID != null) {
|
|
70
|
+
localVarHeaderParameter['X-Daytona-Organization-ID'] = String(xDaytonaOrganizationID)
|
|
71
|
+
}
|
|
72
|
+
setSearchParams(localVarUrlObj, localVarQueryParameter)
|
|
73
|
+
let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {}
|
|
74
|
+
localVarRequestOptions.headers = { ...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers }
|
|
75
|
+
|
|
76
|
+
return {
|
|
77
|
+
url: toPathString(localVarUrlObj),
|
|
78
|
+
options: localVarRequestOptions,
|
|
79
|
+
}
|
|
80
|
+
},
|
|
81
|
+
}
|
|
82
|
+
}
|
|
83
|
+
|
|
84
|
+
/**
|
|
85
|
+
* ObjectStorageApi - functional programming interface
|
|
86
|
+
* @export
|
|
87
|
+
*/
|
|
88
|
+
export const ObjectStorageApiFp = function (configuration?: Configuration) {
|
|
89
|
+
const localVarAxiosParamCreator = ObjectStorageApiAxiosParamCreator(configuration)
|
|
90
|
+
return {
|
|
91
|
+
/**
|
|
92
|
+
*
|
|
93
|
+
* @summary Get temporary storage access for pushing objects
|
|
94
|
+
* @param {string} [xDaytonaOrganizationID] Use with JWT to specify the organization ID
|
|
95
|
+
* @param {*} [options] Override http request option.
|
|
96
|
+
* @throws {RequiredError}
|
|
97
|
+
*/
|
|
98
|
+
async getPushAccess(
|
|
99
|
+
xDaytonaOrganizationID?: string,
|
|
100
|
+
options?: RawAxiosRequestConfig,
|
|
101
|
+
): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<StorageAccessDto>> {
|
|
102
|
+
const localVarAxiosArgs = await localVarAxiosParamCreator.getPushAccess(xDaytonaOrganizationID, options)
|
|
103
|
+
const localVarOperationServerIndex = configuration?.serverIndex ?? 0
|
|
104
|
+
const localVarOperationServerBasePath =
|
|
105
|
+
operationServerMap['ObjectStorageApi.getPushAccess']?.[localVarOperationServerIndex]?.url
|
|
106
|
+
return (axios, basePath) =>
|
|
107
|
+
createRequestFunction(
|
|
108
|
+
localVarAxiosArgs,
|
|
109
|
+
globalAxios,
|
|
110
|
+
BASE_PATH,
|
|
111
|
+
configuration,
|
|
112
|
+
)(axios, localVarOperationServerBasePath || basePath)
|
|
113
|
+
},
|
|
114
|
+
}
|
|
115
|
+
}
|
|
116
|
+
|
|
117
|
+
/**
|
|
118
|
+
* ObjectStorageApi - factory interface
|
|
119
|
+
* @export
|
|
120
|
+
*/
|
|
121
|
+
export const ObjectStorageApiFactory = function (
|
|
122
|
+
configuration?: Configuration,
|
|
123
|
+
basePath?: string,
|
|
124
|
+
axios?: AxiosInstance,
|
|
125
|
+
) {
|
|
126
|
+
const localVarFp = ObjectStorageApiFp(configuration)
|
|
127
|
+
return {
|
|
128
|
+
/**
|
|
129
|
+
*
|
|
130
|
+
* @summary Get temporary storage access for pushing objects
|
|
131
|
+
* @param {string} [xDaytonaOrganizationID] Use with JWT to specify the organization ID
|
|
132
|
+
* @param {*} [options] Override http request option.
|
|
133
|
+
* @throws {RequiredError}
|
|
134
|
+
*/
|
|
135
|
+
getPushAccess(xDaytonaOrganizationID?: string, options?: RawAxiosRequestConfig): AxiosPromise<StorageAccessDto> {
|
|
136
|
+
return localVarFp.getPushAccess(xDaytonaOrganizationID, options).then((request) => request(axios, basePath))
|
|
137
|
+
},
|
|
138
|
+
}
|
|
139
|
+
}
|
|
140
|
+
|
|
141
|
+
/**
|
|
142
|
+
* ObjectStorageApi - object-oriented interface
|
|
143
|
+
* @export
|
|
144
|
+
* @class ObjectStorageApi
|
|
145
|
+
* @extends {BaseAPI}
|
|
146
|
+
*/
|
|
147
|
+
export class ObjectStorageApi extends BaseAPI {
|
|
148
|
+
/**
|
|
149
|
+
*
|
|
150
|
+
* @summary Get temporary storage access for pushing objects
|
|
151
|
+
* @param {string} [xDaytonaOrganizationID] Use with JWT to specify the organization ID
|
|
152
|
+
* @param {*} [options] Override http request option.
|
|
153
|
+
* @throws {RequiredError}
|
|
154
|
+
* @memberof ObjectStorageApi
|
|
155
|
+
*/
|
|
156
|
+
public getPushAccess(xDaytonaOrganizationID?: string, options?: RawAxiosRequestConfig) {
|
|
157
|
+
return ObjectStorageApiFp(this.configuration)
|
|
158
|
+
.getPushAccess(xDaytonaOrganizationID, options)
|
|
159
|
+
.then((request) => request(this.axios, this.basePath))
|
|
160
|
+
}
|
|
161
|
+
}
|