@openfilz-sdk/typescript 1.2.19 → 1.2.21
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 +16 -0
- package/.openapi-generator/openfilz-api-generate-typescript-sdk.sha256 +1 -1
- package/README.md +17 -3
- package/api/aichat-api.ts +341 -0
- package/api/aisettings-api.ts +335 -0
- package/api/settings-api.ts +8 -8
- package/api.ts +2 -0
- package/dist/api/aichat-api.d.ts +161 -0
- package/dist/api/aichat-api.js +332 -0
- package/dist/api/aisettings-api.d.ts +157 -0
- package/dist/api/aisettings-api.js +326 -0
- package/dist/api/settings-api.d.ts +4 -4
- package/dist/api/settings-api.js +8 -8
- package/dist/api.d.ts +2 -0
- package/dist/api.js +2 -0
- package/dist/esm/api/aichat-api.d.ts +161 -0
- package/dist/esm/api/aichat-api.js +325 -0
- package/dist/esm/api/aisettings-api.d.ts +157 -0
- package/dist/esm/api/aisettings-api.js +319 -0
- package/dist/esm/api/settings-api.d.ts +4 -4
- package/dist/esm/api/settings-api.js +8 -8
- package/dist/esm/api.d.ts +2 -0
- package/dist/esm/api.js +2 -0
- package/dist/esm/models/ai-chat-conversation.d.ts +18 -0
- package/dist/esm/models/ai-chat-conversation.js +14 -0
- package/dist/esm/models/ai-chat-request.d.ts +15 -0
- package/dist/esm/models/ai-chat-request.js +14 -0
- package/dist/esm/models/ai-chat-response.d.ts +23 -0
- package/dist/esm/models/ai-chat-response.js +18 -0
- package/dist/esm/models/ai-connection-test-result.d.ts +16 -0
- package/dist/esm/models/ai-connection-test-result.js +14 -0
- package/dist/esm/models/ai-settings-response.d.ts +21 -0
- package/dist/esm/models/ai-settings-response.js +14 -0
- package/dist/esm/models/index.d.ts +6 -0
- package/dist/esm/models/index.js +6 -0
- package/dist/esm/models/save-ai-settings-request.d.ts +36 -0
- package/dist/esm/models/save-ai-settings-request.js +19 -0
- package/dist/esm/models/settings.d.ts +1 -0
- package/dist/models/ai-chat-conversation.d.ts +18 -0
- package/dist/models/ai-chat-conversation.js +15 -0
- package/dist/models/ai-chat-request.d.ts +15 -0
- package/dist/models/ai-chat-request.js +15 -0
- package/dist/models/ai-chat-response.d.ts +23 -0
- package/dist/models/ai-chat-response.js +21 -0
- package/dist/models/ai-connection-test-result.d.ts +16 -0
- package/dist/models/ai-connection-test-result.js +15 -0
- package/dist/models/ai-settings-response.d.ts +21 -0
- package/dist/models/ai-settings-response.js +15 -0
- package/dist/models/index.d.ts +6 -0
- package/dist/models/index.js +6 -0
- package/dist/models/save-ai-settings-request.d.ts +36 -0
- package/dist/models/save-ai-settings-request.js +22 -0
- package/dist/models/settings.d.ts +1 -0
- package/docs/AIChatApi.md +209 -0
- package/docs/AISettingsApi.md +203 -0
- package/docs/AiChatConversation.md +28 -0
- package/docs/AiChatRequest.md +22 -0
- package/docs/AiChatResponse.md +26 -0
- package/docs/AiConnectionTestResult.md +24 -0
- package/docs/AiSettingsResponse.md +34 -0
- package/docs/SaveAiSettingsRequest.md +26 -0
- package/docs/Settings.md +2 -0
- package/docs/SettingsApi.md +4 -4
- package/models/ai-chat-conversation.ts +24 -0
- package/models/ai-chat-request.ts +21 -0
- package/models/ai-chat-response.ts +32 -0
- package/models/ai-connection-test-result.ts +22 -0
- package/models/ai-settings-response.ts +27 -0
- package/models/index.ts +6 -0
- package/models/save-ai-settings-request.ts +45 -0
- package/models/settings.ts +1 -0
- package/package.json +1 -1
|
@@ -0,0 +1,326 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
/* tslint:disable */
|
|
3
|
+
/* eslint-disable */
|
|
4
|
+
/**
|
|
5
|
+
* openfilz-api
|
|
6
|
+
* API for Document Management System
|
|
7
|
+
*
|
|
8
|
+
* The version of the OpenAPI document: 1.0.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.AISettingsApi = exports.AISettingsApiFactory = exports.AISettingsApiFp = exports.AISettingsApiAxiosParamCreator = void 0;
|
|
26
|
+
const axios_1 = require("axios");
|
|
27
|
+
// Some imports not used depending on template conditions
|
|
28
|
+
// @ts-ignore
|
|
29
|
+
const common_1 = require("../common");
|
|
30
|
+
// @ts-ignore
|
|
31
|
+
const base_1 = require("../base");
|
|
32
|
+
/**
|
|
33
|
+
* AISettingsApi - axios parameter creator
|
|
34
|
+
*/
|
|
35
|
+
const AISettingsApiAxiosParamCreator = function (configuration) {
|
|
36
|
+
return {
|
|
37
|
+
/**
|
|
38
|
+
* Remove my chat-LLM override and go back to the server default model.
|
|
39
|
+
* @summary Reset my AI settings
|
|
40
|
+
* @param {*} [options] Override http request option.
|
|
41
|
+
* @throws {RequiredError}
|
|
42
|
+
*/
|
|
43
|
+
deleteSettings: (...args_1) => __awaiter(this, [...args_1], void 0, function* (options = {}) {
|
|
44
|
+
const localVarPath = `/api/v1/settings/ai`;
|
|
45
|
+
// use dummy base URL string because the URL constructor only accepts absolute URLs.
|
|
46
|
+
const localVarUrlObj = new URL(localVarPath, common_1.DUMMY_BASE_URL);
|
|
47
|
+
let baseOptions;
|
|
48
|
+
if (configuration) {
|
|
49
|
+
baseOptions = configuration.baseOptions;
|
|
50
|
+
}
|
|
51
|
+
const localVarRequestOptions = Object.assign(Object.assign({ method: 'DELETE' }, baseOptions), options);
|
|
52
|
+
const localVarHeaderParameter = {};
|
|
53
|
+
const localVarQueryParameter = {};
|
|
54
|
+
// authentication keycloak_auth required
|
|
55
|
+
// http bearer authentication required
|
|
56
|
+
yield (0, common_1.setBearerAuthToObject)(localVarHeaderParameter, configuration);
|
|
57
|
+
(0, common_1.setSearchParams)(localVarUrlObj, localVarQueryParameter);
|
|
58
|
+
let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
|
|
59
|
+
localVarRequestOptions.headers = Object.assign(Object.assign(Object.assign({}, localVarHeaderParameter), headersFromBaseOptions), options.headers);
|
|
60
|
+
return {
|
|
61
|
+
url: (0, common_1.toPathString)(localVarUrlObj),
|
|
62
|
+
options: localVarRequestOptions,
|
|
63
|
+
};
|
|
64
|
+
}),
|
|
65
|
+
/**
|
|
66
|
+
* Current user\'s chat-LLM override. The API key is never returned — only hasApiKey and its last characters.
|
|
67
|
+
* @summary Get my AI settings
|
|
68
|
+
* @param {*} [options] Override http request option.
|
|
69
|
+
* @throws {RequiredError}
|
|
70
|
+
*/
|
|
71
|
+
getSettings: (...args_1) => __awaiter(this, [...args_1], void 0, function* (options = {}) {
|
|
72
|
+
const localVarPath = `/api/v1/settings/ai`;
|
|
73
|
+
// use dummy base URL string because the URL constructor only accepts absolute URLs.
|
|
74
|
+
const localVarUrlObj = new URL(localVarPath, common_1.DUMMY_BASE_URL);
|
|
75
|
+
let baseOptions;
|
|
76
|
+
if (configuration) {
|
|
77
|
+
baseOptions = configuration.baseOptions;
|
|
78
|
+
}
|
|
79
|
+
const localVarRequestOptions = Object.assign(Object.assign({ method: 'GET' }, baseOptions), options);
|
|
80
|
+
const localVarHeaderParameter = {};
|
|
81
|
+
const localVarQueryParameter = {};
|
|
82
|
+
// authentication keycloak_auth required
|
|
83
|
+
// http bearer authentication required
|
|
84
|
+
yield (0, common_1.setBearerAuthToObject)(localVarHeaderParameter, configuration);
|
|
85
|
+
localVarHeaderParameter['Accept'] = 'application/json';
|
|
86
|
+
(0, common_1.setSearchParams)(localVarUrlObj, localVarQueryParameter);
|
|
87
|
+
let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
|
|
88
|
+
localVarRequestOptions.headers = Object.assign(Object.assign(Object.assign({}, localVarHeaderParameter), headersFromBaseOptions), options.headers);
|
|
89
|
+
return {
|
|
90
|
+
url: (0, common_1.toPathString)(localVarUrlObj),
|
|
91
|
+
options: localVarRequestOptions,
|
|
92
|
+
};
|
|
93
|
+
}),
|
|
94
|
+
/**
|
|
95
|
+
* Set the chat LLM to use for my conversations. Omit apiKey to keep the previously stored key.
|
|
96
|
+
* @summary Save my AI settings
|
|
97
|
+
* @param {SaveAiSettingsRequest} saveAiSettingsRequest
|
|
98
|
+
* @param {*} [options] Override http request option.
|
|
99
|
+
* @throws {RequiredError}
|
|
100
|
+
*/
|
|
101
|
+
saveSettings: (saveAiSettingsRequest_1, ...args_1) => __awaiter(this, [saveAiSettingsRequest_1, ...args_1], void 0, function* (saveAiSettingsRequest, options = {}) {
|
|
102
|
+
// verify required parameter 'saveAiSettingsRequest' is not null or undefined
|
|
103
|
+
(0, common_1.assertParamExists)('saveSettings', 'saveAiSettingsRequest', saveAiSettingsRequest);
|
|
104
|
+
const localVarPath = `/api/v1/settings/ai`;
|
|
105
|
+
// use dummy base URL string because the URL constructor only accepts absolute URLs.
|
|
106
|
+
const localVarUrlObj = new URL(localVarPath, common_1.DUMMY_BASE_URL);
|
|
107
|
+
let baseOptions;
|
|
108
|
+
if (configuration) {
|
|
109
|
+
baseOptions = configuration.baseOptions;
|
|
110
|
+
}
|
|
111
|
+
const localVarRequestOptions = Object.assign(Object.assign({ method: 'PUT' }, baseOptions), options);
|
|
112
|
+
const localVarHeaderParameter = {};
|
|
113
|
+
const localVarQueryParameter = {};
|
|
114
|
+
// authentication keycloak_auth required
|
|
115
|
+
// http bearer authentication required
|
|
116
|
+
yield (0, common_1.setBearerAuthToObject)(localVarHeaderParameter, configuration);
|
|
117
|
+
localVarHeaderParameter['Content-Type'] = 'application/json';
|
|
118
|
+
localVarHeaderParameter['Accept'] = 'application/json';
|
|
119
|
+
(0, common_1.setSearchParams)(localVarUrlObj, localVarQueryParameter);
|
|
120
|
+
let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
|
|
121
|
+
localVarRequestOptions.headers = Object.assign(Object.assign(Object.assign({}, localVarHeaderParameter), headersFromBaseOptions), options.headers);
|
|
122
|
+
localVarRequestOptions.data = (0, common_1.serializeDataIfNeeded)(saveAiSettingsRequest, localVarRequestOptions, configuration);
|
|
123
|
+
return {
|
|
124
|
+
url: (0, common_1.toPathString)(localVarUrlObj),
|
|
125
|
+
options: localVarRequestOptions,
|
|
126
|
+
};
|
|
127
|
+
}),
|
|
128
|
+
/**
|
|
129
|
+
* Send a minimal completion request with the submitted settings (falls back to the stored key when apiKey is omitted).
|
|
130
|
+
* @summary Test AI provider connection
|
|
131
|
+
* @param {SaveAiSettingsRequest} saveAiSettingsRequest
|
|
132
|
+
* @param {*} [options] Override http request option.
|
|
133
|
+
* @throws {RequiredError}
|
|
134
|
+
*/
|
|
135
|
+
testConnection: (saveAiSettingsRequest_1, ...args_1) => __awaiter(this, [saveAiSettingsRequest_1, ...args_1], void 0, function* (saveAiSettingsRequest, options = {}) {
|
|
136
|
+
// verify required parameter 'saveAiSettingsRequest' is not null or undefined
|
|
137
|
+
(0, common_1.assertParamExists)('testConnection', 'saveAiSettingsRequest', saveAiSettingsRequest);
|
|
138
|
+
const localVarPath = `/api/v1/settings/ai/test`;
|
|
139
|
+
// use dummy base URL string because the URL constructor only accepts absolute URLs.
|
|
140
|
+
const localVarUrlObj = new URL(localVarPath, common_1.DUMMY_BASE_URL);
|
|
141
|
+
let baseOptions;
|
|
142
|
+
if (configuration) {
|
|
143
|
+
baseOptions = configuration.baseOptions;
|
|
144
|
+
}
|
|
145
|
+
const localVarRequestOptions = Object.assign(Object.assign({ method: 'POST' }, baseOptions), options);
|
|
146
|
+
const localVarHeaderParameter = {};
|
|
147
|
+
const localVarQueryParameter = {};
|
|
148
|
+
// authentication keycloak_auth required
|
|
149
|
+
// http bearer authentication required
|
|
150
|
+
yield (0, common_1.setBearerAuthToObject)(localVarHeaderParameter, configuration);
|
|
151
|
+
localVarHeaderParameter['Content-Type'] = 'application/json';
|
|
152
|
+
localVarHeaderParameter['Accept'] = 'application/json';
|
|
153
|
+
(0, common_1.setSearchParams)(localVarUrlObj, localVarQueryParameter);
|
|
154
|
+
let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
|
|
155
|
+
localVarRequestOptions.headers = Object.assign(Object.assign(Object.assign({}, localVarHeaderParameter), headersFromBaseOptions), options.headers);
|
|
156
|
+
localVarRequestOptions.data = (0, common_1.serializeDataIfNeeded)(saveAiSettingsRequest, localVarRequestOptions, configuration);
|
|
157
|
+
return {
|
|
158
|
+
url: (0, common_1.toPathString)(localVarUrlObj),
|
|
159
|
+
options: localVarRequestOptions,
|
|
160
|
+
};
|
|
161
|
+
}),
|
|
162
|
+
};
|
|
163
|
+
};
|
|
164
|
+
exports.AISettingsApiAxiosParamCreator = AISettingsApiAxiosParamCreator;
|
|
165
|
+
/**
|
|
166
|
+
* AISettingsApi - functional programming interface
|
|
167
|
+
*/
|
|
168
|
+
const AISettingsApiFp = function (configuration) {
|
|
169
|
+
const localVarAxiosParamCreator = (0, exports.AISettingsApiAxiosParamCreator)(configuration);
|
|
170
|
+
return {
|
|
171
|
+
/**
|
|
172
|
+
* Remove my chat-LLM override and go back to the server default model.
|
|
173
|
+
* @summary Reset my AI settings
|
|
174
|
+
* @param {*} [options] Override http request option.
|
|
175
|
+
* @throws {RequiredError}
|
|
176
|
+
*/
|
|
177
|
+
deleteSettings(options) {
|
|
178
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
179
|
+
var _a, _b, _c;
|
|
180
|
+
const localVarAxiosArgs = yield localVarAxiosParamCreator.deleteSettings(options);
|
|
181
|
+
const localVarOperationServerIndex = (_a = configuration === null || configuration === void 0 ? void 0 : configuration.serverIndex) !== null && _a !== void 0 ? _a : 0;
|
|
182
|
+
const localVarOperationServerBasePath = (_c = (_b = base_1.operationServerMap['AISettingsApi.deleteSettings']) === null || _b === void 0 ? void 0 : _b[localVarOperationServerIndex]) === null || _c === void 0 ? void 0 : _c.url;
|
|
183
|
+
return (axios, basePath) => (0, common_1.createRequestFunction)(localVarAxiosArgs, axios_1.default, base_1.BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath);
|
|
184
|
+
});
|
|
185
|
+
},
|
|
186
|
+
/**
|
|
187
|
+
* Current user\'s chat-LLM override. The API key is never returned — only hasApiKey and its last characters.
|
|
188
|
+
* @summary Get my AI settings
|
|
189
|
+
* @param {*} [options] Override http request option.
|
|
190
|
+
* @throws {RequiredError}
|
|
191
|
+
*/
|
|
192
|
+
getSettings(options) {
|
|
193
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
194
|
+
var _a, _b, _c;
|
|
195
|
+
const localVarAxiosArgs = yield localVarAxiosParamCreator.getSettings(options);
|
|
196
|
+
const localVarOperationServerIndex = (_a = configuration === null || configuration === void 0 ? void 0 : configuration.serverIndex) !== null && _a !== void 0 ? _a : 0;
|
|
197
|
+
const localVarOperationServerBasePath = (_c = (_b = base_1.operationServerMap['AISettingsApi.getSettings']) === null || _b === void 0 ? void 0 : _b[localVarOperationServerIndex]) === null || _c === void 0 ? void 0 : _c.url;
|
|
198
|
+
return (axios, basePath) => (0, common_1.createRequestFunction)(localVarAxiosArgs, axios_1.default, base_1.BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath);
|
|
199
|
+
});
|
|
200
|
+
},
|
|
201
|
+
/**
|
|
202
|
+
* Set the chat LLM to use for my conversations. Omit apiKey to keep the previously stored key.
|
|
203
|
+
* @summary Save my AI settings
|
|
204
|
+
* @param {SaveAiSettingsRequest} saveAiSettingsRequest
|
|
205
|
+
* @param {*} [options] Override http request option.
|
|
206
|
+
* @throws {RequiredError}
|
|
207
|
+
*/
|
|
208
|
+
saveSettings(saveAiSettingsRequest, options) {
|
|
209
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
210
|
+
var _a, _b, _c;
|
|
211
|
+
const localVarAxiosArgs = yield localVarAxiosParamCreator.saveSettings(saveAiSettingsRequest, options);
|
|
212
|
+
const localVarOperationServerIndex = (_a = configuration === null || configuration === void 0 ? void 0 : configuration.serverIndex) !== null && _a !== void 0 ? _a : 0;
|
|
213
|
+
const localVarOperationServerBasePath = (_c = (_b = base_1.operationServerMap['AISettingsApi.saveSettings']) === null || _b === void 0 ? void 0 : _b[localVarOperationServerIndex]) === null || _c === void 0 ? void 0 : _c.url;
|
|
214
|
+
return (axios, basePath) => (0, common_1.createRequestFunction)(localVarAxiosArgs, axios_1.default, base_1.BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath);
|
|
215
|
+
});
|
|
216
|
+
},
|
|
217
|
+
/**
|
|
218
|
+
* Send a minimal completion request with the submitted settings (falls back to the stored key when apiKey is omitted).
|
|
219
|
+
* @summary Test AI provider connection
|
|
220
|
+
* @param {SaveAiSettingsRequest} saveAiSettingsRequest
|
|
221
|
+
* @param {*} [options] Override http request option.
|
|
222
|
+
* @throws {RequiredError}
|
|
223
|
+
*/
|
|
224
|
+
testConnection(saveAiSettingsRequest, options) {
|
|
225
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
226
|
+
var _a, _b, _c;
|
|
227
|
+
const localVarAxiosArgs = yield localVarAxiosParamCreator.testConnection(saveAiSettingsRequest, options);
|
|
228
|
+
const localVarOperationServerIndex = (_a = configuration === null || configuration === void 0 ? void 0 : configuration.serverIndex) !== null && _a !== void 0 ? _a : 0;
|
|
229
|
+
const localVarOperationServerBasePath = (_c = (_b = base_1.operationServerMap['AISettingsApi.testConnection']) === null || _b === void 0 ? void 0 : _b[localVarOperationServerIndex]) === null || _c === void 0 ? void 0 : _c.url;
|
|
230
|
+
return (axios, basePath) => (0, common_1.createRequestFunction)(localVarAxiosArgs, axios_1.default, base_1.BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath);
|
|
231
|
+
});
|
|
232
|
+
},
|
|
233
|
+
};
|
|
234
|
+
};
|
|
235
|
+
exports.AISettingsApiFp = AISettingsApiFp;
|
|
236
|
+
/**
|
|
237
|
+
* AISettingsApi - factory interface
|
|
238
|
+
*/
|
|
239
|
+
const AISettingsApiFactory = function (configuration, basePath, axios) {
|
|
240
|
+
const localVarFp = (0, exports.AISettingsApiFp)(configuration);
|
|
241
|
+
return {
|
|
242
|
+
/**
|
|
243
|
+
* Remove my chat-LLM override and go back to the server default model.
|
|
244
|
+
* @summary Reset my AI settings
|
|
245
|
+
* @param {*} [options] Override http request option.
|
|
246
|
+
* @throws {RequiredError}
|
|
247
|
+
*/
|
|
248
|
+
deleteSettings(options) {
|
|
249
|
+
return localVarFp.deleteSettings(options).then((request) => request(axios, basePath));
|
|
250
|
+
},
|
|
251
|
+
/**
|
|
252
|
+
* Current user\'s chat-LLM override. The API key is never returned — only hasApiKey and its last characters.
|
|
253
|
+
* @summary Get my AI settings
|
|
254
|
+
* @param {*} [options] Override http request option.
|
|
255
|
+
* @throws {RequiredError}
|
|
256
|
+
*/
|
|
257
|
+
getSettings(options) {
|
|
258
|
+
return localVarFp.getSettings(options).then((request) => request(axios, basePath));
|
|
259
|
+
},
|
|
260
|
+
/**
|
|
261
|
+
* Set the chat LLM to use for my conversations. Omit apiKey to keep the previously stored key.
|
|
262
|
+
* @summary Save my AI settings
|
|
263
|
+
* @param {SaveAiSettingsRequest} saveAiSettingsRequest
|
|
264
|
+
* @param {*} [options] Override http request option.
|
|
265
|
+
* @throws {RequiredError}
|
|
266
|
+
*/
|
|
267
|
+
saveSettings(saveAiSettingsRequest, options) {
|
|
268
|
+
return localVarFp.saveSettings(saveAiSettingsRequest, options).then((request) => request(axios, basePath));
|
|
269
|
+
},
|
|
270
|
+
/**
|
|
271
|
+
* Send a minimal completion request with the submitted settings (falls back to the stored key when apiKey is omitted).
|
|
272
|
+
* @summary Test AI provider connection
|
|
273
|
+
* @param {SaveAiSettingsRequest} saveAiSettingsRequest
|
|
274
|
+
* @param {*} [options] Override http request option.
|
|
275
|
+
* @throws {RequiredError}
|
|
276
|
+
*/
|
|
277
|
+
testConnection(saveAiSettingsRequest, options) {
|
|
278
|
+
return localVarFp.testConnection(saveAiSettingsRequest, options).then((request) => request(axios, basePath));
|
|
279
|
+
},
|
|
280
|
+
};
|
|
281
|
+
};
|
|
282
|
+
exports.AISettingsApiFactory = AISettingsApiFactory;
|
|
283
|
+
/**
|
|
284
|
+
* AISettingsApi - object-oriented interface
|
|
285
|
+
*/
|
|
286
|
+
class AISettingsApi extends base_1.BaseAPI {
|
|
287
|
+
/**
|
|
288
|
+
* Remove my chat-LLM override and go back to the server default model.
|
|
289
|
+
* @summary Reset my AI settings
|
|
290
|
+
* @param {*} [options] Override http request option.
|
|
291
|
+
* @throws {RequiredError}
|
|
292
|
+
*/
|
|
293
|
+
deleteSettings(options) {
|
|
294
|
+
return (0, exports.AISettingsApiFp)(this.configuration).deleteSettings(options).then((request) => request(this.axios, this.basePath));
|
|
295
|
+
}
|
|
296
|
+
/**
|
|
297
|
+
* Current user\'s chat-LLM override. The API key is never returned — only hasApiKey and its last characters.
|
|
298
|
+
* @summary Get my AI settings
|
|
299
|
+
* @param {*} [options] Override http request option.
|
|
300
|
+
* @throws {RequiredError}
|
|
301
|
+
*/
|
|
302
|
+
getSettings(options) {
|
|
303
|
+
return (0, exports.AISettingsApiFp)(this.configuration).getSettings(options).then((request) => request(this.axios, this.basePath));
|
|
304
|
+
}
|
|
305
|
+
/**
|
|
306
|
+
* Set the chat LLM to use for my conversations. Omit apiKey to keep the previously stored key.
|
|
307
|
+
* @summary Save my AI settings
|
|
308
|
+
* @param {SaveAiSettingsRequest} saveAiSettingsRequest
|
|
309
|
+
* @param {*} [options] Override http request option.
|
|
310
|
+
* @throws {RequiredError}
|
|
311
|
+
*/
|
|
312
|
+
saveSettings(saveAiSettingsRequest, options) {
|
|
313
|
+
return (0, exports.AISettingsApiFp)(this.configuration).saveSettings(saveAiSettingsRequest, options).then((request) => request(this.axios, this.basePath));
|
|
314
|
+
}
|
|
315
|
+
/**
|
|
316
|
+
* Send a minimal completion request with the submitted settings (falls back to the stored key when apiKey is omitted).
|
|
317
|
+
* @summary Test AI provider connection
|
|
318
|
+
* @param {SaveAiSettingsRequest} saveAiSettingsRequest
|
|
319
|
+
* @param {*} [options] Override http request option.
|
|
320
|
+
* @throws {RequiredError}
|
|
321
|
+
*/
|
|
322
|
+
testConnection(saveAiSettingsRequest, options) {
|
|
323
|
+
return (0, exports.AISettingsApiFp)(this.configuration).testConnection(saveAiSettingsRequest, options).then((request) => request(this.axios, this.basePath));
|
|
324
|
+
}
|
|
325
|
+
}
|
|
326
|
+
exports.AISettingsApi = AISettingsApi;
|
|
@@ -23,7 +23,7 @@ export declare const SettingsApiAxiosParamCreator: (configuration?: Configuratio
|
|
|
23
23
|
* @param {*} [options] Override http request option.
|
|
24
24
|
* @throws {RequiredError}
|
|
25
25
|
*/
|
|
26
|
-
|
|
26
|
+
getSettings1: (options?: RawAxiosRequestConfig) => Promise<RequestArgs>;
|
|
27
27
|
};
|
|
28
28
|
/**
|
|
29
29
|
* SettingsApi - functional programming interface
|
|
@@ -35,7 +35,7 @@ export declare const SettingsApiFp: (configuration?: Configuration) => {
|
|
|
35
35
|
* @param {*} [options] Override http request option.
|
|
36
36
|
* @throws {RequiredError}
|
|
37
37
|
*/
|
|
38
|
-
|
|
38
|
+
getSettings1(options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<Settings>>;
|
|
39
39
|
};
|
|
40
40
|
/**
|
|
41
41
|
* SettingsApi - factory interface
|
|
@@ -47,7 +47,7 @@ export declare const SettingsApiFactory: (configuration?: Configuration, basePat
|
|
|
47
47
|
* @param {*} [options] Override http request option.
|
|
48
48
|
* @throws {RequiredError}
|
|
49
49
|
*/
|
|
50
|
-
|
|
50
|
+
getSettings1(options?: RawAxiosRequestConfig): AxiosPromise<Settings>;
|
|
51
51
|
};
|
|
52
52
|
/**
|
|
53
53
|
* SettingsApi - object-oriented interface
|
|
@@ -59,5 +59,5 @@ export declare class SettingsApi extends BaseAPI {
|
|
|
59
59
|
* @param {*} [options] Override http request option.
|
|
60
60
|
* @throws {RequiredError}
|
|
61
61
|
*/
|
|
62
|
-
|
|
62
|
+
getSettings1(options?: RawAxiosRequestConfig): Promise<import("axios").AxiosResponse<Settings, any, {}>>;
|
|
63
63
|
}
|
package/dist/api/settings-api.js
CHANGED
|
@@ -40,7 +40,7 @@ const SettingsApiAxiosParamCreator = function (configuration) {
|
|
|
40
40
|
* @param {*} [options] Override http request option.
|
|
41
41
|
* @throws {RequiredError}
|
|
42
42
|
*/
|
|
43
|
-
|
|
43
|
+
getSettings1: (...args_1) => __awaiter(this, [...args_1], void 0, function* (options = {}) {
|
|
44
44
|
const localVarPath = `/api/v1/settings`;
|
|
45
45
|
// use dummy base URL string because the URL constructor only accepts absolute URLs.
|
|
46
46
|
const localVarUrlObj = new URL(localVarPath, common_1.DUMMY_BASE_URL);
|
|
@@ -78,12 +78,12 @@ const SettingsApiFp = function (configuration) {
|
|
|
78
78
|
* @param {*} [options] Override http request option.
|
|
79
79
|
* @throws {RequiredError}
|
|
80
80
|
*/
|
|
81
|
-
|
|
81
|
+
getSettings1(options) {
|
|
82
82
|
return __awaiter(this, void 0, void 0, function* () {
|
|
83
83
|
var _a, _b, _c;
|
|
84
|
-
const localVarAxiosArgs = yield localVarAxiosParamCreator.
|
|
84
|
+
const localVarAxiosArgs = yield localVarAxiosParamCreator.getSettings1(options);
|
|
85
85
|
const localVarOperationServerIndex = (_a = configuration === null || configuration === void 0 ? void 0 : configuration.serverIndex) !== null && _a !== void 0 ? _a : 0;
|
|
86
|
-
const localVarOperationServerBasePath = (_c = (_b = base_1.operationServerMap['SettingsApi.
|
|
86
|
+
const localVarOperationServerBasePath = (_c = (_b = base_1.operationServerMap['SettingsApi.getSettings1']) === null || _b === void 0 ? void 0 : _b[localVarOperationServerIndex]) === null || _c === void 0 ? void 0 : _c.url;
|
|
87
87
|
return (axios, basePath) => (0, common_1.createRequestFunction)(localVarAxiosArgs, axios_1.default, base_1.BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath);
|
|
88
88
|
});
|
|
89
89
|
},
|
|
@@ -102,8 +102,8 @@ const SettingsApiFactory = function (configuration, basePath, axios) {
|
|
|
102
102
|
* @param {*} [options] Override http request option.
|
|
103
103
|
* @throws {RequiredError}
|
|
104
104
|
*/
|
|
105
|
-
|
|
106
|
-
return localVarFp.
|
|
105
|
+
getSettings1(options) {
|
|
106
|
+
return localVarFp.getSettings1(options).then((request) => request(axios, basePath));
|
|
107
107
|
},
|
|
108
108
|
};
|
|
109
109
|
};
|
|
@@ -118,8 +118,8 @@ class SettingsApi extends base_1.BaseAPI {
|
|
|
118
118
|
* @param {*} [options] Override http request option.
|
|
119
119
|
* @throws {RequiredError}
|
|
120
120
|
*/
|
|
121
|
-
|
|
122
|
-
return (0, exports.SettingsApiFp)(this.configuration).
|
|
121
|
+
getSettings1(options) {
|
|
122
|
+
return (0, exports.SettingsApiFp)(this.configuration).getSettings1(options).then((request) => request(this.axios, this.basePath));
|
|
123
123
|
}
|
|
124
124
|
}
|
|
125
125
|
exports.SettingsApi = SettingsApi;
|
package/dist/api.d.ts
CHANGED
|
@@ -9,6 +9,8 @@
|
|
|
9
9
|
* https://openapi-generator.tech
|
|
10
10
|
* Do not edit the class manually.
|
|
11
11
|
*/
|
|
12
|
+
export * from './api/aichat-api';
|
|
13
|
+
export * from './api/aisettings-api';
|
|
12
14
|
export * from './api/audit-controller-api';
|
|
13
15
|
export * from './api/dashboard-api';
|
|
14
16
|
export * from './api/document-controller-api';
|
package/dist/api.js
CHANGED
|
@@ -27,6 +27,8 @@ var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
|
27
27
|
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
28
28
|
};
|
|
29
29
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
30
|
+
__exportStar(require("./api/aichat-api"), exports);
|
|
31
|
+
__exportStar(require("./api/aisettings-api"), exports);
|
|
30
32
|
__exportStar(require("./api/audit-controller-api"), exports);
|
|
31
33
|
__exportStar(require("./api/dashboard-api"), exports);
|
|
32
34
|
__exportStar(require("./api/document-controller-api"), exports);
|
|
@@ -0,0 +1,161 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* openfilz-api
|
|
3
|
+
* API for Document Management System
|
|
4
|
+
*
|
|
5
|
+
* The version of the OpenAPI document: 1.0.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 { AxiosPromise, AxiosInstance, RawAxiosRequestConfig } from 'axios';
|
|
14
|
+
import { type RequestArgs, BaseAPI } from '../base';
|
|
15
|
+
import type { AiChatConversation } from '../models';
|
|
16
|
+
import type { AiChatRequest } from '../models';
|
|
17
|
+
import type { AiChatResponse } from '../models';
|
|
18
|
+
/**
|
|
19
|
+
* AIChatApi - axios parameter creator
|
|
20
|
+
*/
|
|
21
|
+
export declare const AIChatApiAxiosParamCreator: (configuration?: Configuration) => {
|
|
22
|
+
/**
|
|
23
|
+
* Send a message and receive a streaming response. The AI can answer questions about documents, search, summarize, and reorganize files.
|
|
24
|
+
* @summary Chat with AI assistant
|
|
25
|
+
* @param {AiChatRequest} aiChatRequest
|
|
26
|
+
* @param {*} [options] Override http request option.
|
|
27
|
+
* @throws {RequiredError}
|
|
28
|
+
*/
|
|
29
|
+
chat: (aiChatRequest: AiChatRequest, options?: RawAxiosRequestConfig) => Promise<RequestArgs>;
|
|
30
|
+
/**
|
|
31
|
+
* Delete a conversation and all its messages
|
|
32
|
+
* @summary Delete conversation
|
|
33
|
+
* @param {string} conversationId
|
|
34
|
+
* @param {*} [options] Override http request option.
|
|
35
|
+
* @throws {RequiredError}
|
|
36
|
+
*/
|
|
37
|
+
deleteConversation: (conversationId: string, options?: RawAxiosRequestConfig) => Promise<RequestArgs>;
|
|
38
|
+
/**
|
|
39
|
+
* Get all messages in a conversation
|
|
40
|
+
* @summary Get conversation history
|
|
41
|
+
* @param {string} conversationId
|
|
42
|
+
* @param {*} [options] Override http request option.
|
|
43
|
+
* @throws {RequiredError}
|
|
44
|
+
*/
|
|
45
|
+
getConversationHistory: (conversationId: string, options?: RawAxiosRequestConfig) => Promise<RequestArgs>;
|
|
46
|
+
/**
|
|
47
|
+
* Get all AI chat conversations for the current user
|
|
48
|
+
* @summary List conversations
|
|
49
|
+
* @param {*} [options] Override http request option.
|
|
50
|
+
* @throws {RequiredError}
|
|
51
|
+
*/
|
|
52
|
+
listConversations: (options?: RawAxiosRequestConfig) => Promise<RequestArgs>;
|
|
53
|
+
};
|
|
54
|
+
/**
|
|
55
|
+
* AIChatApi - functional programming interface
|
|
56
|
+
*/
|
|
57
|
+
export declare const AIChatApiFp: (configuration?: Configuration) => {
|
|
58
|
+
/**
|
|
59
|
+
* Send a message and receive a streaming response. The AI can answer questions about documents, search, summarize, and reorganize files.
|
|
60
|
+
* @summary Chat with AI assistant
|
|
61
|
+
* @param {AiChatRequest} aiChatRequest
|
|
62
|
+
* @param {*} [options] Override http request option.
|
|
63
|
+
* @throws {RequiredError}
|
|
64
|
+
*/
|
|
65
|
+
chat(aiChatRequest: AiChatRequest, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<Array<AiChatResponse>>>;
|
|
66
|
+
/**
|
|
67
|
+
* Delete a conversation and all its messages
|
|
68
|
+
* @summary Delete conversation
|
|
69
|
+
* @param {string} conversationId
|
|
70
|
+
* @param {*} [options] Override http request option.
|
|
71
|
+
* @throws {RequiredError}
|
|
72
|
+
*/
|
|
73
|
+
deleteConversation(conversationId: string, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<void>>;
|
|
74
|
+
/**
|
|
75
|
+
* Get all messages in a conversation
|
|
76
|
+
* @summary Get conversation history
|
|
77
|
+
* @param {string} conversationId
|
|
78
|
+
* @param {*} [options] Override http request option.
|
|
79
|
+
* @throws {RequiredError}
|
|
80
|
+
*/
|
|
81
|
+
getConversationHistory(conversationId: string, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<Array<AiChatResponse>>>;
|
|
82
|
+
/**
|
|
83
|
+
* Get all AI chat conversations for the current user
|
|
84
|
+
* @summary List conversations
|
|
85
|
+
* @param {*} [options] Override http request option.
|
|
86
|
+
* @throws {RequiredError}
|
|
87
|
+
*/
|
|
88
|
+
listConversations(options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<Array<AiChatConversation>>>;
|
|
89
|
+
};
|
|
90
|
+
/**
|
|
91
|
+
* AIChatApi - factory interface
|
|
92
|
+
*/
|
|
93
|
+
export declare const AIChatApiFactory: (configuration?: Configuration, basePath?: string, axios?: AxiosInstance) => {
|
|
94
|
+
/**
|
|
95
|
+
* Send a message and receive a streaming response. The AI can answer questions about documents, search, summarize, and reorganize files.
|
|
96
|
+
* @summary Chat with AI assistant
|
|
97
|
+
* @param {AiChatRequest} aiChatRequest
|
|
98
|
+
* @param {*} [options] Override http request option.
|
|
99
|
+
* @throws {RequiredError}
|
|
100
|
+
*/
|
|
101
|
+
chat(aiChatRequest: AiChatRequest, options?: RawAxiosRequestConfig): AxiosPromise<Array<AiChatResponse>>;
|
|
102
|
+
/**
|
|
103
|
+
* Delete a conversation and all its messages
|
|
104
|
+
* @summary Delete conversation
|
|
105
|
+
* @param {string} conversationId
|
|
106
|
+
* @param {*} [options] Override http request option.
|
|
107
|
+
* @throws {RequiredError}
|
|
108
|
+
*/
|
|
109
|
+
deleteConversation(conversationId: string, options?: RawAxiosRequestConfig): AxiosPromise<void>;
|
|
110
|
+
/**
|
|
111
|
+
* Get all messages in a conversation
|
|
112
|
+
* @summary Get conversation history
|
|
113
|
+
* @param {string} conversationId
|
|
114
|
+
* @param {*} [options] Override http request option.
|
|
115
|
+
* @throws {RequiredError}
|
|
116
|
+
*/
|
|
117
|
+
getConversationHistory(conversationId: string, options?: RawAxiosRequestConfig): AxiosPromise<Array<AiChatResponse>>;
|
|
118
|
+
/**
|
|
119
|
+
* Get all AI chat conversations for the current user
|
|
120
|
+
* @summary List conversations
|
|
121
|
+
* @param {*} [options] Override http request option.
|
|
122
|
+
* @throws {RequiredError}
|
|
123
|
+
*/
|
|
124
|
+
listConversations(options?: RawAxiosRequestConfig): AxiosPromise<Array<AiChatConversation>>;
|
|
125
|
+
};
|
|
126
|
+
/**
|
|
127
|
+
* AIChatApi - object-oriented interface
|
|
128
|
+
*/
|
|
129
|
+
export declare class AIChatApi extends BaseAPI {
|
|
130
|
+
/**
|
|
131
|
+
* Send a message and receive a streaming response. The AI can answer questions about documents, search, summarize, and reorganize files.
|
|
132
|
+
* @summary Chat with AI assistant
|
|
133
|
+
* @param {AiChatRequest} aiChatRequest
|
|
134
|
+
* @param {*} [options] Override http request option.
|
|
135
|
+
* @throws {RequiredError}
|
|
136
|
+
*/
|
|
137
|
+
chat(aiChatRequest: AiChatRequest, options?: RawAxiosRequestConfig): Promise<import("axios").AxiosResponse<AiChatResponse[], any, {}>>;
|
|
138
|
+
/**
|
|
139
|
+
* Delete a conversation and all its messages
|
|
140
|
+
* @summary Delete conversation
|
|
141
|
+
* @param {string} conversationId
|
|
142
|
+
* @param {*} [options] Override http request option.
|
|
143
|
+
* @throws {RequiredError}
|
|
144
|
+
*/
|
|
145
|
+
deleteConversation(conversationId: string, options?: RawAxiosRequestConfig): Promise<import("axios").AxiosResponse<void, any, {}>>;
|
|
146
|
+
/**
|
|
147
|
+
* Get all messages in a conversation
|
|
148
|
+
* @summary Get conversation history
|
|
149
|
+
* @param {string} conversationId
|
|
150
|
+
* @param {*} [options] Override http request option.
|
|
151
|
+
* @throws {RequiredError}
|
|
152
|
+
*/
|
|
153
|
+
getConversationHistory(conversationId: string, options?: RawAxiosRequestConfig): Promise<import("axios").AxiosResponse<AiChatResponse[], any, {}>>;
|
|
154
|
+
/**
|
|
155
|
+
* Get all AI chat conversations for the current user
|
|
156
|
+
* @summary List conversations
|
|
157
|
+
* @param {*} [options] Override http request option.
|
|
158
|
+
* @throws {RequiredError}
|
|
159
|
+
*/
|
|
160
|
+
listConversations(options?: RawAxiosRequestConfig): Promise<import("axios").AxiosResponse<AiChatConversation[], any, {}>>;
|
|
161
|
+
}
|