@wildix/wilma-voice-client 0.0.32 → 0.0.34

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.
@@ -9,6 +9,7 @@ const SendPlayCommand_1 = require("./commands/SendPlayCommand");
9
9
  const SendSayCommand_1 = require("./commands/SendSayCommand");
10
10
  const SendStopCommand_1 = require("./commands/SendStopCommand");
11
11
  const SendTransferCommand_1 = require("./commands/SendTransferCommand");
12
+ const StreamCallEventsCommand_1 = require("./commands/StreamCallEventsCommand");
12
13
  const TextToSpeechCommand_1 = require("./commands/TextToSpeechCommand");
13
14
  const WilmaVoiceClient_1 = require("./WilmaVoiceClient");
14
15
  const commands = {
@@ -19,6 +20,7 @@ const commands = {
19
20
  SendSayCommand: SendSayCommand_1.SendSayCommand,
20
21
  SendStopCommand: SendStopCommand_1.SendStopCommand,
21
22
  SendTransferCommand: SendTransferCommand_1.SendTransferCommand,
23
+ StreamCallEventsCommand: StreamCallEventsCommand_1.StreamCallEventsCommand,
22
24
  TextToSpeechCommand: TextToSpeechCommand_1.TextToSpeechCommand,
23
25
  };
24
26
  class WilmaVoice extends WilmaVoiceClient_1.WilmaVoiceClient {
@@ -0,0 +1,20 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.StreamCallEventsCommand = exports.$Command = void 0;
4
+ const client_1 = require("@smithy/core/client");
5
+ Object.defineProperty(exports, "$Command", { enumerable: true, get: function () { return client_1.Command; } });
6
+ const endpoints_1 = require("@smithy/core/endpoints");
7
+ const EndpointParameters_1 = require("../endpoint/EndpointParameters");
8
+ const schemas_0_1 = require("../schemas/schemas_0");
9
+ class StreamCallEventsCommand extends client_1.Command
10
+ .classBuilder()
11
+ .ep(EndpointParameters_1.commonParams)
12
+ .m(function (Command, cs, config, o) {
13
+ return [(0, endpoints_1.getEndpointPlugin)(config, Command.getEndpointParameterInstructions())];
14
+ })
15
+ .s("WilmaVoice", "StreamCallEvents", {})
16
+ .n("WilmaVoiceClient", "StreamCallEventsCommand")
17
+ .sc(schemas_0_1.StreamCallEvents$)
18
+ .build() {
19
+ }
20
+ exports.StreamCallEventsCommand = StreamCallEventsCommand;
@@ -8,4 +8,5 @@ tslib_1.__exportStar(require("./SendPlayCommand"), exports);
8
8
  tslib_1.__exportStar(require("./SendSayCommand"), exports);
9
9
  tslib_1.__exportStar(require("./SendStopCommand"), exports);
10
10
  tslib_1.__exportStar(require("./SendTransferCommand"), exports);
11
+ tslib_1.__exportStar(require("./StreamCallEventsCommand"), exports);
11
12
  tslib_1.__exportStar(require("./TextToSpeechCommand"), exports);
@@ -1,11 +1,12 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.VoiceCommandType = exports.VoiceInputMode = exports.VoiceAudioEncoding = exports.VoiceControlAction = exports.VoiceEventType = exports.VoicePronunciationEncoding = void 0;
3
+ exports.VoiceCallEventInclude = exports.VoiceCommandType = exports.VoiceInputMode = exports.VoiceAudioEncoding = exports.VoiceCallToolPhase = exports.VoiceCallEndReason = exports.VoiceControlAction = exports.VoiceEventType = exports.VoicePronunciationEncoding = void 0;
4
4
  exports.VoicePronunciationEncoding = {
5
5
  ALIAS: "alias",
6
6
  IPA: "ipa",
7
7
  };
8
8
  exports.VoiceEventType = {
9
+ AGENT_TRANSCRIPTION: "agentTranscription",
9
10
  AUDIO: "audio",
10
11
  COMPLETE: "complete",
11
12
  CONTROL: "control",
@@ -22,6 +23,17 @@ exports.VoiceControlAction = {
22
23
  END_OF_TURN: "end_of_turn",
23
24
  KEEPALIVE: "keepalive",
24
25
  };
26
+ exports.VoiceCallEndReason = {
27
+ COMPLETE: "complete",
28
+ ERROR: "error",
29
+ HANGUP: "hangup",
30
+ TIMEOUT: "timeout",
31
+ TRANSFER: "transfer",
32
+ };
33
+ exports.VoiceCallToolPhase = {
34
+ FINISHED: "finished",
35
+ STARTED: "started",
36
+ };
25
37
  exports.VoiceAudioEncoding = {
26
38
  ALAW: "alaw",
27
39
  MULAW: "mulaw",
@@ -39,3 +51,7 @@ exports.VoiceCommandType = {
39
51
  STOP: "stop",
40
52
  TRANSFER: "transfer",
41
53
  };
54
+ exports.VoiceCallEventInclude = {
55
+ COMMANDS: "commands",
56
+ TOOLS: "tools",
57
+ };
@@ -53,6 +53,7 @@ const getRuntimeConfig = (config) => {
53
53
  version: "v2",
54
54
  serviceTarget: "WilmaVoice",
55
55
  },
56
+ sdkStreamMixin: config?.sdkStreamMixin ?? serde_1.sdkStreamMixin,
56
57
  urlParser: config?.urlParser ?? protocols_2.parseUrl,
57
58
  utf8Decoder: config?.utf8Decoder ?? serde_1.fromUtf8,
58
59
  utf8Encoder: config?.utf8Encoder ?? serde_1.toUtf8,
@@ -1,11 +1,14 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.TranscriptionWebsocketEvent$ = exports.TranscriptionEvent$ = exports.TextToSpeechOutput$ = exports.TextToSpeechInput$ = exports.StopWebsocketCommand$ = exports.StopCommandData$ = exports.SessionStartedWebsocketEvent$ = exports.SessionStartedEvent$ = exports.SessionEndedWebsocketEvent$ = exports.SessionEndedEvent$ = exports.SendTransferOutput$ = exports.SendTransferInput$ = exports.SendStopOutput$ = exports.SendStopInput$ = exports.SendSayOutput$ = exports.SendSayInput$ = exports.SendPlayOutput$ = exports.SendPlayInput$ = exports.SendHangupOutput$ = exports.SendHangupInput$ = exports.SayWebsocketCommand$ = exports.SayCommandData$ = exports.SayCommandAudioOptions$ = exports.ReplyWebsocketEvent$ = exports.ReplyEvent$ = exports.PlayWebsocketCommand$ = exports.PlayCommandData$ = exports.PlaybackWebsocketEvent$ = exports.PlaybackEvent$ = exports.ListVoicesOutput$ = exports.ListVoicesInput$ = exports.InterruptionWebsocketEvent$ = exports.InterruptionEvent$ = exports.HangupWebsocketCommand$ = exports.HangupCommandData$ = exports.ErrorWebsocketEvent$ = exports.DescribeVoiceProtocolOutput$ = exports.DescribeVoiceProtocolInput$ = exports.ControlWebsocketEvent$ = exports.ControlEvent$ = exports.CompleteWebsocketEvent$ = exports.CompleteEvent$ = exports.AudioWebsocketEvent$ = exports.AudioEvent$ = exports.VoicePronunciation$ = exports.errorTypeRegistries = exports.ValidationException$ = exports.NotFoundException$ = exports.ForbiddenException$ = exports.WilmaVoiceServiceException$ = void 0;
4
- exports.TextToSpeech$ = exports.SendTransfer$ = exports.SendStop$ = exports.SendSay$ = exports.SendPlay$ = exports.SendHangup$ = exports.ListVoices$ = exports.DescribeVoiceProtocol$ = exports.VoiceSpeechPayload$ = exports.VoiceErrorEvent$ = exports.VoiceConnectParams$ = exports.VoiceAudioFormat$ = exports.Voice$ = exports.TransferWebsocketCommand$ = exports.TransferCommandData$ = void 0;
3
+ exports.StreamCallEventsOutput$ = exports.StreamCallEventsInput$ = exports.StopWebsocketCommand$ = exports.StopCommandData$ = exports.SessionStartedWebsocketEvent$ = exports.SessionStartedEvent$ = exports.SessionEndedWebsocketEvent$ = exports.SessionEndedEvent$ = exports.SendTransferOutput$ = exports.SendTransferInput$ = exports.SendStopOutput$ = exports.SendStopInput$ = exports.SendSayOutput$ = exports.SendSayInput$ = exports.SendPlayOutput$ = exports.SendPlayInput$ = exports.SendHangupOutput$ = exports.SendHangupInput$ = exports.SayWebsocketCommand$ = exports.SayCommandData$ = exports.SayCommandAudioOptions$ = exports.ReplyWebsocketEvent$ = exports.ReplyEvent$ = exports.PlayWebsocketCommand$ = exports.PlayCommandData$ = exports.PlaybackWebsocketEvent$ = exports.PlaybackEvent$ = exports.ListVoicesOutput$ = exports.ListVoicesInput$ = exports.InterruptionWebsocketEvent$ = exports.InterruptionEvent$ = exports.HangupWebsocketCommand$ = exports.HangupCommandData$ = exports.ErrorWebsocketEvent$ = exports.DescribeVoiceProtocolOutput$ = exports.DescribeVoiceProtocolInput$ = exports.ControlWebsocketEvent$ = exports.ControlEvent$ = exports.CompleteWebsocketEvent$ = exports.CompleteEvent$ = exports.AudioWebsocketEvent$ = exports.AudioEvent$ = exports.AgentTranscriptionWebsocketEvent$ = exports.AgentTranscriptionEvent$ = exports.VoicePronunciation$ = exports.errorTypeRegistries = exports.ValidationException$ = exports.NotFoundException$ = exports.ForbiddenException$ = exports.WilmaVoiceServiceException$ = void 0;
4
+ exports.TextToSpeech$ = exports.StreamCallEvents$ = exports.SendTransfer$ = exports.SendStop$ = exports.SendSay$ = exports.SendPlay$ = exports.SendHangup$ = exports.ListVoices$ = exports.DescribeVoiceProtocol$ = exports.VoiceCallEvent$ = exports.VoiceSpeechPayload$ = exports.VoiceErrorEvent$ = exports.VoiceConnectParams$ = exports.VoiceCallTranscriptionEvent$ = exports.VoiceCallToolEvent$ = exports.VoiceCallStartedEvent$ = exports.VoiceCallSayEvent$ = exports.VoiceCallReplyEvent$ = exports.VoiceCallPlaybackEvent$ = exports.VoiceCallLanguageEvent$ = exports.VoiceCallInterruptionEvent$ = exports.VoiceCallEndedEvent$ = exports.VoiceCallAgentTranscriptionEvent$ = exports.VoiceAudioFormat$ = exports.Voice$ = exports.TransferWebsocketCommand$ = exports.TransferCommandData$ = exports.TranscriptionWebsocketEvent$ = exports.TranscriptionEvent$ = exports.TextToSpeechOutput$ = exports.TextToSpeechInput$ = void 0;
5
5
  const _AE = "AudioEvent";
6
+ const _ATE = "AgentTranscriptionEvent";
7
+ const _ATWE = "AgentTranscriptionWebsocketEvent";
6
8
  const _AWE = "AudioWebsocketEvent";
7
9
  const _CE = "CompleteEvent";
8
10
  const _CEo = "ControlEvent";
11
+ const _CT = "Content-Type";
9
12
  const _CWE = "CompleteWebsocketEvent";
10
13
  const _CWEo = "ControlWebsocketEvent";
11
14
  const _DVP = "DescribeVoiceProtocol";
@@ -31,6 +34,9 @@ const _RWE = "ReplyWebsocketEvent";
31
34
  const _SCAO = "SayCommandAudioOptions";
32
35
  const _SCD = "SayCommandData";
33
36
  const _SCDt = "StopCommandData";
37
+ const _SCE = "StreamCallEvents";
38
+ const _SCEI = "StreamCallEventsInput";
39
+ const _SCEO = "StreamCallEventsOutput";
34
40
  const _SEE = "SessionEndedEvent";
35
41
  const _SEWE = "SessionEndedWebsocketEvent";
36
42
  const _SH = "SendHangup";
@@ -61,7 +67,19 @@ const _TWC = "TransferWebsocketCommand";
61
67
  const _TWE = "TranscriptionWebsocketEvent";
62
68
  const _V = "Voice";
63
69
  const _VAF = "VoiceAudioFormat";
70
+ const _VCATE = "VoiceCallAgentTranscriptionEvent";
71
+ const _VCE = "VoiceCallEvent";
72
+ const _VCEE = "VoiceCallEndedEvent";
73
+ const _VCESB = "VoiceCallEventStreamBody";
74
+ const _VCIE = "VoiceCallInterruptionEvent";
75
+ const _VCLE = "VoiceCallLanguageEvent";
64
76
  const _VCP = "VoiceConnectParams";
77
+ const _VCPE = "VoiceCallPlaybackEvent";
78
+ const _VCRE = "VoiceCallReplyEvent";
79
+ const _VCSE = "VoiceCallSayEvent";
80
+ const _VCSEo = "VoiceCallStartedEvent";
81
+ const _VCTE = "VoiceCallToolEvent";
82
+ const _VCTEo = "VoiceCallTranscriptionEvent";
65
83
  const _VE = "ValidationException";
66
84
  const _VEE = "VoiceErrorEvent";
67
85
  const _VL = "VoiceList";
@@ -73,6 +91,8 @@ const _aD = "agentDraft";
73
91
  const _aDu = "autoDetect";
74
92
  const _aI = "agentId";
75
93
  const _aN = "agentName";
94
+ const _aT = "agentTranscription";
95
+ const _aTWE = "agentTranscriptionWebsocketEvent";
76
96
  const _aV = "agentVersion";
77
97
  const _aWE = "audioWebsocketEvent";
78
98
  const _ac = "action";
@@ -81,20 +101,23 @@ const _au = "audio";
81
101
  const _bS = "backgroundSound";
82
102
  const _c = "client";
83
103
  const _cC = "callerCompany";
84
- const _cE = "callerEmail";
104
+ const _cE = "callEvent";
105
+ const _cEa = "callerEmail";
85
106
  const _cI = "callId";
86
107
  const _cN = "callerName";
87
108
  const _cNa = "callerNumber";
88
109
  const _cP = "connectParams";
110
+ const _cT = "contentType";
89
111
  const _cWE = "completeWebsocketEvent";
90
112
  const _cWEo = "controlWebsocketEvent";
91
113
  const _ca = "category";
92
114
  const _ch = "channels";
93
- const _co = "command";
115
+ const _co = "confidence";
94
116
  const _cod = "code";
95
- const _com = "complete";
117
+ const _com = "command";
118
+ const _comp = "complete";
119
+ const _compa = "company";
96
120
  const _con = "context";
97
- const _conf = "confidence";
98
121
  const _cr = "credential";
99
122
  const _d = "data";
100
123
  const _dN = "dialedNumber";
@@ -102,14 +125,18 @@ const _e = "error";
102
125
  const _eT = "endTime";
103
126
  const _eWE = "errorWebsocketEvent";
104
127
  const _en = "encoding";
128
+ const _end = "ended";
105
129
  const _eng = "engine";
106
130
  const _ev = "event";
131
+ const _eve = "events";
107
132
  const _ex = "extension";
108
133
  const _f = "final";
109
134
  const _fI = "flowIndex";
135
+ const _fr = "from";
110
136
  const _gI = "groupId";
111
137
  const _h = "http";
112
138
  const _hE = "httpError";
139
+ const _hH = "httpHeader";
113
140
  const _hQ = "httpQuery";
114
141
  const _hWC = "hangupWebsocketCommand";
115
142
  const _i = "id";
@@ -118,6 +145,8 @@ const _iM = "initialMessage";
118
145
  const _iMn = "inputMode";
119
146
  const _iWE = "interruptionWebsocketEvent";
120
147
  const _in = "interruptible";
148
+ const _inc = "include";
149
+ const _int = "interruption";
121
150
  const _l = "language";
122
151
  const _la = "languages";
123
152
  const _m = "message";
@@ -132,28 +161,39 @@ const _pT = "playedText";
132
161
  const _pV = "protocolVersion";
133
162
  const _pWC = "playWebsocketCommand";
134
163
  const _pWE = "playbackWebsocketEvent";
164
+ const _ph = "phase";
165
+ const _pl = "playback";
135
166
  const _pr = "provider";
136
167
  const _pro = "pronunciations";
137
168
  const _r = "reason";
138
169
  const _rI = "replyId";
139
170
  const _rWE = "replyWebsocketEvent";
171
+ const _re = "reply";
140
172
  const _s = "smithy.ts.sdk.synthetic.wildix.wilma.voice";
141
173
  const _sEWE = "sessionEndedWebsocketEvent";
142
174
  const _sI = "streamId";
143
175
  const _sIe = "sessionId";
176
+ const _sM = "startMessage";
144
177
  const _sR = "sampleRate";
145
178
  const _sSWE = "sessionStartedWebsocketEvent";
146
179
  const _sT = "startTime";
147
180
  const _sWC = "sayWebsocketCommand";
148
181
  const _sWCt = "stopWebsocketCommand";
182
+ const _sa = "say";
149
183
  const _se = "seq";
150
184
  const _sp = "speech";
185
+ const _st = "streaming";
186
+ const _sta = "started";
151
187
  const _t = "type";
152
188
  const _tI = "traceId";
189
+ const _tN = "toolName";
153
190
  const _tWC = "transferWebsocketCommand";
154
191
  const _tWE = "transcriptionWebsocketEvent";
155
192
  const _te = "text";
156
193
  const _ti = "time";
194
+ const _to = "to";
195
+ const _too = "tool";
196
+ const _tr = "transcription";
157
197
  const _u = "uri";
158
198
  const _v = "voices";
159
199
  const _va = "variables";
@@ -191,11 +231,22 @@ exports.errorTypeRegistries = [
191
231
  n0_registry,
192
232
  ];
193
233
  var Mp3Audio = [0, n1, _MA, { [_mT]: _a }, 21];
234
+ var VoiceCallEventStreamBody = [0, n1, _VCESB, { [_st]: 1 }, 42];
194
235
  exports.VoicePronunciation$ = [3, n2, _VP,
195
236
  0,
196
237
  [_p, _as, _en],
197
238
  [0, 0, 0], 2
198
239
  ];
240
+ exports.AgentTranscriptionEvent$ = [3, n1, _ATE,
241
+ 0,
242
+ [_t, _i, _te, _ti, _co, _f, _l],
243
+ [0, 0, 0, 1, 1, 2, 0], 4
244
+ ];
245
+ exports.AgentTranscriptionWebsocketEvent$ = [3, n1, _ATWE,
246
+ 0,
247
+ [_t, _ev],
248
+ [0, () => exports.AgentTranscriptionEvent$], 2
249
+ ];
199
250
  exports.AudioEvent$ = [3, n1, _AE,
200
251
  0,
201
252
  [_t, _d, _se],
@@ -233,8 +284,8 @@ exports.DescribeVoiceProtocolInput$ = [3, n1, _DVPI,
233
284
  ];
234
285
  exports.DescribeVoiceProtocolOutput$ = [3, n1, _DVPO,
235
286
  0,
236
- [_cP, _aWE, _tWE, _rWE, _pWE, _iWE, _cWE, _cWEo, _sSWE, _sEWE, _eWE, _sWC, _pWC, _sWCt, _hWC, _tWC],
237
- [() => exports.VoiceConnectParams$, () => exports.AudioWebsocketEvent$, () => exports.TranscriptionWebsocketEvent$, () => exports.ReplyWebsocketEvent$, () => exports.PlaybackWebsocketEvent$, () => exports.InterruptionWebsocketEvent$, () => exports.CompleteWebsocketEvent$, () => exports.ControlWebsocketEvent$, () => exports.SessionStartedWebsocketEvent$, () => exports.SessionEndedWebsocketEvent$, () => exports.ErrorWebsocketEvent$, () => exports.SayWebsocketCommand$, () => exports.PlayWebsocketCommand$, () => exports.StopWebsocketCommand$, () => exports.HangupWebsocketCommand$, () => exports.TransferWebsocketCommand$]
287
+ [_cP, _aWE, _tWE, _aTWE, _rWE, _pWE, _iWE, _cWE, _cWEo, _sSWE, _sEWE, _eWE, _sWC, _pWC, _sWCt, _hWC, _tWC, _cE],
288
+ [() => exports.VoiceConnectParams$, () => exports.AudioWebsocketEvent$, () => exports.TranscriptionWebsocketEvent$, () => exports.AgentTranscriptionWebsocketEvent$, () => exports.ReplyWebsocketEvent$, () => exports.PlaybackWebsocketEvent$, () => exports.InterruptionWebsocketEvent$, () => exports.CompleteWebsocketEvent$, () => exports.ControlWebsocketEvent$, () => exports.SessionStartedWebsocketEvent$, () => exports.SessionEndedWebsocketEvent$, () => exports.ErrorWebsocketEvent$, () => exports.SayWebsocketCommand$, () => exports.PlayWebsocketCommand$, () => exports.StopWebsocketCommand$, () => exports.HangupWebsocketCommand$, () => exports.TransferWebsocketCommand$, () => exports.VoiceCallEvent$]
238
289
  ];
239
290
  exports.ErrorWebsocketEvent$ = [3, n1, _EWE,
240
291
  0,
@@ -248,7 +299,7 @@ exports.HangupCommandData$ = [3, n1, _HCD,
248
299
  ];
249
300
  exports.HangupWebsocketCommand$ = [3, n1, _HWC,
250
301
  0,
251
- [_t, _co],
302
+ [_t, _com],
252
303
  [0, () => exports.HangupCommandData$], 2
253
304
  ];
254
305
  exports.InterruptionEvent$ = [3, n1, _IE,
@@ -273,7 +324,7 @@ exports.ListVoicesOutput$ = [3, n1, _LVO,
273
324
  ];
274
325
  exports.PlaybackEvent$ = [3, n1, _PE,
275
326
  0,
276
- [_t, _rI, _te, _com, _sT, _eT],
327
+ [_t, _rI, _te, _comp, _sT, _eT],
277
328
  [0, 0, 0, 2, 1, 1], 5
278
329
  ];
279
330
  exports.PlaybackWebsocketEvent$ = [3, n1, _PWE,
@@ -288,7 +339,7 @@ exports.PlayCommandData$ = [3, n1, _PCD,
288
339
  ];
289
340
  exports.PlayWebsocketCommand$ = [3, n1, _PWC,
290
341
  0,
291
- [_t, _co],
342
+ [_t, _com],
292
343
  [0, () => exports.PlayCommandData$], 2
293
344
  ];
294
345
  exports.ReplyEvent$ = [3, n1, _RE,
@@ -313,7 +364,7 @@ exports.SayCommandData$ = [3, n1, _SCD,
313
364
  ];
314
365
  exports.SayWebsocketCommand$ = [3, n1, _SWC,
315
366
  0,
316
- [_t, _co],
367
+ [_t, _com],
317
368
  [0, () => exports.SayCommandData$], 2
318
369
  ];
319
370
  exports.SendHangupInput$ = [3, n1, _SHI,
@@ -393,9 +444,19 @@ exports.StopCommandData$ = [3, n1, _SCDt,
393
444
  ];
394
445
  exports.StopWebsocketCommand$ = [3, n1, _SWCt,
395
446
  0,
396
- [_t, _co],
447
+ [_t, _com],
397
448
  [0, () => exports.StopCommandData$], 2
398
449
  ];
450
+ exports.StreamCallEventsInput$ = [3, n1, _SCEI,
451
+ 0,
452
+ [_cI, _compa, _inc],
453
+ [[0, 1], [0, { [_hQ]: _compa }], [64 | 0, { [_hQ]: _inc }]], 1
454
+ ];
455
+ exports.StreamCallEventsOutput$ = [3, n1, _SCEO,
456
+ 0,
457
+ [_eve, _cT],
458
+ [[() => VoiceCallEventStreamBody, 16], [0, { [_hH]: _CT }]], 2
459
+ ];
399
460
  exports.TextToSpeechInput$ = [3, n1, _TTSI,
400
461
  0,
401
462
  [_vo, _l, _te, _pro],
@@ -408,7 +469,7 @@ exports.TextToSpeechOutput$ = [3, n1, _TTSO,
408
469
  ];
409
470
  exports.TranscriptionEvent$ = [3, n1, _TE,
410
471
  0,
411
- [_t, _i, _te, _ti, _conf, _f, _l],
472
+ [_t, _i, _te, _ti, _co, _f, _l],
412
473
  [0, 0, 0, 1, 1, 2, 0], 4
413
474
  ];
414
475
  exports.TranscriptionWebsocketEvent$ = [3, n1, _TWE,
@@ -423,7 +484,7 @@ exports.TransferCommandData$ = [3, n1, _TCD,
423
484
  ];
424
485
  exports.TransferWebsocketCommand$ = [3, n1, _TWC,
425
486
  0,
426
- [_t, _co],
487
+ [_t, _com],
427
488
  [0, () => exports.TransferCommandData$], 2
428
489
  ];
429
490
  exports.Voice$ = [3, n1, _V,
@@ -436,9 +497,59 @@ exports.VoiceAudioFormat$ = [3, n1, _VAF,
436
497
  [_en, _sR, _ch],
437
498
  [0, 1, 1], 2
438
499
  ];
500
+ exports.VoiceCallAgentTranscriptionEvent$ = [3, n1, _VCATE,
501
+ 0,
502
+ [_i, _te, _f, _l, _ti],
503
+ [0, 0, 2, 0, 1], 3
504
+ ];
505
+ exports.VoiceCallEndedEvent$ = [3, n1, _VCEE,
506
+ 0,
507
+ [_sIe, _r],
508
+ [0, 0], 2
509
+ ];
510
+ exports.VoiceCallInterruptionEvent$ = [3, n1, _VCIE,
511
+ 0,
512
+ [_rI, _pT, _oT],
513
+ [0, 0, 0]
514
+ ];
515
+ exports.VoiceCallLanguageEvent$ = [3, n1, _VCLE,
516
+ 0,
517
+ [_to, _r, _fr],
518
+ [0, 0, 0], 2
519
+ ];
520
+ exports.VoiceCallPlaybackEvent$ = [3, n1, _VCPE,
521
+ 0,
522
+ [_rI, _comp],
523
+ [0, 2], 2
524
+ ];
525
+ exports.VoiceCallReplyEvent$ = [3, n1, _VCRE,
526
+ 0,
527
+ [_i, _te, _l],
528
+ [0, 0, 0], 2
529
+ ];
530
+ exports.VoiceCallSayEvent$ = [3, n1, _VCSE,
531
+ 0,
532
+ [_rI, _te, _in],
533
+ [0, 0, 2], 3
534
+ ];
535
+ exports.VoiceCallStartedEvent$ = [3, n1, _VCSEo,
536
+ 0,
537
+ [_sIe, _aI, _tI, _aN, _aV, _aD, _l],
538
+ [0, 0, 0, 0, 1, 2, 0], 2
539
+ ];
540
+ exports.VoiceCallToolEvent$ = [3, n1, _VCTE,
541
+ 0,
542
+ [_cI, _tN, _ph, _sM],
543
+ [0, 0, 0, 0], 3
544
+ ];
545
+ exports.VoiceCallTranscriptionEvent$ = [3, n1, _VCTEo,
546
+ 0,
547
+ [_i, _te, _f, _l, _ti],
548
+ [0, 0, 2, 0, 1], 3
549
+ ];
439
550
  exports.VoiceConnectParams$ = [3, n1, _VCP,
440
551
  0,
441
- [_sIe, _aI, _pV, _aV, _aD, _cI, _fI, _dN, _l, _cN, _cNa, _cE, _cC, _vo, _iM, _va, _iMn, _iA, _oA],
552
+ [_sIe, _aI, _pV, _aV, _aD, _cI, _fI, _dN, _l, _cN, _cNa, _cEa, _cC, _vo, _iM, _va, _iMn, _iA, _oA],
442
553
  [0, 0, 1, 1, 2, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, () => exports.VoiceAudioFormat$, () => exports.VoiceAudioFormat$], 2
443
554
  ];
444
555
  exports.VoiceErrorEvent$ = [3, n1, _VEE,
@@ -455,9 +566,15 @@ var LanguageCodeList = 64 | 0;
455
566
  var VoicePronunciationList = [1, n2, _VPL,
456
567
  0, () => exports.VoicePronunciation$
457
568
  ];
569
+ var VoiceCallEventIncludeList = 64 | 0;
458
570
  var VoiceList = [1, n1, _VL,
459
571
  0, () => exports.Voice$
460
572
  ];
573
+ exports.VoiceCallEvent$ = [4, n1, _VCE,
574
+ 0,
575
+ [_sta, _tr, _aT, _re, _sa, _pl, _int, _l, _too, _end],
576
+ [() => exports.VoiceCallStartedEvent$, () => exports.VoiceCallTranscriptionEvent$, () => exports.VoiceCallAgentTranscriptionEvent$, () => exports.VoiceCallReplyEvent$, () => exports.VoiceCallSayEvent$, () => exports.VoiceCallPlaybackEvent$, () => exports.VoiceCallInterruptionEvent$, () => exports.VoiceCallLanguageEvent$, () => exports.VoiceCallToolEvent$, () => exports.VoiceCallEndedEvent$]
577
+ ];
461
578
  exports.DescribeVoiceProtocol$ = [9, n1, _DVP,
462
579
  { [_h]: ["POST", "/v2/voice/describe", 200] }, () => exports.DescribeVoiceProtocolInput$, () => exports.DescribeVoiceProtocolOutput$
463
580
  ];
@@ -479,6 +596,9 @@ exports.SendStop$ = [9, n1, _SSe,
479
596
  exports.SendTransfer$ = [9, n1, _ST,
480
597
  { [_h]: ["POST", "/v2/voice/sessions/{sessionId}/transfer", 200] }, () => exports.SendTransferInput$, () => exports.SendTransferOutput$
481
598
  ];
599
+ exports.StreamCallEvents$ = [9, n1, _SCE,
600
+ { [_h]: ["GET", "/v2/voice/calls/{callId}/events", 200] }, () => exports.StreamCallEventsInput$, () => exports.StreamCallEventsOutput$
601
+ ];
482
602
  exports.TextToSpeech$ = [9, n1, _TTS,
483
603
  { [_h]: ["POST", "/v2/voice/text-to-speech", 200] }, () => exports.TextToSpeechInput$, () => exports.TextToSpeechOutput$
484
604
  ];
@@ -6,6 +6,7 @@ import { SendPlayCommand } from "./commands/SendPlayCommand";
6
6
  import { SendSayCommand } from "./commands/SendSayCommand";
7
7
  import { SendStopCommand } from "./commands/SendStopCommand";
8
8
  import { SendTransferCommand, } from "./commands/SendTransferCommand";
9
+ import { StreamCallEventsCommand, } from "./commands/StreamCallEventsCommand";
9
10
  import { TextToSpeechCommand, } from "./commands/TextToSpeechCommand";
10
11
  import { WilmaVoiceClient } from "./WilmaVoiceClient";
11
12
  const commands = {
@@ -16,6 +17,7 @@ const commands = {
16
17
  SendSayCommand,
17
18
  SendStopCommand,
18
19
  SendTransferCommand,
20
+ StreamCallEventsCommand,
19
21
  TextToSpeechCommand,
20
22
  };
21
23
  export class WilmaVoice extends WilmaVoiceClient {
@@ -0,0 +1,16 @@
1
+ import { Command as $Command } from "@smithy/core/client";
2
+ import { getEndpointPlugin } from "@smithy/core/endpoints";
3
+ import { commonParams } from "../endpoint/EndpointParameters";
4
+ import { StreamCallEvents$ } from "../schemas/schemas_0";
5
+ export { $Command };
6
+ export class StreamCallEventsCommand extends $Command
7
+ .classBuilder()
8
+ .ep(commonParams)
9
+ .m(function (Command, cs, config, o) {
10
+ return [getEndpointPlugin(config, Command.getEndpointParameterInstructions())];
11
+ })
12
+ .s("WilmaVoice", "StreamCallEvents", {})
13
+ .n("WilmaVoiceClient", "StreamCallEventsCommand")
14
+ .sc(StreamCallEvents$)
15
+ .build() {
16
+ }
@@ -5,4 +5,5 @@ export * from "./SendPlayCommand";
5
5
  export * from "./SendSayCommand";
6
6
  export * from "./SendStopCommand";
7
7
  export * from "./SendTransferCommand";
8
+ export * from "./StreamCallEventsCommand";
8
9
  export * from "./TextToSpeechCommand";
@@ -3,6 +3,7 @@ export const VoicePronunciationEncoding = {
3
3
  IPA: "ipa",
4
4
  };
5
5
  export const VoiceEventType = {
6
+ AGENT_TRANSCRIPTION: "agentTranscription",
6
7
  AUDIO: "audio",
7
8
  COMPLETE: "complete",
8
9
  CONTROL: "control",
@@ -19,6 +20,17 @@ export const VoiceControlAction = {
19
20
  END_OF_TURN: "end_of_turn",
20
21
  KEEPALIVE: "keepalive",
21
22
  };
23
+ export const VoiceCallEndReason = {
24
+ COMPLETE: "complete",
25
+ ERROR: "error",
26
+ HANGUP: "hangup",
27
+ TIMEOUT: "timeout",
28
+ TRANSFER: "transfer",
29
+ };
30
+ export const VoiceCallToolPhase = {
31
+ FINISHED: "finished",
32
+ STARTED: "started",
33
+ };
22
34
  export const VoiceAudioEncoding = {
23
35
  ALAW: "alaw",
24
36
  MULAW: "mulaw",
@@ -36,3 +48,7 @@ export const VoiceCommandType = {
36
48
  STOP: "stop",
37
49
  TRANSFER: "transfer",
38
50
  };
51
+ export const VoiceCallEventInclude = {
52
+ COMMANDS: "commands",
53
+ TOOLS: "tools",
54
+ };
@@ -2,7 +2,7 @@ import { AwsRestJsonProtocol } from "@aws-sdk/core/protocols";
2
2
  import { HttpBearerAuthSigner } from "@smithy/core";
3
3
  import { NoOpLogger } from "@smithy/core/client";
4
4
  import { parseUrl } from "@smithy/core/protocols";
5
- import { fromBase64, fromUtf8, toBase64, toUtf8 } from "@smithy/core/serde";
5
+ import { fromBase64, fromUtf8, sdkStreamMixin, toBase64, toUtf8 } from "@smithy/core/serde";
6
6
  import { defaultWilmaVoiceHttpAuthSchemeProvider } from "./auth/httpAuthSchemeProvider";
7
7
  import { defaultEndpointResolver } from "./endpoint/endpointResolver";
8
8
  import { errorTypeRegistries } from "./schemas/schemas_0";
@@ -50,6 +50,7 @@ export const getRuntimeConfig = (config) => {
50
50
  version: "v2",
51
51
  serviceTarget: "WilmaVoice",
52
52
  },
53
+ sdkStreamMixin: config?.sdkStreamMixin ?? sdkStreamMixin,
53
54
  urlParser: config?.urlParser ?? parseUrl,
54
55
  utf8Decoder: config?.utf8Decoder ?? fromUtf8,
55
56
  utf8Encoder: config?.utf8Encoder ?? toUtf8,