@wildix/wda-history-client 1.2.20 → 1.2.22

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.
Files changed (36) hide show
  1. package/dist-cjs/WdaHistory.js +6 -0
  2. package/dist-cjs/commands/GetCallAnnotationsCommand.js +21 -0
  3. package/dist-cjs/commands/GetChatAnnotationsCommand.js +21 -0
  4. package/dist-cjs/commands/GetConferenceAnnotationsCommand.js +21 -0
  5. package/dist-cjs/commands/index.js +3 -0
  6. package/dist-cjs/models/models_0.js +86 -13
  7. package/dist-cjs/protocols/Aws_restJson1.js +258 -2
  8. package/dist-es/WdaHistory.js +6 -0
  9. package/dist-es/commands/GetCallAnnotationsCommand.js +17 -0
  10. package/dist-es/commands/GetChatAnnotationsCommand.js +17 -0
  11. package/dist-es/commands/GetConferenceAnnotationsCommand.js +17 -0
  12. package/dist-es/commands/index.js +3 -0
  13. package/dist-es/models/models_0.js +81 -12
  14. package/dist-es/protocols/Aws_restJson1.js +254 -4
  15. package/dist-types/WdaHistory.d.ts +21 -0
  16. package/dist-types/WdaHistoryClient.d.ts +5 -2
  17. package/dist-types/commands/GetCallAnnotationsCommand.d.ts +115 -0
  18. package/dist-types/commands/GetCallCommand.d.ts +2 -1
  19. package/dist-types/commands/GetCallTranscriptionCommand.d.ts +4 -2
  20. package/dist-types/commands/GetChatAnnotationsCommand.d.ts +108 -0
  21. package/dist-types/commands/GetChatCommand.d.ts +2 -1
  22. package/dist-types/commands/GetChatTranscriptionCommand.d.ts +2 -1
  23. package/dist-types/commands/GetChatTranscriptionTextCommand.d.ts +1 -0
  24. package/dist-types/commands/GetConferenceAnnotationsCommand.d.ts +107 -0
  25. package/dist-types/commands/GetConferenceCommand.d.ts +2 -1
  26. package/dist-types/commands/GetConferenceTranscriptionCommand.d.ts +2 -2
  27. package/dist-types/commands/QueryConversationsCommand.d.ts +4 -2
  28. package/dist-types/commands/QueryUserCallsCommand.d.ts +2 -1
  29. package/dist-types/commands/UpdateCallCommand.d.ts +2 -1
  30. package/dist-types/commands/index.d.ts +3 -0
  31. package/dist-types/models/models_0.d.ts +324 -30
  32. package/dist-types/protocols/Aws_restJson1.d.ts +27 -0
  33. package/dist-types/runtimeConfig.browser.d.ts +1 -1
  34. package/dist-types/runtimeConfig.d.ts +1 -1
  35. package/dist-types/runtimeConfig.native.d.ts +1 -1
  36. package/package.json +1 -1
@@ -2,12 +2,15 @@
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.WdaHistory = void 0;
4
4
  const WdaHistoryClient_1 = require("./WdaHistoryClient");
5
+ const GetCallAnnotationsCommand_1 = require("./commands/GetCallAnnotationsCommand");
5
6
  const GetCallCommand_1 = require("./commands/GetCallCommand");
6
7
  const GetCallTranscriptionCommand_1 = require("./commands/GetCallTranscriptionCommand");
7
8
  const GetCallTranscriptionTextCommand_1 = require("./commands/GetCallTranscriptionTextCommand");
9
+ const GetChatAnnotationsCommand_1 = require("./commands/GetChatAnnotationsCommand");
8
10
  const GetChatCommand_1 = require("./commands/GetChatCommand");
9
11
  const GetChatTranscriptionCommand_1 = require("./commands/GetChatTranscriptionCommand");
10
12
  const GetChatTranscriptionTextCommand_1 = require("./commands/GetChatTranscriptionTextCommand");
13
+ const GetConferenceAnnotationsCommand_1 = require("./commands/GetConferenceAnnotationsCommand");
11
14
  const GetConferenceCommand_1 = require("./commands/GetConferenceCommand");
12
15
  const GetConferenceTranscriptionCommand_1 = require("./commands/GetConferenceTranscriptionCommand");
13
16
  const GetConferenceTranscriptionTextCommand_1 = require("./commands/GetConferenceTranscriptionTextCommand");
@@ -17,12 +20,15 @@ const UpdateCallCommand_1 = require("./commands/UpdateCallCommand");
17
20
  const smithy_client_1 = require("@smithy/smithy-client");
