@aws-sdk/client-textract 3.50.0 → 3.53.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 (36) hide show
  1. package/CHANGELOG.md +28 -0
  2. package/dist-cjs/index.js +3 -0
  3. package/dist-cjs/models/TextractServiceException.js +11 -0
  4. package/dist-cjs/models/models_0.js +221 -2
  5. package/dist-cjs/protocols/Aws_json1_1.js +209 -766
  6. package/dist-es/index.js +1 -0
  7. package/dist-es/models/TextractServiceException.js +12 -0
  8. package/dist-es/models/models_0.js +206 -1
  9. package/dist-es/protocols/Aws_json1_1.js +387 -779
  10. package/dist-types/index.d.ts +1 -0
  11. package/dist-types/models/TextractServiceException.d.ts +10 -0
  12. package/dist-types/models/models_0.d.ts +105 -44
  13. package/dist-types/ts3.4/Textract.d.ts +55 -0
  14. package/dist-types/ts3.4/TextractClient.d.ts +83 -0
  15. package/dist-types/ts3.4/commands/AnalyzeDocumentCommand.d.ts +17 -0
  16. package/dist-types/ts3.4/commands/AnalyzeExpenseCommand.d.ts +17 -0
  17. package/dist-types/ts3.4/commands/AnalyzeIDCommand.d.ts +17 -0
  18. package/dist-types/ts3.4/commands/DetectDocumentTextCommand.d.ts +17 -0
  19. package/dist-types/ts3.4/commands/GetDocumentAnalysisCommand.d.ts +17 -0
  20. package/dist-types/ts3.4/commands/GetDocumentTextDetectionCommand.d.ts +17 -0
  21. package/dist-types/ts3.4/commands/GetExpenseAnalysisCommand.d.ts +17 -0
  22. package/dist-types/ts3.4/commands/StartDocumentAnalysisCommand.d.ts +17 -0
  23. package/dist-types/ts3.4/commands/StartDocumentTextDetectionCommand.d.ts +17 -0
  24. package/dist-types/ts3.4/commands/StartExpenseAnalysisCommand.d.ts +17 -0
  25. package/dist-types/ts3.4/commands/index.d.ts +10 -0
  26. package/dist-types/ts3.4/endpoints.d.ts +2 -0
  27. package/dist-types/ts3.4/index.d.ts +5 -0
  28. package/dist-types/ts3.4/models/TextractServiceException.d.ts +6 -0
  29. package/dist-types/ts3.4/models/index.d.ts +1 -0
  30. package/dist-types/ts3.4/models/models_0.d.ts +753 -0
  31. package/dist-types/ts3.4/protocols/Aws_json1_1.d.ts +32 -0
  32. package/dist-types/ts3.4/runtimeConfig.browser.d.ts +38 -0
  33. package/dist-types/ts3.4/runtimeConfig.d.ts +38 -0
  34. package/dist-types/ts3.4/runtimeConfig.native.d.ts +37 -0
  35. package/dist-types/ts3.4/runtimeConfig.shared.d.ts +11 -0
  36. package/package.json +33 -33
package/CHANGELOG.md CHANGED
@@ -3,6 +3,34 @@
3
3
  All notable changes to this project will be documented in this file.
4
4
  See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
5
5
 
