@wildix/wilma-voice-client 0.0.50 → 0.0.52

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.
@@ -73,12 +73,11 @@ export interface WilmaVoice {
73
73
  * (engine, instructions, capabilities and channels.voice settings). This is a runtime only: there
74
74
  * is no agent/bot CRUD here — agents are authored and versioned in wilma-agents.
75
75
  *
76
- * On the WebSocket (transport host `wilma-voice-ws.wildix.com`), PBX clients transcribe caller
77
- * speech themselves and send `transcription` / `reply` text, while web/app clients connect with
78
- * inputMode=AUDIO and push raw caller `audio` chunks that the service transcribes server-side;
79
- * the service returns `say` / `play` / `stop` / `hangup` / `transfer`. On the PBX media socket
80
- * (`/v2/voice/media/ws`, subprotocol `wilma-media-v2`), the PBX sends raw caller audio and the
81
- * service answers with audio and the text frames listed under DescribeVoiceProtocol `media`.
76
+ * On the WebSocket (transport host `wilma-voice-ws.wildix.com`), the PBX transcribes caller
77
+ * speech itself and sends `transcription` / `reply` text; the service returns `say` / `play` /
78
+ * `stop` / `hangup` / `transfer`. On the call socket
79
+ * (`/v2/voice/calls/ws`), the PBX sends raw caller audio and the
80
+ * service answers with audio and the text frames listed under DescribeVoiceProtocol `callSocket`.
82
81
  * Every WebSocket message shape (connect params, events and commands) is declared as a structure
83
82
  * and enumerated by DescribeVoiceProtocol so the generated SDKs carry the types and
84
83
  * (de)serializers; the WebSocket transport itself is hand-coded. The HTTP Send* operations push
@@ -164,12 +164,11 @@ export interface WilmaVoiceClientResolvedConfig extends WilmaVoiceClientResolved
164
164
  * (engine, instructions, capabilities and channels.voice settings). This is a runtime only: there
165
165
  * is no agent/bot CRUD here — agents are authored and versioned in wilma-agents.
166
166
  *
167
- * On the WebSocket (transport host `wilma-voice-ws.wildix.com`), PBX clients transcribe caller
168
- * speech themselves and send `transcription` / `reply` text, while web/app clients connect with
169
- * inputMode=AUDIO and push raw caller `audio` chunks that the service transcribes server-side;
170
- * the service returns `say` / `play` / `stop` / `hangup` / `transfer`. On the PBX media socket
171
- * (`/v2/voice/media/ws`, subprotocol `wilma-media-v2`), the PBX sends raw caller audio and the
172
- * service answers with audio and the text frames listed under DescribeVoiceProtocol `media`.
167
+ * On the WebSocket (transport host `wilma-voice-ws.wildix.com`), the PBX transcribes caller
168
+ * speech itself and sends `transcription` / `reply` text; the service returns `say` / `play` /
169
+ * `stop` / `hangup` / `transfer`. On the call socket
170
+ * (`/v2/voice/calls/ws`), the PBX sends raw caller audio and the
171
+ * service answers with audio and the text frames listed under DescribeVoiceProtocol `callSocket`.
173
172
  * Every WebSocket message shape (connect params, events and commands) is declared as a structure
174
173
  * and enumerated by DescribeVoiceProtocol so the generated SDKs carry the types and
175
174
  * (de)serializers; the WebSocket transport itself is hand-coded. The HTTP Send* operations push
@@ -27,7 +27,7 @@ declare const DescribeVoiceProtocolCommand_base: {
27
27
  getEndpointParameterInstructions(): import("@smithy/types").EndpointParameterInstructions;
28
28
  };
29
29
  /**
30
- * Describes the WebSocket connect parameters, events and commands of the voice protocol, and the messages of the PBX media socket. Utility method; the generated shapes are the source of truth for building a WebSocket client or server by hand.
30
+ * Describes the WebSocket connect parameters, events and commands of the voice protocol, and the messages of the call socket. Utility method; the generated shapes are the source of truth for building a WebSocket client or server by hand.
31
31
  * @example
32
32
  * Use a bare-bones client and the command you need to make an API call.
33
33
  * ```javascript
@@ -43,6 +43,7 @@ declare const DescribeVoiceProtocolCommand_base: {
43
43
  * // connectParams: { // VoiceConnectParams
44
44
  * // protocolVersion: Number("int"),
45
45
  * // sessionId: "STRING_VALUE", // required
46
+ * // resume: true || false,
46
47
  * // agentId: "STRING_VALUE", // required
47
48
  * // agentVersion: Number("int"),
48
49
  * // agentDraft: true || false,
@@ -57,191 +58,120 @@ declare const DescribeVoiceProtocolCommand_base: {
57
58
  * // voice: "STRING_VALUE",
58
59
  * // initialMessage: "STRING_VALUE",
59
60
  * // variables: "STRING_VALUE",
60
- * // inputMode: "transcription" || "audio",
61
- * // inputAudio: { // VoiceAudioFormat
62
- * // encoding: "pcm_s16le" || "mulaw" || "alaw" || "opus", // required
63
- * // sampleRate: Number("int"), // required
64
- * // channels: Number("int"),
65
- * // },
66
- * // outputAudio: {
67
- * // encoding: "pcm_s16le" || "mulaw" || "alaw" || "opus", // required
68
- * // sampleRate: Number("int"), // required
69
- * // channels: Number("int"),
70
- * // },
61
+ * // inputMode: "transcription",
62
+ * // user: "STRING_VALUE",
63
+ * // company: "STRING_VALUE",
71
64
  * // },
72
- * // audioWebsocketEvent: { // AudioWebsocketEvent
65
+ * // healthcheckWebsocketFrame: { // VoiceHealthcheckWebsocketFrame
73
66
  * // type: "STRING_VALUE", // required
74
- * // event: { // AudioEvent
75
- * // type: "started" || "ended" || "error" || "audio" || "transcription" || "agentTranscription" || "reply" || "playback" || "interruption" || "complete" || "control", // required
76
- * // data: "STRING_VALUE", // required
77
- * // seq: Number("int"),
78
- * // },
79
67
  * // },
80
- * // transcriptionWebsocketEvent: { // TranscriptionWebsocketEvent
81
- * // type: "STRING_VALUE", // required
82
- * // event: { // TranscriptionEvent
83
- * // type: "started" || "ended" || "error" || "audio" || "transcription" || "agentTranscription" || "reply" || "playback" || "interruption" || "complete" || "control", // required
84
- * // id: "STRING_VALUE", // required
85
- * // text: "STRING_VALUE", // required
86
- * // confidence: Number("double"),
87
- * // final: true || false,
88
- * // language: "STRING_VALUE",
89
- * // time: Number("long"), // required
90
- * // },
68
+ * // transcriptionEvent: { // VoiceTranscriptionEvent
69
+ * // type: "started" || "ended" || "error" || "transcription" || "agentTranscription" || "reply" || "playback" || "interruption" || "complete" || "thinking" || "tool", // required
70
+ * // id: "STRING_VALUE",
71
+ * // text: "STRING_VALUE", // required
72
+ * // confidence: Number("double"),
73
+ * // final: true || false,
74
+ * // language: "STRING_VALUE",
75
+ * // time: Number("long"),
91
76
  * // },
92
- * // agentTranscriptionWebsocketEvent: { // AgentTranscriptionWebsocketEvent
93
- * // type: "STRING_VALUE", // required
94
- * // event: { // AgentTranscriptionEvent
95
- * // type: "started" || "ended" || "error" || "audio" || "transcription" || "agentTranscription" || "reply" || "playback" || "interruption" || "complete" || "control", // required
96
- * // id: "STRING_VALUE", // required
97
- * // text: "STRING_VALUE", // required
98
- * // confidence: Number("double"),
99
- * // final: true || false,
100
- * // language: "STRING_VALUE",
101
- * // time: Number("long"), // required
102
- * // },
77
+ * // agentTranscriptionEvent: { // VoiceAgentTranscriptionEvent
78
+ * // type: "started" || "ended" || "error" || "transcription" || "agentTranscription" || "reply" || "playback" || "interruption" || "complete" || "thinking" || "tool", // required
79
+ * // id: "STRING_VALUE",
80
+ * // text: "STRING_VALUE", // required
81
+ * // confidence: Number("double"),
82
+ * // final: true || false,
83
+ * // language: "STRING_VALUE",
84
+ * // time: Number("long"),
103
85
  * // },
104
- * // replyWebsocketEvent: { // ReplyWebsocketEvent
105
- * // type: "STRING_VALUE", // required
106
- * // event: { // ReplyEvent
107
- * // type: "started" || "ended" || "error" || "audio" || "transcription" || "agentTranscription" || "reply" || "playback" || "interruption" || "complete" || "control", // required
108
- * // id: "STRING_VALUE", // required
109
- * // text: "STRING_VALUE", // required
110
- * // language: "STRING_VALUE",
111
- * // startTime: Number("long"), // required
112
- * // endTime: Number("long"), // required
113
- * // },
86
+ * // replyEvent: { // VoiceReplyEvent
87
+ * // type: "started" || "ended" || "error" || "transcription" || "agentTranscription" || "reply" || "playback" || "interruption" || "complete" || "thinking" || "tool", // required
88
+ * // id: "STRING_VALUE",
89
+ * // text: "STRING_VALUE", // required
90
+ * // time: Number("long"),
91
+ * // language: "STRING_VALUE",
92
+ * // confidence: Number("double"),
93
+ * // startTime: Number("long"),
94
+ * // endTime: Number("long"),
114
95
  * // },
115
- * // playbackWebsocketEvent: { // PlaybackWebsocketEvent
116
- * // type: "STRING_VALUE", // required
117
- * // event: { // PlaybackEvent
118
- * // type: "started" || "ended" || "error" || "audio" || "transcription" || "agentTranscription" || "reply" || "playback" || "interruption" || "complete" || "control", // required
119
- * // replyId: "STRING_VALUE", // required
120
- * // text: "STRING_VALUE", // required
121
- * // complete: true || false, // required
122
- * // startTime: Number("long"), // required
123
- * // endTime: Number("long"),
124
- * // },
96
+ * // playbackEvent: { // VoicePlaybackEvent
97
+ * // type: "started" || "ended" || "error" || "transcription" || "agentTranscription" || "reply" || "playback" || "interruption" || "complete" || "thinking" || "tool", // required
98
+ * // replyId: "STRING_VALUE",
99
+ * // text: "STRING_VALUE",
100
+ * // complete: true || false, // required
101
+ * // startTime: Number("long"),
102
+ * // endTime: Number("long"),
125
103
  * // },
126
- * // interruptionWebsocketEvent: { // InterruptionWebsocketEvent
127
- * // type: "STRING_VALUE", // required
128
- * // event: { // InterruptionEvent
129
- * // type: "started" || "ended" || "error" || "audio" || "transcription" || "agentTranscription" || "reply" || "playback" || "interruption" || "complete" || "control", // required
130
- * // replyId: "STRING_VALUE", // required
131
- * // playedText: "STRING_VALUE", // required
132
- * // originalText: "STRING_VALUE", // required
133
- * // time: Number("long"), // required
134
- * // },
135
- * // },
136
- * // completeWebsocketEvent: { // CompleteWebsocketEvent
137
- * // type: "STRING_VALUE", // required
138
- * // event: { // CompleteEvent
139
- * // type: "started" || "ended" || "error" || "audio" || "transcription" || "agentTranscription" || "reply" || "playback" || "interruption" || "complete" || "control", // required
140
- * // reason: "STRING_VALUE", // required
141
- * // time: Number("long"), // required
142
- * // },
104
+ * // interruptionEvent: { // VoiceInterruptionEvent
105
+ * // type: "started" || "ended" || "error" || "transcription" || "agentTranscription" || "reply" || "playback" || "interruption" || "complete" || "thinking" || "tool", // required
106
+ * // replyId: "STRING_VALUE",
107
+ * // playedText: "STRING_VALUE",
108
+ * // originalText: "STRING_VALUE",
109
+ * // time: Number("long"),
143
110
  * // },
144
- * // controlWebsocketEvent: { // ControlWebsocketEvent
145
- * // type: "STRING_VALUE", // required
146
- * // event: { // ControlEvent
147
- * // type: "started" || "ended" || "error" || "audio" || "transcription" || "agentTranscription" || "reply" || "playback" || "interruption" || "complete" || "control", // required
148
- * // action: "end_of_turn" || "clear" || "keepalive", // required
149
- * // },
111
+ * // completeEvent: { // VoiceCompleteEvent
112
+ * // type: "started" || "ended" || "error" || "transcription" || "agentTranscription" || "reply" || "playback" || "interruption" || "complete" || "thinking" || "tool", // required
113
+ * // reason: "STRING_VALUE",
114
+ * // time: Number("long"),
150
115
  * // },
151
- * // sessionStartedWebsocketEvent: { // SessionStartedWebsocketEvent
152
- * // type: "STRING_VALUE", // required
153
- * // event: { // SessionStartedEvent
154
- * // type: "started" || "ended" || "error" || "audio" || "transcription" || "agentTranscription" || "reply" || "playback" || "interruption" || "complete" || "control", // required
155
- * // time: Number("long"), // required
156
- * // sessionId: "STRING_VALUE", // required
157
- * // agentId: "STRING_VALUE", // required
158
- * // agentVersion: Number("int"),
159
- * // traceId: "STRING_VALUE",
160
- * // agentName: "STRING_VALUE",
161
- * // category: "STRING_VALUE",
162
- * // groupId: "STRING_VALUE",
163
- * // speech: { // VoiceSpeechPayload
164
- * // engine: "STRING_VALUE", // required
165
- * // languages: [ // LanguageCodeList // required
166
- * // "STRING_VALUE",
167
- * // ],
168
- * // preferredLanguage: "STRING_VALUE", // required
169
- * // autoDetect: true || false, // required
170
- * // },
171
- * // backgroundSound: "STRING_VALUE",
172
- * // inputAudio: {
173
- * // encoding: "pcm_s16le" || "mulaw" || "alaw" || "opus", // required
174
- * // sampleRate: Number("int"), // required
175
- * // channels: Number("int"),
176
- * // },
177
- * // outputAudio: {
178
- * // encoding: "pcm_s16le" || "mulaw" || "alaw" || "opus", // required
179
- * // sampleRate: Number("int"), // required
180
- * // channels: Number("int"),
181
- * // },
116
+ * // sessionStartedEvent: { // VoiceSessionStartedEvent
117
+ * // type: "started" || "ended" || "error" || "transcription" || "agentTranscription" || "reply" || "playback" || "interruption" || "complete" || "thinking" || "tool", // required
118
+ * // time: Number("long"), // required
119
+ * // sessionId: "STRING_VALUE", // required
120
+ * // agentId: "STRING_VALUE", // required
121
+ * // agentVersion: Number("int"),
122
+ * // traceId: "STRING_VALUE",
123
+ * // agentName: "STRING_VALUE",
124
+ * // category: "STRING_VALUE",
125
+ * // groupId: "STRING_VALUE",
126
+ * // speech: { // VoiceSpeechPayload
127
+ * // engine: "STRING_VALUE", // required
128
+ * // languages: [ // LanguageCodeList // required
129
+ * // "STRING_VALUE",
130
+ * // ],
131
+ * // preferredLanguage: "STRING_VALUE", // required
132
+ * // autoDetect: true || false, // required
182
133
  * // },
134
+ * // backgroundSound: "STRING_VALUE",
183
135
  * // },
184
- * // sessionEndedWebsocketEvent: { // SessionEndedWebsocketEvent
185
- * // type: "STRING_VALUE", // required
186
- * // event: { // SessionEndedEvent
187
- * // type: "started" || "ended" || "error" || "audio" || "transcription" || "agentTranscription" || "reply" || "playback" || "interruption" || "complete" || "control", // required
188
- * // reason: "STRING_VALUE",
189
- * // error: "STRING_VALUE",
190
- * // time: Number("long"), // required
191
- * // },
136
+ * // sessionEndedEvent: { // VoiceSessionEndedEvent
137
+ * // type: "started" || "ended" || "error" || "transcription" || "agentTranscription" || "reply" || "playback" || "interruption" || "complete" || "thinking" || "tool", // required
138
+ * // reason: "STRING_VALUE",
139
+ * // error: "STRING_VALUE",
140
+ * // time: Number("long"), // required
192
141
  * // },
193
- * // errorWebsocketEvent: { // ErrorWebsocketEvent
194
- * // type: "STRING_VALUE", // required
195
- * // event: { // VoiceErrorEvent
196
- * // type: "started" || "ended" || "error" || "audio" || "transcription" || "agentTranscription" || "reply" || "playback" || "interruption" || "complete" || "control", // required
197
- * // code: "STRING_VALUE", // required
198
- * // message: "STRING_VALUE", // required
199
- * // time: Number("long"), // required
200
- * // },
142
+ * // errorEvent: { // VoiceErrorEvent
143
+ * // type: "started" || "ended" || "error" || "transcription" || "agentTranscription" || "reply" || "playback" || "interruption" || "complete" || "thinking" || "tool", // required
144
+ * // code: "STRING_VALUE", // required
145
+ * // message: "STRING_VALUE", // required
146
+ * // time: Number("long"), // required
201
147
  * // },
202
- * // sayWebsocketCommand: { // SayWebsocketCommand
203
- * // type: "STRING_VALUE", // required
204
- * // command: { // SayCommandData
205
- * // text: "STRING_VALUE", // required
206
- * // replyId: "STRING_VALUE", // required
207
- * // interruptible: true || false,
208
- * // voice: "STRING_VALUE",
209
- * // audio: { // SayCommandAudioOptions
210
- * // streamId: "STRING_VALUE", // required
211
- * // sampleRate: Number("int"), // required
212
- * // },
213
- * // type: "say" || "play" || "stop" || "hangup" || "transfer", // required
214
- * // },
215
- * // },
216
- * // playWebsocketCommand: { // PlayWebsocketCommand
217
- * // type: "STRING_VALUE", // required
218
- * // command: { // PlayCommandData
219
- * // replyId: "STRING_VALUE", // required
148
+ * // sayCommand: { // VoiceSayCommandData
149
+ * // text: "STRING_VALUE", // required
150
+ * // replyId: "STRING_VALUE", // required
151
+ * // interruptible: true || false,
152
+ * // audio: { // VoiceSayCommandAudioOptions
220
153
  * // streamId: "STRING_VALUE", // required
221
- * // data: "STRING_VALUE", // required
222
- * // type: "say" || "play" || "stop" || "hangup" || "transfer", // required
154
+ * // sampleRate: Number("int"), // required
223
155
  * // },
156
+ * // type: "say" || "play" || "stop" || "hangup" || "transfer", // required
224
157
  * // },
225
- * // stopWebsocketCommand: { // StopWebsocketCommand
226
- * // type: "STRING_VALUE", // required
227
- * // command: { // StopCommandData
228
- * // type: "say" || "play" || "stop" || "hangup" || "transfer", // required
229
- * // },
158
+ * // playCommand: { // VoicePlayCommandData
159
+ * // replyId: "STRING_VALUE", // required
160
+ * // streamId: "STRING_VALUE", // required
161
+ * // data: "STRING_VALUE", // required
162
+ * // type: "say" || "play" || "stop" || "hangup" || "transfer", // required
230
163
  * // },
231
- * // hangupWebsocketCommand: { // HangupWebsocketCommand
232
- * // type: "STRING_VALUE", // required
233
- * // command: { // HangupCommandData
234
- * // reason: "STRING_VALUE",
235
- * // type: "say" || "play" || "stop" || "hangup" || "transfer", // required
236
- * // },
164
+ * // stopCommand: { // VoiceStopCommandData
165
+ * // type: "say" || "play" || "stop" || "hangup" || "transfer", // required
237
166
  * // },
238
- * // transferWebsocketCommand: { // TransferWebsocketCommand
239
- * // type: "STRING_VALUE", // required
240
- * // command: { // TransferCommandData
241
- * // context: "STRING_VALUE", // required
242
- * // extension: "STRING_VALUE", // required
243
- * // type: "say" || "play" || "stop" || "hangup" || "transfer", // required
244
- * // },
167
+ * // hangupCommand: { // VoiceHangupCommandData
168
+ * // reason: "STRING_VALUE",
169
+ * // type: "say" || "play" || "stop" || "hangup" || "transfer", // required
170
+ * // },
171
+ * // transferCommand: { // VoiceTransferCommandData
172
+ * // context: "STRING_VALUE", // required
173
+ * // extension: "STRING_VALUE", // required
174
+ * // type: "say" || "play" || "stop" || "hangup" || "transfer", // required
245
175
  * // },
246
176
  * // callEvent: { // VoiceCallEvent Union: only one key present
247
177
  * // started: { // VoiceCallStartedEvent
@@ -259,7 +189,7 @@ declare const DescribeVoiceProtocolCommand_base: {
259
189
  * // final: true || false, // required
260
190
  * // language: "STRING_VALUE",
261
191
  * // time: Number("long"),
262
- * // dropped: "low_confidence" || "other_speaker",
192
+ * // finalDropReason: "low_confidence" || "other_speaker",
263
193
  * // },
264
194
  * // agentTranscription: { // VoiceCallAgentTranscriptionEvent
265
195
  * // id: "STRING_VALUE", // required
@@ -303,140 +233,116 @@ declare const DescribeVoiceProtocolCommand_base: {
303
233
  * // reason: "hangup" || "transfer" || "timeout" || "error" || "complete", // required
304
234
  * // },
305
235
  * // },
306
- * // media: { // MediaProtocolFrames
307
- * // pbx: { // MediaPbxFrames
308
- * // start: { // MediaStartFrame
309
- * // type: "start", // required
310
- * // purpose: "agent" || "transcription", // required
311
- * // callId: "STRING_VALUE", // required
312
- * // flowIndex: Number("int"), // required
313
- * // sessionId: "STRING_VALUE", // required
314
- * // resume: true || false, // required
315
- * // resumeAtMs: Number("int"), // required
316
- * // audio: { // MediaAudioFormat
317
- * // encoding: "pcm_s16le", // required
318
- * // sampleRate: Number("int"), // required
319
- * // channels: Number("int"), // required
320
- * // },
321
- * // agent: { // MediaStartAgent
322
- * // id: "STRING_VALUE", // required
323
- * // draft: true || false,
324
- * // version: Number("int"),
325
- * // },
326
- * // languages: [ // MediaStartLanguageList
327
- * // "STRING_VALUE",
328
- * // ],
329
- * // preferredLanguage: "STRING_VALUE",
330
- * // autoDetect: true || false,
331
- * // caller: { // MediaStartCaller
332
- * // name: "STRING_VALUE",
333
- * // number: "STRING_VALUE",
334
- * // email: "STRING_VALUE",
335
- * // company: "STRING_VALUE",
336
- * // },
337
- * // dialedNumber: "STRING_VALUE",
338
- * // variables: "STRING_VALUE",
339
- * // },
340
- * // audio: new Uint8Array(),
341
- * // vad: { // MediaVadFrame
342
- * // type: "vad", // required
343
- * // party: "caller" || "callee", // required
344
- * // speaking: true || false, // required
345
- * // energyDb: Number("double"), // required
346
- * // atMs: Number("int"), // required
347
- * // },
348
- * // dtmf: { // MediaDtmfFrame
349
- * // type: "dtmf", // required
236
+ * // callSocket: { // VoiceCallProtocolFrames
237
+ * // start: { // VoiceCallStartFrame
238
+ * // type: "start" || "vad" || "dtmf" || "playback" || "end", // required
239
+ * // callId: "STRING_VALUE", // required
240
+ * // flowIndex: Number("int"), // required
241
+ * // sessionId: "STRING_VALUE", // required
242
+ * // resume: true || false, // required
243
+ * // resumeAtMs: Number("int"), // required
244
+ * // agent: { // VoiceCallStartAgent
350
245
  * // id: "STRING_VALUE", // required
351
- * // digits: "STRING_VALUE", // required
352
- * // },
353
- * // playback: { // MediaPlaybackFrame
354
- * // type: "playback", // required
355
- * // replyId: "STRING_VALUE", // required
356
- * // streamId: "STRING_VALUE", // required
357
- * // event: "started" || "finished" || "stopped", // required
358
- * // atMs: Number("int"), // required
359
- * // playedMs: Number("int"),
360
- * // cause: "cloud" || "caller" || "drop",
246
+ * // draft: true || false,
247
+ * // version: Number("int"),
361
248
  * // },
362
- * // finish: { // MediaFinishFrame
363
- * // type: "finish", // required
364
- * // reason: "caller-hangup" || "callee-hangup" || "agent-hangup" || "agent-transfer" || "timeout", // required
249
+ * // language: "STRING_VALUE", // required
250
+ * // caller: { // VoiceCallStartCaller
251
+ * // name: "STRING_VALUE",
252
+ * // number: "STRING_VALUE",
253
+ * // email: "STRING_VALUE",
254
+ * // company: "STRING_VALUE",
365
255
  * // },
256
+ * // dialedNumber: "STRING_VALUE",
257
+ * // variables: "STRING_VALUE",
366
258
  * // },
367
- * // cloud: { // MediaCloudFrames
368
- * // started: { // MediaStartedFrame
369
- * // type: "started", // required
370
- * // streamId: "STRING_VALUE", // required
371
- * // agent: { // MediaStartedAgent
372
- * // name: "STRING_VALUE", // required
373
- * // },
374
- * // groupId: "STRING_VALUE",
375
- * // backgroundSound: "STRING_VALUE",
376
- * // voiceDetection: { // MediaVoiceDetection
377
- * // silenceMs: Number("int"), // required
378
- * // silenceLevelDb: Number("int"), // required
379
- * // speechLevelDb: Number("int"), // required
380
- * // },
381
- * // },
382
- * // transcription: { // MediaTranscriptionFrame
383
- * // type: "transcription", // required
384
- * // party: "caller" || "callee", // required
385
- * // id: "STRING_VALUE", // required
386
- * // final: true || false, // required
387
- * // text: "STRING_VALUE", // required
388
- * // startMs: Number("int"), // required
389
- * // endMs: Number("int"), // required
390
- * // language: "STRING_VALUE", // required
391
- * // confidence: Number("double"),
392
- * // },
393
- * // audioBegin: { // MediaAudioBeginFrame
394
- * // type: "audio.begin", // required
395
- * // replyId: "STRING_VALUE", // required
396
- * // streamId: "STRING_VALUE", // required
397
- * // sampleRate: Number("int"), // required
398
- * // },
399
- * // audio: new Uint8Array(),
400
- * // audioEnd: { // MediaAudioEndFrame
401
- * // type: "audio.end", // required
402
- * // streamId: "STRING_VALUE", // required
403
- * // },
404
- * // stop: { // MediaStopFrame
405
- * // type: "stop", // required
406
- * // },
407
- * // duck: { // MediaDuckFrame
408
- * // type: "duck", // required
409
- * // replyId: "STRING_VALUE", // required
410
- * // volumeDb: Number("int"), // required
411
- * // rampMs: Number("int"), // required
412
- * // },
413
- * // restore: { // MediaRestoreFrame
414
- * // type: "restore", // required
415
- * // replyId: "STRING_VALUE", // required
416
- * // rampMs: Number("int"), // required
417
- * // },
418
- * // language: { // MediaLanguageFrame
419
- * // type: "language", // required
420
- * // language: "STRING_VALUE", // required
421
- * // },
422
- * // transfer: { // MediaTransferFrame
423
- * // type: "transfer", // required
424
- * // context: "STRING_VALUE", // required
425
- * // extension: "STRING_VALUE", // required
426
- * // },
427
- * // hangup: { // MediaHangupFrame
428
- * // type: "hangup", // required
429
- * // },
430
- * // error: { // MediaErrorFrame
431
- * // type: "error", // required
432
- * // code: "STRING_VALUE", // required
433
- * // retryable: true || false, // required
434
- * // message: "STRING_VALUE", // required
435
- * // },
436
- * // finished: { // MediaFinishedFrame
437
- * // type: "finished", // required
259
+ * // vad: { // VoiceCallVadFrame
260
+ * // type: "start" || "vad" || "dtmf" || "playback" || "end", // required
261
+ * // speaking: true || false, // required
262
+ * // energyDb: Number("double"), // required
263
+ * // atMs: Number("int"), // required
264
+ * // },
265
+ * // dtmf: { // VoiceCallDtmfFrame
266
+ * // type: "start" || "vad" || "dtmf" || "playback" || "end", // required
267
+ * // id: "STRING_VALUE", // required
268
+ * // digits: "STRING_VALUE", // required
269
+ * // },
270
+ * // playback: { // VoiceCallPlaybackFrame
271
+ * // type: "start" || "vad" || "dtmf" || "playback" || "end", // required
272
+ * // replyId: "STRING_VALUE", // required
273
+ * // streamId: "STRING_VALUE", // required
274
+ * // event: "started" || "finished" || "stopped", // required
275
+ * // atMs: Number("int"), // required
276
+ * // playedMs: Number("int"),
277
+ * // dropped: true || false,
278
+ * // },
279
+ * // end: { // VoiceCallEndFrame
280
+ * // type: "start" || "vad" || "dtmf" || "playback" || "end", // required
281
+ * // reason: "caller-hangup" || "agent-hangup" || "agent-transfer" || "timeout", // required
282
+ * // },
283
+ * // started: { // VoiceCallStartedFrame
284
+ * // type: "started" || "transcription" || "audio.begin" || "audio.end" || "stop" || "duck" || "language" || "transfer" || "hangup" || "error" || "ended", // required
285
+ * // connectionId: "STRING_VALUE", // required
286
+ * // agentName: "STRING_VALUE", // required
287
+ * // groupId: "STRING_VALUE",
288
+ * // backgroundSound: "STRING_VALUE",
289
+ * // voiceDetection: { // VoiceDetectionSettings
290
+ * // silenceMs: Number("int"),
291
+ * // silenceLevelDb: Number("int"),
292
+ * // speechLevelDb: Number("int"),
438
293
  * // },
439
294
  * // },
295
+ * // transcription: { // VoiceCallTranscriptionFrame
296
+ * // type: "started" || "transcription" || "audio.begin" || "audio.end" || "stop" || "duck" || "language" || "transfer" || "hangup" || "error" || "ended", // required
297
+ * // party: "caller" || "callee", // required
298
+ * // id: "STRING_VALUE", // required
299
+ * // final: true || false, // required
300
+ * // text: "STRING_VALUE", // required
301
+ * // startMs: Number("int"), // required
302
+ * // endMs: Number("int"), // required
303
+ * // language: "STRING_VALUE", // required
304
+ * // confidence: Number("double"),
305
+ * // },
306
+ * // audioBegin: { // VoiceCallAudioBeginFrame
307
+ * // type: "started" || "transcription" || "audio.begin" || "audio.end" || "stop" || "duck" || "language" || "transfer" || "hangup" || "error" || "ended", // required
308
+ * // replyId: "STRING_VALUE", // required
309
+ * // streamId: "STRING_VALUE", // required
310
+ * // sampleRate: Number("int"), // required
311
+ * // },
312
+ * // audioEnd: { // VoiceCallAudioEndFrame
313
+ * // type: "started" || "transcription" || "audio.begin" || "audio.end" || "stop" || "duck" || "language" || "transfer" || "hangup" || "error" || "ended", // required
314
+ * // streamId: "STRING_VALUE", // required
315
+ * // },
316
+ * // stop: { // VoiceCallStopFrame
317
+ * // type: "started" || "transcription" || "audio.begin" || "audio.end" || "stop" || "duck" || "language" || "transfer" || "hangup" || "error" || "ended", // required
318
+ * // },
319
+ * // duck: { // VoiceCallDuckFrame
320
+ * // type: "started" || "transcription" || "audio.begin" || "audio.end" || "stop" || "duck" || "language" || "transfer" || "hangup" || "error" || "ended", // required
321
+ * // replyId: "STRING_VALUE", // required
322
+ * // volumeDb: Number("int"), // required
323
+ * // rampMs: Number("int"), // required
324
+ * // },
325
+ * // language: { // VoiceCallLanguageFrame
326
+ * // type: "started" || "transcription" || "audio.begin" || "audio.end" || "stop" || "duck" || "language" || "transfer" || "hangup" || "error" || "ended", // required
327
+ * // language: "STRING_VALUE", // required
328
+ * // },
329
+ * // transfer: { // VoiceCallTransferFrame
330
+ * // context: "STRING_VALUE", // required
331
+ * // extension: "STRING_VALUE", // required
332
+ * // type: "started" || "transcription" || "audio.begin" || "audio.end" || "stop" || "duck" || "language" || "transfer" || "hangup" || "error" || "ended", // required
333
+ * // },
334
+ * // hangup: { // VoiceCallHangupFrame
335
+ * // type: "started" || "transcription" || "audio.begin" || "audio.end" || "stop" || "duck" || "language" || "transfer" || "hangup" || "error" || "ended", // required
336
+ * // },
337
+ * // error: { // VoiceCallErrorFrame
338
+ * // type: "started" || "transcription" || "audio.begin" || "audio.end" || "stop" || "duck" || "language" || "transfer" || "hangup" || "error" || "ended", // required
339
+ * // code: "STRING_VALUE", // required
340
+ * // retryable: true || false, // required
341
+ * // message: "STRING_VALUE", // required
342
+ * // },
343
+ * // ended: { // VoiceCallEndedFrame
344
+ * // type: "started" || "transcription" || "audio.begin" || "audio.end" || "stop" || "duck" || "language" || "transfer" || "hangup" || "error" || "ended", // required
345
+ * // },
440
346
  * // },
441
347
  * // };
442
348
  *