@aws-sdk/client-translate 3.37.0 → 3.41.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.
Files changed (49) hide show
  1. package/CHANGELOG.md +43 -0
  2. package/dist-cjs/commands/index.js +17 -0
  3. package/dist-cjs/endpoints.js +123 -17
  4. package/dist-cjs/index.js +4 -20
  5. package/dist-cjs/models/models_0.js +8 -2
  6. package/dist-cjs/pagination/index.js +7 -0
  7. package/dist-cjs/protocols/Aws_json1_1.js +27 -0
  8. package/dist-cjs/runtimeConfig.browser.js +6 -3
  9. package/dist-cjs/runtimeConfig.js +5 -3
  10. package/dist-es/commands/index.js +14 -0
  11. package/dist-es/endpoints.js +123 -17
  12. package/dist-es/index.js +4 -20
  13. package/dist-es/models/models_0.js +6 -0
  14. package/dist-es/pagination/index.js +4 -0
  15. package/dist-es/protocols/Aws_json1_1.js +58 -33
  16. package/dist-es/runtimeConfig.browser.js +3 -2
  17. package/dist-es/runtimeConfig.js +3 -3
  18. package/dist-types/Translate.d.ts +4 -4
  19. package/dist-types/TranslateClient.d.ts +8 -0
  20. package/dist-types/commands/CreateParallelDataCommand.d.ts +4 -4
  21. package/dist-types/commands/DeleteParallelDataCommand.d.ts +1 -1
  22. package/dist-types/commands/DeleteTerminologyCommand.d.ts +1 -1
  23. package/dist-types/commands/DescribeTextTranslationJobCommand.d.ts +2 -2
  24. package/dist-types/commands/GetParallelDataCommand.d.ts +1 -1
  25. package/dist-types/commands/GetTerminologyCommand.d.ts +1 -1
  26. package/dist-types/commands/ImportTerminologyCommand.d.ts +1 -1
  27. package/dist-types/commands/ListParallelDataCommand.d.ts +1 -1
  28. package/dist-types/commands/ListTerminologiesCommand.d.ts +1 -1
  29. package/dist-types/commands/ListTextTranslationJobsCommand.d.ts +1 -1
  30. package/dist-types/commands/StartTextTranslationJobCommand.d.ts +1 -1
  31. package/dist-types/commands/StopTextTranslationJobCommand.d.ts +1 -1
  32. package/dist-types/commands/TranslateTextCommand.d.ts +1 -1
  33. package/dist-types/commands/UpdateParallelDataCommand.d.ts +1 -1
  34. package/dist-types/commands/index.d.ts +14 -0
  35. package/dist-types/index.d.ts +4 -20
  36. package/dist-types/models/models_0.d.ts +132 -17
  37. package/dist-types/pagination/index.d.ts +4 -0
  38. package/dist-types/runtimeConfig.browser.d.ts +2 -0
  39. package/dist-types/runtimeConfig.d.ts +2 -0
  40. package/dist-types/runtimeConfig.native.d.ts +2 -0
  41. package/dist-types/ts3.4/TranslateClient.d.ts +4 -0
  42. package/dist-types/ts3.4/commands/index.d.ts +14 -0
  43. package/dist-types/ts3.4/index.d.ts +4 -20
  44. package/dist-types/ts3.4/models/models_0.d.ts +23 -2
  45. package/dist-types/ts3.4/pagination/index.d.ts +4 -0
  46. package/dist-types/ts3.4/runtimeConfig.browser.d.ts +2 -0
  47. package/dist-types/ts3.4/runtimeConfig.d.ts +2 -0
  48. package/dist-types/ts3.4/runtimeConfig.native.d.ts +2 -0
  49. package/package.json +26 -26
@@ -140,6 +140,7 @@ export var TerminologyDataFormat;
140
140
  (function (TerminologyDataFormat) {
141
141
  TerminologyDataFormat["CSV"] = "CSV";
142
142
  TerminologyDataFormat["TMX"] = "TMX";
143
+ TerminologyDataFormat["TSV"] = "TSV";
143
144
  })(TerminologyDataFormat || (TerminologyDataFormat = {}));
144
145
  export var GetTerminologyRequest;
145
146
  (function (GetTerminologyRequest) {
@@ -149,6 +150,11 @@ export var TerminologyDataLocation;
149
150
  (function (TerminologyDataLocation) {
150
151
  TerminologyDataLocation.filterSensitiveLog = function (obj) { return (__assign({}, obj)); };
151
152
  })(TerminologyDataLocation || (TerminologyDataLocation = {}));
153
+ export var Directionality;
154
+ (function (Directionality) {
155
+ Directionality["MULTI"] = "MULTI";
156
+ Directionality["UNI"] = "UNI";
157
+ })(Directionality || (Directionality = {}));
152
158
  export var TerminologyProperties;
153
159
  (function (TerminologyProperties) {
154
160
  TerminologyProperties.filterSensitiveLog = function (obj) { return (__assign({}, obj)); };
@@ -0,0 +1,4 @@
1
+ export * from "./Interfaces";
2
+ export * from "./ListParallelDataPaginator";
3
+ export * from "./ListTerminologiesPaginator";
4
+ export * from "./ListTextTranslationJobsPaginator";
@@ -967,68 +967,76 @@ export var deserializeAws_json1_1StartTextTranslationJobCommand = function (outp
967
967
  });
968
968
  }); };
969
969
  var deserializeAws_json1_1StartTextTranslationJobCommandError = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