18
21
  const commands = {
19
22
  GetCallCommand: GetCallCommand_1.GetCallCommand,
23
+ GetCallAnnotationsCommand: GetCallAnnotationsCommand_1.GetCallAnnotationsCommand,
20
24
  GetCallTranscriptionCommand: GetCallTranscriptionCommand_1.GetCallTranscriptionCommand,
21
25
  GetCallTranscriptionTextCommand: GetCallTranscriptionTextCommand_1.GetCallTranscriptionTextCommand,
22
26
  GetChatCommand: GetChatCommand_1.GetChatCommand,
27
+ GetChatAnnotationsCommand: GetChatAnnotationsCommand_1.GetChatAnnotationsCommand,
23
28
  GetChatTranscriptionCommand: GetChatTranscriptionCommand_1.GetChatTranscriptionCommand,
24
29
  GetChatTranscriptionTextCommand: GetChatTranscriptionTextCommand_1.GetChatTranscriptionTextCommand,
25
30
  GetConferenceCommand: GetConferenceCommand_1.GetConferenceCommand,
31
+ GetConferenceAnnotationsCommand: GetConferenceAnnotationsCommand_1.GetConferenceAnnotationsCommand,
26
32
  GetConferenceTranscriptionCommand: GetConferenceTranscriptionCommand_1.GetConferenceTranscriptionCommand,
27
33
  GetConferenceTranscriptionTextCommand: GetConferenceTranscriptionTextCommand_1.GetConferenceTranscriptionTextCommand,
28
34
  QueryConversationsCommand: QueryConversationsCommand_1.QueryConversationsCommand,
@@ -0,0 +1,21 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.GetCallAnnotationsCommand = exports.$Command = void 0;
4
+ const Aws_restJson1_1 = require("../protocols/Aws_restJson1");
5
+ const middleware_serde_1 = require("@smithy/middleware-serde");
6
+ const smithy_client_1 = require("@smithy/smithy-client");
7
+ Object.defineProperty(exports, "$Command", { enumerable: true, get: function () { return smithy_client_1.Command; } });
8
+ class GetCallAnnotationsCommand extends smithy_client_1.Command.classBuilder()
9
+ .m(function (Command, cs, config, o) {
10
+ return [
11
+ (0, middleware_serde_1.getSerdePlugin)(config, this.serialize, this.deserialize),
12
+ ];
13
+ })
14
+ .s("WdaHistory", "GetCallAnnotations", {})
15
+ .n("WdaHistoryClient", "GetCallAnnotationsCommand")
16
+ .f(void 0, void 0)
17
+ .ser(Aws_restJson1_1.se_GetCallAnnotationsCommand)
18
+ .de(Aws_restJson1_1.de_GetCallAnnotationsCommand)
19
+ .build() {
20
+ }
21
+ exports.GetCallAnnotationsCommand = GetCallAnnotationsCommand;
@@ -0,0 +1,21 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.GetChatAnnotationsCommand = exports.$Command = void 0;
4
+ const Aws_restJson1_1 = require("../protocols/Aws_restJson1");
5
+ const middleware_serde_1 = require("@smithy/middleware-serde");
6
+ const smithy_client_1 = require("@smithy/smithy-client");
7
+ Object.defineProperty(exports, "$Command", { enumerable: true, get: function () { return smithy_client_1.Command; } });
8
+ class GetChatAnnotationsCommand extends smithy_client_1.Command.classBuilder()
9
+ .m(function (Command, cs, config, o) {
10
+ return [
11
+ (0, middleware_serde_1.getSerdePlugin)(config, this.serialize, this.deserialize),
12
+ ];
13
+ })
14
+ .s("WdaHistory", "GetChatAnnotations", {})
15
+ .n("WdaHistoryClient", "GetChatAnnotationsCommand")
16
+ .f(void 0, void 0)
17
+ .ser(Aws_restJson1_1.se_GetChatAnnotationsCommand)
18
+ .de(Aws_restJson1_1.de_GetChatAnnotationsCommand)
19
+ .build() {
20
+ }
21
+ exports.GetChatAnnotationsCommand = GetChatAnnotationsCommand;
@@ -0,0 +1,21 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.GetConferenceAnnotationsCommand = exports.$Command = void 0;
4
+ const Aws_restJson1_1 = require("../protocols/Aws_restJson1");
5
+ const middleware_serde_1 = require("@smithy/middleware-serde");
6
+ const smithy_client_1 = require("@smithy/smithy-client");
7
+ Object.defineProperty(exports, "$Command", { enumerable: true, get: function () { return smithy_client_1.Command; } });
8
+ class GetConferenceAnnotationsCommand extends smithy_client_1.Command.classBuilder()
9
+ .m(function (Command, cs, config, o) {
10
+ return [
11
+ (0, middleware_serde_1.getSerdePlugin)(config, this.serialize, this.deserialize),
12
+ ];
13
+ })
14
+ .s("WdaHistory", "GetConferenceAnnotations", {})
15
+ .n("WdaHistoryClient", "GetConferenceAnnotationsCommand")
16
+ .f(void 0, void 0)
17
+ .ser(Aws_restJson1_1.se_GetConferenceAnnotationsCommand)
18
+ .de(Aws_restJson1_1.de_GetConferenceAnnotationsCommand)
19
+ .build() {
20
+ }
21
+ exports.GetConferenceAnnotationsCommand = GetConferenceAnnotationsCommand;
@@ -2,12 +2,15 @@
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  const tslib_1 = require("tslib");
4
4
  tslib_1.__exportStar(require("./GetCallCommand"), exports);
5
+ tslib_1.__exportStar(require("./GetCallAnnotationsCommand"), exports);
5
6
  tslib_1.__exportStar(require("./GetCallTranscriptionCommand"), exports);
6
7
  tslib_1.__exportStar(require("./GetCallTranscriptionTextCommand"), exports);
7
8
  tslib_1.__exportStar(require("./GetChatCommand"), exports);
9
+ tslib_1.__exportStar(require("./GetChatAnnotationsCommand"), exports);
8
10
  tslib_1.__exportStar(require("./GetChatTranscriptionCommand"), exports);
9
11
  tslib_1.__exportStar(require("./GetChatTranscriptionTextCommand"), exports);
10
12
  tslib_1.__exportStar(require("./GetConferenceCommand"), exports);
13
+ tslib_1.__exportStar(require("./GetConferenceAnnotationsCommand"), exports);
11
14
  tslib_1.__exportStar(require("./GetConferenceTranscriptionCommand"), exports);
12
15
  tslib_1.__exportStar(require("./GetConferenceTranscriptionTextCommand"), exports);
13
16
  tslib_1.__exportStar(require("./QueryConversationsCommand"), exports);
@@ -1,6 +1,7 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.ConversationUserDirection = exports.ConversationFlag = exports.ConversationDirection = exports.Conversation = exports.ConferenceTranscriptionNotFoundException = exports.ConferenceTranscriptionStatus = exports.ConferenceParticipantType = exports.ConferenceParticipantRole = exports.PbxLicenseType = exports.ConferenceDirection = exports.ConferenceNotFoundException = exports.MessageWhatsAppStatus = exports.MessageType = exports.MessageSmsStatus = exports.Element = exports.ActionElement = exports.ButtonVariant = exports.ButtonHandler = exports.ChatTranscriptionNotFoundException = exports.ChatTag = exports.ChatStatus = exports.ChatParticipantType = exports.ChatParticipantRole = exports.ChatDirection = exports.ChannelWhatsAppStatus = exports.ChannelContextSource = exports.ChannelContextEventAttendeeStatus = exports.ChannelType = exports.ChannelAccess = exports.ChatNotFoundException = exports.CallTranscriptionNotFoundException = exports.CallTranscriptionSpeaker = exports.RecordType = exports.CallFlowTranscriptionStatus = exports.License = exports.CallDevice = exports.CallParticipantType = exports.CallParticipantRole = exports.CallFlowAttachmentType = exports.CallFlowAttachment = exports.CallRecordPauseReason = exports.CallFlowAttachmentStatus = exports.CallRecordOwner = exports.CallNotFoundException = exports.ConversationStatus = exports.CallDirection = exports.ValidationException = exports.ForbiddenException = void 0;
3
+ exports.ConferenceTranscriptionStatus = exports.ConferenceParticipantType = exports.ConferenceParticipantRole = exports.PbxLicenseType = exports.ConferenceDirection = exports.ConferenceNotFoundException = exports.ConferenceAnnotationsNotFoundException = exports.MessageWhatsAppStatus = exports.MessageType = exports.MessageSmsStatus = exports.Element = exports.ActionElement = exports.ButtonVariant = exports.ButtonHandler = exports.ChatTranscriptionNotFoundException = exports.ChatTag = exports.ChatStatus = exports.ChatParticipantType = exports.ChatParticipantRole = exports.ChatDirection = exports.ChannelWhatsAppStatus = exports.ChannelContextSource = exports.ChannelContextEventAttendeeStatus = exports.ChannelType = exports.ChannelAccess = exports.ChatNotFoundException = exports.ChatAnnotationsNotFoundException = exports.TranscriptionSentiment = exports.CallTranscriptionNotFoundException = exports.CallTranscriptionSpeaker = exports.CallFlowTranscriptionStatus = exports.CallDevice = exports.CallParticipantType = exports.CallParticipantRole = exports.CallFlowAttachmentType = exports.CallFlowAttachment = exports.CallRecordPauseReason = exports.CallFlowAttachmentStatus = exports.CallRecordOwner = exports.AnnotationsStatus = exports.CallNotFoundException = exports.RecordType = exports.License = exports.AnnotationSourceType = exports.AnnotationPayload = exports.CallAnnotationsNotFoundException = exports.ConversationStatus = exports.CallDirection = exports.ValidationException = exports.ForbiddenException = void 0;
4
+ exports.ConversationUserDirection = exports.ConversationFlag = exports.ConversationDirection = exports.Conversation = exports.ConferenceTranscriptionNotFoundException = void 0;
4
5
  const WdaHistoryServiceException_1 = require("./WdaHistoryServiceException");
5
6
  class ForbiddenException extends WdaHistoryServiceException_1.WdaHistoryServiceException {
6
7
  name = "ForbiddenException";
@@ -38,6 +39,54 @@ exports.ConversationStatus = {
38
39
  COMPLETED: "COMPLETED",
39
40
  MISSED: "MISSED",
40
41
  };
42
+ class CallAnnotationsNotFoundException extends WdaHistoryServiceException_1.WdaHistoryServiceException {
43
+ name = "CallAnnotationsNotFoundException";
44
+ $fault = "client";
45
+ constructor(opts) {
46
+ super({
47
+ name: "CallAnnotationsNotFoundException",
48
+ $fault: "client",
49
+ ...opts
50
+ });
51
+ Object.setPrototypeOf(this, CallAnnotationsNotFoundException.prototype);
52
+ }
53
+ }
54
+ exports.CallAnnotationsNotFoundException = CallAnnotationsNotFoundException;
55
+ var AnnotationPayload;
56
+ (function (AnnotationPayload) {
57
+ AnnotationPayload.visit = (value, visitor) => {
58
+ if (value.tag !== undefined)
59
+ return visitor.tag(value.tag);
60
+ if (value.text !== undefined)
61
+ return visitor.text(value.text);
62
+ if (value.variables !== undefined)
63
+ return visitor.variables(value.variables);
64
+ if (value.result !== undefined)
65
+ return visitor.result(value.result);
66
+ return visitor._(value.$unknown[0], value.$unknown[1]);
67
+ };
68
+ })(AnnotationPayload || (exports.AnnotationPayload = AnnotationPayload = {}));
69
+ exports.AnnotationSourceType = {
70
+ CHATBOT: "chatbot",
71
+ SYSTEM: "system",
72
+ USER: "user",
73
+ VOICEBOT: "voicebot",
74
+ };
75
+ exports.License = {
76
+ UC: "uc",
77
+ XBEES: "x-bees",
78
+ };
79
+ exports.RecordType = {
80
+ CALL: "call",
81
+ CALL_ANNOTATIONS: "call_annotations",
82
+ CALL_TRANSCRIPTION: "call_transcription",
83
+ CHAT: "chat",
84
+ CHAT_ANNOTATIONS: "chat_annotations",
85
+ CHAT_TRANSCRIPTION: "chat_transcription",
86
+ CONFERENCE: "conference",
87
+ CONFERENCE_ANNOTATIONS: "conference_annotations",
88
+ CONFERENCE_TRANSCRIPTION: "conference_transcription",
89
+ };
41
90
  class CallNotFoundException extends WdaHistoryServiceException_1.WdaHistoryServiceException {
42
91
  name = "CallNotFoundException";
43
92
  $fault = "client";
@@ -51,6 +100,10 @@ class CallNotFoundException extends WdaHistoryServiceException_1.WdaHistoryServi
51
100
  }
52
101
  }
53
102
  exports.CallNotFoundException = CallNotFoundException;
103
+ exports.AnnotationsStatus = {
104
+ AVAILABLE: "AVAILABLE",
105
+ UNAVAILABLE: "UNAVAILABLE",
106
+ };
54
107
  exports.CallRecordOwner = {
55
108
  CALLEE: "callee",
56
109
  CALLER: "caller",
@@ -100,23 +153,11 @@ exports.CallDevice = {
100
153
  XBEES_IOS: "XBEES_IOS",
101
154
  XBEES_WEB: "XBEES_WEB",
102
155
  };
103
- exports.License = {
104
- UC: "uc",
105
- XBEES: "x-bees",
106
- };
107
156
  exports.CallFlowTranscriptionStatus = {
108
157
  AVAILABLE: "AVAILABLE",
109
158
  POST_TRANSCRIPTION: "POST_TRANSCRIPTION",
110
159
  UNAVAILABLE: "UNAVAILABLE",
111
160
  };
112
- exports.RecordType = {
113
- CALL: "call",
114
- CALL_TRANSCRIPTION: "call_transcription",
115
- CHAT: "chat",
116
- CHAT_TRANSCRIPTION: "chat_transcription",
117
- CONFERENCE: "conference",
118
- CONFERENCE_TRANSCRIPTION: "conference_transcription",
119
- };
120
161
  exports.CallTranscriptionSpeaker = {
121
162
  CALLEE: "callee",
122
163
  CALLER: "caller",
@@ -134,6 +175,25 @@ class CallTranscriptionNotFoundException extends WdaHistoryServiceException_1.Wd
134
175
  }
135
176
  }
136
177
  exports.CallTranscriptionNotFoundException = CallTranscriptionNotFoundException;
178
+ exports.TranscriptionSentiment = {
179
+ MIXED: "MIXED",
180
+ NEGATIVE: "NEGATIVE",
181
+ NEUTRAL: "NEUTRAL",
182
+ POSITIVE: "POSITIVE",
183
+ };
184
+ class ChatAnnotationsNotFoundException extends WdaHistoryServiceException_1.WdaHistoryServiceException {
185
+ name = "ChatAnnotationsNotFoundException";
186
+ $fault = "client";
187
+ constructor(opts) {
188
+ super({
189
+ name: "ChatAnnotationsNotFoundException",
190
+ $fault: "client",
191
+ ...opts
192
+ });
193
+ Object.setPrototypeOf(this, ChatAnnotationsNotFoundException.prototype);
194
+ }
195
+ }
196
+ exports.ChatAnnotationsNotFoundException = ChatAnnotationsNotFoundException;
137
197
  class ChatNotFoundException extends WdaHistoryServiceException_1.WdaHistoryServiceException {
138
198
  name = "ChatNotFoundException";
139
199
  $fault = "client";
@@ -256,6 +316,19 @@ exports.MessageWhatsAppStatus = {
256
316
  SENT: "sent",
257
317
  TRYING: "trying",
258
318
  };
319
+ class ConferenceAnnotationsNotFoundException extends WdaHistoryServiceException_1.WdaHistoryServiceException {
320
+ name = "ConferenceAnnotationsNotFoundException";
321
+ $fault = "client";
322
+ constructor(opts) {
323
+ super({
324
+ name: "ConferenceAnnotationsNotFoundException",
325
+ $fault: "client",
326
+ ...opts
327
+ });
328
+ Object.setPrototypeOf(this, ConferenceAnnotationsNotFoundException.prototype);
329
+ }
330
+ }
331
+ exports.ConferenceAnnotationsNotFoundException = ConferenceAnnotationsNotFoundException;
259
332
  class ConferenceNotFoundException extends WdaHistoryServiceException_1.WdaHistoryServiceException {
260
333
  name = "ConferenceNotFoundException";
261
334
  $fault = "client";
@@ -1,6 +1,6 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.de_UpdateCallCommand = exports.de_QueryUserCallsCommand = exports.de_QueryConversationsCommand = exports.de_GetConferenceTranscriptionTextCommand = exports.de_GetConferenceTranscriptionCommand = exports.de_GetConferenceCommand = exports.de_GetChatTranscriptionTextCommand = exports.de_GetChatTranscriptionCommand = exports.de_GetChatCommand = exports.de_GetCallTranscriptionTextCommand = exports.de_GetCallTranscriptionCommand = exports.de_GetCallCommand = exports.se_UpdateCallCommand = exports.se_QueryUserCallsCommand = exports.se_QueryConversationsCommand = exports.se_GetConferenceTranscriptionTextCommand = exports.se_GetConferenceTranscriptionCommand = exports.se_GetConferenceCommand = exports.se_GetChatTranscriptionTextCommand = exports.se_GetChatTranscriptionCommand = exports.se_GetChatCommand = exports.se_GetCallTranscriptionTextCommand = exports.se_GetCallTranscriptionCommand = exports.se_GetCallCommand = void 0;
3
+ exports.de_UpdateCallCommand = exports.de_QueryUserCallsCommand = exports.de_QueryConversationsCommand = exports.de_GetConferenceTranscriptionTextCommand = exports.de_GetConferenceTranscriptionCommand = exports.de_GetConferenceAnnotationsCommand = exports.de_GetConferenceCommand = exports.de_GetChatTranscriptionTextCommand = exports.de_GetChatTranscriptionCommand = exports.de_GetChatAnnotationsCommand = exports.de_GetChatCommand = exports.de_GetCallTranscriptionTextCommand = exports.de_GetCallTranscriptionCommand = exports.de_GetCallAnnotationsCommand = exports.de_GetCallCommand = exports.se_UpdateCallCommand = exports.se_QueryUserCallsCommand = exports.se_QueryConversationsCommand = exports.se_GetConferenceTranscriptionTextCommand = exports.se_GetConferenceTranscriptionCommand = exports.se_GetConferenceAnnotationsCommand = exports.se_GetConferenceCommand = exports.se_GetChatTranscriptionTextCommand = exports.se_GetChatTranscriptionCommand = exports.se_GetChatAnnotationsCommand = exports.se_GetChatCommand = exports.se_GetCallTranscriptionTextCommand = exports.se_GetCallTranscriptionCommand = exports.se_GetCallAnnotationsCommand = exports.se_GetCallCommand = void 0;
4
4
  const WdaHistoryServiceException_1 = require("../models/WdaHistoryServiceException");
5
5
  const models_0_1 = require("../models/models_0");
6
6
  const core_1 = require("@aws-sdk/core");
@@ -23,6 +23,23 @@ const se_GetCallCommand = async (input, context) => {
23
23
  return b.build();
24
24
  };
25
25
  exports.se_GetCallCommand = se_GetCallCommand;
26
+ const se_GetCallAnnotationsCommand = async (input, context) => {
27
+ const b = (0, core_2.requestBuilder)(input, context);
28
+ const headers = {};
29
+ b.bp("/v2/history/calls/{callId}/flows/{flowIndex}/annotations");
30
+ b.p('callId', () => input.callId, '{callId}', false);
31
+ b.p('flowIndex', () => input.flowIndex.toString(), '{flowIndex}', false);
32
+ const query = (0, smithy_client_1.map)({
33
+ [_c]: [, input[_c]],
34
+ });
35
+ let body;
36
+ b.m("GET")
37
+ .h(headers)
38
+ .q(query)
39
+ .b(body);
40
+ return b.build();
41
+ };
42
+ exports.se_GetCallAnnotationsCommand = se_GetCallAnnotationsCommand;
26
43
  const se_GetCallTranscriptionCommand = async (input, context) => {
27
44
  const b = (0, core_2.requestBuilder)(input, context);
28
45
  const headers = {};
@@ -73,6 +90,22 @@ const se_GetChatCommand = async (input, context) => {
73
90
  return b.build();
74
91
  };
75
92
  exports.se_GetChatCommand = se_GetChatCommand;
93
+ const se_GetChatAnnotationsCommand = async (input, context) => {
94
+ const b = (0, core_2.requestBuilder)(input, context);
95
+ const headers = {};
96
+ b.bp("/v2/history/chats/{chatId}/annotations");
97
+ b.p('chatId', () => input.chatId, '{chatId}', false);
98
+ const query = (0, smithy_client_1.map)({
99
+ [_c]: [, input[_c]],
100
+ });
101
+ let body;
102
+ b.m("GET")
103
+ .h(headers)
104
+ .q(query)
105
+ .b(body);
106
+ return b.build();
107
+ };
108
+ exports.se_GetChatAnnotationsCommand = se_GetChatAnnotationsCommand;
76
109
  const se_GetChatTranscriptionCommand = async (input, context) => {
77
110
  const b = (0, core_2.requestBuilder)(input, context);
78
111
  const headers = {};
@@ -121,6 +154,22 @@ const se_GetConferenceCommand = async (input, context) => {
121
154
  return b.build();
122
155
  };
123
156
  exports.se_GetConferenceCommand = se_GetConferenceCommand;
157
+ const se_GetConferenceAnnotationsCommand = async (input, context) => {
158
+ const b = (0, core_2.requestBuilder)(input, context);
159
+ const headers = {};
160
+ b.bp("/v2/history/conferences/{conferenceId}/annotations");
161
+ b.p('conferenceId', () => input.conferenceId, '{conferenceId}', false);
162
+ const query = (0, smithy_client_1.map)({
163
+ [_c]: [, input[_c]],
164
+ });
165
+ let body;
166
+ b.m("GET")
167
+ .h(headers)
168
+ .q(query)
169
+ .b(body);
170
+ return b.build();
171
+ };
172
+ exports.se_GetConferenceAnnotationsCommand = se_GetConferenceAnnotationsCommand;
124
173
  const se_GetConferenceTranscriptionCommand = async (input, context) => {
125
174
  const b = (0, core_2.requestBuilder)(input, context);
126
175
  const headers = {};
@@ -236,6 +285,21 @@ const de_GetCallCommand = async (output, context) => {
236
285
  return contents;
237
286
  };
238
287
  exports.de_GetCallCommand = de_GetCallCommand;
288
+ const de_GetCallAnnotationsCommand = async (output, context) => {
289
+ if (output.statusCode !== 200 && output.statusCode >= 300) {
290
+ return de_CommandError(output, context);
291
+ }
292
+ const contents = (0, smithy_client_1.map)({
293
+ $metadata: deserializeMetadata(output),
294
+ });
295
+ const data = (0, smithy_client_1.expectNonNull)(((0, smithy_client_1.expectObject)(await (0, core_1.parseJsonBody)(output.body, context))), "body");
296
+ const doc = (0, smithy_client_1.take)(data, {
297
+ 'annotations': _ => de_CallAnnotationsRecord(_, context),
298
+ });
299
+ Object.assign(contents, doc);
300
+ return contents;
301
+ };
302
+ exports.de_GetCallAnnotationsCommand = de_GetCallAnnotationsCommand;
239
303
  const de_GetCallTranscriptionCommand = async (output, context) => {
240
304
  if (output.statusCode !== 200 && output.statusCode >= 300) {
241
305
  return de_CommandError(output, context);
@@ -246,7 +310,7 @@ const de_GetCallTranscriptionCommand = async (output, context) => {
246
310
  const data = (0, smithy_client_1.expectNonNull)(((0, smithy_client_1.expectObject)(await (0, core_1.parseJsonBody)(output.body, context))), "body");
247
311
  const doc = (0, smithy_client_1.take)(data, {
248
312
  'interaction': _ => de_CallTranscriptionInteractionRecord(_, context),
249
- 'transcription': smithy_client_1._json,
313
+ 'transcription': _ => de_CallTranscriptionRecord(_, context),
250
314
  });
251
315
  Object.assign(contents, doc);
252
316
  return contents;
@@ -284,6 +348,21 @@ const de_GetChatCommand = async (output, context) => {
284
348
  return contents;
285
349
  };
286
350
  exports.de_GetChatCommand = de_GetChatCommand;
351
+ const de_GetChatAnnotationsCommand = async (output, context) => {
352
+ if (output.statusCode !== 200 && output.statusCode >= 300) {
353
+ return de_CommandError(output, context);
354
+ }
355
+ const contents = (0, smithy_client_1.map)({
356
+ $metadata: deserializeMetadata(output),
357
+ });
358
+ const data = (0, smithy_client_1.expectNonNull)(((0, smithy_client_1.expectObject)(await (0, core_1.parseJsonBody)(output.body, context))), "body");
359
+ const doc = (0, smithy_client_1.take)(data, {
360
+ 'annotations': _ => de_ChatAnnotationsRecord(_, context),
361
+ });
362
+ Object.assign(contents, doc);
363
+ return contents;
364
+ };
365
+ exports.de_GetChatAnnotationsCommand = de_GetChatAnnotationsCommand;
287
366
  const de_GetChatTranscriptionCommand = async (output, context) => {
288
367
  if (output.statusCode !== 200 && output.statusCode >= 300) {
289
368
  return de_CommandError(output, context);
@@ -331,6 +410,21 @@ const de_GetConferenceCommand = async (output, context) => {
331
410
  return contents;
332
411
  };
333
412
  exports.de_GetConferenceCommand = de_GetConferenceCommand;
413
+ const de_GetConferenceAnnotationsCommand = async (output, context) => {
414
+ if (output.statusCode !== 200 && output.statusCode >= 300) {
415
+ return de_CommandError(output, context);
416
+ }
417
+ const contents = (0, smithy_client_1.map)({
418
+ $metadata: deserializeMetadata(output),
419
+ });
420
+ const data = (0, smithy_client_1.expectNonNull)(((0, smithy_client_1.expectObject)(await (0, core_1.parseJsonBody)(output.body, context))), "body");
421
+ const doc = (0, smithy_client_1.take)(data, {
422
+ 'annotations': _ => de_ConferenceAnnotationsRecord(_, context),
423
+ });
424
+ Object.assign(contents, doc);
425
+ return contents;
426
+ };
427
+ exports.de_GetConferenceAnnotationsCommand = de_GetConferenceAnnotationsCommand;
334
428
  const de_GetConferenceTranscriptionCommand = async (output, context) => {
335
429
  if (output.statusCode !== 200 && output.statusCode >= 300) {
336
430
  return de_CommandError(output, context);
@@ -425,18 +519,27 @@ const de_CommandError = async (output, context) => {
425
519
  case "ValidationException":
426
520
  case "smithy.framework#ValidationException":
427
521
  throw await de_ValidationExceptionRes(parsedOutput, context);
522
+ case "CallAnnotationsNotFoundException":
523
+ case "wildix.wda.history#CallAnnotationsNotFoundException":
524
+ throw await de_CallAnnotationsNotFoundExceptionRes(parsedOutput, context);
428
525
  case "CallTranscriptionNotFoundException":
429
526
  case "wildix.wda.history#CallTranscriptionNotFoundException":
430
527
  throw await de_CallTranscriptionNotFoundExceptionRes(parsedOutput, context);
431
528
  case "ChatNotFoundException":
432
529
  case "wildix.wda.history#ChatNotFoundException":
433
530
  throw await de_ChatNotFoundExceptionRes(parsedOutput, context);
531
+ case "ChatAnnotationsNotFoundException":
532
+ case "wildix.wda.history#ChatAnnotationsNotFoundException":
533
+ throw await de_ChatAnnotationsNotFoundExceptionRes(parsedOutput, context);
434
534
  case "ChatTranscriptionNotFoundException":
435
535
  case "wildix.wda.history#ChatTranscriptionNotFoundException":
436
536
  throw await de_ChatTranscriptionNotFoundExceptionRes(parsedOutput, context);
437
537
  case "ConferenceNotFoundException":
438
538
  case "wildix.wda.history#ConferenceNotFoundException":
439
539
  throw await de_ConferenceNotFoundExceptionRes(parsedOutput, context);
540
+ case "ConferenceAnnotationsNotFoundException":
541
+ case "wildix.wda.history#ConferenceAnnotationsNotFoundException":
542
+ throw await de_ConferenceAnnotationsNotFoundExceptionRes(parsedOutput, context);
440
543
  case "ConferenceTranscriptionNotFoundException":
441
544
  case "wildix.wda.history#ConferenceTranscriptionNotFoundException":
442
545
  throw await de_ConferenceTranscriptionNotFoundExceptionRes(parsedOutput, context);
@@ -476,6 +579,19 @@ const de_ValidationExceptionRes = async (parsedOutput, context) => {
476
579
  });
477
580
  return (0, smithy_client_1.decorateServiceException)(exception, parsedOutput.body);
478
581
  };
582
+ const de_CallAnnotationsNotFoundExceptionRes = async (parsedOutput, context) => {
583
+ const contents = (0, smithy_client_1.map)({});
584
+ const data = parsedOutput.body;
585
+ const doc = (0, smithy_client_1.take)(data, {
586
+ 'message': smithy_client_1.expectString,
587
+ });
588
+ Object.assign(contents, doc);
589
+ const exception = new models_0_1.CallAnnotationsNotFoundException({
590
+ $metadata: deserializeMetadata(parsedOutput),
591
+ ...contents
592
+ });
593
+ return (0, smithy_client_1.decorateServiceException)(exception, parsedOutput.body);
594
+ };
479
595
  const de_CallNotFoundExceptionRes = async (parsedOutput, context) => {
480
596
  const contents = (0, smithy_client_1.map)({});
481
597
  const data = parsedOutput.body;
@@ -502,6 +618,19 @@ const de_CallTranscriptionNotFoundExceptionRes = async (parsedOutput, context) =
502
618
  });
503
619
  return (0, smithy_client_1.decorateServiceException)(exception, parsedOutput.body);
504
620
  };
621
+ const de_ChatAnnotationsNotFoundExceptionRes = async (parsedOutput, context) => {
622
+ const contents = (0, smithy_client_1.map)({});
623
+ const data = parsedOutput.body;
624
+ const doc = (0, smithy_client_1.take)(data, {
625
+ 'message': smithy_client_1.expectString,
626
+ });
627
+ Object.assign(contents, doc);
628
+ const exception = new models_0_1.ChatAnnotationsNotFoundException({
629
+ $metadata: deserializeMetadata(parsedOutput),
630
+ ...contents
631
+ });
632
+ return (0, smithy_client_1.decorateServiceException)(exception, parsedOutput.body);
633
+ };
505
634
  const de_ChatNotFoundExceptionRes = async (parsedOutput, context) => {
506
635
  const contents = (0, smithy_client_1.map)({});
507
636
  const data = parsedOutput.body;
@@ -528,6 +657,19 @@ const de_ChatTranscriptionNotFoundExceptionRes = async (parsedOutput, context) =
528
657
  });
529
658
  return (0, smithy_client_1.decorateServiceException)(exception, parsedOutput.body);
530
659
  };
660
+ const de_ConferenceAnnotationsNotFoundExceptionRes = async (parsedOutput, context) => {
661
+ const contents = (0, smithy_client_1.map)({});
662
+ const data = parsedOutput.body;
663
+ const doc = (0, smithy_client_1.take)(data, {
664
+ 'message': smithy_client_1.expectString,
665
+ });
666
+ Object.assign(contents, doc);
667
+ const exception = new models_0_1.ConferenceAnnotationsNotFoundException({
668
+ $metadata: deserializeMetadata(parsedOutput),
669
+ ...contents
670
+ });
671
+ return (0, smithy_client_1.decorateServiceException)(exception, parsedOutput.body);
672
+ };
531
673
  const de_ConferenceNotFoundExceptionRes = async (parsedOutput, context) => {
532
674
  const contents = (0, smithy_client_1.map)({});
533
675
  const data = parsedOutput.body;
@@ -579,6 +721,23 @@ const se_QueryUserCallsFilter = (input, context) => {
579
721
  'userDirection': [],
580
722
  });
581
723
  };
724
+ const de_Document = (output, context) => {
725
+ return output;
726
+ };
727
+ const de_CallAnnotationsRecord = (output, context) => {
728
+ return (0, smithy_client_1.take)(output, {
729
+ 'annotations': (_) => de_Annotations(_, context),
730
+ 'callStartTime': smithy_client_1.expectLong,
731
+ 'company': smithy_client_1.expectString,
732
+ 'flowIndex': smithy_client_1.expectInt32,
733
+ 'flowStartTime': smithy_client_1.expectLong,
734
+ 'id': smithy_client_1.expectString,
735
+ 'licenses': smithy_client_1._json,
736
+ 'pbx': smithy_client_1.expectString,
737
+ 'time': smithy_client_1.expectLong,
738
+ 'type': smithy_client_1.expectString,
739
+ });
740
+ };
582
741
  const de_CallTranscriptionInteractionRecord = (output, context) => {
583
742
  return (0, smithy_client_1.take)(output, {
584
743
  'interruptions': smithy_client_1.expectInt32,
@@ -590,6 +749,39 @@ const de_CallTranscriptionInteractionRecord = (output, context) => {
590
749
  'wordsPerMinute': smithy_client_1.expectInt32,
591
750
  });
592
751
  };
752
+ const de_CallTranscriptionRecord = (output, context) => {
753
+ return (0, smithy_client_1.take)(output, {
754
+ 'callStartTime': smithy_client_1.expectLong,
755
+ 'chunks': (_) => de_CallTranscriptionChunksList(_, context),
756
+ 'company': smithy_client_1.expectString,
757
+ 'flowIndex': smithy_client_1.expectInt32,
758
+ 'flowStartTime': smithy_client_1.expectLong,
759
+ 'id': smithy_client_1.expectString,
760
+ 'licenses': smithy_client_1._json,
761
+ 'pbx': smithy_client_1.expectString,
762
+ 'time': smithy_client_1.expectLong,
763
+ 'type': smithy_client_1.expectString,
764
+ });
765
+ };
766
+ const de_ChatAnnotationsRecord = (output, context) => {
767
+ return (0, smithy_client_1.take)(output, {
768
+ 'annotations': (_) => de_Annotations(_, context),
769
+ 'chatId': smithy_client_1.expectString,
770
+ 'company': smithy_client_1.expectString,
771
+ 'id': smithy_client_1.expectString,
772
+ 'time': smithy_client_1.expectLong,
773
+ 'type': smithy_client_1.expectString,
774
+ });
775
+ };
776
+ const de_ConferenceAnnotationsRecord = (output, context) => {
777
+ return (0, smithy_client_1.take)(output, {
778
+ 'annotations': (_) => de_Annotations(_, context),
779
+ 'company': smithy_client_1.expectString,
780
+ 'id': smithy_client_1.expectString,
781
+ 'time': smithy_client_1.expectLong,
782
+ 'type': smithy_client_1.expectString,
783
+ });
784
+ };
593
785
  const de_ConferenceTranscriptionInteractionRecord = (output, context) => {
594
786
  return (0, smithy_client_1.take)(output, {
595
787
  'interruptions': smithy_client_1.expectInt32,
@@ -601,6 +793,70 @@ const de_ConferenceTranscriptionInteractionRecord = (output, context) => {
601
793
  'wordsPerMinute': smithy_client_1.expectInt32,
602
794
  });
603
795
  };
796
+ const de_Annotation = (output, context) => {
797
+ return (0, smithy_client_1.take)(output, {
798
+ 'id': smithy_client_1.expectString,
799
+ 'payload': (_) => de_AnnotationPayload((0, core_1.awsExpectUnion)(_), context),
800
+ 'source': smithy_client_1._json,
801
+ 'time': smithy_client_1.expectLong,
802
+ });
803
+ };
804
+ const de_AnnotationPayload = (output, context) => {
805
+ if (output.result != null) {
806
+ return {
807
+ result: de_AnnotationResultValue(output.result, context)
808
+ };
809
+ }
810
+ if ((0, smithy_client_1.expectString)(output.tag) !== undefined) {
811
+ return { tag: (0, smithy_client_1.expectString)(output.tag) };
812
+ }
813
+ if ((0, smithy_client_1.expectString)(output.text) !== undefined) {
814
+ return { text: (0, smithy_client_1.expectString)(output.text) };
815
+ }
816
+ if (output.variables != null) {
817
+ return {
818
+ variables: de_AnnotationVariablesValue(output.variables, context)
819
+ };
820
+ }
821
+ return { $unknown: Object.entries(output)[0] };
822
+ };
823
+ const de_AnnotationResultValue = (output, context) => {
824
+ return (0, smithy_client_1.take)(output, {
825
+ 'value': (_) => de_Document(_, context),
826
+ });
827
+ };
828
+ const de_Annotations = (output, context) => {
829
+ const retVal = (output || []).filter((e) => e != null).map((entry) => {
830
+ return de_Annotation(entry, context);
831
+ });
832
+ return retVal;
833
+ };
834
+ const de_AnnotationVariablesValue = (output, context) => {
835
+ return (0, smithy_client_1.take)(output, {
836
+ 'value': (_) => de_Document(_, context),
837
+ });
838
+ };
839
+ const de_CallTranscriptionChunk = (output, context) => {
840
+ return (0, smithy_client_1.take)(output, {
841
+ 'confidence': smithy_client_1.limitedParseDouble,
842
+ 'end': smithy_client_1.expectLong,
843
+ 'id': smithy_client_1.expectString,
844
+ 'isFinal': smithy_client_1.expectBoolean,
845
+ 'language': smithy_client_1.expectString,
846
+ 'sentiment': smithy_client_1.expectString,
847
+ 'shouldComputeSentiment': smithy_client_1.expectBoolean,
848
+ 'speaker': smithy_client_1.expectString,
849
+ 'start': smithy_client_1.expectLong,
850
+ 'text': smithy_client_1.expectString,
851
+ 'time': smithy_client_1.expectLong,
852
+ });
853
+ };
854
+ const de_CallTranscriptionChunksList = (output, context) => {
855
+ const retVal = (output || []).filter((e) => e != null).map((entry) => {
856
+ return de_CallTranscriptionChunk(entry, context);
857
+ });
858
+ return retVal;
859
+ };
604
860
  const deserializeMetadata = (output) => ({
605
861
  httpStatusCode: output.statusCode,
606
862
  requestId: output.headers["x-amzn-requestid"] ?? output.headers["x-amzn-request-id"] ?? output.headers["x-amz-request-id"],
@@ -1,10 +1,13 @@
1
1
  import { WdaHistoryClient, } from "./WdaHistoryClient";
2
+ import { GetCallAnnotationsCommand, } from "./commands/GetCallAnnotationsCommand";
2
3
  import { GetCallCommand, } from "./commands/GetCallCommand";
3
4
  import { GetCallTranscriptionCommand, } from "./commands/GetCallTranscriptionCommand";
4
5
  import { GetCallTranscriptionTextCommand, } from "./commands/GetCallTranscriptionTextCommand";
6
+ import { GetChatAnnotationsCommand, } from "./commands/GetChatAnnotationsCommand";
5
7
  import { GetChatCommand, } from "./commands/GetChatCommand";
6
8
  import { GetChatTranscriptionCommand, } from "./commands/GetChatTranscriptionCommand";
7
9
  import { GetChatTranscriptionTextCommand, } from "./commands/GetChatTranscriptionTextCommand";
10
+ import { GetConferenceAnnotationsCommand, } from "./commands/GetConferenceAnnotationsCommand";
8
11
  import { GetConferenceCommand, } from "./commands/GetConferenceCommand";
9
12
  import { GetConferenceTranscriptionCommand, } from "./commands/GetConferenceTranscriptionCommand";
10
13
  import { GetConferenceTranscriptionTextCommand, } from "./commands/GetConferenceTranscriptionTextCommand";
@@ -14,12 +17,15 @@ import { UpdateCallCommand, } from "./commands/UpdateCallCommand";
14
17
  import { createAggregatedClient } from "@smithy/smithy-client";
15
18
  const commands = {
16
19
  GetCallCommand,
20
+ GetCallAnnotationsCommand,
17
21
  GetCallTranscriptionCommand,
18
22
  GetCallTranscriptionTextCommand,
19
23
  GetChatCommand,
24
+ GetChatAnnotationsCommand,
20
25
  GetChatTranscriptionCommand,
21
26
  GetChatTranscriptionTextCommand,
22
27
  GetConferenceCommand,
28
+ GetConferenceAnnotationsCommand,
23
29
  GetConferenceTranscriptionCommand,
24
30
  GetConferenceTranscriptionTextCommand,
25
31
  QueryConversationsCommand,