@webitel/api-services 0.0.62 → 0.0.64
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/package.json +1 -1
- package/src/api/clients/agents/agentChats.ts +25 -22
- package/src/api/clients/agents/agents.ts +23 -28
- package/src/api/clients/users/users.ts +9 -1
- package/src/gen/_models/agentChatServiceGetAgentChatsCounterParams.ts +11 -0
- package/src/gen/_models/casesChatCatalogGetCaseChatHistoryParams.ts +4 -2
- package/src/gen/_models/catalogGetDialogsParams.ts +6 -2
- package/src/gen/_models/catalogGetHistory2Params.ts +4 -2
- package/src/gen/_models/catalogGetHistoryParams.ts +4 -2
- package/src/gen/_models/configServiceReadSystemObjectsParams.ts +5 -0
- package/src/gen/_models/contactsChatCatalogGetContactChatHistory2Params.ts +4 -2
- package/src/gen/_models/contactsChatCatalogGetContactChatHistoryParams.ts +4 -2
- package/src/gen/_models/index.ts +39 -0
- package/src/gen/_models/searchAgentParams.ts +1 -0
- package/src/gen/_models/searchUserStatusParams.ts +1 -0
- package/src/gen/_models/webitelChatGetAgentChatsCounterResponse.ts +10 -0
- package/src/gen/_models/webitelChatInputFile.ts +1 -0
- package/src/gen/_models/webitelChatMessage.ts +1 -0
- package/src/gen/_models/webitelChatServerAccount.ts +17 -0
- package/src/gen/_models/webitelChatServerButton.ts +14 -0
- package/src/gen/_models/webitelChatServerButtons.ts +11 -0
- package/src/gen/_models/webitelChatServerChannel.ts +18 -0
- package/src/gen/_models/webitelChatServerChatTransferResponse.ts +10 -0
- package/src/gen/_models/webitelChatServerChatVariablesResponse.ts +14 -0
- package/src/gen/_models/webitelChatServerChatVariablesResponseVariables.ts +13 -0
- package/src/gen/_models/webitelChatServerCheckSessionResponse.ts +17 -0
- package/src/gen/_models/webitelChatServerCheckSessionResponseProperties.ts +13 -0
- package/src/gen/_models/webitelChatServerCloseConversationCause.ts +18 -0
- package/src/gen/_models/webitelChatServerCloseConversationResponse.ts +10 -0
- package/src/gen/_models/webitelChatServerConversation.ts +20 -0
- package/src/gen/_models/webitelChatServerDeclineInvitationResponse.ts +10 -0
- package/src/gen/_models/webitelChatServerFile.ts +14 -0
- package/src/gen/_models/webitelChatServerGateway.ts +12 -0
- package/src/gen/_models/webitelChatServerGetConversationByIDResponse.ts +11 -0
- package/src/gen/_models/webitelChatServerGetConversationsResponse.ts +13 -0
- package/src/gen/_models/webitelChatServerGetHistoryMessagesResponse.ts +13 -0
- package/src/gen/_models/webitelChatServerHistoryMessage.ts +18 -0
- package/src/gen/_models/webitelChatServerInviteToConversationResponse.ts +10 -0
- package/src/gen/_models/webitelChatServerJoinConversationResponse.ts +10 -0
- package/src/gen/_models/webitelChatServerLeaveConversationCause.ts +19 -0
- package/src/gen/_models/webitelChatServerLeaveConversationResponse.ts +10 -0
- package/src/gen/_models/webitelChatServerMember.ts +18 -0
- package/src/gen/_models/webitelChatServerMessage.ts +45 -0
- package/src/gen/_models/webitelChatServerMessageForwardFromVariables.ts +10 -0
- package/src/gen/_models/webitelChatServerMessageReplyToVariables.ts +10 -0
- package/src/gen/_models/webitelChatServerMessageVariables.ts +8 -0
- package/src/gen/_models/webitelChatServerPostback.ts +18 -0
- package/src/gen/_models/webitelChatServerSendMessageResponse.ts +11 -0
- package/src/gen/_models/webitelChatServerSendServiceMessageResponse.ts +10 -0
- package/src/gen/_models/webitelChatServerSendUserActionResponse.ts +10 -0
- package/src/gen/_models/webitelChatServerStartConversationResponse.ts +13 -0
- package/src/gen/_models/webitelChatServerUpdateChannelResponse.ts +10 -0
- package/src/gen/_models/webitelChatServerUser.ts +13 -0
- package/src/gen/_models/webitelChatServerUserAction.ts +23 -0
- package/src/gen/_models/webitelChatServerWaitMessageResponse.ts +12 -0
- package/src/gen/agent-chat-service/agent-chat-service.api.gen.ts +16 -0
- package/src/gen/agent-chat-service/agent-chat-service.msw.api.gen.ts +41 -0
- package/src/gen/agent-chat-service/agent-chat-service.zod.gen.ts +10 -0
- package/src/gen/agent-service/agent-service.zod.gen.ts +2 -0
- package/src/gen/cases-chat-catalog/cases-chat-catalog.msw.api.gen.ts +4 -0
- package/src/gen/cases-chat-catalog/cases-chat-catalog.zod.gen.ts +2 -1
- package/src/gen/config-service/config-service.zod.gen.ts +5 -0
- package/src/gen/contacts-chat-catalog/contacts-chat-catalog.zod.gen.ts +2 -2
- package/src/gen/index.ts +3 -6
- package/src/gen/{catalog/catalog.api.gen.ts → messages/messages.api.gen.ts} +21 -1
- package/src/gen/{catalog/catalog.msw.api.gen.ts → messages/messages.msw.api.gen.ts} +95 -1
- package/src/gen/{catalog/catalog.zod.gen.ts → messages/messages.zod.gen.ts} +82 -3
- package/src/gen/users/users.api.gen.ts +1 -5
- package/src/gen/users/users.msw.api.gen.ts +2 -2
- package/types/api/clients/agents/agentChats.d.ts +1 -0
- package/types/api/clients/index.d.ts +1 -1
- package/types/gen/_models/agentChatServiceGetAgentChatsCounterParams.d.ts +10 -0
- package/types/gen/_models/casesChatCatalogGetCaseChatHistoryParams.d.ts +4 -2
- package/types/gen/_models/catalogGetDialogsParams.d.ts +6 -2
- package/types/gen/_models/catalogGetHistory2Params.d.ts +4 -2
- package/types/gen/_models/catalogGetHistoryParams.d.ts +4 -2
- package/types/gen/_models/configServiceReadSystemObjectsParams.d.ts +5 -0
- package/types/gen/_models/contactsChatCatalogGetContactChatHistory2Params.d.ts +4 -2
- package/types/gen/_models/contactsChatCatalogGetContactChatHistoryParams.d.ts +4 -2
- package/types/gen/_models/searchAgentParams.d.ts +1 -0
- package/types/gen/_models/searchUserStatusParams.d.ts +1 -0
- package/types/gen/_models/webitelChatGetAgentChatsCounterResponse.d.ts +9 -0
- package/types/gen/_models/webitelChatInputFile.d.ts +1 -0
- package/types/gen/_models/webitelChatMessage.d.ts +1 -0
- package/types/gen/_models/webitelChatServerAccount.d.ts +16 -0
- package/types/gen/_models/webitelChatServerButton.d.ts +13 -0
- package/types/gen/_models/webitelChatServerButtons.d.ts +10 -0
- package/types/gen/_models/webitelChatServerChannel.d.ts +17 -0
- package/types/gen/_models/webitelChatServerChatTransferResponse.d.ts +9 -0
- package/types/gen/_models/webitelChatServerChatVariablesResponse.d.ts +13 -0
- package/types/gen/_models/webitelChatServerChatVariablesResponseVariables.d.ts +12 -0
- package/types/gen/_models/webitelChatServerCheckSessionResponse.d.ts +16 -0
- package/types/gen/_models/webitelChatServerCheckSessionResponseProperties.d.ts +12 -0
- package/types/gen/_models/webitelChatServerCloseConversationCause.d.ts +14 -0
- package/types/gen/_models/webitelChatServerCloseConversationResponse.d.ts +9 -0
- package/types/gen/_models/webitelChatServerConversation.d.ts +18 -0
- package/types/gen/_models/webitelChatServerDeclineInvitationResponse.d.ts +9 -0
- package/types/gen/_models/webitelChatServerFile.d.ts +13 -0
- package/types/gen/_models/webitelChatServerGateway.d.ts +11 -0
- package/types/gen/_models/webitelChatServerGetConversationByIDResponse.d.ts +10 -0
- package/types/gen/_models/webitelChatServerGetConversationsResponse.d.ts +12 -0
- package/types/gen/_models/webitelChatServerGetHistoryMessagesResponse.d.ts +12 -0
- package/types/gen/_models/webitelChatServerHistoryMessage.d.ts +17 -0
- package/types/gen/_models/webitelChatServerInviteToConversationResponse.d.ts +9 -0
- package/types/gen/_models/webitelChatServerJoinConversationResponse.d.ts +9 -0
- package/types/gen/_models/webitelChatServerLeaveConversationCause.d.ts +15 -0
- package/types/gen/_models/webitelChatServerLeaveConversationResponse.d.ts +9 -0
- package/types/gen/_models/webitelChatServerMember.d.ts +17 -0
- package/types/gen/_models/webitelChatServerMessage.d.ts +43 -0
- package/types/gen/_models/webitelChatServerMessageForwardFromVariables.d.ts +9 -0
- package/types/gen/_models/webitelChatServerMessageReplyToVariables.d.ts +9 -0
- package/types/gen/_models/webitelChatServerMessageVariables.d.ts +9 -0
- package/types/gen/_models/webitelChatServerPostback.d.ts +17 -0
- package/types/gen/_models/webitelChatServerSendMessageResponse.d.ts +10 -0
- package/types/gen/_models/webitelChatServerSendServiceMessageResponse.d.ts +9 -0
- package/types/gen/_models/webitelChatServerSendUserActionResponse.d.ts +9 -0
- package/types/gen/_models/webitelChatServerStartConversationResponse.d.ts +12 -0
- package/types/gen/_models/webitelChatServerUpdateChannelResponse.d.ts +9 -0
- package/types/gen/_models/webitelChatServerUser.d.ts +12 -0
- package/types/gen/_models/webitelChatServerUserAction.d.ts +19 -0
- package/types/gen/_models/webitelChatServerWaitMessageResponse.d.ts +11 -0
- package/types/gen/agent-chat-service/agent-chat-service.api.gen.d.ts +3 -1
- package/types/gen/agent-chat-service/agent-chat-service.msw.api.gen.d.ts +3 -1
- package/types/gen/agent-chat-service/agent-chat-service.zod.gen.d.ts +8 -0
- package/types/gen/agent-service/agent-service.zod.gen.d.ts +2 -0
- package/types/gen/cases-chat-catalog/cases-chat-catalog.zod.gen.d.ts +1 -0
- package/types/gen/config-service/config-service.zod.gen.d.ts +5 -0
- package/types/gen/{catalog/catalog.api.gen.d.ts → messages/messages.api.gen.d.ts} +4 -2
- package/types/gen/{catalog/catalog.msw.api.gen.d.ts → messages/messages.msw.api.gen.d.ts} +4 -2
- package/types/gen/{catalog/catalog.zod.gen.d.ts → messages/messages.zod.gen.d.ts} +47 -0
- package/types/gen/users/users.msw.api.gen.d.ts +1 -1
- package/src/gen/messages-service/messages-service.api.gen.ts +0 -46
- package/src/gen/messages-service/messages-service.msw.api.gen.ts +0 -92
- package/src/gen/messages-service/messages-service.zod.gen.ts +0 -82
- package/types/gen/messages-service/messages-service.api.gen.d.ts +0 -7
- package/types/gen/messages-service/messages-service.msw.api.gen.d.ts +0 -5
- package/types/gen/messages-service/messages-service.zod.gen.d.ts +0 -50
package/package.json
CHANGED
|
@@ -1,10 +1,5 @@
|
|
|
1
|
-
import {
|
|
2
|
-
|
|
3
|
-
import {
|
|
4
|
-
getDefaultGetParams,
|
|
5
|
-
getDefaultInstance,
|
|
6
|
-
getDefaultOpenAPIConfig,
|
|
7
|
-
} from '../../defaults';
|
|
1
|
+
import { getAgentChatService } from '@webitel/api-services/gen';
|
|
2
|
+
import { getDefaultGetParams } from '../../defaults';
|
|
8
3
|
import {
|
|
9
4
|
applyTransform,
|
|
10
5
|
merge,
|
|
@@ -12,30 +7,18 @@ import {
|
|
|
12
7
|
snakeToCamel,
|
|
13
8
|
} from '../../transformers';
|
|
14
9
|
|
|
15
|
-
const instance = getDefaultInstance();
|
|
16
|
-
const configuration = getDefaultOpenAPIConfig();
|
|
17
|
-
|
|
18
|
-
const agentChatsService = AgentChatServiceApiFactory(
|
|
19
|
-
configuration,
|
|
20
|
-
'',
|
|
21
|
-
instance,
|
|
22
|
-
);
|
|
23
|
-
|
|
24
10
|
const getChatsList = async (params) => {
|
|
25
11
|
const { size, page, onlyClosed, onlyUnprocessed } = applyTransform(params, [
|
|
26
12
|
merge(getDefaultGetParams()),
|
|
27
13
|
]);
|
|
28
14
|
|
|
29
15
|
try {
|
|
30
|
-
const response = await
|
|
16
|
+
const response = await getAgentChatService().agentChatServiceGetAgentChats({
|
|
31
17
|
size,
|
|
32
18
|
page,
|
|
33
|
-
undefined,
|
|
34
|
-
undefined,
|
|
35
|
-
undefined,
|
|
36
19
|
onlyClosed,
|
|
37
20
|
onlyUnprocessed,
|
|
38
|
-
);
|
|
21
|
+
});
|
|
39
22
|
const { items, next } = applyTransform(response.data, [snakeToCamel()]);
|
|
40
23
|
return {
|
|
41
24
|
items,
|
|
@@ -46,10 +29,29 @@ const getChatsList = async (params) => {
|
|
|
46
29
|
}
|
|
47
30
|
};
|
|
48
31
|
|
|
32
|
+
const getChatCount = async (params) => {
|
|
33
|
+
const { onlyClosed, onlyUnprocessed } = applyTransform(params, [
|
|
34
|
+
merge(getDefaultGetParams()),
|
|
35
|
+
]);
|
|
36
|
+
|
|
37
|
+
try {
|
|
38
|
+
const response =
|
|
39
|
+
await getAgentChatService().agentChatServiceGetAgentChatsCounter({
|
|
40
|
+
onlyClosed,
|
|
41
|
+
onlyUnprocessed,
|
|
42
|
+
});
|
|
43
|
+
const { count } = applyTransform(response.data, [snakeToCamel()]);
|
|
44
|
+
return count;
|
|
45
|
+
} catch (err) {
|
|
46
|
+
throw applyTransform(err, [notify]);
|
|
47
|
+
}
|
|
48
|
+
};
|
|
49
|
+
|
|
49
50
|
const markChatProcessed = async (chatId) => {
|
|
50
51
|
// add to chat unprocessedClose: true
|
|
51
52
|
try {
|
|
52
|
-
const response =
|
|
53
|
+
const response =
|
|
54
|
+
await getAgentChatService().agentChatServiceMarkChatProcessed(chatId);
|
|
53
55
|
return applyTransform(response.data, [snakeToCamel()]);
|
|
54
56
|
} catch (err) {
|
|
55
57
|
throw applyTransform(err, [
|
|
@@ -66,4 +68,5 @@ const markChatProcessed = async (chatId) => {
|
|
|
66
68
|
export const AgentChatsAPI = {
|
|
67
69
|
getList: getChatsList,
|
|
68
70
|
markChatProcessed,
|
|
71
|
+
getChatCount,
|
|
69
72
|
};
|
|
@@ -1,16 +1,11 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { getAgentService } from '@webitel/api-services/gen';
|
|
2
2
|
|
|
3
3
|
// @author @Lera
|
|
4
4
|
// fixme: change on library
|
|
5
5
|
// https://webitel.atlassian.net/browse/WTEL-7842?focusedCommentId=702198
|
|
6
6
|
//
|
|
7
7
|
import { convertDuration } from '../../../scripts';
|
|
8
|
-
import {
|
|
9
|
-
getDefaultGetListResponse,
|
|
10
|
-
getDefaultGetParams,
|
|
11
|
-
getDefaultInstance,
|
|
12
|
-
getDefaultOpenAPIConfig,
|
|
13
|
-
} from '../../defaults';
|
|
8
|
+
import { getDefaultGetListResponse, getDefaultGetParams } from '../../defaults';
|
|
14
9
|
import {
|
|
15
10
|
applyTransform,
|
|
16
11
|
camelToSnake,
|
|
@@ -21,11 +16,6 @@ import {
|
|
|
21
16
|
starToSearch,
|
|
22
17
|
} from '../../transformers';
|
|
23
18
|
|
|
24
|
-
const instance = getDefaultInstance();
|
|
25
|
-
const configuration = getDefaultOpenAPIConfig();
|
|
26
|
-
|
|
27
|
-
const agentService = AgentServiceApiFactory(configuration, '', instance);
|
|
28
|
-
|
|
29
19
|
const convertStatusDuration = (value) => {
|
|
30
20
|
if (value > 60 * 60 * 24) return '>24:00:00';
|
|
31
21
|
return convertDuration(value);
|
|
@@ -46,38 +36,43 @@ const getAgentsList = async (params) => {
|
|
|
46
36
|
sort,
|
|
47
37
|
fields,
|
|
48
38
|
id,
|
|
39
|
+
allowChannels,
|
|
49
40
|
team,
|
|
41
|
+
regionId,
|
|
42
|
+
auditorId,
|
|
50
43
|
skill,
|
|
44
|
+
queueId,
|
|
51
45
|
isSupervisor,
|
|
52
46
|
isNotSupervisor,
|
|
53
47
|
userId,
|
|
54
48
|
notTeamId,
|
|
55
49
|
supervisorId,
|
|
56
50
|
notSkillId,
|
|
51
|
+
notUserId,
|
|
57
52
|
} = applyTransform(params, [merge(getDefaultGetParams())]);
|
|
58
53
|
|
|
59
54
|
try {
|
|
60
|
-
const response = await
|
|
55
|
+
const response = await getAgentService().searchAgent({
|
|
61
56
|
page,
|
|
62
57
|
size,
|
|
63
58
|
search,
|
|
64
59
|
sort,
|
|
65
60
|
fields,
|
|
66
61
|
id,
|
|
67
|
-
|
|
62
|
+
allowChannels,
|
|
68
63
|
supervisorId,
|
|
69
64
|
team,
|
|
70
|
-
|
|
71
|
-
|
|
65
|
+
regionId,
|
|
66
|
+
auditorId,
|
|
72
67
|
isSupervisor,
|
|
73
68
|
skill,
|
|
74
|
-
|
|
69
|
+
queueId,
|
|
75
70
|
isNotSupervisor,
|
|
76
71
|
userId,
|
|
77
|
-
undefined,
|
|
78
72
|
notTeamId,
|
|
79
73
|
notSkillId,
|
|
80
|
-
|
|
74
|
+
notUserId,
|
|
75
|
+
});
|
|
81
76
|
const { items, next } = applyTransform(response.data, [
|
|
82
77
|
snakeToCamel(),
|
|
83
78
|
merge(getDefaultGetListResponse()),
|
|
@@ -107,7 +102,7 @@ const getAgent = async ({ itemId: id }) => {
|
|
|
107
102
|
};
|
|
108
103
|
|
|
109
104
|
try {
|
|
110
|
-
const response = await
|
|
105
|
+
const response = await getAgentService().readAgent(id);
|
|
111
106
|
return applyTransform(response.data, [
|
|
112
107
|
snakeToCamel(),
|
|
113
108
|
merge(defaultObject),
|
|
@@ -136,7 +131,7 @@ const addAgent = async ({ itemInstance }) => {
|
|
|
136
131
|
camelToSnake(),
|
|
137
132
|
]);
|
|
138
133
|
try {
|
|
139
|
-
const response = await
|
|
134
|
+
const response = await getAgentService().createAgent(item);
|
|
140
135
|
return applyTransform(response.data, [snakeToCamel()]);
|
|
141
136
|
} catch (err) {
|
|
142
137
|
throw applyTransform(err, [notify]);
|
|
@@ -149,7 +144,7 @@ const patchAgent = async ({ changes, id }) => {
|
|
|
149
144
|
camelToSnake(),
|
|
150
145
|
]);
|
|
151
146
|
try {
|
|
152
|
-
const response = await
|
|
147
|
+
const response = await getAgentService().patchAgent(id, body);
|
|
153
148
|
return applyTransform(response.data, [snakeToCamel()]);
|
|
154
149
|
} catch (err) {
|
|
155
150
|
throw applyTransform(err, [notify]);
|
|
@@ -162,7 +157,7 @@ const updateAgent = async ({ itemInstance, itemId: id }) => {
|
|
|
162
157
|
camelToSnake(),
|
|
163
158
|
]);
|
|
164
159
|
try {
|
|
165
|
-
const response = await
|
|
160
|
+
const response = await getAgentService().updateAgent(id, item);
|
|
166
161
|
return applyTransform(response.data, [snakeToCamel()]);
|
|
167
162
|
} catch (err) {
|
|
168
163
|
throw applyTransform(err, [notify]);
|
|
@@ -171,7 +166,7 @@ const updateAgent = async ({ itemInstance, itemId: id }) => {
|
|
|
171
166
|
|
|
172
167
|
const deleteAgent = async ({ id }) => {
|
|
173
168
|
try {
|
|
174
|
-
const response = await
|
|
169
|
+
const response = await getAgentService().deleteAgent(id);
|
|
175
170
|
return applyTransform(response.data, []);
|
|
176
171
|
} catch (err) {
|
|
177
172
|
throw applyTransform(err, [notify]);
|
|
@@ -198,14 +193,14 @@ const getAgentHistory = async (params) => {
|
|
|
198
193
|
]);
|
|
199
194
|
|
|
200
195
|
try {
|
|
201
|
-
const response = await
|
|
196
|
+
const response = await getAgentService().searchAgentStateHistory({
|
|
202
197
|
page,
|
|
203
198
|
size,
|
|
204
199
|
from,
|
|
205
200
|
to,
|
|
206
201
|
parentId,
|
|
207
202
|
sort,
|
|
208
|
-
);
|
|
203
|
+
});
|
|
209
204
|
const { items, next } = applyTransform(response.data, [
|
|
210
205
|
snakeToCamel(),
|
|
211
206
|
merge(getDefaultGetListResponse()),
|
|
@@ -226,11 +221,11 @@ const getAgentUsersOptions = async (params) => {
|
|
|
226
221
|
]);
|
|
227
222
|
|
|
228
223
|
try {
|
|
229
|
-
const response = await
|
|
224
|
+
const response = await getAgentService().searchLookupUsersAgentNotExists({
|
|
230
225
|
page,
|
|
231
226
|
size,
|
|
232
227
|
search,
|
|
233
|
-
);
|
|
228
|
+
});
|
|
234
229
|
const { items, next } = applyTransform(response.data, [
|
|
235
230
|
snakeToCamel(),
|
|
236
231
|
merge(getDefaultGetListResponse()),
|
|
@@ -38,7 +38,15 @@ const fieldsToSend = [
|
|
|
38
38
|
];
|
|
39
39
|
|
|
40
40
|
const getUsersList = async (params) => {
|
|
41
|
-
const fieldsToSend = [
|
|
41
|
+
const fieldsToSend = [
|
|
42
|
+
'page',
|
|
43
|
+
'size',
|
|
44
|
+
'q',
|
|
45
|
+
'sort',
|
|
46
|
+
'fields',
|
|
47
|
+
'id',
|
|
48
|
+
'not_user_id',
|
|
49
|
+
];
|
|
42
50
|
|
|
43
51
|
const defaultObject = {
|
|
44
52
|
name: '',
|
|
@@ -28,7 +28,9 @@ export type CasesChatCatalogGetCaseChatHistoryParams = {
|
|
|
28
28
|
*/
|
|
29
29
|
fields?: string[];
|
|
30
30
|
/**
|
|
31
|
-
|
|
32
|
-
|
|
31
|
+
* Includes the history of ONLY those dialogs
|
|
32
|
+
whose member channel(s) contain
|
|
33
|
+
a specified set of variables.
|
|
34
|
+
*/
|
|
33
35
|
groupString?: string;
|
|
34
36
|
};
|
|
@@ -72,7 +72,11 @@ Contact **type**-specific string.
|
|
|
72
72
|
*/
|
|
73
73
|
online?: boolean;
|
|
74
74
|
/**
|
|
75
|
-
|
|
76
|
-
|
|
75
|
+
* Includes ONLY those chat dialogs
|
|
76
|
+
whose member channel(s) contain
|
|
77
|
+
a specified set of variables.
|
|
78
|
+
|
|
79
|
+
10
|
|
80
|
+
*/
|
|
77
81
|
groupString?: string;
|
|
78
82
|
};
|
|
@@ -35,7 +35,9 @@ export type CatalogGetHistory2Params = {
|
|
|
35
35
|
*/
|
|
36
36
|
peerName?: string;
|
|
37
37
|
/**
|
|
38
|
-
|
|
39
|
-
|
|
38
|
+
* Includes the history of ONLY those dialogs
|
|
39
|
+
whose member channel(s) contain
|
|
40
|
+
a specified set of variables.
|
|
41
|
+
*/
|
|
40
42
|
groupStringString?: string;
|
|
41
43
|
};
|
|
@@ -40,7 +40,9 @@ Contact **type**-specific string.
|
|
|
40
40
|
*/
|
|
41
41
|
peerName?: string;
|
|
42
42
|
/**
|
|
43
|
-
|
|
44
|
-
|
|
43
|
+
* Includes the history of ONLY those dialogs
|
|
44
|
+
whose member channel(s) contain
|
|
45
|
+
a specified set of variables.
|
|
46
|
+
*/
|
|
45
47
|
groupString?: string;
|
|
46
48
|
};
|
|
@@ -32,7 +32,9 @@ export type ContactsChatCatalogGetContactChatHistory2Params = {
|
|
|
32
32
|
*/
|
|
33
33
|
chatId?: string;
|
|
34
34
|
/**
|
|
35
|
-
|
|
36
|
-
|
|
35
|
+
* Includes the history of ONLY those dialogs
|
|
36
|
+
whose member channel(s) contain
|
|
37
|
+
a specified set of variables.
|
|
38
|
+
*/
|
|
37
39
|
groupStringString?: string;
|
|
38
40
|
};
|
|
@@ -28,7 +28,9 @@ export type ContactsChatCatalogGetContactChatHistoryParams = {
|
|
|
28
28
|
*/
|
|
29
29
|
fields?: string[];
|
|
30
30
|
/**
|
|
31
|
-
|
|
32
|
-
|
|
31
|
+
* Includes the history of ONLY those dialogs
|
|
32
|
+
whose member channel(s) contain
|
|
33
|
+
a specified set of variables.
|
|
34
|
+
*/
|
|
33
35
|
groupString?: string;
|
|
34
36
|
};
|
package/src/gen/_models/index.ts
CHANGED
|
@@ -19,6 +19,7 @@ export * from './agentAbsenceServiceSearchAgentAbsenceParams';
|
|
|
19
19
|
export * from './agentAbsenceServiceSearchAgentsAbsencesParams';
|
|
20
20
|
export * from './agentAbsenceServiceUpdateAgentAbsenceBody';
|
|
21
21
|
export * from './agentAbsenceServiceUpdateAgentAbsenceBodyItem';
|
|
22
|
+
export * from './agentChatServiceGetAgentChatsCounterParams';
|
|
22
23
|
export * from './agentChatServiceGetAgentChatsParams';
|
|
23
24
|
export * from './agentStateHistoryParams';
|
|
24
25
|
export * from './agentTodayStatisticsParams';
|
|
@@ -1455,6 +1456,7 @@ export * from './webitelChatDialog';
|
|
|
1455
1456
|
export * from './webitelChatDialogContext';
|
|
1456
1457
|
export * from './webitelChatEmptyResponse';
|
|
1457
1458
|
export * from './webitelChatFile';
|
|
1459
|
+
export * from './webitelChatGetAgentChatsCounterResponse';
|
|
1458
1460
|
export * from './webitelChatGetAgentChatsResponse';
|
|
1459
1461
|
export * from './webitelChatGetCaseChatHistoryRequestOffset';
|
|
1460
1462
|
export * from './webitelChatGetContactChatHistoryRequestOffset';
|
|
@@ -1479,6 +1481,43 @@ export * from './webitelChatMessageReplyMarkup';
|
|
|
1479
1481
|
export * from './webitelChatPeer';
|
|
1480
1482
|
export * from './webitelChatPostback';
|
|
1481
1483
|
export * from './webitelChatReplyMarkup';
|
|
1484
|
+
export * from './webitelChatServerAccount';
|
|
1485
|
+
export * from './webitelChatServerButton';
|
|
1486
|
+
export * from './webitelChatServerButtons';
|
|
1487
|
+
export * from './webitelChatServerChannel';
|
|
1488
|
+
export * from './webitelChatServerChatTransferResponse';
|
|
1489
|
+
export * from './webitelChatServerChatVariablesResponse';
|
|
1490
|
+
export * from './webitelChatServerChatVariablesResponseVariables';
|
|
1491
|
+
export * from './webitelChatServerCheckSessionResponse';
|
|
1492
|
+
export * from './webitelChatServerCheckSessionResponseProperties';
|
|
1493
|
+
export * from './webitelChatServerCloseConversationCause';
|
|
1494
|
+
export * from './webitelChatServerCloseConversationResponse';
|
|
1495
|
+
export * from './webitelChatServerConversation';
|
|
1496
|
+
export * from './webitelChatServerDeclineInvitationResponse';
|
|
1497
|
+
export * from './webitelChatServerFile';
|
|
1498
|
+
export * from './webitelChatServerGateway';
|
|
1499
|
+
export * from './webitelChatServerGetConversationByIDResponse';
|
|
1500
|
+
export * from './webitelChatServerGetConversationsResponse';
|
|
1501
|
+
export * from './webitelChatServerGetHistoryMessagesResponse';
|
|
1502
|
+
export * from './webitelChatServerHistoryMessage';
|
|
1503
|
+
export * from './webitelChatServerInviteToConversationResponse';
|
|
1504
|
+
export * from './webitelChatServerJoinConversationResponse';
|
|
1505
|
+
export * from './webitelChatServerLeaveConversationCause';
|
|
1506
|
+
export * from './webitelChatServerLeaveConversationResponse';
|
|
1507
|
+
export * from './webitelChatServerMember';
|
|
1508
|
+
export * from './webitelChatServerMessage';
|
|
1509
|
+
export * from './webitelChatServerMessageForwardFromVariables';
|
|
1510
|
+
export * from './webitelChatServerMessageReplyToVariables';
|
|
1511
|
+
export * from './webitelChatServerMessageVariables';
|
|
1512
|
+
export * from './webitelChatServerPostback';
|
|
1513
|
+
export * from './webitelChatServerSendMessageResponse';
|
|
1514
|
+
export * from './webitelChatServerSendServiceMessageResponse';
|
|
1515
|
+
export * from './webitelChatServerSendUserActionResponse';
|
|
1516
|
+
export * from './webitelChatServerStartConversationResponse';
|
|
1517
|
+
export * from './webitelChatServerUpdateChannelResponse';
|
|
1518
|
+
export * from './webitelChatServerUser';
|
|
1519
|
+
export * from './webitelChatServerUserAction';
|
|
1520
|
+
export * from './webitelChatServerWaitMessageResponse';
|
|
1482
1521
|
export * from './webitelChatTimerange';
|
|
1483
1522
|
export * from './webitelcontactsAttachment';
|
|
1484
1523
|
export * from './webitelcontactsContact';
|
|
@@ -31,6 +31,7 @@ export interface WebitelChatMessage {
|
|
|
31
31
|
id?: string;
|
|
32
32
|
/** Keyboard. Buttons. Quick Replies. */
|
|
33
33
|
keyboard?: WebitelChatReplyMarkup;
|
|
34
|
+
kind?: string;
|
|
34
35
|
/** Postback. Reply Button Click[ed]. */
|
|
35
36
|
postback?: WebitelChatPostback;
|
|
36
37
|
/** Chat Sender of the message, sent on behalf of a chat (member). */
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Generated by orval v7.10.0 🍺
|
|
3
|
+
* Do not edit manually.
|
|
4
|
+
* Webitel API
|
|
5
|
+
* OpenAPI spec version: 24.04.0
|
|
6
|
+
*/
|
|
7
|
+
|
|
8
|
+
export interface WebitelChatServerAccount {
|
|
9
|
+
/** e.g.: bot, user, phone, telegram, facebook, viber, skype ... */
|
|
10
|
+
channel?: string;
|
|
11
|
+
/** optional: channel specific contact string */
|
|
12
|
+
contact?: string;
|
|
13
|
+
firstName?: string;
|
|
14
|
+
id?: string;
|
|
15
|
+
lastName?: string;
|
|
16
|
+
username?: string;
|
|
17
|
+
}
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Generated by orval v7.10.0 🍺
|
|
3
|
+
* Do not edit manually.
|
|
4
|
+
* Webitel API
|
|
5
|
+
* OpenAPI spec version: 24.04.0
|
|
6
|
+
*/
|
|
7
|
+
|
|
8
|
+
export interface WebitelChatServerButton {
|
|
9
|
+
caption?: string;
|
|
10
|
+
code?: string;
|
|
11
|
+
text?: string;
|
|
12
|
+
type?: string;
|
|
13
|
+
url?: string;
|
|
14
|
+
}
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Generated by orval v7.10.0 🍺
|
|
3
|
+
* Do not edit manually.
|
|
4
|
+
* Webitel API
|
|
5
|
+
* OpenAPI spec version: 24.04.0
|
|
6
|
+
*/
|
|
7
|
+
import type { WebitelChatServerButton } from './webitelChatServerButton';
|
|
8
|
+
|
|
9
|
+
export interface WebitelChatServerButtons {
|
|
10
|
+
button?: WebitelChatServerButton[];
|
|
11
|
+
}
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Generated by orval v7.10.0 🍺
|
|
3
|
+
* Do not edit manually.
|
|
4
|
+
* Webitel API
|
|
5
|
+
* OpenAPI spec version: 24.04.0
|
|
6
|
+
*/
|
|
7
|
+
|
|
8
|
+
export interface WebitelChatServerChannel {
|
|
9
|
+
closedAt?: string;
|
|
10
|
+
connection?: string;
|
|
11
|
+
createdAt?: string;
|
|
12
|
+
domainId?: string;
|
|
13
|
+
id?: string;
|
|
14
|
+
internal?: boolean;
|
|
15
|
+
props?: string;
|
|
16
|
+
type?: string;
|
|
17
|
+
userId?: string;
|
|
18
|
+
}
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Generated by orval v7.10.0 🍺
|
|
3
|
+
* Do not edit manually.
|
|
4
|
+
* Webitel API
|
|
5
|
+
* OpenAPI spec version: 24.04.0
|
|
6
|
+
*/
|
|
7
|
+
import type { WebitelChatServerChatVariablesResponseVariables } from './webitelChatServerChatVariablesResponseVariables';
|
|
8
|
+
|
|
9
|
+
export interface WebitelChatServerChatVariablesResponse {
|
|
10
|
+
/** Unique Chat Channel IDentifier. */
|
|
11
|
+
channelId?: string;
|
|
12
|
+
/** Result Chat Channel's Variables SET. */
|
|
13
|
+
variables?: WebitelChatServerChatVariablesResponseVariables;
|
|
14
|
+
}
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Generated by orval v7.10.0 🍺
|
|
3
|
+
* Do not edit manually.
|
|
4
|
+
* Webitel API
|
|
5
|
+
* OpenAPI spec version: 24.04.0
|
|
6
|
+
*/
|
|
7
|
+
|
|
8
|
+
/**
|
|
9
|
+
* Result Chat Channel's Variables SET.
|
|
10
|
+
*/
|
|
11
|
+
export type WebitelChatServerChatVariablesResponseVariables = {
|
|
12
|
+
[key: string]: string;
|
|
13
|
+
};
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Generated by orval v7.10.0 🍺
|
|
3
|
+
* Do not edit manually.
|
|
4
|
+
* Webitel API
|
|
5
|
+
* OpenAPI spec version: 24.04.0
|
|
6
|
+
*/
|
|
7
|
+
import type { WebitelChatServerAccount } from './webitelChatServerAccount';
|
|
8
|
+
import type { WebitelChatServerCheckSessionResponseProperties } from './webitelChatServerCheckSessionResponseProperties';
|
|
9
|
+
|
|
10
|
+
export interface WebitelChatServerCheckSessionResponse {
|
|
11
|
+
account?: WebitelChatServerAccount;
|
|
12
|
+
channelId?: string;
|
|
13
|
+
clientId?: string;
|
|
14
|
+
exists?: boolean;
|
|
15
|
+
/** optional: extra context */
|
|
16
|
+
properties?: WebitelChatServerCheckSessionResponseProperties;
|
|
17
|
+
}
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Generated by orval v7.10.0 🍺
|
|
3
|
+
* Do not edit manually.
|
|
4
|
+
* Webitel API
|
|
5
|
+
* OpenAPI spec version: 24.04.0
|
|
6
|
+
*/
|
|
7
|
+
|
|
8
|
+
/**
|
|
9
|
+
* optional: extra context
|
|
10
|
+
*/
|
|
11
|
+
export type WebitelChatServerCheckSessionResponseProperties = {
|
|
12
|
+
[key: string]: string;
|
|
13
|
+
};
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Generated by orval v7.10.0 🍺
|
|
3
|
+
* Do not edit manually.
|
|
4
|
+
* Webitel API
|
|
5
|
+
* OpenAPI spec version: 24.04.0
|
|
6
|
+
*/
|
|
7
|
+
|
|
8
|
+
export type WebitelChatServerCloseConversationCause =
|
|
9
|
+
(typeof WebitelChatServerCloseConversationCause)[keyof typeof WebitelChatServerCloseConversationCause];
|
|
10
|
+
|
|
11
|
+
// eslint-disable-next-line @typescript-eslint/no-redeclare
|
|
12
|
+
export const WebitelChatServerCloseConversationCause = {
|
|
13
|
+
NoCause: 'no_cause',
|
|
14
|
+
FlowEnd: 'flow_end',
|
|
15
|
+
ClientLeave: 'client_leave',
|
|
16
|
+
FlowErr: 'flow_err',
|
|
17
|
+
BroadcastEnd: 'broadcast_end',
|
|
18
|
+
} as const;
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Generated by orval v7.10.0 🍺
|
|
3
|
+
* Do not edit manually.
|
|
4
|
+
* Webitel API
|
|
5
|
+
* OpenAPI spec version: 24.04.0
|
|
6
|
+
*/
|
|
7
|
+
|
|
8
|
+
import type { WebitelChatServerHistoryMessage } from './webitelChatServerHistoryMessage';
|
|
9
|
+
import type { WebitelChatServerMember } from './webitelChatServerMember';
|
|
10
|
+
|
|
11
|
+
export interface WebitelChatServerConversation {
|
|
12
|
+
closedAt?: string;
|
|
13
|
+
createdAt?: string;
|
|
14
|
+
domainId?: string;
|
|
15
|
+
id?: string;
|
|
16
|
+
members?: WebitelChatServerMember[];
|
|
17
|
+
messages?: WebitelChatServerHistoryMessage[];
|
|
18
|
+
title?: string;
|
|
19
|
+
updatedAt?: string;
|
|
20
|
+
}
|