@aws-sdk/client-textract 3.216.0 → 3.222.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/Textract.js +45 -0
- package/dist-cjs/commands/GetLendingAnalysisCommand.js +46 -0
- package/dist-cjs/commands/GetLendingAnalysisSummaryCommand.js +46 -0
- package/dist-cjs/commands/StartLendingAnalysisCommand.js +46 -0
- package/dist-cjs/commands/index.js +3 -0
- package/dist-cjs/endpoint/ruleset.js +1 -1
- package/dist-cjs/models/models_0.js +77 -1
- package/dist-cjs/protocols/Aws_json1_1.js +501 -1
- package/dist-es/Textract.js +45 -0
- package/dist-es/commands/GetLendingAnalysisCommand.js +42 -0
- package/dist-es/commands/GetLendingAnalysisSummaryCommand.js +42 -0
- package/dist-es/commands/StartLendingAnalysisCommand.js +42 -0
- package/dist-es/commands/index.js +3 -0
- package/dist-es/endpoint/ruleset.js +1 -1
- package/dist-es/models/models_0.js +57 -0
- package/dist-es/protocols/Aws_json1_1.js +494 -0
- package/dist-types/Textract.d.ts +72 -0
- package/dist-types/TextractClient.d.ts +5 -2
- package/dist-types/commands/GetLendingAnalysisCommand.d.ts +47 -0
- package/dist-types/commands/GetLendingAnalysisSummaryCommand.d.ts +48 -0
- package/dist-types/commands/StartLendingAnalysisCommand.d.ts +67 -0
- package/dist-types/commands/index.d.ts +3 -0
- package/dist-types/endpoint/EndpointParameters.d.ts +1 -1
- package/dist-types/models/models_0.d.ts +431 -10
- package/dist-types/protocols/Aws_json1_1.d.ts +9 -0
- package/dist-types/ts3.4/Textract.d.ts +51 -0
- package/dist-types/ts3.4/TextractClient.d.ts +20 -2
- package/dist-types/ts3.4/commands/GetLendingAnalysisCommand.d.ts +38 -0
- package/dist-types/ts3.4/commands/GetLendingAnalysisSummaryCommand.d.ts +41 -0
- package/dist-types/ts3.4/commands/StartLendingAnalysisCommand.d.ts +41 -0
- package/dist-types/ts3.4/commands/index.d.ts +3 -0
- package/dist-types/ts3.4/endpoint/EndpointParameters.d.ts +1 -1
- package/dist-types/ts3.4/models/models_0.d.ts +144 -0
- package/dist-types/ts3.4/protocols/Aws_json1_1.d.ts +36 -0
- package/package.json +29 -28
|
@@ -65,6 +65,24 @@ export const serializeAws_json1_1GetExpenseAnalysisCommand = async (input, conte
|
|
|
65
65
|
body = JSON.stringify(serializeAws_json1_1GetExpenseAnalysisRequest(input, context));
|
|
66
66
|
return buildHttpRpcRequest(context, headers, "/", undefined, body);
|
|
67
67
|
};
|
|
68
|
+
export const serializeAws_json1_1GetLendingAnalysisCommand = async (input, context) => {
|
|
69
|
+
const headers = {
|
|
70
|
+
"content-type": "application/x-amz-json-1.1",
|
|
71
|
+
"x-amz-target": "Textract.GetLendingAnalysis",
|
|
72
|
+
};
|
|
73
|
+
let body;
|
|
74
|
+
body = JSON.stringify(serializeAws_json1_1GetLendingAnalysisRequest(input, context));
|
|
75
|
+
return buildHttpRpcRequest(context, headers, "/", undefined, body);
|
|
76
|
+
};
|
|
77
|
+
export const serializeAws_json1_1GetLendingAnalysisSummaryCommand = async (input, context) => {
|
|
78
|
+
const headers = {
|
|
79
|
+
"content-type": "application/x-amz-json-1.1",
|
|
80
|
+
"x-amz-target": "Textract.GetLendingAnalysisSummary",
|
|
81
|
+
};
|
|
82
|
+
let body;
|
|
83
|
+
body = JSON.stringify(serializeAws_json1_1GetLendingAnalysisSummaryRequest(input, context));
|
|
84
|
+
return buildHttpRpcRequest(context, headers, "/", undefined, body);
|
|
85
|
+
};
|
|
68
86
|
export const serializeAws_json1_1StartDocumentAnalysisCommand = async (input, context) => {
|
|
69
87
|
const headers = {
|
|
70
88
|
"content-type": "application/x-amz-json-1.1",
|
|
@@ -92,6 +110,15 @@ export const serializeAws_json1_1StartExpenseAnalysisCommand = async (input, con
|
|
|
92
110
|
body = JSON.stringify(serializeAws_json1_1StartExpenseAnalysisRequest(input, context));
|
|
93
111
|
return buildHttpRpcRequest(context, headers, "/", undefined, body);
|
|
94
112
|
};
|
|
113
|
+
export const serializeAws_json1_1StartLendingAnalysisCommand = async (input, context) => {
|
|
114
|
+
const headers = {
|
|
115
|
+
"content-type": "application/x-amz-json-1.1",
|
|
116
|
+
"x-amz-target": "Textract.StartLendingAnalysis",
|
|
117
|
+
};
|
|
118
|
+
let body;
|
|
119
|
+
body = JSON.stringify(serializeAws_json1_1StartLendingAnalysisRequest(input, context));
|
|
120
|
+
return buildHttpRpcRequest(context, headers, "/", undefined, body);
|
|
121
|
+
};
|
|
95
122
|
export const deserializeAws_json1_1AnalyzeDocumentCommand = async (output, context) => {
|
|
96
123
|
if (output.statusCode >= 300) {
|
|
97
124
|
return deserializeAws_json1_1AnalyzeDocumentCommandError(output, context);
|
|
@@ -485,6 +512,114 @@ const deserializeAws_json1_1GetExpenseAnalysisCommandError = async (output, cont
|
|
|
485
512
|
});
|
|
486
513
|
}
|
|
487
514
|
};
|
|
515
|
+
export const deserializeAws_json1_1GetLendingAnalysisCommand = async (output, context) => {
|
|
516
|
+
if (output.statusCode >= 300) {
|
|
517
|
+
return deserializeAws_json1_1GetLendingAnalysisCommandError(output, context);
|
|
518
|
+
}
|
|
519
|
+
const data = await parseBody(output.body, context);
|
|
520
|
+
let contents = {};
|
|
521
|
+
contents = deserializeAws_json1_1GetLendingAnalysisResponse(data, context);
|
|
522
|
+
const response = {
|
|
523
|
+
$metadata: deserializeMetadata(output),
|
|
524
|
+
...contents,
|
|
525
|
+
};
|
|
526
|
+
return Promise.resolve(response);
|
|
527
|
+
};
|
|
528
|
+
const deserializeAws_json1_1GetLendingAnalysisCommandError = async (output, context) => {
|
|
529
|
+
const parsedOutput = {
|
|
530
|
+
...output,
|
|
531
|
+
body: await parseErrorBody(output.body, context),
|
|
532
|
+
};
|
|
533
|
+
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
534
|
+
switch (errorCode) {
|
|
535
|
+
case "AccessDeniedException":
|
|
536
|
+
case "com.amazonaws.textract#AccessDeniedException":
|
|
537
|
+
throw await deserializeAws_json1_1AccessDeniedExceptionResponse(parsedOutput, context);
|
|
538
|
+
case "InternalServerError":
|
|
539
|
+
case "com.amazonaws.textract#InternalServerError":
|
|
540
|
+
throw await deserializeAws_json1_1InternalServerErrorResponse(parsedOutput, context);
|
|
541
|
+
case "InvalidJobIdException":
|
|
542
|
+
case "com.amazonaws.textract#InvalidJobIdException":
|
|
543
|
+
throw await deserializeAws_json1_1InvalidJobIdExceptionResponse(parsedOutput, context);
|
|
544
|
+
case "InvalidKMSKeyException":
|
|
545
|
+
case "com.amazonaws.textract#InvalidKMSKeyException":
|
|
546
|
+
throw await deserializeAws_json1_1InvalidKMSKeyExceptionResponse(parsedOutput, context);
|
|
547
|
+
case "InvalidParameterException":
|
|
548
|
+
case "com.amazonaws.textract#InvalidParameterException":
|
|
549
|
+
throw await deserializeAws_json1_1InvalidParameterExceptionResponse(parsedOutput, context);
|
|
550
|
+
case "InvalidS3ObjectException":
|
|
551
|
+
case "com.amazonaws.textract#InvalidS3ObjectException":
|
|
552
|
+
throw await deserializeAws_json1_1InvalidS3ObjectExceptionResponse(parsedOutput, context);
|
|
553
|
+
case "ProvisionedThroughputExceededException":
|
|
554
|
+
case "com.amazonaws.textract#ProvisionedThroughputExceededException":
|
|
555
|
+
throw await deserializeAws_json1_1ProvisionedThroughputExceededExceptionResponse(parsedOutput, context);
|
|
556
|
+
case "ThrottlingException":
|
|
557
|
+
case "com.amazonaws.textract#ThrottlingException":
|
|
558
|
+
throw await deserializeAws_json1_1ThrottlingExceptionResponse(parsedOutput, context);
|
|
559
|
+
default:
|
|
560
|
+
const parsedBody = parsedOutput.body;
|
|
561
|
+
throwDefaultError({
|
|
562
|
+
output,
|
|
563
|
+
parsedBody,
|
|
564
|
+
exceptionCtor: __BaseException,
|
|
565
|
+
errorCode,
|
|
566
|
+
});
|
|
567
|
+
}
|
|
568
|
+
};
|
|
569
|
+
export const deserializeAws_json1_1GetLendingAnalysisSummaryCommand = async (output, context) => {
|
|
570
|
+
if (output.statusCode >= 300) {
|
|
571
|
+
return deserializeAws_json1_1GetLendingAnalysisSummaryCommandError(output, context);
|
|
572
|
+
}
|
|
573
|
+
const data = await parseBody(output.body, context);
|
|
574
|
+
let contents = {};
|
|
575
|
+
contents = deserializeAws_json1_1GetLendingAnalysisSummaryResponse(data, context);
|
|
576
|
+
const response = {
|
|
577
|
+
$metadata: deserializeMetadata(output),
|
|
578
|
+
...contents,
|
|
579
|
+
};
|
|
580
|
+
return Promise.resolve(response);
|
|
581
|
+
};
|
|
582
|
+
const deserializeAws_json1_1GetLendingAnalysisSummaryCommandError = async (output, context) => {
|
|
583
|
+
const parsedOutput = {
|
|
584
|
+
...output,
|
|
585
|
+
body: await parseErrorBody(output.body, context),
|
|
586
|
+
};
|
|
587
|
+
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
588
|
+
switch (errorCode) {
|
|
589
|
+
case "AccessDeniedException":
|
|
590
|
+
case "com.amazonaws.textract#AccessDeniedException":
|
|
591
|
+
throw await deserializeAws_json1_1AccessDeniedExceptionResponse(parsedOutput, context);
|
|
592
|
+
case "InternalServerError":
|
|
593
|
+
case "com.amazonaws.textract#InternalServerError":
|
|
594
|
+
throw await deserializeAws_json1_1InternalServerErrorResponse(parsedOutput, context);
|
|
595
|
+
case "InvalidJobIdException":
|
|
596
|
+
case "com.amazonaws.textract#InvalidJobIdException":
|
|
597
|
+
throw await deserializeAws_json1_1InvalidJobIdExceptionResponse(parsedOutput, context);
|
|
598
|
+
case "InvalidKMSKeyException":
|
|
599
|
+
case "com.amazonaws.textract#InvalidKMSKeyException":
|
|
600
|
+
throw await deserializeAws_json1_1InvalidKMSKeyExceptionResponse(parsedOutput, context);
|
|
601
|
+
case "InvalidParameterException":
|
|
602
|
+
case "com.amazonaws.textract#InvalidParameterException":
|
|
603
|
+
throw await deserializeAws_json1_1InvalidParameterExceptionResponse(parsedOutput, context);
|
|
604
|
+
case "InvalidS3ObjectException":
|
|
605
|
+
case "com.amazonaws.textract#InvalidS3ObjectException":
|
|
606
|
+
throw await deserializeAws_json1_1InvalidS3ObjectExceptionResponse(parsedOutput, context);
|
|
607
|
+
case "ProvisionedThroughputExceededException":
|
|
608
|
+
case "com.amazonaws.textract#ProvisionedThroughputExceededException":
|
|
609
|
+
throw await deserializeAws_json1_1ProvisionedThroughputExceededExceptionResponse(parsedOutput, context);
|
|
610
|
+
case "ThrottlingException":
|
|
611
|
+
case "com.amazonaws.textract#ThrottlingException":
|
|
612
|
+
throw await deserializeAws_json1_1ThrottlingExceptionResponse(parsedOutput, context);
|
|
613
|
+
default:
|
|
614
|
+
const parsedBody = parsedOutput.body;
|
|
615
|
+
throwDefaultError({
|
|
616
|
+
output,
|
|
617
|
+
parsedBody,
|
|
618
|
+
exceptionCtor: __BaseException,
|
|
619
|
+
errorCode,
|
|
620
|
+
});
|
|
621
|
+
}
|
|
622
|
+
};
|
|
488
623
|
export const deserializeAws_json1_1StartDocumentAnalysisCommand = async (output, context) => {
|
|
489
624
|
if (output.statusCode >= 300) {
|
|
490
625
|
return deserializeAws_json1_1StartDocumentAnalysisCommandError(output, context);
|
|
@@ -683,6 +818,72 @@ const deserializeAws_json1_1StartExpenseAnalysisCommandError = async (output, co
|
|
|
683
818
|
});
|
|
684
819
|
}
|
|
685
820
|
};
|
|
821
|
+
export const deserializeAws_json1_1StartLendingAnalysisCommand = async (output, context) => {
|
|
822
|
+
if (output.statusCode >= 300) {
|
|
823
|
+
return deserializeAws_json1_1StartLendingAnalysisCommandError(output, context);
|
|
824
|
+
}
|
|
825
|
+
const data = await parseBody(output.body, context);
|
|
826
|
+
let contents = {};
|
|
827
|
+
contents = deserializeAws_json1_1StartLendingAnalysisResponse(data, context);
|
|
828
|
+
const response = {
|
|
829
|
+
$metadata: deserializeMetadata(output),
|
|
830
|
+
...contents,
|
|
831
|
+
};
|
|
832
|
+
return Promise.resolve(response);
|
|
833
|
+
};
|
|
834
|
+
const deserializeAws_json1_1StartLendingAnalysisCommandError = async (output, context) => {
|
|
835
|
+
const parsedOutput = {
|
|
836
|
+
...output,
|
|
837
|
+
body: await parseErrorBody(output.body, context),
|
|
838
|
+
};
|
|
839
|
+
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
840
|
+
switch (errorCode) {
|
|
841
|
+
case "AccessDeniedException":
|
|
842
|
+
case "com.amazonaws.textract#AccessDeniedException":
|
|
843
|
+
throw await deserializeAws_json1_1AccessDeniedExceptionResponse(parsedOutput, context);
|
|
844
|
+
case "BadDocumentException":
|
|
845
|
+
case "com.amazonaws.textract#BadDocumentException":
|
|
846
|
+
throw await deserializeAws_json1_1BadDocumentExceptionResponse(parsedOutput, context);
|
|
847
|
+
case "DocumentTooLargeException":
|
|
848
|
+
case "com.amazonaws.textract#DocumentTooLargeException":
|
|
849
|
+
throw await deserializeAws_json1_1DocumentTooLargeExceptionResponse(parsedOutput, context);
|
|
850
|
+
case "IdempotentParameterMismatchException":
|
|
851
|
+
case "com.amazonaws.textract#IdempotentParameterMismatchException":
|
|
852
|
+
throw await deserializeAws_json1_1IdempotentParameterMismatchExceptionResponse(parsedOutput, context);
|
|
853
|
+
case "InternalServerError":
|
|
854
|
+
case "com.amazonaws.textract#InternalServerError":
|
|
855
|
+
throw await deserializeAws_json1_1InternalServerErrorResponse(parsedOutput, context);
|
|
856
|
+
case "InvalidKMSKeyException":
|
|
857
|
+
case "com.amazonaws.textract#InvalidKMSKeyException":
|
|
858
|
+
throw await deserializeAws_json1_1InvalidKMSKeyExceptionResponse(parsedOutput, context);
|
|
859
|
+
case "InvalidParameterException":
|
|
860
|
+
case "com.amazonaws.textract#InvalidParameterException":
|
|
861
|
+
throw await deserializeAws_json1_1InvalidParameterExceptionResponse(parsedOutput, context);
|
|
862
|
+
case "InvalidS3ObjectException":
|
|
863
|
+
case "com.amazonaws.textract#InvalidS3ObjectException":
|
|
864
|
+
throw await deserializeAws_json1_1InvalidS3ObjectExceptionResponse(parsedOutput, context);
|
|
865
|
+
case "LimitExceededException":
|
|
866
|
+
case "com.amazonaws.textract#LimitExceededException":
|
|
867
|
+
throw await deserializeAws_json1_1LimitExceededExceptionResponse(parsedOutput, context);
|
|
868
|
+
case "ProvisionedThroughputExceededException":
|
|
869
|
+
case "com.amazonaws.textract#ProvisionedThroughputExceededException":
|
|
870
|
+
throw await deserializeAws_json1_1ProvisionedThroughputExceededExceptionResponse(parsedOutput, context);
|
|
871
|
+
case "ThrottlingException":
|
|
872
|
+
case "com.amazonaws.textract#ThrottlingException":
|
|
873
|
+
throw await deserializeAws_json1_1ThrottlingExceptionResponse(parsedOutput, context);
|
|
874
|
+
case "UnsupportedDocumentException":
|
|
875
|
+
case "com.amazonaws.textract#UnsupportedDocumentException":
|
|
876
|
+
throw await deserializeAws_json1_1UnsupportedDocumentExceptionResponse(parsedOutput, context);
|
|
877
|
+
default:
|
|
878
|
+
const parsedBody = parsedOutput.body;
|
|
879
|
+
throwDefaultError({
|
|
880
|
+
output,
|
|
881
|
+
parsedBody,
|
|
882
|
+
exceptionCtor: __BaseException,
|
|
883
|
+
errorCode,
|
|
884
|
+
});
|
|
885
|
+
}
|
|
886
|
+
};
|
|
686
887
|
const deserializeAws_json1_1AccessDeniedExceptionResponse = async (parsedOutput, context) => {
|
|
687
888
|
const body = parsedOutput.body;
|
|
688
889
|
const deserialized = deserializeAws_json1_1AccessDeniedException(body, context);
|
|
@@ -891,6 +1092,18 @@ const serializeAws_json1_1GetExpenseAnalysisRequest = (input, context) => {
|
|
|
891
1092
|
...(input.NextToken != null && { NextToken: input.NextToken }),
|
|
892
1093
|
};
|
|
893
1094
|
};
|
|
1095
|
+
const serializeAws_json1_1GetLendingAnalysisRequest = (input, context) => {
|
|
1096
|
+
return {
|
|
1097
|
+
...(input.JobId != null && { JobId: input.JobId }),
|
|
1098
|
+
...(input.MaxResults != null && { MaxResults: input.MaxResults }),
|
|
1099
|
+
...(input.NextToken != null && { NextToken: input.NextToken }),
|
|
1100
|
+
};
|
|
1101
|
+
};
|
|
1102
|
+
const serializeAws_json1_1GetLendingAnalysisSummaryRequest = (input, context) => {
|
|
1103
|
+
return {
|
|
1104
|
+
...(input.JobId != null && { JobId: input.JobId }),
|
|
1105
|
+
};
|
|
1106
|
+
};
|
|
894
1107
|
const serializeAws_json1_1HumanLoopConfig = (input, context) => {
|
|
895
1108
|
return {
|
|
896
1109
|
...(input.DataAttributes != null && {
|
|
@@ -998,6 +1211,20 @@ const serializeAws_json1_1StartExpenseAnalysisRequest = (input, context) => {
|
|
|
998
1211
|
...(input.OutputConfig != null && { OutputConfig: serializeAws_json1_1OutputConfig(input.OutputConfig, context) }),
|
|
999
1212
|
};
|
|
1000
1213
|
};
|
|
1214
|
+
const serializeAws_json1_1StartLendingAnalysisRequest = (input, context) => {
|
|
1215
|
+
return {
|
|
1216
|
+
...(input.ClientRequestToken != null && { ClientRequestToken: input.ClientRequestToken }),
|
|
1217
|
+
...(input.DocumentLocation != null && {
|
|
1218
|
+
DocumentLocation: serializeAws_json1_1DocumentLocation(input.DocumentLocation, context),
|
|
1219
|
+
}),
|
|
1220
|
+
...(input.JobTag != null && { JobTag: input.JobTag }),
|
|
1221
|
+
...(input.KMSKeyId != null && { KMSKeyId: input.KMSKeyId }),
|
|
1222
|
+
...(input.NotificationChannel != null && {
|
|
1223
|
+
NotificationChannel: serializeAws_json1_1NotificationChannel(input.NotificationChannel, context),
|
|
1224
|
+
}),
|
|
1225
|
+
...(input.OutputConfig != null && { OutputConfig: serializeAws_json1_1OutputConfig(input.OutputConfig, context) }),
|
|
1226
|
+
};
|
|
1227
|
+
};
|
|
1001
1228
|
const deserializeAws_json1_1AccessDeniedException = (output, context) => {
|
|
1002
1229
|
return {
|
|
1003
1230
|
Code: __expectString(output.Code),
|
|
@@ -1099,6 +1326,47 @@ const deserializeAws_json1_1DetectDocumentTextResponse = (output, context) => {
|
|
|
1099
1326
|
: undefined,
|
|
1100
1327
|
};
|
|
1101
1328
|
};
|
|
1329
|
+
const deserializeAws_json1_1DetectedSignature = (output, context) => {
|
|
1330
|
+
return {
|
|
1331
|
+
Page: __expectInt32(output.Page),
|
|
1332
|
+
};
|
|
1333
|
+
};
|
|
1334
|
+
const deserializeAws_json1_1DetectedSignatureList = (output, context) => {
|
|
1335
|
+
const retVal = (output || [])
|
|
1336
|
+
.filter((e) => e != null)
|
|
1337
|
+
.map((entry) => {
|
|
1338
|
+
if (entry === null) {
|
|
1339
|
+
return null;
|
|
1340
|
+
}
|
|
1341
|
+
return deserializeAws_json1_1DetectedSignature(entry, context);
|
|
1342
|
+
});
|
|
1343
|
+
return retVal;
|
|
1344
|
+
};
|
|
1345
|
+
const deserializeAws_json1_1DocumentGroup = (output, context) => {
|
|
1346
|
+
return {
|
|
1347
|
+
DetectedSignatures: output.DetectedSignatures != null
|
|
1348
|
+
? deserializeAws_json1_1DetectedSignatureList(output.DetectedSignatures, context)
|
|
1349
|
+
: undefined,
|
|
1350
|
+
SplitDocuments: output.SplitDocuments != null
|
|
1351
|
+
? deserializeAws_json1_1SplitDocumentList(output.SplitDocuments, context)
|
|
1352
|
+
: undefined,
|
|
1353
|
+
Type: __expectString(output.Type),
|
|
1354
|
+
UndetectedSignatures: output.UndetectedSignatures != null
|
|
1355
|
+
? deserializeAws_json1_1UndetectedSignatureList(output.UndetectedSignatures, context)
|
|
1356
|
+
: undefined,
|
|
1357
|
+
};
|
|
1358
|
+
};
|
|
1359
|
+
const deserializeAws_json1_1DocumentGroupList = (output, context) => {
|
|
1360
|
+
const retVal = (output || [])
|
|
1361
|
+
.filter((e) => e != null)
|
|
1362
|
+
.map((entry) => {
|
|
1363
|
+
if (entry === null) {
|
|
1364
|
+
return null;
|
|
1365
|
+
}
|
|
1366
|
+
return deserializeAws_json1_1DocumentGroup(entry, context);
|
|
1367
|
+
});
|
|
1368
|
+
return retVal;
|
|
1369
|
+
};
|
|
1102
1370
|
const deserializeAws_json1_1DocumentMetadata = (output, context) => {
|
|
1103
1371
|
return {
|
|
1104
1372
|
Pages: __expectInt32(output.Pages),
|
|
@@ -1205,6 +1473,30 @@ const deserializeAws_json1_1ExpenseType = (output, context) => {
|
|
|
1205
1473
|
Text: __expectString(output.Text),
|
|
1206
1474
|
};
|
|
1207
1475
|
};
|
|
1476
|
+
const deserializeAws_json1_1Extraction = (output, context) => {
|
|
1477
|
+
return {
|
|
1478
|
+
ExpenseDocument: output.ExpenseDocument != null
|
|
1479
|
+
? deserializeAws_json1_1ExpenseDocument(output.ExpenseDocument, context)
|
|
1480
|
+
: undefined,
|
|
1481
|
+
IdentityDocument: output.IdentityDocument != null
|
|
1482
|
+
? deserializeAws_json1_1IdentityDocument(output.IdentityDocument, context)
|
|
1483
|
+
: undefined,
|
|
1484
|
+
LendingDocument: output.LendingDocument != null
|
|
1485
|
+
? deserializeAws_json1_1LendingDocument(output.LendingDocument, context)
|
|
1486
|
+
: undefined,
|
|
1487
|
+
};
|
|
1488
|
+
};
|
|
1489
|
+
const deserializeAws_json1_1ExtractionList = (output, context) => {
|
|
1490
|
+
const retVal = (output || [])
|
|
1491
|
+
.filter((e) => e != null)
|
|
1492
|
+
.map((entry) => {
|
|
1493
|
+
if (entry === null) {
|
|
1494
|
+
return null;
|
|
1495
|
+
}
|
|
1496
|
+
return deserializeAws_json1_1Extraction(entry, context);
|
|
1497
|
+
});
|
|
1498
|
+
return retVal;
|
|
1499
|
+
};
|
|
1208
1500
|
const deserializeAws_json1_1Geometry = (output, context) => {
|
|
1209
1501
|
return {
|
|
1210
1502
|
BoundingBox: output.BoundingBox != null ? deserializeAws_json1_1BoundingBox(output.BoundingBox, context) : undefined,
|
|
@@ -1252,6 +1544,31 @@ const deserializeAws_json1_1GetExpenseAnalysisResponse = (output, context) => {
|
|
|
1252
1544
|
Warnings: output.Warnings != null ? deserializeAws_json1_1Warnings(output.Warnings, context) : undefined,
|
|
1253
1545
|
};
|
|
1254
1546
|
};
|
|
1547
|
+
const deserializeAws_json1_1GetLendingAnalysisResponse = (output, context) => {
|
|
1548
|
+
return {
|
|
1549
|
+
AnalyzeLendingModelVersion: __expectString(output.AnalyzeLendingModelVersion),
|
|
1550
|
+
DocumentMetadata: output.DocumentMetadata != null
|
|
1551
|
+
? deserializeAws_json1_1DocumentMetadata(output.DocumentMetadata, context)
|
|
1552
|
+
: undefined,
|
|
1553
|
+
JobStatus: __expectString(output.JobStatus),
|
|
1554
|
+
NextToken: __expectString(output.NextToken),
|
|
1555
|
+
Results: output.Results != null ? deserializeAws_json1_1LendingResultList(output.Results, context) : undefined,
|
|
1556
|
+
StatusMessage: __expectString(output.StatusMessage),
|
|
1557
|
+
Warnings: output.Warnings != null ? deserializeAws_json1_1Warnings(output.Warnings, context) : undefined,
|
|
1558
|
+
};
|
|
1559
|
+
};
|
|
1560
|
+
const deserializeAws_json1_1GetLendingAnalysisSummaryResponse = (output, context) => {
|
|
1561
|
+
return {
|
|
1562
|
+
AnalyzeLendingModelVersion: __expectString(output.AnalyzeLendingModelVersion),
|
|
1563
|
+
DocumentMetadata: output.DocumentMetadata != null
|
|
1564
|
+
? deserializeAws_json1_1DocumentMetadata(output.DocumentMetadata, context)
|
|
1565
|
+
: undefined,
|
|
1566
|
+
JobStatus: __expectString(output.JobStatus),
|
|
1567
|
+
StatusMessage: __expectString(output.StatusMessage),
|
|
1568
|
+
Summary: output.Summary != null ? deserializeAws_json1_1LendingSummary(output.Summary, context) : undefined,
|
|
1569
|
+
Warnings: output.Warnings != null ? deserializeAws_json1_1Warnings(output.Warnings, context) : undefined,
|
|
1570
|
+
};
|
|
1571
|
+
};
|
|
1255
1572
|
const deserializeAws_json1_1HumanLoopActivationOutput = (output, context) => {
|
|
1256
1573
|
return {
|
|
1257
1574
|
HumanLoopActivationConditionsEvaluationResults: output.HumanLoopActivationConditionsEvaluationResults != null
|
|
@@ -1369,6 +1686,83 @@ const deserializeAws_json1_1InvalidS3ObjectException = (output, context) => {
|
|
|
1369
1686
|
Message: __expectString(output.Message),
|
|
1370
1687
|
};
|
|
1371
1688
|
};
|
|
1689
|
+
const deserializeAws_json1_1LendingDetection = (output, context) => {
|
|
1690
|
+
return {
|
|
1691
|
+
Confidence: __limitedParseFloat32(output.Confidence),
|
|
1692
|
+
Geometry: output.Geometry != null ? deserializeAws_json1_1Geometry(output.Geometry, context) : undefined,
|
|
1693
|
+
SelectionStatus: __expectString(output.SelectionStatus),
|
|
1694
|
+
Text: __expectString(output.Text),
|
|
1695
|
+
};
|
|
1696
|
+
};
|
|
1697
|
+
const deserializeAws_json1_1LendingDetectionList = (output, context) => {
|
|
1698
|
+
const retVal = (output || [])
|
|
1699
|
+
.filter((e) => e != null)
|
|
1700
|
+
.map((entry) => {
|
|
1701
|
+
if (entry === null) {
|
|
1702
|
+
return null;
|
|
1703
|
+
}
|
|
1704
|
+
return deserializeAws_json1_1LendingDetection(entry, context);
|
|
1705
|
+
});
|
|
1706
|
+
return retVal;
|
|
1707
|
+
};
|
|
1708
|
+
const deserializeAws_json1_1LendingDocument = (output, context) => {
|
|
1709
|
+
return {
|
|
1710
|
+
LendingFields: output.LendingFields != null ? deserializeAws_json1_1LendingFieldList(output.LendingFields, context) : undefined,
|
|
1711
|
+
SignatureDetections: output.SignatureDetections != null
|
|
1712
|
+
? deserializeAws_json1_1SignatureDetectionList(output.SignatureDetections, context)
|
|
1713
|
+
: undefined,
|
|
1714
|
+
};
|
|
1715
|
+
};
|
|
1716
|
+
const deserializeAws_json1_1LendingField = (output, context) => {
|
|
1717
|
+
return {
|
|
1718
|
+
KeyDetection: output.KeyDetection != null ? deserializeAws_json1_1LendingDetection(output.KeyDetection, context) : undefined,
|
|
1719
|
+
Type: __expectString(output.Type),
|
|
1720
|
+
ValueDetections: output.ValueDetections != null
|
|
1721
|
+
? deserializeAws_json1_1LendingDetectionList(output.ValueDetections, context)
|
|
1722
|
+
: undefined,
|
|
1723
|
+
};
|
|
1724
|
+
};
|
|
1725
|
+
const deserializeAws_json1_1LendingFieldList = (output, context) => {
|
|
1726
|
+
const retVal = (output || [])
|
|
1727
|
+
.filter((e) => e != null)
|
|
1728
|
+
.map((entry) => {
|
|
1729
|
+
if (entry === null) {
|
|
1730
|
+
return null;
|
|
1731
|
+
}
|
|
1732
|
+
return deserializeAws_json1_1LendingField(entry, context);
|
|
1733
|
+
});
|
|
1734
|
+
return retVal;
|
|
1735
|
+
};
|
|
1736
|
+
const deserializeAws_json1_1LendingResult = (output, context) => {
|
|
1737
|
+
return {
|
|
1738
|
+
Extractions: output.Extractions != null ? deserializeAws_json1_1ExtractionList(output.Extractions, context) : undefined,
|
|
1739
|
+
Page: __expectInt32(output.Page),
|
|
1740
|
+
PageClassification: output.PageClassification != null
|
|
1741
|
+
? deserializeAws_json1_1PageClassification(output.PageClassification, context)
|
|
1742
|
+
: undefined,
|
|
1743
|
+
};
|
|
1744
|
+
};
|
|
1745
|
+
const deserializeAws_json1_1LendingResultList = (output, context) => {
|
|
1746
|
+
const retVal = (output || [])
|
|
1747
|
+
.filter((e) => e != null)
|
|
1748
|
+
.map((entry) => {
|
|
1749
|
+
if (entry === null) {
|
|
1750
|
+
return null;
|
|
1751
|
+
}
|
|
1752
|
+
return deserializeAws_json1_1LendingResult(entry, context);
|
|
1753
|
+
});
|
|
1754
|
+
return retVal;
|
|
1755
|
+
};
|
|
1756
|
+
const deserializeAws_json1_1LendingSummary = (output, context) => {
|
|
1757
|
+
return {
|
|
1758
|
+
DocumentGroups: output.DocumentGroups != null
|
|
1759
|
+
? deserializeAws_json1_1DocumentGroupList(output.DocumentGroups, context)
|
|
1760
|
+
: undefined,
|
|
1761
|
+
UndetectedDocumentTypes: output.UndetectedDocumentTypes != null
|
|
1762
|
+
? deserializeAws_json1_1UndetectedDocumentTypeList(output.UndetectedDocumentTypes, context)
|
|
1763
|
+
: undefined,
|
|
1764
|
+
};
|
|
1765
|
+
};
|
|
1372
1766
|
const deserializeAws_json1_1LimitExceededException = (output, context) => {
|
|
1373
1767
|
return {
|
|
1374
1768
|
Code: __expectString(output.Code),
|
|
@@ -1416,6 +1810,23 @@ const deserializeAws_json1_1NormalizedValue = (output, context) => {
|
|
|
1416
1810
|
ValueType: __expectString(output.ValueType),
|
|
1417
1811
|
};
|
|
1418
1812
|
};
|
|
1813
|
+
const deserializeAws_json1_1PageClassification = (output, context) => {
|
|
1814
|
+
return {
|
|
1815
|
+
PageNumber: output.PageNumber != null ? deserializeAws_json1_1PredictionList(output.PageNumber, context) : undefined,
|
|
1816
|
+
PageType: output.PageType != null ? deserializeAws_json1_1PredictionList(output.PageType, context) : undefined,
|
|
1817
|
+
};
|
|
1818
|
+
};
|
|
1819
|
+
const deserializeAws_json1_1PageList = (output, context) => {
|
|
1820
|
+
const retVal = (output || [])
|
|
1821
|
+
.filter((e) => e != null)
|
|
1822
|
+
.map((entry) => {
|
|
1823
|
+
if (entry === null) {
|
|
1824
|
+
return null;
|
|
1825
|
+
}
|
|
1826
|
+
return __expectInt32(entry);
|
|
1827
|
+
});
|
|
1828
|
+
return retVal;
|
|
1829
|
+
};
|
|
1419
1830
|
const deserializeAws_json1_1Pages = (output, context) => {
|
|
1420
1831
|
const retVal = (output || [])
|
|
1421
1832
|
.filter((e) => e != null)
|
|
@@ -1444,6 +1855,23 @@ const deserializeAws_json1_1Polygon = (output, context) => {
|
|
|
1444
1855
|
});
|
|
1445
1856
|
return retVal;
|
|
1446
1857
|
};
|
|
1858
|
+
const deserializeAws_json1_1Prediction = (output, context) => {
|
|
1859
|
+
return {
|
|
1860
|
+
Confidence: __limitedParseFloat32(output.Confidence),
|
|
1861
|
+
Value: __expectString(output.Value),
|
|
1862
|
+
};
|
|
1863
|
+
};
|
|
1864
|
+
const deserializeAws_json1_1PredictionList = (output, context) => {
|
|
1865
|
+
const retVal = (output || [])
|
|
1866
|
+
.filter((e) => e != null)
|
|
1867
|
+
.map((entry) => {
|
|
1868
|
+
if (entry === null) {
|
|
1869
|
+
return null;
|
|
1870
|
+
}
|
|
1871
|
+
return deserializeAws_json1_1Prediction(entry, context);
|
|
1872
|
+
});
|
|
1873
|
+
return retVal;
|
|
1874
|
+
};
|
|
1447
1875
|
const deserializeAws_json1_1ProvisionedThroughputExceededException = (output, context) => {
|
|
1448
1876
|
return {
|
|
1449
1877
|
Code: __expectString(output.Code),
|
|
@@ -1485,6 +1913,40 @@ const deserializeAws_json1_1RelationshipList = (output, context) => {
|
|
|
1485
1913
|
});
|
|
1486
1914
|
return retVal;
|
|
1487
1915
|
};
|
|
1916
|
+
const deserializeAws_json1_1SignatureDetection = (output, context) => {
|
|
1917
|
+
return {
|
|
1918
|
+
Confidence: __limitedParseFloat32(output.Confidence),
|
|
1919
|
+
Geometry: output.Geometry != null ? deserializeAws_json1_1Geometry(output.Geometry, context) : undefined,
|
|
1920
|
+
};
|
|
1921
|
+
};
|
|
1922
|
+
const deserializeAws_json1_1SignatureDetectionList = (output, context) => {
|
|
1923
|
+
const retVal = (output || [])
|
|
1924
|
+
.filter((e) => e != null)
|
|
1925
|
+
.map((entry) => {
|
|
1926
|
+
if (entry === null) {
|
|
1927
|
+
return null;
|
|
1928
|
+
}
|
|
1929
|
+
return deserializeAws_json1_1SignatureDetection(entry, context);
|
|
1930
|
+
});
|
|
1931
|
+
return retVal;
|
|
1932
|
+
};
|
|
1933
|
+
const deserializeAws_json1_1SplitDocument = (output, context) => {
|
|
1934
|
+
return {
|
|
1935
|
+
Index: __expectInt32(output.Index),
|
|
1936
|
+
Pages: output.Pages != null ? deserializeAws_json1_1PageList(output.Pages, context) : undefined,
|
|
1937
|
+
};
|
|
1938
|
+
};
|
|
1939
|
+
const deserializeAws_json1_1SplitDocumentList = (output, context) => {
|
|
1940
|
+
const retVal = (output || [])
|
|
1941
|
+
.filter((e) => e != null)
|
|
1942
|
+
.map((entry) => {
|
|
1943
|
+
if (entry === null) {
|
|
1944
|
+
return null;
|
|
1945
|
+
}
|
|
1946
|
+
return deserializeAws_json1_1SplitDocument(entry, context);
|
|
1947
|
+
});
|
|
1948
|
+
return retVal;
|
|
1949
|
+
};
|
|
1488
1950
|
const deserializeAws_json1_1StartDocumentAnalysisResponse = (output, context) => {
|
|
1489
1951
|
return {
|
|
1490
1952
|
JobId: __expectString(output.JobId),
|
|
@@ -1500,6 +1962,11 @@ const deserializeAws_json1_1StartExpenseAnalysisResponse = (output, context) =>
|
|
|
1500
1962
|
JobId: __expectString(output.JobId),
|
|
1501
1963
|
};
|
|
1502
1964
|
};
|
|
1965
|
+
const deserializeAws_json1_1StartLendingAnalysisResponse = (output, context) => {
|
|
1966
|
+
return {
|
|
1967
|
+
JobId: __expectString(output.JobId),
|
|
1968
|
+
};
|
|
1969
|
+
};
|
|
1503
1970
|
const deserializeAws_json1_1StringList = (output, context) => {
|
|
1504
1971
|
const retVal = (output || [])
|
|
1505
1972
|
.filter((e) => e != null)
|
|
@@ -1517,6 +1984,33 @@ const deserializeAws_json1_1ThrottlingException = (output, context) => {
|
|
|
1517
1984
|
Message: __expectString(output.Message),
|
|
1518
1985
|
};
|
|
1519
1986
|
};
|
|
1987
|
+
const deserializeAws_json1_1UndetectedDocumentTypeList = (output, context) => {
|
|
1988
|
+
const retVal = (output || [])
|
|
1989
|
+
.filter((e) => e != null)
|
|
1990
|
+
.map((entry) => {
|
|
1991
|
+
if (entry === null) {
|
|
1992
|
+
return null;
|
|
1993
|
+
}
|
|
1994
|
+
return __expectString(entry);
|
|
1995
|
+
});
|
|
1996
|
+
return retVal;
|
|
1997
|
+
};
|
|
1998
|
+
const deserializeAws_json1_1UndetectedSignature = (output, context) => {
|
|
1999
|
+
return {
|
|
2000
|
+
Page: __expectInt32(output.Page),
|
|
2001
|
+
};
|
|
2002
|
+
};
|
|
2003
|
+
const deserializeAws_json1_1UndetectedSignatureList = (output, context) => {
|
|
2004
|
+
const retVal = (output || [])
|
|
2005
|
+
.filter((e) => e != null)
|
|
2006
|
+
.map((entry) => {
|
|
2007
|
+
if (entry === null) {
|
|
2008
|
+
return null;
|
|
2009
|
+
}
|
|
2010
|
+
return deserializeAws_json1_1UndetectedSignature(entry, context);
|
|
2011
|
+
});
|
|
2012
|
+
return retVal;
|
|
2013
|
+
};
|
|
1520
2014
|
const deserializeAws_json1_1UnsupportedDocumentException = (output, context) => {
|
|
1521
2015
|
return {
|
|
1522
2016
|
Code: __expectString(output.Code),
|