6
+ # [3.53.0](https://github.com/aws/aws-sdk-js-v3/compare/v3.52.0...v3.53.0) (2022-02-24)
7
+
8
+
9
+ ### Features
10
+
11
+ * **clients:** generate service exceptions as classes ([#3267](https://github.com/aws/aws-sdk-js-v3/issues/3267)) ([ca64fee](https://github.com/aws/aws-sdk-js-v3/commit/ca64feed3351c394c07dc26b782a5760a396a074))
12
+ * **clients:** update clients as of 2022/02/23 ([#3356](https://github.com/aws/aws-sdk-js-v3/issues/3356)) ([b6b2e25](https://github.com/aws/aws-sdk-js-v3/commit/b6b2e258add12c73d807483ca078401a6d84a12b))
13
+
14
+
15
+
16
+
17
+
18
+ # [3.52.0](https://github.com/aws/aws-sdk-js-v3/compare/v3.51.0...v3.52.0) (2022-02-18)
19
+
20
+ **Note:** Version bump only for package @aws-sdk/client-textract
21
+
22
+
23
+
24
+
25
+
26
+ # [3.51.0](https://github.com/aws/aws-sdk-js-v3/compare/v3.50.0...v3.51.0) (2022-02-12)
27
+
28
+ **Note:** Version bump only for package @aws-sdk/client-textract
29
+
30
+
31
+
32
+
33
+
6
34
  # [3.50.0](https://github.com/aws/aws-sdk-js-v3/compare/v3.49.0...v3.50.0) (2022-02-08)
7
35
 
8
36
  **Note:** Version bump only for package @aws-sdk/client-textract
package/dist-cjs/index.js CHANGED
@@ -1,7 +1,10 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.TextractServiceException = void 0;
3
4
  const tslib_1 = require("tslib");
4
5
  tslib_1.__exportStar(require("./Textract"), exports);
5
6
  tslib_1.__exportStar(require("./TextractClient"), exports);
6
7
  tslib_1.__exportStar(require("./commands"), exports);
7
8
  tslib_1.__exportStar(require("./models"), exports);
9
+ var TextractServiceException_1 = require("./models/TextractServiceException");
10
+ Object.defineProperty(exports, "TextractServiceException", { enumerable: true, get: function () { return TextractServiceException_1.TextractServiceException; } });
@@ -0,0 +1,11 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.TextractServiceException = void 0;
4
+ const smithy_client_1 = require("@aws-sdk/smithy-client");
5
+ class TextractServiceException extends smithy_client_1.ServiceException {
6
+ constructor(options) {
7
+ super(options);
8
+ Object.setPrototypeOf(this, TextractServiceException.prototype);
9
+ }
10
+ }
11
+ exports.TextractServiceException = TextractServiceException;
@@ -1,7 +1,23 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.StartDocumentAnalysisResponse = exports.StartDocumentAnalysisRequest = exports.OutputConfig = exports.NotificationChannel = exports.GetExpenseAnalysisResponse = exports.GetExpenseAnalysisRequest = exports.GetDocumentTextDetectionResponse = exports.GetDocumentTextDetectionRequest = exports.GetDocumentAnalysisResponse = exports.Warning = exports.JobStatus = exports.GetDocumentAnalysisRequest = exports.DocumentLocation = exports.DetectDocumentTextResponse = exports.DetectDocumentTextRequest = exports.AnalyzeIDResponse = exports.IdentityDocument = exports.IdentityDocumentField = exports.AnalyzeIDDetections = exports.NormalizedValue = exports.ValueType = exports.AnalyzeIDRequest = exports.AnalyzeExpenseResponse = exports.ExpenseDocument = exports.LineItemGroup = exports.LineItemFields = exports.ExpenseField = exports.ExpenseType = exports.ExpenseDetection = exports.AnalyzeExpenseRequest = exports.AnalyzeDocumentResponse = exports.HumanLoopActivationOutput = exports.DocumentMetadata = exports.Block = exports.TextType = exports.SelectionStatus = exports.Relationship = exports.RelationshipType = exports.Geometry = exports.Point = exports.BoundingBox = exports.EntityType = exports.BlockType = exports.AnalyzeDocumentRequest = exports.HumanLoopConfig = exports.HumanLoopDataAttributes = exports.ContentClassifier = exports.FeatureType = exports.Document = exports.S3Object = void 0;
4
- exports.StartExpenseAnalysisResponse = exports.StartExpenseAnalysisRequest = exports.StartDocumentTextDetectionResponse = exports.StartDocumentTextDetectionRequest = void 0;
3
+ exports.JobStatus = exports.GetDocumentAnalysisRequest = exports.DocumentLocation = exports.DetectDocumentTextResponse = exports.DetectDocumentTextRequest = exports.AnalyzeIDResponse = exports.IdentityDocument = exports.IdentityDocumentField = exports.AnalyzeIDDetections = exports.NormalizedValue = exports.ValueType = exports.AnalyzeIDRequest = exports.AnalyzeExpenseResponse = exports.ExpenseDocument = exports.LineItemGroup = exports.LineItemFields = exports.ExpenseField = exports.ExpenseType = exports.ExpenseDetection = exports.AnalyzeExpenseRequest = exports.UnsupportedDocumentException = exports.ThrottlingException = exports.ProvisionedThroughputExceededException = exports.InvalidS3ObjectException = exports.InvalidParameterException = exports.InternalServerError = exports.HumanLoopQuotaExceededException = exports.DocumentTooLargeException = exports.BadDocumentException = exports.AnalyzeDocumentResponse = exports.HumanLoopActivationOutput = exports.DocumentMetadata = exports.Block = exports.TextType = exports.SelectionStatus = exports.Relationship = exports.RelationshipType = exports.Geometry = exports.Point = exports.BoundingBox = exports.EntityType = exports.BlockType = exports.AnalyzeDocumentRequest = exports.HumanLoopConfig = exports.HumanLoopDataAttributes = exports.ContentClassifier = exports.FeatureType = exports.Document = exports.S3Object = exports.AccessDeniedException = void 0;
4
+ exports.StartExpenseAnalysisResponse = exports.StartExpenseAnalysisRequest = exports.StartDocumentTextDetectionResponse = exports.StartDocumentTextDetectionRequest = exports.StartDocumentAnalysisResponse = exports.StartDocumentAnalysisRequest = exports.OutputConfig = exports.NotificationChannel = exports.LimitExceededException = exports.IdempotentParameterMismatchException = exports.GetExpenseAnalysisResponse = exports.GetExpenseAnalysisRequest = exports.GetDocumentTextDetectionResponse = exports.GetDocumentTextDetectionRequest = exports.InvalidKMSKeyException = exports.InvalidJobIdException = exports.GetDocumentAnalysisResponse = exports.Warning = void 0;
5
+ const TextractServiceException_1 = require("./TextractServiceException");
6
+ class AccessDeniedException extends TextractServiceException_1.TextractServiceException {
7
+ constructor(opts) {
8
+ super({
9
+ name: "AccessDeniedException",
10
+ $fault: "client",
11
+ ...opts,
12
+ });
13
+ this.name = "AccessDeniedException";
14
+ this.$fault = "client";
15
+ Object.setPrototypeOf(this, AccessDeniedException.prototype);
16
+ this.Message = opts.Message;
17
+ this.Code = opts.Code;
18
+ }
19
+ }
20
+ exports.AccessDeniedException = AccessDeniedException;
5
21
  var S3Object;
6
22
  (function (S3Object) {
7
23
  S3Object.filterSensitiveLog = (obj) => ({
@@ -47,13 +63,16 @@ var BlockType;
47
63
  BlockType["CELL"] = "CELL";
48
64
  BlockType["KEY_VALUE_SET"] = "KEY_VALUE_SET";
49
65
  BlockType["LINE"] = "LINE";
66
+ BlockType["MERGED_CELL"] = "MERGED_CELL";
50
67
  BlockType["PAGE"] = "PAGE";
51
68
  BlockType["SELECTION_ELEMENT"] = "SELECTION_ELEMENT";
52
69
  BlockType["TABLE"] = "TABLE";
70
+ BlockType["TITLE"] = "TITLE";
53
71
  BlockType["WORD"] = "WORD";
54
72
  })(BlockType = exports.BlockType || (exports.BlockType = {}));
55
73
  var EntityType;
56
74
  (function (EntityType) {
75
+ EntityType["COLUMN_HEADER"] = "COLUMN_HEADER";
57
76
  EntityType["KEY"] = "KEY";
58
77
  EntityType["VALUE"] = "VALUE";
59
78
  })(EntityType = exports.EntityType || (exports.EntityType = {}));
@@ -79,6 +98,8 @@ var RelationshipType;
79
98
  (function (RelationshipType) {
80
99
  RelationshipType["CHILD"] = "CHILD";
81
100
  RelationshipType["COMPLEX_FEATURES"] = "COMPLEX_FEATURES";
101
+ RelationshipType["MERGED_CELL"] = "MERGED_CELL";
102
+ RelationshipType["TITLE"] = "TITLE";
82
103
  RelationshipType["VALUE"] = "VALUE";
83
104
  })(RelationshipType = exports.RelationshipType || (exports.RelationshipType = {}));
84
105
  var Relationship;
@@ -121,6 +142,144 @@ var AnalyzeDocumentResponse;
121
142
  ...obj,
122
143
  });
123
144
  })(AnalyzeDocumentResponse = exports.AnalyzeDocumentResponse || (exports.AnalyzeDocumentResponse = {}));
145
+ class BadDocumentException extends TextractServiceException_1.TextractServiceException {
146
+ constructor(opts) {
147
+ super({
148
+ name: "BadDocumentException",
149
+ $fault: "client",
150
+ ...opts,
151
+ });
152
+ this.name = "BadDocumentException";
153
+ this.$fault = "client";
154
+ Object.setPrototypeOf(this, BadDocumentException.prototype);
155
+ this.Message = opts.Message;
156
+ this.Code = opts.Code;
157
+ }
158
+ }
159
+ exports.BadDocumentException = BadDocumentException;
160
+ class DocumentTooLargeException extends TextractServiceException_1.TextractServiceException {
161
+ constructor(opts) {
162
+ super({
163
+ name: "DocumentTooLargeException",
164
+ $fault: "client",
165
+ ...opts,
166
+ });
167
+ this.name = "DocumentTooLargeException";
168
+ this.$fault = "client";
169
+ Object.setPrototypeOf(this, DocumentTooLargeException.prototype);
170
+ this.Message = opts.Message;
171
+ this.Code = opts.Code;
172
+ }
173
+ }
174
+ exports.DocumentTooLargeException = DocumentTooLargeException;
175
+ class HumanLoopQuotaExceededException extends TextractServiceException_1.TextractServiceException {
176
+ constructor(opts) {
177
+ super({
178
+ name: "HumanLoopQuotaExceededException",
179
+ $fault: "client",
180
+ ...opts,
181
+ });
182
+ this.name = "HumanLoopQuotaExceededException";
183
+ this.$fault = "client";
184
+ Object.setPrototypeOf(this, HumanLoopQuotaExceededException.prototype);
185
+ this.ResourceType = opts.ResourceType;
186
+ this.QuotaCode = opts.QuotaCode;
187
+ this.ServiceCode = opts.ServiceCode;
188
+ this.Message = opts.Message;
189
+ this.Code = opts.Code;
190
+ }
191
+ }
192
+ exports.HumanLoopQuotaExceededException = HumanLoopQuotaExceededException;
193
+ class InternalServerError extends TextractServiceException_1.TextractServiceException {
194
+ constructor(opts) {
195
+ super({
196
+ name: "InternalServerError",
197
+ $fault: "server",
198
+ ...opts,
199
+ });
200
+ this.name = "InternalServerError";
201
+ this.$fault = "server";
202
+ Object.setPrototypeOf(this, InternalServerError.prototype);
203
+ this.Message = opts.Message;
204
+ this.Code = opts.Code;
205
+ }
206
+ }
207
+ exports.InternalServerError = InternalServerError;
208
+ class InvalidParameterException extends TextractServiceException_1.TextractServiceException {
209
+ constructor(opts) {
210
+ super({
211
+ name: "InvalidParameterException",
212
+ $fault: "client",
213
+ ...opts,
214
+ });
215
+ this.name = "InvalidParameterException";
216
+ this.$fault = "client";
217
+ Object.setPrototypeOf(this, InvalidParameterException.prototype);
218
+ this.Message = opts.Message;
219
+ this.Code = opts.Code;
220
+ }
221
+ }
222
+ exports.InvalidParameterException = InvalidParameterException;
223
+ class InvalidS3ObjectException extends TextractServiceException_1.TextractServiceException {
224
+ constructor(opts) {
225
+ super({
226
+ name: "InvalidS3ObjectException",
227
+ $fault: "client",
228
+ ...opts,
229
+ });
230
+ this.name = "InvalidS3ObjectException";
231
+ this.$fault = "client";
232
+ Object.setPrototypeOf(this, InvalidS3ObjectException.prototype);
233
+ this.Message = opts.Message;
234
+ this.Code = opts.Code;
235
+ }
236
+ }
237
+ exports.InvalidS3ObjectException = InvalidS3ObjectException;
238
+ class ProvisionedThroughputExceededException extends TextractServiceException_1.TextractServiceException {
239
+ constructor(opts) {
240
+ super({
241
+ name: "ProvisionedThroughputExceededException",
242
+ $fault: "client",
243
+ ...opts,
244
+ });
245
+ this.name = "ProvisionedThroughputExceededException";
246
+ this.$fault = "client";
247
+ Object.setPrototypeOf(this, ProvisionedThroughputExceededException.prototype);
248
+ this.Message = opts.Message;
249
+ this.Code = opts.Code;
250
+ }
251
+ }
252
+ exports.ProvisionedThroughputExceededException = ProvisionedThroughputExceededException;
253
+ class ThrottlingException extends TextractServiceException_1.TextractServiceException {
254
+ constructor(opts) {
255
+ super({
256
+ name: "ThrottlingException",
257
+ $fault: "server",
258
+ ...opts,
259
+ });
260
+ this.name = "ThrottlingException";
261
+ this.$fault = "server";
262
+ Object.setPrototypeOf(this, ThrottlingException.prototype);
263
+ this.Message = opts.Message;
264
+ this.Code = opts.Code;
265
+ }
266
+ }
267
+ exports.ThrottlingException = ThrottlingException;
268
+ class UnsupportedDocumentException extends TextractServiceException_1.TextractServiceException {
269
+ constructor(opts) {
270
+ super({
271
+ name: "UnsupportedDocumentException",
272
+ $fault: "client",
273
+ ...opts,
274
+ });
275
+ this.name = "UnsupportedDocumentException";
276
+ this.$fault = "client";
277
+ Object.setPrototypeOf(this, UnsupportedDocumentException.prototype);
278
+ this.Message = opts.Message;
279
+ this.Code = opts.Code;
280
+ }
281
+ }
282
+ exports.UnsupportedDocumentException = UnsupportedDocumentException;
124
283
  var AnalyzeExpenseRequest;
125
284
  (function (AnalyzeExpenseRequest) {
126
285
  AnalyzeExpenseRequest.filterSensitiveLog = (obj) => ({
@@ -252,6 +411,36 @@ var GetDocumentAnalysisResponse;
252
411
  ...obj,
253
412
  });
254
413
  })(GetDocumentAnalysisResponse = exports.GetDocumentAnalysisResponse || (exports.GetDocumentAnalysisResponse = {}));
414
+ class InvalidJobIdException extends TextractServiceException_1.TextractServiceException {
415
+ constructor(opts) {
416
+ super({
417
+ name: "InvalidJobIdException",
418
+ $fault: "client",
419
+ ...opts,
420
+ });
421
+ this.name = "InvalidJobIdException";
422
+ this.$fault = "client";
423
+ Object.setPrototypeOf(this, InvalidJobIdException.prototype);
424
+ this.Message = opts.Message;
425
+ this.Code = opts.Code;
426
+ }
427
+ }
428
+ exports.InvalidJobIdException = InvalidJobIdException;
429
+ class InvalidKMSKeyException extends TextractServiceException_1.TextractServiceException {
430
+ constructor(opts) {
431
+ super({
432
+ name: "InvalidKMSKeyException",
433
+ $fault: "client",
434
+ ...opts,
435
+ });
436
+ this.name = "InvalidKMSKeyException";
437
+ this.$fault = "client";
438
+ Object.setPrototypeOf(this, InvalidKMSKeyException.prototype);
439
+ this.Message = opts.Message;
440
+ this.Code = opts.Code;
441
+ }
442
+ }
443
+ exports.InvalidKMSKeyException = InvalidKMSKeyException;
255
444
  var GetDocumentTextDetectionRequest;
256
445
  (function (GetDocumentTextDetectionRequest) {
257
446
  GetDocumentTextDetectionRequest.filterSensitiveLog = (obj) => ({
@@ -276,6 +465,36 @@ var GetExpenseAnalysisResponse;
276
465
  ...obj,
277
466
  });
278
467
  })(GetExpenseAnalysisResponse = exports.GetExpenseAnalysisResponse || (exports.GetExpenseAnalysisResponse = {}));
468
+ class IdempotentParameterMismatchException extends TextractServiceException_1.TextractServiceException {
469
+ constructor(opts) {
470
+ super({
471
+ name: "IdempotentParameterMismatchException",
472
+ $fault: "client",
473
+ ...opts,
474
+ });
475
+ this.name = "IdempotentParameterMismatchException";
476
+ this.$fault = "client";
477
+ Object.setPrototypeOf(this, IdempotentParameterMismatchException.prototype);
478
+ this.Message = opts.Message;
479
+ this.Code = opts.Code;
480
+ }
481
+ }
482
+ exports.IdempotentParameterMismatchException = IdempotentParameterMismatchException;
483
+ class LimitExceededException extends TextractServiceException_1.TextractServiceException {
484
+ constructor(opts) {
485
+ super({
486
+ name: "LimitExceededException",
487
+ $fault: "client",
488
+ ...opts,
489
+ });
490
+ this.name = "LimitExceededException";
491
+ this.$fault = "client";
492
+ Object.setPrototypeOf(this, LimitExceededException.prototype);
493
+ this.Message = opts.Message;
494
+ this.Code = opts.Code;
495
+ }
496
+ }
497
+ exports.LimitExceededException = LimitExceededException;
279
498
  var NotificationChannel;
280
499
  (function (NotificationChannel) {
281
500
  NotificationChannel.filterSensitiveLog = (obj) => ({