970
- var parsedOutput, _a, response, errorCode, _b, _c, _d, _e, _f, _g, parsedBody, message;
971
- var _h;
972
- return __generator(this, function (_j) {
973
- switch (_j.label) {
970
+ var parsedOutput, _a, response, errorCode, _b, _c, _d, _e, _f, _g, _h, parsedBody, message;
971
+ var _j;
972
+ return __generator(this, function (_k) {
973
+ switch (_k.label) {
974
974
  case 0:
975
975
  _a = [__assign({}, output)];
976
- _h = {};
976
+ _j = {};
977
977
  return [4, parseBody(output.body, context)];
978
978
  case 1:
979
- parsedOutput = __assign.apply(void 0, _a.concat([(_h.body = _j.sent(), _h)]));
979
+ parsedOutput = __assign.apply(void 0, _a.concat([(_j.body = _k.sent(), _j)]));
980
980
  errorCode = "UnknownError";
981
981
  errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
982
982
  _b = errorCode;
983
983
  switch (_b) {
984
984
  case "InternalServerException": return [3, 2];
985
985
  case "com.amazonaws.translate#InternalServerException": return [3, 2];
986
- case "InvalidRequestException": return [3, 4];
987
- case "com.amazonaws.translate#InvalidRequestException": return [3, 4];
988
- case "ResourceNotFoundException": return [3, 6];
989
- case "com.amazonaws.translate#ResourceNotFoundException": return [3, 6];
990
- case "TooManyRequestsException": return [3, 8];
991
- case "com.amazonaws.translate#TooManyRequestsException": return [3, 8];
992
- case "UnsupportedLanguagePairException": return [3, 10];
993
- case "com.amazonaws.translate#UnsupportedLanguagePairException": return [3, 10];
986
+ case "InvalidParameterValueException": return [3, 4];
987
+ case "com.amazonaws.translate#InvalidParameterValueException": return [3, 4];
988
+ case "InvalidRequestException": return [3, 6];
989
+ case "com.amazonaws.translate#InvalidRequestException": return [3, 6];
990
+ case "ResourceNotFoundException": return [3, 8];
991
+ case "com.amazonaws.translate#ResourceNotFoundException": return [3, 8];
992
+ case "TooManyRequestsException": return [3, 10];
993
+ case "com.amazonaws.translate#TooManyRequestsException": return [3, 10];
994
+ case "UnsupportedLanguagePairException": return [3, 12];
995
+ case "com.amazonaws.translate#UnsupportedLanguagePairException": return [3, 12];
994
996
  }
995
- return [3, 12];
997
+ return [3, 14];
996
998
  case 2:
997
999
  _c = [{}];
998
1000
  return [4, deserializeAws_json1_1InternalServerExceptionResponse(parsedOutput, context)];
999
1001
  case 3:
1000
- response = __assign.apply(void 0, [__assign.apply(void 0, _c.concat([(_j.sent())])), { name: errorCode, $metadata: deserializeMetadata(output) }]);
1001
- return [3, 13];
1002
+ response = __assign.apply(void 0, [__assign.apply(void 0, _c.concat([(_k.sent())])), { name: errorCode, $metadata: deserializeMetadata(output) }]);
1003
+ return [3, 15];
1002
1004
  case 4:
1003
1005
  _d = [{}];
1004
- return [4, deserializeAws_json1_1InvalidRequestExceptionResponse(parsedOutput, context)];
1006
+ return [4, deserializeAws_json1_1InvalidParameterValueExceptionResponse(parsedOutput, context)];
1005
1007
  case 5:
1006
- response = __assign.apply(void 0, [__assign.apply(void 0, _d.concat([(_j.sent())])), { name: errorCode, $metadata: deserializeMetadata(output) }]);
1007
- return [3, 13];
1008
+ response = __assign.apply(void 0, [__assign.apply(void 0, _d.concat([(_k.sent())])), { name: errorCode, $metadata: deserializeMetadata(output) }]);
1009
+ return [3, 15];
1008
1010
  case 6:
1009
1011
  _e = [{}];
1010
- return [4, deserializeAws_json1_1ResourceNotFoundExceptionResponse(parsedOutput, context)];
1012
+ return [4, deserializeAws_json1_1InvalidRequestExceptionResponse(parsedOutput, context)];
1011
1013
  case 7:
1012
- response = __assign.apply(void 0, [__assign.apply(void 0, _e.concat([(_j.sent())])), { name: errorCode, $metadata: deserializeMetadata(output) }]);
1013
- return [3, 13];
1014
+ response = __assign.apply(void 0, [__assign.apply(void 0, _e.concat([(_k.sent())])), { name: errorCode, $metadata: deserializeMetadata(output) }]);
1015
+ return [3, 15];
1014
1016
  case 8:
1015
1017
  _f = [{}];
1016
- return [4, deserializeAws_json1_1TooManyRequestsExceptionResponse(parsedOutput, context)];
1018
+ return [4, deserializeAws_json1_1ResourceNotFoundExceptionResponse(parsedOutput, context)];
1017
1019
  case 9:
1018
- response = __assign.apply(void 0, [__assign.apply(void 0, _f.concat([(_j.sent())])), { name: errorCode, $metadata: deserializeMetadata(output) }]);
1019
- return [3, 13];
1020
+ response = __assign.apply(void 0, [__assign.apply(void 0, _f.concat([(_k.sent())])), { name: errorCode, $metadata: deserializeMetadata(output) }]);
1021
+ return [3, 15];
1020
1022
  case 10:
1021
1023
  _g = [{}];
1022
- return [4, deserializeAws_json1_1UnsupportedLanguagePairExceptionResponse(parsedOutput, context)];
1024
+ return [4, deserializeAws_json1_1TooManyRequestsExceptionResponse(parsedOutput, context)];
1023
1025
  case 11:
1024
- response = __assign.apply(void 0, [__assign.apply(void 0, _g.concat([(_j.sent())])), { name: errorCode, $metadata: deserializeMetadata(output) }]);
1025
- return [3, 13];
1026
+ response = __assign.apply(void 0, [__assign.apply(void 0, _g.concat([(_k.sent())])), { name: errorCode, $metadata: deserializeMetadata(output) }]);
1027
+ return [3, 15];
1026
1028
  case 12:
1029
+ _h = [{}];
1030
+ return [4, deserializeAws_json1_1UnsupportedLanguagePairExceptionResponse(parsedOutput, context)];
1031
+ case 13:
1032
+ response = __assign.apply(void 0, [__assign.apply(void 0, _h.concat([(_k.sent())])), { name: errorCode, $metadata: deserializeMetadata(output) }]);
1033
+ return [3, 15];
1034
+ case 14:
1027
1035
  parsedBody = parsedOutput.body;
1028
1036
  errorCode = parsedBody.code || parsedBody.Code || errorCode;
1029
1037
  response = __assign(__assign({}, parsedBody), { name: "" + errorCode, message: parsedBody.message || parsedBody.Message || errorCode, $fault: "client", $metadata: deserializeMetadata(output) });
1030
- _j.label = 13;
1031
- case 13:
1038
+ _k.label = 15;
1039
+ case 15:
1032
1040
  message = response.message || response.Message || errorCode;
1033
1041
  response.message = message;
1034
1042
  delete response.Message;
@@ -1501,7 +1509,10 @@ var serializeAws_json1_1ListTextTranslationJobsRequest = function (input, contex
1501
1509
  input.Filter !== null && { Filter: serializeAws_json1_1TextTranslationJobFilter(input.Filter, context) })), (input.MaxResults !== undefined && input.MaxResults !== null && { MaxResults: input.MaxResults })), (input.NextToken !== undefined && input.NextToken !== null && { NextToken: input.NextToken }));
1502
1510
  };
1503
1511
  var serializeAws_json1_1OutputDataConfig = function (input, context) {
1504
- return __assign({}, (input.S3Uri !== undefined && input.S3Uri !== null && { S3Uri: input.S3Uri }));
1512
+ return __assign(__assign({}, (input.EncryptionKey !== undefined &&
1513
+ input.EncryptionKey !== null && {
1514
+ EncryptionKey: serializeAws_json1_1EncryptionKey(input.EncryptionKey, context),
1515
+ })), (input.S3Uri !== undefined && input.S3Uri !== null && { S3Uri: input.S3Uri }));
1505
1516
  };
1506
1517
  var serializeAws_json1_1ParallelDataConfig = function (input, context) {
1507
1518
  return __assign(__assign({}, (input.Format !== undefined && input.Format !== null && { Format: input.Format })), (input.S3Uri !== undefined && input.S3Uri !== null && { S3Uri: input.S3Uri }));
@@ -1551,7 +1562,8 @@ var serializeAws_json1_1TargetLanguageCodeStringList = function (input, context)
1551
1562
  });
1552
1563
  };
