kb-cloud-client-typescript 2.3.0-alpha.107 → 2.3.0-alpha.108
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/dist/adminapi/api.d.ts +0 -1
- package/dist/adminapi/api.d.ts.map +1 -1
- package/dist/adminapi/api.js +0 -1
- package/dist/adminapi/api.js.map +1 -1
- package/dist/adminapi/models/account-option.d.ts +7 -1
- package/dist/adminapi/models/account-option.d.ts.map +1 -1
- package/dist/adminapi/models/index.d.ts +0 -10
- package/dist/adminapi/models/index.d.ts.map +1 -1
- package/dist/adminapi/models/index.js +0 -10
- package/dist/adminapi/models/index.js.map +1 -1
- package/dist/openapi/api.d.ts +0 -1
- package/dist/openapi/api.d.ts.map +1 -1
- package/dist/openapi/api.js +0 -1
- package/dist/openapi/api.js.map +1 -1
- package/dist/openapi/models/account-option.d.ts +7 -1
- package/dist/openapi/models/account-option.d.ts.map +1 -1
- package/dist/openapi/models/index.d.ts +0 -10
- package/dist/openapi/models/index.d.ts.map +1 -1
- package/dist/openapi/models/index.js +0 -10
- package/dist/openapi/models/index.js.map +1 -1
- package/package.json +1 -1
- package/src/adminapi/.openapi-generator/FILES +0 -11
- package/src/adminapi/api.ts +0 -1
- package/src/adminapi/models/account-option.ts +7 -1
- package/src/adminapi/models/index.ts +0 -10
- package/src/adminapi.yaml +6 -382
- package/src/openapi/.openapi-generator/FILES +0 -11
- package/src/openapi/api.ts +0 -1
- package/src/openapi/models/account-option.ts +7 -1
- package/src/openapi/models/index.ts +0 -10
- package/src/openapi.yaml +6 -382
- package/dist/adminapi/apis/aiapi.d.ts +0 -408
- package/dist/adminapi/apis/aiapi.d.ts.map +0 -1
- package/dist/adminapi/apis/aiapi.js +0 -496
- package/dist/adminapi/apis/aiapi.js.map +0 -1
- package/dist/adminapi/models/ai-conversation-list-response.d.ts +0 -32
- package/dist/adminapi/models/ai-conversation-list-response.d.ts.map +0 -1
- package/dist/adminapi/models/ai-conversation-list-response.js +0 -16
- package/dist/adminapi/models/ai-conversation-list-response.js.map +0 -1
- package/dist/adminapi/models/ai-conversation.d.ts +0 -67
- package/dist/adminapi/models/ai-conversation.d.ts.map +0 -1
- package/dist/adminapi/models/ai-conversation.js +0 -16
- package/dist/adminapi/models/ai-conversation.js.map +0 -1
- package/dist/adminapi/models/ai-message-list-response.d.ts +0 -26
- package/dist/adminapi/models/ai-message-list-response.d.ts.map +0 -1
- package/dist/adminapi/models/ai-message-list-response.js +0 -16
- package/dist/adminapi/models/ai-message-list-response.js.map +0 -1
- package/dist/adminapi/models/ai-message.d.ts +0 -70
- package/dist/adminapi/models/ai-message.d.ts.map +0 -1
- package/dist/adminapi/models/ai-message.js +0 -16
- package/dist/adminapi/models/ai-message.js.map +0 -1
- package/dist/adminapi/models/aichat-type.d.ts +0 -22
- package/dist/adminapi/models/aichat-type.d.ts.map +0 -1
- package/dist/adminapi/models/aichat-type.js +0 -26
- package/dist/adminapi/models/aichat-type.js.map +0 -1
- package/dist/adminapi/models/aiconversation-request.d.ts +0 -26
- package/dist/adminapi/models/aiconversation-request.d.ts.map +0 -1
- package/dist/adminapi/models/aiconversation-request.js +0 -16
- package/dist/adminapi/models/aiconversation-request.js.map +0 -1
- package/dist/adminapi/models/chat-request.d.ts +0 -79
- package/dist/adminapi/models/chat-request.d.ts.map +0 -1
- package/dist/adminapi/models/chat-request.js +0 -16
- package/dist/adminapi/models/chat-request.js.map +0 -1
- package/dist/adminapi/models/chat-response-type.d.ts +0 -29
- package/dist/adminapi/models/chat-response-type.d.ts.map +0 -1
- package/dist/adminapi/models/chat-response-type.js +0 -33
- package/dist/adminapi/models/chat-response-type.js.map +0 -1
- package/dist/adminapi/models/chat-response.d.ts +0 -50
- package/dist/adminapi/models/chat-response.d.ts.map +0 -1
- package/dist/adminapi/models/chat-response.js +0 -16
- package/dist/adminapi/models/chat-response.js.map +0 -1
- package/dist/adminapi/models/sender-type.d.ts +0 -23
- package/dist/adminapi/models/sender-type.d.ts.map +0 -1
- package/dist/adminapi/models/sender-type.js +0 -27
- package/dist/adminapi/models/sender-type.js.map +0 -1
- package/dist/openapi/apis/aiapi.d.ts +0 -408
- package/dist/openapi/apis/aiapi.d.ts.map +0 -1
- package/dist/openapi/apis/aiapi.js +0 -496
- package/dist/openapi/apis/aiapi.js.map +0 -1
- package/dist/openapi/models/ai-conversation-list-response.d.ts +0 -32
- package/dist/openapi/models/ai-conversation-list-response.d.ts.map +0 -1
- package/dist/openapi/models/ai-conversation-list-response.js +0 -16
- package/dist/openapi/models/ai-conversation-list-response.js.map +0 -1
- package/dist/openapi/models/ai-conversation.d.ts +0 -67
- package/dist/openapi/models/ai-conversation.d.ts.map +0 -1
- package/dist/openapi/models/ai-conversation.js +0 -16
- package/dist/openapi/models/ai-conversation.js.map +0 -1
- package/dist/openapi/models/ai-message-list-response.d.ts +0 -26
- package/dist/openapi/models/ai-message-list-response.d.ts.map +0 -1
- package/dist/openapi/models/ai-message-list-response.js +0 -16
- package/dist/openapi/models/ai-message-list-response.js.map +0 -1
- package/dist/openapi/models/ai-message.d.ts +0 -70
- package/dist/openapi/models/ai-message.d.ts.map +0 -1
- package/dist/openapi/models/ai-message.js +0 -16
- package/dist/openapi/models/ai-message.js.map +0 -1
- package/dist/openapi/models/aichat-type.d.ts +0 -22
- package/dist/openapi/models/aichat-type.d.ts.map +0 -1
- package/dist/openapi/models/aichat-type.js +0 -26
- package/dist/openapi/models/aichat-type.js.map +0 -1
- package/dist/openapi/models/aiconversation-request.d.ts +0 -26
- package/dist/openapi/models/aiconversation-request.d.ts.map +0 -1
- package/dist/openapi/models/aiconversation-request.js +0 -16
- package/dist/openapi/models/aiconversation-request.js.map +0 -1
- package/dist/openapi/models/chat-request.d.ts +0 -79
- package/dist/openapi/models/chat-request.d.ts.map +0 -1
- package/dist/openapi/models/chat-request.js +0 -16
- package/dist/openapi/models/chat-request.js.map +0 -1
- package/dist/openapi/models/chat-response-type.d.ts +0 -29
- package/dist/openapi/models/chat-response-type.d.ts.map +0 -1
- package/dist/openapi/models/chat-response-type.js +0 -33
- package/dist/openapi/models/chat-response-type.js.map +0 -1
- package/dist/openapi/models/chat-response.d.ts +0 -50
- package/dist/openapi/models/chat-response.d.ts.map +0 -1
- package/dist/openapi/models/chat-response.js +0 -16
- package/dist/openapi/models/chat-response.js.map +0 -1
- package/dist/openapi/models/sender-type.d.ts +0 -23
- package/dist/openapi/models/sender-type.d.ts.map +0 -1
- package/dist/openapi/models/sender-type.js +0 -27
- package/dist/openapi/models/sender-type.js.map +0 -1
- package/src/adminapi/apis/aiapi.ts +0 -728
- package/src/adminapi/models/ai-conversation-list-response.ts +0 -39
- package/src/adminapi/models/ai-conversation.ts +0 -72
- package/src/adminapi/models/ai-message-list-response.ts +0 -33
- package/src/adminapi/models/ai-message.ts +0 -77
- package/src/adminapi/models/aichat-type.ts +0 -31
- package/src/adminapi/models/aiconversation-request.ts +0 -35
- package/src/adminapi/models/chat-request.ts +0 -84
- package/src/adminapi/models/chat-response-type.ts +0 -38
- package/src/adminapi/models/chat-response.ts +0 -59
- package/src/adminapi/models/sender-type.ts +0 -32
- package/src/openapi/apis/aiapi.ts +0 -728
- package/src/openapi/models/ai-conversation-list-response.ts +0 -39
- package/src/openapi/models/ai-conversation.ts +0 -72
- package/src/openapi/models/ai-message-list-response.ts +0 -33
- package/src/openapi/models/ai-message.ts +0 -77
- package/src/openapi/models/aichat-type.ts +0 -31
- package/src/openapi/models/aiconversation-request.ts +0 -35
- package/src/openapi/models/chat-request.ts +0 -84
- package/src/openapi/models/chat-response-type.ts +0 -38
- package/src/openapi/models/chat-response.ts +0 -59
- package/src/openapi/models/sender-type.ts +0 -32
|
@@ -1,728 +0,0 @@
|
|
|
1
|
-
/* tslint:disable */
|
|
2
|
-
/* eslint-disable */
|
|
3
|
-
/**
|
|
4
|
-
* KubeBlocks Cloud API
|
|
5
|
-
* KubeBlocks Cloud API is a RESTful API for managing KubeBlocks Cloud resources. The API is organized around REST. Our API has predictable resource-oriented URLs, accepts `JSON-encoded` request bodies, returns `JSON-encoded` responses, and uses standard HTTP response codes, authentication, and verbs. We use standard HTTP authentication and provide API keys to identify who you are. Your API keys carry many privileges, so be sure to keep them secret! Do not share your secret API keys in publicly accessible areas such as GitHub, client-side code, and so forth.
|
|
6
|
-
*
|
|
7
|
-
* The version of the OpenAPI document: 1.0.0
|
|
8
|
-
* Contact: support@apecloud.com
|
|
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
|
-
|
|
16
|
-
import type { Configuration } from '../configuration';
|
|
17
|
-
import type { AxiosPromise, AxiosInstance, RawAxiosRequestConfig } from 'axios';
|
|
18
|
-
import globalAxios from 'axios';
|
|
19
|
-
// Some imports not used depending on template conditions
|
|
20
|
-
// @ts-ignore
|
|
21
|
-
import { DUMMY_BASE_URL, assertParamExists, setApiKeyToObject, setBasicAuthToObject, setBearerAuthToObject, setOAuthToObject, setSearchParams, serializeDataIfNeeded, toPathString, createRequestFunction } from '../common';
|
|
22
|
-
// @ts-ignore
|
|
23
|
-
import { BASE_PATH, COLLECTION_FORMATS, type RequestArgs, BaseAPI, RequiredError, operationServerMap } from '../base';
|
|
24
|
-
// @ts-ignore
|
|
25
|
-
import type { AIConversationRequest } from '../models';
|
|
26
|
-
// @ts-ignore
|
|
27
|
-
import type { APIErrorResponse } from '../models';
|
|
28
|
-
// @ts-ignore
|
|
29
|
-
import type { AiConversation } from '../models';
|
|
30
|
-
// @ts-ignore
|
|
31
|
-
import type { AiConversationListResponse } from '../models';
|
|
32
|
-
// @ts-ignore
|
|
33
|
-
import type { AiMessageListResponse } from '../models';
|
|
34
|
-
// @ts-ignore
|
|
35
|
-
import type { ChatRequest } from '../models';
|
|
36
|
-
// @ts-ignore
|
|
37
|
-
import type { ChatResponse } from '../models';
|
|
38
|
-
/**
|
|
39
|
-
* AIApi - axios parameter creator
|
|
40
|
-
* @export
|
|
41
|
-
*/
|
|
42
|
-
export const AIApiAxiosParamCreator = function (configuration?: Configuration) {
|
|
43
|
-
return {
|
|
44
|
-
/**
|
|
45
|
-
* Establishes an SSE connection for AI BI conversation.
|
|
46
|
-
* @summary SSE endpoint for Chat BI V2
|
|
47
|
-
* @param {ChatRequest} chatRequest
|
|
48
|
-
* @param {*} [options] Override http request option.
|
|
49
|
-
* @throws {RequiredError}
|
|
50
|
-
*/
|
|
51
|
-
chatBIV2SSE: async (chatRequest: ChatRequest, options: RawAxiosRequestConfig = {}): Promise<RequestArgs> => {
|
|
52
|
-
// verify required parameter 'chatRequest' is not null or undefined
|
|
53
|
-
assertParamExists('chatBIV2SSE', 'chatRequest', chatRequest)
|
|
54
|
-
const localVarPath = `/api/v1/ai/chatbi/v2`;
|
|
55
|
-
// use dummy base URL string because the URL constructor only accepts absolute URLs.
|
|
56
|
-
const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
|
|
57
|
-
let baseOptions;
|
|
58
|
-
if (configuration) {
|
|
59
|
-
baseOptions = configuration.baseOptions;
|
|
60
|
-
}
|
|
61
|
-
|
|
62
|
-
const localVarRequestOptions = { method: 'POST', ...baseOptions, ...options};
|
|
63
|
-
const localVarHeaderParameter = {} as any;
|
|
64
|
-
const localVarQueryParameter = {} as any;
|
|
65
|
-
|
|
66
|
-
// authentication BearerToken required
|
|
67
|
-
// http bearer authentication required
|
|
68
|
-
await setBearerAuthToObject(localVarHeaderParameter, configuration)
|
|
69
|
-
|
|
70
|
-
// authentication DigestAuth required
|
|
71
|
-
await setApiKeyToObject(localVarHeaderParameter, "Authorization", configuration)
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
localVarHeaderParameter['Content-Type'] = 'application/json';
|
|
76
|
-
|
|
77
|
-
setSearchParams(localVarUrlObj, localVarQueryParameter);
|
|
78
|
-
let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
|
|
79
|
-
localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers};
|
|
80
|
-
localVarRequestOptions.data = serializeDataIfNeeded(chatRequest, localVarRequestOptions, configuration)
|
|
81
|
-
|
|
82
|
-
return {
|
|
83
|
-
url: toPathString(localVarUrlObj),
|
|
84
|
-
options: localVarRequestOptions,
|
|
85
|
-
};
|
|
86
|
-
},
|
|
87
|
-
/**
|
|
88
|
-
* Establishes an SSE connection for AI conversation.
|
|
89
|
-
* @summary SSE endpoint for Chat V2
|
|
90
|
-
* @param {ChatRequest} chatRequest
|
|
91
|
-
* @param {*} [options] Override http request option.
|
|
92
|
-
* @throws {RequiredError}
|
|
93
|
-
*/
|
|
94
|
-
chatV2SSE: async (chatRequest: ChatRequest, options: RawAxiosRequestConfig = {}): Promise<RequestArgs> => {
|
|
95
|
-
// verify required parameter 'chatRequest' is not null or undefined
|
|
96
|
-
assertParamExists('chatV2SSE', 'chatRequest', chatRequest)
|
|
97
|
-
const localVarPath = `/api/v1/ai/chatops/v2`;
|
|
98
|
-
// use dummy base URL string because the URL constructor only accepts absolute URLs.
|
|
99
|
-
const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
|
|
100
|
-
let baseOptions;
|
|
101
|
-
if (configuration) {
|
|
102
|
-
baseOptions = configuration.baseOptions;
|
|
103
|
-
}
|
|
104
|
-
|
|
105
|
-
const localVarRequestOptions = { method: 'POST', ...baseOptions, ...options};
|
|
106
|
-
const localVarHeaderParameter = {} as any;
|
|
107
|
-
const localVarQueryParameter = {} as any;
|
|
108
|
-
|
|
109
|
-
// authentication BearerToken required
|
|
110
|
-
// http bearer authentication required
|
|
111
|
-
await setBearerAuthToObject(localVarHeaderParameter, configuration)
|
|
112
|
-
|
|
113
|
-
// authentication DigestAuth required
|
|
114
|
-
await setApiKeyToObject(localVarHeaderParameter, "Authorization", configuration)
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
localVarHeaderParameter['Content-Type'] = 'application/json';
|
|
119
|
-
|
|
120
|
-
setSearchParams(localVarUrlObj, localVarQueryParameter);
|
|
121
|
-
let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
|
|
122
|
-
localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers};
|
|
123
|
-
localVarRequestOptions.data = serializeDataIfNeeded(chatRequest, localVarRequestOptions, configuration)
|
|
124
|
-
|
|
125
|
-
return {
|
|
126
|
-
url: toPathString(localVarUrlObj),
|
|
127
|
-
options: localVarRequestOptions,
|
|
128
|
-
};
|
|
129
|
-
},
|
|
130
|
-
/**
|
|
131
|
-
* Deletes a specific conversation and all its associated messages.
|
|
132
|
-
* @summary Delete a conversation
|
|
133
|
-
* @param {string} conversationId ID of the conversation to delete
|
|
134
|
-
* @param {*} [options] Override http request option.
|
|
135
|
-
* @throws {RequiredError}
|
|
136
|
-
*/
|
|
137
|
-
deleteConversation: async (conversationId: string, options: RawAxiosRequestConfig = {}): Promise<RequestArgs> => {
|
|
138
|
-
// verify required parameter 'conversationId' is not null or undefined
|
|
139
|
-
assertParamExists('deleteConversation', 'conversationId', conversationId)
|
|
140
|
-
const localVarPath = `/api/v1/ai/conversations/{conversationId}`
|
|
141
|
-
.replace(`{${"conversationId"}}`, encodeURIComponent(String(conversationId)));
|
|
142
|
-
// use dummy base URL string because the URL constructor only accepts absolute URLs.
|
|
143
|
-
const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
|
|
144
|
-
let baseOptions;
|
|
145
|
-
if (configuration) {
|
|
146
|
-
baseOptions = configuration.baseOptions;
|
|
147
|
-
}
|
|
148
|
-
|
|
149
|
-
const localVarRequestOptions = { method: 'DELETE', ...baseOptions, ...options};
|
|
150
|
-
const localVarHeaderParameter = {} as any;
|
|
151
|
-
const localVarQueryParameter = {} as any;
|
|
152
|
-
|
|
153
|
-
// authentication BearerToken required
|
|
154
|
-
// http bearer authentication required
|
|
155
|
-
await setBearerAuthToObject(localVarHeaderParameter, configuration)
|
|
156
|
-
|
|
157
|
-
// authentication DigestAuth required
|
|
158
|
-
await setApiKeyToObject(localVarHeaderParameter, "Authorization", configuration)
|
|
159
|
-
|
|
160
|
-
|
|
161
|
-
|
|
162
|
-
setSearchParams(localVarUrlObj, localVarQueryParameter);
|
|
163
|
-
let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
|
|
164
|
-
localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers};
|
|
165
|
-
|
|
166
|
-
return {
|
|
167
|
-
url: toPathString(localVarUrlObj),
|
|
168
|
-
options: localVarRequestOptions,
|
|
169
|
-
};
|
|
170
|
-
},
|
|
171
|
-
/**
|
|
172
|
-
* Retrieves ai messages for a specific conversation. If pre is not provided, returns the last 10 turn messages. If pre is provided, returns 10 turn messages after the pre message.
|
|
173
|
-
* @summary Get AI conversation messages
|
|
174
|
-
* @param {string} conversationId ID of the conversation
|
|
175
|
-
* @param {string} [pre] Previous message ID
|
|
176
|
-
* @param {*} [options] Override http request option.
|
|
177
|
-
* @throws {RequiredError}
|
|
178
|
-
*/
|
|
179
|
-
getConversationMessages: async (conversationId: string, pre?: string, options: RawAxiosRequestConfig = {}): Promise<RequestArgs> => {
|
|
180
|
-
// verify required parameter 'conversationId' is not null or undefined
|
|
181
|
-
assertParamExists('getConversationMessages', 'conversationId', conversationId)
|
|
182
|
-
const localVarPath = `/api/v1/ai/conversations/{conversationId}/messages`
|
|
183
|
-
.replace(`{${"conversationId"}}`, encodeURIComponent(String(conversationId)));
|
|
184
|
-
// use dummy base URL string because the URL constructor only accepts absolute URLs.
|
|
185
|
-
const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
|
|
186
|
-
let baseOptions;
|
|
187
|
-
if (configuration) {
|
|
188
|
-
baseOptions = configuration.baseOptions;
|
|
189
|
-
}
|
|
190
|
-
|
|
191
|
-
const localVarRequestOptions = { method: 'GET', ...baseOptions, ...options};
|
|
192
|
-
const localVarHeaderParameter = {} as any;
|
|
193
|
-
const localVarQueryParameter = {} as any;
|
|
194
|
-
|
|
195
|
-
// authentication BearerToken required
|
|
196
|
-
// http bearer authentication required
|
|
197
|
-
await setBearerAuthToObject(localVarHeaderParameter, configuration)
|
|
198
|
-
|
|
199
|
-
// authentication DigestAuth required
|
|
200
|
-
await setApiKeyToObject(localVarHeaderParameter, "Authorization", configuration)
|
|
201
|
-
|
|
202
|
-
if (pre !== undefined) {
|
|
203
|
-
localVarQueryParameter['pre'] = pre;
|
|
204
|
-
}
|
|
205
|
-
|
|
206
|
-
|
|
207
|
-
|
|
208
|
-
setSearchParams(localVarUrlObj, localVarQueryParameter);
|
|
209
|
-
let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
|
|
210
|
-
localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers};
|
|
211
|
-
|
|
212
|
-
return {
|
|
213
|
-
url: toPathString(localVarUrlObj),
|
|
214
|
-
options: localVarRequestOptions,
|
|
215
|
-
};
|
|
216
|
-
},
|
|
217
|
-
/**
|
|
218
|
-
* Retrieves a list of conversations filtered by user.
|
|
219
|
-
* @summary List conversations by user
|
|
220
|
-
* @param {number} [page] Page number for pagination
|
|
221
|
-
* @param {number} [pageSize] Number of items per page
|
|
222
|
-
* @param {string} [type] Type of conversations to filter, can be bi or analysis.
|
|
223
|
-
* @param {*} [options] Override http request option.
|
|
224
|
-
* @throws {RequiredError}
|
|
225
|
-
*/
|
|
226
|
-
listConversations: async (page?: number, pageSize?: number, type?: string, options: RawAxiosRequestConfig = {}): Promise<RequestArgs> => {
|
|
227
|
-
const localVarPath = `/api/v1/ai/conversations`;
|
|
228
|
-
// use dummy base URL string because the URL constructor only accepts absolute URLs.
|
|
229
|
-
const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
|
|
230
|
-
let baseOptions;
|
|
231
|
-
if (configuration) {
|
|
232
|
-
baseOptions = configuration.baseOptions;
|
|
233
|
-
}
|
|
234
|
-
|
|
235
|
-
const localVarRequestOptions = { method: 'GET', ...baseOptions, ...options};
|
|
236
|
-
const localVarHeaderParameter = {} as any;
|
|
237
|
-
const localVarQueryParameter = {} as any;
|
|
238
|
-
|
|
239
|
-
// authentication BearerToken required
|
|
240
|
-
// http bearer authentication required
|
|
241
|
-
await setBearerAuthToObject(localVarHeaderParameter, configuration)
|
|
242
|
-
|
|
243
|
-
// authentication DigestAuth required
|
|
244
|
-
await setApiKeyToObject(localVarHeaderParameter, "Authorization", configuration)
|
|
245
|
-
|
|
246
|
-
if (page !== undefined) {
|
|
247
|
-
localVarQueryParameter['page'] = page;
|
|
248
|
-
}
|
|
249
|
-
|
|
250
|
-
if (pageSize !== undefined) {
|
|
251
|
-
localVarQueryParameter['pageSize'] = pageSize;
|
|
252
|
-
}
|
|
253
|
-
|
|
254
|
-
if (type !== undefined) {
|
|
255
|
-
localVarQueryParameter['type'] = type;
|
|
256
|
-
}
|
|
257
|
-
|
|
258
|
-
|
|
259
|
-
|
|
260
|
-
setSearchParams(localVarUrlObj, localVarQueryParameter);
|
|
261
|
-
let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
|
|
262
|
-
localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers};
|
|
263
|
-
|
|
264
|
-
return {
|
|
265
|
-
url: toPathString(localVarUrlObj),
|
|
266
|
-
options: localVarRequestOptions,
|
|
267
|
-
};
|
|
268
|
-
},
|
|
269
|
-
/**
|
|
270
|
-
* Creates a new conversation.
|
|
271
|
-
* @summary Create a new conversation
|
|
272
|
-
* @param {AIConversationRequest} aIConversationRequest
|
|
273
|
-
* @param {*} [options] Override http request option.
|
|
274
|
-
* @throws {RequiredError}
|
|
275
|
-
*/
|
|
276
|
-
newAIConversation: async (aIConversationRequest: AIConversationRequest, options: RawAxiosRequestConfig = {}): Promise<RequestArgs> => {
|
|
277
|
-
// verify required parameter 'aIConversationRequest' is not null or undefined
|
|
278
|
-
assertParamExists('newAIConversation', 'aIConversationRequest', aIConversationRequest)
|
|
279
|
-
const localVarPath = `/api/v1/ai/conversations`;
|
|
280
|
-
// use dummy base URL string because the URL constructor only accepts absolute URLs.
|
|
281
|
-
const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
|
|
282
|
-
let baseOptions;
|
|
283
|
-
if (configuration) {
|
|
284
|
-
baseOptions = configuration.baseOptions;
|
|
285
|
-
}
|
|
286
|
-
|
|
287
|
-
const localVarRequestOptions = { method: 'POST', ...baseOptions, ...options};
|
|
288
|
-
const localVarHeaderParameter = {} as any;
|
|
289
|
-
const localVarQueryParameter = {} as any;
|
|
290
|
-
|
|
291
|
-
// authentication BearerToken required
|
|
292
|
-
// http bearer authentication required
|
|
293
|
-
await setBearerAuthToObject(localVarHeaderParameter, configuration)
|
|
294
|
-
|
|
295
|
-
// authentication DigestAuth required
|
|
296
|
-
await setApiKeyToObject(localVarHeaderParameter, "Authorization", configuration)
|
|
297
|
-
|
|
298
|
-
|
|
299
|
-
|
|
300
|
-
localVarHeaderParameter['Content-Type'] = 'application/json';
|
|
301
|
-
|
|
302
|
-
setSearchParams(localVarUrlObj, localVarQueryParameter);
|
|
303
|
-
let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
|
|
304
|
-
localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers};
|
|
305
|
-
localVarRequestOptions.data = serializeDataIfNeeded(aIConversationRequest, localVarRequestOptions, configuration)
|
|
306
|
-
|
|
307
|
-
return {
|
|
308
|
-
url: toPathString(localVarUrlObj),
|
|
309
|
-
options: localVarRequestOptions,
|
|
310
|
-
};
|
|
311
|
-
},
|
|
312
|
-
}
|
|
313
|
-
};
|
|
314
|
-
|
|
315
|
-
/**
|
|
316
|
-
* AIApi - functional programming interface
|
|
317
|
-
* @export
|
|
318
|
-
*/
|
|
319
|
-
export const AIApiFp = function(configuration?: Configuration) {
|
|
320
|
-
const localVarAxiosParamCreator = AIApiAxiosParamCreator(configuration)
|
|
321
|
-
return {
|
|
322
|
-
/**
|
|
323
|
-
* Establishes an SSE connection for AI BI conversation.
|
|
324
|
-
* @summary SSE endpoint for Chat BI V2
|
|
325
|
-
* @param {ChatRequest} chatRequest
|
|
326
|
-
* @param {*} [options] Override http request option.
|
|
327
|
-
* @throws {RequiredError}
|
|
328
|
-
*/
|
|
329
|
-
async chatBIV2SSE(chatRequest: ChatRequest, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<ChatResponse>> {
|
|
330
|
-
const localVarAxiosArgs = await localVarAxiosParamCreator.chatBIV2SSE(chatRequest, options);
|
|
331
|
-
const localVarOperationServerIndex = configuration?.serverIndex ?? 0;
|
|
332
|
-
const localVarOperationServerBasePath = operationServerMap['AIApi.chatBIV2SSE']?.[localVarOperationServerIndex]?.url;
|
|
333
|
-
return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath);
|
|
334
|
-
},
|
|
335
|
-
/**
|
|
336
|
-
* Establishes an SSE connection for AI conversation.
|
|
337
|
-
* @summary SSE endpoint for Chat V2
|
|
338
|
-
* @param {ChatRequest} chatRequest
|
|
339
|
-
* @param {*} [options] Override http request option.
|
|
340
|
-
* @throws {RequiredError}
|
|
341
|
-
*/
|
|
342
|
-
async chatV2SSE(chatRequest: ChatRequest, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<ChatResponse>> {
|
|
343
|
-
const localVarAxiosArgs = await localVarAxiosParamCreator.chatV2SSE(chatRequest, options);
|
|
344
|
-
const localVarOperationServerIndex = configuration?.serverIndex ?? 0;
|
|
345
|
-
const localVarOperationServerBasePath = operationServerMap['AIApi.chatV2SSE']?.[localVarOperationServerIndex]?.url;
|
|
346
|
-
return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath);
|
|
347
|
-
},
|
|
348
|
-
/**
|
|
349
|
-
* Deletes a specific conversation and all its associated messages.
|
|
350
|
-
* @summary Delete a conversation
|
|
351
|
-
* @param {string} conversationId ID of the conversation to delete
|
|
352
|
-
* @param {*} [options] Override http request option.
|
|
353
|
-
* @throws {RequiredError}
|
|
354
|
-
*/
|
|
355
|
-
async deleteConversation(conversationId: string, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<void>> {
|
|
356
|
-
const localVarAxiosArgs = await localVarAxiosParamCreator.deleteConversation(conversationId, options);
|
|
357
|
-
const localVarOperationServerIndex = configuration?.serverIndex ?? 0;
|
|
358
|
-
const localVarOperationServerBasePath = operationServerMap['AIApi.deleteConversation']?.[localVarOperationServerIndex]?.url;
|
|
359
|
-
return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath);
|
|
360
|
-
},
|
|
361
|
-
/**
|
|
362
|
-
* Retrieves ai messages for a specific conversation. If pre is not provided, returns the last 10 turn messages. If pre is provided, returns 10 turn messages after the pre message.
|
|
363
|
-
* @summary Get AI conversation messages
|
|
364
|
-
* @param {string} conversationId ID of the conversation
|
|
365
|
-
* @param {string} [pre] Previous message ID
|
|
366
|
-
* @param {*} [options] Override http request option.
|
|
367
|
-
* @throws {RequiredError}
|
|
368
|
-
*/
|
|
369
|
-
async getConversationMessages(conversationId: string, pre?: string, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<AiMessageListResponse>> {
|
|
370
|
-
const localVarAxiosArgs = await localVarAxiosParamCreator.getConversationMessages(conversationId, pre, options);
|
|
371
|
-
const localVarOperationServerIndex = configuration?.serverIndex ?? 0;
|
|
372
|
-
const localVarOperationServerBasePath = operationServerMap['AIApi.getConversationMessages']?.[localVarOperationServerIndex]?.url;
|
|
373
|
-
return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath);
|
|
374
|
-
},
|
|
375
|
-
/**
|
|
376
|
-
* Retrieves a list of conversations filtered by user.
|
|
377
|
-
* @summary List conversations by user
|
|
378
|
-
* @param {number} [page] Page number for pagination
|
|
379
|
-
* @param {number} [pageSize] Number of items per page
|
|
380
|
-
* @param {string} [type] Type of conversations to filter, can be bi or analysis.
|
|
381
|
-
* @param {*} [options] Override http request option.
|
|
382
|
-
* @throws {RequiredError}
|
|
383
|
-
*/
|
|
384
|
-
async listConversations(page?: number, pageSize?: number, type?: string, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<AiConversationListResponse>> {
|
|
385
|
-
const localVarAxiosArgs = await localVarAxiosParamCreator.listConversations(page, pageSize, type, options);
|
|
386
|
-
const localVarOperationServerIndex = configuration?.serverIndex ?? 0;
|
|
387
|
-
const localVarOperationServerBasePath = operationServerMap['AIApi.listConversations']?.[localVarOperationServerIndex]?.url;
|
|
388
|
-
return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath);
|
|
389
|
-
},
|
|
390
|
-
/**
|
|
391
|
-
* Creates a new conversation.
|
|
392
|
-
* @summary Create a new conversation
|
|
393
|
-
* @param {AIConversationRequest} aIConversationRequest
|
|
394
|
-
* @param {*} [options] Override http request option.
|
|
395
|
-
* @throws {RequiredError}
|
|
396
|
-
*/
|
|
397
|
-
async newAIConversation(aIConversationRequest: AIConversationRequest, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<AiConversation>> {
|
|
398
|
-
const localVarAxiosArgs = await localVarAxiosParamCreator.newAIConversation(aIConversationRequest, options);
|
|
399
|
-
const localVarOperationServerIndex = configuration?.serverIndex ?? 0;
|
|
400
|
-
const localVarOperationServerBasePath = operationServerMap['AIApi.newAIConversation']?.[localVarOperationServerIndex]?.url;
|
|
401
|
-
return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath);
|
|
402
|
-
},
|
|
403
|
-
}
|
|
404
|
-
};
|
|
405
|
-
|
|
406
|
-
/**
|
|
407
|
-
* AIApi - factory interface
|
|
408
|
-
* @export
|
|
409
|
-
*/
|
|
410
|
-
export const AIApiFactory = function (configuration?: Configuration, basePath?: string, axios?: AxiosInstance) {
|
|
411
|
-
const localVarFp = AIApiFp(configuration)
|
|
412
|
-
return {
|
|
413
|
-
/**
|
|
414
|
-
* Establishes an SSE connection for AI BI conversation.
|
|
415
|
-
* @summary SSE endpoint for Chat BI V2
|
|
416
|
-
* @param {AIApiChatBIV2SSERequest} requestParameters Request parameters.
|
|
417
|
-
* @param {*} [options] Override http request option.
|
|
418
|
-
* @throws {RequiredError}
|
|
419
|
-
*/
|
|
420
|
-
chatBIV2SSE(requestParameters: AIApiChatBIV2SSERequest, options?: RawAxiosRequestConfig): AxiosPromise<ChatResponse> {
|
|
421
|
-
return localVarFp.chatBIV2SSE(requestParameters.chatRequest, options).then((request) => request(axios, basePath));
|
|
422
|
-
},
|
|
423
|
-
/**
|
|
424
|
-
* Establishes an SSE connection for AI conversation.
|
|
425
|
-
* @summary SSE endpoint for Chat V2
|
|
426
|
-
* @param {AIApiChatV2SSERequest} requestParameters Request parameters.
|
|
427
|
-
* @param {*} [options] Override http request option.
|
|
428
|
-
* @throws {RequiredError}
|
|
429
|
-
*/
|
|
430
|
-
chatV2SSE(requestParameters: AIApiChatV2SSERequest, options?: RawAxiosRequestConfig): AxiosPromise<ChatResponse> {
|
|
431
|
-
return localVarFp.chatV2SSE(requestParameters.chatRequest, options).then((request) => request(axios, basePath));
|
|
432
|
-
},
|
|
433
|
-
/**
|
|
434
|
-
* Deletes a specific conversation and all its associated messages.
|
|
435
|
-
* @summary Delete a conversation
|
|
436
|
-
* @param {AIApiDeleteConversationRequest} requestParameters Request parameters.
|
|
437
|
-
* @param {*} [options] Override http request option.
|
|
438
|
-
* @throws {RequiredError}
|
|
439
|
-
*/
|
|
440
|
-
deleteConversation(requestParameters: AIApiDeleteConversationRequest, options?: RawAxiosRequestConfig): AxiosPromise<void> {
|
|
441
|
-
return localVarFp.deleteConversation(requestParameters.conversationId, options).then((request) => request(axios, basePath));
|
|
442
|
-
},
|
|
443
|
-
/**
|
|
444
|
-
* Retrieves ai messages for a specific conversation. If pre is not provided, returns the last 10 turn messages. If pre is provided, returns 10 turn messages after the pre message.
|
|
445
|
-
* @summary Get AI conversation messages
|
|
446
|
-
* @param {AIApiGetConversationMessagesRequest} requestParameters Request parameters.
|
|
447
|
-
* @param {*} [options] Override http request option.
|
|
448
|
-
* @throws {RequiredError}
|
|
449
|
-
*/
|
|
450
|
-
getConversationMessages(requestParameters: AIApiGetConversationMessagesRequest, options?: RawAxiosRequestConfig): AxiosPromise<AiMessageListResponse> {
|
|
451
|
-
return localVarFp.getConversationMessages(requestParameters.conversationId, requestParameters.pre, options).then((request) => request(axios, basePath));
|
|
452
|
-
},
|
|
453
|
-
/**
|
|
454
|
-
* Retrieves a list of conversations filtered by user.
|
|
455
|
-
* @summary List conversations by user
|
|
456
|
-
* @param {AIApiListConversationsRequest} requestParameters Request parameters.
|
|
457
|
-
* @param {*} [options] Override http request option.
|
|
458
|
-
* @throws {RequiredError}
|
|
459
|
-
*/
|
|
460
|
-
listConversations(requestParameters: AIApiListConversationsRequest = {}, options?: RawAxiosRequestConfig): AxiosPromise<AiConversationListResponse> {
|
|
461
|
-
return localVarFp.listConversations(requestParameters.page, requestParameters.pageSize, requestParameters.type, options).then((request) => request(axios, basePath));
|
|
462
|
-
},
|
|
463
|
-
/**
|
|
464
|
-
* Creates a new conversation.
|
|
465
|
-
* @summary Create a new conversation
|
|
466
|
-
* @param {AIApiNewAIConversationRequest} requestParameters Request parameters.
|
|
467
|
-
* @param {*} [options] Override http request option.
|
|
468
|
-
* @throws {RequiredError}
|
|
469
|
-
*/
|
|
470
|
-
newAIConversation(requestParameters: AIApiNewAIConversationRequest, options?: RawAxiosRequestConfig): AxiosPromise<AiConversation> {
|
|
471
|
-
return localVarFp.newAIConversation(requestParameters.aIConversationRequest, options).then((request) => request(axios, basePath));
|
|
472
|
-
},
|
|
473
|
-
};
|
|
474
|
-
};
|
|
475
|
-
|
|
476
|
-
/**
|
|
477
|
-
* AIApi - interface
|
|
478
|
-
* @export
|
|
479
|
-
* @interface AIApi
|
|
480
|
-
*/
|
|
481
|
-
export interface AIApiInterface {
|
|
482
|
-
/**
|
|
483
|
-
* Establishes an SSE connection for AI BI conversation.
|
|
484
|
-
* @summary SSE endpoint for Chat BI V2
|
|
485
|
-
* @param {AIApiChatBIV2SSERequest} requestParameters Request parameters.
|
|
486
|
-
* @param {*} [options] Override http request option.
|
|
487
|
-
* @throws {RequiredError}
|
|
488
|
-
* @memberof AIApiInterface
|
|
489
|
-
*/
|
|
490
|
-
chatBIV2SSE(requestParameters: AIApiChatBIV2SSERequest, options?: RawAxiosRequestConfig): AxiosPromise<ChatResponse>;
|
|
491
|
-
|
|
492
|
-
/**
|
|
493
|
-
* Establishes an SSE connection for AI conversation.
|
|
494
|
-
* @summary SSE endpoint for Chat V2
|
|
495
|
-
* @param {AIApiChatV2SSERequest} requestParameters Request parameters.
|
|
496
|
-
* @param {*} [options] Override http request option.
|
|
497
|
-
* @throws {RequiredError}
|
|
498
|
-
* @memberof AIApiInterface
|
|
499
|
-
*/
|
|
500
|
-
chatV2SSE(requestParameters: AIApiChatV2SSERequest, options?: RawAxiosRequestConfig): AxiosPromise<ChatResponse>;
|
|
501
|
-
|
|
502
|
-
/**
|
|
503
|
-
* Deletes a specific conversation and all its associated messages.
|
|
504
|
-
* @summary Delete a conversation
|
|
505
|
-
* @param {AIApiDeleteConversationRequest} requestParameters Request parameters.
|
|
506
|
-
* @param {*} [options] Override http request option.
|
|
507
|
-
* @throws {RequiredError}
|
|
508
|
-
* @memberof AIApiInterface
|
|
509
|
-
*/
|
|
510
|
-
deleteConversation(requestParameters: AIApiDeleteConversationRequest, options?: RawAxiosRequestConfig): AxiosPromise<void>;
|
|
511
|
-
|
|
512
|
-
/**
|
|
513
|
-
* Retrieves ai messages for a specific conversation. If pre is not provided, returns the last 10 turn messages. If pre is provided, returns 10 turn messages after the pre message.
|
|
514
|
-
* @summary Get AI conversation messages
|
|
515
|
-
* @param {AIApiGetConversationMessagesRequest} requestParameters Request parameters.
|
|
516
|
-
* @param {*} [options] Override http request option.
|
|
517
|
-
* @throws {RequiredError}
|
|
518
|
-
* @memberof AIApiInterface
|
|
519
|
-
*/
|
|
520
|
-
getConversationMessages(requestParameters: AIApiGetConversationMessagesRequest, options?: RawAxiosRequestConfig): AxiosPromise<AiMessageListResponse>;
|
|
521
|
-
|
|
522
|
-
/**
|
|
523
|
-
* Retrieves a list of conversations filtered by user.
|
|
524
|
-
* @summary List conversations by user
|
|
525
|
-
* @param {AIApiListConversationsRequest} requestParameters Request parameters.
|
|
526
|
-
* @param {*} [options] Override http request option.
|
|
527
|
-
* @throws {RequiredError}
|
|
528
|
-
* @memberof AIApiInterface
|
|
529
|
-
*/
|
|
530
|
-
listConversations(requestParameters?: AIApiListConversationsRequest, options?: RawAxiosRequestConfig): AxiosPromise<AiConversationListResponse>;
|
|
531
|
-
|
|
532
|
-
/**
|
|
533
|
-
* Creates a new conversation.
|
|
534
|
-
* @summary Create a new conversation
|
|
535
|
-
* @param {AIApiNewAIConversationRequest} requestParameters Request parameters.
|
|
536
|
-
* @param {*} [options] Override http request option.
|
|
537
|
-
* @throws {RequiredError}
|
|
538
|
-
* @memberof AIApiInterface
|
|
539
|
-
*/
|
|
540
|
-
newAIConversation(requestParameters: AIApiNewAIConversationRequest, options?: RawAxiosRequestConfig): AxiosPromise<AiConversation>;
|
|
541
|
-
|
|
542
|
-
}
|
|
543
|
-
|
|
544
|
-
/**
|
|
545
|
-
* Request parameters for chatBIV2SSE operation in AIApi.
|
|
546
|
-
* @export
|
|
547
|
-
* @interface AIApiChatBIV2SSERequest
|
|
548
|
-
*/
|
|
549
|
-
export interface AIApiChatBIV2SSERequest {
|
|
550
|
-
/**
|
|
551
|
-
*
|
|
552
|
-
* @type {ChatRequest}
|
|
553
|
-
* @memberof AIApiChatBIV2SSE
|
|
554
|
-
*/
|
|
555
|
-
readonly chatRequest: ChatRequest
|
|
556
|
-
}
|
|
557
|
-
|
|
558
|
-
/**
|
|
559
|
-
* Request parameters for chatV2SSE operation in AIApi.
|
|
560
|
-
* @export
|
|
561
|
-
* @interface AIApiChatV2SSERequest
|
|
562
|
-
*/
|
|
563
|
-
export interface AIApiChatV2SSERequest {
|
|
564
|
-
/**
|
|
565
|
-
*
|
|
566
|
-
* @type {ChatRequest}
|
|
567
|
-
* @memberof AIApiChatV2SSE
|
|
568
|
-
*/
|
|
569
|
-
readonly chatRequest: ChatRequest
|
|
570
|
-
}
|
|
571
|
-
|
|
572
|
-
/**
|
|
573
|
-
* Request parameters for deleteConversation operation in AIApi.
|
|
574
|
-
* @export
|
|
575
|
-
* @interface AIApiDeleteConversationRequest
|
|
576
|
-
*/
|
|
577
|
-
export interface AIApiDeleteConversationRequest {
|
|
578
|
-
/**
|
|
579
|
-
* ID of the conversation to delete
|
|
580
|
-
* @type {string}
|
|
581
|
-
* @memberof AIApiDeleteConversation
|
|
582
|
-
*/
|
|
583
|
-
readonly conversationId: string
|
|
584
|
-
}
|
|
585
|
-
|
|
586
|
-
/**
|
|
587
|
-
* Request parameters for getConversationMessages operation in AIApi.
|
|
588
|
-
* @export
|
|
589
|
-
* @interface AIApiGetConversationMessagesRequest
|
|
590
|
-
*/
|
|
591
|
-
export interface AIApiGetConversationMessagesRequest {
|
|
592
|
-
/**
|
|
593
|
-
* ID of the conversation
|
|
594
|
-
* @type {string}
|
|
595
|
-
* @memberof AIApiGetConversationMessages
|
|
596
|
-
*/
|
|
597
|
-
readonly conversationId: string
|
|
598
|
-
|
|
599
|
-
/**
|
|
600
|
-
* Previous message ID
|
|
601
|
-
* @type {string}
|
|
602
|
-
* @memberof AIApiGetConversationMessages
|
|
603
|
-
*/
|
|
604
|
-
readonly pre?: string
|
|
605
|
-
}
|
|
606
|
-
|
|
607
|
-
/**
|
|
608
|
-
* Request parameters for listConversations operation in AIApi.
|
|
609
|
-
* @export
|
|
610
|
-
* @interface AIApiListConversationsRequest
|
|
611
|
-
*/
|
|
612
|
-
export interface AIApiListConversationsRequest {
|
|
613
|
-
/**
|
|
614
|
-
* Page number for pagination
|
|
615
|
-
* @type {number}
|
|
616
|
-
* @memberof AIApiListConversations
|
|
617
|
-
*/
|
|
618
|
-
readonly page?: number
|
|
619
|
-
|
|
620
|
-
/**
|
|
621
|
-
* Number of items per page
|
|
622
|
-
* @type {number}
|
|
623
|
-
* @memberof AIApiListConversations
|
|
624
|
-
*/
|
|
625
|
-
readonly pageSize?: number
|
|
626
|
-
|
|
627
|
-
/**
|
|
628
|
-
* Type of conversations to filter, can be bi or analysis.
|
|
629
|
-
* @type {string}
|
|
630
|
-
* @memberof AIApiListConversations
|
|
631
|
-
*/
|
|
632
|
-
readonly type?: string
|
|
633
|
-
}
|
|
634
|
-
|
|
635
|
-
/**
|
|
636
|
-
* Request parameters for newAIConversation operation in AIApi.
|
|
637
|
-
* @export
|
|
638
|
-
* @interface AIApiNewAIConversationRequest
|
|
639
|
-
*/
|
|
640
|
-
export interface AIApiNewAIConversationRequest {
|
|
641
|
-
/**
|
|
642
|
-
*
|
|
643
|
-
* @type {AIConversationRequest}
|
|
644
|
-
* @memberof AIApiNewAIConversation
|
|
645
|
-
*/
|
|
646
|
-
readonly aIConversationRequest: AIConversationRequest
|
|
647
|
-
}
|
|
648
|
-
|
|
649
|
-
/**
|
|
650
|
-
* AIApi - object-oriented interface
|
|
651
|
-
* @export
|
|
652
|
-
* @class AIApi
|
|
653
|
-
* @extends {BaseAPI}
|
|
654
|
-
*/
|
|
655
|
-
export class AIApi extends BaseAPI implements AIApiInterface {
|
|
656
|
-
/**
|
|
657
|
-
* Establishes an SSE connection for AI BI conversation.
|
|
658
|
-
* @summary SSE endpoint for Chat BI V2
|
|
659
|
-
* @param {AIApiChatBIV2SSERequest} requestParameters Request parameters.
|
|
660
|
-
* @param {*} [options] Override http request option.
|
|
661
|
-
* @throws {RequiredError}
|
|
662
|
-
* @memberof AIApi
|
|
663
|
-
*/
|
|
664
|
-
public chatBIV2SSE(requestParameters: AIApiChatBIV2SSERequest, options?: RawAxiosRequestConfig) {
|
|
665
|
-
return AIApiFp(this.configuration).chatBIV2SSE(requestParameters.chatRequest, options).then((request) => request(this.axios, this.basePath));
|
|
666
|
-
}
|
|
667
|
-
|
|
668
|
-
/**
|
|
669
|
-
* Establishes an SSE connection for AI conversation.
|
|
670
|
-
* @summary SSE endpoint for Chat V2
|
|
671
|
-
* @param {AIApiChatV2SSERequest} requestParameters Request parameters.
|
|
672
|
-
* @param {*} [options] Override http request option.
|
|
673
|
-
* @throws {RequiredError}
|
|
674
|
-
* @memberof AIApi
|
|
675
|
-
*/
|
|
676
|
-
public chatV2SSE(requestParameters: AIApiChatV2SSERequest, options?: RawAxiosRequestConfig) {
|
|
677
|
-
return AIApiFp(this.configuration).chatV2SSE(requestParameters.chatRequest, options).then((request) => request(this.axios, this.basePath));
|
|
678
|
-
}
|
|
679
|
-
|
|
680
|
-
/**
|
|
681
|
-
* Deletes a specific conversation and all its associated messages.
|
|
682
|
-
* @summary Delete a conversation
|
|
683
|
-
* @param {AIApiDeleteConversationRequest} requestParameters Request parameters.
|
|
684
|
-
* @param {*} [options] Override http request option.
|
|
685
|
-
* @throws {RequiredError}
|
|
686
|
-
* @memberof AIApi
|
|
687
|
-
*/
|
|
688
|
-
public deleteConversation(requestParameters: AIApiDeleteConversationRequest, options?: RawAxiosRequestConfig) {
|
|
689
|
-
return AIApiFp(this.configuration).deleteConversation(requestParameters.conversationId, options).then((request) => request(this.axios, this.basePath));
|
|
690
|
-
}
|
|
691
|
-
|
|
692
|
-
/**
|
|
693
|
-
* Retrieves ai messages for a specific conversation. If pre is not provided, returns the last 10 turn messages. If pre is provided, returns 10 turn messages after the pre message.
|
|
694
|
-
* @summary Get AI conversation messages
|
|
695
|
-
* @param {AIApiGetConversationMessagesRequest} requestParameters Request parameters.
|
|
696
|
-
* @param {*} [options] Override http request option.
|
|
697
|
-
* @throws {RequiredError}
|
|
698
|
-
* @memberof AIApi
|
|
699
|
-
*/
|
|
700
|
-
public getConversationMessages(requestParameters: AIApiGetConversationMessagesRequest, options?: RawAxiosRequestConfig) {
|
|
701
|
-
return AIApiFp(this.configuration).getConversationMessages(requestParameters.conversationId, requestParameters.pre, options).then((request) => request(this.axios, this.basePath));
|
|
702
|
-
}
|
|
703
|
-
|
|
704
|
-
/**
|
|
705
|
-
* Retrieves a list of conversations filtered by user.
|
|
706
|
-
* @summary List conversations by user
|
|
707
|
-
* @param {AIApiListConversationsRequest} requestParameters Request parameters.
|
|
708
|
-
* @param {*} [options] Override http request option.
|
|
709
|
-
* @throws {RequiredError}
|
|
710
|
-
* @memberof AIApi
|
|
711
|
-
*/
|
|
712
|
-
public listConversations(requestParameters: AIApiListConversationsRequest = {}, options?: RawAxiosRequestConfig) {
|
|
713
|
-
return AIApiFp(this.configuration).listConversations(requestParameters.page, requestParameters.pageSize, requestParameters.type, options).then((request) => request(this.axios, this.basePath));
|
|
714
|
-
}
|
|
715
|
-
|
|
716
|
-
/**
|
|
717
|
-
* Creates a new conversation.
|
|
718
|
-
* @summary Create a new conversation
|
|
719
|
-
* @param {AIApiNewAIConversationRequest} requestParameters Request parameters.
|
|
720
|
-
* @param {*} [options] Override http request option.
|
|
721
|
-
* @throws {RequiredError}
|
|
722
|
-
* @memberof AIApi
|
|
723
|
-
*/
|
|
724
|
-
public newAIConversation(requestParameters: AIApiNewAIConversationRequest, options?: RawAxiosRequestConfig) {
|
|
725
|
-
return AIApiFp(this.configuration).newAIConversation(requestParameters.aIConversationRequest, options).then((request) => request(this.axios, this.basePath));
|
|
726
|
-
}
|
|
727
|
-
}
|
|
728
|
-
|