@aws-sdk/client-transcribe-streaming 3.301.0 → 3.305.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist-cjs/TranscribeStreamingClient.js +3 -2
- package/dist-cjs/commands/StartCallAnalyticsStreamTranscriptionCommand.js +2 -0
- package/dist-cjs/commands/StartMedicalStreamTranscriptionCommand.js +2 -0
- package/dist-cjs/commands/StartStreamTranscriptionCommand.js +2 -0
- package/dist-cjs/models/models_0.js +81 -95
- package/dist-cjs/runtimeConfig.browser.js +3 -1
- package/dist-cjs/runtimeConfig.native.js +0 -1
- package/dist-es/TranscribeStreamingClient.js +3 -2
- package/dist-es/commands/StartCallAnalyticsStreamTranscriptionCommand.js +2 -0
- package/dist-es/commands/StartMedicalStreamTranscriptionCommand.js +2 -0
- package/dist-es/commands/StartStreamTranscriptionCommand.js +2 -0
- package/dist-es/models/models_0.js +81 -95
- package/dist-es/runtimeConfig.browser.js +5 -3
- package/dist-es/runtimeConfig.native.js +1 -2
- package/dist-types/TranscribeStreamingClient.d.ts +1 -1
- package/dist-types/models/models_0.d.ts +151 -81
- package/dist-types/runtimeConfig.browser.d.ts +2 -2
- package/dist-types/runtimeConfig.native.d.ts +1 -2
- package/dist-types/ts3.4/TranscribeStreamingClient.d.ts +4 -4
- package/dist-types/ts3.4/models/models_0.d.ts +103 -81
- package/dist-types/ts3.4/runtimeConfig.browser.d.ts +2 -2
- package/dist-types/ts3.4/runtimeConfig.native.d.ts +2 -3
- package/package.json +41 -40
|
@@ -13,6 +13,7 @@ const middleware_retry_1 = require("@aws-sdk/middleware-retry");
|
|
|
13
13
|
const middleware_sdk_transcribe_streaming_1 = require("@aws-sdk/middleware-sdk-transcribe-streaming");
|
|
14
14
|
const middleware_signing_1 = require("@aws-sdk/middleware-signing");
|
|
15
15
|
const middleware_user_agent_1 = require("@aws-sdk/middleware-user-agent");
|
|
16
|
+
const middleware_websocket_1 = require("@aws-sdk/middleware-websocket");
|
|
16
17
|
const smithy_client_1 = require("@aws-sdk/smithy-client");
|
|
17
18
|
const EndpointParameters_1 = require("./endpoint/EndpointParameters");
|
|
18
19
|
const runtimeConfig_1 = require("./runtimeConfig");
|
|
@@ -26,7 +27,7 @@ class TranscribeStreamingClient extends smithy_client_1.Client {
|
|
|
26
27
|
const _config_5 = (0, middleware_host_header_1.resolveHostHeaderConfig)(_config_4);
|
|
27
28
|
const _config_6 = (0, middleware_signing_1.resolveAwsAuthConfig)(_config_5);
|
|
28
29
|
const _config_7 = (0, middleware_eventstream_1.resolveEventStreamConfig)(_config_6);
|
|
29
|
-
const _config_8 = (0,
|
|
30
|
+
const _config_8 = (0, middleware_websocket_1.resolveWebSocketConfig)(_config_7);
|
|
30
31
|
const _config_9 = (0, middleware_user_agent_1.resolveUserAgentConfig)(_config_8);
|
|
31
32
|
const _config_10 = (0, eventstream_serde_config_resolver_1.resolveEventStreamSerdeConfig)(_config_9);
|
|
32
33
|
super(_config_10);
|
|
@@ -37,7 +38,7 @@ class TranscribeStreamingClient extends smithy_client_1.Client {
|
|
|
37
38
|
this.middlewareStack.use((0, middleware_logger_1.getLoggerPlugin)(this.config));
|
|
38
39
|
this.middlewareStack.use((0, middleware_recursion_detection_1.getRecursionDetectionPlugin)(this.config));
|
|
39
40
|
this.middlewareStack.use((0, middleware_signing_1.getAwsAuthPlugin)(this.config));
|
|
40
|
-
this.middlewareStack.use((0, middleware_sdk_transcribe_streaming_1.
|
|
41
|
+
this.middlewareStack.use((0, middleware_sdk_transcribe_streaming_1.getTranscribeStreamingPlugin)(this.config));
|
|
41
42
|
this.middlewareStack.use((0, middleware_user_agent_1.getUserAgentPlugin)(this.config));
|
|
42
43
|
}
|
|
43
44
|
destroy() {
|
|
@@ -4,6 +4,7 @@ exports.StartCallAnalyticsStreamTranscriptionCommand = void 0;
|
|
|
4
4
|
const middleware_endpoint_1 = require("@aws-sdk/middleware-endpoint");
|
|
5
5
|
const middleware_eventstream_1 = require("@aws-sdk/middleware-eventstream");
|
|
6
6
|
const middleware_serde_1 = require("@aws-sdk/middleware-serde");
|
|
7
|
+
const middleware_websocket_1 = require("@aws-sdk/middleware-websocket");
|
|
7
8
|
const smithy_client_1 = require("@aws-sdk/smithy-client");
|
|
8
9
|
const models_0_1 = require("../models/models_0");
|
|
9
10
|
const Aws_restJson1_1 = require("../protocols/Aws_restJson1");
|
|
@@ -24,6 +25,7 @@ class StartCallAnalyticsStreamTranscriptionCommand extends smithy_client_1.Comma
|
|
|
24
25
|
this.middlewareStack.use((0, middleware_serde_1.getSerdePlugin)(configuration, this.serialize, this.deserialize));
|
|
25
26
|
this.middlewareStack.use((0, middleware_endpoint_1.getEndpointPlugin)(configuration, StartCallAnalyticsStreamTranscriptionCommand.getEndpointParameterInstructions()));
|
|
26
27
|
this.middlewareStack.use((0, middleware_eventstream_1.getEventStreamPlugin)(configuration));
|
|
28
|
+
this.middlewareStack.use((0, middleware_websocket_1.getWebSocketPlugin)(configuration, { headerPrefix: "x-amzn-transcribe-" }));
|
|
27
29
|
const stack = clientStack.concat(this.middlewareStack);
|
|
28
30
|
const { logger } = configuration;
|
|
29
31
|
const clientName = "TranscribeStreamingClient";
|
|
@@ -4,6 +4,7 @@ exports.StartMedicalStreamTranscriptionCommand = void 0;
|
|
|
4
4
|
const middleware_endpoint_1 = require("@aws-sdk/middleware-endpoint");
|
|
5
5
|
const middleware_eventstream_1 = require("@aws-sdk/middleware-eventstream");
|
|
6
6
|
const middleware_serde_1 = require("@aws-sdk/middleware-serde");
|
|
7
|
+
const middleware_websocket_1 = require("@aws-sdk/middleware-websocket");
|
|
7
8
|
const smithy_client_1 = require("@aws-sdk/smithy-client");
|
|
8
9
|
const models_0_1 = require("../models/models_0");
|
|
9
10
|
const Aws_restJson1_1 = require("../protocols/Aws_restJson1");
|
|
@@ -24,6 +25,7 @@ class StartMedicalStreamTranscriptionCommand extends smithy_client_1.Command {
|
|
|
24
25
|
this.middlewareStack.use((0, middleware_serde_1.getSerdePlugin)(configuration, this.serialize, this.deserialize));
|
|
25
26
|
this.middlewareStack.use((0, middleware_endpoint_1.getEndpointPlugin)(configuration, StartMedicalStreamTranscriptionCommand.getEndpointParameterInstructions()));
|
|
26
27
|
this.middlewareStack.use((0, middleware_eventstream_1.getEventStreamPlugin)(configuration));
|
|
28
|
+
this.middlewareStack.use((0, middleware_websocket_1.getWebSocketPlugin)(configuration, { headerPrefix: "x-amzn-transcribe-" }));
|
|
27
29
|
const stack = clientStack.concat(this.middlewareStack);
|
|
28
30
|
const { logger } = configuration;
|
|
29
31
|
const clientName = "TranscribeStreamingClient";
|
|
@@ -4,6 +4,7 @@ exports.StartStreamTranscriptionCommand = void 0;
|
|
|
4
4
|
const middleware_endpoint_1 = require("@aws-sdk/middleware-endpoint");
|
|
5
5
|
const middleware_eventstream_1 = require("@aws-sdk/middleware-eventstream");
|
|
6
6
|
const middleware_serde_1 = require("@aws-sdk/middleware-serde");
|
|
7
|
+
const middleware_websocket_1 = require("@aws-sdk/middleware-websocket");
|
|
7
8
|
const smithy_client_1 = require("@aws-sdk/smithy-client");
|
|
8
9
|
const models_0_1 = require("../models/models_0");
|
|
9
10
|
const Aws_restJson1_1 = require("../protocols/Aws_restJson1");
|
|
@@ -24,6 +25,7 @@ class StartStreamTranscriptionCommand extends smithy_client_1.Command {
|
|
|
24
25
|
this.middlewareStack.use((0, middleware_serde_1.getSerdePlugin)(configuration, this.serialize, this.deserialize));
|
|
25
26
|
this.middlewareStack.use((0, middleware_endpoint_1.getEndpointPlugin)(configuration, StartStreamTranscriptionCommand.getEndpointParameterInstructions()));
|
|
26
27
|
this.middlewareStack.use((0, middleware_eventstream_1.getEventStreamPlugin)(configuration));
|
|
28
|
+
this.middlewareStack.use((0, middleware_websocket_1.getWebSocketPlugin)(configuration, { headerPrefix: "x-amzn-transcribe-" }));
|
|
27
29
|
const stack = clientStack.concat(this.middlewareStack);
|
|
28
30
|
const { logger } = configuration;
|
|
29
31
|
const clientName = "TranscribeStreamingClient";
|
|
@@ -2,21 +2,18 @@
|
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.StartStreamTranscriptionResponseFilterSensitiveLog = exports.TranscriptResultStreamFilterSensitiveLog = exports.StartStreamTranscriptionRequestFilterSensitiveLog = exports.StartMedicalStreamTranscriptionResponseFilterSensitiveLog = exports.StartMedicalStreamTranscriptionRequestFilterSensitiveLog = exports.StartCallAnalyticsStreamTranscriptionResponseFilterSensitiveLog = exports.StartCallAnalyticsStreamTranscriptionRequestFilterSensitiveLog = exports.MedicalTranscriptResultStreamFilterSensitiveLog = exports.CallAnalyticsTranscriptResultStreamFilterSensitiveLog = exports.AudioStreamFilterSensitiveLog = exports.TranscriptResultStream = exports.Type = exports.VocabularyFilterMethod = exports.Specialty = exports.PartialResultsStability = exports.MedicalTranscriptResultStream = exports.MedicalContentIdentificationType = exports.MediaEncoding = exports.LanguageCode = exports.ContentRedactionType = exports.ContentIdentificationType = exports.CallAnalyticsTranscriptResultStream = exports.Sentiment = exports.ServiceUnavailableException = exports.LimitExceededException = exports.InternalFailureException = exports.ConflictException = exports.CallAnalyticsLanguageCode = exports.BadRequestException = exports.AudioStream = exports.ContentRedactionOutput = exports.ParticipantRole = exports.ItemType = void 0;
|
|
4
4
|
const TranscribeStreamingServiceException_1 = require("./TranscribeStreamingServiceException");
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
ContentRedactionOutput["REDACTED"] = "redacted";
|
|
18
|
-
ContentRedactionOutput["REDACTED_AND_UNREDACTED"] = "redacted_and_unredacted";
|
|
19
|
-
})(ContentRedactionOutput = exports.ContentRedactionOutput || (exports.ContentRedactionOutput = {}));
|
|
5
|
+
exports.ItemType = {
|
|
6
|
+
PRONUNCIATION: "pronunciation",
|
|
7
|
+
PUNCTUATION: "punctuation",
|
|
8
|
+
};
|
|
9
|
+
exports.ParticipantRole = {
|
|
10
|
+
AGENT: "AGENT",
|
|
11
|
+
CUSTOMER: "CUSTOMER",
|
|
12
|
+
};
|
|
13
|
+
exports.ContentRedactionOutput = {
|
|
14
|
+
REDACTED: "redacted",
|
|
15
|
+
REDACTED_AND_UNREDACTED: "redacted_and_unredacted",
|
|
16
|
+
};
|
|
20
17
|
var AudioStream;
|
|
21
18
|
(function (AudioStream) {
|
|
22
19
|
AudioStream.visit = (value, visitor) => {
|
|
@@ -41,18 +38,17 @@ class BadRequestException extends TranscribeStreamingServiceException_1.Transcri
|
|
|
41
38
|
}
|
|
42
39
|
}
|
|
43
40
|
exports.BadRequestException = BadRequestException;
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
})(CallAnalyticsLanguageCode = exports.CallAnalyticsLanguageCode || (exports.CallAnalyticsLanguageCode = {}));
|
|
41
|
+
exports.CallAnalyticsLanguageCode = {
|
|
42
|
+
DE_DE: "de-DE",
|
|
43
|
+
EN_AU: "en-AU",
|
|
44
|
+
EN_GB: "en-GB",
|
|
45
|
+
EN_US: "en-US",
|
|
46
|
+
ES_US: "es-US",
|
|
47
|
+
FR_CA: "fr-CA",
|
|
48
|
+
FR_FR: "fr-FR",
|
|
49
|
+
IT_IT: "it-IT",
|
|
50
|
+
PT_BR: "pt-BR",
|
|
51
|
+
};
|
|
56
52
|
class ConflictException extends TranscribeStreamingServiceException_1.TranscribeStreamingServiceException {
|
|
57
53
|
constructor(opts) {
|
|
58
54
|
super({
|
|
@@ -109,13 +105,12 @@ class ServiceUnavailableException extends TranscribeStreamingServiceException_1.
|
|
|
109
105
|
}
|
|
110
106
|
}
|
|
111
107
|
exports.ServiceUnavailableException = ServiceUnavailableException;
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
})(Sentiment = exports.Sentiment || (exports.Sentiment = {}));
|
|
108
|
+
exports.Sentiment = {
|
|
109
|
+
MIXED: "MIXED",
|
|
110
|
+
NEGATIVE: "NEGATIVE",
|
|
111
|
+
NEUTRAL: "NEUTRAL",
|
|
112
|
+
POSITIVE: "POSITIVE",
|
|
113
|
+
};
|
|
119
114
|
var CallAnalyticsTranscriptResultStream;
|
|
120
115
|
(function (CallAnalyticsTranscriptResultStream) {
|
|
121
116
|
CallAnalyticsTranscriptResultStream.visit = (value, visitor) => {
|
|
@@ -136,41 +131,36 @@ var CallAnalyticsTranscriptResultStream;
|
|
|
136
131
|
return visitor._(value.$unknown[0], value.$unknown[1]);
|
|
137
132
|
};
|
|
138
133
|
})(CallAnalyticsTranscriptResultStream = exports.CallAnalyticsTranscriptResultStream || (exports.CallAnalyticsTranscriptResultStream = {}));
|
|
139
|
-
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-
|
|
145
|
-
|
|
146
|
-
|
|
147
|
-
|
|
148
|
-
|
|
149
|
-
|
|
150
|
-
|
|
151
|
-
|
|
152
|
-
|
|
153
|
-
|
|
154
|
-
|
|
155
|
-
|
|
156
|
-
|
|
157
|
-
|
|
158
|
-
|
|
159
|
-
|
|
160
|
-
|
|
161
|
-
|
|
162
|
-
|
|
163
|
-
|
|
164
|
-
|
|
165
|
-
|
|
166
|
-
|
|
167
|
-
|
|
168
|
-
|
|
169
|
-
})(MediaEncoding = exports.MediaEncoding || (exports.MediaEncoding = {}));
|
|
170
|
-
var MedicalContentIdentificationType;
|
|
171
|
-
(function (MedicalContentIdentificationType) {
|
|
172
|
-
MedicalContentIdentificationType["PHI"] = "PHI";
|
|
173
|
-
})(MedicalContentIdentificationType = exports.MedicalContentIdentificationType || (exports.MedicalContentIdentificationType = {}));
|
|
134
|
+
exports.ContentIdentificationType = {
|
|
135
|
+
PII: "PII",
|
|
136
|
+
};
|
|
137
|
+
exports.ContentRedactionType = {
|
|
138
|
+
PII: "PII",
|
|
139
|
+
};
|
|
140
|
+
exports.LanguageCode = {
|
|
141
|
+
DE_DE: "de-DE",
|
|
142
|
+
EN_AU: "en-AU",
|
|
143
|
+
EN_GB: "en-GB",
|
|
144
|
+
EN_US: "en-US",
|
|
145
|
+
ES_US: "es-US",
|
|
146
|
+
FR_CA: "fr-CA",
|
|
147
|
+
FR_FR: "fr-FR",
|
|
148
|
+
HI_IN: "hi-IN",
|
|
149
|
+
IT_IT: "it-IT",
|
|
150
|
+
JA_JP: "ja-JP",
|
|
151
|
+
KO_KR: "ko-KR",
|
|
152
|
+
PT_BR: "pt-BR",
|
|
153
|
+
TH_TH: "th-TH",
|
|
154
|
+
ZH_CN: "zh-CN",
|
|
155
|
+
};
|
|
156
|
+
exports.MediaEncoding = {
|
|
157
|
+
FLAC: "flac",
|
|
158
|
+
OGG_OPUS: "ogg-opus",
|
|
159
|
+
PCM: "pcm",
|
|
160
|
+
};
|
|
161
|
+
exports.MedicalContentIdentificationType = {
|
|
162
|
+
PHI: "PHI",
|
|
163
|
+
};
|
|
174
164
|
var MedicalTranscriptResultStream;
|
|
175
165
|
(function (MedicalTranscriptResultStream) {
|
|
176
166
|
MedicalTranscriptResultStream.visit = (value, visitor) => {
|
|
@@ -189,32 +179,28 @@ var MedicalTranscriptResultStream;
|
|
|
189
179
|
return visitor._(value.$unknown[0], value.$unknown[1]);
|
|
190
180
|
};
|
|
191
181
|
})(MedicalTranscriptResultStream = exports.MedicalTranscriptResultStream || (exports.MedicalTranscriptResultStream = {}));
|
|
192
|
-
|
|
193
|
-
|
|
194
|
-
|
|
195
|
-
|
|
196
|
-
|
|
197
|
-
|
|
198
|
-
|
|
199
|
-
|
|
200
|
-
|
|
201
|
-
|
|
202
|
-
|
|
203
|
-
|
|
204
|
-
|
|
205
|
-
|
|
206
|
-
|
|
207
|
-
|
|
208
|
-
|
|
209
|
-
|
|
210
|
-
|
|
211
|
-
|
|
212
|
-
|
|
213
|
-
|
|
214
|
-
(function (Type) {
|
|
215
|
-
Type["CONVERSATION"] = "CONVERSATION";
|
|
216
|
-
Type["DICTATION"] = "DICTATION";
|
|
217
|
-
})(Type = exports.Type || (exports.Type = {}));
|
|
182
|
+
exports.PartialResultsStability = {
|
|
183
|
+
HIGH: "high",
|
|
184
|
+
LOW: "low",
|
|
185
|
+
MEDIUM: "medium",
|
|
186
|
+
};
|
|
187
|
+
exports.Specialty = {
|
|
188
|
+
CARDIOLOGY: "CARDIOLOGY",
|
|
189
|
+
NEUROLOGY: "NEUROLOGY",
|
|
190
|
+
ONCOLOGY: "ONCOLOGY",
|
|
191
|
+
PRIMARYCARE: "PRIMARYCARE",
|
|
192
|
+
RADIOLOGY: "RADIOLOGY",
|
|
193
|
+
UROLOGY: "UROLOGY",
|
|
194
|
+
};
|
|
195
|
+
exports.VocabularyFilterMethod = {
|
|
196
|
+
MASK: "mask",
|
|
197
|
+
REMOVE: "remove",
|
|
198
|
+
TAG: "tag",
|
|
199
|
+
};
|
|
200
|
+
exports.Type = {
|
|
201
|
+
CONVERSATION: "CONVERSATION",
|
|
202
|
+
DICTATION: "DICTATION",
|
|
203
|
+
};
|
|
218
204
|
var TranscriptResultStream;
|
|
219
205
|
(function (TranscriptResultStream) {
|
|
220
206
|
TranscriptResultStream.visit = (value, visitor) => {
|
|
@@ -9,6 +9,7 @@ const eventstream_serde_browser_1 = require("@aws-sdk/eventstream-serde-browser"
|
|
|
9
9
|
const fetch_http_handler_1 = require("@aws-sdk/fetch-http-handler");
|
|
10
10
|
const invalid_dependency_1 = require("@aws-sdk/invalid-dependency");
|
|
11
11
|
const middleware_sdk_transcribe_streaming_1 = require("@aws-sdk/middleware-sdk-transcribe-streaming");
|
|
12
|
+
const middleware_websocket_1 = require("@aws-sdk/middleware-websocket");
|
|
12
13
|
const util_body_length_browser_1 = require("@aws-sdk/util-body-length-browser");
|
|
13
14
|
const util_retry_1 = require("@aws-sdk/util-retry");
|
|
14
15
|
const util_user_agent_browser_1 = require("@aws-sdk/util-user-agent-browser");
|
|
@@ -32,7 +33,8 @@ const getRuntimeConfig = (config) => {
|
|
|
32
33
|
eventStreamSerdeProvider: config?.eventStreamSerdeProvider ?? eventstream_serde_browser_1.eventStreamSerdeProvider,
|
|
33
34
|
maxAttempts: config?.maxAttempts ?? util_retry_1.DEFAULT_MAX_ATTEMPTS,
|
|
34
35
|
region: config?.region ?? (0, invalid_dependency_1.invalidProvider)("Region is missing"),
|
|
35
|
-
requestHandler: config?.requestHandler ??
|
|
36
|
+
requestHandler: config?.requestHandler ??
|
|
37
|
+
new middleware_websocket_1.WebSocketFetchHandler(defaultConfigProvider, new fetch_http_handler_1.FetchHttpHandler(defaultConfigProvider)),
|
|
36
38
|
retryMode: config?.retryMode ?? (async () => (await defaultConfigProvider()).retryMode || util_retry_1.DEFAULT_RETRY_MODE),
|
|
37
39
|
sha256: config?.sha256 ?? sha256_browser_1.Sha256,
|
|
38
40
|
streamCollector: config?.streamCollector ?? fetch_http_handler_1.streamCollector,
|
|
@@ -11,7 +11,6 @@ const getRuntimeConfig = (config) => {
|
|
|
11
11
|
...config,
|
|
12
12
|
runtime: "react-native",
|
|
13
13
|
eventStreamPayloadHandlerProvider: config?.eventStreamPayloadHandlerProvider ?? (() => middleware_sdk_transcribe_streaming_1.eventStreamPayloadHandler),
|
|
14
|
-
requestHandler: config?.requestHandler ?? new middleware_sdk_transcribe_streaming_1.WebSocketHandler(),
|
|
15
14
|
sha256: config?.sha256 ?? sha256_js_1.Sha256,
|
|
16
15
|
};
|
|
17
16
|
};
|
|
@@ -7,9 +7,10 @@ import { getHostHeaderPlugin, resolveHostHeaderConfig, } from "@aws-sdk/middlewa
|
|
|
7
7
|
import { getLoggerPlugin } from "@aws-sdk/middleware-logger";
|
|
8
8
|
import { getRecursionDetectionPlugin } from "@aws-sdk/middleware-recursion-detection";
|
|
9
9
|
import { getRetryPlugin, resolveRetryConfig } from "@aws-sdk/middleware-retry";
|
|
10
|
-
import {
|
|
10
|
+
import { getTranscribeStreamingPlugin } from "@aws-sdk/middleware-sdk-transcribe-streaming";
|
|
11
11
|
import { getAwsAuthPlugin, resolveAwsAuthConfig, } from "@aws-sdk/middleware-signing";
|
|
12
12
|
import { getUserAgentPlugin, resolveUserAgentConfig, } from "@aws-sdk/middleware-user-agent";
|
|
13
|
+
import { resolveWebSocketConfig } from "@aws-sdk/middleware-websocket";
|
|
13
14
|
import { Client as __Client, } from "@aws-sdk/smithy-client";
|
|
14
15
|
import { resolveClientEndpointParameters, } from "./endpoint/EndpointParameters";
|
|
15
16
|
import { getRuntimeConfig as __getRuntimeConfig } from "./runtimeConfig";
|
|
@@ -34,7 +35,7 @@ export class TranscribeStreamingClient extends __Client {
|
|
|
34
35
|
this.middlewareStack.use(getLoggerPlugin(this.config));
|
|
35
36
|
this.middlewareStack.use(getRecursionDetectionPlugin(this.config));
|
|
36
37
|
this.middlewareStack.use(getAwsAuthPlugin(this.config));
|
|
37
|
-
this.middlewareStack.use(
|
|
38
|
+
this.middlewareStack.use(getTranscribeStreamingPlugin(this.config));
|
|
38
39
|
this.middlewareStack.use(getUserAgentPlugin(this.config));
|
|
39
40
|
}
|
|
40
41
|
destroy() {
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import { getEndpointPlugin } from "@aws-sdk/middleware-endpoint";
|
|
2
2
|
import { getEventStreamPlugin } from "@aws-sdk/middleware-eventstream";
|
|
3
3
|
import { getSerdePlugin } from "@aws-sdk/middleware-serde";
|
|
4
|
+
import { getWebSocketPlugin } from "@aws-sdk/middleware-websocket";
|
|
4
5
|
import { Command as $Command } from "@aws-sdk/smithy-client";
|
|
5
6
|
import { StartCallAnalyticsStreamTranscriptionRequestFilterSensitiveLog, StartCallAnalyticsStreamTranscriptionResponseFilterSensitiveLog, } from "../models/models_0";
|
|
6
7
|
import { deserializeAws_restJson1StartCallAnalyticsStreamTranscriptionCommand, serializeAws_restJson1StartCallAnalyticsStreamTranscriptionCommand, } from "../protocols/Aws_restJson1";
|
|
@@ -21,6 +22,7 @@ export class StartCallAnalyticsStreamTranscriptionCommand extends $Command {
|
|
|
21
22
|
this.middlewareStack.use(getSerdePlugin(configuration, this.serialize, this.deserialize));
|
|
22
23
|
this.middlewareStack.use(getEndpointPlugin(configuration, StartCallAnalyticsStreamTranscriptionCommand.getEndpointParameterInstructions()));
|
|
23
24
|
this.middlewareStack.use(getEventStreamPlugin(configuration));
|
|
25
|
+
this.middlewareStack.use(getWebSocketPlugin(configuration, { headerPrefix: "x-amzn-transcribe-" }));
|
|
24
26
|
const stack = clientStack.concat(this.middlewareStack);
|
|
25
27
|
const { logger } = configuration;
|
|
26
28
|
const clientName = "TranscribeStreamingClient";
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import { getEndpointPlugin } from "@aws-sdk/middleware-endpoint";
|
|
2
2
|
import { getEventStreamPlugin } from "@aws-sdk/middleware-eventstream";
|
|
3
3
|
import { getSerdePlugin } from "@aws-sdk/middleware-serde";
|
|
4
|
+
import { getWebSocketPlugin } from "@aws-sdk/middleware-websocket";
|
|
4
5
|
import { Command as $Command } from "@aws-sdk/smithy-client";
|
|
5
6
|
import { StartMedicalStreamTranscriptionRequestFilterSensitiveLog, StartMedicalStreamTranscriptionResponseFilterSensitiveLog, } from "../models/models_0";
|
|
6
7
|
import { deserializeAws_restJson1StartMedicalStreamTranscriptionCommand, serializeAws_restJson1StartMedicalStreamTranscriptionCommand, } from "../protocols/Aws_restJson1";
|
|
@@ -21,6 +22,7 @@ export class StartMedicalStreamTranscriptionCommand extends $Command {
|
|
|
21
22
|
this.middlewareStack.use(getSerdePlugin(configuration, this.serialize, this.deserialize));
|
|
22
23
|
this.middlewareStack.use(getEndpointPlugin(configuration, StartMedicalStreamTranscriptionCommand.getEndpointParameterInstructions()));
|
|
23
24
|
this.middlewareStack.use(getEventStreamPlugin(configuration));
|
|
25
|
+
this.middlewareStack.use(getWebSocketPlugin(configuration, { headerPrefix: "x-amzn-transcribe-" }));
|
|
24
26
|
const stack = clientStack.concat(this.middlewareStack);
|
|
25
27
|
const { logger } = configuration;
|
|
26
28
|
const clientName = "TranscribeStreamingClient";
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import { getEndpointPlugin } from "@aws-sdk/middleware-endpoint";
|
|
2
2
|
import { getEventStreamPlugin } from "@aws-sdk/middleware-eventstream";
|
|
3
3
|
import { getSerdePlugin } from "@aws-sdk/middleware-serde";
|
|
4
|
+
import { getWebSocketPlugin } from "@aws-sdk/middleware-websocket";
|
|
4
5
|
import { Command as $Command } from "@aws-sdk/smithy-client";
|
|
5
6
|
import { StartStreamTranscriptionRequestFilterSensitiveLog, StartStreamTranscriptionResponseFilterSensitiveLog, } from "../models/models_0";
|
|
6
7
|
import { deserializeAws_restJson1StartStreamTranscriptionCommand, serializeAws_restJson1StartStreamTranscriptionCommand, } from "../protocols/Aws_restJson1";
|
|
@@ -21,6 +22,7 @@ export class StartStreamTranscriptionCommand extends $Command {
|
|
|
21
22
|
this.middlewareStack.use(getSerdePlugin(configuration, this.serialize, this.deserialize));
|
|
22
23
|
this.middlewareStack.use(getEndpointPlugin(configuration, StartStreamTranscriptionCommand.getEndpointParameterInstructions()));
|
|
23
24
|
this.middlewareStack.use(getEventStreamPlugin(configuration));
|
|
25
|
+
this.middlewareStack.use(getWebSocketPlugin(configuration, { headerPrefix: "x-amzn-transcribe-" }));
|
|
24
26
|
const stack = clientStack.concat(this.middlewareStack);
|
|
25
27
|
const { logger } = configuration;
|
|
26
28
|
const clientName = "TranscribeStreamingClient";
|
|
@@ -1,19 +1,16 @@
|
|
|
1
1
|
import { TranscribeStreamingServiceException as __BaseException } from "./TranscribeStreamingServiceException";
|
|
2
|
-
export
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
ContentRedactionOutput["REDACTED"] = "redacted";
|
|
15
|
-
ContentRedactionOutput["REDACTED_AND_UNREDACTED"] = "redacted_and_unredacted";
|
|
16
|
-
})(ContentRedactionOutput || (ContentRedactionOutput = {}));
|
|
2
|
+
export const ItemType = {
|
|
3
|
+
PRONUNCIATION: "pronunciation",
|
|
4
|
+
PUNCTUATION: "punctuation",
|
|
5
|
+
};
|
|
6
|
+
export const ParticipantRole = {
|
|
7
|
+
AGENT: "AGENT",
|
|
8
|
+
CUSTOMER: "CUSTOMER",
|
|
9
|
+
};
|
|
10
|
+
export const ContentRedactionOutput = {
|
|
11
|
+
REDACTED: "redacted",
|
|
12
|
+
REDACTED_AND_UNREDACTED: "redacted_and_unredacted",
|
|
13
|
+
};
|
|
17
14
|
export var AudioStream;
|
|
18
15
|
(function (AudioStream) {
|
|
19
16
|
AudioStream.visit = (value, visitor) => {
|
|
@@ -37,18 +34,17 @@ export class BadRequestException extends __BaseException {
|
|
|
37
34
|
this.Message = opts.Message;
|
|
38
35
|
}
|
|
39
36
|
}
|
|
40
|
-
export
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
})(CallAnalyticsLanguageCode || (CallAnalyticsLanguageCode = {}));
|
|
37
|
+
export const CallAnalyticsLanguageCode = {
|
|
38
|
+
DE_DE: "de-DE",
|
|
39
|
+
EN_AU: "en-AU",
|
|
40
|
+
EN_GB: "en-GB",
|
|
41
|
+
EN_US: "en-US",
|
|
42
|
+
ES_US: "es-US",
|
|
43
|
+
FR_CA: "fr-CA",
|
|
44
|
+
FR_FR: "fr-FR",
|
|
45
|
+
IT_IT: "it-IT",
|
|
46
|
+
PT_BR: "pt-BR",
|
|
47
|
+
};
|
|
52
48
|
export class ConflictException extends __BaseException {
|
|
53
49
|
constructor(opts) {
|
|
54
50
|
super({
|
|
@@ -101,13 +97,12 @@ export class ServiceUnavailableException extends __BaseException {
|
|
|
101
97
|
this.Message = opts.Message;
|
|
102
98
|
}
|
|
103
99
|
}
|
|
104
|
-
export
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
})(Sentiment || (Sentiment = {}));
|
|
100
|
+
export const Sentiment = {
|
|
101
|
+
MIXED: "MIXED",
|
|
102
|
+
NEGATIVE: "NEGATIVE",
|
|
103
|
+
NEUTRAL: "NEUTRAL",
|
|
104
|
+
POSITIVE: "POSITIVE",
|
|
105
|
+
};
|
|
111
106
|
export var CallAnalyticsTranscriptResultStream;
|
|
112
107
|
(function (CallAnalyticsTranscriptResultStream) {
|
|
113
108
|
CallAnalyticsTranscriptResultStream.visit = (value, visitor) => {
|
|
@@ -128,41 +123,36 @@ export var CallAnalyticsTranscriptResultStream;
|
|
|
128
123
|
return visitor._(value.$unknown[0], value.$unknown[1]);
|
|
129
124
|
};
|
|
130
125
|
})(CallAnalyticsTranscriptResultStream || (CallAnalyticsTranscriptResultStream = {}));
|
|
131
|
-
export
|
|
132
|
-
|
|
133
|
-
|
|
134
|
-
|
|
135
|
-
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-
|
|
145
|
-
|
|
146
|
-
|
|
147
|
-
|
|
148
|
-
|
|
149
|
-
|
|
150
|
-
|
|
151
|
-
|
|
152
|
-
|
|
153
|
-
|
|
154
|
-
|
|
155
|
-
|
|
156
|
-
|
|
157
|
-
|
|
158
|
-
|
|
159
|
-
|
|
160
|
-
|
|
161
|
-
})(MediaEncoding || (MediaEncoding = {}));
|
|
162
|
-
export var MedicalContentIdentificationType;
|
|
163
|
-
(function (MedicalContentIdentificationType) {
|
|
164
|
-
MedicalContentIdentificationType["PHI"] = "PHI";
|
|
165
|
-
})(MedicalContentIdentificationType || (MedicalContentIdentificationType = {}));
|
|
126
|
+
export const ContentIdentificationType = {
|
|
127
|
+
PII: "PII",
|
|
128
|
+
};
|
|
129
|
+
export const ContentRedactionType = {
|
|
130
|
+
PII: "PII",
|
|
131
|
+
};
|
|
132
|
+
export const LanguageCode = {
|
|
133
|
+
DE_DE: "de-DE",
|
|
134
|
+
EN_AU: "en-AU",
|
|
135
|
+
EN_GB: "en-GB",
|
|
136
|
+
EN_US: "en-US",
|
|
137
|
+
ES_US: "es-US",
|
|
138
|
+
FR_CA: "fr-CA",
|
|
139
|
+
FR_FR: "fr-FR",
|
|
140
|
+
HI_IN: "hi-IN",
|
|
141
|
+
IT_IT: "it-IT",
|
|
142
|
+
JA_JP: "ja-JP",
|
|
143
|
+
KO_KR: "ko-KR",
|
|
144
|
+
PT_BR: "pt-BR",
|
|
145
|
+
TH_TH: "th-TH",
|
|
146
|
+
ZH_CN: "zh-CN",
|
|
147
|
+
};
|
|
148
|
+
export const MediaEncoding = {
|
|
149
|
+
FLAC: "flac",
|
|
150
|
+
OGG_OPUS: "ogg-opus",
|
|
151
|
+
PCM: "pcm",
|
|
152
|
+
};
|
|
153
|
+
export const MedicalContentIdentificationType = {
|
|
154
|
+
PHI: "PHI",
|
|
155
|
+
};
|
|
166
156
|
export var MedicalTranscriptResultStream;
|
|
167
157
|
(function (MedicalTranscriptResultStream) {
|
|
168
158
|
MedicalTranscriptResultStream.visit = (value, visitor) => {
|
|
@@ -181,32 +171,28 @@ export var MedicalTranscriptResultStream;
|
|
|
181
171
|
return visitor._(value.$unknown[0], value.$unknown[1]);
|
|
182
172
|
};
|
|
183
173
|
})(MedicalTranscriptResultStream || (MedicalTranscriptResultStream = {}));
|
|
184
|
-
export
|
|
185
|
-
|
|
186
|
-
|
|
187
|
-
|
|
188
|
-
|
|
189
|
-
|
|
190
|
-
|
|
191
|
-
|
|
192
|
-
|
|
193
|
-
|
|
194
|
-
|
|
195
|
-
|
|
196
|
-
|
|
197
|
-
|
|
198
|
-
|
|
199
|
-
|
|
200
|
-
|
|
201
|
-
|
|
202
|
-
|
|
203
|
-
|
|
204
|
-
|
|
205
|
-
|
|
206
|
-
(function (Type) {
|
|
207
|
-
Type["CONVERSATION"] = "CONVERSATION";
|
|
208
|
-
Type["DICTATION"] = "DICTATION";
|
|
209
|
-
})(Type || (Type = {}));
|
|
174
|
+
export const PartialResultsStability = {
|
|
175
|
+
HIGH: "high",
|
|
176
|
+
LOW: "low",
|
|
177
|
+
MEDIUM: "medium",
|
|
178
|
+
};
|
|
179
|
+
export const Specialty = {
|
|
180
|
+
CARDIOLOGY: "CARDIOLOGY",
|
|
181
|
+
NEUROLOGY: "NEUROLOGY",
|
|
182
|
+
ONCOLOGY: "ONCOLOGY",
|
|
183
|
+
PRIMARYCARE: "PRIMARYCARE",
|
|
184
|
+
RADIOLOGY: "RADIOLOGY",
|
|
185
|
+
UROLOGY: "UROLOGY",
|
|
186
|
+
};
|
|
187
|
+
export const VocabularyFilterMethod = {
|
|
188
|
+
MASK: "mask",
|
|
189
|
+
REMOVE: "remove",
|
|
190
|
+
TAG: "tag",
|
|
191
|
+
};
|
|
192
|
+
export const Type = {
|
|
193
|
+
CONVERSATION: "CONVERSATION",
|
|
194
|
+
DICTATION: "DICTATION",
|
|
195
|
+
};
|
|
210
196
|
export var TranscriptResultStream;
|
|
211
197
|
(function (TranscriptResultStream) {
|
|
212
198
|
TranscriptResultStream.visit = (value, visitor) => {
|
|
@@ -2,9 +2,10 @@ import packageInfo from "../package.json";
|
|
|
2
2
|
import { Sha256 } from "@aws-crypto/sha256-browser";
|
|
3
3
|
import { DEFAULT_USE_DUALSTACK_ENDPOINT, DEFAULT_USE_FIPS_ENDPOINT } from "@aws-sdk/config-resolver";
|
|
4
4
|
import { eventStreamSerdeProvider } from "@aws-sdk/eventstream-serde-browser";
|
|
5
|
-
import { streamCollector } from "@aws-sdk/fetch-http-handler";
|
|
5
|
+
import { FetchHttpHandler as HttpRequestHandler, streamCollector } from "@aws-sdk/fetch-http-handler";
|
|
6
6
|
import { invalidProvider } from "@aws-sdk/invalid-dependency";
|
|
7
|
-
import {
|
|
7
|
+
import { eventStreamPayloadHandler } from "@aws-sdk/middleware-sdk-transcribe-streaming";
|
|
8
|
+
import { WebSocketFetchHandler as WebSocketRequestHandler } from "@aws-sdk/middleware-websocket";
|
|
8
9
|
import { calculateBodyLength } from "@aws-sdk/util-body-length-browser";
|
|
9
10
|
import { DEFAULT_MAX_ATTEMPTS, DEFAULT_RETRY_MODE } from "@aws-sdk/util-retry";
|
|
10
11
|
import { defaultUserAgent } from "@aws-sdk/util-user-agent-browser";
|
|
@@ -28,7 +29,8 @@ export const getRuntimeConfig = (config) => {
|
|
|
28
29
|
eventStreamSerdeProvider: config?.eventStreamSerdeProvider ?? eventStreamSerdeProvider,
|
|
29
30
|
maxAttempts: config?.maxAttempts ?? DEFAULT_MAX_ATTEMPTS,
|
|
30
31
|
region: config?.region ?? invalidProvider("Region is missing"),
|
|
31
|
-
requestHandler: config?.requestHandler ??
|
|
32
|
+
requestHandler: config?.requestHandler ??
|
|
33
|
+
new WebSocketRequestHandler(defaultConfigProvider, new HttpRequestHandler(defaultConfigProvider)),
|
|
32
34
|
retryMode: config?.retryMode ?? (async () => (await defaultConfigProvider()).retryMode || DEFAULT_RETRY_MODE),
|
|
33
35
|
sha256: config?.sha256 ?? Sha256,
|
|
34
36
|
streamCollector: config?.streamCollector ?? streamCollector,
|