1553
1564
  var serializeAws_json1_1TerminologyData = function (input, context) {
1554
- return __assign(__assign({}, (input.File !== undefined && input.File !== null && { File: context.base64Encoder(input.File) })), (input.Format !== undefined && input.Format !== null && { Format: input.Format }));
1565
+ return __assign(__assign(__assign({}, (input.Directionality !== undefined &&
1566
+ input.Directionality !== null && { Directionality: input.Directionality })), (input.File !== undefined && input.File !== null && { File: context.base64Encoder(input.File) })), (input.Format !== undefined && input.Format !== null && { Format: input.Format }));
1555
1567
  };
1556
1568
  var serializeAws_json1_1TextTranslationJobFilter = function (input, context) {
1557
1569
  return __assign(__assign(__assign(__assign({}, (input.JobName !== undefined && input.JobName !== null && { JobName: input.JobName })), (input.JobStatus !== undefined && input.JobStatus !== null && { JobStatus: input.JobStatus })), (input.SubmittedAfterTime !== undefined &&
@@ -1655,6 +1667,9 @@ var deserializeAws_json1_1GetParallelDataResponse = function (output, context) {
1655
1667
  };
1656
1668
  var deserializeAws_json1_1GetTerminologyResponse = function (output, context) {
1657
1669
  return {
1670
+ AuxiliaryDataLocation: output.AuxiliaryDataLocation !== undefined && output.AuxiliaryDataLocation !== null
1671
+ ? deserializeAws_json1_1TerminologyDataLocation(output.AuxiliaryDataLocation, context)
1672
+ : undefined,
1658
1673
  TerminologyDataLocation: output.TerminologyDataLocation !== undefined && output.TerminologyDataLocation !== null
1659
1674
  ? deserializeAws_json1_1TerminologyDataLocation(output.TerminologyDataLocation, context)
1660
1675
  : undefined,
@@ -1665,6 +1680,9 @@ var deserializeAws_json1_1GetTerminologyResponse = function (output, context) {
1665
1680
  };
1666
1681
  var deserializeAws_json1_1ImportTerminologyResponse = function (output, context) {
1667
1682
  return {
1683
+ AuxiliaryDataLocation: output.AuxiliaryDataLocation !== undefined && output.AuxiliaryDataLocation !== null
1684
+ ? deserializeAws_json1_1TerminologyDataLocation(output.AuxiliaryDataLocation, context)
1685
+ : undefined,
1668
1686
  TerminologyProperties: output.TerminologyProperties !== undefined && output.TerminologyProperties !== null
1669
1687
  ? deserializeAws_json1_1TerminologyProperties(output.TerminologyProperties, context)
1670
1688
  : undefined,
@@ -1744,6 +1762,9 @@ var deserializeAws_json1_1ListTextTranslationJobsResponse = function (output, co
1744
1762
  };
1745
1763
  var deserializeAws_json1_1OutputDataConfig = function (output, context) {
1746
1764
  return {
1765
+ EncryptionKey: output.EncryptionKey !== undefined && output.EncryptionKey !== null
1766
+ ? deserializeAws_json1_1EncryptionKey(output.EncryptionKey, context)
1767
+ : undefined,
1747
1768
  S3Uri: __expectString(output.S3Uri),
1748
1769
  };
1749
1770
  };
@@ -1863,14 +1884,18 @@ var deserializeAws_json1_1TerminologyProperties = function (output, context) {
1863
1884
  ? __expectNonNull(__parseEpochTimestamp(__expectNumber(output.CreatedAt)))
1864
1885
  : undefined,
1865
1886
  Description: __expectString(output.Description),
1887
+ Directionality: __expectString(output.Directionality),
1866
1888
  EncryptionKey: output.EncryptionKey !== undefined && output.EncryptionKey !== null
1867
1889
  ? deserializeAws_json1_1EncryptionKey(output.EncryptionKey, context)
1868
1890
  : undefined,
1891
+ Format: __expectString(output.Format),
1869
1892
  LastUpdatedAt: output.LastUpdatedAt !== undefined && output.LastUpdatedAt !== null
1870
1893
  ? __expectNonNull(__parseEpochTimestamp(__expectNumber(output.LastUpdatedAt)))
1871
1894
  : undefined,
1895
+ Message: __expectString(output.Message),
1872
1896
  Name: __expectString(output.Name),
1873
1897
  SizeBytes: __expectInt32(output.SizeBytes),
1898
+ SkippedTermCount: __expectInt32(output.SkippedTermCount),
1874
1899
  SourceLanguageCode: __expectString(output.SourceLanguageCode),
1875
1900
  TargetLanguageCodes: output.TargetLanguageCodes !== undefined && output.TargetLanguageCodes !== null
1876
1901
  ? deserializeAws_json1_1LanguageCodeStringList(output.TargetLanguageCodes, context)
@@ -1,6 +1,7 @@
1
1
  import { __assign } from "tslib";
2
2
  import packageInfo from "../package.json";
3
3
  import { Sha256 } from "@aws-crypto/sha256-browser";
4
+ import { DEFAULT_USE_DUALSTACK_ENDPOINT, DEFAULT_USE_FIPS_ENDPOINT } from "@aws-sdk/config-resolver";
4
5
  import { FetchHttpHandler, streamCollector } from "@aws-sdk/fetch-http-handler";
5
6
  import { invalidProvider } from "@aws-sdk/invalid-dependency";
6
7
  import { DEFAULT_MAX_ATTEMPTS, DEFAULT_RETRY_MODE } from "@aws-sdk/middleware-retry";
@@ -10,7 +11,7 @@ import { defaultUserAgent } from "@aws-sdk/util-user-agent-browser";
10
11
  import { fromUtf8, toUtf8 } from "@aws-sdk/util-utf8-browser";
11
12
  import { getRuntimeConfig as getSharedRuntimeConfig } from "./runtimeConfig.shared";
12
13
  export var getRuntimeConfig = function (config) {
13
- var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o;
14
+ var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o, _p, _q;
14
15
  var clientSharedValues = getSharedRuntimeConfig(config);
15
- return __assign(__assign(__assign({}, clientSharedValues), config), { runtime: "browser", base64Decoder: (_a = config === null || config === void 0 ? void 0 : config.base64Decoder) !== null && _a !== void 0 ? _a : fromBase64, base64Encoder: (_b = config === null || config === void 0 ? void 0 : config.base64Encoder) !== null && _b !== void 0 ? _b : toBase64, bodyLengthChecker: (_c = config === null || config === void 0 ? void 0 : config.bodyLengthChecker) !== null && _c !== void 0 ? _c : calculateBodyLength, credentialDefaultProvider: (_d = config === null || config === void 0 ? void 0 : config.credentialDefaultProvider) !== null && _d !== void 0 ? _d : (function (_) { return function () { return Promise.reject(new Error("Credential is missing")); }; }), defaultUserAgentProvider: (_e = config === null || config === void 0 ? void 0 : config.defaultUserAgentProvider) !== null && _e !== void 0 ? _e : defaultUserAgent({ serviceId: clientSharedValues.serviceId, clientVersion: packageInfo.version }), maxAttempts: (_f = config === null || config === void 0 ? void 0 : config.maxAttempts) !== null && _f !== void 0 ? _f : DEFAULT_MAX_ATTEMPTS, region: (_g = config === null || config === void 0 ? void 0 : config.region) !== null && _g !== void 0 ? _g : invalidProvider("Region is missing"), requestHandler: (_h = config === null || config === void 0 ? void 0 : config.requestHandler) !== null && _h !== void 0 ? _h : new FetchHttpHandler(), retryMode: (_j = config === null || config === void 0 ? void 0 : config.retryMode) !== null && _j !== void 0 ? _j : (function () { return Promise.resolve(DEFAULT_RETRY_MODE); }), sha256: (_k = config === null || config === void 0 ? void 0 : config.sha256) !== null && _k !== void 0 ? _k : Sha256, streamCollector: (_l = config === null || config === void 0 ? void 0 : config.streamCollector) !== null && _l !== void 0 ? _l : streamCollector, utf8Decoder: (_m = config === null || config === void 0 ? void 0 : config.utf8Decoder) !== null && _m !== void 0 ? _m : fromUtf8, utf8Encoder: (_o = config === null || config === void 0 ? void 0 : config.utf8Encoder) !== null && _o !== void 0 ? _o : toUtf8 });
16
+ return __assign(__assign(__assign({}, clientSharedValues), config), { runtime: "browser", base64Decoder: (_a = config === null || config === void 0 ? void 0 : config.base64Decoder) !== null && _a !== void 0 ? _a : fromBase64, base64Encoder: (_b = config === null || config === void 0 ? void 0 : config.base64Encoder) !== null && _b !== void 0 ? _b : toBase64, bodyLengthChecker: (_c = config === null || config === void 0 ? void 0 : config.bodyLengthChecker) !== null && _c !== void 0 ? _c : calculateBodyLength, credentialDefaultProvider: (_d = config === null || config === void 0 ? void 0 : config.credentialDefaultProvider) !== null && _d !== void 0 ? _d : (function (_) { return function () { return Promise.reject(new Error("Credential is missing")); }; }), defaultUserAgentProvider: (_e = config === null || config === void 0 ? void 0 : config.defaultUserAgentProvider) !== null && _e !== void 0 ? _e : defaultUserAgent({ serviceId: clientSharedValues.serviceId, clientVersion: packageInfo.version }), maxAttempts: (_f = config === null || config === void 0 ? void 0 : config.maxAttempts) !== null && _f !== void 0 ? _f : DEFAULT_MAX_ATTEMPTS, region: (_g = config === null || config === void 0 ? void 0 : config.region) !== null && _g !== void 0 ? _g : invalidProvider("Region is missing"), requestHandler: (_h = config === null || config === void 0 ? void 0 : config.requestHandler) !== null && _h !== void 0 ? _h : new FetchHttpHandler(), retryMode: (_j = config === null || config === void 0 ? void 0 : config.retryMode) !== null && _j !== void 0 ? _j : (function () { return Promise.resolve(DEFAULT_RETRY_MODE); }), sha256: (_k = config === null || config === void 0 ? void 0 : config.sha256) !== null && _k !== void 0 ? _k : Sha256, streamCollector: (_l = config === null || config === void 0 ? void 0 : config.streamCollector) !== null && _l !== void 0 ? _l : streamCollector, useDualstackEndpoint: (_m = config === null || config === void 0 ? void 0 : config.useDualstackEndpoint) !== null && _m !== void 0 ? _m : (function () { return Promise.resolve(DEFAULT_USE_DUALSTACK_ENDPOINT); }), useFipsEndpoint: (_o = config === null || config === void 0 ? void 0 : config.useFipsEndpoint) !== null && _o !== void 0 ? _o : (function () { return Promise.resolve(DEFAULT_USE_FIPS_ENDPOINT); }), utf8Decoder: (_p = config === null || config === void 0 ? void 0 : config.utf8Decoder) !== null && _p !== void 0 ? _p : fromUtf8, utf8Encoder: (_q = config === null || config === void 0 ? void 0 : config.utf8Encoder) !== null && _q !== void 0 ? _q : toUtf8 });
16
17
  };
@@ -1,7 +1,7 @@
1
1
  import { __assign } from "tslib";
2
2
  import packageInfo from "../package.json";
3
3
  import { decorateDefaultCredentialProvider } from "@aws-sdk/client-sts";
4
- import { NODE_REGION_CONFIG_FILE_OPTIONS, NODE_REGION_CONFIG_OPTIONS } from "@aws-sdk/config-resolver";
4
+ import { NODE_REGION_CONFIG_FILE_OPTIONS, NODE_REGION_CONFIG_OPTIONS, NODE_USE_DUALSTACK_ENDPOINT_CONFIG_OPTIONS, NODE_USE_FIPS_ENDPOINT_CONFIG_OPTIONS, } from "@aws-sdk/config-resolver";
5
5
  import { defaultProvider as credentialDefaultProvider } from "@aws-sdk/credential-provider-node";
6
6
  import { Hash } from "@aws-sdk/hash-node";
7
7
  import { NODE_MAX_ATTEMPT_CONFIG_OPTIONS, NODE_RETRY_MODE_CONFIG_OPTIONS } from "@aws-sdk/middleware-retry";
@@ -14,8 +14,8 @@ import { fromUtf8, toUtf8 } from "@aws-sdk/util-utf8-node";
14
14
  import { getRuntimeConfig as getSharedRuntimeConfig } from "./runtimeConfig.shared";
15
15
  import { emitWarningIfUnsupportedVersion } from "@aws-sdk/smithy-client";
16
16
  export var getRuntimeConfig = function (config) {
17
- var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o;
17
+ var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o, _p, _q;
18
18
  emitWarningIfUnsupportedVersion(process.version);
19
19
  var clientSharedValues = getSharedRuntimeConfig(config);
20
- return __assign(__assign(__assign({}, clientSharedValues), config), { runtime: "node", base64Decoder: (_a = config === null || config === void 0 ? void 0 : config.base64Decoder) !== null && _a !== void 0 ? _a : fromBase64, base64Encoder: (_b = config === null || config === void 0 ? void 0 : config.base64Encoder) !== null && _b !== void 0 ? _b : toBase64, bodyLengthChecker: (_c = config === null || config === void 0 ? void 0 : config.bodyLengthChecker) !== null && _c !== void 0 ? _c : calculateBodyLength, credentialDefaultProvider: (_d = config === null || config === void 0 ? void 0 : config.credentialDefaultProvider) !== null && _d !== void 0 ? _d : decorateDefaultCredentialProvider(credentialDefaultProvider), defaultUserAgentProvider: (_e = config === null || config === void 0 ? void 0 : config.defaultUserAgentProvider) !== null && _e !== void 0 ? _e : defaultUserAgent({ serviceId: clientSharedValues.serviceId, clientVersion: packageInfo.version }), maxAttempts: (_f = config === null || config === void 0 ? void 0 : config.maxAttempts) !== null && _f !== void 0 ? _f : loadNodeConfig(NODE_MAX_ATTEMPT_CONFIG_OPTIONS), region: (_g = config === null || config === void 0 ? void 0 : config.region) !== null && _g !== void 0 ? _g : loadNodeConfig(NODE_REGION_CONFIG_OPTIONS, NODE_REGION_CONFIG_FILE_OPTIONS), requestHandler: (_h = config === null || config === void 0 ? void 0 : config.requestHandler) !== null && _h !== void 0 ? _h : new NodeHttpHandler(), retryMode: (_j = config === null || config === void 0 ? void 0 : config.retryMode) !== null && _j !== void 0 ? _j : loadNodeConfig(NODE_RETRY_MODE_CONFIG_OPTIONS), sha256: (_k = config === null || config === void 0 ? void 0 : config.sha256) !== null && _k !== void 0 ? _k : Hash.bind(null, "sha256"), streamCollector: (_l = config === null || config === void 0 ? void 0 : config.streamCollector) !== null && _l !== void 0 ? _l : streamCollector, utf8Decoder: (_m = config === null || config === void 0 ? void 0 : config.utf8Decoder) !== null && _m !== void 0 ? _m : fromUtf8, utf8Encoder: (_o = config === null || config === void 0 ? void 0 : config.utf8Encoder) !== null && _o !== void 0 ? _o : toUtf8 });
20
+ return __assign(__assign(__assign({}, clientSharedValues), config), { runtime: "node", base64Decoder: (_a = config === null || config === void 0 ? void 0 : config.base64Decoder) !== null && _a !== void 0 ? _a : fromBase64, base64Encoder: (_b = config === null || config === void 0 ? void 0 : config.base64Encoder) !== null && _b !== void 0 ? _b : toBase64, bodyLengthChecker: (_c = config === null || config === void 0 ? void 0 : config.bodyLengthChecker) !== null && _c !== void 0 ? _c : calculateBodyLength, credentialDefaultProvider: (_d = config === null || config === void 0 ? void 0 : config.credentialDefaultProvider) !== null && _d !== void 0 ? _d : decorateDefaultCredentialProvider(credentialDefaultProvider), defaultUserAgentProvider: (_e = config === null || config === void 0 ? void 0 : config.defaultUserAgentProvider) !== null && _e !== void 0 ? _e : defaultUserAgent({ serviceId: clientSharedValues.serviceId, clientVersion: packageInfo.version }), maxAttempts: (_f = config === null || config === void 0 ? void 0 : config.maxAttempts) !== null && _f !== void 0 ? _f : loadNodeConfig(NODE_MAX_ATTEMPT_CONFIG_OPTIONS), region: (_g = config === null || config === void 0 ? void 0 : config.region) !== null && _g !== void 0 ? _g : loadNodeConfig(NODE_REGION_CONFIG_OPTIONS, NODE_REGION_CONFIG_FILE_OPTIONS), requestHandler: (_h = config === null || config === void 0 ? void 0 : config.requestHandler) !== null && _h !== void 0 ? _h : new NodeHttpHandler(), retryMode: (_j = config === null || config === void 0 ? void 0 : config.retryMode) !== null && _j !== void 0 ? _j : loadNodeConfig(NODE_RETRY_MODE_CONFIG_OPTIONS), sha256: (_k = config === null || config === void 0 ? void 0 : config.sha256) !== null && _k !== void 0 ? _k : Hash.bind(null, "sha256"), streamCollector: (_l = config === null || config === void 0 ? void 0 : config.streamCollector) !== null && _l !== void 0 ? _l : streamCollector, useDualstackEndpoint: (_m = config === null || config === void 0 ? void 0 : config.useDualstackEndpoint) !== null && _m !== void 0 ? _m : loadNodeConfig(NODE_USE_DUALSTACK_ENDPOINT_CONFIG_OPTIONS), useFipsEndpoint: (_o = config === null || config === void 0 ? void 0 : config.useFipsEndpoint) !== null && _o !== void 0 ? _o : loadNodeConfig(NODE_USE_FIPS_ENDPOINT_CONFIG_OPTIONS), utf8Decoder: (_p = config === null || config === void 0 ? void 0 : config.utf8Decoder) !== null && _p !== void 0 ? _p : fromUtf8, utf8Encoder: (_q = config === null || config === void 0 ? void 0 : config.utf8Encoder) !== null && _q !== void 0 ? _q : toUtf8 });
21
21
  };
@@ -21,9 +21,9 @@ import { TranslateClient } from "./TranslateClient";
21
21
  export declare class Translate extends TranslateClient {
22
22
  /**
23
23
  * <p>Creates a parallel data resource in Amazon Translate by importing an input file from
24
- * Amazon S3. Parallel data files contain examples of source phrases and their translations from
25
- * your translation memory. By adding parallel data, you can influence the style, tone, and word
26
- * choice in your translation output.</p>
24
+ * Amazon S3. Parallel data files contain examples that show how you want segments of text to be
25
+ * translated. By adding parallel data, you can influence the style, tone, and word choice in
26
+ * your translation output.</p>
27
27
  */
28
28
  createParallelData(args: CreateParallelDataCommandInput, options?: __HttpHandlerOptions): Promise<CreateParallelDataCommandOutput>;
29
29
  createParallelData(args: CreateParallelDataCommandInput, cb: (err: any, data?: CreateParallelDataCommandOutput) => void): void;
@@ -41,7 +41,7 @@ export declare class Translate extends TranslateClient {
41
41
  deleteTerminology(args: DeleteTerminologyCommandInput, cb: (err: any, data?: DeleteTerminologyCommandOutput) => void): void;
42
42
  deleteTerminology(args: DeleteTerminologyCommandInput, options: __HttpHandlerOptions, cb: (err: any, data?: DeleteTerminologyCommandOutput) => void): void;
43
43
  /**
44
- * <p>Gets the properties associated with an asycnhronous batch translation job including name,
44
+ * <p>Gets the properties associated with an asynchronous batch translation job including name,
45
45
  * ID, status, source and target languages, input/output S3 buckets, and so on.</p>
46
46
  */
47
47
  describeTextTranslationJob(args: DescribeTextTranslationJobCommandInput, options?: __HttpHandlerOptions): Promise<DescribeTextTranslationJobCommandOutput>;
@@ -90,6 +90,14 @@ export interface ClientDefaults extends Partial<__SmithyResolvedConfiguration<__
90
90
  * Optional logger for logging debug/info/warn/error.
91
91
  */
92
92
  logger?: __Logger;
93
+ /**
94
+ * Enables IPv6/IPv4 dualstack endpoint.
95
+ */
96
+ useDualstackEndpoint?: boolean | __Provider<boolean>;
97
+ /**
98
+ * Enables FIPS compatible endpoints.
99
+ */
100
+ useFipsEndpoint?: boolean | __Provider<boolean>;
93
101
  /**
94
102
  * Unique service identifier.
95
103
  * @internal
@@ -8,9 +8,9 @@ export interface CreateParallelDataCommandOutput extends CreateParallelDataRespo
8
8
  }
9
9
  /**
10
10
  * <p>Creates a parallel data resource in Amazon Translate by importing an input file from
11
- * Amazon S3. Parallel data files contain examples of source phrases and their translations from
12
- * your translation memory. By adding parallel data, you can influence the style, tone, and word
13
- * choice in your translation output.</p>
11
+ * Amazon S3. Parallel data files contain examples that show how you want segments of text to be
12
+ * translated. By adding parallel data, you can influence the style, tone, and word choice in
13
+ * your translation output.</p>
14
14
  * @example
15
15
  * Use a bare-bones client and the command you need to make an API call.
16
16
  * ```javascript
@@ -23,7 +23,7 @@ export interface CreateParallelDataCommandOutput extends CreateParallelDataRespo
23
23
  *
24
24
  * @see {@link CreateParallelDataCommandInput} for command's `input` shape.
25
25
  * @see {@link CreateParallelDataCommandOutput} for command's `response` shape.
26
- * @see {@link TranslateClientResolvedConfig | config} for command's `input` shape.
26
+ * @see {@link TranslateClientResolvedConfig | config} for TranslateClient's `config` shape.
27
27
  *
28
28
  */
29
29
  export declare class CreateParallelDataCommand extends $Command<CreateParallelDataCommandInput, CreateParallelDataCommandOutput, TranslateClientResolvedConfig> {
@@ -20,7 +20,7 @@ export interface DeleteParallelDataCommandOutput extends DeleteParallelDataRespo
20
20
  *
21
21
  * @see {@link DeleteParallelDataCommandInput} for command's `input` shape.
22
22
  * @see {@link DeleteParallelDataCommandOutput} for command's `response` shape.
23
- * @see {@link TranslateClientResolvedConfig | config} for command's `input` shape.
23
+ * @see {@link TranslateClientResolvedConfig | config} for TranslateClient's `config` shape.
24
24
  *
25
25
  */
26
26
  export declare class DeleteParallelDataCommand extends $Command<DeleteParallelDataCommandInput, DeleteParallelDataCommandOutput, TranslateClientResolvedConfig> {
@@ -20,7 +20,7 @@ export interface DeleteTerminologyCommandOutput extends __MetadataBearer {
20
20
  *
21
21
  * @see {@link DeleteTerminologyCommandInput} for command's `input` shape.
22
22
  * @see {@link DeleteTerminologyCommandOutput} for command's `response` shape.
23
- * @see {@link TranslateClientResolvedConfig | config} for command's `input` shape.
23
+ * @see {@link TranslateClientResolvedConfig | config} for TranslateClient's `config` shape.
24
24
  *
25
25
  */
26
26
  export declare class DeleteTerminologyCommand extends $Command<DeleteTerminologyCommandInput, DeleteTerminologyCommandOutput, TranslateClientResolvedConfig> {
@@ -7,7 +7,7 @@ export interface DescribeTextTranslationJobCommandInput extends DescribeTextTran
7
7
  export interface DescribeTextTranslationJobCommandOutput extends DescribeTextTranslationJobResponse, __MetadataBearer {
8
8
  }
9
9
  /**
10
- * <p>Gets the properties associated with an asycnhronous batch translation job including name,
10
+ * <p>Gets the properties associated with an asynchronous batch translation job including name,
11
11
  * ID, status, source and target languages, input/output S3 buckets, and so on.</p>
12
12
  * @example
13
13
  * Use a bare-bones client and the command you need to make an API call.
@@ -21,7 +21,7 @@ export interface DescribeTextTranslationJobCommandOutput extends DescribeTextTra
21
21
  *
22
22
  * @see {@link DescribeTextTranslationJobCommandInput} for command's `input` shape.
23
23
  * @see {@link DescribeTextTranslationJobCommandOutput} for command's `response` shape.
24
- * @see {@link TranslateClientResolvedConfig | config} for command's `input` shape.
24
+ * @see {@link TranslateClientResolvedConfig | config} for TranslateClient's `config` shape.
25
25
  *
26
26
  */
27
27
  export declare class DescribeTextTranslationJobCommand extends $Command<DescribeTextTranslationJobCommandInput, DescribeTextTranslationJobCommandOutput, TranslateClientResolvedConfig> {
@@ -20,7 +20,7 @@ export interface GetParallelDataCommandOutput extends GetParallelDataResponse, _
20
20
  *
21
21
  * @see {@link GetParallelDataCommandInput} for command's `input` shape.
22
22
  * @see {@link GetParallelDataCommandOutput} for command's `response` shape.
23
- * @see {@link TranslateClientResolvedConfig | config} for command's `input` shape.
23
+ * @see {@link TranslateClientResolvedConfig | config} for TranslateClient's `config` shape.
24
24
  *
25
25
  */
26
26
  export declare class GetParallelDataCommand extends $Command<GetParallelDataCommandInput, GetParallelDataCommandOutput, TranslateClientResolvedConfig> {
@@ -20,7 +20,7 @@ export interface GetTerminologyCommandOutput extends GetTerminologyResponse, __M
20
20
  *
21
21
  * @see {@link GetTerminologyCommandInput} for command's `input` shape.
22
22
  * @see {@link GetTerminologyCommandOutput} for command's `response` shape.
23
- * @see {@link TranslateClientResolvedConfig | config} for command's `input` shape.
23
+ * @see {@link TranslateClientResolvedConfig | config} for TranslateClient's `config` shape.
24
24
  *
25
25
  */
26
26
  export declare class GetTerminologyCommand extends $Command<GetTerminologyCommandInput, GetTerminologyCommandOutput, TranslateClientResolvedConfig> {
@@ -27,7 +27,7 @@ export interface ImportTerminologyCommandOutput extends ImportTerminologyRespons
27
27
  *
28
28
  * @see {@link ImportTerminologyCommandInput} for command's `input` shape.
29
29
  * @see {@link ImportTerminologyCommandOutput} for command's `response` shape.
30
- * @see {@link TranslateClientResolvedConfig | config} for command's `input` shape.
30
+ * @see {@link TranslateClientResolvedConfig | config} for TranslateClient's `config` shape.
31
31
  *
32
32
  */
33
33
  export declare class ImportTerminologyCommand extends $Command<ImportTerminologyCommandInput, ImportTerminologyCommandOutput, TranslateClientResolvedConfig> {
@@ -20,7 +20,7 @@ export interface ListParallelDataCommandOutput extends ListParallelDataResponse,
20
20
  *
21
21
  * @see {@link ListParallelDataCommandInput} for command's `input` shape.
22
22
  * @see {@link ListParallelDataCommandOutput} for command's `response` shape.
23
- * @see {@link TranslateClientResolvedConfig | config} for command's `input` shape.
23
+ * @see {@link TranslateClientResolvedConfig | config} for TranslateClient's `config` shape.
24
24
  *
25
25
  */
26
26
  export declare class ListParallelDataCommand extends $Command<ListParallelDataCommandInput, ListParallelDataCommandOutput, TranslateClientResolvedConfig> {
@@ -20,7 +20,7 @@ export interface ListTerminologiesCommandOutput extends ListTerminologiesRespons
20
20
  *
21
21
  * @see {@link ListTerminologiesCommandInput} for command's `input` shape.
22
22
  * @see {@link ListTerminologiesCommandOutput} for command's `response` shape.
23
- * @see {@link TranslateClientResolvedConfig | config} for command's `input` shape.
23
+ * @see {@link TranslateClientResolvedConfig | config} for TranslateClient's `config` shape.
24
24
  *
25
25
  */
26
26
  export declare class ListTerminologiesCommand extends $Command<ListTerminologiesCommandInput, ListTerminologiesCommandOutput, TranslateClientResolvedConfig> {
@@ -20,7 +20,7 @@ export interface ListTextTranslationJobsCommandOutput extends ListTextTranslatio
20
20
  *
21
21
  * @see {@link ListTextTranslationJobsCommandInput} for command's `input` shape.
22
22
  * @see {@link ListTextTranslationJobsCommandOutput} for command's `response` shape.
23
- * @see {@link TranslateClientResolvedConfig | config} for command's `input` shape.
23
+ * @see {@link TranslateClientResolvedConfig | config} for TranslateClient's `config` shape.
24
24
  *
25
25
  */
26
26
  export declare class ListTextTranslationJobsCommand extends $Command<ListTextTranslationJobsCommandInput, ListTextTranslationJobsCommandOutput, TranslateClientResolvedConfig> {
@@ -27,7 +27,7 @@ export interface StartTextTranslationJobCommandOutput extends StartTextTranslati
27
27
  *
28
28
  * @see {@link StartTextTranslationJobCommandInput} for command's `input` shape.
29
29
  * @see {@link StartTextTranslationJobCommandOutput} for command's `response` shape.
30
- * @see {@link TranslateClientResolvedConfig | config} for command's `input` shape.
30
+ * @see {@link TranslateClientResolvedConfig | config} for TranslateClient's `config` shape.
31
31
  *
32
32
  */
33
33
  export declare class StartTextTranslationJobCommand extends $Command<StartTextTranslationJobCommandInput, StartTextTranslationJobCommandOutput, TranslateClientResolvedConfig> {
@@ -26,7 +26,7 @@ export interface StopTextTranslationJobCommandOutput extends StopTextTranslation
26
26
  *
27
27
  * @see {@link StopTextTranslationJobCommandInput} for command's `input` shape.
28
28
  * @see {@link StopTextTranslationJobCommandOutput} for command's `response` shape.
29
- * @see {@link TranslateClientResolvedConfig | config} for command's `input` shape.
29
+ * @see {@link TranslateClientResolvedConfig | config} for TranslateClient's `config` shape.
30
30
  *
31
31
  */
32
32
  export declare class StopTextTranslationJobCommand extends $Command<StopTextTranslationJobCommandInput, StopTextTranslationJobCommandOutput, TranslateClientResolvedConfig> {
@@ -21,7 +21,7 @@ export interface TranslateTextCommandOutput extends TranslateTextResponse, __Met
21
21
  *
22
22
  * @see {@link TranslateTextCommandInput} for command's `input` shape.
23
23
  * @see {@link TranslateTextCommandOutput} for command's `response` shape.
24
- * @see {@link TranslateClientResolvedConfig | config} for command's `input` shape.
24
+ * @see {@link TranslateClientResolvedConfig | config} for TranslateClient's `config` shape.
25
25
  *
26
26
  */
27
27
  export declare class TranslateTextCommand extends $Command<TranslateTextCommandInput, TranslateTextCommandOutput, TranslateClientResolvedConfig> {
@@ -21,7 +21,7 @@ export interface UpdateParallelDataCommandOutput extends UpdateParallelDataRespo
21
21
  *
22
22
  * @see {@link UpdateParallelDataCommandInput} for command's `input` shape.
23
23
  * @see {@link UpdateParallelDataCommandOutput} for command's `response` shape.
24
- * @see {@link TranslateClientResolvedConfig | config} for command's `input` shape.
24
+ * @see {@link TranslateClientResolvedConfig | config} for TranslateClient's `config` shape.
25
25
  *
26
26
  */
27
27
  export declare class UpdateParallelDataCommand extends $Command<UpdateParallelDataCommandInput, UpdateParallelDataCommandOutput, TranslateClientResolvedConfig> {
@@ -0,0 +1,14 @@
1
+ export * from "./CreateParallelDataCommand";
2
+ export * from "./DeleteParallelDataCommand";
3
+ export * from "./DeleteTerminologyCommand";
4
+ export * from "./DescribeTextTranslationJobCommand";
5
+ export * from "./GetParallelDataCommand";
6
+ export * from "./GetTerminologyCommand";
7
+ export * from "./ImportTerminologyCommand";
8
+ export * from "./ListParallelDataCommand";
9
+ export * from "./ListTerminologiesCommand";
10
+ export * from "./ListTextTranslationJobsCommand";
11
+ export * from "./StartTextTranslationJobCommand";
12
+ export * from "./StopTextTranslationJobCommand";
13
+ export * from "./TranslateTextCommand";
14
+ export * from "./UpdateParallelDataCommand";
@@ -1,21 +1,5 @@
1
- export * from "./TranslateClient";
2
1
  export * from "./Translate";
3
- export * from "./commands/CreateParallelDataCommand";
4
- export * from "./commands/DeleteParallelDataCommand";
5
- export * from "./commands/DeleteTerminologyCommand";
6
- export * from "./commands/DescribeTextTranslationJobCommand";
7
- export * from "./commands/GetParallelDataCommand";
8
- export * from "./commands/GetTerminologyCommand";
9
- export * from "./commands/ImportTerminologyCommand";
10
- export * from "./commands/ListParallelDataCommand";
11
- export * from "./pagination/ListParallelDataPaginator";
12
- export * from "./commands/ListTerminologiesCommand";
13
- export * from "./pagination/ListTerminologiesPaginator";
14
- export * from "./commands/ListTextTranslationJobsCommand";
15
- export * from "./pagination/ListTextTranslationJobsPaginator";
16
- export * from "./commands/StartTextTranslationJobCommand";
17
- export * from "./commands/StopTextTranslationJobCommand";
18
- export * from "./commands/TranslateTextCommand";
19
- export * from "./commands/UpdateParallelDataCommand";
20
- export * from "./pagination/Interfaces";
21
- export * from "./models/index";
2
+ export * from "./TranslateClient";
3
+ export * from "./commands";
4
+ export * from "./models";
5
+ export * from "./pagination";