@knowledge-stack/ksapi 1.65.7 → 1.65.8
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 +0 -2
- package/README.md +2 -4
- package/dist/apis/TenantsApi.d.ts +1 -45
- package/dist/apis/TenantsApi.js +0 -45
- package/dist/esm/apis/TenantsApi.d.ts +1 -45
- package/dist/esm/apis/TenantsApi.js +1 -46
- package/dist/esm/models/index.d.ts +0 -1
- package/dist/esm/models/index.js +0 -1
- package/dist/models/index.d.ts +0 -1
- package/dist/models/index.js +0 -1
- package/docs/TenantsApi.md +0 -75
- package/package.json +1 -1
- package/src/apis/TenantsApi.ts +0 -90
- package/src/models/index.ts +0 -1
- package/dist/esm/models/CreateTenantRequest.d.ts +0 -54
- package/dist/esm/models/CreateTenantRequest.js +0 -47
- package/dist/models/CreateTenantRequest.d.ts +0 -54
- package/dist/models/CreateTenantRequest.js +0 -55
- package/docs/CreateTenantRequest.md +0 -37
- package/src/models/CreateTenantRequest.ts +0 -99
package/.openapi-generator/FILES
CHANGED
|
@@ -39,7 +39,6 @@ docs/CreatePasswordUserRequest.md
|
|
|
39
39
|
docs/CreatePermissionRequest.md
|
|
40
40
|
docs/CreateSectionRequest.md
|
|
41
41
|
docs/CreateTagRequest.md
|
|
42
|
-
docs/CreateTenantRequest.md
|
|
43
42
|
docs/CreateThreadMessageRequest.md
|
|
44
43
|
docs/CreateThreadRequest.md
|
|
45
44
|
docs/CreateWorkflowDefinitionRequest.md
|
|
@@ -264,7 +263,6 @@ src/models/CreatePasswordUserRequest.ts
|
|
|
264
263
|
src/models/CreatePermissionRequest.ts
|
|
265
264
|
src/models/CreateSectionRequest.ts
|
|
266
265
|
src/models/CreateTagRequest.ts
|
|
267
|
-
src/models/CreateTenantRequest.ts
|
|
268
266
|
src/models/CreateThreadMessageRequest.ts
|
|
269
267
|
src/models/CreateThreadRequest.ts
|
|
270
268
|
src/models/CreateWorkflowDefinitionRequest.ts
|
package/README.md
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
# @knowledge-stack/ksapi@1.65.
|
|
1
|
+
# @knowledge-stack/ksapi@1.65.8
|
|
2
2
|
|
|
3
3
|
A TypeScript SDK client for the localhost API.
|
|
4
4
|
|
|
@@ -142,7 +142,6 @@ All URIs are relative to *http://localhost:8000*
|
|
|
142
142
|
*TenantGroupsApi* | [**removeGroupMember**](docs/TenantGroupsApi.md#removegroupmember) | **DELETE** /v1/tenant-groups/{group_id}/members/{user_id} | Remove Group Member Handler
|
|
143
143
|
*TenantGroupsApi* | [**updateGroupPermission**](docs/TenantGroupsApi.md#updategrouppermissionoperation) | **PATCH** /v1/tenant-groups/{group_id}/permissions/{permission_id} | Update Group Permission Handler
|
|
144
144
|
*TenantGroupsApi* | [**updateTenantGroup**](docs/TenantGroupsApi.md#updatetenantgroup) | **PATCH** /v1/tenant-groups/{group_id} | Update Tenant Group Handler
|
|
145
|
-
*TenantsApi* | [**createTenant**](docs/TenantsApi.md#createtenantoperation) | **POST** /v1/tenants | Create Tenant
|
|
146
145
|
*TenantsApi* | [**deleteTenant**](docs/TenantsApi.md#deletetenant) | **DELETE** /v1/tenants/{tenant_id} | Delete Tenant
|
|
147
146
|
*TenantsApi* | [**deleteTenantLogo**](docs/TenantsApi.md#deletetenantlogo) | **DELETE** /v1/tenants/{tenant_id}/branding/logo | Delete Tenant Logo
|
|
148
147
|
*TenantsApi* | [**deleteTenantUser**](docs/TenantsApi.md#deletetenantuser) | **DELETE** /v1/tenants/{tenant_id}/users/{user_id} | Delete Tenant User
|
|
@@ -220,7 +219,6 @@ All URIs are relative to *http://localhost:8000*
|
|
|
220
219
|
- [CreatePermissionRequest](docs/CreatePermissionRequest.md)
|
|
221
220
|
- [CreateSectionRequest](docs/CreateSectionRequest.md)
|
|
222
221
|
- [CreateTagRequest](docs/CreateTagRequest.md)
|
|
223
|
-
- [CreateTenantRequest](docs/CreateTenantRequest.md)
|
|
224
222
|
- [CreateThreadMessageRequest](docs/CreateThreadMessageRequest.md)
|
|
225
223
|
- [CreateThreadRequest](docs/CreateThreadRequest.md)
|
|
226
224
|
- [CreateWorkflowDefinitionRequest](docs/CreateWorkflowDefinitionRequest.md)
|
|
@@ -380,7 +378,7 @@ and is automatically generated by the
|
|
|
380
378
|
[OpenAPI Generator](https://openapi-generator.tech) project:
|
|
381
379
|
|
|
382
380
|
- API version: `0.1.0`
|
|
383
|
-
- Package version: `1.65.
|
|
381
|
+
- Package version: `1.65.8`
|
|
384
382
|
- Generator version: `7.20.0`
|
|
385
383
|
- Build package: `org.openapitools.codegen.languages.TypeScriptFetchClientCodegen`
|
|
386
384
|
|
|
@@ -10,12 +10,7 @@
|
|
|
10
10
|
* Do not edit the class manually.
|
|
11
11
|
*/
|
|
12
12
|
import * as runtime from '../runtime';
|
|
13
|
-
import type { BrandingLogoType,
|
|
14
|
-
export interface CreateTenantOperationRequest {
|
|
15
|
-
createTenantRequest: CreateTenantRequest;
|
|
16
|
-
authorization?: string | null;
|
|
17
|
-
ksUat?: string | null;
|
|
18
|
-
}
|
|
13
|
+
import type { BrandingLogoType, PaginatedResponseTenantResponse, PaginatedResponseTenantUserResponse, TenantResponse, TenantUserEditRequest, TenantUserResponse, UpdateTenantRequest } from '../models/index';
|
|
19
14
|
export interface DeleteTenantRequest {
|
|
20
15
|
tenantId: string;
|
|
21
16
|
authorization?: string | null;
|
|
@@ -78,31 +73,6 @@ export interface UploadTenantLogoRequest {
|
|
|
78
73
|
* @interface TenantsApiInterface
|
|
79
74
|
*/
|
|
80
75
|
export interface TenantsApiInterface {
|
|
81
|
-
/**
|
|
82
|
-
* Creates request options for createTenant without sending the request
|
|
83
|
-
* @param {CreateTenantRequest} createTenantRequest
|
|
84
|
-
* @param {string} [authorization]
|
|
85
|
-
* @param {string} [ksUat]
|
|
86
|
-
* @throws {RequiredError}
|
|
87
|
-
* @memberof TenantsApiInterface
|
|
88
|
-
*/
|
|
89
|
-
createTenantRequestOpts(requestParameters: CreateTenantOperationRequest): Promise<runtime.RequestOpts>;
|
|
90
|
-
/**
|
|
91
|
-
* Create a new tenant. The creator is automatically added as OWNER of the tenant.
|
|
92
|
-
* @summary Create Tenant
|
|
93
|
-
* @param {CreateTenantRequest} createTenantRequest
|
|
94
|
-
* @param {string} [authorization]
|
|
95
|
-
* @param {string} [ksUat]
|
|
96
|
-
* @param {*} [options] Override http request option.
|
|
97
|
-
* @throws {RequiredError}
|
|
98
|
-
* @memberof TenantsApiInterface
|
|
99
|
-
*/
|
|
100
|
-
createTenantRaw(requestParameters: CreateTenantOperationRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<TenantResponse>>;
|
|
101
|
-
/**
|
|
102
|
-
* Create a new tenant. The creator is automatically added as OWNER of the tenant.
|
|
103
|
-
* Create Tenant
|
|
104
|
-
*/
|
|
105
|
-
createTenant(requestParameters: CreateTenantOperationRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<TenantResponse>;
|
|
106
76
|
/**
|
|
107
77
|
* Creates request options for deleteTenant without sending the request
|
|
108
78
|
* @param {string} tenantId
|
|
@@ -353,20 +323,6 @@ export interface TenantsApiInterface {
|
|
|
353
323
|
*
|
|
354
324
|
*/
|
|
355
325
|
export declare class TenantsApi extends runtime.BaseAPI implements TenantsApiInterface {
|
|
356
|
-
/**
|
|
357
|
-
* Creates request options for createTenant without sending the request
|
|
358
|
-
*/
|
|
359
|
-
createTenantRequestOpts(requestParameters: CreateTenantOperationRequest): Promise<runtime.RequestOpts>;
|
|
360
|
-
/**
|
|
361
|
-
* Create a new tenant. The creator is automatically added as OWNER of the tenant.
|
|
362
|
-
* Create Tenant
|
|
363
|
-
*/
|
|
364
|
-
createTenantRaw(requestParameters: CreateTenantOperationRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<TenantResponse>>;
|
|
365
|
-
/**
|
|
366
|
-
* Create a new tenant. The creator is automatically added as OWNER of the tenant.
|
|
367
|
-
* Create Tenant
|
|
368
|
-
*/
|
|
369
|
-
createTenant(requestParameters: CreateTenantOperationRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<TenantResponse>;
|
|
370
326
|
/**
|
|
371
327
|
* Creates request options for deleteTenant without sending the request
|
|
372
328
|
*/
|
package/dist/apis/TenantsApi.js
CHANGED
|
@@ -29,51 +29,6 @@ const index_1 = require("../models/index");
|
|
|
29
29
|
*
|
|
30
30
|
*/
|
|
31
31
|
class TenantsApi extends runtime.BaseAPI {
|
|
32
|
-
/**
|
|
33
|
-
* Creates request options for createTenant without sending the request
|
|
34
|
-
*/
|
|
35
|
-
createTenantRequestOpts(requestParameters) {
|
|
36
|
-
return __awaiter(this, void 0, void 0, function* () {
|
|
37
|
-
if (requestParameters['createTenantRequest'] == null) {
|
|
38
|
-
throw new runtime.RequiredError('createTenantRequest', 'Required parameter "createTenantRequest" was null or undefined when calling createTenant().');
|
|
39
|
-
}
|
|
40
|
-
const queryParameters = {};
|
|
41
|
-
const headerParameters = {};
|
|
42
|
-
headerParameters['Content-Type'] = 'application/json';
|
|
43
|
-
if (requestParameters['authorization'] != null) {
|
|
44
|
-
headerParameters['authorization'] = String(requestParameters['authorization']);
|
|
45
|
-
}
|
|
46
|
-
let urlPath = `/v1/tenants`;
|
|
47
|
-
return {
|
|
48
|
-
path: urlPath,
|
|
49
|
-
method: 'POST',
|
|
50
|
-
headers: headerParameters,
|
|
51
|
-
query: queryParameters,
|
|
52
|
-
body: (0, index_1.CreateTenantRequestToJSON)(requestParameters['createTenantRequest']),
|
|
53
|
-
};
|
|
54
|
-
});
|
|
55
|
-
}
|
|
56
|
-
/**
|
|
57
|
-
* Create a new tenant. The creator is automatically added as OWNER of the tenant.
|
|
58
|
-
* Create Tenant
|
|
59
|
-
*/
|
|
60
|
-
createTenantRaw(requestParameters, initOverrides) {
|
|
61
|
-
return __awaiter(this, void 0, void 0, function* () {
|
|
62
|
-
const requestOptions = yield this.createTenantRequestOpts(requestParameters);
|
|
63
|
-
const response = yield this.request(requestOptions, initOverrides);
|
|
64
|
-
return new runtime.JSONApiResponse(response, (jsonValue) => (0, index_1.TenantResponseFromJSON)(jsonValue));
|
|
65
|
-
});
|
|
66
|
-
}
|
|
67
|
-
/**
|
|
68
|
-
* Create a new tenant. The creator is automatically added as OWNER of the tenant.
|
|
69
|
-
* Create Tenant
|
|
70
|
-
*/
|
|
71
|
-
createTenant(requestParameters, initOverrides) {
|
|
72
|
-
return __awaiter(this, void 0, void 0, function* () {
|
|
73
|
-
const response = yield this.createTenantRaw(requestParameters, initOverrides);
|
|
74
|
-
return yield response.value();
|
|
75
|
-
});
|
|
76
|
-
}
|
|
77
32
|
/**
|
|
78
33
|
* Creates request options for deleteTenant without sending the request
|
|
79
34
|
*/
|
|
@@ -10,12 +10,7 @@
|
|
|
10
10
|
* Do not edit the class manually.
|
|
11
11
|
*/
|
|
12
12
|
import * as runtime from '../runtime';
|
|
13
|
-
import type { BrandingLogoType,
|
|
14
|
-
export interface CreateTenantOperationRequest {
|
|
15
|
-
createTenantRequest: CreateTenantRequest;
|
|
16
|
-
authorization?: string | null;
|
|
17
|
-
ksUat?: string | null;
|
|
18
|
-
}
|
|
13
|
+
import type { BrandingLogoType, PaginatedResponseTenantResponse, PaginatedResponseTenantUserResponse, TenantResponse, TenantUserEditRequest, TenantUserResponse, UpdateTenantRequest } from '../models/index';
|
|
19
14
|
export interface DeleteTenantRequest {
|
|
20
15
|
tenantId: string;
|
|
21
16
|
authorization?: string | null;
|
|
@@ -78,31 +73,6 @@ export interface UploadTenantLogoRequest {
|
|
|
78
73
|
* @interface TenantsApiInterface
|
|
79
74
|
*/
|
|
80
75
|
export interface TenantsApiInterface {
|
|
81
|
-
/**
|
|
82
|
-
* Creates request options for createTenant without sending the request
|
|
83
|
-
* @param {CreateTenantRequest} createTenantRequest
|
|
84
|
-
* @param {string} [authorization]
|
|
85
|
-
* @param {string} [ksUat]
|
|
86
|
-
* @throws {RequiredError}
|
|
87
|
-
* @memberof TenantsApiInterface
|
|
88
|
-
*/
|
|
89
|
-
createTenantRequestOpts(requestParameters: CreateTenantOperationRequest): Promise<runtime.RequestOpts>;
|
|
90
|
-
/**
|
|
91
|
-
* Create a new tenant. The creator is automatically added as OWNER of the tenant.
|
|
92
|
-
* @summary Create Tenant
|
|
93
|
-
* @param {CreateTenantRequest} createTenantRequest
|
|
94
|
-
* @param {string} [authorization]
|
|
95
|
-
* @param {string} [ksUat]
|
|
96
|
-
* @param {*} [options] Override http request option.
|
|
97
|
-
* @throws {RequiredError}
|
|
98
|
-
* @memberof TenantsApiInterface
|
|
99
|
-
*/
|
|
100
|
-
createTenantRaw(requestParameters: CreateTenantOperationRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<TenantResponse>>;
|
|
101
|
-
/**
|
|
102
|
-
* Create a new tenant. The creator is automatically added as OWNER of the tenant.
|
|
103
|
-
* Create Tenant
|
|
104
|
-
*/
|
|
105
|
-
createTenant(requestParameters: CreateTenantOperationRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<TenantResponse>;
|
|
106
76
|
/**
|
|
107
77
|
* Creates request options for deleteTenant without sending the request
|
|
108
78
|
* @param {string} tenantId
|
|
@@ -353,20 +323,6 @@ export interface TenantsApiInterface {
|
|
|
353
323
|
*
|
|
354
324
|
*/
|
|
355
325
|
export declare class TenantsApi extends runtime.BaseAPI implements TenantsApiInterface {
|
|
356
|
-
/**
|
|
357
|
-
* Creates request options for createTenant without sending the request
|
|
358
|
-
*/
|
|
359
|
-
createTenantRequestOpts(requestParameters: CreateTenantOperationRequest): Promise<runtime.RequestOpts>;
|
|
360
|
-
/**
|
|
361
|
-
* Create a new tenant. The creator is automatically added as OWNER of the tenant.
|
|
362
|
-
* Create Tenant
|
|
363
|
-
*/
|
|
364
|
-
createTenantRaw(requestParameters: CreateTenantOperationRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<TenantResponse>>;
|
|
365
|
-
/**
|
|
366
|
-
* Create a new tenant. The creator is automatically added as OWNER of the tenant.
|
|
367
|
-
* Create Tenant
|
|
368
|
-
*/
|
|
369
|
-
createTenant(requestParameters: CreateTenantOperationRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<TenantResponse>;
|
|
370
326
|
/**
|
|
371
327
|
* Creates request options for deleteTenant without sending the request
|
|
372
328
|
*/
|
|
@@ -21,56 +21,11 @@ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, ge
|
|
|
21
21
|
});
|
|
22
22
|
};
|
|
23
23
|
import * as runtime from '../runtime';
|
|
24
|
-
import {
|
|
24
|
+
import { PaginatedResponseTenantResponseFromJSON, PaginatedResponseTenantUserResponseFromJSON, TenantResponseFromJSON, TenantUserEditRequestToJSON, TenantUserResponseFromJSON, UpdateTenantRequestToJSON, } from '../models/index';
|
|
25
25
|
/**
|
|
26
26
|
*
|
|
27
27
|
*/
|
|
28
28
|
export class TenantsApi extends runtime.BaseAPI {
|
|
29
|
-
/**
|
|
30
|
-
* Creates request options for createTenant without sending the request
|
|
31
|
-
*/
|
|
32
|
-
createTenantRequestOpts(requestParameters) {
|
|
33
|
-
return __awaiter(this, void 0, void 0, function* () {
|
|
34
|
-
if (requestParameters['createTenantRequest'] == null) {
|
|
35
|
-
throw new runtime.RequiredError('createTenantRequest', 'Required parameter "createTenantRequest" was null or undefined when calling createTenant().');
|
|
36
|
-
}
|
|
37
|
-
const queryParameters = {};
|
|
38
|
-
const headerParameters = {};
|
|
39
|
-
headerParameters['Content-Type'] = 'application/json';
|
|
40
|
-
if (requestParameters['authorization'] != null) {
|
|
41
|
-
headerParameters['authorization'] = String(requestParameters['authorization']);
|
|
42
|
-
}
|
|
43
|
-
let urlPath = `/v1/tenants`;
|
|
44
|
-
return {
|
|
45
|
-
path: urlPath,
|
|
46
|
-
method: 'POST',
|
|
47
|
-
headers: headerParameters,
|
|
48
|
-
query: queryParameters,
|
|
49
|
-
body: CreateTenantRequestToJSON(requestParameters['createTenantRequest']),
|
|
50
|
-
};
|
|
51
|
-
});
|
|
52
|
-
}
|
|
53
|
-
/**
|
|
54
|
-
* Create a new tenant. The creator is automatically added as OWNER of the tenant.
|
|
55
|
-
* Create Tenant
|
|
56
|
-
*/
|
|
57
|
-
createTenantRaw(requestParameters, initOverrides) {
|
|
58
|
-
return __awaiter(this, void 0, void 0, function* () {
|
|
59
|
-
const requestOptions = yield this.createTenantRequestOpts(requestParameters);
|
|
60
|
-
const response = yield this.request(requestOptions, initOverrides);
|
|
61
|
-
return new runtime.JSONApiResponse(response, (jsonValue) => TenantResponseFromJSON(jsonValue));
|
|
62
|
-
});
|
|
63
|
-
}
|
|
64
|
-
/**
|
|
65
|
-
* Create a new tenant. The creator is automatically added as OWNER of the tenant.
|
|
66
|
-
* Create Tenant
|
|
67
|
-
*/
|
|
68
|
-
createTenant(requestParameters, initOverrides) {
|
|
69
|
-
return __awaiter(this, void 0, void 0, function* () {
|
|
70
|
-
const response = yield this.createTenantRaw(requestParameters, initOverrides);
|
|
71
|
-
return yield response.value();
|
|
72
|
-
});
|
|
73
|
-
}
|
|
74
29
|
/**
|
|
75
30
|
* Creates request options for deleteTenant without sending the request
|
|
76
31
|
*/
|
|
@@ -31,7 +31,6 @@ export * from './CreatePasswordUserRequest';
|
|
|
31
31
|
export * from './CreatePermissionRequest';
|
|
32
32
|
export * from './CreateSectionRequest';
|
|
33
33
|
export * from './CreateTagRequest';
|
|
34
|
-
export * from './CreateTenantRequest';
|
|
35
34
|
export * from './CreateThreadMessageRequest';
|
|
36
35
|
export * from './CreateThreadRequest';
|
|
37
36
|
export * from './CreateWorkflowDefinitionRequest';
|
package/dist/esm/models/index.js
CHANGED
|
@@ -33,7 +33,6 @@ export * from './CreatePasswordUserRequest';
|
|
|
33
33
|
export * from './CreatePermissionRequest';
|
|
34
34
|
export * from './CreateSectionRequest';
|
|
35
35
|
export * from './CreateTagRequest';
|
|
36
|
-
export * from './CreateTenantRequest';
|
|
37
36
|
export * from './CreateThreadMessageRequest';
|
|
38
37
|
export * from './CreateThreadRequest';
|
|
39
38
|
export * from './CreateWorkflowDefinitionRequest';
|
package/dist/models/index.d.ts
CHANGED
|
@@ -31,7 +31,6 @@ export * from './CreatePasswordUserRequest';
|
|
|
31
31
|
export * from './CreatePermissionRequest';
|
|
32
32
|
export * from './CreateSectionRequest';
|
|
33
33
|
export * from './CreateTagRequest';
|
|
34
|
-
export * from './CreateTenantRequest';
|
|
35
34
|
export * from './CreateThreadMessageRequest';
|
|
36
35
|
export * from './CreateThreadRequest';
|
|
37
36
|
export * from './CreateWorkflowDefinitionRequest';
|
package/dist/models/index.js
CHANGED
|
@@ -49,7 +49,6 @@ __exportStar(require("./CreatePasswordUserRequest"), exports);
|
|
|
49
49
|
__exportStar(require("./CreatePermissionRequest"), exports);
|
|
50
50
|
__exportStar(require("./CreateSectionRequest"), exports);
|
|
51
51
|
__exportStar(require("./CreateTagRequest"), exports);
|
|
52
|
-
__exportStar(require("./CreateTenantRequest"), exports);
|
|
53
52
|
__exportStar(require("./CreateThreadMessageRequest"), exports);
|
|
54
53
|
__exportStar(require("./CreateThreadRequest"), exports);
|
|
55
54
|
__exportStar(require("./CreateWorkflowDefinitionRequest"), exports);
|
package/docs/TenantsApi.md
CHANGED
|
@@ -4,7 +4,6 @@ All URIs are relative to *http://localhost:8000*
|
|
|
4
4
|
|
|
5
5
|
| Method | HTTP request | Description |
|
|
6
6
|
|------------- | ------------- | -------------|
|
|
7
|
-
| [**createTenant**](TenantsApi.md#createtenantoperation) | **POST** /v1/tenants | Create Tenant |
|
|
8
7
|
| [**deleteTenant**](TenantsApi.md#deletetenant) | **DELETE** /v1/tenants/{tenant_id} | Delete Tenant |
|
|
9
8
|
| [**deleteTenantLogo**](TenantsApi.md#deletetenantlogo) | **DELETE** /v1/tenants/{tenant_id}/branding/logo | Delete Tenant Logo |
|
|
10
9
|
| [**deleteTenantUser**](TenantsApi.md#deletetenantuser) | **DELETE** /v1/tenants/{tenant_id}/users/{user_id} | Delete Tenant User |
|
|
@@ -17,80 +16,6 @@ All URIs are relative to *http://localhost:8000*
|
|
|
17
16
|
|
|
18
17
|
|
|
19
18
|
|
|
20
|
-
## createTenant
|
|
21
|
-
|
|
22
|
-
> TenantResponse createTenant(createTenantRequest, authorization, ksUat)
|
|
23
|
-
|
|
24
|
-
Create Tenant
|
|
25
|
-
|
|
26
|
-
Create a new tenant. The creator is automatically added as OWNER of the tenant.
|
|
27
|
-
|
|
28
|
-
### Example
|
|
29
|
-
|
|
30
|
-
```ts
|
|
31
|
-
import {
|
|
32
|
-
Configuration,
|
|
33
|
-
TenantsApi,
|
|
34
|
-
} from '@knowledge-stack/ksapi';
|
|
35
|
-
import type { CreateTenantOperationRequest } from '@knowledge-stack/ksapi';
|
|
36
|
-
|
|
37
|
-
async function example() {
|
|
38
|
-
console.log("🚀 Testing @knowledge-stack/ksapi SDK...");
|
|
39
|
-
const api = new TenantsApi();
|
|
40
|
-
|
|
41
|
-
const body = {
|
|
42
|
-
// CreateTenantRequest
|
|
43
|
-
createTenantRequest: ...,
|
|
44
|
-
// string (optional)
|
|
45
|
-
authorization: authorization_example,
|
|
46
|
-
// string (optional)
|
|
47
|
-
ksUat: ksUat_example,
|
|
48
|
-
} satisfies CreateTenantOperationRequest;
|
|
49
|
-
|
|
50
|
-
try {
|
|
51
|
-
const data = await api.createTenant(body);
|
|
52
|
-
console.log(data);
|
|
53
|
-
} catch (error) {
|
|
54
|
-
console.error(error);
|
|
55
|
-
}
|
|
56
|
-
}
|
|
57
|
-
|
|
58
|
-
// Run the test
|
|
59
|
-
example().catch(console.error);
|
|
60
|
-
```
|
|
61
|
-
|
|
62
|
-
### Parameters
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
| Name | Type | Description | Notes |
|
|
66
|
-
|------------- | ------------- | ------------- | -------------|
|
|
67
|
-
| **createTenantRequest** | [CreateTenantRequest](CreateTenantRequest.md) | | |
|
|
68
|
-
| **authorization** | `string` | | [Optional] [Defaults to `undefined`] |
|
|
69
|
-
| **ksUat** | `string` | | [Optional] [Defaults to `undefined`] |
|
|
70
|
-
|
|
71
|
-
### Return type
|
|
72
|
-
|
|
73
|
-
[**TenantResponse**](TenantResponse.md)
|
|
74
|
-
|
|
75
|
-
### Authorization
|
|
76
|
-
|
|
77
|
-
No authorization required
|
|
78
|
-
|
|
79
|
-
### HTTP request headers
|
|
80
|
-
|
|
81
|
-
- **Content-Type**: `application/json`
|
|
82
|
-
- **Accept**: `application/json`
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
### HTTP response details
|
|
86
|
-
| Status code | Description | Response headers |
|
|
87
|
-
|-------------|-------------|------------------|
|
|
88
|
-
| **201** | Successful Response | - |
|
|
89
|
-
| **422** | Validation Error | - |
|
|
90
|
-
|
|
91
|
-
[[Back to top]](#) [[Back to API list]](../README.md#api-endpoints) [[Back to Model list]](../README.md#models) [[Back to README]](../README.md)
|
|
92
|
-
|
|
93
|
-
|
|
94
19
|
## deleteTenant
|
|
95
20
|
|
|
96
21
|
> deleteTenant(tenantId, authorization, ksUat)
|
package/package.json
CHANGED
package/src/apis/TenantsApi.ts
CHANGED
|
@@ -16,7 +16,6 @@
|
|
|
16
16
|
import * as runtime from '../runtime';
|
|
17
17
|
import type {
|
|
18
18
|
BrandingLogoType,
|
|
19
|
-
CreateTenantRequest,
|
|
20
19
|
HTTPValidationError,
|
|
21
20
|
PaginatedResponseTenantResponse,
|
|
22
21
|
PaginatedResponseTenantUserResponse,
|
|
@@ -28,8 +27,6 @@ import type {
|
|
|
28
27
|
import {
|
|
29
28
|
BrandingLogoTypeFromJSON,
|
|
30
29
|
BrandingLogoTypeToJSON,
|
|
31
|
-
CreateTenantRequestFromJSON,
|
|
32
|
-
CreateTenantRequestToJSON,
|
|
33
30
|
HTTPValidationErrorFromJSON,
|
|
34
31
|
HTTPValidationErrorToJSON,
|
|
35
32
|
PaginatedResponseTenantResponseFromJSON,
|
|
@@ -46,12 +43,6 @@ import {
|
|
|
46
43
|
UpdateTenantRequestToJSON,
|
|
47
44
|
} from '../models/index';
|
|
48
45
|
|
|
49
|
-
export interface CreateTenantOperationRequest {
|
|
50
|
-
createTenantRequest: CreateTenantRequest;
|
|
51
|
-
authorization?: string | null;
|
|
52
|
-
ksUat?: string | null;
|
|
53
|
-
}
|
|
54
|
-
|
|
55
46
|
export interface DeleteTenantRequest {
|
|
56
47
|
tenantId: string;
|
|
57
48
|
authorization?: string | null;
|
|
@@ -123,34 +114,6 @@ export interface UploadTenantLogoRequest {
|
|
|
123
114
|
* @interface TenantsApiInterface
|
|
124
115
|
*/
|
|
125
116
|
export interface TenantsApiInterface {
|
|
126
|
-
/**
|
|
127
|
-
* Creates request options for createTenant without sending the request
|
|
128
|
-
* @param {CreateTenantRequest} createTenantRequest
|
|
129
|
-
* @param {string} [authorization]
|
|
130
|
-
* @param {string} [ksUat]
|
|
131
|
-
* @throws {RequiredError}
|
|
132
|
-
* @memberof TenantsApiInterface
|
|
133
|
-
*/
|
|
134
|
-
createTenantRequestOpts(requestParameters: CreateTenantOperationRequest): Promise<runtime.RequestOpts>;
|
|
135
|
-
|
|
136
|
-
/**
|
|
137
|
-
* Create a new tenant. The creator is automatically added as OWNER of the tenant.
|
|
138
|
-
* @summary Create Tenant
|
|
139
|
-
* @param {CreateTenantRequest} createTenantRequest
|
|
140
|
-
* @param {string} [authorization]
|
|
141
|
-
* @param {string} [ksUat]
|
|
142
|
-
* @param {*} [options] Override http request option.
|
|
143
|
-
* @throws {RequiredError}
|
|
144
|
-
* @memberof TenantsApiInterface
|
|
145
|
-
*/
|
|
146
|
-
createTenantRaw(requestParameters: CreateTenantOperationRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<TenantResponse>>;
|
|
147
|
-
|
|
148
|
-
/**
|
|
149
|
-
* Create a new tenant. The creator is automatically added as OWNER of the tenant.
|
|
150
|
-
* Create Tenant
|
|
151
|
-
*/
|
|
152
|
-
createTenant(requestParameters: CreateTenantOperationRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<TenantResponse>;
|
|
153
|
-
|
|
154
117
|
/**
|
|
155
118
|
* Creates request options for deleteTenant without sending the request
|
|
156
119
|
* @param {string} tenantId
|
|
@@ -430,59 +393,6 @@ export interface TenantsApiInterface {
|
|
|
430
393
|
*/
|
|
431
394
|
export class TenantsApi extends runtime.BaseAPI implements TenantsApiInterface {
|
|
432
395
|
|
|
433
|
-
/**
|
|
434
|
-
* Creates request options for createTenant without sending the request
|
|
435
|
-
*/
|
|
436
|
-
async createTenantRequestOpts(requestParameters: CreateTenantOperationRequest): Promise<runtime.RequestOpts> {
|
|
437
|
-
if (requestParameters['createTenantRequest'] == null) {
|
|
438
|
-
throw new runtime.RequiredError(
|
|
439
|
-
'createTenantRequest',
|
|
440
|
-
'Required parameter "createTenantRequest" was null or undefined when calling createTenant().'
|
|
441
|
-
);
|
|
442
|
-
}
|
|
443
|
-
|
|
444
|
-
const queryParameters: any = {};
|
|
445
|
-
|
|
446
|
-
const headerParameters: runtime.HTTPHeaders = {};
|
|
447
|
-
|
|
448
|
-
headerParameters['Content-Type'] = 'application/json';
|
|
449
|
-
|
|
450
|
-
if (requestParameters['authorization'] != null) {
|
|
451
|
-
headerParameters['authorization'] = String(requestParameters['authorization']);
|
|
452
|
-
}
|
|
453
|
-
|
|
454
|
-
|
|
455
|
-
let urlPath = `/v1/tenants`;
|
|
456
|
-
|
|
457
|
-
return {
|
|
458
|
-
path: urlPath,
|
|
459
|
-
method: 'POST',
|
|
460
|
-
headers: headerParameters,
|
|
461
|
-
query: queryParameters,
|
|
462
|
-
body: CreateTenantRequestToJSON(requestParameters['createTenantRequest']),
|
|
463
|
-
};
|
|
464
|
-
}
|
|
465
|
-
|
|
466
|
-
/**
|
|
467
|
-
* Create a new tenant. The creator is automatically added as OWNER of the tenant.
|
|
468
|
-
* Create Tenant
|
|
469
|
-
*/
|
|
470
|
-
async createTenantRaw(requestParameters: CreateTenantOperationRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<TenantResponse>> {
|
|
471
|
-
const requestOptions = await this.createTenantRequestOpts(requestParameters);
|
|
472
|
-
const response = await this.request(requestOptions, initOverrides);
|
|
473
|
-
|
|
474
|
-
return new runtime.JSONApiResponse(response, (jsonValue) => TenantResponseFromJSON(jsonValue));
|
|
475
|
-
}
|
|
476
|
-
|
|
477
|
-
/**
|
|
478
|
-
* Create a new tenant. The creator is automatically added as OWNER of the tenant.
|
|
479
|
-
* Create Tenant
|
|
480
|
-
*/
|
|
481
|
-
async createTenant(requestParameters: CreateTenantOperationRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<TenantResponse> {
|
|
482
|
-
const response = await this.createTenantRaw(requestParameters, initOverrides);
|
|
483
|
-
return await response.value();
|
|
484
|
-
}
|
|
485
|
-
|
|
486
396
|
/**
|
|
487
397
|
* Creates request options for deleteTenant without sending the request
|
|
488
398
|
*/
|
package/src/models/index.ts
CHANGED
|
@@ -33,7 +33,6 @@ export * from './CreatePasswordUserRequest';
|
|
|
33
33
|
export * from './CreatePermissionRequest';
|
|
34
34
|
export * from './CreateSectionRequest';
|
|
35
35
|
export * from './CreateTagRequest';
|
|
36
|
-
export * from './CreateTenantRequest';
|
|
37
36
|
export * from './CreateThreadMessageRequest';
|
|
38
37
|
export * from './CreateThreadRequest';
|
|
39
38
|
export * from './CreateWorkflowDefinitionRequest';
|
|
@@ -1,54 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Knowledge Stack API
|
|
3
|
-
* Knowledge Stack backend API for authentication and knowledge management
|
|
4
|
-
*
|
|
5
|
-
* The version of the OpenAPI document: 0.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 { OAuth2Config } from './OAuth2Config';
|
|
13
|
-
/**
|
|
14
|
-
* Create tenant request model.
|
|
15
|
-
* @export
|
|
16
|
-
* @interface CreateTenantRequest
|
|
17
|
-
*/
|
|
18
|
-
export interface CreateTenantRequest {
|
|
19
|
-
/**
|
|
20
|
-
* Tenant name
|
|
21
|
-
* @type {string}
|
|
22
|
-
* @memberof CreateTenantRequest
|
|
23
|
-
*/
|
|
24
|
-
name: string;
|
|
25
|
-
/**
|
|
26
|
-
*
|
|
27
|
-
* @type {OAuth2Config}
|
|
28
|
-
* @memberof CreateTenantRequest
|
|
29
|
-
*/
|
|
30
|
-
idpConfig?: OAuth2Config;
|
|
31
|
-
}
|
|
32
|
-
/**
|
|
33
|
-
* Check if a given object implements the CreateTenantRequest interface.
|
|
34
|
-
*/
|
|
35
|
-
export declare function instanceOfCreateTenantRequest(value: object): value is CreateTenantRequest;
|
|
36
|
-
export declare function CreateTenantRequestFromJSON(json: any): CreateTenantRequest;
|
|
37
|
-
export declare function CreateTenantRequestFromJSONTyped(json: any, ignoreDiscriminator: boolean): CreateTenantRequest;
|
|
38
|
-
export declare function CreateTenantRequestToJSON(json: any): CreateTenantRequest;
|
|
39
|
-
export declare function CreateTenantRequestToJSONTyped(value?: CreateTenantRequest | null, ignoreDiscriminator?: boolean): any;
|
|
40
|
-
export declare const CreateTenantRequestPropertyValidationAttributesMap: {
|
|
41
|
-
[property: string]: {
|
|
42
|
-
maxLength?: number;
|
|
43
|
-
minLength?: number;
|
|
44
|
-
pattern?: string;
|
|
45
|
-
maximum?: number;
|
|
46
|
-
exclusiveMaximum?: boolean;
|
|
47
|
-
minimum?: number;
|
|
48
|
-
exclusiveMinimum?: boolean;
|
|
49
|
-
multipleOf?: number;
|
|
50
|
-
maxItems?: number;
|
|
51
|
-
minItems?: number;
|
|
52
|
-
uniqueItems?: boolean;
|
|
53
|
-
};
|
|
54
|
-
};
|
|
@@ -1,47 +0,0 @@
|
|
|
1
|
-
/* tslint:disable */
|
|
2
|
-
/* eslint-disable */
|
|
3
|
-
/**
|
|
4
|
-
* Knowledge Stack API
|
|
5
|
-
* Knowledge Stack backend API for authentication and knowledge management
|
|
6
|
-
*
|
|
7
|
-
* The version of the OpenAPI document: 0.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 { OAuth2ConfigFromJSON, OAuth2ConfigToJSON, } from './OAuth2Config';
|
|
15
|
-
/**
|
|
16
|
-
* Check if a given object implements the CreateTenantRequest interface.
|
|
17
|
-
*/
|
|
18
|
-
export function instanceOfCreateTenantRequest(value) {
|
|
19
|
-
if (!('name' in value) || value['name'] === undefined)
|
|
20
|
-
return false;
|
|
21
|
-
return true;
|
|
22
|
-
}
|
|
23
|
-
export function CreateTenantRequestFromJSON(json) {
|
|
24
|
-
return CreateTenantRequestFromJSONTyped(json, false);
|
|
25
|
-
}
|
|
26
|
-
export function CreateTenantRequestFromJSONTyped(json, ignoreDiscriminator) {
|
|
27
|
-
if (json == null) {
|
|
28
|
-
return json;
|
|
29
|
-
}
|
|
30
|
-
return {
|
|
31
|
-
'name': json['name'],
|
|
32
|
-
'idpConfig': json['idp_config'] == null ? undefined : OAuth2ConfigFromJSON(json['idp_config']),
|
|
33
|
-
};
|
|
34
|
-
}
|
|
35
|
-
export function CreateTenantRequestToJSON(json) {
|
|
36
|
-
return CreateTenantRequestToJSONTyped(json, false);
|
|
37
|
-
}
|
|
38
|
-
export function CreateTenantRequestToJSONTyped(value, ignoreDiscriminator = false) {
|
|
39
|
-
if (value == null) {
|
|
40
|
-
return value;
|
|
41
|
-
}
|
|
42
|
-
return {
|
|
43
|
-
'name': value['name'],
|
|
44
|
-
'idp_config': OAuth2ConfigToJSON(value['idpConfig']),
|
|
45
|
-
};
|
|
46
|
-
}
|
|
47
|
-
export const CreateTenantRequestPropertyValidationAttributesMap = {};
|
|
@@ -1,54 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Knowledge Stack API
|
|
3
|
-
* Knowledge Stack backend API for authentication and knowledge management
|
|
4
|
-
*
|
|
5
|
-
* The version of the OpenAPI document: 0.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 { OAuth2Config } from './OAuth2Config';
|
|
13
|
-
/**
|
|
14
|
-
* Create tenant request model.
|
|
15
|
-
* @export
|
|
16
|
-
* @interface CreateTenantRequest
|
|
17
|
-
*/
|
|
18
|
-
export interface CreateTenantRequest {
|
|
19
|
-
/**
|
|
20
|
-
* Tenant name
|
|
21
|
-
* @type {string}
|
|
22
|
-
* @memberof CreateTenantRequest
|
|
23
|
-
*/
|
|
24
|
-
name: string;
|
|
25
|
-
/**
|
|
26
|
-
*
|
|
27
|
-
* @type {OAuth2Config}
|
|
28
|
-
* @memberof CreateTenantRequest
|
|
29
|
-
*/
|
|
30
|
-
idpConfig?: OAuth2Config;
|
|
31
|
-
}
|
|
32
|
-
/**
|
|
33
|
-
* Check if a given object implements the CreateTenantRequest interface.
|
|
34
|
-
*/
|
|
35
|
-
export declare function instanceOfCreateTenantRequest(value: object): value is CreateTenantRequest;
|
|
36
|
-
export declare function CreateTenantRequestFromJSON(json: any): CreateTenantRequest;
|
|
37
|
-
export declare function CreateTenantRequestFromJSONTyped(json: any, ignoreDiscriminator: boolean): CreateTenantRequest;
|
|
38
|
-
export declare function CreateTenantRequestToJSON(json: any): CreateTenantRequest;
|
|
39
|
-
export declare function CreateTenantRequestToJSONTyped(value?: CreateTenantRequest | null, ignoreDiscriminator?: boolean): any;
|
|
40
|
-
export declare const CreateTenantRequestPropertyValidationAttributesMap: {
|
|
41
|
-
[property: string]: {
|
|
42
|
-
maxLength?: number;
|
|
43
|
-
minLength?: number;
|
|
44
|
-
pattern?: string;
|
|
45
|
-
maximum?: number;
|
|
46
|
-
exclusiveMaximum?: boolean;
|
|
47
|
-
minimum?: number;
|
|
48
|
-
exclusiveMinimum?: boolean;
|
|
49
|
-
multipleOf?: number;
|
|
50
|
-
maxItems?: number;
|
|
51
|
-
minItems?: number;
|
|
52
|
-
uniqueItems?: boolean;
|
|
53
|
-
};
|
|
54
|
-
};
|
|
@@ -1,55 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
/* tslint:disable */
|
|
3
|
-
/* eslint-disable */
|
|
4
|
-
/**
|
|
5
|
-
* Knowledge Stack API
|
|
6
|
-
* Knowledge Stack backend API for authentication and knowledge management
|
|
7
|
-
*
|
|
8
|
-
* The version of the OpenAPI document: 0.1.0
|
|
9
|
-
*
|
|
10
|
-
*
|
|
11
|
-
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
12
|
-
* https://openapi-generator.tech
|
|
13
|
-
* Do not edit the class manually.
|
|
14
|
-
*/
|
|
15
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
16
|
-
exports.CreateTenantRequestPropertyValidationAttributesMap = void 0;
|
|
17
|
-
exports.instanceOfCreateTenantRequest = instanceOfCreateTenantRequest;
|
|
18
|
-
exports.CreateTenantRequestFromJSON = CreateTenantRequestFromJSON;
|
|
19
|
-
exports.CreateTenantRequestFromJSONTyped = CreateTenantRequestFromJSONTyped;
|
|
20
|
-
exports.CreateTenantRequestToJSON = CreateTenantRequestToJSON;
|
|
21
|
-
exports.CreateTenantRequestToJSONTyped = CreateTenantRequestToJSONTyped;
|
|
22
|
-
const OAuth2Config_1 = require("./OAuth2Config");
|
|
23
|
-
/**
|
|
24
|
-
* Check if a given object implements the CreateTenantRequest interface.
|
|
25
|
-
*/
|
|
26
|
-
function instanceOfCreateTenantRequest(value) {
|
|
27
|
-
if (!('name' in value) || value['name'] === undefined)
|
|
28
|
-
return false;
|
|
29
|
-
return true;
|
|
30
|
-
}
|
|
31
|
-
function CreateTenantRequestFromJSON(json) {
|
|
32
|
-
return CreateTenantRequestFromJSONTyped(json, false);
|
|
33
|
-
}
|
|
34
|
-
function CreateTenantRequestFromJSONTyped(json, ignoreDiscriminator) {
|
|
35
|
-
if (json == null) {
|
|
36
|
-
return json;
|
|
37
|
-
}
|
|
38
|
-
return {
|
|
39
|
-
'name': json['name'],
|
|
40
|
-
'idpConfig': json['idp_config'] == null ? undefined : (0, OAuth2Config_1.OAuth2ConfigFromJSON)(json['idp_config']),
|
|
41
|
-
};
|
|
42
|
-
}
|
|
43
|
-
function CreateTenantRequestToJSON(json) {
|
|
44
|
-
return CreateTenantRequestToJSONTyped(json, false);
|
|
45
|
-
}
|
|
46
|
-
function CreateTenantRequestToJSONTyped(value, ignoreDiscriminator = false) {
|
|
47
|
-
if (value == null) {
|
|
48
|
-
return value;
|
|
49
|
-
}
|
|
50
|
-
return {
|
|
51
|
-
'name': value['name'],
|
|
52
|
-
'idp_config': (0, OAuth2Config_1.OAuth2ConfigToJSON)(value['idpConfig']),
|
|
53
|
-
};
|
|
54
|
-
}
|
|
55
|
-
exports.CreateTenantRequestPropertyValidationAttributesMap = {};
|
|
@@ -1,37 +0,0 @@
|
|
|
1
|
-
|
|
2
|
-
# CreateTenantRequest
|
|
3
|
-
|
|
4
|
-
Create tenant request model.
|
|
5
|
-
|
|
6
|
-
## Properties
|
|
7
|
-
|
|
8
|
-
Name | Type
|
|
9
|
-
------------ | -------------
|
|
10
|
-
`name` | string
|
|
11
|
-
`idpConfig` | [OAuth2Config](OAuth2Config.md)
|
|
12
|
-
|
|
13
|
-
## Example
|
|
14
|
-
|
|
15
|
-
```typescript
|
|
16
|
-
import type { CreateTenantRequest } from '@knowledge-stack/ksapi'
|
|
17
|
-
|
|
18
|
-
// TODO: Update the object below with actual values
|
|
19
|
-
const example = {
|
|
20
|
-
"name": null,
|
|
21
|
-
"idpConfig": null,
|
|
22
|
-
} satisfies CreateTenantRequest
|
|
23
|
-
|
|
24
|
-
console.log(example)
|
|
25
|
-
|
|
26
|
-
// Convert the instance to a JSON string
|
|
27
|
-
const exampleJSON: string = JSON.stringify(example)
|
|
28
|
-
console.log(exampleJSON)
|
|
29
|
-
|
|
30
|
-
// Parse the JSON string back to an object
|
|
31
|
-
const exampleParsed = JSON.parse(exampleJSON) as CreateTenantRequest
|
|
32
|
-
console.log(exampleParsed)
|
|
33
|
-
```
|
|
34
|
-
|
|
35
|
-
[[Back to top]](#) [[Back to API list]](../README.md#api-endpoints) [[Back to Model list]](../README.md#models) [[Back to README]](../README.md)
|
|
36
|
-
|
|
37
|
-
|
|
@@ -1,99 +0,0 @@
|
|
|
1
|
-
/* tslint:disable */
|
|
2
|
-
/* eslint-disable */
|
|
3
|
-
/**
|
|
4
|
-
* Knowledge Stack API
|
|
5
|
-
* Knowledge Stack backend API for authentication and knowledge management
|
|
6
|
-
*
|
|
7
|
-
* The version of the OpenAPI document: 0.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 { mapValues } from '../runtime';
|
|
16
|
-
import type { OAuth2Config } from './OAuth2Config';
|
|
17
|
-
import {
|
|
18
|
-
OAuth2ConfigFromJSON,
|
|
19
|
-
OAuth2ConfigFromJSONTyped,
|
|
20
|
-
OAuth2ConfigToJSON,
|
|
21
|
-
OAuth2ConfigToJSONTyped,
|
|
22
|
-
} from './OAuth2Config';
|
|
23
|
-
|
|
24
|
-
/**
|
|
25
|
-
* Create tenant request model.
|
|
26
|
-
* @export
|
|
27
|
-
* @interface CreateTenantRequest
|
|
28
|
-
*/
|
|
29
|
-
export interface CreateTenantRequest {
|
|
30
|
-
/**
|
|
31
|
-
* Tenant name
|
|
32
|
-
* @type {string}
|
|
33
|
-
* @memberof CreateTenantRequest
|
|
34
|
-
*/
|
|
35
|
-
name: string;
|
|
36
|
-
/**
|
|
37
|
-
*
|
|
38
|
-
* @type {OAuth2Config}
|
|
39
|
-
* @memberof CreateTenantRequest
|
|
40
|
-
*/
|
|
41
|
-
idpConfig?: OAuth2Config;
|
|
42
|
-
}
|
|
43
|
-
|
|
44
|
-
/**
|
|
45
|
-
* Check if a given object implements the CreateTenantRequest interface.
|
|
46
|
-
*/
|
|
47
|
-
export function instanceOfCreateTenantRequest(value: object): value is CreateTenantRequest {
|
|
48
|
-
if (!('name' in value) || value['name'] === undefined) return false;
|
|
49
|
-
return true;
|
|
50
|
-
}
|
|
51
|
-
|
|
52
|
-
export function CreateTenantRequestFromJSON(json: any): CreateTenantRequest {
|
|
53
|
-
return CreateTenantRequestFromJSONTyped(json, false);
|
|
54
|
-
}
|
|
55
|
-
|
|
56
|
-
export function CreateTenantRequestFromJSONTyped(json: any, ignoreDiscriminator: boolean): CreateTenantRequest {
|
|
57
|
-
if (json == null) {
|
|
58
|
-
return json;
|
|
59
|
-
}
|
|
60
|
-
return {
|
|
61
|
-
|
|
62
|
-
'name': json['name'],
|
|
63
|
-
'idpConfig': json['idp_config'] == null ? undefined : OAuth2ConfigFromJSON(json['idp_config']),
|
|
64
|
-
};
|
|
65
|
-
}
|
|
66
|
-
|
|
67
|
-
export function CreateTenantRequestToJSON(json: any): CreateTenantRequest {
|
|
68
|
-
return CreateTenantRequestToJSONTyped(json, false);
|
|
69
|
-
}
|
|
70
|
-
|
|
71
|
-
export function CreateTenantRequestToJSONTyped(value?: CreateTenantRequest | null, ignoreDiscriminator: boolean = false): any {
|
|
72
|
-
if (value == null) {
|
|
73
|
-
return value;
|
|
74
|
-
}
|
|
75
|
-
|
|
76
|
-
return {
|
|
77
|
-
|
|
78
|
-
'name': value['name'],
|
|
79
|
-
'idp_config': OAuth2ConfigToJSON(value['idpConfig']),
|
|
80
|
-
};
|
|
81
|
-
}
|
|
82
|
-
|
|
83
|
-
export const CreateTenantRequestPropertyValidationAttributesMap: {
|
|
84
|
-
[property: string]: {
|
|
85
|
-
maxLength?: number,
|
|
86
|
-
minLength?: number,
|
|
87
|
-
pattern?: string,
|
|
88
|
-
maximum?: number,
|
|
89
|
-
exclusiveMaximum?: boolean,
|
|
90
|
-
minimum?: number,
|
|
91
|
-
exclusiveMinimum?: boolean,
|
|
92
|
-
multipleOf?: number,
|
|
93
|
-
maxItems?: number,
|
|
94
|
-
minItems?: number,
|
|
95
|
-
uniqueItems?: boolean
|
|
96
|
-
}
|
|
97
|
-
} = {
|
|
98
|
-
}
|
|
99
|
-
|