@knowledge-stack/ksapi 1.11.2 → 1.12.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 +6 -0
- package/README.md +2 -2
- package/dist/apis/TagsApi.d.ts +237 -0
- package/dist/apis/TagsApi.js +272 -0
- package/dist/apis/index.d.ts +1 -0
- package/dist/apis/index.js +1 -0
- package/dist/esm/apis/TagsApi.d.ts +237 -0
- package/dist/esm/apis/TagsApi.js +268 -0
- package/dist/esm/apis/index.d.ts +1 -0
- package/dist/esm/apis/index.js +1 -0
- package/dist/esm/models/CreateTagRequest.d.ts +59 -0
- package/dist/esm/models/CreateTagRequest.js +61 -0
- package/dist/esm/models/PaginatedResponseTagResponse.d.ts +66 -0
- package/dist/esm/models/PaginatedResponseTagResponse.js +70 -0
- package/dist/esm/models/TagPathPartRequest.d.ts +47 -0
- package/dist/esm/models/TagPathPartRequest.js +44 -0
- package/dist/esm/models/TagResponse.d.ts +83 -0
- package/dist/esm/models/TagResponse.js +66 -0
- package/dist/esm/models/UpdateTagRequest.d.ts +59 -0
- package/dist/esm/models/UpdateTagRequest.js +59 -0
- package/dist/esm/models/index.d.ts +5 -0
- package/dist/esm/models/index.js +5 -0
- package/dist/models/CreateTagRequest.d.ts +59 -0
- package/dist/models/CreateTagRequest.js +69 -0
- package/dist/models/PaginatedResponseTagResponse.d.ts +66 -0
- package/dist/models/PaginatedResponseTagResponse.js +78 -0
- package/dist/models/TagPathPartRequest.d.ts +47 -0
- package/dist/models/TagPathPartRequest.js +52 -0
- package/dist/models/TagResponse.d.ts +83 -0
- package/dist/models/TagResponse.js +74 -0
- package/dist/models/UpdateTagRequest.d.ts +59 -0
- package/dist/models/UpdateTagRequest.js +67 -0
- package/dist/models/index.d.ts +5 -0
- package/dist/models/index.js +5 -0
- package/package.json +1 -1
- package/src/apis/TagsApi.ts +517 -0
- package/src/apis/index.ts +1 -0
- package/src/models/CreateTagRequest.ts +111 -0
- package/src/models/PaginatedResponseTagResponse.ts +130 -0
- package/src/models/TagPathPartRequest.ts +83 -0
- package/src/models/TagResponse.ts +136 -0
- package/src/models/UpdateTagRequest.ts +110 -0
- package/src/models/index.ts +5 -0
package/.openapi-generator/FILES
CHANGED
|
@@ -13,6 +13,7 @@ src/apis/FoldersApi.ts
|
|
|
13
13
|
src/apis/InvitesApi.ts
|
|
14
14
|
src/apis/PathPartsApi.ts
|
|
15
15
|
src/apis/SectionsApi.ts
|
|
16
|
+
src/apis/TagsApi.ts
|
|
16
17
|
src/apis/TenantsApi.ts
|
|
17
18
|
src/apis/ThreadMessagesApi.ts
|
|
18
19
|
src/apis/ThreadsApi.ts
|
|
@@ -30,6 +31,7 @@ src/models/CreateDocumentRequest.ts
|
|
|
30
31
|
src/models/CreateFolderRequest.ts
|
|
31
32
|
src/models/CreatePasswordUserRequest.ts
|
|
32
33
|
src/models/CreateSectionRequest.ts
|
|
34
|
+
src/models/CreateTagRequest.ts
|
|
33
35
|
src/models/CreateTenantRequest.ts
|
|
34
36
|
src/models/CreateThreadMessageRequest.ts
|
|
35
37
|
src/models/CreateThreadRequest.ts
|
|
@@ -60,6 +62,7 @@ src/models/PaginatedResponseFolderDocumentResponse.ts
|
|
|
60
62
|
src/models/PaginatedResponseFolderResponse.ts
|
|
61
63
|
src/models/PaginatedResponseInviteResponse.ts
|
|
62
64
|
src/models/PaginatedResponsePathPartResponse.ts
|
|
65
|
+
src/models/PaginatedResponseTagResponse.ts
|
|
63
66
|
src/models/PaginatedResponseTenantResponse.ts
|
|
64
67
|
src/models/PaginatedResponseTenantUserInTenantResponse.ts
|
|
65
68
|
src/models/PaginatedResponseThreadMessageResponse.ts
|
|
@@ -74,6 +77,8 @@ src/models/PolygonReference.ts
|
|
|
74
77
|
src/models/RootResponse.ts
|
|
75
78
|
src/models/SectionResponse.ts
|
|
76
79
|
src/models/SignInRequest.ts
|
|
80
|
+
src/models/TagPathPartRequest.ts
|
|
81
|
+
src/models/TagResponse.ts
|
|
77
82
|
src/models/TenantResponse.ts
|
|
78
83
|
src/models/TenantUserInTenantResponse.ts
|
|
79
84
|
src/models/TenantUserRole.ts
|
|
@@ -84,6 +89,7 @@ src/models/UpdateChunkMetadataRequest.ts
|
|
|
84
89
|
src/models/UpdateDocumentRequest.ts
|
|
85
90
|
src/models/UpdateFolderRequest.ts
|
|
86
91
|
src/models/UpdateSectionRequest.ts
|
|
92
|
+
src/models/UpdateTagRequest.ts
|
|
87
93
|
src/models/UpdateTenantRequest.ts
|
|
88
94
|
src/models/UpdateThreadRequest.ts
|
|
89
95
|
src/models/UpdateUserRequest.ts
|
package/README.md
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
## @knowledge-stack/ksapi@1.
|
|
1
|
+
## @knowledge-stack/ksapi@1.12.0
|
|
2
2
|
|
|
3
3
|
This generator creates TypeScript/JavaScript client that utilizes [Fetch API](https://fetch.spec.whatwg.org/). The generated Node module can be used in the following environments:
|
|
4
4
|
|
|
@@ -36,7 +36,7 @@ navigate to the folder of your consuming project and run one of the following co
|
|
|
36
36
|
_published:_
|
|
37
37
|
|
|
38
38
|
```
|
|
39
|
-
npm install @knowledge-stack/ksapi@1.
|
|
39
|
+
npm install @knowledge-stack/ksapi@1.12.0 --save
|
|
40
40
|
```
|
|
41
41
|
|
|
42
42
|
_unPublished (not recommended):_
|
|
@@ -0,0 +1,237 @@
|
|
|
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 * as runtime from '../runtime';
|
|
13
|
+
import type { CreateTagRequest, PaginatedResponseTagResponse, TagPathPartRequest, TagResponse, UpdateTagRequest } from '../models/index';
|
|
14
|
+
export interface AttachTagToPathPartRequest {
|
|
15
|
+
tagId: string;
|
|
16
|
+
tagPathPartRequest: TagPathPartRequest;
|
|
17
|
+
ksUat?: string;
|
|
18
|
+
}
|
|
19
|
+
export interface CreateTagOperationRequest {
|
|
20
|
+
createTagRequest: CreateTagRequest;
|
|
21
|
+
ksUat?: string;
|
|
22
|
+
}
|
|
23
|
+
export interface DeleteTagRequest {
|
|
24
|
+
tagId: string;
|
|
25
|
+
ksUat?: string;
|
|
26
|
+
}
|
|
27
|
+
export interface DetachTagFromPathPartRequest {
|
|
28
|
+
tagId: string;
|
|
29
|
+
pathPartId: string;
|
|
30
|
+
ksUat?: string;
|
|
31
|
+
}
|
|
32
|
+
export interface GetTagRequest {
|
|
33
|
+
tagId: string;
|
|
34
|
+
ksUat?: string;
|
|
35
|
+
}
|
|
36
|
+
export interface ListTagsRequest {
|
|
37
|
+
limit?: number;
|
|
38
|
+
offset?: number;
|
|
39
|
+
ksUat?: string;
|
|
40
|
+
}
|
|
41
|
+
export interface UpdateTagOperationRequest {
|
|
42
|
+
tagId: string;
|
|
43
|
+
updateTagRequest: UpdateTagRequest;
|
|
44
|
+
ksUat?: string;
|
|
45
|
+
}
|
|
46
|
+
/**
|
|
47
|
+
* TagsApi - interface
|
|
48
|
+
*
|
|
49
|
+
* @export
|
|
50
|
+
* @interface TagsApiInterface
|
|
51
|
+
*/
|
|
52
|
+
export interface TagsApiInterface {
|
|
53
|
+
/**
|
|
54
|
+
* Attach a tag to a path part.
|
|
55
|
+
* @summary Attach Tag Handler
|
|
56
|
+
* @param {string} tagId
|
|
57
|
+
* @param {TagPathPartRequest} tagPathPartRequest
|
|
58
|
+
* @param {string} [ksUat]
|
|
59
|
+
* @param {*} [options] Override http request option.
|
|
60
|
+
* @throws {RequiredError}
|
|
61
|
+
* @memberof TagsApiInterface
|
|
62
|
+
*/
|
|
63
|
+
attachTagToPathPartRaw(requestParameters: AttachTagToPathPartRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<TagResponse>>;
|
|
64
|
+
/**
|
|
65
|
+
* Attach a tag to a path part.
|
|
66
|
+
* Attach Tag Handler
|
|
67
|
+
*/
|
|
68
|
+
attachTagToPathPart(requestParameters: AttachTagToPathPartRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<TagResponse>;
|
|
69
|
+
/**
|
|
70
|
+
* Create a new tag for the current tenant.
|
|
71
|
+
* @summary Create Tag Handler
|
|
72
|
+
* @param {CreateTagRequest} createTagRequest
|
|
73
|
+
* @param {string} [ksUat]
|
|
74
|
+
* @param {*} [options] Override http request option.
|
|
75
|
+
* @throws {RequiredError}
|
|
76
|
+
* @memberof TagsApiInterface
|
|
77
|
+
*/
|
|
78
|
+
createTagRaw(requestParameters: CreateTagOperationRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<TagResponse>>;
|
|
79
|
+
/**
|
|
80
|
+
* Create a new tag for the current tenant.
|
|
81
|
+
* Create Tag Handler
|
|
82
|
+
*/
|
|
83
|
+
createTag(requestParameters: CreateTagOperationRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<TagResponse>;
|
|
84
|
+
/**
|
|
85
|
+
* Delete a tag and all its path_part associations.
|
|
86
|
+
* @summary Delete Tag Handler
|
|
87
|
+
* @param {string} tagId
|
|
88
|
+
* @param {string} [ksUat]
|
|
89
|
+
* @param {*} [options] Override http request option.
|
|
90
|
+
* @throws {RequiredError}
|
|
91
|
+
* @memberof TagsApiInterface
|
|
92
|
+
*/
|
|
93
|
+
deleteTagRaw(requestParameters: DeleteTagRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<void>>;
|
|
94
|
+
/**
|
|
95
|
+
* Delete a tag and all its path_part associations.
|
|
96
|
+
* Delete Tag Handler
|
|
97
|
+
*/
|
|
98
|
+
deleteTag(requestParameters: DeleteTagRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<void>;
|
|
99
|
+
/**
|
|
100
|
+
* Detach a tag from a path part.
|
|
101
|
+
* @summary Detach Tag Handler
|
|
102
|
+
* @param {string} tagId
|
|
103
|
+
* @param {string} pathPartId
|
|
104
|
+
* @param {string} [ksUat]
|
|
105
|
+
* @param {*} [options] Override http request option.
|
|
106
|
+
* @throws {RequiredError}
|
|
107
|
+
* @memberof TagsApiInterface
|
|
108
|
+
*/
|
|
109
|
+
detachTagFromPathPartRaw(requestParameters: DetachTagFromPathPartRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<void>>;
|
|
110
|
+
/**
|
|
111
|
+
* Detach a tag from a path part.
|
|
112
|
+
* Detach Tag Handler
|
|
113
|
+
*/
|
|
114
|
+
detachTagFromPathPart(requestParameters: DetachTagFromPathPartRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<void>;
|
|
115
|
+
/**
|
|
116
|
+
* Get a tag by its ID.
|
|
117
|
+
* @summary Get Tag Handler
|
|
118
|
+
* @param {string} tagId
|
|
119
|
+
* @param {string} [ksUat]
|
|
120
|
+
* @param {*} [options] Override http request option.
|
|
121
|
+
* @throws {RequiredError}
|
|
122
|
+
* @memberof TagsApiInterface
|
|
123
|
+
*/
|
|
124
|
+
getTagRaw(requestParameters: GetTagRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<TagResponse>>;
|
|
125
|
+
/**
|
|
126
|
+
* Get a tag by its ID.
|
|
127
|
+
* Get Tag Handler
|
|
128
|
+
*/
|
|
129
|
+
getTag(requestParameters: GetTagRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<TagResponse>;
|
|
130
|
+
/**
|
|
131
|
+
* List all tags for the current tenant.
|
|
132
|
+
* @summary List Tags Handler
|
|
133
|
+
* @param {number} [limit] Number of items per page
|
|
134
|
+
* @param {number} [offset] Number of items to skip
|
|
135
|
+
* @param {string} [ksUat]
|
|
136
|
+
* @param {*} [options] Override http request option.
|
|
137
|
+
* @throws {RequiredError}
|
|
138
|
+
* @memberof TagsApiInterface
|
|
139
|
+
*/
|
|
140
|
+
listTagsRaw(requestParameters: ListTagsRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<PaginatedResponseTagResponse>>;
|
|
141
|
+
/**
|
|
142
|
+
* List all tags for the current tenant.
|
|
143
|
+
* List Tags Handler
|
|
144
|
+
*/
|
|
145
|
+
listTags(requestParameters: ListTagsRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<PaginatedResponseTagResponse>;
|
|
146
|
+
/**
|
|
147
|
+
* Update a tag (name, color, and/or description).
|
|
148
|
+
* @summary Update Tag Handler
|
|
149
|
+
* @param {string} tagId
|
|
150
|
+
* @param {UpdateTagRequest} updateTagRequest
|
|
151
|
+
* @param {string} [ksUat]
|
|
152
|
+
* @param {*} [options] Override http request option.
|
|
153
|
+
* @throws {RequiredError}
|
|
154
|
+
* @memberof TagsApiInterface
|
|
155
|
+
*/
|
|
156
|
+
updateTagRaw(requestParameters: UpdateTagOperationRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<TagResponse>>;
|
|
157
|
+
/**
|
|
158
|
+
* Update a tag (name, color, and/or description).
|
|
159
|
+
* Update Tag Handler
|
|
160
|
+
*/
|
|
161
|
+
updateTag(requestParameters: UpdateTagOperationRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<TagResponse>;
|
|
162
|
+
}
|
|
163
|
+
/**
|
|
164
|
+
*
|
|
165
|
+
*/
|
|
166
|
+
export declare class TagsApi extends runtime.BaseAPI implements TagsApiInterface {
|
|
167
|
+
/**
|
|
168
|
+
* Attach a tag to a path part.
|
|
169
|
+
* Attach Tag Handler
|
|
170
|
+
*/
|
|
171
|
+
attachTagToPathPartRaw(requestParameters: AttachTagToPathPartRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<TagResponse>>;
|
|
172
|
+
/**
|
|
173
|
+
* Attach a tag to a path part.
|
|
174
|
+
* Attach Tag Handler
|
|
175
|
+
*/
|
|
176
|
+
attachTagToPathPart(requestParameters: AttachTagToPathPartRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<TagResponse>;
|
|
177
|
+
/**
|
|
178
|
+
* Create a new tag for the current tenant.
|
|
179
|
+
* Create Tag Handler
|
|
180
|
+
*/
|
|
181
|
+
createTagRaw(requestParameters: CreateTagOperationRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<TagResponse>>;
|
|
182
|
+
/**
|
|
183
|
+
* Create a new tag for the current tenant.
|
|
184
|
+
* Create Tag Handler
|
|
185
|
+
*/
|
|
186
|
+
createTag(requestParameters: CreateTagOperationRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<TagResponse>;
|
|
187
|
+
/**
|
|
188
|
+
* Delete a tag and all its path_part associations.
|
|
189
|
+
* Delete Tag Handler
|
|
190
|
+
*/
|
|
191
|
+
deleteTagRaw(requestParameters: DeleteTagRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<void>>;
|
|
192
|
+
/**
|
|
193
|
+
* Delete a tag and all its path_part associations.
|
|
194
|
+
* Delete Tag Handler
|
|
195
|
+
*/
|
|
196
|
+
deleteTag(requestParameters: DeleteTagRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<void>;
|
|
197
|
+
/**
|
|
198
|
+
* Detach a tag from a path part.
|
|
199
|
+
* Detach Tag Handler
|
|
200
|
+
*/
|
|
201
|
+
detachTagFromPathPartRaw(requestParameters: DetachTagFromPathPartRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<void>>;
|
|
202
|
+
/**
|
|
203
|
+
* Detach a tag from a path part.
|
|
204
|
+
* Detach Tag Handler
|
|
205
|
+
*/
|
|
206
|
+
detachTagFromPathPart(requestParameters: DetachTagFromPathPartRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<void>;
|
|
207
|
+
/**
|
|
208
|
+
* Get a tag by its ID.
|
|
209
|
+
* Get Tag Handler
|
|
210
|
+
*/
|
|
211
|
+
getTagRaw(requestParameters: GetTagRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<TagResponse>>;
|
|
212
|
+
/**
|
|
213
|
+
* Get a tag by its ID.
|
|
214
|
+
* Get Tag Handler
|
|
215
|
+
*/
|
|
216
|
+
getTag(requestParameters: GetTagRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<TagResponse>;
|
|
217
|
+
/**
|
|
218
|
+
* List all tags for the current tenant.
|
|
219
|
+
* List Tags Handler
|
|
220
|
+
*/
|
|
221
|
+
listTagsRaw(requestParameters: ListTagsRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<PaginatedResponseTagResponse>>;
|
|
222
|
+
/**
|
|
223
|
+
* List all tags for the current tenant.
|
|
224
|
+
* List Tags Handler
|
|
225
|
+
*/
|
|
226
|
+
listTags(requestParameters?: ListTagsRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<PaginatedResponseTagResponse>;
|
|
227
|
+
/**
|
|
228
|
+
* Update a tag (name, color, and/or description).
|
|
229
|
+
* Update Tag Handler
|
|
230
|
+
*/
|
|
231
|
+
updateTagRaw(requestParameters: UpdateTagOperationRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<TagResponse>>;
|
|
232
|
+
/**
|
|
233
|
+
* Update a tag (name, color, and/or description).
|
|
234
|
+
* Update Tag Handler
|
|
235
|
+
*/
|
|
236
|
+
updateTag(requestParameters: UpdateTagOperationRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<TagResponse>;
|
|
237
|
+
}
|
|
@@ -0,0 +1,272 @@
|
|
|
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
|
+
var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
|
|
16
|
+
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
|
|
17
|
+
return new (P || (P = Promise))(function (resolve, reject) {
|
|
18
|
+
function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
|
|
19
|
+
function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
|
|
20
|
+
function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
|
|
21
|
+
step((generator = generator.apply(thisArg, _arguments || [])).next());
|
|
22
|
+
});
|
|
23
|
+
};
|
|
24
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
25
|
+
exports.TagsApi = void 0;
|
|
26
|
+
const runtime = require("../runtime");
|
|
27
|
+
const index_1 = require("../models/index");
|
|
28
|
+
/**
|
|
29
|
+
*
|
|
30
|
+
*/
|
|
31
|
+
class TagsApi extends runtime.BaseAPI {
|
|
32
|
+
/**
|
|
33
|
+
* Attach a tag to a path part.
|
|
34
|
+
* Attach Tag Handler
|
|
35
|
+
*/
|
|
36
|
+
attachTagToPathPartRaw(requestParameters, initOverrides) {
|
|
37
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
38
|
+
if (requestParameters['tagId'] == null) {
|
|
39
|
+
throw new runtime.RequiredError('tagId', 'Required parameter "tagId" was null or undefined when calling attachTagToPathPart().');
|
|
40
|
+
}
|
|
41
|
+
if (requestParameters['tagPathPartRequest'] == null) {
|
|
42
|
+
throw new runtime.RequiredError('tagPathPartRequest', 'Required parameter "tagPathPartRequest" was null or undefined when calling attachTagToPathPart().');
|
|
43
|
+
}
|
|
44
|
+
const queryParameters = {};
|
|
45
|
+
const headerParameters = {};
|
|
46
|
+
headerParameters['Content-Type'] = 'application/json';
|
|
47
|
+
let urlPath = `/v1/tags/{tag_id}/path-parts`;
|
|
48
|
+
urlPath = urlPath.replace(`{${"tag_id"}}`, encodeURIComponent(String(requestParameters['tagId'])));
|
|
49
|
+
const response = yield this.request({
|
|
50
|
+
path: urlPath,
|
|
51
|
+
method: 'POST',
|
|
52
|
+
headers: headerParameters,
|
|
53
|
+
query: queryParameters,
|
|
54
|
+
body: (0, index_1.TagPathPartRequestToJSON)(requestParameters['tagPathPartRequest']),
|
|
55
|
+
}, initOverrides);
|
|
56
|
+
return new runtime.JSONApiResponse(response, (jsonValue) => (0, index_1.TagResponseFromJSON)(jsonValue));
|
|
57
|
+
});
|
|
58
|
+
}
|
|
59
|
+
/**
|
|
60
|
+
* Attach a tag to a path part.
|
|
61
|
+
* Attach Tag Handler
|
|
62
|
+
*/
|
|
63
|
+
attachTagToPathPart(requestParameters, initOverrides) {
|
|
64
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
65
|
+
const response = yield this.attachTagToPathPartRaw(requestParameters, initOverrides);
|
|
66
|
+
return yield response.value();
|
|
67
|
+
});
|
|
68
|
+
}
|
|
69
|
+
/**
|
|
70
|
+
* Create a new tag for the current tenant.
|
|
71
|
+
* Create Tag Handler
|
|
72
|
+
*/
|
|
73
|
+
createTagRaw(requestParameters, initOverrides) {
|
|
74
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
75
|
+
if (requestParameters['createTagRequest'] == null) {
|
|
76
|
+
throw new runtime.RequiredError('createTagRequest', 'Required parameter "createTagRequest" was null or undefined when calling createTag().');
|
|
77
|
+
}
|
|
78
|
+
const queryParameters = {};
|
|
79
|
+
const headerParameters = {};
|
|
80
|
+
headerParameters['Content-Type'] = 'application/json';
|
|
81
|
+
let urlPath = `/v1/tags`;
|
|
82
|
+
const response = yield this.request({
|
|
83
|
+
path: urlPath,
|
|
84
|
+
method: 'POST',
|
|
85
|
+
headers: headerParameters,
|
|
86
|
+
query: queryParameters,
|
|
87
|
+
body: (0, index_1.CreateTagRequestToJSON)(requestParameters['createTagRequest']),
|
|
88
|
+
}, initOverrides);
|
|
89
|
+
return new runtime.JSONApiResponse(response, (jsonValue) => (0, index_1.TagResponseFromJSON)(jsonValue));
|
|
90
|
+
});
|
|
91
|
+
}
|
|
92
|
+
/**
|
|
93
|
+
* Create a new tag for the current tenant.
|
|
94
|
+
* Create Tag Handler
|
|
95
|
+
*/
|
|
96
|
+
createTag(requestParameters, initOverrides) {
|
|
97
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
98
|
+
const response = yield this.createTagRaw(requestParameters, initOverrides);
|
|
99
|
+
return yield response.value();
|
|
100
|
+
});
|
|
101
|
+
}
|
|
102
|
+
/**
|
|
103
|
+
* Delete a tag and all its path_part associations.
|
|
104
|
+
* Delete Tag Handler
|
|
105
|
+
*/
|
|
106
|
+
deleteTagRaw(requestParameters, initOverrides) {
|
|
107
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
108
|
+
if (requestParameters['tagId'] == null) {
|
|
109
|
+
throw new runtime.RequiredError('tagId', 'Required parameter "tagId" was null or undefined when calling deleteTag().');
|
|
110
|
+
}
|
|
111
|
+
const queryParameters = {};
|
|
112
|
+
const headerParameters = {};
|
|
113
|
+
let urlPath = `/v1/tags/{tag_id}`;
|
|
114
|
+
urlPath = urlPath.replace(`{${"tag_id"}}`, encodeURIComponent(String(requestParameters['tagId'])));
|
|
115
|
+
const response = yield this.request({
|
|
116
|
+
path: urlPath,
|
|
117
|
+
method: 'DELETE',
|
|
118
|
+
headers: headerParameters,
|
|
119
|
+
query: queryParameters,
|
|
120
|
+
}, initOverrides);
|
|
121
|
+
return new runtime.VoidApiResponse(response);
|
|
122
|
+
});
|
|
123
|
+
}
|
|
124
|
+
/**
|
|
125
|
+
* Delete a tag and all its path_part associations.
|
|
126
|
+
* Delete Tag Handler
|
|
127
|
+
*/
|
|
128
|
+
deleteTag(requestParameters, initOverrides) {
|
|
129
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
130
|
+
yield this.deleteTagRaw(requestParameters, initOverrides);
|
|
131
|
+
});
|
|
132
|
+
}
|
|
133
|
+
/**
|
|
134
|
+
* Detach a tag from a path part.
|
|
135
|
+
* Detach Tag Handler
|
|
136
|
+
*/
|
|
137
|
+
detachTagFromPathPartRaw(requestParameters, initOverrides) {
|
|
138
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
139
|
+
if (requestParameters['tagId'] == null) {
|
|
140
|
+
throw new runtime.RequiredError('tagId', 'Required parameter "tagId" was null or undefined when calling detachTagFromPathPart().');
|
|
141
|
+
}
|
|
142
|
+
if (requestParameters['pathPartId'] == null) {
|
|
143
|
+
throw new runtime.RequiredError('pathPartId', 'Required parameter "pathPartId" was null or undefined when calling detachTagFromPathPart().');
|
|
144
|
+
}
|
|
145
|
+
const queryParameters = {};
|
|
146
|
+
const headerParameters = {};
|
|
147
|
+
let urlPath = `/v1/tags/{tag_id}/path-parts/{path_part_id}`;
|
|
148
|
+
urlPath = urlPath.replace(`{${"tag_id"}}`, encodeURIComponent(String(requestParameters['tagId'])));
|
|
149
|
+
urlPath = urlPath.replace(`{${"path_part_id"}}`, encodeURIComponent(String(requestParameters['pathPartId'])));
|
|
150
|
+
const response = yield this.request({
|
|
151
|
+
path: urlPath,
|
|
152
|
+
method: 'DELETE',
|
|
153
|
+
headers: headerParameters,
|
|
154
|
+
query: queryParameters,
|
|
155
|
+
}, initOverrides);
|
|
156
|
+
return new runtime.VoidApiResponse(response);
|
|
157
|
+
});
|
|
158
|
+
}
|
|
159
|
+
/**
|
|
160
|
+
* Detach a tag from a path part.
|
|
161
|
+
* Detach Tag Handler
|
|
162
|
+
*/
|
|
163
|
+
detachTagFromPathPart(requestParameters, initOverrides) {
|
|
164
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
165
|
+
yield this.detachTagFromPathPartRaw(requestParameters, initOverrides);
|
|
166
|
+
});
|
|
167
|
+
}
|
|
168
|
+
/**
|
|
169
|
+
* Get a tag by its ID.
|
|
170
|
+
* Get Tag Handler
|
|
171
|
+
*/
|
|
172
|
+
getTagRaw(requestParameters, initOverrides) {
|
|
173
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
174
|
+
if (requestParameters['tagId'] == null) {
|
|
175
|
+
throw new runtime.RequiredError('tagId', 'Required parameter "tagId" was null or undefined when calling getTag().');
|
|
176
|
+
}
|
|
177
|
+
const queryParameters = {};
|
|
178
|
+
const headerParameters = {};
|
|
179
|
+
let urlPath = `/v1/tags/{tag_id}`;
|
|
180
|
+
urlPath = urlPath.replace(`{${"tag_id"}}`, encodeURIComponent(String(requestParameters['tagId'])));
|
|
181
|
+
const response = yield this.request({
|
|
182
|
+
path: urlPath,
|
|
183
|
+
method: 'GET',
|
|
184
|
+
headers: headerParameters,
|
|
185
|
+
query: queryParameters,
|
|
186
|
+
}, initOverrides);
|
|
187
|
+
return new runtime.JSONApiResponse(response, (jsonValue) => (0, index_1.TagResponseFromJSON)(jsonValue));
|
|
188
|
+
});
|
|
189
|
+
}
|
|
190
|
+
/**
|
|
191
|
+
* Get a tag by its ID.
|
|
192
|
+
* Get Tag Handler
|
|
193
|
+
*/
|
|
194
|
+
getTag(requestParameters, initOverrides) {
|
|
195
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
196
|
+
const response = yield this.getTagRaw(requestParameters, initOverrides);
|
|
197
|
+
return yield response.value();
|
|
198
|
+
});
|
|
199
|
+
}
|
|
200
|
+
/**
|
|
201
|
+
* List all tags for the current tenant.
|
|
202
|
+
* List Tags Handler
|
|
203
|
+
*/
|
|
204
|
+
listTagsRaw(requestParameters, initOverrides) {
|
|
205
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
206
|
+
const queryParameters = {};
|
|
207
|
+
if (requestParameters['limit'] != null) {
|
|
208
|
+
queryParameters['limit'] = requestParameters['limit'];
|
|
209
|
+
}
|
|
210
|
+
if (requestParameters['offset'] != null) {
|
|
211
|
+
queryParameters['offset'] = requestParameters['offset'];
|
|
212
|
+
}
|
|
213
|
+
const headerParameters = {};
|
|
214
|
+
let urlPath = `/v1/tags`;
|
|
215
|
+
const response = yield this.request({
|
|
216
|
+
path: urlPath,
|
|
217
|
+
method: 'GET',
|
|
218
|
+
headers: headerParameters,
|
|
219
|
+
query: queryParameters,
|
|
220
|
+
}, initOverrides);
|
|
221
|
+
return new runtime.JSONApiResponse(response, (jsonValue) => (0, index_1.PaginatedResponseTagResponseFromJSON)(jsonValue));
|
|
222
|
+
});
|
|
223
|
+
}
|
|
224
|
+
/**
|
|
225
|
+
* List all tags for the current tenant.
|
|
226
|
+
* List Tags Handler
|
|
227
|
+
*/
|
|
228
|
+
listTags() {
|
|
229
|
+
return __awaiter(this, arguments, void 0, function* (requestParameters = {}, initOverrides) {
|
|
230
|
+
const response = yield this.listTagsRaw(requestParameters, initOverrides);
|
|
231
|
+
return yield response.value();
|
|
232
|
+
});
|
|
233
|
+
}
|
|
234
|
+
/**
|
|
235
|
+
* Update a tag (name, color, and/or description).
|
|
236
|
+
* Update Tag Handler
|
|
237
|
+
*/
|
|
238
|
+
updateTagRaw(requestParameters, initOverrides) {
|
|
239
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
240
|
+
if (requestParameters['tagId'] == null) {
|
|
241
|
+
throw new runtime.RequiredError('tagId', 'Required parameter "tagId" was null or undefined when calling updateTag().');
|
|
242
|
+
}
|
|
243
|
+
if (requestParameters['updateTagRequest'] == null) {
|
|
244
|
+
throw new runtime.RequiredError('updateTagRequest', 'Required parameter "updateTagRequest" was null or undefined when calling updateTag().');
|
|
245
|
+
}
|
|
246
|
+
const queryParameters = {};
|
|
247
|
+
const headerParameters = {};
|
|
248
|
+
headerParameters['Content-Type'] = 'application/json';
|
|
249
|
+
let urlPath = `/v1/tags/{tag_id}`;
|
|
250
|
+
urlPath = urlPath.replace(`{${"tag_id"}}`, encodeURIComponent(String(requestParameters['tagId'])));
|
|
251
|
+
const response = yield this.request({
|
|
252
|
+
path: urlPath,
|
|
253
|
+
method: 'PATCH',
|
|
254
|
+
headers: headerParameters,
|
|
255
|
+
query: queryParameters,
|
|
256
|
+
body: (0, index_1.UpdateTagRequestToJSON)(requestParameters['updateTagRequest']),
|
|
257
|
+
}, initOverrides);
|
|
258
|
+
return new runtime.JSONApiResponse(response, (jsonValue) => (0, index_1.TagResponseFromJSON)(jsonValue));
|
|
259
|
+
});
|
|
260
|
+
}
|
|
261
|
+
/**
|
|
262
|
+
* Update a tag (name, color, and/or description).
|
|
263
|
+
* Update Tag Handler
|
|
264
|
+
*/
|
|
265
|
+
updateTag(requestParameters, initOverrides) {
|
|
266
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
267
|
+
const response = yield this.updateTagRaw(requestParameters, initOverrides);
|
|
268
|
+
return yield response.value();
|
|
269
|
+
});
|
|
270
|
+
}
|
|
271
|
+
}
|
|
272
|
+
exports.TagsApi = TagsApi;
|
package/dist/apis/index.d.ts
CHANGED
package/dist/apis/index.js
CHANGED
|
@@ -26,6 +26,7 @@ __exportStar(require("./FoldersApi"), exports);
|
|
|
26
26
|
__exportStar(require("./InvitesApi"), exports);
|
|
27
27
|
__exportStar(require("./PathPartsApi"), exports);
|
|
28
28
|
__exportStar(require("./SectionsApi"), exports);
|
|
29
|
+
__exportStar(require("./TagsApi"), exports);
|
|
29
30
|
__exportStar(require("./TenantsApi"), exports);
|
|
30
31
|
__exportStar(require("./ThreadMessagesApi"), exports);
|
|
31
32
|
__exportStar(require("./ThreadsApi"), exports);
|