@daytonaio/api-client 0.1.0 → 0.2.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 +26 -23
- package/README.md +3 -3
- package/api/default-api.ts +3621 -0
- package/api/docker-registry-api.ts +572 -0
- package/api.ts +19 -0
- package/base.ts +86 -0
- package/common.ts +150 -0
- package/configuration.ts +110 -0
- package/dist/api/default-api.d.ts +1621 -0
- package/dist/api/default-api.js +3393 -0
- package/dist/api/docker-registry-api.d.ts +269 -0
- package/dist/api/docker-registry-api.js +547 -0
- package/dist/api.d.ts +13 -0
- package/dist/{apis/index.js → api.js} +15 -4
- package/dist/base.d.ts +66 -0
- package/dist/base.js +65 -0
- package/dist/common.d.ts +65 -0
- package/dist/common.js +161 -0
- package/dist/configuration.d.ts +91 -0
- package/dist/configuration.js +43 -0
- package/dist/esm/api/default-api.d.ts +1621 -0
- package/dist/esm/api/default-api.js +3386 -0
- package/dist/esm/api/docker-registry-api.d.ts +269 -0
- package/dist/esm/api/docker-registry-api.js +540 -0
- package/dist/esm/api.d.ts +13 -0
- package/dist/esm/api.js +15 -0
- package/dist/esm/base.d.ts +66 -0
- package/dist/esm/base.js +60 -0
- package/dist/esm/common.d.ts +65 -0
- package/dist/esm/common.js +149 -0
- package/dist/esm/configuration.d.ts +91 -0
- package/dist/esm/configuration.js +39 -0
- package/dist/esm/index.d.ts +14 -3
- package/dist/esm/index.js +14 -3
- package/dist/esm/models/{ApiKeyListDto.d.ts → api-key-list-dto.d.ts} +4 -12
- package/dist/esm/models/api-key-list-dto.js +14 -0
- package/dist/esm/models/{ApiKeyResponseDto.d.ts → api-key-response-dto.d.ts} +4 -12
- package/dist/esm/models/api-key-response-dto.js +14 -0
- package/dist/esm/models/create-api-key-dto.d.ts +24 -0
- package/dist/esm/models/create-api-key-dto.js +14 -0
- package/dist/{models/CreateDockerRegistryDto.d.ts → esm/models/create-docker-registry-dto.d.ts} +6 -14
- package/dist/esm/models/create-docker-registry-dto.js +14 -0
- package/dist/{models/CreateWorkspaceDto.d.ts → esm/models/create-workspace-dto.d.ts} +6 -14
- package/dist/esm/models/create-workspace-dto.js +14 -0
- package/dist/esm/models/execute-request-dto.d.ts +30 -0
- package/dist/esm/models/execute-request-dto.js +14 -0
- package/dist/esm/models/execute-response-dto.d.ts +30 -0
- package/dist/esm/models/execute-response-dto.js +14 -0
- package/dist/esm/models/git-add-request-dto.d.ts +30 -0
- package/dist/esm/models/git-add-request-dto.js +14 -0
- package/dist/esm/models/git-branch-request-dto.d.ts +30 -0
- package/dist/esm/models/git-branch-request-dto.js +14 -0
- package/dist/{models/GitCloneRequestDto.d.ts → esm/models/git-clone-request-dto.d.ts} +6 -14
- package/dist/esm/models/git-clone-request-dto.js +14 -0
- package/dist/{models/GitCommitRequestDto.d.ts → esm/models/git-commit-request-dto.d.ts} +4 -12
- package/dist/esm/models/git-commit-request-dto.js +14 -0
- package/dist/esm/models/git-repo-request-dto.d.ts +36 -0
- package/dist/esm/models/git-repo-request-dto.js +14 -0
- package/dist/esm/models/index.d.ts +17 -17
- package/dist/esm/models/index.js +17 -19
- package/dist/esm/models/replace-request-dto.d.ts +36 -0
- package/dist/esm/models/replace-request-dto.js +14 -0
- package/dist/{models/UpdateDockerRegistryDto.d.ts → esm/models/update-docker-registry-dto.d.ts} +6 -14
- package/dist/esm/models/update-docker-registry-dto.js +14 -0
- package/dist/{models/WorkspaceDto.d.ts → esm/models/workspace-dto.d.ts} +8 -16
- package/dist/esm/models/workspace-dto.js +14 -0
- package/dist/esm/models/{WorkspaceInfoDto.d.ts → workspace-info-dto.d.ts} +3 -11
- package/dist/esm/models/workspace-info-dto.js +14 -0
- package/dist/esm/models/workspace-labels-dto.d.ts +26 -0
- package/dist/esm/models/workspace-labels-dto.js +14 -0
- package/dist/index.d.ts +14 -3
- package/dist/index.js +16 -5
- package/dist/models/{ApiKeyListDto.d.ts → api-key-list-dto.d.ts} +4 -12
- package/dist/models/api-key-list-dto.js +15 -0
- package/dist/models/{ApiKeyResponseDto.d.ts → api-key-response-dto.d.ts} +4 -12
- package/dist/models/api-key-response-dto.js +15 -0
- package/dist/models/create-api-key-dto.d.ts +24 -0
- package/dist/models/create-api-key-dto.js +15 -0
- package/dist/{esm/models/CreateDockerRegistryDto.d.ts → models/create-docker-registry-dto.d.ts} +6 -14
- package/dist/models/create-docker-registry-dto.js +15 -0
- package/dist/{esm/models/CreateWorkspaceDto.d.ts → models/create-workspace-dto.d.ts} +6 -14
- package/dist/models/create-workspace-dto.js +15 -0
- package/dist/models/execute-request-dto.d.ts +30 -0
- package/dist/models/execute-request-dto.js +15 -0
- package/dist/models/execute-response-dto.d.ts +30 -0
- package/dist/models/execute-response-dto.js +15 -0
- package/dist/models/git-add-request-dto.d.ts +30 -0
- package/dist/models/git-add-request-dto.js +15 -0
- package/dist/models/git-branch-request-dto.d.ts +30 -0
- package/dist/models/git-branch-request-dto.js +15 -0
- package/dist/{esm/models/GitCloneRequestDto.d.ts → models/git-clone-request-dto.d.ts} +6 -14
- package/dist/models/git-clone-request-dto.js +15 -0
- package/dist/{esm/models/GitCommitRequestDto.d.ts → models/git-commit-request-dto.d.ts} +4 -12
- package/dist/models/git-commit-request-dto.js +15 -0
- package/dist/models/git-repo-request-dto.d.ts +36 -0
- package/dist/models/git-repo-request-dto.js +15 -0
- package/dist/models/index.d.ts +17 -17
- package/dist/models/index.js +17 -19
- package/dist/models/replace-request-dto.d.ts +36 -0
- package/dist/models/replace-request-dto.js +15 -0
- package/dist/{esm/models/UpdateDockerRegistryDto.d.ts → models/update-docker-registry-dto.d.ts} +6 -14
- package/dist/models/update-docker-registry-dto.js +15 -0
- package/dist/{esm/models/WorkspaceDto.d.ts → models/workspace-dto.d.ts} +8 -16
- package/dist/models/workspace-dto.js +15 -0
- package/dist/models/{WorkspaceInfoDto.d.ts → workspace-info-dto.d.ts} +3 -11
- package/dist/models/workspace-info-dto.js +15 -0
- package/dist/models/workspace-labels-dto.d.ts +26 -0
- package/dist/models/workspace-labels-dto.js +15 -0
- package/git_push.sh +57 -0
- package/index.ts +18 -0
- package/models/api-key-list-dto.ts +42 -0
- package/models/api-key-response-dto.ts +42 -0
- package/models/create-api-key-dto.ts +30 -0
- package/models/create-docker-registry-dto.ts +60 -0
- package/models/create-workspace-dto.ts +60 -0
- package/models/execute-request-dto.ts +36 -0
- package/models/execute-response-dto.ts +36 -0
- package/models/git-add-request-dto.ts +36 -0
- package/models/git-branch-request-dto.ts +36 -0
- package/models/git-clone-request-dto.ts +60 -0
- package/models/git-commit-request-dto.ts +48 -0
- package/models/git-repo-request-dto.ts +42 -0
- package/models/index.ts +17 -0
- package/models/replace-request-dto.ts +42 -0
- package/models/update-docker-registry-dto.ts +60 -0
- package/models/workspace-dto.ts +69 -0
- package/models/workspace-info-dto.ts +42 -0
- package/models/workspace-labels-dto.ts +30 -0
- package/package.json +14 -3
- package/tsconfig.json +4 -2
- package/dist/apis/DefaultApi.d.ts +0 -551
- package/dist/apis/DefaultApi.js +0 -1645
- package/dist/apis/DockerRegistryApi.d.ts +0 -90
- package/dist/apis/DockerRegistryApi.js +0 -257
- package/dist/apis/index.d.ts +0 -2
- package/dist/esm/apis/DefaultApi.d.ts +0 -551
- package/dist/esm/apis/DefaultApi.js +0 -1641
- package/dist/esm/apis/DockerRegistryApi.d.ts +0 -90
- package/dist/esm/apis/DockerRegistryApi.js +0 -253
- package/dist/esm/apis/index.d.ts +0 -2
- package/dist/esm/apis/index.js +0 -4
- package/dist/esm/models/ApiKeyListDto.js +0 -51
- package/dist/esm/models/ApiKeyResponseDto.js +0 -51
- package/dist/esm/models/CreateApiKeyDto.d.ts +0 -32
- package/dist/esm/models/CreateApiKeyDto.js +0 -43
- package/dist/esm/models/CreateDockerRegistryDto.js +0 -61
- package/dist/esm/models/CreateWorkspaceDto.js +0 -63
- package/dist/esm/models/ExecuteRequestDto.d.ts +0 -38
- package/dist/esm/models/ExecuteRequestDto.js +0 -45
- package/dist/esm/models/ExecuteResponseDto.d.ts +0 -38
- package/dist/esm/models/ExecuteResponseDto.js +0 -47
- package/dist/esm/models/GitAddRequestDto.d.ts +0 -38
- package/dist/esm/models/GitAddRequestDto.js +0 -47
- package/dist/esm/models/GitBranchRequestDto.d.ts +0 -38
- package/dist/esm/models/GitBranchRequestDto.js +0 -47
- package/dist/esm/models/GitCloneRequestDto.js +0 -55
- package/dist/esm/models/GitCommitRequestDto.js +0 -55
- package/dist/esm/models/GitRepoRequestDto.d.ts +0 -44
- package/dist/esm/models/GitRepoRequestDto.js +0 -47
- package/dist/esm/models/ReplaceRequestDto.d.ts +0 -44
- package/dist/esm/models/ReplaceRequestDto.js +0 -51
- package/dist/esm/models/UpdateDockerRegistryDto.js +0 -51
- package/dist/esm/models/WorkspaceDto.js +0 -66
- package/dist/esm/models/WorkspaceInfoDto.js +0 -49
- package/dist/esm/models/WorkspaceLabelsDto.d.ts +0 -34
- package/dist/esm/models/WorkspaceLabelsDto.js +0 -43
- package/dist/esm/runtime.d.ts +0 -181
- package/dist/esm/runtime.js +0 -326
- package/dist/models/ApiKeyListDto.js +0 -59
- package/dist/models/ApiKeyResponseDto.js +0 -59
- package/dist/models/CreateApiKeyDto.d.ts +0 -32
- package/dist/models/CreateApiKeyDto.js +0 -51
- package/dist/models/CreateDockerRegistryDto.js +0 -69
- package/dist/models/CreateWorkspaceDto.js +0 -71
- package/dist/models/ExecuteRequestDto.d.ts +0 -38
- package/dist/models/ExecuteRequestDto.js +0 -53
- package/dist/models/ExecuteResponseDto.d.ts +0 -38
- package/dist/models/ExecuteResponseDto.js +0 -55
- package/dist/models/GitAddRequestDto.d.ts +0 -38
- package/dist/models/GitAddRequestDto.js +0 -55
- package/dist/models/GitBranchRequestDto.d.ts +0 -38
- package/dist/models/GitBranchRequestDto.js +0 -55
- package/dist/models/GitCloneRequestDto.js +0 -63
- package/dist/models/GitCommitRequestDto.js +0 -63
- package/dist/models/GitRepoRequestDto.d.ts +0 -44
- package/dist/models/GitRepoRequestDto.js +0 -55
- package/dist/models/ReplaceRequestDto.d.ts +0 -44
- package/dist/models/ReplaceRequestDto.js +0 -59
- package/dist/models/UpdateDockerRegistryDto.js +0 -59
- package/dist/models/WorkspaceDto.js +0 -74
- package/dist/models/WorkspaceInfoDto.js +0 -57
- package/dist/models/WorkspaceLabelsDto.d.ts +0 -34
- package/dist/models/WorkspaceLabelsDto.js +0 -51
- package/dist/runtime.d.ts +0 -181
- package/dist/runtime.js +0 -341
- package/src/apis/DefaultApi.ts +0 -2380
- package/src/apis/DockerRegistryApi.ts +0 -318
- package/src/apis/index.ts +0 -4
- package/src/index.ts +0 -5
- package/src/models/ApiKeyListDto.ts +0 -84
- package/src/models/ApiKeyResponseDto.ts +0 -84
- package/src/models/CreateApiKeyDto.ts +0 -66
- package/src/models/CreateDockerRegistryDto.ts +0 -110
- package/src/models/CreateWorkspaceDto.ts +0 -111
- package/src/models/ExecuteRequestDto.ts +0 -74
- package/src/models/ExecuteResponseDto.ts +0 -75
- package/src/models/GitAddRequestDto.ts +0 -75
- package/src/models/GitBranchRequestDto.ts +0 -75
- package/src/models/GitCloneRequestDto.ts +0 -107
- package/src/models/GitCommitRequestDto.ts +0 -93
- package/src/models/GitRepoRequestDto.ts +0 -82
- package/src/models/ReplaceRequestDto.ts +0 -84
- package/src/models/UpdateDockerRegistryDto.ts +0 -105
- package/src/models/WorkspaceDto.ts +0 -127
- package/src/models/WorkspaceInfoDto.ts +0 -83
- package/src/models/WorkspaceLabelsDto.ts +0 -66
- package/src/models/index.ts +0 -19
- package/src/runtime.ts +0 -426
package/dist/esm/base.js
ADDED
|
@@ -0,0 +1,60 @@
|
|
|
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
|
+
import globalAxios from 'axios';
|
|
15
|
+
export const BASE_PATH = "http://localhost".replace(/\/+$/, "");
|
|
16
|
+
/**
|
|
17
|
+
*
|
|
18
|
+
* @export
|
|
19
|
+
*/
|
|
20
|
+
export const COLLECTION_FORMATS = {
|
|
21
|
+
csv: ",",
|
|
22
|
+
ssv: " ",
|
|
23
|
+
tsv: "\t",
|
|
24
|
+
pipes: "|",
|
|
25
|
+
};
|
|
26
|
+
/**
|
|
27
|
+
*
|
|
28
|
+
* @export
|
|
29
|
+
* @class BaseAPI
|
|
30
|
+
*/
|
|
31
|
+
export class BaseAPI {
|
|
32
|
+
constructor(configuration, basePath = BASE_PATH, axios = globalAxios) {
|
|
33
|
+
var _a;
|
|
34
|
+
this.basePath = basePath;
|
|
35
|
+
this.axios = axios;
|
|
36
|
+
if (configuration) {
|
|
37
|
+
this.configuration = configuration;
|
|
38
|
+
this.basePath = (_a = configuration.basePath) !== null && _a !== void 0 ? _a : basePath;
|
|
39
|
+
}
|
|
40
|
+
}
|
|
41
|
+
}
|
|
42
|
+
;
|
|
43
|
+
/**
|
|
44
|
+
*
|
|
45
|
+
* @export
|
|
46
|
+
* @class RequiredError
|
|
47
|
+
* @extends {Error}
|
|
48
|
+
*/
|
|
49
|
+
export class RequiredError extends Error {
|
|
50
|
+
constructor(field, msg) {
|
|
51
|
+
super(msg);
|
|
52
|
+
this.field = field;
|
|
53
|
+
this.name = "RequiredError";
|
|
54
|
+
}
|
|
55
|
+
}
|
|
56
|
+
/**
|
|
57
|
+
*
|
|
58
|
+
* @export
|
|
59
|
+
*/
|
|
60
|
+
export const operationServerMap = {};
|
|
@@ -0,0 +1,65 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Daytona Workspaces
|
|
3
|
+
* Daytona Workspaces API Docs
|
|
4
|
+
*
|
|
5
|
+
* The version of the OpenAPI document: 1.0
|
|
6
|
+
*
|
|
7
|
+
*
|
|
8
|
+
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
9
|
+
* https://openapi-generator.tech
|
|
10
|
+
* Do not edit the class manually.
|
|
11
|
+
*/
|
|
12
|
+
import type { Configuration } from "./configuration";
|
|
13
|
+
import type { RequestArgs } from "./base";
|
|
14
|
+
import type { AxiosInstance, AxiosResponse } from 'axios';
|
|
15
|
+
/**
|
|
16
|
+
*
|
|
17
|
+
* @export
|
|
18
|
+
*/
|
|
19
|
+
export declare const DUMMY_BASE_URL = "https://example.com";
|
|
20
|
+
/**
|
|
21
|
+
*
|
|
22
|
+
* @throws {RequiredError}
|
|
23
|
+
* @export
|
|
24
|
+
*/
|
|
25
|
+
export declare const assertParamExists: (functionName: string, paramName: string, paramValue: unknown) => void;
|
|
26
|
+
/**
|
|
27
|
+
*
|
|
28
|
+
* @export
|
|
29
|
+
*/
|
|
30
|
+
export declare const setApiKeyToObject: (object: any, keyParamName: string, configuration?: Configuration) => Promise<void>;
|
|
31
|
+
/**
|
|
32
|
+
*
|
|
33
|
+
* @export
|
|
34
|
+
*/
|
|
35
|
+
export declare const setBasicAuthToObject: (object: any, configuration?: Configuration) => void;
|
|
36
|
+
/**
|
|
37
|
+
*
|
|
38
|
+
* @export
|
|
39
|
+
*/
|
|
40
|
+
export declare const setBearerAuthToObject: (object: any, configuration?: Configuration) => Promise<void>;
|
|
41
|
+
/**
|
|
42
|
+
*
|
|
43
|
+
* @export
|
|
44
|
+
*/
|
|
45
|
+
export declare const setOAuthToObject: (object: any, name: string, scopes: string[], configuration?: Configuration) => Promise<void>;
|
|
46
|
+
/**
|
|
47
|
+
*
|
|
48
|
+
* @export
|
|
49
|
+
*/
|
|
50
|
+
export declare const setSearchParams: (url: URL, ...objects: any[]) => void;
|
|
51
|
+
/**
|
|
52
|
+
*
|
|
53
|
+
* @export
|
|
54
|
+
*/
|
|
55
|
+
export declare const serializeDataIfNeeded: (value: any, requestOptions: any, configuration?: Configuration) => any;
|
|
56
|
+
/**
|
|
57
|
+
*
|
|
58
|
+
* @export
|
|
59
|
+
*/
|
|
60
|
+
export declare const toPathString: (url: URL) => string;
|
|
61
|
+
/**
|
|
62
|
+
*
|
|
63
|
+
* @export
|
|
64
|
+
*/
|
|
65
|
+
export declare const createRequestFunction: (axiosArgs: RequestArgs, globalAxios: AxiosInstance, BASE_PATH: string, configuration?: Configuration) => <T = unknown, R = AxiosResponse<T, any>>(axios?: AxiosInstance, basePath?: string) => Promise<R>;
|
|
@@ -0,0 +1,149 @@
|
|
|
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
|
+
var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
|
|
15
|
+
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
|
|
16
|
+
return new (P || (P = Promise))(function (resolve, reject) {
|
|
17
|
+
function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
|
|
18
|
+
function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
|
|
19
|
+
function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
|
|
20
|
+
step((generator = generator.apply(thisArg, _arguments || [])).next());
|
|
21
|
+
});
|
|
22
|
+
};
|
|
23
|
+
import { RequiredError } from "./base";
|
|
24
|
+
/**
|
|
25
|
+
*
|
|
26
|
+
* @export
|
|
27
|
+
*/
|
|
28
|
+
export const DUMMY_BASE_URL = 'https://example.com';
|
|
29
|
+
/**
|
|
30
|
+
*
|
|
31
|
+
* @throws {RequiredError}
|
|
32
|
+
* @export
|
|
33
|
+
*/
|
|
34
|
+
export const assertParamExists = function (functionName, paramName, paramValue) {
|
|
35
|
+
if (paramValue === null || paramValue === undefined) {
|
|
36
|
+
throw new RequiredError(paramName, `Required parameter ${paramName} was null or undefined when calling ${functionName}.`);
|
|
37
|
+
}
|
|
38
|
+
};
|
|
39
|
+
/**
|
|
40
|
+
*
|
|
41
|
+
* @export
|
|
42
|
+
*/
|
|
43
|
+
export const setApiKeyToObject = function (object, keyParamName, configuration) {
|
|
44
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
45
|
+
if (configuration && configuration.apiKey) {
|
|
46
|
+
const localVarApiKeyValue = typeof configuration.apiKey === 'function'
|
|
47
|
+
? yield configuration.apiKey(keyParamName)
|
|
48
|
+
: yield configuration.apiKey;
|
|
49
|
+
object[keyParamName] = localVarApiKeyValue;
|
|
50
|
+
}
|
|
51
|
+
});
|
|
52
|
+
};
|
|
53
|
+
/**
|
|
54
|
+
*
|
|
55
|
+
* @export
|
|
56
|
+
*/
|
|
57
|
+
export const setBasicAuthToObject = function (object, configuration) {
|
|
58
|
+
if (configuration && (configuration.username || configuration.password)) {
|
|
59
|
+
object["auth"] = { username: configuration.username, password: configuration.password };
|
|
60
|
+
}
|
|
61
|
+
};
|
|
62
|
+
/**
|
|
63
|
+
*
|
|
64
|
+
* @export
|
|
65
|
+
*/
|
|
66
|
+
export const setBearerAuthToObject = function (object, configuration) {
|
|
67
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
68
|
+
if (configuration && configuration.accessToken) {
|
|
69
|
+
const accessToken = typeof configuration.accessToken === 'function'
|
|
70
|
+
? yield configuration.accessToken()
|
|
71
|
+
: yield configuration.accessToken;
|
|
72
|
+
object["Authorization"] = "Bearer " + accessToken;
|
|
73
|
+
}
|
|
74
|
+
});
|
|
75
|
+
};
|
|
76
|
+
/**
|
|
77
|
+
*
|
|
78
|
+
* @export
|
|
79
|
+
*/
|
|
80
|
+
export const setOAuthToObject = function (object, name, scopes, configuration) {
|
|
81
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
82
|
+
if (configuration && configuration.accessToken) {
|
|
83
|
+
const localVarAccessTokenValue = typeof configuration.accessToken === 'function'
|
|
84
|
+
? yield configuration.accessToken(name, scopes)
|
|
85
|
+
: yield configuration.accessToken;
|
|
86
|
+
object["Authorization"] = "Bearer " + localVarAccessTokenValue;
|
|
87
|
+
}
|
|
88
|
+
});
|
|
89
|
+
};
|
|
90
|
+
function setFlattenedQueryParams(urlSearchParams, parameter, key = "") {
|
|
91
|
+
if (parameter == null)
|
|
92
|
+
return;
|
|
93
|
+
if (typeof parameter === "object") {
|
|
94
|
+
if (Array.isArray(parameter)) {
|
|
95
|
+
parameter.forEach(item => setFlattenedQueryParams(urlSearchParams, item, key));
|
|
96
|
+
}
|
|
97
|
+
else {
|
|
98
|
+
Object.keys(parameter).forEach(currentKey => setFlattenedQueryParams(urlSearchParams, parameter[currentKey], `${key}${key !== '' ? '.' : ''}${currentKey}`));
|
|
99
|
+
}
|
|
100
|
+
}
|
|
101
|
+
else {
|
|
102
|
+
if (urlSearchParams.has(key)) {
|
|
103
|
+
urlSearchParams.append(key, parameter);
|
|
104
|
+
}
|
|
105
|
+
else {
|
|
106
|
+
urlSearchParams.set(key, parameter);
|
|
107
|
+
}
|
|
108
|
+
}
|
|
109
|
+
}
|
|
110
|
+
/**
|
|
111
|
+
*
|
|
112
|
+
* @export
|
|
113
|
+
*/
|
|
114
|
+
export const setSearchParams = function (url, ...objects) {
|
|
115
|
+
const searchParams = new URLSearchParams(url.search);
|
|
116
|
+
setFlattenedQueryParams(searchParams, objects);
|
|
117
|
+
url.search = searchParams.toString();
|
|
118
|
+
};
|
|
119
|
+
/**
|
|
120
|
+
*
|
|
121
|
+
* @export
|
|
122
|
+
*/
|
|
123
|
+
export const serializeDataIfNeeded = function (value, requestOptions, configuration) {
|
|
124
|
+
const nonString = typeof value !== 'string';
|
|
125
|
+
const needsSerialization = nonString && configuration && configuration.isJsonMime
|
|
126
|
+
? configuration.isJsonMime(requestOptions.headers['Content-Type'])
|
|
127
|
+
: nonString;
|
|
128
|
+
return needsSerialization
|
|
129
|
+
? JSON.stringify(value !== undefined ? value : {})
|
|
130
|
+
: (value || "");
|
|
131
|
+
};
|
|
132
|
+
/**
|
|
133
|
+
*
|
|
134
|
+
* @export
|
|
135
|
+
*/
|
|
136
|
+
export const toPathString = function (url) {
|
|
137
|
+
return url.pathname + url.search + url.hash;
|
|
138
|
+
};
|
|
139
|
+
/**
|
|
140
|
+
*
|
|
141
|
+
* @export
|
|
142
|
+
*/
|
|
143
|
+
export const createRequestFunction = function (axiosArgs, globalAxios, BASE_PATH, configuration) {
|
|
144
|
+
return (axios = globalAxios, basePath = BASE_PATH) => {
|
|
145
|
+
var _a;
|
|
146
|
+
const axiosRequestArgs = Object.assign(Object.assign({}, axiosArgs.options), { url: (axios.defaults.baseURL ? '' : (_a = configuration === null || configuration === void 0 ? void 0 : configuration.basePath) !== null && _a !== void 0 ? _a : basePath) + axiosArgs.url });
|
|
147
|
+
return axios.request(axiosRequestArgs);
|
|
148
|
+
};
|
|
149
|
+
};
|
|
@@ -0,0 +1,91 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Daytona Workspaces
|
|
3
|
+
* Daytona Workspaces API Docs
|
|
4
|
+
*
|
|
5
|
+
* The version of the OpenAPI document: 1.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
|
+
export interface ConfigurationParameters {
|
|
13
|
+
apiKey?: string | Promise<string> | ((name: string) => string) | ((name: string) => Promise<string>);
|
|
14
|
+
username?: string;
|
|
15
|
+
password?: string;
|
|
16
|
+
accessToken?: string | Promise<string> | ((name?: string, scopes?: string[]) => string) | ((name?: string, scopes?: string[]) => Promise<string>);
|
|
17
|
+
basePath?: string;
|
|
18
|
+
serverIndex?: number;
|
|
19
|
+
baseOptions?: any;
|
|
20
|
+
formDataCtor?: new () => any;
|
|
21
|
+
}
|
|
22
|
+
export declare class Configuration {
|
|
23
|
+
/**
|
|
24
|
+
* parameter for apiKey security
|
|
25
|
+
* @param name security name
|
|
26
|
+
* @memberof Configuration
|
|
27
|
+
*/
|
|
28
|
+
apiKey?: string | Promise<string> | ((name: string) => string) | ((name: string) => Promise<string>);
|
|
29
|
+
/**
|
|
30
|
+
* parameter for basic security
|
|
31
|
+
*
|
|
32
|
+
* @type {string}
|
|
33
|
+
* @memberof Configuration
|
|
34
|
+
*/
|
|
35
|
+
username?: string;
|
|
36
|
+
/**
|
|
37
|
+
* parameter for basic security
|
|
38
|
+
*
|
|
39
|
+
* @type {string}
|
|
40
|
+
* @memberof Configuration
|
|
41
|
+
*/
|
|
42
|
+
password?: string;
|
|
43
|
+
/**
|
|
44
|
+
* parameter for oauth2 security
|
|
45
|
+
* @param name security name
|
|
46
|
+
* @param scopes oauth2 scope
|
|
47
|
+
* @memberof Configuration
|
|
48
|
+
*/
|
|
49
|
+
accessToken?: string | Promise<string> | ((name?: string, scopes?: string[]) => string) | ((name?: string, scopes?: string[]) => Promise<string>);
|
|
50
|
+
/**
|
|
51
|
+
* override base path
|
|
52
|
+
*
|
|
53
|
+
* @type {string}
|
|
54
|
+
* @memberof Configuration
|
|
55
|
+
*/
|
|
56
|
+
basePath?: string;
|
|
57
|
+
/**
|
|
58
|
+
* override server index
|
|
59
|
+
*
|
|
60
|
+
* @type {number}
|
|
61
|
+
* @memberof Configuration
|
|
62
|
+
*/
|
|
63
|
+
serverIndex?: number;
|
|
64
|
+
/**
|
|
65
|
+
* base options for axios calls
|
|
66
|
+
*
|
|
67
|
+
* @type {any}
|
|
68
|
+
* @memberof Configuration
|
|
69
|
+
*/
|
|
70
|
+
baseOptions?: any;
|
|
71
|
+
/**
|
|
72
|
+
* The FormData constructor that will be used to create multipart form data
|
|
73
|
+
* requests. You can inject this here so that execution environments that
|
|
74
|
+
* do not support the FormData class can still run the generated client.
|
|
75
|
+
*
|
|
76
|
+
* @type {new () => FormData}
|
|
77
|
+
*/
|
|
78
|
+
formDataCtor?: new () => any;
|
|
79
|
+
constructor(param?: ConfigurationParameters);
|
|
80
|
+
/**
|
|
81
|
+
* Check if the given MIME is a JSON MIME.
|
|
82
|
+
* JSON MIME examples:
|
|
83
|
+
* application/json
|
|
84
|
+
* application/json; charset=UTF8
|
|
85
|
+
* APPLICATION/JSON
|
|
86
|
+
* application/vnd.company+json
|
|
87
|
+
* @param mime - MIME (Multipurpose Internet Mail Extensions)
|
|
88
|
+
* @return True if the given MIME is JSON, false otherwise.
|
|
89
|
+
*/
|
|
90
|
+
isJsonMime(mime: string): boolean;
|
|
91
|
+
}
|
|
@@ -0,0 +1,39 @@
|
|
|
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
|
+
export class Configuration {
|
|
15
|
+
constructor(param = {}) {
|
|
16
|
+
this.apiKey = param.apiKey;
|
|
17
|
+
this.username = param.username;
|
|
18
|
+
this.password = param.password;
|
|
19
|
+
this.accessToken = param.accessToken;
|
|
20
|
+
this.basePath = param.basePath;
|
|
21
|
+
this.serverIndex = param.serverIndex;
|
|
22
|
+
this.baseOptions = param.baseOptions;
|
|
23
|
+
this.formDataCtor = param.formDataCtor;
|
|
24
|
+
}
|
|
25
|
+
/**
|
|
26
|
+
* Check if the given MIME is a JSON MIME.
|
|
27
|
+
* JSON MIME examples:
|
|
28
|
+
* application/json
|
|
29
|
+
* application/json; charset=UTF8
|
|
30
|
+
* APPLICATION/JSON
|
|
31
|
+
* application/vnd.company+json
|
|
32
|
+
* @param mime - MIME (Multipurpose Internet Mail Extensions)
|
|
33
|
+
* @return True if the given MIME is JSON, false otherwise.
|
|
34
|
+
*/
|
|
35
|
+
isJsonMime(mime) {
|
|
36
|
+
const jsonMime = new RegExp('^(application\/json|[^;/ \t]+\/[^;/ \t]+[+]json)[ \t]*(;.*)?$', 'i');
|
|
37
|
+
return mime !== null && (jsonMime.test(mime) || mime.toLowerCase() === 'application/json-patch+json');
|
|
38
|
+
}
|
|
39
|
+
}
|
package/dist/esm/index.d.ts
CHANGED
|
@@ -1,3 +1,14 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
1
|
+
/**
|
|
2
|
+
* Daytona Workspaces
|
|
3
|
+
* Daytona Workspaces API Docs
|
|
4
|
+
*
|
|
5
|
+
* The version of the OpenAPI document: 1.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
|
+
export * from "./api";
|
|
13
|
+
export * from "./configuration";
|
|
14
|
+
export * from "./models";
|
package/dist/esm/index.js
CHANGED
|
@@ -1,5 +1,16 @@
|
|
|
1
1
|
/* tslint:disable */
|
|
2
2
|
/* eslint-disable */
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
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
|
+
export * from "./api";
|
|
15
|
+
export * from "./configuration";
|
|
16
|
+
export * from "./models";
|
|
@@ -20,25 +20,17 @@ export interface ApiKeyListDto {
|
|
|
20
20
|
* @type {string}
|
|
21
21
|
* @memberof ApiKeyListDto
|
|
22
22
|
*/
|
|
23
|
-
name: string;
|
|
23
|
+
'name': string;
|
|
24
24
|
/**
|
|
25
25
|
* The masked API key value
|
|
26
26
|
* @type {string}
|
|
27
27
|
* @memberof ApiKeyListDto
|
|
28
28
|
*/
|
|
29
|
-
value: string;
|
|
29
|
+
'value': string;
|
|
30
30
|
/**
|
|
31
31
|
* When the API key was created
|
|
32
|
-
* @type {
|
|
32
|
+
* @type {string}
|
|
33
33
|
* @memberof ApiKeyListDto
|
|
34
34
|
*/
|
|
35
|
-
createdAt:
|
|
35
|
+
'createdAt': string;
|
|
36
36
|
}
|
|
37
|
-
/**
|
|
38
|
-
* Check if a given object implements the ApiKeyListDto interface.
|
|
39
|
-
*/
|
|
40
|
-
export declare function instanceOfApiKeyListDto(value: object): value is ApiKeyListDto;
|
|
41
|
-
export declare function ApiKeyListDtoFromJSON(json: any): ApiKeyListDto;
|
|
42
|
-
export declare function ApiKeyListDtoFromJSONTyped(json: any, ignoreDiscriminator: boolean): ApiKeyListDto;
|
|
43
|
-
export declare function ApiKeyListDtoToJSON(json: any): ApiKeyListDto;
|
|
44
|
-
export declare function ApiKeyListDtoToJSONTyped(value?: ApiKeyListDto | null, ignoreDiscriminator?: boolean): any;
|
|
@@ -0,0 +1,14 @@
|
|
|
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
|
+
export {};
|
|
@@ -20,25 +20,17 @@ export interface ApiKeyResponseDto {
|
|
|
20
20
|
* @type {string}
|
|
21
21
|
* @memberof ApiKeyResponseDto
|
|
22
22
|
*/
|
|
23
|
-
name: string;
|
|
23
|
+
'name': string;
|
|
24
24
|
/**
|
|
25
25
|
* The API key value
|
|
26
26
|
* @type {string}
|
|
27
27
|
* @memberof ApiKeyResponseDto
|
|
28
28
|
*/
|
|
29
|
-
value: string;
|
|
29
|
+
'value': string;
|
|
30
30
|
/**
|
|
31
31
|
* When the API key was created
|
|
32
|
-
* @type {
|
|
32
|
+
* @type {string}
|
|
33
33
|
* @memberof ApiKeyResponseDto
|
|
34
34
|
*/
|
|
35
|
-
createdAt:
|
|
35
|
+
'createdAt': string;
|
|
36
36
|
}
|
|
37
|
-
/**
|
|
38
|
-
* Check if a given object implements the ApiKeyResponseDto interface.
|
|
39
|
-
*/
|
|
40
|
-
export declare function instanceOfApiKeyResponseDto(value: object): value is ApiKeyResponseDto;
|
|
41
|
-
export declare function ApiKeyResponseDtoFromJSON(json: any): ApiKeyResponseDto;
|
|
42
|
-
export declare function ApiKeyResponseDtoFromJSONTyped(json: any, ignoreDiscriminator: boolean): ApiKeyResponseDto;
|
|
43
|
-
export declare function ApiKeyResponseDtoToJSON(json: any): ApiKeyResponseDto;
|
|
44
|
-
export declare function ApiKeyResponseDtoToJSONTyped(value?: ApiKeyResponseDto | null, ignoreDiscriminator?: boolean): any;
|
|
@@ -0,0 +1,14 @@
|
|
|
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
|
+
export {};
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Daytona Workspaces
|
|
3
|
+
* Daytona Workspaces API Docs
|
|
4
|
+
*
|
|
5
|
+
* The version of the OpenAPI document: 1.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 CreateApiKeyDto
|
|
16
|
+
*/
|
|
17
|
+
export interface CreateApiKeyDto {
|
|
18
|
+
/**
|
|
19
|
+
* The name of the API key
|
|
20
|
+
* @type {string}
|
|
21
|
+
* @memberof CreateApiKeyDto
|
|
22
|
+
*/
|
|
23
|
+
'name': string;
|
|
24
|
+
}
|
|
@@ -0,0 +1,14 @@
|
|
|
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
|
+
export {};
|
package/dist/{models/CreateDockerRegistryDto.d.ts → esm/models/create-docker-registry-dto.d.ts}
RENAMED
|
@@ -20,43 +20,35 @@ export interface CreateDockerRegistryDto {
|
|
|
20
20
|
* @type {string}
|
|
21
21
|
* @memberof CreateDockerRegistryDto
|
|
22
22
|
*/
|
|
23
|
-
name: string;
|
|
23
|
+
'name': string;
|
|
24
24
|
/**
|
|
25
25
|
* Registry URL
|
|
26
26
|
* @type {string}
|
|
27
27
|
* @memberof CreateDockerRegistryDto
|
|
28
28
|
*/
|
|
29
|
-
url: string;
|
|
29
|
+
'url': string;
|
|
30
30
|
/**
|
|
31
31
|
* Registry username
|
|
32
32
|
* @type {string}
|
|
33
33
|
* @memberof CreateDockerRegistryDto
|
|
34
34
|
*/
|
|
35
|
-
username: string;
|
|
35
|
+
'username': string;
|
|
36
36
|
/**
|
|
37
37
|
* Registry password
|
|
38
38
|
* @type {string}
|
|
39
39
|
* @memberof CreateDockerRegistryDto
|
|
40
40
|
*/
|
|
41
|
-
password: string;
|
|
41
|
+
'password': string;
|
|
42
42
|
/**
|
|
43
43
|
* Registry project
|
|
44
44
|
* @type {string}
|
|
45
45
|
* @memberof CreateDockerRegistryDto
|
|
46
46
|
*/
|
|
47
|
-
project: string;
|
|
47
|
+
'project': string;
|
|
48
48
|
/**
|
|
49
49
|
* Set as default registry
|
|
50
50
|
* @type {boolean}
|
|
51
51
|
* @memberof CreateDockerRegistryDto
|
|
52
52
|
*/
|
|
53
|
-
isDefault?: boolean;
|
|
53
|
+
'isDefault'?: boolean;
|
|
54
54
|
}
|
|
55
|
-
/**
|
|
56
|
-
* Check if a given object implements the CreateDockerRegistryDto interface.
|
|
57
|
-
*/
|
|
58
|
-
export declare function instanceOfCreateDockerRegistryDto(value: object): value is CreateDockerRegistryDto;
|
|
59
|
-
export declare function CreateDockerRegistryDtoFromJSON(json: any): CreateDockerRegistryDto;
|
|
60
|
-
export declare function CreateDockerRegistryDtoFromJSONTyped(json: any, ignoreDiscriminator: boolean): CreateDockerRegistryDto;
|
|
61
|
-
export declare function CreateDockerRegistryDtoToJSON(json: any): CreateDockerRegistryDto;
|
|
62
|
-
export declare function CreateDockerRegistryDtoToJSONTyped(value?: CreateDockerRegistryDto | null, ignoreDiscriminator?: boolean): any;
|
|
@@ -0,0 +1,14 @@
|
|
|
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
|
+
export {};
|