@aws-sdk/client-comprehend 3.504.0 → 3.507.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/index.js +208 -2689
- package/dist-es/protocols/Aws_json1_1.js +410 -2891
- package/package.json +3 -3
|
@@ -516,7 +516,7 @@ export const se_UpdateFlywheelCommand = async (input, context) => {
|
|
|
516
516
|
};
|
|
517
517
|
export const de_BatchDetectDominantLanguageCommand = async (output, context) => {
|
|
518
518
|
if (output.statusCode >= 300) {
|
|
519
|
-
return
|
|
519
|
+
return de_CommandError(output, context);
|
|
520
520
|
}
|
|
521
521
|
const data = await parseBody(output.body, context);
|
|
522
522
|
let contents = {};
|
|
@@ -527,37 +527,9 @@ export const de_BatchDetectDominantLanguageCommand = async (output, context) =>
|
|
|
527
527
|
};
|
|
528
528
|
return response;
|
|
529
529
|
};
|
|
530
|
-
const de_BatchDetectDominantLanguageCommandError = async (output, context) => {
|
|
531
|
-
const parsedOutput = {
|
|
532
|
-
...output,
|
|
533
|
-
body: await parseErrorBody(output.body, context),
|
|
534
|
-
};
|
|
535
|
-
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
536
|
-
switch (errorCode) {
|
|
537
|
-
case "BatchSizeLimitExceededException":
|
|
538
|
-
case "com.amazonaws.comprehend#BatchSizeLimitExceededException":
|
|
539
|
-
throw await de_BatchSizeLimitExceededExceptionRes(parsedOutput, context);
|
|
540
|
-
case "InternalServerException":
|
|
541
|
-
case "com.amazonaws.comprehend#InternalServerException":
|
|
542
|
-
throw await de_InternalServerExceptionRes(parsedOutput, context);
|
|
543
|
-
case "InvalidRequestException":
|
|
544
|
-
case "com.amazonaws.comprehend#InvalidRequestException":
|
|
545
|
-
throw await de_InvalidRequestExceptionRes(parsedOutput, context);
|
|
546
|
-
case "TextSizeLimitExceededException":
|
|
547
|
-
case "com.amazonaws.comprehend#TextSizeLimitExceededException":
|
|
548
|
-
throw await de_TextSizeLimitExceededExceptionRes(parsedOutput, context);
|
|
549
|
-
default:
|
|
550
|
-
const parsedBody = parsedOutput.body;
|
|
551
|
-
return throwDefaultError({
|
|
552
|
-
output,
|
|
553
|
-
parsedBody,
|
|
554
|
-
errorCode,
|
|
555
|
-
});
|
|
556
|
-
}
|
|
557
|
-
};
|
|
558
530
|
export const de_BatchDetectEntitiesCommand = async (output, context) => {
|
|
559
531
|
if (output.statusCode >= 300) {
|
|
560
|
-
return
|
|
532
|
+
return de_CommandError(output, context);
|
|
561
533
|
}
|
|
562
534
|
const data = await parseBody(output.body, context);
|
|
563
535
|
let contents = {};
|
|
@@ -568,40 +540,9 @@ export const de_BatchDetectEntitiesCommand = async (output, context) => {
|
|
|
568
540
|
};
|
|
569
541
|
return response;
|
|
570
542
|
};
|
|
571
|
-
const de_BatchDetectEntitiesCommandError = async (output, context) => {
|
|
572
|
-
const parsedOutput = {
|
|
573
|
-
...output,
|
|
574
|
-
body: await parseErrorBody(output.body, context),
|
|
575
|
-
};
|
|
576
|
-
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
577
|
-
switch (errorCode) {
|
|
578
|
-
case "BatchSizeLimitExceededException":
|
|
579
|
-
case "com.amazonaws.comprehend#BatchSizeLimitExceededException":
|
|
580
|
-
throw await de_BatchSizeLimitExceededExceptionRes(parsedOutput, context);
|
|
581
|
-
case "InternalServerException":
|
|
582
|
-
case "com.amazonaws.comprehend#InternalServerException":
|
|
583
|
-
throw await de_InternalServerExceptionRes(parsedOutput, context);
|
|
584
|
-
case "InvalidRequestException":
|
|
585
|
-
case "com.amazonaws.comprehend#InvalidRequestException":
|
|
586
|
-
throw await de_InvalidRequestExceptionRes(parsedOutput, context);
|
|
587
|
-
case "TextSizeLimitExceededException":
|
|
588
|
-
case "com.amazonaws.comprehend#TextSizeLimitExceededException":
|
|
589
|
-
throw await de_TextSizeLimitExceededExceptionRes(parsedOutput, context);
|
|
590
|
-
case "UnsupportedLanguageException":
|
|
591
|
-
case "com.amazonaws.comprehend#UnsupportedLanguageException":
|
|
592
|
-
throw await de_UnsupportedLanguageExceptionRes(parsedOutput, context);
|
|
593
|
-
default:
|
|
594
|
-
const parsedBody = parsedOutput.body;
|
|
595
|
-
return throwDefaultError({
|
|
596
|
-
output,
|
|
597
|
-
parsedBody,
|
|
598
|
-
errorCode,
|
|
599
|
-
});
|
|
600
|
-
}
|
|
601
|
-
};
|
|
602
543
|
export const de_BatchDetectKeyPhrasesCommand = async (output, context) => {
|
|
603
544
|
if (output.statusCode >= 300) {
|
|
604
|
-
return
|
|
545
|
+
return de_CommandError(output, context);
|
|
605
546
|
}
|
|
606
547
|
const data = await parseBody(output.body, context);
|
|
607
548
|
let contents = {};
|
|
@@ -612,40 +553,9 @@ export const de_BatchDetectKeyPhrasesCommand = async (output, context) => {
|
|
|
612
553
|
};
|
|
613
554
|
return response;
|
|
614
555
|
};
|
|
615
|
-
const de_BatchDetectKeyPhrasesCommandError = async (output, context) => {
|
|
616
|
-
const parsedOutput = {
|
|
617
|
-
...output,
|
|
618
|
-
body: await parseErrorBody(output.body, context),
|
|
619
|
-
};
|
|
620
|
-
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
621
|
-
switch (errorCode) {
|
|
622
|
-
case "BatchSizeLimitExceededException":
|
|
623
|
-
case "com.amazonaws.comprehend#BatchSizeLimitExceededException":
|
|
624
|
-
throw await de_BatchSizeLimitExceededExceptionRes(parsedOutput, context);
|
|
625
|
-
case "InternalServerException":
|
|
626
|
-
case "com.amazonaws.comprehend#InternalServerException":
|
|
627
|
-
throw await de_InternalServerExceptionRes(parsedOutput, context);
|
|
628
|
-
case "InvalidRequestException":
|
|
629
|
-
case "com.amazonaws.comprehend#InvalidRequestException":
|
|
630
|
-
throw await de_InvalidRequestExceptionRes(parsedOutput, context);
|
|
631
|
-
case "TextSizeLimitExceededException":
|
|
632
|
-
case "com.amazonaws.comprehend#TextSizeLimitExceededException":
|
|
633
|
-
throw await de_TextSizeLimitExceededExceptionRes(parsedOutput, context);
|
|
634
|
-
case "UnsupportedLanguageException":
|
|
635
|
-
case "com.amazonaws.comprehend#UnsupportedLanguageException":
|
|
636
|
-
throw await de_UnsupportedLanguageExceptionRes(parsedOutput, context);
|
|
637
|
-
default:
|
|
638
|
-
const parsedBody = parsedOutput.body;
|
|
639
|
-
return throwDefaultError({
|
|
640
|
-
output,
|
|
641
|
-
parsedBody,
|
|
642
|
-
errorCode,
|
|
643
|
-
});
|
|
644
|
-
}
|
|
645
|
-
};
|
|
646
556
|
export const de_BatchDetectSentimentCommand = async (output, context) => {
|
|
647
557
|
if (output.statusCode >= 300) {
|
|
648
|
-
return
|
|
558
|
+
return de_CommandError(output, context);
|
|
649
559
|
}
|
|
650
560
|
const data = await parseBody(output.body, context);
|
|
651
561
|
let contents = {};
|
|
@@ -656,40 +566,9 @@ export const de_BatchDetectSentimentCommand = async (output, context) => {
|
|
|
656
566
|
};
|
|
657
567
|
return response;
|
|
658
568
|
};
|
|
659
|
-
const de_BatchDetectSentimentCommandError = async (output, context) => {
|
|
660
|
-
const parsedOutput = {
|
|
661
|
-
...output,
|
|
662
|
-
body: await parseErrorBody(output.body, context),
|
|
663
|
-
};
|
|
664
|
-
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
665
|
-
switch (errorCode) {
|
|
666
|
-
case "BatchSizeLimitExceededException":
|
|
667
|
-
case "com.amazonaws.comprehend#BatchSizeLimitExceededException":
|
|
668
|
-
throw await de_BatchSizeLimitExceededExceptionRes(parsedOutput, context);
|
|
669
|
-
case "InternalServerException":
|
|
670
|
-
case "com.amazonaws.comprehend#InternalServerException":
|
|
671
|
-
throw await de_InternalServerExceptionRes(parsedOutput, context);
|
|
672
|
-
case "InvalidRequestException":
|
|
673
|
-
case "com.amazonaws.comprehend#InvalidRequestException":
|
|
674
|
-
throw await de_InvalidRequestExceptionRes(parsedOutput, context);
|
|
675
|
-
case "TextSizeLimitExceededException":
|
|
676
|
-
case "com.amazonaws.comprehend#TextSizeLimitExceededException":
|
|
677
|
-
throw await de_TextSizeLimitExceededExceptionRes(parsedOutput, context);
|
|
678
|
-
case "UnsupportedLanguageException":
|
|
679
|
-
case "com.amazonaws.comprehend#UnsupportedLanguageException":
|
|
680
|
-
throw await de_UnsupportedLanguageExceptionRes(parsedOutput, context);
|
|
681
|
-
default:
|
|
682
|
-
const parsedBody = parsedOutput.body;
|
|
683
|
-
return throwDefaultError({
|
|
684
|
-
output,
|
|
685
|
-
parsedBody,
|
|
686
|
-
errorCode,
|
|
687
|
-
});
|
|
688
|
-
}
|
|
689
|
-
};
|
|
690
569
|
export const de_BatchDetectSyntaxCommand = async (output, context) => {
|
|
691
570
|
if (output.statusCode >= 300) {
|
|
692
|
-
return
|
|
571
|
+
return de_CommandError(output, context);
|
|
693
572
|
}
|
|
694
573
|
const data = await parseBody(output.body, context);
|
|
695
574
|
let contents = {};
|
|
@@ -700,40 +579,9 @@ export const de_BatchDetectSyntaxCommand = async (output, context) => {
|
|
|
700
579
|
};
|
|
701
580
|
return response;
|
|
702
581
|
};
|
|
703
|
-
const de_BatchDetectSyntaxCommandError = async (output, context) => {
|
|
704
|
-
const parsedOutput = {
|
|
705
|
-
...output,
|
|
706
|
-
body: await parseErrorBody(output.body, context),
|
|
707
|
-
};
|
|
708
|
-
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
709
|
-
switch (errorCode) {
|
|
710
|
-
case "BatchSizeLimitExceededException":
|
|
711
|
-
case "com.amazonaws.comprehend#BatchSizeLimitExceededException":
|
|
712
|
-
throw await de_BatchSizeLimitExceededExceptionRes(parsedOutput, context);
|
|
713
|
-
case "InternalServerException":
|
|
714
|
-
case "com.amazonaws.comprehend#InternalServerException":
|
|
715
|
-
throw await de_InternalServerExceptionRes(parsedOutput, context);
|
|
716
|
-
case "InvalidRequestException":
|
|
717
|
-
case "com.amazonaws.comprehend#InvalidRequestException":
|
|
718
|
-
throw await de_InvalidRequestExceptionRes(parsedOutput, context);
|
|
719
|
-
case "TextSizeLimitExceededException":
|
|
720
|
-
case "com.amazonaws.comprehend#TextSizeLimitExceededException":
|
|
721
|
-
throw await de_TextSizeLimitExceededExceptionRes(parsedOutput, context);
|
|
722
|
-
case "UnsupportedLanguageException":
|
|
723
|
-
case "com.amazonaws.comprehend#UnsupportedLanguageException":
|
|
724
|
-
throw await de_UnsupportedLanguageExceptionRes(parsedOutput, context);
|
|
725
|
-
default:
|
|
726
|
-
const parsedBody = parsedOutput.body;
|
|
727
|
-
return throwDefaultError({
|
|
728
|
-
output,
|
|
729
|
-
parsedBody,
|
|
730
|
-
errorCode,
|
|
731
|
-
});
|
|
732
|
-
}
|
|
733
|
-
};
|
|
734
582
|
export const de_BatchDetectTargetedSentimentCommand = async (output, context) => {
|
|
735
583
|
if (output.statusCode >= 300) {
|
|
736
|
-
return
|
|
584
|
+
return de_CommandError(output, context);
|
|
737
585
|
}
|
|
738
586
|
const data = await parseBody(output.body, context);
|
|
739
587
|
let contents = {};
|
|
@@ -744,40 +592,9 @@ export const de_BatchDetectTargetedSentimentCommand = async (output, context) =>
|
|
|
744
592
|
};
|
|
745
593
|
return response;
|
|
746
594
|
};
|
|
747
|
-
const de_BatchDetectTargetedSentimentCommandError = async (output, context) => {
|
|
748
|
-
const parsedOutput = {
|
|
749
|
-
...output,
|
|
750
|
-
body: await parseErrorBody(output.body, context),
|
|
751
|
-
};
|
|
752
|
-
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
753
|
-
switch (errorCode) {
|
|
754
|
-
case "BatchSizeLimitExceededException":
|
|
755
|
-
case "com.amazonaws.comprehend#BatchSizeLimitExceededException":
|
|
756
|
-
throw await de_BatchSizeLimitExceededExceptionRes(parsedOutput, context);
|
|
757
|
-
case "InternalServerException":
|
|
758
|
-
case "com.amazonaws.comprehend#InternalServerException":
|
|
759
|
-
throw await de_InternalServerExceptionRes(parsedOutput, context);
|
|
760
|
-
case "InvalidRequestException":
|
|
761
|
-
case "com.amazonaws.comprehend#InvalidRequestException":
|
|
762
|
-
throw await de_InvalidRequestExceptionRes(parsedOutput, context);
|
|
763
|
-
case "TextSizeLimitExceededException":
|
|
764
|
-
case "com.amazonaws.comprehend#TextSizeLimitExceededException":
|
|
765
|
-
throw await de_TextSizeLimitExceededExceptionRes(parsedOutput, context);
|
|
766
|
-
case "UnsupportedLanguageException":
|
|
767
|
-
case "com.amazonaws.comprehend#UnsupportedLanguageException":
|
|
768
|
-
throw await de_UnsupportedLanguageExceptionRes(parsedOutput, context);
|
|
769
|
-
default:
|
|
770
|
-
const parsedBody = parsedOutput.body;
|
|
771
|
-
return throwDefaultError({
|
|
772
|
-
output,
|
|
773
|
-
parsedBody,
|
|
774
|
-
errorCode,
|
|
775
|
-
});
|
|
776
|
-
}
|
|
777
|
-
};
|
|
778
595
|
export const de_ClassifyDocumentCommand = async (output, context) => {
|
|
779
596
|
if (output.statusCode >= 300) {
|
|
780
|
-
return
|
|
597
|
+
return de_CommandError(output, context);
|
|
781
598
|
}
|
|
782
599
|
const data = await parseBody(output.body, context);
|
|
783
600
|
let contents = {};
|
|
@@ -788,37 +605,9 @@ export const de_ClassifyDocumentCommand = async (output, context) => {
|
|
|
788
605
|
};
|
|
789
606
|
return response;
|
|
790
607
|
};
|
|
791
|
-
const de_ClassifyDocumentCommandError = async (output, context) => {
|
|
792
|
-
const parsedOutput = {
|
|
793
|
-
...output,
|
|
794
|
-
body: await parseErrorBody(output.body, context),
|
|
795
|
-
};
|
|
796
|
-
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
797
|
-
switch (errorCode) {
|
|
798
|
-
case "InternalServerException":
|
|
799
|
-
case "com.amazonaws.comprehend#InternalServerException":
|
|
800
|
-
throw await de_InternalServerExceptionRes(parsedOutput, context);
|
|
801
|
-
case "InvalidRequestException":
|
|
802
|
-
case "com.amazonaws.comprehend#InvalidRequestException":
|
|
803
|
-
throw await de_InvalidRequestExceptionRes(parsedOutput, context);
|
|
804
|
-
case "ResourceUnavailableException":
|
|
805
|
-
case "com.amazonaws.comprehend#ResourceUnavailableException":
|
|
806
|
-
throw await de_ResourceUnavailableExceptionRes(parsedOutput, context);
|
|
807
|
-
case "TextSizeLimitExceededException":
|
|
808
|
-
case "com.amazonaws.comprehend#TextSizeLimitExceededException":
|
|
809
|
-
throw await de_TextSizeLimitExceededExceptionRes(parsedOutput, context);
|
|
810
|
-
default:
|
|
811
|
-
const parsedBody = parsedOutput.body;
|
|
812
|
-
return throwDefaultError({
|
|
813
|
-
output,
|
|
814
|
-
parsedBody,
|
|
815
|
-
errorCode,
|
|
816
|
-
});
|
|
817
|
-
}
|
|
818
|
-
};
|
|
819
608
|
export const de_ContainsPiiEntitiesCommand = async (output, context) => {
|
|
820
609
|
if (output.statusCode >= 300) {
|
|
821
|
-
return
|
|
610
|
+
return de_CommandError(output, context);
|
|
822
611
|
}
|
|
823
612
|
const data = await parseBody(output.body, context);
|
|
824
613
|
let contents = {};
|
|
@@ -829,37 +618,22 @@ export const de_ContainsPiiEntitiesCommand = async (output, context) => {
|
|
|
829
618
|
};
|
|
830
619
|
return response;
|
|
831
620
|
};
|
|
832
|
-
const
|
|
833
|
-
|
|
834
|
-
|
|
835
|
-
body: await parseErrorBody(output.body, context),
|
|
836
|
-
};
|
|
837
|
-
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
838
|
-
switch (errorCode) {
|
|
839
|
-
case "InternalServerException":
|
|
840
|
-
case "com.amazonaws.comprehend#InternalServerException":
|
|
841
|
-
throw await de_InternalServerExceptionRes(parsedOutput, context);
|
|
842
|
-
case "InvalidRequestException":
|
|
843
|
-
case "com.amazonaws.comprehend#InvalidRequestException":
|
|
844
|
-
throw await de_InvalidRequestExceptionRes(parsedOutput, context);
|
|
845
|
-
case "TextSizeLimitExceededException":
|
|
846
|
-
case "com.amazonaws.comprehend#TextSizeLimitExceededException":
|
|
847
|
-
throw await de_TextSizeLimitExceededExceptionRes(parsedOutput, context);
|
|
848
|
-
case "UnsupportedLanguageException":
|
|
849
|
-
case "com.amazonaws.comprehend#UnsupportedLanguageException":
|
|
850
|
-
throw await de_UnsupportedLanguageExceptionRes(parsedOutput, context);
|
|
851
|
-
default:
|
|
852
|
-
const parsedBody = parsedOutput.body;
|
|
853
|
-
return throwDefaultError({
|
|
854
|
-
output,
|
|
855
|
-
parsedBody,
|
|
856
|
-
errorCode,
|
|
857
|
-
});
|
|
621
|
+
export const de_CreateDatasetCommand = async (output, context) => {
|
|
622
|
+
if (output.statusCode >= 300) {
|
|
623
|
+
return de_CommandError(output, context);
|
|
858
624
|
}
|
|
625
|
+
const data = await parseBody(output.body, context);
|
|
626
|
+
let contents = {};
|
|
627
|
+
contents = _json(data);
|
|
628
|
+
const response = {
|
|
629
|
+
$metadata: deserializeMetadata(output),
|
|
630
|
+
...contents,
|
|
631
|
+
};
|
|
632
|
+
return response;
|
|
859
633
|
};
|
|
860
|
-
export const
|
|
634
|
+
export const de_CreateDocumentClassifierCommand = async (output, context) => {
|
|
861
635
|
if (output.statusCode >= 300) {
|
|
862
|
-
return
|
|
636
|
+
return de_CommandError(output, context);
|
|
863
637
|
}
|
|
864
638
|
const data = await parseBody(output.body, context);
|
|
865
639
|
let contents = {};
|
|
@@ -870,152 +644,22 @@ export const de_CreateDatasetCommand = async (output, context) => {
|
|
|
870
644
|
};
|
|
871
645
|
return response;
|
|
872
646
|
};
|
|
873
|
-
const
|
|
874
|
-
|
|
875
|
-
|
|
876
|
-
|
|
877
|
-
|
|
878
|
-
|
|
879
|
-
|
|
880
|
-
|
|
881
|
-
|
|
882
|
-
|
|
883
|
-
case "InvalidRequestException":
|
|
884
|
-
case "com.amazonaws.comprehend#InvalidRequestException":
|
|
885
|
-
throw await de_InvalidRequestExceptionRes(parsedOutput, context);
|
|
886
|
-
case "ResourceInUseException":
|
|
887
|
-
case "com.amazonaws.comprehend#ResourceInUseException":
|
|
888
|
-
throw await de_ResourceInUseExceptionRes(parsedOutput, context);
|
|
889
|
-
case "ResourceLimitExceededException":
|
|
890
|
-
case "com.amazonaws.comprehend#ResourceLimitExceededException":
|
|
891
|
-
throw await de_ResourceLimitExceededExceptionRes(parsedOutput, context);
|
|
892
|
-
case "ResourceNotFoundException":
|
|
893
|
-
case "com.amazonaws.comprehend#ResourceNotFoundException":
|
|
894
|
-
throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
|
|
895
|
-
case "TooManyRequestsException":
|
|
896
|
-
case "com.amazonaws.comprehend#TooManyRequestsException":
|
|
897
|
-
throw await de_TooManyRequestsExceptionRes(parsedOutput, context);
|
|
898
|
-
case "TooManyTagsException":
|
|
899
|
-
case "com.amazonaws.comprehend#TooManyTagsException":
|
|
900
|
-
throw await de_TooManyTagsExceptionRes(parsedOutput, context);
|
|
901
|
-
default:
|
|
902
|
-
const parsedBody = parsedOutput.body;
|
|
903
|
-
return throwDefaultError({
|
|
904
|
-
output,
|
|
905
|
-
parsedBody,
|
|
906
|
-
errorCode,
|
|
907
|
-
});
|
|
908
|
-
}
|
|
909
|
-
};
|
|
910
|
-
export const de_CreateDocumentClassifierCommand = async (output, context) => {
|
|
911
|
-
if (output.statusCode >= 300) {
|
|
912
|
-
return de_CreateDocumentClassifierCommandError(output, context);
|
|
913
|
-
}
|
|
914
|
-
const data = await parseBody(output.body, context);
|
|
915
|
-
let contents = {};
|
|
916
|
-
contents = _json(data);
|
|
917
|
-
const response = {
|
|
918
|
-
$metadata: deserializeMetadata(output),
|
|
919
|
-
...contents,
|
|
920
|
-
};
|
|
921
|
-
return response;
|
|
922
|
-
};
|
|
923
|
-
const de_CreateDocumentClassifierCommandError = async (output, context) => {
|
|
924
|
-
const parsedOutput = {
|
|
925
|
-
...output,
|
|
926
|
-
body: await parseErrorBody(output.body, context),
|
|
927
|
-
};
|
|
928
|
-
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
929
|
-
switch (errorCode) {
|
|
930
|
-
case "InternalServerException":
|
|
931
|
-
case "com.amazonaws.comprehend#InternalServerException":
|
|
932
|
-
throw await de_InternalServerExceptionRes(parsedOutput, context);
|
|
933
|
-
case "InvalidRequestException":
|
|
934
|
-
case "com.amazonaws.comprehend#InvalidRequestException":
|
|
935
|
-
throw await de_InvalidRequestExceptionRes(parsedOutput, context);
|
|
936
|
-
case "KmsKeyValidationException":
|
|
937
|
-
case "com.amazonaws.comprehend#KmsKeyValidationException":
|
|
938
|
-
throw await de_KmsKeyValidationExceptionRes(parsedOutput, context);
|
|
939
|
-
case "ResourceInUseException":
|
|
940
|
-
case "com.amazonaws.comprehend#ResourceInUseException":
|
|
941
|
-
throw await de_ResourceInUseExceptionRes(parsedOutput, context);
|
|
942
|
-
case "ResourceLimitExceededException":
|
|
943
|
-
case "com.amazonaws.comprehend#ResourceLimitExceededException":
|
|
944
|
-
throw await de_ResourceLimitExceededExceptionRes(parsedOutput, context);
|
|
945
|
-
case "TooManyRequestsException":
|
|
946
|
-
case "com.amazonaws.comprehend#TooManyRequestsException":
|
|
947
|
-
throw await de_TooManyRequestsExceptionRes(parsedOutput, context);
|
|
948
|
-
case "TooManyTagsException":
|
|
949
|
-
case "com.amazonaws.comprehend#TooManyTagsException":
|
|
950
|
-
throw await de_TooManyTagsExceptionRes(parsedOutput, context);
|
|
951
|
-
case "UnsupportedLanguageException":
|
|
952
|
-
case "com.amazonaws.comprehend#UnsupportedLanguageException":
|
|
953
|
-
throw await de_UnsupportedLanguageExceptionRes(parsedOutput, context);
|
|
954
|
-
default:
|
|
955
|
-
const parsedBody = parsedOutput.body;
|
|
956
|
-
return throwDefaultError({
|
|
957
|
-
output,
|
|
958
|
-
parsedBody,
|
|
959
|
-
errorCode,
|
|
960
|
-
});
|
|
961
|
-
}
|
|
962
|
-
};
|
|
963
|
-
export const de_CreateEndpointCommand = async (output, context) => {
|
|
964
|
-
if (output.statusCode >= 300) {
|
|
965
|
-
return de_CreateEndpointCommandError(output, context);
|
|
966
|
-
}
|
|
967
|
-
const data = await parseBody(output.body, context);
|
|
968
|
-
let contents = {};
|
|
969
|
-
contents = _json(data);
|
|
970
|
-
const response = {
|
|
971
|
-
$metadata: deserializeMetadata(output),
|
|
972
|
-
...contents,
|
|
647
|
+
export const de_CreateEndpointCommand = async (output, context) => {
|
|
648
|
+
if (output.statusCode >= 300) {
|
|
649
|
+
return de_CommandError(output, context);
|
|
650
|
+
}
|
|
651
|
+
const data = await parseBody(output.body, context);
|
|
652
|
+
let contents = {};
|
|
653
|
+
contents = _json(data);
|
|
654
|
+
const response = {
|
|
655
|
+
$metadata: deserializeMetadata(output),
|
|
656
|
+
...contents,
|
|
973
657
|
};
|
|
974
658
|
return response;
|
|
975
659
|
};
|
|
976
|
-
const de_CreateEndpointCommandError = async (output, context) => {
|
|
977
|
-
const parsedOutput = {
|
|
978
|
-
...output,
|
|
979
|
-
body: await parseErrorBody(output.body, context),
|
|
980
|
-
};
|
|
981
|
-
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
982
|
-
switch (errorCode) {
|
|
983
|
-
case "InternalServerException":
|
|
984
|
-
case "com.amazonaws.comprehend#InternalServerException":
|
|
985
|
-
throw await de_InternalServerExceptionRes(parsedOutput, context);
|
|
986
|
-
case "InvalidRequestException":
|
|
987
|
-
case "com.amazonaws.comprehend#InvalidRequestException":
|
|
988
|
-
throw await de_InvalidRequestExceptionRes(parsedOutput, context);
|
|
989
|
-
case "ResourceInUseException":
|
|
990
|
-
case "com.amazonaws.comprehend#ResourceInUseException":
|
|
991
|
-
throw await de_ResourceInUseExceptionRes(parsedOutput, context);
|
|
992
|
-
case "ResourceLimitExceededException":
|
|
993
|
-
case "com.amazonaws.comprehend#ResourceLimitExceededException":
|
|
994
|
-
throw await de_ResourceLimitExceededExceptionRes(parsedOutput, context);
|
|
995
|
-
case "ResourceNotFoundException":
|
|
996
|
-
case "com.amazonaws.comprehend#ResourceNotFoundException":
|
|
997
|
-
throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
|
|
998
|
-
case "ResourceUnavailableException":
|
|
999
|
-
case "com.amazonaws.comprehend#ResourceUnavailableException":
|
|
1000
|
-
throw await de_ResourceUnavailableExceptionRes(parsedOutput, context);
|
|
1001
|
-
case "TooManyRequestsException":
|
|
1002
|
-
case "com.amazonaws.comprehend#TooManyRequestsException":
|
|
1003
|
-
throw await de_TooManyRequestsExceptionRes(parsedOutput, context);
|
|
1004
|
-
case "TooManyTagsException":
|
|
1005
|
-
case "com.amazonaws.comprehend#TooManyTagsException":
|
|
1006
|
-
throw await de_TooManyTagsExceptionRes(parsedOutput, context);
|
|
1007
|
-
default:
|
|
1008
|
-
const parsedBody = parsedOutput.body;
|
|
1009
|
-
return throwDefaultError({
|
|
1010
|
-
output,
|
|
1011
|
-
parsedBody,
|
|
1012
|
-
errorCode,
|
|
1013
|
-
});
|
|
1014
|
-
}
|
|
1015
|
-
};
|
|
1016
660
|
export const de_CreateEntityRecognizerCommand = async (output, context) => {
|
|
1017
661
|
if (output.statusCode >= 300) {
|
|
1018
|
-
return
|
|
662
|
+
return de_CommandError(output, context);
|
|
1019
663
|
}
|
|
1020
664
|
const data = await parseBody(output.body, context);
|
|
1021
665
|
let contents = {};
|
|
@@ -1026,49 +670,9 @@ export const de_CreateEntityRecognizerCommand = async (output, context) => {
|
|
|
1026
670
|
};
|
|
1027
671
|
return response;
|
|
1028
672
|
};
|
|
1029
|
-
const de_CreateEntityRecognizerCommandError = async (output, context) => {
|
|
1030
|
-
const parsedOutput = {
|
|
1031
|
-
...output,
|
|
1032
|
-
body: await parseErrorBody(output.body, context),
|
|
1033
|
-
};
|
|
1034
|
-
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1035
|
-
switch (errorCode) {
|
|
1036
|
-
case "InternalServerException":
|
|
1037
|
-
case "com.amazonaws.comprehend#InternalServerException":
|
|
1038
|
-
throw await de_InternalServerExceptionRes(parsedOutput, context);
|
|
1039
|
-
case "InvalidRequestException":
|
|
1040
|
-
case "com.amazonaws.comprehend#InvalidRequestException":
|
|
1041
|
-
throw await de_InvalidRequestExceptionRes(parsedOutput, context);
|
|
1042
|
-
case "KmsKeyValidationException":
|
|
1043
|
-
case "com.amazonaws.comprehend#KmsKeyValidationException":
|
|
1044
|
-
throw await de_KmsKeyValidationExceptionRes(parsedOutput, context);
|
|
1045
|
-
case "ResourceInUseException":
|
|
1046
|
-
case "com.amazonaws.comprehend#ResourceInUseException":
|
|
1047
|
-
throw await de_ResourceInUseExceptionRes(parsedOutput, context);
|
|
1048
|
-
case "ResourceLimitExceededException":
|
|
1049
|
-
case "com.amazonaws.comprehend#ResourceLimitExceededException":
|
|
1050
|
-
throw await de_ResourceLimitExceededExceptionRes(parsedOutput, context);
|
|
1051
|
-
case "TooManyRequestsException":
|
|
1052
|
-
case "com.amazonaws.comprehend#TooManyRequestsException":
|
|
1053
|
-
throw await de_TooManyRequestsExceptionRes(parsedOutput, context);
|
|
1054
|
-
case "TooManyTagsException":
|
|
1055
|
-
case "com.amazonaws.comprehend#TooManyTagsException":
|
|
1056
|
-
throw await de_TooManyTagsExceptionRes(parsedOutput, context);
|
|
1057
|
-
case "UnsupportedLanguageException":
|
|
1058
|
-
case "com.amazonaws.comprehend#UnsupportedLanguageException":
|
|
1059
|
-
throw await de_UnsupportedLanguageExceptionRes(parsedOutput, context);
|
|
1060
|
-
default:
|
|
1061
|
-
const parsedBody = parsedOutput.body;
|
|
1062
|
-
return throwDefaultError({
|
|
1063
|
-
output,
|
|
1064
|
-
parsedBody,
|
|
1065
|
-
errorCode,
|
|
1066
|
-
});
|
|
1067
|
-
}
|
|
1068
|
-
};
|
|
1069
673
|
export const de_CreateFlywheelCommand = async (output, context) => {
|
|
1070
674
|
if (output.statusCode >= 300) {
|
|
1071
|
-
return
|
|
675
|
+
return de_CommandError(output, context);
|
|
1072
676
|
}
|
|
1073
677
|
const data = await parseBody(output.body, context);
|
|
1074
678
|
let contents = {};
|
|
@@ -1079,55 +683,9 @@ export const de_CreateFlywheelCommand = async (output, context) => {
|
|
|
1079
683
|
};
|
|
1080
684
|
return response;
|
|
1081
685
|
};
|
|
1082
|
-
const de_CreateFlywheelCommandError = async (output, context) => {
|
|
1083
|
-
const parsedOutput = {
|
|
1084
|
-
...output,
|
|
1085
|
-
body: await parseErrorBody(output.body, context),
|
|
1086
|
-
};
|
|
1087
|
-
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1088
|
-
switch (errorCode) {
|
|
1089
|
-
case "InternalServerException":
|
|
1090
|
-
case "com.amazonaws.comprehend#InternalServerException":
|
|
1091
|
-
throw await de_InternalServerExceptionRes(parsedOutput, context);
|
|
1092
|
-
case "InvalidRequestException":
|
|
1093
|
-
case "com.amazonaws.comprehend#InvalidRequestException":
|
|
1094
|
-
throw await de_InvalidRequestExceptionRes(parsedOutput, context);
|
|
1095
|
-
case "KmsKeyValidationException":
|
|
1096
|
-
case "com.amazonaws.comprehend#KmsKeyValidationException":
|
|
1097
|
-
throw await de_KmsKeyValidationExceptionRes(parsedOutput, context);
|
|
1098
|
-
case "ResourceInUseException":
|
|
1099
|
-
case "com.amazonaws.comprehend#ResourceInUseException":
|
|
1100
|
-
throw await de_ResourceInUseExceptionRes(parsedOutput, context);
|
|
1101
|
-
case "ResourceLimitExceededException":
|
|
1102
|
-
case "com.amazonaws.comprehend#ResourceLimitExceededException":
|
|
1103
|
-
throw await de_ResourceLimitExceededExceptionRes(parsedOutput, context);
|
|
1104
|
-
case "ResourceNotFoundException":
|
|
1105
|
-
case "com.amazonaws.comprehend#ResourceNotFoundException":
|
|
1106
|
-
throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
|
|
1107
|
-
case "ResourceUnavailableException":
|
|
1108
|
-
case "com.amazonaws.comprehend#ResourceUnavailableException":
|
|
1109
|
-
throw await de_ResourceUnavailableExceptionRes(parsedOutput, context);
|
|
1110
|
-
case "TooManyRequestsException":
|
|
1111
|
-
case "com.amazonaws.comprehend#TooManyRequestsException":
|
|
1112
|
-
throw await de_TooManyRequestsExceptionRes(parsedOutput, context);
|
|
1113
|
-
case "TooManyTagsException":
|
|
1114
|
-
case "com.amazonaws.comprehend#TooManyTagsException":
|
|
1115
|
-
throw await de_TooManyTagsExceptionRes(parsedOutput, context);
|
|
1116
|
-
case "UnsupportedLanguageException":
|
|
1117
|
-
case "com.amazonaws.comprehend#UnsupportedLanguageException":
|
|
1118
|
-
throw await de_UnsupportedLanguageExceptionRes(parsedOutput, context);
|
|
1119
|
-
default:
|
|
1120
|
-
const parsedBody = parsedOutput.body;
|
|
1121
|
-
return throwDefaultError({
|
|
1122
|
-
output,
|
|
1123
|
-
parsedBody,
|
|
1124
|
-
errorCode,
|
|
1125
|
-
});
|
|
1126
|
-
}
|
|
1127
|
-
};
|
|
1128
686
|
export const de_DeleteDocumentClassifierCommand = async (output, context) => {
|
|
1129
687
|
if (output.statusCode >= 300) {
|
|
1130
|
-
return
|
|
688
|
+
return de_CommandError(output, context);
|
|
1131
689
|
}
|
|
1132
690
|
const data = await parseBody(output.body, context);
|
|
1133
691
|
let contents = {};
|
|
@@ -1138,2179 +696,581 @@ export const de_DeleteDocumentClassifierCommand = async (output, context) => {
|
|
|
1138
696
|
};
|
|
1139
697
|
return response;
|
|
1140
698
|
};
|
|
1141
|
-
const
|
|
1142
|
-
const parsedOutput = {
|
|
1143
|
-
...output,
|
|
1144
|
-
body: await parseErrorBody(output.body, context),
|
|
1145
|
-
};
|
|
1146
|
-
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1147
|
-
switch (errorCode) {
|
|
1148
|
-
case "InternalServerException":
|
|
1149
|
-
case "com.amazonaws.comprehend#InternalServerException":
|
|
1150
|
-
throw await de_InternalServerExceptionRes(parsedOutput, context);
|
|
1151
|
-
case "InvalidRequestException":
|
|
1152
|
-
case "com.amazonaws.comprehend#InvalidRequestException":
|
|
1153
|
-
throw await de_InvalidRequestExceptionRes(parsedOutput, context);
|
|
1154
|
-
case "ResourceInUseException":
|
|
1155
|
-
case "com.amazonaws.comprehend#ResourceInUseException":
|
|
1156
|
-
throw await de_ResourceInUseExceptionRes(parsedOutput, context);
|
|
1157
|
-
case "ResourceNotFoundException":
|
|
1158
|
-
case "com.amazonaws.comprehend#ResourceNotFoundException":
|
|
1159
|
-
throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
|
|
1160
|
-
case "ResourceUnavailableException":
|
|
1161
|
-
case "com.amazonaws.comprehend#ResourceUnavailableException":
|
|
1162
|
-
throw await de_ResourceUnavailableExceptionRes(parsedOutput, context);
|
|
1163
|
-
case "TooManyRequestsException":
|
|
1164
|
-
case "com.amazonaws.comprehend#TooManyRequestsException":
|
|
1165
|
-
throw await de_TooManyRequestsExceptionRes(parsedOutput, context);
|
|
1166
|
-
default:
|
|
1167
|
-
const parsedBody = parsedOutput.body;
|
|
1168
|
-
return throwDefaultError({
|
|
1169
|
-
output,
|
|
1170
|
-
parsedBody,
|
|
1171
|
-
errorCode,
|
|
1172
|
-
});
|
|
1173
|
-
}
|
|
1174
|
-
};
|
|
1175
|
-
export const de_DeleteEndpointCommand = async (output, context) => {
|
|
1176
|
-
if (output.statusCode >= 300) {
|
|
1177
|
-
return de_DeleteEndpointCommandError(output, context);
|
|
1178
|
-
}
|
|
1179
|
-
const data = await parseBody(output.body, context);
|
|
1180
|
-
let contents = {};
|
|
1181
|
-
contents = _json(data);
|
|
1182
|
-
const response = {
|
|
1183
|
-
$metadata: deserializeMetadata(output),
|
|
1184
|
-
...contents,
|
|
1185
|
-
};
|
|
1186
|
-
return response;
|
|
1187
|
-
};
|
|
1188
|
-
const de_DeleteEndpointCommandError = async (output, context) => {
|
|
1189
|
-
const parsedOutput = {
|
|
1190
|
-
...output,
|
|
1191
|
-
body: await parseErrorBody(output.body, context),
|
|
1192
|
-
};
|
|
1193
|
-
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1194
|
-
switch (errorCode) {
|
|
1195
|
-
case "InternalServerException":
|
|
1196
|
-
case "com.amazonaws.comprehend#InternalServerException":
|
|
1197
|
-
throw await de_InternalServerExceptionRes(parsedOutput, context);
|
|
1198
|
-
case "InvalidRequestException":
|
|
1199
|
-
case "com.amazonaws.comprehend#InvalidRequestException":
|
|
1200
|
-
throw await de_InvalidRequestExceptionRes(parsedOutput, context);
|
|
1201
|
-
case "ResourceInUseException":
|
|
1202
|
-
case "com.amazonaws.comprehend#ResourceInUseException":
|
|
1203
|
-
throw await de_ResourceInUseExceptionRes(parsedOutput, context);
|
|
1204
|
-
case "ResourceNotFoundException":
|
|
1205
|
-
case "com.amazonaws.comprehend#ResourceNotFoundException":
|
|
1206
|
-
throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
|
|
1207
|
-
case "TooManyRequestsException":
|
|
1208
|
-
case "com.amazonaws.comprehend#TooManyRequestsException":
|
|
1209
|
-
throw await de_TooManyRequestsExceptionRes(parsedOutput, context);
|
|
1210
|
-
default:
|
|
1211
|
-
const parsedBody = parsedOutput.body;
|
|
1212
|
-
return throwDefaultError({
|
|
1213
|
-
output,
|
|
1214
|
-
parsedBody,
|
|
1215
|
-
errorCode,
|
|
1216
|
-
});
|
|
1217
|
-
}
|
|
1218
|
-
};
|
|
1219
|
-
export const de_DeleteEntityRecognizerCommand = async (output, context) => {
|
|
1220
|
-
if (output.statusCode >= 300) {
|
|
1221
|
-
return de_DeleteEntityRecognizerCommandError(output, context);
|
|
1222
|
-
}
|
|
1223
|
-
const data = await parseBody(output.body, context);
|
|
1224
|
-
let contents = {};
|
|
1225
|
-
contents = _json(data);
|
|
1226
|
-
const response = {
|
|
1227
|
-
$metadata: deserializeMetadata(output),
|
|
1228
|
-
...contents,
|
|
1229
|
-
};
|
|
1230
|
-
return response;
|
|
1231
|
-
};
|
|
1232
|
-
const de_DeleteEntityRecognizerCommandError = async (output, context) => {
|
|
1233
|
-
const parsedOutput = {
|
|
1234
|
-
...output,
|
|
1235
|
-
body: await parseErrorBody(output.body, context),
|
|
1236
|
-
};
|
|
1237
|
-
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1238
|
-
switch (errorCode) {
|
|
1239
|
-
case "InternalServerException":
|
|
1240
|
-
case "com.amazonaws.comprehend#InternalServerException":
|
|
1241
|
-
throw await de_InternalServerExceptionRes(parsedOutput, context);
|
|
1242
|
-
case "InvalidRequestException":
|
|
1243
|
-
case "com.amazonaws.comprehend#InvalidRequestException":
|
|
1244
|
-
throw await de_InvalidRequestExceptionRes(parsedOutput, context);
|
|
1245
|
-
case "ResourceInUseException":
|
|
1246
|
-
case "com.amazonaws.comprehend#ResourceInUseException":
|
|
1247
|
-
throw await de_ResourceInUseExceptionRes(parsedOutput, context);
|
|
1248
|
-
case "ResourceNotFoundException":
|
|
1249
|
-
case "com.amazonaws.comprehend#ResourceNotFoundException":
|
|
1250
|
-
throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
|
|
1251
|
-
case "ResourceUnavailableException":
|
|
1252
|
-
case "com.amazonaws.comprehend#ResourceUnavailableException":
|
|
1253
|
-
throw await de_ResourceUnavailableExceptionRes(parsedOutput, context);
|
|
1254
|
-
case "TooManyRequestsException":
|
|
1255
|
-
case "com.amazonaws.comprehend#TooManyRequestsException":
|
|
1256
|
-
throw await de_TooManyRequestsExceptionRes(parsedOutput, context);
|
|
1257
|
-
default:
|
|
1258
|
-
const parsedBody = parsedOutput.body;
|
|
1259
|
-
return throwDefaultError({
|
|
1260
|
-
output,
|
|
1261
|
-
parsedBody,
|
|
1262
|
-
errorCode,
|
|
1263
|
-
});
|
|
1264
|
-
}
|
|
1265
|
-
};
|
|
1266
|
-
export const de_DeleteFlywheelCommand = async (output, context) => {
|
|
1267
|
-
if (output.statusCode >= 300) {
|
|
1268
|
-
return de_DeleteFlywheelCommandError(output, context);
|
|
1269
|
-
}
|
|
1270
|
-
const data = await parseBody(output.body, context);
|
|
1271
|
-
let contents = {};
|
|
1272
|
-
contents = _json(data);
|
|
1273
|
-
const response = {
|
|
1274
|
-
$metadata: deserializeMetadata(output),
|
|
1275
|
-
...contents,
|
|
1276
|
-
};
|
|
1277
|
-
return response;
|
|
1278
|
-
};
|
|
1279
|
-
const de_DeleteFlywheelCommandError = async (output, context) => {
|
|
1280
|
-
const parsedOutput = {
|
|
1281
|
-
...output,
|
|
1282
|
-
body: await parseErrorBody(output.body, context),
|
|
1283
|
-
};
|
|
1284
|
-
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1285
|
-
switch (errorCode) {
|
|
1286
|
-
case "InternalServerException":
|
|
1287
|
-
case "com.amazonaws.comprehend#InternalServerException":
|
|
1288
|
-
throw await de_InternalServerExceptionRes(parsedOutput, context);
|
|
1289
|
-
case "InvalidRequestException":
|
|
1290
|
-
case "com.amazonaws.comprehend#InvalidRequestException":
|
|
1291
|
-
throw await de_InvalidRequestExceptionRes(parsedOutput, context);
|
|
1292
|
-
case "ResourceInUseException":
|
|
1293
|
-
case "com.amazonaws.comprehend#ResourceInUseException":
|
|
1294
|
-
throw await de_ResourceInUseExceptionRes(parsedOutput, context);
|
|
1295
|
-
case "ResourceNotFoundException":
|
|
1296
|
-
case "com.amazonaws.comprehend#ResourceNotFoundException":
|
|
1297
|
-
throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
|
|
1298
|
-
case "ResourceUnavailableException":
|
|
1299
|
-
case "com.amazonaws.comprehend#ResourceUnavailableException":
|
|
1300
|
-
throw await de_ResourceUnavailableExceptionRes(parsedOutput, context);
|
|
1301
|
-
case "TooManyRequestsException":
|
|
1302
|
-
case "com.amazonaws.comprehend#TooManyRequestsException":
|
|
1303
|
-
throw await de_TooManyRequestsExceptionRes(parsedOutput, context);
|
|
1304
|
-
default:
|
|
1305
|
-
const parsedBody = parsedOutput.body;
|
|
1306
|
-
return throwDefaultError({
|
|
1307
|
-
output,
|
|
1308
|
-
parsedBody,
|
|
1309
|
-
errorCode,
|
|
1310
|
-
});
|
|
1311
|
-
}
|
|
1312
|
-
};
|
|
1313
|
-
export const de_DeleteResourcePolicyCommand = async (output, context) => {
|
|
1314
|
-
if (output.statusCode >= 300) {
|
|
1315
|
-
return de_DeleteResourcePolicyCommandError(output, context);
|
|
1316
|
-
}
|
|
1317
|
-
const data = await parseBody(output.body, context);
|
|
1318
|
-
let contents = {};
|
|
1319
|
-
contents = _json(data);
|
|
1320
|
-
const response = {
|
|
1321
|
-
$metadata: deserializeMetadata(output),
|
|
1322
|
-
...contents,
|
|
1323
|
-
};
|
|
1324
|
-
return response;
|
|
1325
|
-
};
|
|
1326
|
-
const de_DeleteResourcePolicyCommandError = async (output, context) => {
|
|
1327
|
-
const parsedOutput = {
|
|
1328
|
-
...output,
|
|
1329
|
-
body: await parseErrorBody(output.body, context),
|
|
1330
|
-
};
|
|
1331
|
-
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1332
|
-
switch (errorCode) {
|
|
1333
|
-
case "InternalServerException":
|
|
1334
|
-
case "com.amazonaws.comprehend#InternalServerException":
|
|
1335
|
-
throw await de_InternalServerExceptionRes(parsedOutput, context);
|
|
1336
|
-
case "InvalidRequestException":
|
|
1337
|
-
case "com.amazonaws.comprehend#InvalidRequestException":
|
|
1338
|
-
throw await de_InvalidRequestExceptionRes(parsedOutput, context);
|
|
1339
|
-
case "ResourceNotFoundException":
|
|
1340
|
-
case "com.amazonaws.comprehend#ResourceNotFoundException":
|
|
1341
|
-
throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
|
|
1342
|
-
default:
|
|
1343
|
-
const parsedBody = parsedOutput.body;
|
|
1344
|
-
return throwDefaultError({
|
|
1345
|
-
output,
|
|
1346
|
-
parsedBody,
|
|
1347
|
-
errorCode,
|
|
1348
|
-
});
|
|
1349
|
-
}
|
|
1350
|
-
};
|
|
1351
|
-
export const de_DescribeDatasetCommand = async (output, context) => {
|
|
1352
|
-
if (output.statusCode >= 300) {
|
|
1353
|
-
return de_DescribeDatasetCommandError(output, context);
|
|
1354
|
-
}
|
|
1355
|
-
const data = await parseBody(output.body, context);
|
|
1356
|
-
let contents = {};
|
|
1357
|
-
contents = de_DescribeDatasetResponse(data, context);
|
|
1358
|
-
const response = {
|
|
1359
|
-
$metadata: deserializeMetadata(output),
|
|
1360
|
-
...contents,
|
|
1361
|
-
};
|
|
1362
|
-
return response;
|
|
1363
|
-
};
|
|
1364
|
-
const de_DescribeDatasetCommandError = async (output, context) => {
|
|
1365
|
-
const parsedOutput = {
|
|
1366
|
-
...output,
|
|
1367
|
-
body: await parseErrorBody(output.body, context),
|
|
1368
|
-
};
|
|
1369
|
-
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1370
|
-
switch (errorCode) {
|
|
1371
|
-
case "InternalServerException":
|
|
1372
|
-
case "com.amazonaws.comprehend#InternalServerException":
|
|
1373
|
-
throw await de_InternalServerExceptionRes(parsedOutput, context);
|
|
1374
|
-
case "InvalidRequestException":
|
|
1375
|
-
case "com.amazonaws.comprehend#InvalidRequestException":
|
|
1376
|
-
throw await de_InvalidRequestExceptionRes(parsedOutput, context);
|
|
1377
|
-
case "ResourceNotFoundException":
|
|
1378
|
-
case "com.amazonaws.comprehend#ResourceNotFoundException":
|
|
1379
|
-
throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
|
|
1380
|
-
case "TooManyRequestsException":
|
|
1381
|
-
case "com.amazonaws.comprehend#TooManyRequestsException":
|
|
1382
|
-
throw await de_TooManyRequestsExceptionRes(parsedOutput, context);
|
|
1383
|
-
default:
|
|
1384
|
-
const parsedBody = parsedOutput.body;
|
|
1385
|
-
return throwDefaultError({
|
|
1386
|
-
output,
|
|
1387
|
-
parsedBody,
|
|
1388
|
-
errorCode,
|
|
1389
|
-
});
|
|
1390
|
-
}
|
|
1391
|
-
};
|
|
1392
|
-
export const de_DescribeDocumentClassificationJobCommand = async (output, context) => {
|
|
1393
|
-
if (output.statusCode >= 300) {
|
|
1394
|
-
return de_DescribeDocumentClassificationJobCommandError(output, context);
|
|
1395
|
-
}
|
|
1396
|
-
const data = await parseBody(output.body, context);
|
|
1397
|
-
let contents = {};
|
|
1398
|
-
contents = de_DescribeDocumentClassificationJobResponse(data, context);
|
|
1399
|
-
const response = {
|
|
1400
|
-
$metadata: deserializeMetadata(output),
|
|
1401
|
-
...contents,
|
|
1402
|
-
};
|
|
1403
|
-
return response;
|
|
1404
|
-
};
|
|
1405
|
-
const de_DescribeDocumentClassificationJobCommandError = async (output, context) => {
|
|
1406
|
-
const parsedOutput = {
|
|
1407
|
-
...output,
|
|
1408
|
-
body: await parseErrorBody(output.body, context),
|
|
1409
|
-
};
|
|
1410
|
-
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1411
|
-
switch (errorCode) {
|
|
1412
|
-
case "InternalServerException":
|
|
1413
|
-
case "com.amazonaws.comprehend#InternalServerException":
|
|
1414
|
-
throw await de_InternalServerExceptionRes(parsedOutput, context);
|
|
1415
|
-
case "InvalidRequestException":
|
|
1416
|
-
case "com.amazonaws.comprehend#InvalidRequestException":
|
|
1417
|
-
throw await de_InvalidRequestExceptionRes(parsedOutput, context);
|
|
1418
|
-
case "JobNotFoundException":
|
|
1419
|
-
case "com.amazonaws.comprehend#JobNotFoundException":
|
|
1420
|
-
throw await de_JobNotFoundExceptionRes(parsedOutput, context);
|
|
1421
|
-
case "TooManyRequestsException":
|
|
1422
|
-
case "com.amazonaws.comprehend#TooManyRequestsException":
|
|
1423
|
-
throw await de_TooManyRequestsExceptionRes(parsedOutput, context);
|
|
1424
|
-
default:
|
|
1425
|
-
const parsedBody = parsedOutput.body;
|
|
1426
|
-
return throwDefaultError({
|
|
1427
|
-
output,
|
|
1428
|
-
parsedBody,
|
|
1429
|
-
errorCode,
|
|
1430
|
-
});
|
|
1431
|
-
}
|
|
1432
|
-
};
|
|
1433
|
-
export const de_DescribeDocumentClassifierCommand = async (output, context) => {
|
|
1434
|
-
if (output.statusCode >= 300) {
|
|
1435
|
-
return de_DescribeDocumentClassifierCommandError(output, context);
|
|
1436
|
-
}
|
|
1437
|
-
const data = await parseBody(output.body, context);
|
|
1438
|
-
let contents = {};
|
|
1439
|
-
contents = de_DescribeDocumentClassifierResponse(data, context);
|
|
1440
|
-
const response = {
|
|
1441
|
-
$metadata: deserializeMetadata(output),
|
|
1442
|
-
...contents,
|
|
1443
|
-
};
|
|
1444
|
-
return response;
|
|
1445
|
-
};
|
|
1446
|
-
const de_DescribeDocumentClassifierCommandError = async (output, context) => {
|
|
1447
|
-
const parsedOutput = {
|
|
1448
|
-
...output,
|
|
1449
|
-
body: await parseErrorBody(output.body, context),
|
|
1450
|
-
};
|
|
1451
|
-
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1452
|
-
switch (errorCode) {
|
|
1453
|
-
case "InternalServerException":
|
|
1454
|
-
case "com.amazonaws.comprehend#InternalServerException":
|
|
1455
|
-
throw await de_InternalServerExceptionRes(parsedOutput, context);
|
|
1456
|
-
case "InvalidRequestException":
|
|
1457
|
-
case "com.amazonaws.comprehend#InvalidRequestException":
|
|
1458
|
-
throw await de_InvalidRequestExceptionRes(parsedOutput, context);
|
|
1459
|
-
case "ResourceNotFoundException":
|
|
1460
|
-
case "com.amazonaws.comprehend#ResourceNotFoundException":
|
|
1461
|
-
throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
|
|
1462
|
-
case "TooManyRequestsException":
|
|
1463
|
-
case "com.amazonaws.comprehend#TooManyRequestsException":
|
|
1464
|
-
throw await de_TooManyRequestsExceptionRes(parsedOutput, context);
|
|
1465
|
-
default:
|
|
1466
|
-
const parsedBody = parsedOutput.body;
|
|
1467
|
-
return throwDefaultError({
|
|
1468
|
-
output,
|
|
1469
|
-
parsedBody,
|
|
1470
|
-
errorCode,
|
|
1471
|
-
});
|
|
1472
|
-
}
|
|
1473
|
-
};
|
|
1474
|
-
export const de_DescribeDominantLanguageDetectionJobCommand = async (output, context) => {
|
|
1475
|
-
if (output.statusCode >= 300) {
|
|
1476
|
-
return de_DescribeDominantLanguageDetectionJobCommandError(output, context);
|
|
1477
|
-
}
|
|
1478
|
-
const data = await parseBody(output.body, context);
|
|
1479
|
-
let contents = {};
|
|
1480
|
-
contents = de_DescribeDominantLanguageDetectionJobResponse(data, context);
|
|
1481
|
-
const response = {
|
|
1482
|
-
$metadata: deserializeMetadata(output),
|
|
1483
|
-
...contents,
|
|
1484
|
-
};
|
|
1485
|
-
return response;
|
|
1486
|
-
};
|
|
1487
|
-
const de_DescribeDominantLanguageDetectionJobCommandError = async (output, context) => {
|
|
1488
|
-
const parsedOutput = {
|
|
1489
|
-
...output,
|
|
1490
|
-
body: await parseErrorBody(output.body, context),
|
|
1491
|
-
};
|
|
1492
|
-
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1493
|
-
switch (errorCode) {
|
|
1494
|
-
case "InternalServerException":
|
|
1495
|
-
case "com.amazonaws.comprehend#InternalServerException":
|
|
1496
|
-
throw await de_InternalServerExceptionRes(parsedOutput, context);
|
|
1497
|
-
case "InvalidRequestException":
|
|
1498
|
-
case "com.amazonaws.comprehend#InvalidRequestException":
|
|
1499
|
-
throw await de_InvalidRequestExceptionRes(parsedOutput, context);
|
|
1500
|
-
case "JobNotFoundException":
|
|
1501
|
-
case "com.amazonaws.comprehend#JobNotFoundException":
|
|
1502
|
-
throw await de_JobNotFoundExceptionRes(parsedOutput, context);
|
|
1503
|
-
case "TooManyRequestsException":
|
|
1504
|
-
case "com.amazonaws.comprehend#TooManyRequestsException":
|
|
1505
|
-
throw await de_TooManyRequestsExceptionRes(parsedOutput, context);
|
|
1506
|
-
default:
|
|
1507
|
-
const parsedBody = parsedOutput.body;
|
|
1508
|
-
return throwDefaultError({
|
|
1509
|
-
output,
|
|
1510
|
-
parsedBody,
|
|
1511
|
-
errorCode,
|
|
1512
|
-
});
|
|
1513
|
-
}
|
|
1514
|
-
};
|
|
1515
|
-
export const de_DescribeEndpointCommand = async (output, context) => {
|
|
1516
|
-
if (output.statusCode >= 300) {
|
|
1517
|
-
return de_DescribeEndpointCommandError(output, context);
|
|
1518
|
-
}
|
|
1519
|
-
const data = await parseBody(output.body, context);
|
|
1520
|
-
let contents = {};
|
|
1521
|
-
contents = de_DescribeEndpointResponse(data, context);
|
|
1522
|
-
const response = {
|
|
1523
|
-
$metadata: deserializeMetadata(output),
|
|
1524
|
-
...contents,
|
|
1525
|
-
};
|
|
1526
|
-
return response;
|
|
1527
|
-
};
|
|
1528
|
-
const de_DescribeEndpointCommandError = async (output, context) => {
|
|
1529
|
-
const parsedOutput = {
|
|
1530
|
-
...output,
|
|
1531
|
-
body: await parseErrorBody(output.body, context),
|
|
1532
|
-
};
|
|
1533
|
-
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1534
|
-
switch (errorCode) {
|
|
1535
|
-
case "InternalServerException":
|
|
1536
|
-
case "com.amazonaws.comprehend#InternalServerException":
|
|
1537
|
-
throw await de_InternalServerExceptionRes(parsedOutput, context);
|
|
1538
|
-
case "InvalidRequestException":
|
|
1539
|
-
case "com.amazonaws.comprehend#InvalidRequestException":
|
|
1540
|
-
throw await de_InvalidRequestExceptionRes(parsedOutput, context);
|
|
1541
|
-
case "ResourceNotFoundException":
|
|
1542
|
-
case "com.amazonaws.comprehend#ResourceNotFoundException":
|
|
1543
|
-
throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
|
|
1544
|
-
case "TooManyRequestsException":
|
|
1545
|
-
case "com.amazonaws.comprehend#TooManyRequestsException":
|
|
1546
|
-
throw await de_TooManyRequestsExceptionRes(parsedOutput, context);
|
|
1547
|
-
default:
|
|
1548
|
-
const parsedBody = parsedOutput.body;
|
|
1549
|
-
return throwDefaultError({
|
|
1550
|
-
output,
|
|
1551
|
-
parsedBody,
|
|
1552
|
-
errorCode,
|
|
1553
|
-
});
|
|
1554
|
-
}
|
|
1555
|
-
};
|
|
1556
|
-
export const de_DescribeEntitiesDetectionJobCommand = async (output, context) => {
|
|
1557
|
-
if (output.statusCode >= 300) {
|
|
1558
|
-
return de_DescribeEntitiesDetectionJobCommandError(output, context);
|
|
1559
|
-
}
|
|
1560
|
-
const data = await parseBody(output.body, context);
|
|
1561
|
-
let contents = {};
|
|
1562
|
-
contents = de_DescribeEntitiesDetectionJobResponse(data, context);
|
|
1563
|
-
const response = {
|
|
1564
|
-
$metadata: deserializeMetadata(output),
|
|
1565
|
-
...contents,
|
|
1566
|
-
};
|
|
1567
|
-
return response;
|
|
1568
|
-
};
|
|
1569
|
-
const de_DescribeEntitiesDetectionJobCommandError = async (output, context) => {
|
|
1570
|
-
const parsedOutput = {
|
|
1571
|
-
...output,
|
|
1572
|
-
body: await parseErrorBody(output.body, context),
|
|
1573
|
-
};
|
|
1574
|
-
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1575
|
-
switch (errorCode) {
|
|
1576
|
-
case "InternalServerException":
|
|
1577
|
-
case "com.amazonaws.comprehend#InternalServerException":
|
|
1578
|
-
throw await de_InternalServerExceptionRes(parsedOutput, context);
|
|
1579
|
-
case "InvalidRequestException":
|
|
1580
|
-
case "com.amazonaws.comprehend#InvalidRequestException":
|
|
1581
|
-
throw await de_InvalidRequestExceptionRes(parsedOutput, context);
|
|
1582
|
-
case "JobNotFoundException":
|
|
1583
|
-
case "com.amazonaws.comprehend#JobNotFoundException":
|
|
1584
|
-
throw await de_JobNotFoundExceptionRes(parsedOutput, context);
|
|
1585
|
-
case "TooManyRequestsException":
|
|
1586
|
-
case "com.amazonaws.comprehend#TooManyRequestsException":
|
|
1587
|
-
throw await de_TooManyRequestsExceptionRes(parsedOutput, context);
|
|
1588
|
-
default:
|
|
1589
|
-
const parsedBody = parsedOutput.body;
|
|
1590
|
-
return throwDefaultError({
|
|
1591
|
-
output,
|
|
1592
|
-
parsedBody,
|
|
1593
|
-
errorCode,
|
|
1594
|
-
});
|
|
1595
|
-
}
|
|
1596
|
-
};
|
|
1597
|
-
export const de_DescribeEntityRecognizerCommand = async (output, context) => {
|
|
1598
|
-
if (output.statusCode >= 300) {
|
|
1599
|
-
return de_DescribeEntityRecognizerCommandError(output, context);
|
|
1600
|
-
}
|
|
1601
|
-
const data = await parseBody(output.body, context);
|
|
1602
|
-
let contents = {};
|
|
1603
|
-
contents = de_DescribeEntityRecognizerResponse(data, context);
|
|
1604
|
-
const response = {
|
|
1605
|
-
$metadata: deserializeMetadata(output),
|
|
1606
|
-
...contents,
|
|
1607
|
-
};
|
|
1608
|
-
return response;
|
|
1609
|
-
};
|
|
1610
|
-
const de_DescribeEntityRecognizerCommandError = async (output, context) => {
|
|
1611
|
-
const parsedOutput = {
|
|
1612
|
-
...output,
|
|
1613
|
-
body: await parseErrorBody(output.body, context),
|
|
1614
|
-
};
|
|
1615
|
-
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1616
|
-
switch (errorCode) {
|
|
1617
|
-
case "InternalServerException":
|
|
1618
|
-
case "com.amazonaws.comprehend#InternalServerException":
|
|
1619
|
-
throw await de_InternalServerExceptionRes(parsedOutput, context);
|
|
1620
|
-
case "InvalidRequestException":
|
|
1621
|
-
case "com.amazonaws.comprehend#InvalidRequestException":
|
|
1622
|
-
throw await de_InvalidRequestExceptionRes(parsedOutput, context);
|
|
1623
|
-
case "ResourceNotFoundException":
|
|
1624
|
-
case "com.amazonaws.comprehend#ResourceNotFoundException":
|
|
1625
|
-
throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
|
|
1626
|
-
case "TooManyRequestsException":
|
|
1627
|
-
case "com.amazonaws.comprehend#TooManyRequestsException":
|
|
1628
|
-
throw await de_TooManyRequestsExceptionRes(parsedOutput, context);
|
|
1629
|
-
default:
|
|
1630
|
-
const parsedBody = parsedOutput.body;
|
|
1631
|
-
return throwDefaultError({
|
|
1632
|
-
output,
|
|
1633
|
-
parsedBody,
|
|
1634
|
-
errorCode,
|
|
1635
|
-
});
|
|
1636
|
-
}
|
|
1637
|
-
};
|
|
1638
|
-
export const de_DescribeEventsDetectionJobCommand = async (output, context) => {
|
|
1639
|
-
if (output.statusCode >= 300) {
|
|
1640
|
-
return de_DescribeEventsDetectionJobCommandError(output, context);
|
|
1641
|
-
}
|
|
1642
|
-
const data = await parseBody(output.body, context);
|
|
1643
|
-
let contents = {};
|
|
1644
|
-
contents = de_DescribeEventsDetectionJobResponse(data, context);
|
|
1645
|
-
const response = {
|
|
1646
|
-
$metadata: deserializeMetadata(output),
|
|
1647
|
-
...contents,
|
|
1648
|
-
};
|
|
1649
|
-
return response;
|
|
1650
|
-
};
|
|
1651
|
-
const de_DescribeEventsDetectionJobCommandError = async (output, context) => {
|
|
1652
|
-
const parsedOutput = {
|
|
1653
|
-
...output,
|
|
1654
|
-
body: await parseErrorBody(output.body, context),
|
|
1655
|
-
};
|
|
1656
|
-
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1657
|
-
switch (errorCode) {
|
|
1658
|
-
case "InternalServerException":
|
|
1659
|
-
case "com.amazonaws.comprehend#InternalServerException":
|
|
1660
|
-
throw await de_InternalServerExceptionRes(parsedOutput, context);
|
|
1661
|
-
case "InvalidRequestException":
|
|
1662
|
-
case "com.amazonaws.comprehend#InvalidRequestException":
|
|
1663
|
-
throw await de_InvalidRequestExceptionRes(parsedOutput, context);
|
|
1664
|
-
case "JobNotFoundException":
|
|
1665
|
-
case "com.amazonaws.comprehend#JobNotFoundException":
|
|
1666
|
-
throw await de_JobNotFoundExceptionRes(parsedOutput, context);
|
|
1667
|
-
case "TooManyRequestsException":
|
|
1668
|
-
case "com.amazonaws.comprehend#TooManyRequestsException":
|
|
1669
|
-
throw await de_TooManyRequestsExceptionRes(parsedOutput, context);
|
|
1670
|
-
default:
|
|
1671
|
-
const parsedBody = parsedOutput.body;
|
|
1672
|
-
return throwDefaultError({
|
|
1673
|
-
output,
|
|
1674
|
-
parsedBody,
|
|
1675
|
-
errorCode,
|
|
1676
|
-
});
|
|
1677
|
-
}
|
|
1678
|
-
};
|
|
1679
|
-
export const de_DescribeFlywheelCommand = async (output, context) => {
|
|
1680
|
-
if (output.statusCode >= 300) {
|
|
1681
|
-
return de_DescribeFlywheelCommandError(output, context);
|
|
1682
|
-
}
|
|
1683
|
-
const data = await parseBody(output.body, context);
|
|
1684
|
-
let contents = {};
|
|
1685
|
-
contents = de_DescribeFlywheelResponse(data, context);
|
|
1686
|
-
const response = {
|
|
1687
|
-
$metadata: deserializeMetadata(output),
|
|
1688
|
-
...contents,
|
|
1689
|
-
};
|
|
1690
|
-
return response;
|
|
1691
|
-
};
|
|
1692
|
-
const de_DescribeFlywheelCommandError = async (output, context) => {
|
|
1693
|
-
const parsedOutput = {
|
|
1694
|
-
...output,
|
|
1695
|
-
body: await parseErrorBody(output.body, context),
|
|
1696
|
-
};
|
|
1697
|
-
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1698
|
-
switch (errorCode) {
|
|
1699
|
-
case "InternalServerException":
|
|
1700
|
-
case "com.amazonaws.comprehend#InternalServerException":
|
|
1701
|
-
throw await de_InternalServerExceptionRes(parsedOutput, context);
|
|
1702
|
-
case "InvalidRequestException":
|
|
1703
|
-
case "com.amazonaws.comprehend#InvalidRequestException":
|
|
1704
|
-
throw await de_InvalidRequestExceptionRes(parsedOutput, context);
|
|
1705
|
-
case "ResourceNotFoundException":
|
|
1706
|
-
case "com.amazonaws.comprehend#ResourceNotFoundException":
|
|
1707
|
-
throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
|
|
1708
|
-
case "TooManyRequestsException":
|
|
1709
|
-
case "com.amazonaws.comprehend#TooManyRequestsException":
|
|
1710
|
-
throw await de_TooManyRequestsExceptionRes(parsedOutput, context);
|
|
1711
|
-
default:
|
|
1712
|
-
const parsedBody = parsedOutput.body;
|
|
1713
|
-
return throwDefaultError({
|
|
1714
|
-
output,
|
|
1715
|
-
parsedBody,
|
|
1716
|
-
errorCode,
|
|
1717
|
-
});
|
|
1718
|
-
}
|
|
1719
|
-
};
|
|
1720
|
-
export const de_DescribeFlywheelIterationCommand = async (output, context) => {
|
|
1721
|
-
if (output.statusCode >= 300) {
|
|
1722
|
-
return de_DescribeFlywheelIterationCommandError(output, context);
|
|
1723
|
-
}
|
|
1724
|
-
const data = await parseBody(output.body, context);
|
|
1725
|
-
let contents = {};
|
|
1726
|
-
contents = de_DescribeFlywheelIterationResponse(data, context);
|
|
1727
|
-
const response = {
|
|
1728
|
-
$metadata: deserializeMetadata(output),
|
|
1729
|
-
...contents,
|
|
1730
|
-
};
|
|
1731
|
-
return response;
|
|
1732
|
-
};
|
|
1733
|
-
const de_DescribeFlywheelIterationCommandError = async (output, context) => {
|
|
1734
|
-
const parsedOutput = {
|
|
1735
|
-
...output,
|
|
1736
|
-
body: await parseErrorBody(output.body, context),
|
|
1737
|
-
};
|
|
1738
|
-
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1739
|
-
switch (errorCode) {
|
|
1740
|
-
case "InternalServerException":
|
|
1741
|
-
case "com.amazonaws.comprehend#InternalServerException":
|
|
1742
|
-
throw await de_InternalServerExceptionRes(parsedOutput, context);
|
|
1743
|
-
case "InvalidRequestException":
|
|
1744
|
-
case "com.amazonaws.comprehend#InvalidRequestException":
|
|
1745
|
-
throw await de_InvalidRequestExceptionRes(parsedOutput, context);
|
|
1746
|
-
case "ResourceNotFoundException":
|
|
1747
|
-
case "com.amazonaws.comprehend#ResourceNotFoundException":
|
|
1748
|
-
throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
|
|
1749
|
-
case "TooManyRequestsException":
|
|
1750
|
-
case "com.amazonaws.comprehend#TooManyRequestsException":
|
|
1751
|
-
throw await de_TooManyRequestsExceptionRes(parsedOutput, context);
|
|
1752
|
-
default:
|
|
1753
|
-
const parsedBody = parsedOutput.body;
|
|
1754
|
-
return throwDefaultError({
|
|
1755
|
-
output,
|
|
1756
|
-
parsedBody,
|
|
1757
|
-
errorCode,
|
|
1758
|
-
});
|
|
1759
|
-
}
|
|
1760
|
-
};
|
|
1761
|
-
export const de_DescribeKeyPhrasesDetectionJobCommand = async (output, context) => {
|
|
1762
|
-
if (output.statusCode >= 300) {
|
|
1763
|
-
return de_DescribeKeyPhrasesDetectionJobCommandError(output, context);
|
|
1764
|
-
}
|
|
1765
|
-
const data = await parseBody(output.body, context);
|
|
1766
|
-
let contents = {};
|
|
1767
|
-
contents = de_DescribeKeyPhrasesDetectionJobResponse(data, context);
|
|
1768
|
-
const response = {
|
|
1769
|
-
$metadata: deserializeMetadata(output),
|
|
1770
|
-
...contents,
|
|
1771
|
-
};
|
|
1772
|
-
return response;
|
|
1773
|
-
};
|
|
1774
|
-
const de_DescribeKeyPhrasesDetectionJobCommandError = async (output, context) => {
|
|
1775
|
-
const parsedOutput = {
|
|
1776
|
-
...output,
|
|
1777
|
-
body: await parseErrorBody(output.body, context),
|
|
1778
|
-
};
|
|
1779
|
-
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1780
|
-
switch (errorCode) {
|
|
1781
|
-
case "InternalServerException":
|
|
1782
|
-
case "com.amazonaws.comprehend#InternalServerException":
|
|
1783
|
-
throw await de_InternalServerExceptionRes(parsedOutput, context);
|
|
1784
|
-
case "InvalidRequestException":
|
|
1785
|
-
case "com.amazonaws.comprehend#InvalidRequestException":
|
|
1786
|
-
throw await de_InvalidRequestExceptionRes(parsedOutput, context);
|
|
1787
|
-
case "JobNotFoundException":
|
|
1788
|
-
case "com.amazonaws.comprehend#JobNotFoundException":
|
|
1789
|
-
throw await de_JobNotFoundExceptionRes(parsedOutput, context);
|
|
1790
|
-
case "TooManyRequestsException":
|
|
1791
|
-
case "com.amazonaws.comprehend#TooManyRequestsException":
|
|
1792
|
-
throw await de_TooManyRequestsExceptionRes(parsedOutput, context);
|
|
1793
|
-
default:
|
|
1794
|
-
const parsedBody = parsedOutput.body;
|
|
1795
|
-
return throwDefaultError({
|
|
1796
|
-
output,
|
|
1797
|
-
parsedBody,
|
|
1798
|
-
errorCode,
|
|
1799
|
-
});
|
|
1800
|
-
}
|
|
1801
|
-
};
|
|
1802
|
-
export const de_DescribePiiEntitiesDetectionJobCommand = async (output, context) => {
|
|
1803
|
-
if (output.statusCode >= 300) {
|
|
1804
|
-
return de_DescribePiiEntitiesDetectionJobCommandError(output, context);
|
|
1805
|
-
}
|
|
1806
|
-
const data = await parseBody(output.body, context);
|
|
1807
|
-
let contents = {};
|
|
1808
|
-
contents = de_DescribePiiEntitiesDetectionJobResponse(data, context);
|
|
1809
|
-
const response = {
|
|
1810
|
-
$metadata: deserializeMetadata(output),
|
|
1811
|
-
...contents,
|
|
1812
|
-
};
|
|
1813
|
-
return response;
|
|
1814
|
-
};
|
|
1815
|
-
const de_DescribePiiEntitiesDetectionJobCommandError = async (output, context) => {
|
|
1816
|
-
const parsedOutput = {
|
|
1817
|
-
...output,
|
|
1818
|
-
body: await parseErrorBody(output.body, context),
|
|
1819
|
-
};
|
|
1820
|
-
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1821
|
-
switch (errorCode) {
|
|
1822
|
-
case "InternalServerException":
|
|
1823
|
-
case "com.amazonaws.comprehend#InternalServerException":
|
|
1824
|
-
throw await de_InternalServerExceptionRes(parsedOutput, context);
|
|
1825
|
-
case "InvalidRequestException":
|
|
1826
|
-
case "com.amazonaws.comprehend#InvalidRequestException":
|
|
1827
|
-
throw await de_InvalidRequestExceptionRes(parsedOutput, context);
|
|
1828
|
-
case "JobNotFoundException":
|
|
1829
|
-
case "com.amazonaws.comprehend#JobNotFoundException":
|
|
1830
|
-
throw await de_JobNotFoundExceptionRes(parsedOutput, context);
|
|
1831
|
-
case "TooManyRequestsException":
|
|
1832
|
-
case "com.amazonaws.comprehend#TooManyRequestsException":
|
|
1833
|
-
throw await de_TooManyRequestsExceptionRes(parsedOutput, context);
|
|
1834
|
-
default:
|
|
1835
|
-
const parsedBody = parsedOutput.body;
|
|
1836
|
-
return throwDefaultError({
|
|
1837
|
-
output,
|
|
1838
|
-
parsedBody,
|
|
1839
|
-
errorCode,
|
|
1840
|
-
});
|
|
1841
|
-
}
|
|
1842
|
-
};
|
|
1843
|
-
export const de_DescribeResourcePolicyCommand = async (output, context) => {
|
|
1844
|
-
if (output.statusCode >= 300) {
|
|
1845
|
-
return de_DescribeResourcePolicyCommandError(output, context);
|
|
1846
|
-
}
|
|
1847
|
-
const data = await parseBody(output.body, context);
|
|
1848
|
-
let contents = {};
|
|
1849
|
-
contents = de_DescribeResourcePolicyResponse(data, context);
|
|
1850
|
-
const response = {
|
|
1851
|
-
$metadata: deserializeMetadata(output),
|
|
1852
|
-
...contents,
|
|
1853
|
-
};
|
|
1854
|
-
return response;
|
|
1855
|
-
};
|
|
1856
|
-
const de_DescribeResourcePolicyCommandError = async (output, context) => {
|
|
1857
|
-
const parsedOutput = {
|
|
1858
|
-
...output,
|
|
1859
|
-
body: await parseErrorBody(output.body, context),
|
|
1860
|
-
};
|
|
1861
|
-
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1862
|
-
switch (errorCode) {
|
|
1863
|
-
case "InternalServerException":
|
|
1864
|
-
case "com.amazonaws.comprehend#InternalServerException":
|
|
1865
|
-
throw await de_InternalServerExceptionRes(parsedOutput, context);
|
|
1866
|
-
case "InvalidRequestException":
|
|
1867
|
-
case "com.amazonaws.comprehend#InvalidRequestException":
|
|
1868
|
-
throw await de_InvalidRequestExceptionRes(parsedOutput, context);
|
|
1869
|
-
case "ResourceNotFoundException":
|
|
1870
|
-
case "com.amazonaws.comprehend#ResourceNotFoundException":
|
|
1871
|
-
throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
|
|
1872
|
-
default:
|
|
1873
|
-
const parsedBody = parsedOutput.body;
|
|
1874
|
-
return throwDefaultError({
|
|
1875
|
-
output,
|
|
1876
|
-
parsedBody,
|
|
1877
|
-
errorCode,
|
|
1878
|
-
});
|
|
1879
|
-
}
|
|
1880
|
-
};
|
|
1881
|
-
export const de_DescribeSentimentDetectionJobCommand = async (output, context) => {
|
|
1882
|
-
if (output.statusCode >= 300) {
|
|
1883
|
-
return de_DescribeSentimentDetectionJobCommandError(output, context);
|
|
1884
|
-
}
|
|
1885
|
-
const data = await parseBody(output.body, context);
|
|
1886
|
-
let contents = {};
|
|
1887
|
-
contents = de_DescribeSentimentDetectionJobResponse(data, context);
|
|
1888
|
-
const response = {
|
|
1889
|
-
$metadata: deserializeMetadata(output),
|
|
1890
|
-
...contents,
|
|
1891
|
-
};
|
|
1892
|
-
return response;
|
|
1893
|
-
};
|
|
1894
|
-
const de_DescribeSentimentDetectionJobCommandError = async (output, context) => {
|
|
1895
|
-
const parsedOutput = {
|
|
1896
|
-
...output,
|
|
1897
|
-
body: await parseErrorBody(output.body, context),
|
|
1898
|
-
};
|
|
1899
|
-
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1900
|
-
switch (errorCode) {
|
|
1901
|
-
case "InternalServerException":
|
|
1902
|
-
case "com.amazonaws.comprehend#InternalServerException":
|
|
1903
|
-
throw await de_InternalServerExceptionRes(parsedOutput, context);
|
|
1904
|
-
case "InvalidRequestException":
|
|
1905
|
-
case "com.amazonaws.comprehend#InvalidRequestException":
|
|
1906
|
-
throw await de_InvalidRequestExceptionRes(parsedOutput, context);
|
|
1907
|
-
case "JobNotFoundException":
|
|
1908
|
-
case "com.amazonaws.comprehend#JobNotFoundException":
|
|
1909
|
-
throw await de_JobNotFoundExceptionRes(parsedOutput, context);
|
|
1910
|
-
case "TooManyRequestsException":
|
|
1911
|
-
case "com.amazonaws.comprehend#TooManyRequestsException":
|
|
1912
|
-
throw await de_TooManyRequestsExceptionRes(parsedOutput, context);
|
|
1913
|
-
default:
|
|
1914
|
-
const parsedBody = parsedOutput.body;
|
|
1915
|
-
return throwDefaultError({
|
|
1916
|
-
output,
|
|
1917
|
-
parsedBody,
|
|
1918
|
-
errorCode,
|
|
1919
|
-
});
|
|
1920
|
-
}
|
|
1921
|
-
};
|
|
1922
|
-
export const de_DescribeTargetedSentimentDetectionJobCommand = async (output, context) => {
|
|
1923
|
-
if (output.statusCode >= 300) {
|
|
1924
|
-
return de_DescribeTargetedSentimentDetectionJobCommandError(output, context);
|
|
1925
|
-
}
|
|
1926
|
-
const data = await parseBody(output.body, context);
|
|
1927
|
-
let contents = {};
|
|
1928
|
-
contents = de_DescribeTargetedSentimentDetectionJobResponse(data, context);
|
|
1929
|
-
const response = {
|
|
1930
|
-
$metadata: deserializeMetadata(output),
|
|
1931
|
-
...contents,
|
|
1932
|
-
};
|
|
1933
|
-
return response;
|
|
1934
|
-
};
|
|
1935
|
-
const de_DescribeTargetedSentimentDetectionJobCommandError = async (output, context) => {
|
|
1936
|
-
const parsedOutput = {
|
|
1937
|
-
...output,
|
|
1938
|
-
body: await parseErrorBody(output.body, context),
|
|
1939
|
-
};
|
|
1940
|
-
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1941
|
-
switch (errorCode) {
|
|
1942
|
-
case "InternalServerException":
|
|
1943
|
-
case "com.amazonaws.comprehend#InternalServerException":
|
|
1944
|
-
throw await de_InternalServerExceptionRes(parsedOutput, context);
|
|
1945
|
-
case "InvalidRequestException":
|
|
1946
|
-
case "com.amazonaws.comprehend#InvalidRequestException":
|
|
1947
|
-
throw await de_InvalidRequestExceptionRes(parsedOutput, context);
|
|
1948
|
-
case "JobNotFoundException":
|
|
1949
|
-
case "com.amazonaws.comprehend#JobNotFoundException":
|
|
1950
|
-
throw await de_JobNotFoundExceptionRes(parsedOutput, context);
|
|
1951
|
-
case "TooManyRequestsException":
|
|
1952
|
-
case "com.amazonaws.comprehend#TooManyRequestsException":
|
|
1953
|
-
throw await de_TooManyRequestsExceptionRes(parsedOutput, context);
|
|
1954
|
-
default:
|
|
1955
|
-
const parsedBody = parsedOutput.body;
|
|
1956
|
-
return throwDefaultError({
|
|
1957
|
-
output,
|
|
1958
|
-
parsedBody,
|
|
1959
|
-
errorCode,
|
|
1960
|
-
});
|
|
1961
|
-
}
|
|
1962
|
-
};
|
|
1963
|
-
export const de_DescribeTopicsDetectionJobCommand = async (output, context) => {
|
|
699
|
+
export const de_DeleteEndpointCommand = async (output, context) => {
|
|
1964
700
|
if (output.statusCode >= 300) {
|
|
1965
|
-
return
|
|
701
|
+
return de_CommandError(output, context);
|
|
1966
702
|
}
|
|
1967
703
|
const data = await parseBody(output.body, context);
|
|
1968
704
|
let contents = {};
|
|
1969
|
-
contents =
|
|
705
|
+
contents = _json(data);
|
|
1970
706
|
const response = {
|
|
1971
707
|
$metadata: deserializeMetadata(output),
|
|
1972
708
|
...contents,
|
|
1973
709
|
};
|
|
1974
710
|
return response;
|
|
1975
711
|
};
|
|
1976
|
-
const
|
|
1977
|
-
const parsedOutput = {
|
|
1978
|
-
...output,
|
|
1979
|
-
body: await parseErrorBody(output.body, context),
|
|
1980
|
-
};
|
|
1981
|
-
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1982
|
-
switch (errorCode) {
|
|
1983
|
-
case "InternalServerException":
|
|
1984
|
-
case "com.amazonaws.comprehend#InternalServerException":
|
|
1985
|
-
throw await de_InternalServerExceptionRes(parsedOutput, context);
|
|
1986
|
-
case "InvalidRequestException":
|
|
1987
|
-
case "com.amazonaws.comprehend#InvalidRequestException":
|
|
1988
|
-
throw await de_InvalidRequestExceptionRes(parsedOutput, context);
|
|
1989
|
-
case "JobNotFoundException":
|
|
1990
|
-
case "com.amazonaws.comprehend#JobNotFoundException":
|
|
1991
|
-
throw await de_JobNotFoundExceptionRes(parsedOutput, context);
|
|
1992
|
-
case "TooManyRequestsException":
|
|
1993
|
-
case "com.amazonaws.comprehend#TooManyRequestsException":
|
|
1994
|
-
throw await de_TooManyRequestsExceptionRes(parsedOutput, context);
|
|
1995
|
-
default:
|
|
1996
|
-
const parsedBody = parsedOutput.body;
|
|
1997
|
-
return throwDefaultError({
|
|
1998
|
-
output,
|
|
1999
|
-
parsedBody,
|
|
2000
|
-
errorCode,
|
|
2001
|
-
});
|
|
2002
|
-
}
|
|
2003
|
-
};
|
|
2004
|
-
export const de_DetectDominantLanguageCommand = async (output, context) => {
|
|
712
|
+
export const de_DeleteEntityRecognizerCommand = async (output, context) => {
|
|
2005
713
|
if (output.statusCode >= 300) {
|
|
2006
|
-
return
|
|
714
|
+
return de_CommandError(output, context);
|
|
2007
715
|
}
|
|
2008
716
|
const data = await parseBody(output.body, context);
|
|
2009
717
|
let contents = {};
|
|
2010
|
-
contents =
|
|
718
|
+
contents = _json(data);
|
|
2011
719
|
const response = {
|
|
2012
720
|
$metadata: deserializeMetadata(output),
|
|
2013
721
|
...contents,
|
|
2014
722
|
};
|
|
2015
723
|
return response;
|
|
2016
724
|
};
|
|
2017
|
-
const
|
|
2018
|
-
const parsedOutput = {
|
|
2019
|
-
...output,
|
|
2020
|
-
body: await parseErrorBody(output.body, context),
|
|
2021
|
-
};
|
|
2022
|
-
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
2023
|
-
switch (errorCode) {
|
|
2024
|
-
case "InternalServerException":
|
|
2025
|
-
case "com.amazonaws.comprehend#InternalServerException":
|
|
2026
|
-
throw await de_InternalServerExceptionRes(parsedOutput, context);
|
|
2027
|
-
case "InvalidRequestException":
|
|
2028
|
-
case "com.amazonaws.comprehend#InvalidRequestException":
|
|
2029
|
-
throw await de_InvalidRequestExceptionRes(parsedOutput, context);
|
|
2030
|
-
case "TextSizeLimitExceededException":
|
|
2031
|
-
case "com.amazonaws.comprehend#TextSizeLimitExceededException":
|
|
2032
|
-
throw await de_TextSizeLimitExceededExceptionRes(parsedOutput, context);
|
|
2033
|
-
default:
|
|
2034
|
-
const parsedBody = parsedOutput.body;
|
|
2035
|
-
return throwDefaultError({
|
|
2036
|
-
output,
|
|
2037
|
-
parsedBody,
|
|
2038
|
-
errorCode,
|
|
2039
|
-
});
|
|
2040
|
-
}
|
|
2041
|
-
};
|
|
2042
|
-
export const de_DetectEntitiesCommand = async (output, context) => {
|
|
725
|
+
export const de_DeleteFlywheelCommand = async (output, context) => {
|
|
2043
726
|
if (output.statusCode >= 300) {
|
|
2044
|
-
return
|
|
727
|
+
return de_CommandError(output, context);
|
|
2045
728
|
}
|
|
2046
729
|
const data = await parseBody(output.body, context);
|
|
2047
730
|
let contents = {};
|
|
2048
|
-
contents =
|
|
731
|
+
contents = _json(data);
|
|
2049
732
|
const response = {
|
|
2050
733
|
$metadata: deserializeMetadata(output),
|
|
2051
734
|
...contents,
|
|
2052
735
|
};
|
|
2053
736
|
return response;
|
|
2054
737
|
};
|
|
2055
|
-
const
|
|
2056
|
-
const parsedOutput = {
|
|
2057
|
-
...output,
|
|
2058
|
-
body: await parseErrorBody(output.body, context),
|
|
2059
|
-
};
|
|
2060
|
-
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
2061
|
-
switch (errorCode) {
|
|
2062
|
-
case "InternalServerException":
|
|
2063
|
-
case "com.amazonaws.comprehend#InternalServerException":
|
|
2064
|
-
throw await de_InternalServerExceptionRes(parsedOutput, context);
|
|
2065
|
-
case "InvalidRequestException":
|
|
2066
|
-
case "com.amazonaws.comprehend#InvalidRequestException":
|
|
2067
|
-
throw await de_InvalidRequestExceptionRes(parsedOutput, context);
|
|
2068
|
-
case "ResourceUnavailableException":
|
|
2069
|
-
case "com.amazonaws.comprehend#ResourceUnavailableException":
|
|
2070
|
-
throw await de_ResourceUnavailableExceptionRes(parsedOutput, context);
|
|
2071
|
-
case "TextSizeLimitExceededException":
|
|
2072
|
-
case "com.amazonaws.comprehend#TextSizeLimitExceededException":
|
|
2073
|
-
throw await de_TextSizeLimitExceededExceptionRes(parsedOutput, context);
|
|
2074
|
-
case "UnsupportedLanguageException":
|
|
2075
|
-
case "com.amazonaws.comprehend#UnsupportedLanguageException":
|
|
2076
|
-
throw await de_UnsupportedLanguageExceptionRes(parsedOutput, context);
|
|
2077
|
-
default:
|
|
2078
|
-
const parsedBody = parsedOutput.body;
|
|
2079
|
-
return throwDefaultError({
|
|
2080
|
-
output,
|
|
2081
|
-
parsedBody,
|
|
2082
|
-
errorCode,
|
|
2083
|
-
});
|
|
2084
|
-
}
|
|
2085
|
-
};
|
|
2086
|
-
export const de_DetectKeyPhrasesCommand = async (output, context) => {
|
|
738
|
+
export const de_DeleteResourcePolicyCommand = async (output, context) => {
|
|
2087
739
|
if (output.statusCode >= 300) {
|
|
2088
|
-
return
|
|
740
|
+
return de_CommandError(output, context);
|
|
2089
741
|
}
|
|
2090
742
|
const data = await parseBody(output.body, context);
|
|
2091
743
|
let contents = {};
|
|
2092
|
-
contents =
|
|
744
|
+
contents = _json(data);
|
|
2093
745
|
const response = {
|
|
2094
746
|
$metadata: deserializeMetadata(output),
|
|
2095
747
|
...contents,
|
|
2096
748
|
};
|
|
2097
749
|
return response;
|
|
2098
750
|
};
|
|
2099
|
-
const
|
|
2100
|
-
const parsedOutput = {
|
|
2101
|
-
...output,
|
|
2102
|
-
body: await parseErrorBody(output.body, context),
|
|
2103
|
-
};
|
|
2104
|
-
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
2105
|
-
switch (errorCode) {
|
|
2106
|
-
case "InternalServerException":
|
|
2107
|
-
case "com.amazonaws.comprehend#InternalServerException":
|
|
2108
|
-
throw await de_InternalServerExceptionRes(parsedOutput, context);
|
|
2109
|
-
case "InvalidRequestException":
|
|
2110
|
-
case "com.amazonaws.comprehend#InvalidRequestException":
|
|
2111
|
-
throw await de_InvalidRequestExceptionRes(parsedOutput, context);
|
|
2112
|
-
case "TextSizeLimitExceededException":
|
|
2113
|
-
case "com.amazonaws.comprehend#TextSizeLimitExceededException":
|
|
2114
|
-
throw await de_TextSizeLimitExceededExceptionRes(parsedOutput, context);
|
|
2115
|
-
case "UnsupportedLanguageException":
|
|
2116
|
-
case "com.amazonaws.comprehend#UnsupportedLanguageException":
|
|
2117
|
-
throw await de_UnsupportedLanguageExceptionRes(parsedOutput, context);
|
|
2118
|
-
default:
|
|
2119
|
-
const parsedBody = parsedOutput.body;
|
|
2120
|
-
return throwDefaultError({
|
|
2121
|
-
output,
|
|
2122
|
-
parsedBody,
|
|
2123
|
-
errorCode,
|
|
2124
|
-
});
|
|
2125
|
-
}
|
|
2126
|
-
};
|
|
2127
|
-
export const de_DetectPiiEntitiesCommand = async (output, context) => {
|
|
751
|
+
export const de_DescribeDatasetCommand = async (output, context) => {
|
|
2128
752
|
if (output.statusCode >= 300) {
|
|
2129
|
-
return
|
|
753
|
+
return de_CommandError(output, context);
|
|
2130
754
|
}
|
|
2131
755
|
const data = await parseBody(output.body, context);
|
|
2132
756
|
let contents = {};
|
|
2133
|
-
contents =
|
|
757
|
+
contents = de_DescribeDatasetResponse(data, context);
|
|
2134
758
|
const response = {
|
|
2135
759
|
$metadata: deserializeMetadata(output),
|
|
2136
760
|
...contents,
|
|
2137
761
|
};
|
|
2138
762
|
return response;
|
|
2139
763
|
};
|
|
2140
|
-
const
|
|
2141
|
-
const parsedOutput = {
|
|
2142
|
-
...output,
|
|
2143
|
-
body: await parseErrorBody(output.body, context),
|
|
2144
|
-
};
|
|
2145
|
-
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
2146
|
-
switch (errorCode) {
|
|
2147
|
-
case "InternalServerException":
|
|
2148
|
-
case "com.amazonaws.comprehend#InternalServerException":
|
|
2149
|
-
throw await de_InternalServerExceptionRes(parsedOutput, context);
|
|
2150
|
-
case "InvalidRequestException":
|
|
2151
|
-
case "com.amazonaws.comprehend#InvalidRequestException":
|
|
2152
|
-
throw await de_InvalidRequestExceptionRes(parsedOutput, context);
|
|
2153
|
-
case "TextSizeLimitExceededException":
|
|
2154
|
-
case "com.amazonaws.comprehend#TextSizeLimitExceededException":
|
|
2155
|
-
throw await de_TextSizeLimitExceededExceptionRes(parsedOutput, context);
|
|
2156
|
-
case "UnsupportedLanguageException":
|
|
2157
|
-
case "com.amazonaws.comprehend#UnsupportedLanguageException":
|
|
2158
|
-
throw await de_UnsupportedLanguageExceptionRes(parsedOutput, context);
|
|
2159
|
-
default:
|
|
2160
|
-
const parsedBody = parsedOutput.body;
|
|
2161
|
-
return throwDefaultError({
|
|
2162
|
-
output,
|
|
2163
|
-
parsedBody,
|
|
2164
|
-
errorCode,
|
|
2165
|
-
});
|
|
2166
|
-
}
|
|
2167
|
-
};
|
|
2168
|
-
export const de_DetectSentimentCommand = async (output, context) => {
|
|
764
|
+
export const de_DescribeDocumentClassificationJobCommand = async (output, context) => {
|
|
2169
765
|
if (output.statusCode >= 300) {
|
|
2170
|
-
return
|
|
766
|
+
return de_CommandError(output, context);
|
|
2171
767
|
}
|
|
2172
768
|
const data = await parseBody(output.body, context);
|
|
2173
769
|
let contents = {};
|
|
2174
|
-
contents =
|
|
770
|
+
contents = de_DescribeDocumentClassificationJobResponse(data, context);
|
|
2175
771
|
const response = {
|
|
2176
772
|
$metadata: deserializeMetadata(output),
|
|
2177
773
|
...contents,
|
|
2178
774
|
};
|
|
2179
775
|
return response;
|
|
2180
776
|
};
|
|
2181
|
-
const
|
|
2182
|
-
const parsedOutput = {
|
|
2183
|
-
...output,
|
|
2184
|
-
body: await parseErrorBody(output.body, context),
|
|
2185
|
-
};
|
|
2186
|
-
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
2187
|
-
switch (errorCode) {
|
|
2188
|
-
case "InternalServerException":
|
|
2189
|
-
case "com.amazonaws.comprehend#InternalServerException":
|
|
2190
|
-
throw await de_InternalServerExceptionRes(parsedOutput, context);
|
|
2191
|
-
case "InvalidRequestException":
|
|
2192
|
-
case "com.amazonaws.comprehend#InvalidRequestException":
|
|
2193
|
-
throw await de_InvalidRequestExceptionRes(parsedOutput, context);
|
|
2194
|
-
case "TextSizeLimitExceededException":
|
|
2195
|
-
case "com.amazonaws.comprehend#TextSizeLimitExceededException":
|
|
2196
|
-
throw await de_TextSizeLimitExceededExceptionRes(parsedOutput, context);
|
|
2197
|
-
case "UnsupportedLanguageException":
|
|
2198
|
-
case "com.amazonaws.comprehend#UnsupportedLanguageException":
|
|
2199
|
-
throw await de_UnsupportedLanguageExceptionRes(parsedOutput, context);
|
|
2200
|
-
default:
|
|
2201
|
-
const parsedBody = parsedOutput.body;
|
|
2202
|
-
return throwDefaultError({
|
|
2203
|
-
output,
|
|
2204
|
-
parsedBody,
|
|
2205
|
-
errorCode,
|
|
2206
|
-
});
|
|
2207
|
-
}
|
|
2208
|
-
};
|
|
2209
|
-
export const de_DetectSyntaxCommand = async (output, context) => {
|
|
777
|
+
export const de_DescribeDocumentClassifierCommand = async (output, context) => {
|
|
2210
778
|
if (output.statusCode >= 300) {
|
|
2211
|
-
return
|
|
779
|
+
return de_CommandError(output, context);
|
|
2212
780
|
}
|
|
2213
781
|
const data = await parseBody(output.body, context);
|
|
2214
782
|
let contents = {};
|
|
2215
|
-
contents =
|
|
783
|
+
contents = de_DescribeDocumentClassifierResponse(data, context);
|
|
2216
784
|
const response = {
|
|
2217
785
|
$metadata: deserializeMetadata(output),
|
|
2218
786
|
...contents,
|
|
2219
787
|
};
|
|
2220
788
|
return response;
|
|
2221
789
|
};
|
|
2222
|
-
const
|
|
2223
|
-
const parsedOutput = {
|
|
2224
|
-
...output,
|
|
2225
|
-
body: await parseErrorBody(output.body, context),
|
|
2226
|
-
};
|
|
2227
|
-
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
2228
|
-
switch (errorCode) {
|
|
2229
|
-
case "InternalServerException":
|
|
2230
|
-
case "com.amazonaws.comprehend#InternalServerException":
|
|
2231
|
-
throw await de_InternalServerExceptionRes(parsedOutput, context);
|
|
2232
|
-
case "InvalidRequestException":
|
|
2233
|
-
case "com.amazonaws.comprehend#InvalidRequestException":
|
|
2234
|
-
throw await de_InvalidRequestExceptionRes(parsedOutput, context);
|
|
2235
|
-
case "TextSizeLimitExceededException":
|
|
2236
|
-
case "com.amazonaws.comprehend#TextSizeLimitExceededException":
|
|
2237
|
-
throw await de_TextSizeLimitExceededExceptionRes(parsedOutput, context);
|
|
2238
|
-
case "UnsupportedLanguageException":
|
|
2239
|
-
case "com.amazonaws.comprehend#UnsupportedLanguageException":
|
|
2240
|
-
throw await de_UnsupportedLanguageExceptionRes(parsedOutput, context);
|
|
2241
|
-
default:
|
|
2242
|
-
const parsedBody = parsedOutput.body;
|
|
2243
|
-
return throwDefaultError({
|
|
2244
|
-
output,
|
|
2245
|
-
parsedBody,
|
|
2246
|
-
errorCode,
|
|
2247
|
-
});
|
|
2248
|
-
}
|
|
2249
|
-
};
|
|
2250
|
-
export const de_DetectTargetedSentimentCommand = async (output, context) => {
|
|
790
|
+
export const de_DescribeDominantLanguageDetectionJobCommand = async (output, context) => {
|
|
2251
791
|
if (output.statusCode >= 300) {
|
|
2252
|
-
return
|
|
792
|
+
return de_CommandError(output, context);
|
|
2253
793
|
}
|
|
2254
794
|
const data = await parseBody(output.body, context);
|
|
2255
795
|
let contents = {};
|
|
2256
|
-
contents =
|
|
796
|
+
contents = de_DescribeDominantLanguageDetectionJobResponse(data, context);
|
|
2257
797
|
const response = {
|
|
2258
798
|
$metadata: deserializeMetadata(output),
|
|
2259
799
|
...contents,
|
|
2260
800
|
};
|
|
2261
801
|
return response;
|
|
2262
802
|
};
|
|
2263
|
-
const
|
|
2264
|
-
|
|
2265
|
-
|
|
2266
|
-
body: await parseErrorBody(output.body, context),
|
|
2267
|
-
};
|
|
2268
|
-
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
2269
|
-
switch (errorCode) {
|
|
2270
|
-
case "InternalServerException":
|
|
2271
|
-
case "com.amazonaws.comprehend#InternalServerException":
|
|
2272
|
-
throw await de_InternalServerExceptionRes(parsedOutput, context);
|
|
2273
|
-
case "InvalidRequestException":
|
|
2274
|
-
case "com.amazonaws.comprehend#InvalidRequestException":
|
|
2275
|
-
throw await de_InvalidRequestExceptionRes(parsedOutput, context);
|
|
2276
|
-
case "TextSizeLimitExceededException":
|
|
2277
|
-
case "com.amazonaws.comprehend#TextSizeLimitExceededException":
|
|
2278
|
-
throw await de_TextSizeLimitExceededExceptionRes(parsedOutput, context);
|
|
2279
|
-
case "UnsupportedLanguageException":
|
|
2280
|
-
case "com.amazonaws.comprehend#UnsupportedLanguageException":
|
|
2281
|
-
throw await de_UnsupportedLanguageExceptionRes(parsedOutput, context);
|
|
2282
|
-
default:
|
|
2283
|
-
const parsedBody = parsedOutput.body;
|
|
2284
|
-
return throwDefaultError({
|
|
2285
|
-
output,
|
|
2286
|
-
parsedBody,
|
|
2287
|
-
errorCode,
|
|
2288
|
-
});
|
|
803
|
+
export const de_DescribeEndpointCommand = async (output, context) => {
|
|
804
|
+
if (output.statusCode >= 300) {
|
|
805
|
+
return de_CommandError(output, context);
|
|
2289
806
|
}
|
|
807
|
+
const data = await parseBody(output.body, context);
|
|
808
|
+
let contents = {};
|
|
809
|
+
contents = de_DescribeEndpointResponse(data, context);
|
|
810
|
+
const response = {
|
|
811
|
+
$metadata: deserializeMetadata(output),
|
|
812
|
+
...contents,
|
|
813
|
+
};
|
|
814
|
+
return response;
|
|
2290
815
|
};
|
|
2291
|
-
export const
|
|
816
|
+
export const de_DescribeEntitiesDetectionJobCommand = async (output, context) => {
|
|
2292
817
|
if (output.statusCode >= 300) {
|
|
2293
|
-
return
|
|
818
|
+
return de_CommandError(output, context);
|
|
2294
819
|
}
|
|
2295
820
|
const data = await parseBody(output.body, context);
|
|
2296
821
|
let contents = {};
|
|
2297
|
-
contents =
|
|
822
|
+
contents = de_DescribeEntitiesDetectionJobResponse(data, context);
|
|
2298
823
|
const response = {
|
|
2299
824
|
$metadata: deserializeMetadata(output),
|
|
2300
825
|
...contents,
|
|
2301
826
|
};
|
|
2302
827
|
return response;
|
|
2303
828
|
};
|
|
2304
|
-
const
|
|
2305
|
-
const parsedOutput = {
|
|
2306
|
-
...output,
|
|
2307
|
-
body: await parseErrorBody(output.body, context),
|
|
2308
|
-
};
|
|
2309
|
-
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
2310
|
-
switch (errorCode) {
|
|
2311
|
-
case "InternalServerException":
|
|
2312
|
-
case "com.amazonaws.comprehend#InternalServerException":
|
|
2313
|
-
throw await de_InternalServerExceptionRes(parsedOutput, context);
|
|
2314
|
-
case "InvalidRequestException":
|
|
2315
|
-
case "com.amazonaws.comprehend#InvalidRequestException":
|
|
2316
|
-
throw await de_InvalidRequestExceptionRes(parsedOutput, context);
|
|
2317
|
-
case "TextSizeLimitExceededException":
|
|
2318
|
-
case "com.amazonaws.comprehend#TextSizeLimitExceededException":
|
|
2319
|
-
throw await de_TextSizeLimitExceededExceptionRes(parsedOutput, context);
|
|
2320
|
-
case "UnsupportedLanguageException":
|
|
2321
|
-
case "com.amazonaws.comprehend#UnsupportedLanguageException":
|
|
2322
|
-
throw await de_UnsupportedLanguageExceptionRes(parsedOutput, context);
|
|
2323
|
-
default:
|
|
2324
|
-
const parsedBody = parsedOutput.body;
|
|
2325
|
-
return throwDefaultError({
|
|
2326
|
-
output,
|
|
2327
|
-
parsedBody,
|
|
2328
|
-
errorCode,
|
|
2329
|
-
});
|
|
2330
|
-
}
|
|
2331
|
-
};
|
|
2332
|
-
export const de_ImportModelCommand = async (output, context) => {
|
|
829
|
+
export const de_DescribeEntityRecognizerCommand = async (output, context) => {
|
|
2333
830
|
if (output.statusCode >= 300) {
|
|
2334
|
-
return
|
|
831
|
+
return de_CommandError(output, context);
|
|
2335
832
|
}
|
|
2336
833
|
const data = await parseBody(output.body, context);
|
|
2337
834
|
let contents = {};
|
|
2338
|
-
contents =
|
|
835
|
+
contents = de_DescribeEntityRecognizerResponse(data, context);
|
|
2339
836
|
const response = {
|
|
2340
837
|
$metadata: deserializeMetadata(output),
|
|
2341
838
|
...contents,
|
|
2342
839
|
};
|
|
2343
840
|
return response;
|
|
2344
841
|
};
|
|
2345
|
-
const
|
|
2346
|
-
const parsedOutput = {
|
|
2347
|
-
...output,
|
|
2348
|
-
body: await parseErrorBody(output.body, context),
|
|
2349
|
-
};
|
|
2350
|
-
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
2351
|
-
switch (errorCode) {
|
|
2352
|
-
case "InternalServerException":
|
|
2353
|
-
case "com.amazonaws.comprehend#InternalServerException":
|
|
2354
|
-
throw await de_InternalServerExceptionRes(parsedOutput, context);
|
|
2355
|
-
case "InvalidRequestException":
|
|
2356
|
-
case "com.amazonaws.comprehend#InvalidRequestException":
|
|
2357
|
-
throw await de_InvalidRequestExceptionRes(parsedOutput, context);
|
|
2358
|
-
case "KmsKeyValidationException":
|
|
2359
|
-
case "com.amazonaws.comprehend#KmsKeyValidationException":
|
|
2360
|
-
throw await de_KmsKeyValidationExceptionRes(parsedOutput, context);
|
|
2361
|
-
case "ResourceInUseException":
|
|
2362
|
-
case "com.amazonaws.comprehend#ResourceInUseException":
|
|
2363
|
-
throw await de_ResourceInUseExceptionRes(parsedOutput, context);
|
|
2364
|
-
case "ResourceLimitExceededException":
|
|
2365
|
-
case "com.amazonaws.comprehend#ResourceLimitExceededException":
|
|
2366
|
-
throw await de_ResourceLimitExceededExceptionRes(parsedOutput, context);
|
|
2367
|
-
case "ResourceNotFoundException":
|
|
2368
|
-
case "com.amazonaws.comprehend#ResourceNotFoundException":
|
|
2369
|
-
throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
|
|
2370
|
-
case "ResourceUnavailableException":
|
|
2371
|
-
case "com.amazonaws.comprehend#ResourceUnavailableException":
|
|
2372
|
-
throw await de_ResourceUnavailableExceptionRes(parsedOutput, context);
|
|
2373
|
-
case "TooManyRequestsException":
|
|
2374
|
-
case "com.amazonaws.comprehend#TooManyRequestsException":
|
|
2375
|
-
throw await de_TooManyRequestsExceptionRes(parsedOutput, context);
|
|
2376
|
-
case "TooManyTagsException":
|
|
2377
|
-
case "com.amazonaws.comprehend#TooManyTagsException":
|
|
2378
|
-
throw await de_TooManyTagsExceptionRes(parsedOutput, context);
|
|
2379
|
-
default:
|
|
2380
|
-
const parsedBody = parsedOutput.body;
|
|
2381
|
-
return throwDefaultError({
|
|
2382
|
-
output,
|
|
2383
|
-
parsedBody,
|
|
2384
|
-
errorCode,
|
|
2385
|
-
});
|
|
2386
|
-
}
|
|
2387
|
-
};
|
|
2388
|
-
export const de_ListDatasetsCommand = async (output, context) => {
|
|
842
|
+
export const de_DescribeEventsDetectionJobCommand = async (output, context) => {
|
|
2389
843
|
if (output.statusCode >= 300) {
|
|
2390
|
-
return
|
|
844
|
+
return de_CommandError(output, context);
|
|
2391
845
|
}
|
|
2392
846
|
const data = await parseBody(output.body, context);
|
|
2393
847
|
let contents = {};
|
|
2394
|
-
contents =
|
|
848
|
+
contents = de_DescribeEventsDetectionJobResponse(data, context);
|
|
2395
849
|
const response = {
|
|
2396
850
|
$metadata: deserializeMetadata(output),
|
|
2397
851
|
...contents,
|
|
2398
852
|
};
|
|
2399
853
|
return response;
|
|
2400
854
|
};
|
|
2401
|
-
const
|
|
2402
|
-
const parsedOutput = {
|
|
2403
|
-
...output,
|
|
2404
|
-
body: await parseErrorBody(output.body, context),
|
|
2405
|
-
};
|
|
2406
|
-
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
2407
|
-
switch (errorCode) {
|
|
2408
|
-
case "InternalServerException":
|
|
2409
|
-
case "com.amazonaws.comprehend#InternalServerException":
|
|
2410
|
-
throw await de_InternalServerExceptionRes(parsedOutput, context);
|
|
2411
|
-
case "InvalidFilterException":
|
|
2412
|
-
case "com.amazonaws.comprehend#InvalidFilterException":
|
|
2413
|
-
throw await de_InvalidFilterExceptionRes(parsedOutput, context);
|
|
2414
|
-
case "InvalidRequestException":
|
|
2415
|
-
case "com.amazonaws.comprehend#InvalidRequestException":
|
|
2416
|
-
throw await de_InvalidRequestExceptionRes(parsedOutput, context);
|
|
2417
|
-
case "ResourceNotFoundException":
|
|
2418
|
-
case "com.amazonaws.comprehend#ResourceNotFoundException":
|
|
2419
|
-
throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
|
|
2420
|
-
case "TooManyRequestsException":
|
|
2421
|
-
case "com.amazonaws.comprehend#TooManyRequestsException":
|
|
2422
|
-
throw await de_TooManyRequestsExceptionRes(parsedOutput, context);
|
|
2423
|
-
default:
|
|
2424
|
-
const parsedBody = parsedOutput.body;
|
|
2425
|
-
return throwDefaultError({
|
|
2426
|
-
output,
|
|
2427
|
-
parsedBody,
|
|
2428
|
-
errorCode,
|
|
2429
|
-
});
|
|
2430
|
-
}
|
|
2431
|
-
};
|
|
2432
|
-
export const de_ListDocumentClassificationJobsCommand = async (output, context) => {
|
|
855
|
+
export const de_DescribeFlywheelCommand = async (output, context) => {
|
|
2433
856
|
if (output.statusCode >= 300) {
|
|
2434
|
-
return
|
|
857
|
+
return de_CommandError(output, context);
|
|
2435
858
|
}
|
|
2436
859
|
const data = await parseBody(output.body, context);
|
|
2437
860
|
let contents = {};
|
|
2438
|
-
contents =
|
|
861
|
+
contents = de_DescribeFlywheelResponse(data, context);
|
|
2439
862
|
const response = {
|
|
2440
863
|
$metadata: deserializeMetadata(output),
|
|
2441
864
|
...contents,
|
|
2442
865
|
};
|
|
2443
866
|
return response;
|
|
2444
867
|
};
|
|
2445
|
-
const
|
|
2446
|
-
const parsedOutput = {
|
|
2447
|
-
...output,
|
|
2448
|
-
body: await parseErrorBody(output.body, context),
|
|
2449
|
-
};
|
|
2450
|
-
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
2451
|
-
switch (errorCode) {
|
|
2452
|
-
case "InternalServerException":
|
|
2453
|
-
case "com.amazonaws.comprehend#InternalServerException":
|
|
2454
|
-
throw await de_InternalServerExceptionRes(parsedOutput, context);
|
|
2455
|
-
case "InvalidFilterException":
|
|
2456
|
-
case "com.amazonaws.comprehend#InvalidFilterException":
|
|
2457
|
-
throw await de_InvalidFilterExceptionRes(parsedOutput, context);
|
|
2458
|
-
case "InvalidRequestException":
|
|
2459
|
-
case "com.amazonaws.comprehend#InvalidRequestException":
|
|
2460
|
-
throw await de_InvalidRequestExceptionRes(parsedOutput, context);
|
|
2461
|
-
case "TooManyRequestsException":
|
|
2462
|
-
case "com.amazonaws.comprehend#TooManyRequestsException":
|
|
2463
|
-
throw await de_TooManyRequestsExceptionRes(parsedOutput, context);
|
|
2464
|
-
default:
|
|
2465
|
-
const parsedBody = parsedOutput.body;
|
|
2466
|
-
return throwDefaultError({
|
|
2467
|
-
output,
|
|
2468
|
-
parsedBody,
|
|
2469
|
-
errorCode,
|
|
2470
|
-
});
|
|
2471
|
-
}
|
|
2472
|
-
};
|
|
2473
|
-
export const de_ListDocumentClassifiersCommand = async (output, context) => {
|
|
868
|
+
export const de_DescribeFlywheelIterationCommand = async (output, context) => {
|
|
2474
869
|
if (output.statusCode >= 300) {
|
|
2475
|
-
return
|
|
870
|
+
return de_CommandError(output, context);
|
|
2476
871
|
}
|
|
2477
872
|
const data = await parseBody(output.body, context);
|
|
2478
873
|
let contents = {};
|
|
2479
|
-
contents =
|
|
874
|
+
contents = de_DescribeFlywheelIterationResponse(data, context);
|
|
2480
875
|
const response = {
|
|
2481
876
|
$metadata: deserializeMetadata(output),
|
|
2482
877
|
...contents,
|
|
2483
878
|
};
|
|
2484
879
|
return response;
|
|
2485
880
|
};
|
|
2486
|
-
const
|
|
2487
|
-
|
|
2488
|
-
|
|
2489
|
-
body: await parseErrorBody(output.body, context),
|
|
2490
|
-
};
|
|
2491
|
-
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
2492
|
-
switch (errorCode) {
|
|
2493
|
-
case "InternalServerException":
|
|
2494
|
-
case "com.amazonaws.comprehend#InternalServerException":
|
|
2495
|
-
throw await de_InternalServerExceptionRes(parsedOutput, context);
|
|
2496
|
-
case "InvalidFilterException":
|
|
2497
|
-
case "com.amazonaws.comprehend#InvalidFilterException":
|
|
2498
|
-
throw await de_InvalidFilterExceptionRes(parsedOutput, context);
|
|
2499
|
-
case "InvalidRequestException":
|
|
2500
|
-
case "com.amazonaws.comprehend#InvalidRequestException":
|
|
2501
|
-
throw await de_InvalidRequestExceptionRes(parsedOutput, context);
|
|
2502
|
-
case "TooManyRequestsException":
|
|
2503
|
-
case "com.amazonaws.comprehend#TooManyRequestsException":
|
|
2504
|
-
throw await de_TooManyRequestsExceptionRes(parsedOutput, context);
|
|
2505
|
-
default:
|
|
2506
|
-
const parsedBody = parsedOutput.body;
|
|
2507
|
-
return throwDefaultError({
|
|
2508
|
-
output,
|
|
2509
|
-
parsedBody,
|
|
2510
|
-
errorCode,
|
|
2511
|
-
});
|
|
881
|
+
export const de_DescribeKeyPhrasesDetectionJobCommand = async (output, context) => {
|
|
882
|
+
if (output.statusCode >= 300) {
|
|
883
|
+
return de_CommandError(output, context);
|
|
2512
884
|
}
|
|
885
|
+
const data = await parseBody(output.body, context);
|
|
886
|
+
let contents = {};
|
|
887
|
+
contents = de_DescribeKeyPhrasesDetectionJobResponse(data, context);
|
|
888
|
+
const response = {
|
|
889
|
+
$metadata: deserializeMetadata(output),
|
|
890
|
+
...contents,
|
|
891
|
+
};
|
|
892
|
+
return response;
|
|
2513
893
|
};
|
|
2514
|
-
export const
|
|
894
|
+
export const de_DescribePiiEntitiesDetectionJobCommand = async (output, context) => {
|
|
2515
895
|
if (output.statusCode >= 300) {
|
|
2516
|
-
return
|
|
896
|
+
return de_CommandError(output, context);
|
|
2517
897
|
}
|
|
2518
898
|
const data = await parseBody(output.body, context);
|
|
2519
899
|
let contents = {};
|
|
2520
|
-
contents =
|
|
900
|
+
contents = de_DescribePiiEntitiesDetectionJobResponse(data, context);
|
|
2521
901
|
const response = {
|
|
2522
902
|
$metadata: deserializeMetadata(output),
|
|
2523
903
|
...contents,
|
|
2524
904
|
};
|
|
2525
905
|
return response;
|
|
2526
906
|
};
|
|
2527
|
-
const
|
|
2528
|
-
|
|
2529
|
-
|
|
2530
|
-
body: await parseErrorBody(output.body, context),
|
|
2531
|
-
};
|
|
2532
|
-
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
2533
|
-
switch (errorCode) {
|
|
2534
|
-
case "InternalServerException":
|
|
2535
|
-
case "com.amazonaws.comprehend#InternalServerException":
|
|
2536
|
-
throw await de_InternalServerExceptionRes(parsedOutput, context);
|
|
2537
|
-
case "InvalidRequestException":
|
|
2538
|
-
case "com.amazonaws.comprehend#InvalidRequestException":
|
|
2539
|
-
throw await de_InvalidRequestExceptionRes(parsedOutput, context);
|
|
2540
|
-
case "TooManyRequestsException":
|
|
2541
|
-
case "com.amazonaws.comprehend#TooManyRequestsException":
|
|
2542
|
-
throw await de_TooManyRequestsExceptionRes(parsedOutput, context);
|
|
2543
|
-
default:
|
|
2544
|
-
const parsedBody = parsedOutput.body;
|
|
2545
|
-
return throwDefaultError({
|
|
2546
|
-
output,
|
|
2547
|
-
parsedBody,
|
|
2548
|
-
errorCode,
|
|
2549
|
-
});
|
|
907
|
+
export const de_DescribeResourcePolicyCommand = async (output, context) => {
|
|
908
|
+
if (output.statusCode >= 300) {
|
|
909
|
+
return de_CommandError(output, context);
|
|
2550
910
|
}
|
|
911
|
+
const data = await parseBody(output.body, context);
|
|
912
|
+
let contents = {};
|
|
913
|
+
contents = de_DescribeResourcePolicyResponse(data, context);
|
|
914
|
+
const response = {
|
|
915
|
+
$metadata: deserializeMetadata(output),
|
|
916
|
+
...contents,
|
|
917
|
+
};
|
|
918
|
+
return response;
|
|
2551
919
|
};
|
|
2552
|
-
export const
|
|
920
|
+
export const de_DescribeSentimentDetectionJobCommand = async (output, context) => {
|
|
2553
921
|
if (output.statusCode >= 300) {
|
|
2554
|
-
return
|
|
922
|
+
return de_CommandError(output, context);
|
|
2555
923
|
}
|
|
2556
924
|
const data = await parseBody(output.body, context);
|
|
2557
925
|
let contents = {};
|
|
2558
|
-
contents =
|
|
926
|
+
contents = de_DescribeSentimentDetectionJobResponse(data, context);
|
|
2559
927
|
const response = {
|
|
2560
928
|
$metadata: deserializeMetadata(output),
|
|
2561
929
|
...contents,
|
|
2562
930
|
};
|
|
2563
931
|
return response;
|
|
2564
932
|
};
|
|
2565
|
-
const
|
|
2566
|
-
|
|
2567
|
-
|
|
2568
|
-
body: await parseErrorBody(output.body, context),
|
|
2569
|
-
};
|
|
2570
|
-
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
2571
|
-
switch (errorCode) {
|
|
2572
|
-
case "InternalServerException":
|
|
2573
|
-
case "com.amazonaws.comprehend#InternalServerException":
|
|
2574
|
-
throw await de_InternalServerExceptionRes(parsedOutput, context);
|
|
2575
|
-
case "InvalidFilterException":
|
|
2576
|
-
case "com.amazonaws.comprehend#InvalidFilterException":
|
|
2577
|
-
throw await de_InvalidFilterExceptionRes(parsedOutput, context);
|
|
2578
|
-
case "InvalidRequestException":
|
|
2579
|
-
case "com.amazonaws.comprehend#InvalidRequestException":
|
|
2580
|
-
throw await de_InvalidRequestExceptionRes(parsedOutput, context);
|
|
2581
|
-
case "TooManyRequestsException":
|
|
2582
|
-
case "com.amazonaws.comprehend#TooManyRequestsException":
|
|
2583
|
-
throw await de_TooManyRequestsExceptionRes(parsedOutput, context);
|
|
2584
|
-
default:
|
|
2585
|
-
const parsedBody = parsedOutput.body;
|
|
2586
|
-
return throwDefaultError({
|
|
2587
|
-
output,
|
|
2588
|
-
parsedBody,
|
|
2589
|
-
errorCode,
|
|
2590
|
-
});
|
|
933
|
+
export const de_DescribeTargetedSentimentDetectionJobCommand = async (output, context) => {
|
|
934
|
+
if (output.statusCode >= 300) {
|
|
935
|
+
return de_CommandError(output, context);
|
|
2591
936
|
}
|
|
937
|
+
const data = await parseBody(output.body, context);
|
|
938
|
+
let contents = {};
|
|
939
|
+
contents = de_DescribeTargetedSentimentDetectionJobResponse(data, context);
|
|
940
|
+
const response = {
|
|
941
|
+
$metadata: deserializeMetadata(output),
|
|
942
|
+
...contents,
|
|
943
|
+
};
|
|
944
|
+
return response;
|
|
2592
945
|
};
|
|
2593
|
-
export const
|
|
946
|
+
export const de_DescribeTopicsDetectionJobCommand = async (output, context) => {
|
|
2594
947
|
if (output.statusCode >= 300) {
|
|
2595
|
-
return
|
|
948
|
+
return de_CommandError(output, context);
|
|
2596
949
|
}
|
|
2597
950
|
const data = await parseBody(output.body, context);
|
|
2598
951
|
let contents = {};
|
|
2599
|
-
contents =
|
|
952
|
+
contents = de_DescribeTopicsDetectionJobResponse(data, context);
|
|
2600
953
|
const response = {
|
|
2601
954
|
$metadata: deserializeMetadata(output),
|
|
2602
955
|
...contents,
|
|
2603
956
|
};
|
|
2604
957
|
return response;
|
|
2605
958
|
};
|
|
2606
|
-
const
|
|
2607
|
-
const parsedOutput = {
|
|
2608
|
-
...output,
|
|
2609
|
-
body: await parseErrorBody(output.body, context),
|
|
2610
|
-
};
|
|
2611
|
-
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
2612
|
-
switch (errorCode) {
|
|
2613
|
-
case "InternalServerException":
|
|
2614
|
-
case "com.amazonaws.comprehend#InternalServerException":
|
|
2615
|
-
throw await de_InternalServerExceptionRes(parsedOutput, context);
|
|
2616
|
-
case "InvalidRequestException":
|
|
2617
|
-
case "com.amazonaws.comprehend#InvalidRequestException":
|
|
2618
|
-
throw await de_InvalidRequestExceptionRes(parsedOutput, context);
|
|
2619
|
-
case "TooManyRequestsException":
|
|
2620
|
-
case "com.amazonaws.comprehend#TooManyRequestsException":
|
|
2621
|
-
throw await de_TooManyRequestsExceptionRes(parsedOutput, context);
|
|
2622
|
-
default:
|
|
2623
|
-
const parsedBody = parsedOutput.body;
|
|
2624
|
-
return throwDefaultError({
|
|
2625
|
-
output,
|
|
2626
|
-
parsedBody,
|
|
2627
|
-
errorCode,
|
|
2628
|
-
});
|
|
2629
|
-
}
|
|
2630
|
-
};
|
|
2631
|
-
export const de_ListEntitiesDetectionJobsCommand = async (output, context) => {
|
|
959
|
+
export const de_DetectDominantLanguageCommand = async (output, context) => {
|
|
2632
960
|
if (output.statusCode >= 300) {
|
|
2633
|
-
return
|
|
961
|
+
return de_CommandError(output, context);
|
|
2634
962
|
}
|
|
2635
963
|
const data = await parseBody(output.body, context);
|
|
2636
964
|
let contents = {};
|
|
2637
|
-
contents =
|
|
965
|
+
contents = de_DetectDominantLanguageResponse(data, context);
|
|
2638
966
|
const response = {
|
|
2639
967
|
$metadata: deserializeMetadata(output),
|
|
2640
968
|
...contents,
|
|
2641
969
|
};
|
|
2642
970
|
return response;
|
|
2643
971
|
};
|
|
2644
|
-
const
|
|
2645
|
-
const parsedOutput = {
|
|
2646
|
-
...output,
|
|
2647
|
-
body: await parseErrorBody(output.body, context),
|
|
2648
|
-
};
|
|
2649
|
-
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
2650
|
-
switch (errorCode) {
|
|
2651
|
-
case "InternalServerException":
|
|
2652
|
-
case "com.amazonaws.comprehend#InternalServerException":
|
|
2653
|
-
throw await de_InternalServerExceptionRes(parsedOutput, context);
|
|
2654
|
-
case "InvalidFilterException":
|
|
2655
|
-
case "com.amazonaws.comprehend#InvalidFilterException":
|
|
2656
|
-
throw await de_InvalidFilterExceptionRes(parsedOutput, context);
|
|
2657
|
-
case "InvalidRequestException":
|
|
2658
|
-
case "com.amazonaws.comprehend#InvalidRequestException":
|
|
2659
|
-
throw await de_InvalidRequestExceptionRes(parsedOutput, context);
|
|
2660
|
-
case "TooManyRequestsException":
|
|
2661
|
-
case "com.amazonaws.comprehend#TooManyRequestsException":
|
|
2662
|
-
throw await de_TooManyRequestsExceptionRes(parsedOutput, context);
|
|
2663
|
-
default:
|
|
2664
|
-
const parsedBody = parsedOutput.body;
|
|
2665
|
-
return throwDefaultError({
|
|
2666
|
-
output,
|
|
2667
|
-
parsedBody,
|
|
2668
|
-
errorCode,
|
|
2669
|
-
});
|
|
2670
|
-
}
|
|
2671
|
-
};
|
|
2672
|
-
export const de_ListEntityRecognizersCommand = async (output, context) => {
|
|
972
|
+
export const de_DetectEntitiesCommand = async (output, context) => {
|
|
2673
973
|
if (output.statusCode >= 300) {
|
|
2674
|
-
return
|
|
974
|
+
return de_CommandError(output, context);
|
|
2675
975
|
}
|
|
2676
976
|
const data = await parseBody(output.body, context);
|
|
2677
977
|
let contents = {};
|
|
2678
|
-
contents =
|
|
978
|
+
contents = de_DetectEntitiesResponse(data, context);
|
|
2679
979
|
const response = {
|
|
2680
980
|
$metadata: deserializeMetadata(output),
|
|
2681
981
|
...contents,
|
|
2682
982
|
};
|
|
2683
983
|
return response;
|
|
2684
984
|
};
|
|
2685
|
-
const
|
|
2686
|
-
const parsedOutput = {
|
|
2687
|
-
...output,
|
|
2688
|
-
body: await parseErrorBody(output.body, context),
|
|
2689
|
-
};
|
|
2690
|
-
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
2691
|
-
switch (errorCode) {
|
|
2692
|
-
case "InternalServerException":
|
|
2693
|
-
case "com.amazonaws.comprehend#InternalServerException":
|
|
2694
|
-
throw await de_InternalServerExceptionRes(parsedOutput, context);
|
|
2695
|
-
case "InvalidFilterException":
|
|
2696
|
-
case "com.amazonaws.comprehend#InvalidFilterException":
|
|
2697
|
-
throw await de_InvalidFilterExceptionRes(parsedOutput, context);
|
|
2698
|
-
case "InvalidRequestException":
|
|
2699
|
-
case "com.amazonaws.comprehend#InvalidRequestException":
|
|
2700
|
-
throw await de_InvalidRequestExceptionRes(parsedOutput, context);
|
|
2701
|
-
case "TooManyRequestsException":
|
|
2702
|
-
case "com.amazonaws.comprehend#TooManyRequestsException":
|
|
2703
|
-
throw await de_TooManyRequestsExceptionRes(parsedOutput, context);
|
|
2704
|
-
default:
|
|
2705
|
-
const parsedBody = parsedOutput.body;
|
|
2706
|
-
return throwDefaultError({
|
|
2707
|
-
output,
|
|
2708
|
-
parsedBody,
|
|
2709
|
-
errorCode,
|
|
2710
|
-
});
|
|
2711
|
-
}
|
|
2712
|
-
};
|
|
2713
|
-
export const de_ListEntityRecognizerSummariesCommand = async (output, context) => {
|
|
985
|
+
export const de_DetectKeyPhrasesCommand = async (output, context) => {
|
|
2714
986
|
if (output.statusCode >= 300) {
|
|
2715
|
-
return
|
|
987
|
+
return de_CommandError(output, context);
|
|
2716
988
|
}
|
|
2717
989
|
const data = await parseBody(output.body, context);
|
|
2718
990
|
let contents = {};
|
|
2719
|
-
contents =
|
|
991
|
+
contents = de_DetectKeyPhrasesResponse(data, context);
|
|
2720
992
|
const response = {
|
|
2721
993
|
$metadata: deserializeMetadata(output),
|
|
2722
994
|
...contents,
|
|
2723
995
|
};
|
|
2724
996
|
return response;
|
|
2725
997
|
};
|
|
2726
|
-
const
|
|
2727
|
-
const parsedOutput = {
|
|
2728
|
-
...output,
|
|
2729
|
-
body: await parseErrorBody(output.body, context),
|
|
2730
|
-
};
|
|
2731
|
-
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
2732
|
-
switch (errorCode) {
|
|
2733
|
-
case "InternalServerException":
|
|
2734
|
-
case "com.amazonaws.comprehend#InternalServerException":
|
|
2735
|
-
throw await de_InternalServerExceptionRes(parsedOutput, context);
|
|
2736
|
-
case "InvalidRequestException":
|
|
2737
|
-
case "com.amazonaws.comprehend#InvalidRequestException":
|
|
2738
|
-
throw await de_InvalidRequestExceptionRes(parsedOutput, context);
|
|
2739
|
-
case "TooManyRequestsException":
|
|
2740
|
-
case "com.amazonaws.comprehend#TooManyRequestsException":
|
|
2741
|
-
throw await de_TooManyRequestsExceptionRes(parsedOutput, context);
|
|
2742
|
-
default:
|
|
2743
|
-
const parsedBody = parsedOutput.body;
|
|
2744
|
-
return throwDefaultError({
|
|
2745
|
-
output,
|
|
2746
|
-
parsedBody,
|
|
2747
|
-
errorCode,
|
|
2748
|
-
});
|
|
2749
|
-
}
|
|
2750
|
-
};
|
|
2751
|
-
export const de_ListEventsDetectionJobsCommand = async (output, context) => {
|
|
998
|
+
export const de_DetectPiiEntitiesCommand = async (output, context) => {
|
|
2752
999
|
if (output.statusCode >= 300) {
|
|
2753
|
-
return
|
|
1000
|
+
return de_CommandError(output, context);
|
|
2754
1001
|
}
|
|
2755
1002
|
const data = await parseBody(output.body, context);
|
|
2756
1003
|
let contents = {};
|
|
2757
|
-
contents =
|
|
1004
|
+
contents = de_DetectPiiEntitiesResponse(data, context);
|
|
2758
1005
|
const response = {
|
|
2759
1006
|
$metadata: deserializeMetadata(output),
|
|
2760
1007
|
...contents,
|
|
2761
1008
|
};
|
|
2762
1009
|
return response;
|
|
2763
1010
|
};
|
|
2764
|
-
const
|
|
2765
|
-
const parsedOutput = {
|
|
2766
|
-
...output,
|
|
2767
|
-
body: await parseErrorBody(output.body, context),
|
|
2768
|
-
};
|
|
2769
|
-
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
2770
|
-
switch (errorCode) {
|
|
2771
|
-
case "InternalServerException":
|
|
2772
|
-
case "com.amazonaws.comprehend#InternalServerException":
|
|
2773
|
-
throw await de_InternalServerExceptionRes(parsedOutput, context);
|
|
2774
|
-
case "InvalidFilterException":
|
|
2775
|
-
case "com.amazonaws.comprehend#InvalidFilterException":
|
|
2776
|
-
throw await de_InvalidFilterExceptionRes(parsedOutput, context);
|
|
2777
|
-
case "InvalidRequestException":
|
|
2778
|
-
case "com.amazonaws.comprehend#InvalidRequestException":
|
|
2779
|
-
throw await de_InvalidRequestExceptionRes(parsedOutput, context);
|
|
2780
|
-
case "TooManyRequestsException":
|
|
2781
|
-
case "com.amazonaws.comprehend#TooManyRequestsException":
|
|
2782
|
-
throw await de_TooManyRequestsExceptionRes(parsedOutput, context);
|
|
2783
|
-
default:
|
|
2784
|
-
const parsedBody = parsedOutput.body;
|
|
2785
|
-
return throwDefaultError({
|
|
2786
|
-
output,
|
|
2787
|
-
parsedBody,
|
|
2788
|
-
errorCode,
|
|
2789
|
-
});
|
|
2790
|
-
}
|
|
2791
|
-
};
|
|
2792
|
-
export const de_ListFlywheelIterationHistoryCommand = async (output, context) => {
|
|
1011
|
+
export const de_DetectSentimentCommand = async (output, context) => {
|
|
2793
1012
|
if (output.statusCode >= 300) {
|
|
2794
|
-
return
|
|
1013
|
+
return de_CommandError(output, context);
|
|
2795
1014
|
}
|
|
2796
1015
|
const data = await parseBody(output.body, context);
|
|
2797
1016
|
let contents = {};
|
|
2798
|
-
contents =
|
|
1017
|
+
contents = de_DetectSentimentResponse(data, context);
|
|
2799
1018
|
const response = {
|
|
2800
1019
|
$metadata: deserializeMetadata(output),
|
|
2801
1020
|
...contents,
|
|
2802
1021
|
};
|
|
2803
1022
|
return response;
|
|
2804
1023
|
};
|
|
2805
|
-
const
|
|
2806
|
-
const parsedOutput = {
|
|
2807
|
-
...output,
|
|
2808
|
-
body: await parseErrorBody(output.body, context),
|
|
2809
|
-
};
|
|
2810
|
-
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
2811
|
-
switch (errorCode) {
|
|
2812
|
-
case "InternalServerException":
|
|
2813
|
-
case "com.amazonaws.comprehend#InternalServerException":
|
|
2814
|
-
throw await de_InternalServerExceptionRes(parsedOutput, context);
|
|
2815
|
-
case "InvalidFilterException":
|
|
2816
|
-
case "com.amazonaws.comprehend#InvalidFilterException":
|
|
2817
|
-
throw await de_InvalidFilterExceptionRes(parsedOutput, context);
|
|
2818
|
-
case "InvalidRequestException":
|
|
2819
|
-
case "com.amazonaws.comprehend#InvalidRequestException":
|
|
2820
|
-
throw await de_InvalidRequestExceptionRes(parsedOutput, context);
|
|
2821
|
-
case "ResourceNotFoundException":
|
|
2822
|
-
case "com.amazonaws.comprehend#ResourceNotFoundException":
|
|
2823
|
-
throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
|
|
2824
|
-
case "TooManyRequestsException":
|
|
2825
|
-
case "com.amazonaws.comprehend#TooManyRequestsException":
|
|
2826
|
-
throw await de_TooManyRequestsExceptionRes(parsedOutput, context);
|
|
2827
|
-
default:
|
|
2828
|
-
const parsedBody = parsedOutput.body;
|
|
2829
|
-
return throwDefaultError({
|
|
2830
|
-
output,
|
|
2831
|
-
parsedBody,
|
|
2832
|
-
errorCode,
|
|
2833
|
-
});
|
|
2834
|
-
}
|
|
2835
|
-
};
|
|
2836
|
-
export const de_ListFlywheelsCommand = async (output, context) => {
|
|
1024
|
+
export const de_DetectSyntaxCommand = async (output, context) => {
|
|
2837
1025
|
if (output.statusCode >= 300) {
|
|
2838
|
-
return
|
|
1026
|
+
return de_CommandError(output, context);
|
|
2839
1027
|
}
|
|
2840
1028
|
const data = await parseBody(output.body, context);
|
|
2841
1029
|
let contents = {};
|
|
2842
|
-
contents =
|
|
1030
|
+
contents = de_DetectSyntaxResponse(data, context);
|
|
2843
1031
|
const response = {
|
|
2844
1032
|
$metadata: deserializeMetadata(output),
|
|
2845
1033
|
...contents,
|
|
2846
1034
|
};
|
|
2847
1035
|
return response;
|
|
2848
1036
|
};
|
|
2849
|
-
const
|
|
2850
|
-
|
|
2851
|
-
|
|
2852
|
-
body: await parseErrorBody(output.body, context),
|
|
2853
|
-
};
|
|
2854
|
-
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
2855
|
-
switch (errorCode) {
|
|
2856
|
-
case "InternalServerException":
|
|
2857
|
-
case "com.amazonaws.comprehend#InternalServerException":
|
|
2858
|
-
throw await de_InternalServerExceptionRes(parsedOutput, context);
|
|
2859
|
-
case "InvalidFilterException":
|
|
2860
|
-
case "com.amazonaws.comprehend#InvalidFilterException":
|
|
2861
|
-
throw await de_InvalidFilterExceptionRes(parsedOutput, context);
|
|
2862
|
-
case "InvalidRequestException":
|
|
2863
|
-
case "com.amazonaws.comprehend#InvalidRequestException":
|
|
2864
|
-
throw await de_InvalidRequestExceptionRes(parsedOutput, context);
|
|
2865
|
-
case "TooManyRequestsException":
|
|
2866
|
-
case "com.amazonaws.comprehend#TooManyRequestsException":
|
|
2867
|
-
throw await de_TooManyRequestsExceptionRes(parsedOutput, context);
|
|
2868
|
-
default:
|
|
2869
|
-
const parsedBody = parsedOutput.body;
|
|
2870
|
-
return throwDefaultError({
|
|
2871
|
-
output,
|
|
2872
|
-
parsedBody,
|
|
2873
|
-
errorCode,
|
|
2874
|
-
});
|
|
1037
|
+
export const de_DetectTargetedSentimentCommand = async (output, context) => {
|
|
1038
|
+
if (output.statusCode >= 300) {
|
|
1039
|
+
return de_CommandError(output, context);
|
|
2875
1040
|
}
|
|
1041
|
+
const data = await parseBody(output.body, context);
|
|
1042
|
+
let contents = {};
|
|
1043
|
+
contents = de_DetectTargetedSentimentResponse(data, context);
|
|
1044
|
+
const response = {
|
|
1045
|
+
$metadata: deserializeMetadata(output),
|
|
1046
|
+
...contents,
|
|
1047
|
+
};
|
|
1048
|
+
return response;
|
|
2876
1049
|
};
|
|
2877
|
-
export const
|
|
1050
|
+
export const de_DetectToxicContentCommand = async (output, context) => {
|
|
2878
1051
|
if (output.statusCode >= 300) {
|
|
2879
|
-
return
|
|
1052
|
+
return de_CommandError(output, context);
|
|
2880
1053
|
}
|
|
2881
1054
|
const data = await parseBody(output.body, context);
|
|
2882
1055
|
let contents = {};
|
|
2883
|
-
contents =
|
|
1056
|
+
contents = de_DetectToxicContentResponse(data, context);
|
|
2884
1057
|
const response = {
|
|
2885
1058
|
$metadata: deserializeMetadata(output),
|
|
2886
1059
|
...contents,
|
|
2887
1060
|
};
|
|
2888
1061
|
return response;
|
|
2889
1062
|
};
|
|
2890
|
-
const
|
|
2891
|
-
|
|
2892
|
-
|
|
2893
|
-
body: await parseErrorBody(output.body, context),
|
|
2894
|
-
};
|
|
2895
|
-
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
2896
|
-
switch (errorCode) {
|
|
2897
|
-
case "InternalServerException":
|
|
2898
|
-
case "com.amazonaws.comprehend#InternalServerException":
|
|
2899
|
-
throw await de_InternalServerExceptionRes(parsedOutput, context);
|
|
2900
|
-
case "InvalidFilterException":
|
|
2901
|
-
case "com.amazonaws.comprehend#InvalidFilterException":
|
|
2902
|
-
throw await de_InvalidFilterExceptionRes(parsedOutput, context);
|
|
2903
|
-
case "InvalidRequestException":
|
|
2904
|
-
case "com.amazonaws.comprehend#InvalidRequestException":
|
|
2905
|
-
throw await de_InvalidRequestExceptionRes(parsedOutput, context);
|
|
2906
|
-
case "TooManyRequestsException":
|
|
2907
|
-
case "com.amazonaws.comprehend#TooManyRequestsException":
|
|
2908
|
-
throw await de_TooManyRequestsExceptionRes(parsedOutput, context);
|
|
2909
|
-
default:
|
|
2910
|
-
const parsedBody = parsedOutput.body;
|
|
2911
|
-
return throwDefaultError({
|
|
2912
|
-
output,
|
|
2913
|
-
parsedBody,
|
|
2914
|
-
errorCode,
|
|
2915
|
-
});
|
|
1063
|
+
export const de_ImportModelCommand = async (output, context) => {
|
|
1064
|
+
if (output.statusCode >= 300) {
|
|
1065
|
+
return de_CommandError(output, context);
|
|
2916
1066
|
}
|
|
1067
|
+
const data = await parseBody(output.body, context);
|
|
1068
|
+
let contents = {};
|
|
1069
|
+
contents = _json(data);
|
|
1070
|
+
const response = {
|
|
1071
|
+
$metadata: deserializeMetadata(output),
|
|
1072
|
+
...contents,
|
|
1073
|
+
};
|
|
1074
|
+
return response;
|
|
2917
1075
|
};
|
|
2918
|
-
export const
|
|
1076
|
+
export const de_ListDatasetsCommand = async (output, context) => {
|
|
2919
1077
|
if (output.statusCode >= 300) {
|
|
2920
|
-
return
|
|
1078
|
+
return de_CommandError(output, context);
|
|
2921
1079
|
}
|
|
2922
1080
|
const data = await parseBody(output.body, context);
|
|
2923
1081
|
let contents = {};
|
|
2924
|
-
contents =
|
|
1082
|
+
contents = de_ListDatasetsResponse(data, context);
|
|
2925
1083
|
const response = {
|
|
2926
1084
|
$metadata: deserializeMetadata(output),
|
|
2927
1085
|
...contents,
|
|
2928
1086
|
};
|
|
2929
1087
|
return response;
|
|
2930
1088
|
};
|
|
2931
|
-
const
|
|
2932
|
-
const parsedOutput = {
|
|
2933
|
-
...output,
|
|
2934
|
-
body: await parseErrorBody(output.body, context),
|
|
2935
|
-
};
|
|
2936
|
-
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
2937
|
-
switch (errorCode) {
|
|
2938
|
-
case "InternalServerException":
|
|
2939
|
-
case "com.amazonaws.comprehend#InternalServerException":
|
|
2940
|
-
throw await de_InternalServerExceptionRes(parsedOutput, context);
|
|
2941
|
-
case "InvalidFilterException":
|
|
2942
|
-
case "com.amazonaws.comprehend#InvalidFilterException":
|
|
2943
|
-
throw await de_InvalidFilterExceptionRes(parsedOutput, context);
|
|
2944
|
-
case "InvalidRequestException":
|
|
2945
|
-
case "com.amazonaws.comprehend#InvalidRequestException":
|
|
2946
|
-
throw await de_InvalidRequestExceptionRes(parsedOutput, context);
|
|
2947
|
-
case "TooManyRequestsException":
|
|
2948
|
-
case "com.amazonaws.comprehend#TooManyRequestsException":
|
|
2949
|
-
throw await de_TooManyRequestsExceptionRes(parsedOutput, context);
|
|
2950
|
-
default:
|
|
2951
|
-
const parsedBody = parsedOutput.body;
|
|
2952
|
-
return throwDefaultError({
|
|
2953
|
-
output,
|
|
2954
|
-
parsedBody,
|
|
2955
|
-
errorCode,
|
|
2956
|
-
});
|
|
2957
|
-
}
|
|
2958
|
-
};
|
|
2959
|
-
export const de_ListSentimentDetectionJobsCommand = async (output, context) => {
|
|
1089
|
+
export const de_ListDocumentClassificationJobsCommand = async (output, context) => {
|
|
2960
1090
|
if (output.statusCode >= 300) {
|
|
2961
|
-
return
|
|
1091
|
+
return de_CommandError(output, context);
|
|
2962
1092
|
}
|
|
2963
1093
|
const data = await parseBody(output.body, context);
|
|
2964
1094
|
let contents = {};
|
|
2965
|
-
contents =
|
|
1095
|
+
contents = de_ListDocumentClassificationJobsResponse(data, context);
|
|
2966
1096
|
const response = {
|
|
2967
1097
|
$metadata: deserializeMetadata(output),
|
|
2968
1098
|
...contents,
|
|
2969
1099
|
};
|
|
2970
1100
|
return response;
|
|
2971
1101
|
};
|
|
2972
|
-
const
|
|
2973
|
-
const parsedOutput = {
|
|
2974
|
-
...output,
|
|
2975
|
-
body: await parseErrorBody(output.body, context),
|
|
2976
|
-
};
|
|
2977
|
-
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
2978
|
-
switch (errorCode) {
|
|
2979
|
-
case "InternalServerException":
|
|
2980
|
-
case "com.amazonaws.comprehend#InternalServerException":
|
|
2981
|
-
throw await de_InternalServerExceptionRes(parsedOutput, context);
|
|
2982
|
-
case "InvalidFilterException":
|
|
2983
|
-
case "com.amazonaws.comprehend#InvalidFilterException":
|
|
2984
|
-
throw await de_InvalidFilterExceptionRes(parsedOutput, context);
|
|
2985
|
-
case "InvalidRequestException":
|
|
2986
|
-
case "com.amazonaws.comprehend#InvalidRequestException":
|
|
2987
|
-
throw await de_InvalidRequestExceptionRes(parsedOutput, context);
|
|
2988
|
-
case "TooManyRequestsException":
|
|
2989
|
-
case "com.amazonaws.comprehend#TooManyRequestsException":
|
|
2990
|
-
throw await de_TooManyRequestsExceptionRes(parsedOutput, context);
|
|
2991
|
-
default:
|
|
2992
|
-
const parsedBody = parsedOutput.body;
|
|
2993
|
-
return throwDefaultError({
|
|
2994
|
-
output,
|
|
2995
|
-
parsedBody,
|
|
2996
|
-
errorCode,
|
|
2997
|
-
});
|
|
2998
|
-
}
|
|
2999
|
-
};
|
|
3000
|
-
export const de_ListTagsForResourceCommand = async (output, context) => {
|
|
1102
|
+
export const de_ListDocumentClassifiersCommand = async (output, context) => {
|
|
3001
1103
|
if (output.statusCode >= 300) {
|
|
3002
|
-
return
|
|
1104
|
+
return de_CommandError(output, context);
|
|
3003
1105
|
}
|
|
3004
1106
|
const data = await parseBody(output.body, context);
|
|
3005
1107
|
let contents = {};
|
|
3006
|
-
contents =
|
|
1108
|
+
contents = de_ListDocumentClassifiersResponse(data, context);
|
|
3007
1109
|
const response = {
|
|
3008
1110
|
$metadata: deserializeMetadata(output),
|
|
3009
1111
|
...contents,
|
|
3010
1112
|
};
|
|
3011
1113
|
return response;
|
|
3012
1114
|
};
|
|
3013
|
-
const
|
|
3014
|
-
const parsedOutput = {
|
|
3015
|
-
...output,
|
|
3016
|
-
body: await parseErrorBody(output.body, context),
|
|
3017
|
-
};
|
|
3018
|
-
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
3019
|
-
switch (errorCode) {
|
|
3020
|
-
case "InternalServerException":
|
|
3021
|
-
case "com.amazonaws.comprehend#InternalServerException":
|
|
3022
|
-
throw await de_InternalServerExceptionRes(parsedOutput, context);
|
|
3023
|
-
case "InvalidRequestException":
|
|
3024
|
-
case "com.amazonaws.comprehend#InvalidRequestException":
|
|
3025
|
-
throw await de_InvalidRequestExceptionRes(parsedOutput, context);
|
|
3026
|
-
case "ResourceNotFoundException":
|
|
3027
|
-
case "com.amazonaws.comprehend#ResourceNotFoundException":
|
|
3028
|
-
throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
|
|
3029
|
-
default:
|
|
3030
|
-
const parsedBody = parsedOutput.body;
|
|
3031
|
-
return throwDefaultError({
|
|
3032
|
-
output,
|
|
3033
|
-
parsedBody,
|
|
3034
|
-
errorCode,
|
|
3035
|
-
});
|
|
3036
|
-
}
|
|
3037
|
-
};
|
|
3038
|
-
export const de_ListTargetedSentimentDetectionJobsCommand = async (output, context) => {
|
|
1115
|
+
export const de_ListDocumentClassifierSummariesCommand = async (output, context) => {
|
|
3039
1116
|
if (output.statusCode >= 300) {
|
|
3040
|
-
return
|
|
1117
|
+
return de_CommandError(output, context);
|
|
3041
1118
|
}
|
|
3042
1119
|
const data = await parseBody(output.body, context);
|
|
3043
1120
|
let contents = {};
|
|
3044
|
-
contents =
|
|
1121
|
+
contents = de_ListDocumentClassifierSummariesResponse(data, context);
|
|
3045
1122
|
const response = {
|
|
3046
1123
|
$metadata: deserializeMetadata(output),
|
|
3047
1124
|
...contents,
|
|
3048
1125
|
};
|
|
3049
1126
|
return response;
|
|
3050
1127
|
};
|
|
3051
|
-
const
|
|
3052
|
-
|
|
3053
|
-
|
|
3054
|
-
body: await parseErrorBody(output.body, context),
|
|
3055
|
-
};
|
|
3056
|
-
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
3057
|
-
switch (errorCode) {
|
|
3058
|
-
case "InternalServerException":
|
|
3059
|
-
case "com.amazonaws.comprehend#InternalServerException":
|
|
3060
|
-
throw await de_InternalServerExceptionRes(parsedOutput, context);
|
|
3061
|
-
case "InvalidFilterException":
|
|
3062
|
-
case "com.amazonaws.comprehend#InvalidFilterException":
|
|
3063
|
-
throw await de_InvalidFilterExceptionRes(parsedOutput, context);
|
|
3064
|
-
case "InvalidRequestException":
|
|
3065
|
-
case "com.amazonaws.comprehend#InvalidRequestException":
|
|
3066
|
-
throw await de_InvalidRequestExceptionRes(parsedOutput, context);
|
|
3067
|
-
case "TooManyRequestsException":
|
|
3068
|
-
case "com.amazonaws.comprehend#TooManyRequestsException":
|
|
3069
|
-
throw await de_TooManyRequestsExceptionRes(parsedOutput, context);
|
|
3070
|
-
default:
|
|
3071
|
-
const parsedBody = parsedOutput.body;
|
|
3072
|
-
return throwDefaultError({
|
|
3073
|
-
output,
|
|
3074
|
-
parsedBody,
|
|
3075
|
-
errorCode,
|
|
3076
|
-
});
|
|
1128
|
+
export const de_ListDominantLanguageDetectionJobsCommand = async (output, context) => {
|
|
1129
|
+
if (output.statusCode >= 300) {
|
|
1130
|
+
return de_CommandError(output, context);
|
|
3077
1131
|
}
|
|
1132
|
+
const data = await parseBody(output.body, context);
|
|
1133
|
+
let contents = {};
|
|
1134
|
+
contents = de_ListDominantLanguageDetectionJobsResponse(data, context);
|
|
1135
|
+
const response = {
|
|
1136
|
+
$metadata: deserializeMetadata(output),
|
|
1137
|
+
...contents,
|
|
1138
|
+
};
|
|
1139
|
+
return response;
|
|
3078
1140
|
};
|
|
3079
|
-
export const
|
|
1141
|
+
export const de_ListEndpointsCommand = async (output, context) => {
|
|
3080
1142
|
if (output.statusCode >= 300) {
|
|
3081
|
-
return
|
|
1143
|
+
return de_CommandError(output, context);
|
|
3082
1144
|
}
|
|
3083
1145
|
const data = await parseBody(output.body, context);
|
|
3084
1146
|
let contents = {};
|
|
3085
|
-
contents =
|
|
1147
|
+
contents = de_ListEndpointsResponse(data, context);
|
|
3086
1148
|
const response = {
|
|
3087
1149
|
$metadata: deserializeMetadata(output),
|
|
3088
1150
|
...contents,
|
|
3089
1151
|
};
|
|
3090
1152
|
return response;
|
|
3091
1153
|
};
|
|
3092
|
-
const
|
|
3093
|
-
|
|
3094
|
-
|
|
3095
|
-
body: await parseErrorBody(output.body, context),
|
|
3096
|
-
};
|
|
3097
|
-
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
3098
|
-
switch (errorCode) {
|
|
3099
|
-
case "InternalServerException":
|
|
3100
|
-
case "com.amazonaws.comprehend#InternalServerException":
|
|
3101
|
-
throw await de_InternalServerExceptionRes(parsedOutput, context);
|
|
3102
|
-
case "InvalidFilterException":
|
|
3103
|
-
case "com.amazonaws.comprehend#InvalidFilterException":
|
|
3104
|
-
throw await de_InvalidFilterExceptionRes(parsedOutput, context);
|
|
3105
|
-
case "InvalidRequestException":
|
|
3106
|
-
case "com.amazonaws.comprehend#InvalidRequestException":
|
|
3107
|
-
throw await de_InvalidRequestExceptionRes(parsedOutput, context);
|
|
3108
|
-
case "TooManyRequestsException":
|
|
3109
|
-
case "com.amazonaws.comprehend#TooManyRequestsException":
|
|
3110
|
-
throw await de_TooManyRequestsExceptionRes(parsedOutput, context);
|
|
3111
|
-
default:
|
|
3112
|
-
const parsedBody = parsedOutput.body;
|
|
3113
|
-
return throwDefaultError({
|
|
3114
|
-
output,
|
|
3115
|
-
parsedBody,
|
|
3116
|
-
errorCode,
|
|
3117
|
-
});
|
|
1154
|
+
export const de_ListEntitiesDetectionJobsCommand = async (output, context) => {
|
|
1155
|
+
if (output.statusCode >= 300) {
|
|
1156
|
+
return de_CommandError(output, context);
|
|
3118
1157
|
}
|
|
1158
|
+
const data = await parseBody(output.body, context);
|
|
1159
|
+
let contents = {};
|
|
1160
|
+
contents = de_ListEntitiesDetectionJobsResponse(data, context);
|
|
1161
|
+
const response = {
|
|
1162
|
+
$metadata: deserializeMetadata(output),
|
|
1163
|
+
...contents,
|
|
1164
|
+
};
|
|
1165
|
+
return response;
|
|
3119
1166
|
};
|
|
3120
|
-
export const
|
|
1167
|
+
export const de_ListEntityRecognizersCommand = async (output, context) => {
|
|
3121
1168
|
if (output.statusCode >= 300) {
|
|
3122
|
-
return
|
|
1169
|
+
return de_CommandError(output, context);
|
|
3123
1170
|
}
|
|
3124
1171
|
const data = await parseBody(output.body, context);
|
|
3125
1172
|
let contents = {};
|
|
3126
|
-
contents =
|
|
1173
|
+
contents = de_ListEntityRecognizersResponse(data, context);
|
|
3127
1174
|
const response = {
|
|
3128
1175
|
$metadata: deserializeMetadata(output),
|
|
3129
1176
|
...contents,
|
|
3130
1177
|
};
|
|
3131
1178
|
return response;
|
|
3132
1179
|
};
|
|
3133
|
-
const
|
|
3134
|
-
|
|
3135
|
-
|
|
3136
|
-
body: await parseErrorBody(output.body, context),
|
|
3137
|
-
};
|
|
3138
|
-
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
3139
|
-
switch (errorCode) {
|
|
3140
|
-
case "InternalServerException":
|
|
3141
|
-
case "com.amazonaws.comprehend#InternalServerException":
|
|
3142
|
-
throw await de_InternalServerExceptionRes(parsedOutput, context);
|
|
3143
|
-
case "InvalidRequestException":
|
|
3144
|
-
case "com.amazonaws.comprehend#InvalidRequestException":
|
|
3145
|
-
throw await de_InvalidRequestExceptionRes(parsedOutput, context);
|
|
3146
|
-
case "ResourceNotFoundException":
|
|
3147
|
-
case "com.amazonaws.comprehend#ResourceNotFoundException":
|
|
3148
|
-
throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
|
|
3149
|
-
default:
|
|
3150
|
-
const parsedBody = parsedOutput.body;
|
|
3151
|
-
return throwDefaultError({
|
|
3152
|
-
output,
|
|
3153
|
-
parsedBody,
|
|
3154
|
-
errorCode,
|
|
3155
|
-
});
|
|
1180
|
+
export const de_ListEntityRecognizerSummariesCommand = async (output, context) => {
|
|
1181
|
+
if (output.statusCode >= 300) {
|
|
1182
|
+
return de_CommandError(output, context);
|
|
3156
1183
|
}
|
|
1184
|
+
const data = await parseBody(output.body, context);
|
|
1185
|
+
let contents = {};
|
|
1186
|
+
contents = de_ListEntityRecognizerSummariesResponse(data, context);
|
|
1187
|
+
const response = {
|
|
1188
|
+
$metadata: deserializeMetadata(output),
|
|
1189
|
+
...contents,
|
|
1190
|
+
};
|
|
1191
|
+
return response;
|
|
3157
1192
|
};
|
|
3158
|
-
export const
|
|
1193
|
+
export const de_ListEventsDetectionJobsCommand = async (output, context) => {
|
|
3159
1194
|
if (output.statusCode >= 300) {
|
|
3160
|
-
return
|
|
1195
|
+
return de_CommandError(output, context);
|
|
3161
1196
|
}
|
|
3162
1197
|
const data = await parseBody(output.body, context);
|
|
3163
1198
|
let contents = {};
|
|
3164
|
-
contents =
|
|
1199
|
+
contents = de_ListEventsDetectionJobsResponse(data, context);
|
|
3165
1200
|
const response = {
|
|
3166
1201
|
$metadata: deserializeMetadata(output),
|
|
3167
1202
|
...contents,
|
|
3168
1203
|
};
|
|
3169
1204
|
return response;
|
|
3170
1205
|
};
|
|
3171
|
-
const
|
|
3172
|
-
|
|
3173
|
-
|
|
3174
|
-
body: await parseErrorBody(output.body, context),
|
|
3175
|
-
};
|
|
3176
|
-
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
3177
|
-
switch (errorCode) {
|
|
3178
|
-
case "InternalServerException":
|
|
3179
|
-
case "com.amazonaws.comprehend#InternalServerException":
|
|
3180
|
-
throw await de_InternalServerExceptionRes(parsedOutput, context);
|
|
3181
|
-
case "InvalidRequestException":
|
|
3182
|
-
case "com.amazonaws.comprehend#InvalidRequestException":
|
|
3183
|
-
throw await de_InvalidRequestExceptionRes(parsedOutput, context);
|
|
3184
|
-
case "KmsKeyValidationException":
|
|
3185
|
-
case "com.amazonaws.comprehend#KmsKeyValidationException":
|
|
3186
|
-
throw await de_KmsKeyValidationExceptionRes(parsedOutput, context);
|
|
3187
|
-
case "ResourceInUseException":
|
|
3188
|
-
case "com.amazonaws.comprehend#ResourceInUseException":
|
|
3189
|
-
throw await de_ResourceInUseExceptionRes(parsedOutput, context);
|
|
3190
|
-
case "ResourceNotFoundException":
|
|
3191
|
-
case "com.amazonaws.comprehend#ResourceNotFoundException":
|
|
3192
|
-
throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
|
|
3193
|
-
case "ResourceUnavailableException":
|
|
3194
|
-
case "com.amazonaws.comprehend#ResourceUnavailableException":
|
|
3195
|
-
throw await de_ResourceUnavailableExceptionRes(parsedOutput, context);
|
|
3196
|
-
case "TooManyRequestsException":
|
|
3197
|
-
case "com.amazonaws.comprehend#TooManyRequestsException":
|
|
3198
|
-
throw await de_TooManyRequestsExceptionRes(parsedOutput, context);
|
|
3199
|
-
case "TooManyTagsException":
|
|
3200
|
-
case "com.amazonaws.comprehend#TooManyTagsException":
|
|
3201
|
-
throw await de_TooManyTagsExceptionRes(parsedOutput, context);
|
|
3202
|
-
default:
|
|
3203
|
-
const parsedBody = parsedOutput.body;
|
|
3204
|
-
return throwDefaultError({
|
|
3205
|
-
output,
|
|
3206
|
-
parsedBody,
|
|
3207
|
-
errorCode,
|
|
3208
|
-
});
|
|
1206
|
+
export const de_ListFlywheelIterationHistoryCommand = async (output, context) => {
|
|
1207
|
+
if (output.statusCode >= 300) {
|
|
1208
|
+
return de_CommandError(output, context);
|
|
3209
1209
|
}
|
|
1210
|
+
const data = await parseBody(output.body, context);
|
|
1211
|
+
let contents = {};
|
|
1212
|
+
contents = de_ListFlywheelIterationHistoryResponse(data, context);
|
|
1213
|
+
const response = {
|
|
1214
|
+
$metadata: deserializeMetadata(output),
|
|
1215
|
+
...contents,
|
|
1216
|
+
};
|
|
1217
|
+
return response;
|
|
3210
1218
|
};
|
|
3211
|
-
export const
|
|
1219
|
+
export const de_ListFlywheelsCommand = async (output, context) => {
|
|
3212
1220
|
if (output.statusCode >= 300) {
|
|
3213
|
-
return
|
|
1221
|
+
return de_CommandError(output, context);
|
|
3214
1222
|
}
|
|
3215
1223
|
const data = await parseBody(output.body, context);
|
|
3216
1224
|
let contents = {};
|
|
3217
|
-
contents =
|
|
1225
|
+
contents = de_ListFlywheelsResponse(data, context);
|
|
3218
1226
|
const response = {
|
|
3219
1227
|
$metadata: deserializeMetadata(output),
|
|
3220
1228
|
...contents,
|
|
3221
1229
|
};
|
|
3222
1230
|
return response;
|
|
3223
1231
|
};
|
|
3224
|
-
const
|
|
3225
|
-
|
|
3226
|
-
|
|
3227
|
-
body: await parseErrorBody(output.body, context),
|
|
3228
|
-
};
|
|
3229
|
-
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
3230
|
-
switch (errorCode) {
|
|
3231
|
-
case "InternalServerException":
|
|
3232
|
-
case "com.amazonaws.comprehend#InternalServerException":
|
|
3233
|
-
throw await de_InternalServerExceptionRes(parsedOutput, context);
|
|
3234
|
-
case "InvalidRequestException":
|
|
3235
|
-
case "com.amazonaws.comprehend#InvalidRequestException":
|
|
3236
|
-
throw await de_InvalidRequestExceptionRes(parsedOutput, context);
|
|
3237
|
-
case "KmsKeyValidationException":
|
|
3238
|
-
case "com.amazonaws.comprehend#KmsKeyValidationException":
|
|
3239
|
-
throw await de_KmsKeyValidationExceptionRes(parsedOutput, context);
|
|
3240
|
-
case "ResourceInUseException":
|
|
3241
|
-
case "com.amazonaws.comprehend#ResourceInUseException":
|
|
3242
|
-
throw await de_ResourceInUseExceptionRes(parsedOutput, context);
|
|
3243
|
-
case "TooManyRequestsException":
|
|
3244
|
-
case "com.amazonaws.comprehend#TooManyRequestsException":
|
|
3245
|
-
throw await de_TooManyRequestsExceptionRes(parsedOutput, context);
|
|
3246
|
-
case "TooManyTagsException":
|
|
3247
|
-
case "com.amazonaws.comprehend#TooManyTagsException":
|
|
3248
|
-
throw await de_TooManyTagsExceptionRes(parsedOutput, context);
|
|
3249
|
-
default:
|
|
3250
|
-
const parsedBody = parsedOutput.body;
|
|
3251
|
-
return throwDefaultError({
|
|
3252
|
-
output,
|
|
3253
|
-
parsedBody,
|
|
3254
|
-
errorCode,
|
|
3255
|
-
});
|
|
1232
|
+
export const de_ListKeyPhrasesDetectionJobsCommand = async (output, context) => {
|
|
1233
|
+
if (output.statusCode >= 300) {
|
|
1234
|
+
return de_CommandError(output, context);
|
|
3256
1235
|
}
|
|
1236
|
+
const data = await parseBody(output.body, context);
|
|
1237
|
+
let contents = {};
|
|
1238
|
+
contents = de_ListKeyPhrasesDetectionJobsResponse(data, context);
|
|
1239
|
+
const response = {
|
|
1240
|
+
$metadata: deserializeMetadata(output),
|
|
1241
|
+
...contents,
|
|
1242
|
+
};
|
|
1243
|
+
return response;
|
|
3257
1244
|
};
|
|
3258
|
-
export const
|
|
1245
|
+
export const de_ListPiiEntitiesDetectionJobsCommand = async (output, context) => {
|
|
3259
1246
|
if (output.statusCode >= 300) {
|
|
3260
|
-
return
|
|
1247
|
+
return de_CommandError(output, context);
|
|
3261
1248
|
}
|
|
3262
1249
|
const data = await parseBody(output.body, context);
|
|
3263
1250
|
let contents = {};
|
|
3264
|
-
contents =
|
|
1251
|
+
contents = de_ListPiiEntitiesDetectionJobsResponse(data, context);
|
|
3265
1252
|
const response = {
|
|
3266
1253
|
$metadata: deserializeMetadata(output),
|
|
3267
1254
|
...contents,
|
|
3268
1255
|
};
|
|
3269
1256
|
return response;
|
|
3270
1257
|
};
|
|
3271
|
-
const
|
|
3272
|
-
|
|
3273
|
-
|
|
3274
|
-
body: await parseErrorBody(output.body, context),
|
|
3275
|
-
};
|
|
3276
|
-
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
3277
|
-
switch (errorCode) {
|
|
3278
|
-
case "InternalServerException":
|
|
3279
|
-
case "com.amazonaws.comprehend#InternalServerException":
|
|
3280
|
-
throw await de_InternalServerExceptionRes(parsedOutput, context);
|
|
3281
|
-
case "InvalidRequestException":
|
|
3282
|
-
case "com.amazonaws.comprehend#InvalidRequestException":
|
|
3283
|
-
throw await de_InvalidRequestExceptionRes(parsedOutput, context);
|
|
3284
|
-
case "KmsKeyValidationException":
|
|
3285
|
-
case "com.amazonaws.comprehend#KmsKeyValidationException":
|
|
3286
|
-
throw await de_KmsKeyValidationExceptionRes(parsedOutput, context);
|
|
3287
|
-
case "ResourceInUseException":
|
|
3288
|
-
case "com.amazonaws.comprehend#ResourceInUseException":
|
|
3289
|
-
throw await de_ResourceInUseExceptionRes(parsedOutput, context);
|
|
3290
|
-
case "ResourceNotFoundException":
|
|
3291
|
-
case "com.amazonaws.comprehend#ResourceNotFoundException":
|
|
3292
|
-
throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
|
|
3293
|
-
case "ResourceUnavailableException":
|
|
3294
|
-
case "com.amazonaws.comprehend#ResourceUnavailableException":
|
|
3295
|
-
throw await de_ResourceUnavailableExceptionRes(parsedOutput, context);
|
|
3296
|
-
case "TooManyRequestsException":
|
|
3297
|
-
case "com.amazonaws.comprehend#TooManyRequestsException":
|
|
3298
|
-
throw await de_TooManyRequestsExceptionRes(parsedOutput, context);
|
|
3299
|
-
case "TooManyTagsException":
|
|
3300
|
-
case "com.amazonaws.comprehend#TooManyTagsException":
|
|
3301
|
-
throw await de_TooManyTagsExceptionRes(parsedOutput, context);
|
|
3302
|
-
default:
|
|
3303
|
-
const parsedBody = parsedOutput.body;
|
|
3304
|
-
return throwDefaultError({
|
|
3305
|
-
output,
|
|
3306
|
-
parsedBody,
|
|
3307
|
-
errorCode,
|
|
3308
|
-
});
|
|
1258
|
+
export const de_ListSentimentDetectionJobsCommand = async (output, context) => {
|
|
1259
|
+
if (output.statusCode >= 300) {
|
|
1260
|
+
return de_CommandError(output, context);
|
|
3309
1261
|
}
|
|
1262
|
+
const data = await parseBody(output.body, context);
|
|
1263
|
+
let contents = {};
|
|
1264
|
+
contents = de_ListSentimentDetectionJobsResponse(data, context);
|
|
1265
|
+
const response = {
|
|
1266
|
+
$metadata: deserializeMetadata(output),
|
|
1267
|
+
...contents,
|
|
1268
|
+
};
|
|
1269
|
+
return response;
|
|
3310
1270
|
};
|
|
3311
|
-
export const
|
|
1271
|
+
export const de_ListTagsForResourceCommand = async (output, context) => {
|
|
3312
1272
|
if (output.statusCode >= 300) {
|
|
3313
|
-
return
|
|
1273
|
+
return de_CommandError(output, context);
|
|
3314
1274
|
}
|
|
3315
1275
|
const data = await parseBody(output.body, context);
|
|
3316
1276
|
let contents = {};
|
|
@@ -3321,87 +1281,35 @@ export const de_StartEventsDetectionJobCommand = async (output, context) => {
|
|
|
3321
1281
|
};
|
|
3322
1282
|
return response;
|
|
3323
1283
|
};
|
|
3324
|
-
const
|
|
3325
|
-
const parsedOutput = {
|
|
3326
|
-
...output,
|
|
3327
|
-
body: await parseErrorBody(output.body, context),
|
|
3328
|
-
};
|
|
3329
|
-
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
3330
|
-
switch (errorCode) {
|
|
3331
|
-
case "InternalServerException":
|
|
3332
|
-
case "com.amazonaws.comprehend#InternalServerException":
|
|
3333
|
-
throw await de_InternalServerExceptionRes(parsedOutput, context);
|
|
3334
|
-
case "InvalidRequestException":
|
|
3335
|
-
case "com.amazonaws.comprehend#InvalidRequestException":
|
|
3336
|
-
throw await de_InvalidRequestExceptionRes(parsedOutput, context);
|
|
3337
|
-
case "KmsKeyValidationException":
|
|
3338
|
-
case "com.amazonaws.comprehend#KmsKeyValidationException":
|
|
3339
|
-
throw await de_KmsKeyValidationExceptionRes(parsedOutput, context);
|
|
3340
|
-
case "ResourceInUseException":
|
|
3341
|
-
case "com.amazonaws.comprehend#ResourceInUseException":
|
|
3342
|
-
throw await de_ResourceInUseExceptionRes(parsedOutput, context);
|
|
3343
|
-
case "TooManyRequestsException":
|
|
3344
|
-
case "com.amazonaws.comprehend#TooManyRequestsException":
|
|
3345
|
-
throw await de_TooManyRequestsExceptionRes(parsedOutput, context);
|
|
3346
|
-
case "TooManyTagsException":
|
|
3347
|
-
case "com.amazonaws.comprehend#TooManyTagsException":
|
|
3348
|
-
throw await de_TooManyTagsExceptionRes(parsedOutput, context);
|
|
3349
|
-
default:
|
|
3350
|
-
const parsedBody = parsedOutput.body;
|
|
3351
|
-
return throwDefaultError({
|
|
3352
|
-
output,
|
|
3353
|
-
parsedBody,
|
|
3354
|
-
errorCode,
|
|
3355
|
-
});
|
|
3356
|
-
}
|
|
3357
|
-
};
|
|
3358
|
-
export const de_StartFlywheelIterationCommand = async (output, context) => {
|
|
1284
|
+
export const de_ListTargetedSentimentDetectionJobsCommand = async (output, context) => {
|
|
3359
1285
|
if (output.statusCode >= 300) {
|
|
3360
|
-
return
|
|
1286
|
+
return de_CommandError(output, context);
|
|
3361
1287
|
}
|
|
3362
1288
|
const data = await parseBody(output.body, context);
|
|
3363
1289
|
let contents = {};
|
|
3364
|
-
contents =
|
|
1290
|
+
contents = de_ListTargetedSentimentDetectionJobsResponse(data, context);
|
|
3365
1291
|
const response = {
|
|
3366
1292
|
$metadata: deserializeMetadata(output),
|
|
3367
1293
|
...contents,
|
|
3368
1294
|
};
|
|
3369
1295
|
return response;
|
|
3370
1296
|
};
|
|
3371
|
-
const
|
|
3372
|
-
|
|
3373
|
-
|
|
3374
|
-
body: await parseErrorBody(output.body, context),
|
|
3375
|
-
};
|
|
3376
|
-
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
3377
|
-
switch (errorCode) {
|
|
3378
|
-
case "InternalServerException":
|
|
3379
|
-
case "com.amazonaws.comprehend#InternalServerException":
|
|
3380
|
-
throw await de_InternalServerExceptionRes(parsedOutput, context);
|
|
3381
|
-
case "InvalidRequestException":
|
|
3382
|
-
case "com.amazonaws.comprehend#InvalidRequestException":
|
|
3383
|
-
throw await de_InvalidRequestExceptionRes(parsedOutput, context);
|
|
3384
|
-
case "ResourceInUseException":
|
|
3385
|
-
case "com.amazonaws.comprehend#ResourceInUseException":
|
|
3386
|
-
throw await de_ResourceInUseExceptionRes(parsedOutput, context);
|
|
3387
|
-
case "ResourceNotFoundException":
|
|
3388
|
-
case "com.amazonaws.comprehend#ResourceNotFoundException":
|
|
3389
|
-
throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
|
|
3390
|
-
case "TooManyRequestsException":
|
|
3391
|
-
case "com.amazonaws.comprehend#TooManyRequestsException":
|
|
3392
|
-
throw await de_TooManyRequestsExceptionRes(parsedOutput, context);
|
|
3393
|
-
default:
|
|
3394
|
-
const parsedBody = parsedOutput.body;
|
|
3395
|
-
return throwDefaultError({
|
|
3396
|
-
output,
|
|
3397
|
-
parsedBody,
|
|
3398
|
-
errorCode,
|
|
3399
|
-
});
|
|
1297
|
+
export const de_ListTopicsDetectionJobsCommand = async (output, context) => {
|
|
1298
|
+
if (output.statusCode >= 300) {
|
|
1299
|
+
return de_CommandError(output, context);
|
|
3400
1300
|
}
|
|
1301
|
+
const data = await parseBody(output.body, context);
|
|
1302
|
+
let contents = {};
|
|
1303
|
+
contents = de_ListTopicsDetectionJobsResponse(data, context);
|
|
1304
|
+
const response = {
|
|
1305
|
+
$metadata: deserializeMetadata(output),
|
|
1306
|
+
...contents,
|
|
1307
|
+
};
|
|
1308
|
+
return response;
|
|
3401
1309
|
};
|
|
3402
|
-
export const
|
|
1310
|
+
export const de_PutResourcePolicyCommand = async (output, context) => {
|
|
3403
1311
|
if (output.statusCode >= 300) {
|
|
3404
|
-
return
|
|
1312
|
+
return de_CommandError(output, context);
|
|
3405
1313
|
}
|
|
3406
1314
|
const data = await parseBody(output.body, context);
|
|
3407
1315
|
let contents = {};
|
|
@@ -3412,43 +1320,9 @@ export const de_StartKeyPhrasesDetectionJobCommand = async (output, context) =>
|
|
|
3412
1320
|
};
|
|
3413
1321
|
return response;
|
|
3414
1322
|
};
|
|
3415
|
-
const
|
|
3416
|
-
const parsedOutput = {
|
|
3417
|
-
...output,
|
|
3418
|
-
body: await parseErrorBody(output.body, context),
|
|
3419
|
-
};
|
|
3420
|
-
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
3421
|
-
switch (errorCode) {
|
|
3422
|
-
case "InternalServerException":
|
|
3423
|
-
case "com.amazonaws.comprehend#InternalServerException":
|
|
3424
|
-
throw await de_InternalServerExceptionRes(parsedOutput, context);
|
|
3425
|
-
case "InvalidRequestException":
|
|
3426
|
-
case "com.amazonaws.comprehend#InvalidRequestException":
|
|
3427
|
-
throw await de_InvalidRequestExceptionRes(parsedOutput, context);
|
|
3428
|
-
case "KmsKeyValidationException":
|
|
3429
|
-
case "com.amazonaws.comprehend#KmsKeyValidationException":
|
|
3430
|
-
throw await de_KmsKeyValidationExceptionRes(parsedOutput, context);
|
|
3431
|
-
case "ResourceInUseException":
|
|
3432
|
-
case "com.amazonaws.comprehend#ResourceInUseException":
|
|
3433
|
-
throw await de_ResourceInUseExceptionRes(parsedOutput, context);
|
|
3434
|
-
case "TooManyRequestsException":
|
|
3435
|
-
case "com.amazonaws.comprehend#TooManyRequestsException":
|
|
3436
|
-
throw await de_TooManyRequestsExceptionRes(parsedOutput, context);
|
|
3437
|
-
case "TooManyTagsException":
|
|
3438
|
-
case "com.amazonaws.comprehend#TooManyTagsException":
|
|
3439
|
-
throw await de_TooManyTagsExceptionRes(parsedOutput, context);
|
|
3440
|
-
default:
|
|
3441
|
-
const parsedBody = parsedOutput.body;
|
|
3442
|
-
return throwDefaultError({
|
|
3443
|
-
output,
|
|
3444
|
-
parsedBody,
|
|
3445
|
-
errorCode,
|
|
3446
|
-
});
|
|
3447
|
-
}
|
|
3448
|
-
};
|
|
3449
|
-
export const de_StartPiiEntitiesDetectionJobCommand = async (output, context) => {
|
|
1323
|
+
export const de_StartDocumentClassificationJobCommand = async (output, context) => {
|
|
3450
1324
|
if (output.statusCode >= 300) {
|
|
3451
|
-
return
|
|
1325
|
+
return de_CommandError(output, context);
|
|
3452
1326
|
}
|
|
3453
1327
|
const data = await parseBody(output.body, context);
|
|
3454
1328
|
let contents = {};
|
|
@@ -3459,43 +1333,22 @@ export const de_StartPiiEntitiesDetectionJobCommand = async (output, context) =>
|
|
|
3459
1333
|
};
|
|
3460
1334
|
return response;
|
|
3461
1335
|
};
|
|
3462
|
-
const
|
|
3463
|
-
|
|
3464
|
-
|
|
3465
|
-
body: await parseErrorBody(output.body, context),
|
|
3466
|
-
};
|
|
3467
|
-
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
3468
|
-
switch (errorCode) {
|
|
3469
|
-
case "InternalServerException":
|
|
3470
|
-
case "com.amazonaws.comprehend#InternalServerException":
|
|
3471
|
-
throw await de_InternalServerExceptionRes(parsedOutput, context);
|
|
3472
|
-
case "InvalidRequestException":
|
|
3473
|
-
case "com.amazonaws.comprehend#InvalidRequestException":
|
|
3474
|
-
throw await de_InvalidRequestExceptionRes(parsedOutput, context);
|
|
3475
|
-
case "KmsKeyValidationException":
|
|
3476
|
-
case "com.amazonaws.comprehend#KmsKeyValidationException":
|
|
3477
|
-
throw await de_KmsKeyValidationExceptionRes(parsedOutput, context);
|
|
3478
|
-
case "ResourceInUseException":
|
|
3479
|
-
case "com.amazonaws.comprehend#ResourceInUseException":
|
|
3480
|
-
throw await de_ResourceInUseExceptionRes(parsedOutput, context);
|
|
3481
|
-
case "TooManyRequestsException":
|
|
3482
|
-
case "com.amazonaws.comprehend#TooManyRequestsException":
|
|
3483
|
-
throw await de_TooManyRequestsExceptionRes(parsedOutput, context);
|
|
3484
|
-
case "TooManyTagsException":
|
|
3485
|
-
case "com.amazonaws.comprehend#TooManyTagsException":
|
|
3486
|
-
throw await de_TooManyTagsExceptionRes(parsedOutput, context);
|
|
3487
|
-
default:
|
|
3488
|
-
const parsedBody = parsedOutput.body;
|
|
3489
|
-
return throwDefaultError({
|
|
3490
|
-
output,
|
|
3491
|
-
parsedBody,
|
|
3492
|
-
errorCode,
|
|
3493
|
-
});
|
|
1336
|
+
export const de_StartDominantLanguageDetectionJobCommand = async (output, context) => {
|
|
1337
|
+
if (output.statusCode >= 300) {
|
|
1338
|
+
return de_CommandError(output, context);
|
|
3494
1339
|
}
|
|
1340
|
+
const data = await parseBody(output.body, context);
|
|
1341
|
+
let contents = {};
|
|
1342
|
+
contents = _json(data);
|
|
1343
|
+
const response = {
|
|
1344
|
+
$metadata: deserializeMetadata(output),
|
|
1345
|
+
...contents,
|
|
1346
|
+
};
|
|
1347
|
+
return response;
|
|
3495
1348
|
};
|
|
3496
|
-
export const
|
|
1349
|
+
export const de_StartEntitiesDetectionJobCommand = async (output, context) => {
|
|
3497
1350
|
if (output.statusCode >= 300) {
|
|
3498
|
-
return
|
|
1351
|
+
return de_CommandError(output, context);
|
|
3499
1352
|
}
|
|
3500
1353
|
const data = await parseBody(output.body, context);
|
|
3501
1354
|
let contents = {};
|
|
@@ -3506,43 +1359,9 @@ export const de_StartSentimentDetectionJobCommand = async (output, context) => {
|
|
|
3506
1359
|
};
|
|
3507
1360
|
return response;
|
|
3508
1361
|
};
|
|
3509
|
-
const
|
|
3510
|
-
const parsedOutput = {
|
|
3511
|
-
...output,
|
|
3512
|
-
body: await parseErrorBody(output.body, context),
|
|
3513
|
-
};
|
|
3514
|
-
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
3515
|
-
switch (errorCode) {
|
|
3516
|
-
case "InternalServerException":
|
|
3517
|
-
case "com.amazonaws.comprehend#InternalServerException":
|
|
3518
|
-
throw await de_InternalServerExceptionRes(parsedOutput, context);
|
|
3519
|
-
case "InvalidRequestException":
|
|
3520
|
-
case "com.amazonaws.comprehend#InvalidRequestException":
|
|
3521
|
-
throw await de_InvalidRequestExceptionRes(parsedOutput, context);
|
|
3522
|
-
case "KmsKeyValidationException":
|
|
3523
|
-
case "com.amazonaws.comprehend#KmsKeyValidationException":
|
|
3524
|
-
throw await de_KmsKeyValidationExceptionRes(parsedOutput, context);
|
|
3525
|
-
case "ResourceInUseException":
|
|
3526
|
-
case "com.amazonaws.comprehend#ResourceInUseException":
|
|
3527
|
-
throw await de_ResourceInUseExceptionRes(parsedOutput, context);
|
|
3528
|
-
case "TooManyRequestsException":
|
|
3529
|
-
case "com.amazonaws.comprehend#TooManyRequestsException":
|
|
3530
|
-
throw await de_TooManyRequestsExceptionRes(parsedOutput, context);
|
|
3531
|
-
case "TooManyTagsException":
|
|
3532
|
-
case "com.amazonaws.comprehend#TooManyTagsException":
|
|
3533
|
-
throw await de_TooManyTagsExceptionRes(parsedOutput, context);
|
|
3534
|
-
default:
|
|
3535
|
-
const parsedBody = parsedOutput.body;
|
|
3536
|
-
return throwDefaultError({
|
|
3537
|
-
output,
|
|
3538
|
-
parsedBody,
|
|
3539
|
-
errorCode,
|
|
3540
|
-
});
|
|
3541
|
-
}
|
|
3542
|
-
};
|
|
3543
|
-
export const de_StartTargetedSentimentDetectionJobCommand = async (output, context) => {
|
|
1362
|
+
export const de_StartEventsDetectionJobCommand = async (output, context) => {
|
|
3544
1363
|
if (output.statusCode >= 300) {
|
|
3545
|
-
return
|
|
1364
|
+
return de_CommandError(output, context);
|
|
3546
1365
|
}
|
|
3547
1366
|
const data = await parseBody(output.body, context);
|
|
3548
1367
|
let contents = {};
|
|
@@ -3553,43 +1372,9 @@ export const de_StartTargetedSentimentDetectionJobCommand = async (output, conte
|
|
|
3553
1372
|
};
|
|
3554
1373
|
return response;
|
|
3555
1374
|
};
|
|
3556
|
-
const
|
|
3557
|
-
const parsedOutput = {
|
|
3558
|
-
...output,
|
|
3559
|
-
body: await parseErrorBody(output.body, context),
|
|
3560
|
-
};
|
|
3561
|
-
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
3562
|
-
switch (errorCode) {
|
|
3563
|
-
case "InternalServerException":
|
|
3564
|
-
case "com.amazonaws.comprehend#InternalServerException":
|
|
3565
|
-
throw await de_InternalServerExceptionRes(parsedOutput, context);
|
|
3566
|
-
case "InvalidRequestException":
|
|
3567
|
-
case "com.amazonaws.comprehend#InvalidRequestException":
|
|
3568
|
-
throw await de_InvalidRequestExceptionRes(parsedOutput, context);
|
|
3569
|
-
case "KmsKeyValidationException":
|
|
3570
|
-
case "com.amazonaws.comprehend#KmsKeyValidationException":
|
|
3571
|
-
throw await de_KmsKeyValidationExceptionRes(parsedOutput, context);
|
|
3572
|
-
case "ResourceInUseException":
|
|
3573
|
-
case "com.amazonaws.comprehend#ResourceInUseException":
|
|
3574
|
-
throw await de_ResourceInUseExceptionRes(parsedOutput, context);
|
|
3575
|
-
case "TooManyRequestsException":
|
|
3576
|
-
case "com.amazonaws.comprehend#TooManyRequestsException":
|
|
3577
|
-
throw await de_TooManyRequestsExceptionRes(parsedOutput, context);
|
|
3578
|
-
case "TooManyTagsException":
|
|
3579
|
-
case "com.amazonaws.comprehend#TooManyTagsException":
|
|
3580
|
-
throw await de_TooManyTagsExceptionRes(parsedOutput, context);
|
|
3581
|
-
default:
|
|
3582
|
-
const parsedBody = parsedOutput.body;
|
|
3583
|
-
return throwDefaultError({
|
|
3584
|
-
output,
|
|
3585
|
-
parsedBody,
|
|
3586
|
-
errorCode,
|
|
3587
|
-
});
|
|
3588
|
-
}
|
|
3589
|
-
};
|
|
3590
|
-
export const de_StartTopicsDetectionJobCommand = async (output, context) => {
|
|
1375
|
+
export const de_StartFlywheelIterationCommand = async (output, context) => {
|
|
3591
1376
|
if (output.statusCode >= 300) {
|
|
3592
|
-
return
|
|
1377
|
+
return de_CommandError(output, context);
|
|
3593
1378
|
}
|
|
3594
1379
|
const data = await parseBody(output.body, context);
|
|
3595
1380
|
let contents = {};
|
|
@@ -3600,43 +1385,9 @@ export const de_StartTopicsDetectionJobCommand = async (output, context) => {
|
|
|
3600
1385
|
};
|
|
3601
1386
|
return response;
|
|
3602
1387
|
};
|
|
3603
|
-
const
|
|
3604
|
-
const parsedOutput = {
|
|
3605
|
-
...output,
|
|
3606
|
-
body: await parseErrorBody(output.body, context),
|
|
3607
|
-
};
|
|
3608
|
-
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
3609
|
-
switch (errorCode) {
|
|
3610
|
-
case "InternalServerException":
|
|
3611
|
-
case "com.amazonaws.comprehend#InternalServerException":
|
|
3612
|
-
throw await de_InternalServerExceptionRes(parsedOutput, context);
|
|
3613
|
-
case "InvalidRequestException":
|
|
3614
|
-
case "com.amazonaws.comprehend#InvalidRequestException":
|
|
3615
|
-
throw await de_InvalidRequestExceptionRes(parsedOutput, context);
|
|
3616
|
-
case "KmsKeyValidationException":
|
|
3617
|
-
case "com.amazonaws.comprehend#KmsKeyValidationException":
|
|
3618
|
-
throw await de_KmsKeyValidationExceptionRes(parsedOutput, context);
|
|
3619
|
-
case "ResourceInUseException":
|
|
3620
|
-
case "com.amazonaws.comprehend#ResourceInUseException":
|
|
3621
|
-
throw await de_ResourceInUseExceptionRes(parsedOutput, context);
|
|
3622
|
-
case "TooManyRequestsException":
|
|
3623
|
-
case "com.amazonaws.comprehend#TooManyRequestsException":
|
|
3624
|
-
throw await de_TooManyRequestsExceptionRes(parsedOutput, context);
|
|
3625
|
-
case "TooManyTagsException":
|
|
3626
|
-
case "com.amazonaws.comprehend#TooManyTagsException":
|
|
3627
|
-
throw await de_TooManyTagsExceptionRes(parsedOutput, context);
|
|
3628
|
-
default:
|
|
3629
|
-
const parsedBody = parsedOutput.body;
|
|
3630
|
-
return throwDefaultError({
|
|
3631
|
-
output,
|
|
3632
|
-
parsedBody,
|
|
3633
|
-
errorCode,
|
|
3634
|
-
});
|
|
3635
|
-
}
|
|
3636
|
-
};
|
|
3637
|
-
export const de_StopDominantLanguageDetectionJobCommand = async (output, context) => {
|
|
1388
|
+
export const de_StartKeyPhrasesDetectionJobCommand = async (output, context) => {
|
|
3638
1389
|
if (output.statusCode >= 300) {
|
|
3639
|
-
return
|
|
1390
|
+
return de_CommandError(output, context);
|
|
3640
1391
|
}
|
|
3641
1392
|
const data = await parseBody(output.body, context);
|
|
3642
1393
|
let contents = {};
|
|
@@ -3647,34 +1398,9 @@ export const de_StopDominantLanguageDetectionJobCommand = async (output, context
|
|
|
3647
1398
|
};
|
|
3648
1399
|
return response;
|
|
3649
1400
|
};
|
|
3650
|
-
const
|
|
3651
|
-
const parsedOutput = {
|
|
3652
|
-
...output,
|
|
3653
|
-
body: await parseErrorBody(output.body, context),
|
|
3654
|
-
};
|
|
3655
|
-
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
3656
|
-
switch (errorCode) {
|
|
3657
|
-
case "InternalServerException":
|
|
3658
|
-
case "com.amazonaws.comprehend#InternalServerException":
|
|
3659
|
-
throw await de_InternalServerExceptionRes(parsedOutput, context);
|
|
3660
|
-
case "InvalidRequestException":
|
|
3661
|
-
case "com.amazonaws.comprehend#InvalidRequestException":
|
|
3662
|
-
throw await de_InvalidRequestExceptionRes(parsedOutput, context);
|
|
3663
|
-
case "JobNotFoundException":
|
|
3664
|
-
case "com.amazonaws.comprehend#JobNotFoundException":
|
|
3665
|
-
throw await de_JobNotFoundExceptionRes(parsedOutput, context);
|
|
3666
|
-
default:
|
|
3667
|
-
const parsedBody = parsedOutput.body;
|
|
3668
|
-
return throwDefaultError({
|
|
3669
|
-
output,
|
|
3670
|
-
parsedBody,
|
|
3671
|
-
errorCode,
|
|
3672
|
-
});
|
|
3673
|
-
}
|
|
3674
|
-
};
|
|
3675
|
-
export const de_StopEntitiesDetectionJobCommand = async (output, context) => {
|
|
1401
|
+
export const de_StartPiiEntitiesDetectionJobCommand = async (output, context) => {
|
|
3676
1402
|
if (output.statusCode >= 300) {
|
|
3677
|
-
return
|
|
1403
|
+
return de_CommandError(output, context);
|
|
3678
1404
|
}
|
|
3679
1405
|
const data = await parseBody(output.body, context);
|
|
3680
1406
|
let contents = {};
|
|
@@ -3685,34 +1411,22 @@ export const de_StopEntitiesDetectionJobCommand = async (output, context) => {
|
|
|
3685
1411
|
};
|
|
3686
1412
|
return response;
|
|
3687
1413
|
};
|
|
3688
|
-
const
|
|
3689
|
-
|
|
3690
|
-
|
|
3691
|
-
body: await parseErrorBody(output.body, context),
|
|
3692
|
-
};
|
|
3693
|
-
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
3694
|
-
switch (errorCode) {
|
|
3695
|
-
case "InternalServerException":
|
|
3696
|
-
case "com.amazonaws.comprehend#InternalServerException":
|
|
3697
|
-
throw await de_InternalServerExceptionRes(parsedOutput, context);
|
|
3698
|
-
case "InvalidRequestException":
|
|
3699
|
-
case "com.amazonaws.comprehend#InvalidRequestException":
|
|
3700
|
-
throw await de_InvalidRequestExceptionRes(parsedOutput, context);
|
|
3701
|
-
case "JobNotFoundException":
|
|
3702
|
-
case "com.amazonaws.comprehend#JobNotFoundException":
|
|
3703
|
-
throw await de_JobNotFoundExceptionRes(parsedOutput, context);
|
|
3704
|
-
default:
|
|
3705
|
-
const parsedBody = parsedOutput.body;
|
|
3706
|
-
return throwDefaultError({
|
|
3707
|
-
output,
|
|
3708
|
-
parsedBody,
|
|
3709
|
-
errorCode,
|
|
3710
|
-
});
|
|
1414
|
+
export const de_StartSentimentDetectionJobCommand = async (output, context) => {
|
|
1415
|
+
if (output.statusCode >= 300) {
|
|
1416
|
+
return de_CommandError(output, context);
|
|
3711
1417
|
}
|
|
1418
|
+
const data = await parseBody(output.body, context);
|
|
1419
|
+
let contents = {};
|
|
1420
|
+
contents = _json(data);
|
|
1421
|
+
const response = {
|
|
1422
|
+
$metadata: deserializeMetadata(output),
|
|
1423
|
+
...contents,
|
|
1424
|
+
};
|
|
1425
|
+
return response;
|
|
3712
1426
|
};
|
|
3713
|
-
export const
|
|
1427
|
+
export const de_StartTargetedSentimentDetectionJobCommand = async (output, context) => {
|
|
3714
1428
|
if (output.statusCode >= 300) {
|
|
3715
|
-
return
|
|
1429
|
+
return de_CommandError(output, context);
|
|
3716
1430
|
}
|
|
3717
1431
|
const data = await parseBody(output.body, context);
|
|
3718
1432
|
let contents = {};
|
|
@@ -3723,34 +1437,22 @@ export const de_StopEventsDetectionJobCommand = async (output, context) => {
|
|
|
3723
1437
|
};
|
|
3724
1438
|
return response;
|
|
3725
1439
|
};
|
|
3726
|
-
const
|
|
3727
|
-
|
|
3728
|
-
|
|
3729
|
-
body: await parseErrorBody(output.body, context),
|
|
3730
|
-
};
|
|
3731
|
-
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
3732
|
-
switch (errorCode) {
|
|
3733
|
-
case "InternalServerException":
|
|
3734
|
-
case "com.amazonaws.comprehend#InternalServerException":
|
|
3735
|
-
throw await de_InternalServerExceptionRes(parsedOutput, context);
|
|
3736
|
-
case "InvalidRequestException":
|
|
3737
|
-
case "com.amazonaws.comprehend#InvalidRequestException":
|
|
3738
|
-
throw await de_InvalidRequestExceptionRes(parsedOutput, context);
|
|
3739
|
-
case "JobNotFoundException":
|
|
3740
|
-
case "com.amazonaws.comprehend#JobNotFoundException":
|
|
3741
|
-
throw await de_JobNotFoundExceptionRes(parsedOutput, context);
|
|
3742
|
-
default:
|
|
3743
|
-
const parsedBody = parsedOutput.body;
|
|
3744
|
-
return throwDefaultError({
|
|
3745
|
-
output,
|
|
3746
|
-
parsedBody,
|
|
3747
|
-
errorCode,
|
|
3748
|
-
});
|
|
1440
|
+
export const de_StartTopicsDetectionJobCommand = async (output, context) => {
|
|
1441
|
+
if (output.statusCode >= 300) {
|
|
1442
|
+
return de_CommandError(output, context);
|
|
3749
1443
|
}
|
|
1444
|
+
const data = await parseBody(output.body, context);
|
|
1445
|
+
let contents = {};
|
|
1446
|
+
contents = _json(data);
|
|
1447
|
+
const response = {
|
|
1448
|
+
$metadata: deserializeMetadata(output),
|
|
1449
|
+
...contents,
|
|
1450
|
+
};
|
|
1451
|
+
return response;
|
|
3750
1452
|
};
|
|
3751
|
-
export const
|
|
1453
|
+
export const de_StopDominantLanguageDetectionJobCommand = async (output, context) => {
|
|
3752
1454
|
if (output.statusCode >= 300) {
|
|
3753
|
-
return
|
|
1455
|
+
return de_CommandError(output, context);
|
|
3754
1456
|
}
|
|
3755
1457
|
const data = await parseBody(output.body, context);
|
|
3756
1458
|
let contents = {};
|
|
@@ -3761,34 +1463,22 @@ export const de_StopKeyPhrasesDetectionJobCommand = async (output, context) => {
|
|
|
3761
1463
|
};
|
|
3762
1464
|
return response;
|
|
3763
1465
|
};
|
|
3764
|
-
const
|
|
3765
|
-
|
|
3766
|
-
|
|
3767
|
-
body: await parseErrorBody(output.body, context),
|
|
3768
|
-
};
|
|
3769
|
-
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
3770
|
-
switch (errorCode) {
|
|
3771
|
-
case "InternalServerException":
|
|
3772
|
-
case "com.amazonaws.comprehend#InternalServerException":
|
|
3773
|
-
throw await de_InternalServerExceptionRes(parsedOutput, context);
|
|
3774
|
-
case "InvalidRequestException":
|
|
3775
|
-
case "com.amazonaws.comprehend#InvalidRequestException":
|
|
3776
|
-
throw await de_InvalidRequestExceptionRes(parsedOutput, context);
|
|
3777
|
-
case "JobNotFoundException":
|
|
3778
|
-
case "com.amazonaws.comprehend#JobNotFoundException":
|
|
3779
|
-
throw await de_JobNotFoundExceptionRes(parsedOutput, context);
|
|
3780
|
-
default:
|
|
3781
|
-
const parsedBody = parsedOutput.body;
|
|
3782
|
-
return throwDefaultError({
|
|
3783
|
-
output,
|
|
3784
|
-
parsedBody,
|
|
3785
|
-
errorCode,
|
|
3786
|
-
});
|
|
1466
|
+
export const de_StopEntitiesDetectionJobCommand = async (output, context) => {
|
|
1467
|
+
if (output.statusCode >= 300) {
|
|
1468
|
+
return de_CommandError(output, context);
|
|
3787
1469
|
}
|
|
1470
|
+
const data = await parseBody(output.body, context);
|
|
1471
|
+
let contents = {};
|
|
1472
|
+
contents = _json(data);
|
|
1473
|
+
const response = {
|
|
1474
|
+
$metadata: deserializeMetadata(output),
|
|
1475
|
+
...contents,
|
|
1476
|
+
};
|
|
1477
|
+
return response;
|
|
3788
1478
|
};
|
|
3789
|
-
export const
|
|
1479
|
+
export const de_StopEventsDetectionJobCommand = async (output, context) => {
|
|
3790
1480
|
if (output.statusCode >= 300) {
|
|
3791
|
-
return
|
|
1481
|
+
return de_CommandError(output, context);
|
|
3792
1482
|
}
|
|
3793
1483
|
const data = await parseBody(output.body, context);
|
|
3794
1484
|
let contents = {};
|
|
@@ -3799,34 +1489,22 @@ export const de_StopPiiEntitiesDetectionJobCommand = async (output, context) =>
|
|
|
3799
1489
|
};
|
|
3800
1490
|
return response;
|
|
3801
1491
|
};
|
|
3802
|
-
const
|
|
3803
|
-
|
|
3804
|
-
|
|
3805
|
-
body: await parseErrorBody(output.body, context),
|
|
3806
|
-
};
|
|
3807
|
-
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
3808
|
-
switch (errorCode) {
|
|
3809
|
-
case "InternalServerException":
|
|
3810
|
-
case "com.amazonaws.comprehend#InternalServerException":
|
|
3811
|
-
throw await de_InternalServerExceptionRes(parsedOutput, context);
|
|
3812
|
-
case "InvalidRequestException":
|
|
3813
|
-
case "com.amazonaws.comprehend#InvalidRequestException":
|
|
3814
|
-
throw await de_InvalidRequestExceptionRes(parsedOutput, context);
|
|
3815
|
-
case "JobNotFoundException":
|
|
3816
|
-
case "com.amazonaws.comprehend#JobNotFoundException":
|
|
3817
|
-
throw await de_JobNotFoundExceptionRes(parsedOutput, context);
|
|
3818
|
-
default:
|
|
3819
|
-
const parsedBody = parsedOutput.body;
|
|
3820
|
-
return throwDefaultError({
|
|
3821
|
-
output,
|
|
3822
|
-
parsedBody,
|
|
3823
|
-
errorCode,
|
|
3824
|
-
});
|
|
1492
|
+
export const de_StopKeyPhrasesDetectionJobCommand = async (output, context) => {
|
|
1493
|
+
if (output.statusCode >= 300) {
|
|
1494
|
+
return de_CommandError(output, context);
|
|
3825
1495
|
}
|
|
1496
|
+
const data = await parseBody(output.body, context);
|
|
1497
|
+
let contents = {};
|
|
1498
|
+
contents = _json(data);
|
|
1499
|
+
const response = {
|
|
1500
|
+
$metadata: deserializeMetadata(output),
|
|
1501
|
+
...contents,
|
|
1502
|
+
};
|
|
1503
|
+
return response;
|
|
3826
1504
|
};
|
|
3827
|
-
export const
|
|
1505
|
+
export const de_StopPiiEntitiesDetectionJobCommand = async (output, context) => {
|
|
3828
1506
|
if (output.statusCode >= 300) {
|
|
3829
|
-
return
|
|
1507
|
+
return de_CommandError(output, context);
|
|
3830
1508
|
}
|
|
3831
1509
|
const data = await parseBody(output.body, context);
|
|
3832
1510
|
let contents = {};
|
|
@@ -3837,34 +1515,22 @@ export const de_StopSentimentDetectionJobCommand = async (output, context) => {
|
|
|
3837
1515
|
};
|
|
3838
1516
|
return response;
|
|
3839
1517
|
};
|
|
3840
|
-
const
|
|
3841
|
-
|
|
3842
|
-
|
|
3843
|
-
body: await parseErrorBody(output.body, context),
|
|
3844
|
-
};
|
|
3845
|
-
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
3846
|
-
switch (errorCode) {
|
|
3847
|
-
case "InternalServerException":
|
|
3848
|
-
case "com.amazonaws.comprehend#InternalServerException":
|
|
3849
|
-
throw await de_InternalServerExceptionRes(parsedOutput, context);
|
|
3850
|
-
case "InvalidRequestException":
|
|
3851
|
-
case "com.amazonaws.comprehend#InvalidRequestException":
|
|
3852
|
-
throw await de_InvalidRequestExceptionRes(parsedOutput, context);
|
|
3853
|
-
case "JobNotFoundException":
|
|
3854
|
-
case "com.amazonaws.comprehend#JobNotFoundException":
|
|
3855
|
-
throw await de_JobNotFoundExceptionRes(parsedOutput, context);
|
|
3856
|
-
default:
|
|
3857
|
-
const parsedBody = parsedOutput.body;
|
|
3858
|
-
return throwDefaultError({
|
|
3859
|
-
output,
|
|
3860
|
-
parsedBody,
|
|
3861
|
-
errorCode,
|
|
3862
|
-
});
|
|
1518
|
+
export const de_StopSentimentDetectionJobCommand = async (output, context) => {
|
|
1519
|
+
if (output.statusCode >= 300) {
|
|
1520
|
+
return de_CommandError(output, context);
|
|
3863
1521
|
}
|
|
1522
|
+
const data = await parseBody(output.body, context);
|
|
1523
|
+
let contents = {};
|
|
1524
|
+
contents = _json(data);
|
|
1525
|
+
const response = {
|
|
1526
|
+
$metadata: deserializeMetadata(output),
|
|
1527
|
+
...contents,
|
|
1528
|
+
};
|
|
1529
|
+
return response;
|
|
3864
1530
|
};
|
|
3865
1531
|
export const de_StopTargetedSentimentDetectionJobCommand = async (output, context) => {
|
|
3866
1532
|
if (output.statusCode >= 300) {
|
|
3867
|
-
return
|
|
1533
|
+
return de_CommandError(output, context);
|
|
3868
1534
|
}
|
|
3869
1535
|
const data = await parseBody(output.body, context);
|
|
3870
1536
|
let contents = {};
|
|
@@ -3875,34 +1541,9 @@ export const de_StopTargetedSentimentDetectionJobCommand = async (output, contex
|
|
|
3875
1541
|
};
|
|
3876
1542
|
return response;
|
|
3877
1543
|
};
|
|
3878
|
-
const de_StopTargetedSentimentDetectionJobCommandError = async (output, context) => {
|
|
3879
|
-
const parsedOutput = {
|
|
3880
|
-
...output,
|
|
3881
|
-
body: await parseErrorBody(output.body, context),
|
|
3882
|
-
};
|
|
3883
|
-
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
3884
|
-
switch (errorCode) {
|
|
3885
|
-
case "InternalServerException":
|
|
3886
|
-
case "com.amazonaws.comprehend#InternalServerException":
|
|
3887
|
-
throw await de_InternalServerExceptionRes(parsedOutput, context);
|
|
3888
|
-
case "InvalidRequestException":
|
|
3889
|
-
case "com.amazonaws.comprehend#InvalidRequestException":
|
|
3890
|
-
throw await de_InvalidRequestExceptionRes(parsedOutput, context);
|
|
3891
|
-
case "JobNotFoundException":
|
|
3892
|
-
case "com.amazonaws.comprehend#JobNotFoundException":
|
|
3893
|
-
throw await de_JobNotFoundExceptionRes(parsedOutput, context);
|
|
3894
|
-
default:
|
|
3895
|
-
const parsedBody = parsedOutput.body;
|
|
3896
|
-
return throwDefaultError({
|
|
3897
|
-
output,
|
|
3898
|
-
parsedBody,
|
|
3899
|
-
errorCode,
|
|
3900
|
-
});
|
|
3901
|
-
}
|
|
3902
|
-
};
|
|
3903
1544
|
export const de_StopTrainingDocumentClassifierCommand = async (output, context) => {
|
|
3904
1545
|
if (output.statusCode >= 300) {
|
|
3905
|
-
return
|
|
1546
|
+
return de_CommandError(output, context);
|
|
3906
1547
|
}
|
|
3907
1548
|
const data = await parseBody(output.body, context);
|
|
3908
1549
|
let contents = {};
|
|
@@ -3913,37 +1554,9 @@ export const de_StopTrainingDocumentClassifierCommand = async (output, context)
|
|
|
3913
1554
|
};
|
|
3914
1555
|
return response;
|
|
3915
1556
|
};
|
|
3916
|
-
const de_StopTrainingDocumentClassifierCommandError = async (output, context) => {
|
|
3917
|
-
const parsedOutput = {
|
|
3918
|
-
...output,
|
|
3919
|
-
body: await parseErrorBody(output.body, context),
|
|
3920
|
-
};
|
|
3921
|
-
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
3922
|
-
switch (errorCode) {
|
|
3923
|
-
case "InternalServerException":
|
|
3924
|
-
case "com.amazonaws.comprehend#InternalServerException":
|
|
3925
|
-
throw await de_InternalServerExceptionRes(parsedOutput, context);
|
|
3926
|
-
case "InvalidRequestException":
|
|
3927
|
-
case "com.amazonaws.comprehend#InvalidRequestException":
|
|
3928
|
-
throw await de_InvalidRequestExceptionRes(parsedOutput, context);
|
|
3929
|
-
case "ResourceNotFoundException":
|
|
3930
|
-
case "com.amazonaws.comprehend#ResourceNotFoundException":
|
|
3931
|
-
throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
|
|
3932
|
-
case "TooManyRequestsException":
|
|
3933
|
-
case "com.amazonaws.comprehend#TooManyRequestsException":
|
|
3934
|
-
throw await de_TooManyRequestsExceptionRes(parsedOutput, context);
|
|
3935
|
-
default:
|
|
3936
|
-
const parsedBody = parsedOutput.body;
|
|
3937
|
-
return throwDefaultError({
|
|
3938
|
-
output,
|
|
3939
|
-
parsedBody,
|
|
3940
|
-
errorCode,
|
|
3941
|
-
});
|
|
3942
|
-
}
|
|
3943
|
-
};
|
|
3944
1557
|
export const de_StopTrainingEntityRecognizerCommand = async (output, context) => {
|
|
3945
1558
|
if (output.statusCode >= 300) {
|
|
3946
|
-
return
|
|
1559
|
+
return de_CommandError(output, context);
|
|
3947
1560
|
}
|
|
3948
1561
|
const data = await parseBody(output.body, context);
|
|
3949
1562
|
let contents = {};
|
|
@@ -3954,37 +1567,9 @@ export const de_StopTrainingEntityRecognizerCommand = async (output, context) =>
|
|
|
3954
1567
|
};
|
|
3955
1568
|
return response;
|
|
3956
1569
|
};
|
|
3957
|
-
const de_StopTrainingEntityRecognizerCommandError = async (output, context) => {
|
|
3958
|
-
const parsedOutput = {
|
|
3959
|
-
...output,
|
|
3960
|
-
body: await parseErrorBody(output.body, context),
|
|
3961
|
-
};
|
|
3962
|
-
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
3963
|
-
switch (errorCode) {
|
|
3964
|
-
case "InternalServerException":
|
|
3965
|
-
case "com.amazonaws.comprehend#InternalServerException":
|
|
3966
|
-
throw await de_InternalServerExceptionRes(parsedOutput, context);
|
|
3967
|
-
case "InvalidRequestException":
|
|
3968
|
-
case "com.amazonaws.comprehend#InvalidRequestException":
|
|
3969
|
-
throw await de_InvalidRequestExceptionRes(parsedOutput, context);
|
|
3970
|
-
case "ResourceNotFoundException":
|
|
3971
|
-
case "com.amazonaws.comprehend#ResourceNotFoundException":
|
|
3972
|
-
throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
|
|
3973
|
-
case "TooManyRequestsException":
|
|
3974
|
-
case "com.amazonaws.comprehend#TooManyRequestsException":
|
|
3975
|
-
throw await de_TooManyRequestsExceptionRes(parsedOutput, context);
|
|
3976
|
-
default:
|
|
3977
|
-
const parsedBody = parsedOutput.body;
|
|
3978
|
-
return throwDefaultError({
|
|
3979
|
-
output,
|
|
3980
|
-
parsedBody,
|
|
3981
|
-
errorCode,
|
|
3982
|
-
});
|
|
3983
|
-
}
|
|
3984
|
-
};
|
|
3985
1570
|
export const de_TagResourceCommand = async (output, context) => {
|
|
3986
1571
|
if (output.statusCode >= 300) {
|
|
3987
|
-
return
|
|
1572
|
+
return de_CommandError(output, context);
|
|
3988
1573
|
}
|
|
3989
1574
|
const data = await parseBody(output.body, context);
|
|
3990
1575
|
let contents = {};
|
|
@@ -3995,40 +1580,9 @@ export const de_TagResourceCommand = async (output, context) => {
|
|
|
3995
1580
|
};
|
|
3996
1581
|
return response;
|
|
3997
1582
|
};
|
|
3998
|
-
const de_TagResourceCommandError = async (output, context) => {
|
|
3999
|
-
const parsedOutput = {
|
|
4000
|
-
...output,
|
|
4001
|
-
body: await parseErrorBody(output.body, context),
|
|
4002
|
-
};
|
|
4003
|
-
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
4004
|
-
switch (errorCode) {
|
|
4005
|
-
case "ConcurrentModificationException":
|
|
4006
|
-
case "com.amazonaws.comprehend#ConcurrentModificationException":
|
|
4007
|
-
throw await de_ConcurrentModificationExceptionRes(parsedOutput, context);
|
|
4008
|
-
case "InternalServerException":
|
|
4009
|
-
case "com.amazonaws.comprehend#InternalServerException":
|
|
4010
|
-
throw await de_InternalServerExceptionRes(parsedOutput, context);
|
|
4011
|
-
case "InvalidRequestException":
|
|
4012
|
-
case "com.amazonaws.comprehend#InvalidRequestException":
|
|
4013
|
-
throw await de_InvalidRequestExceptionRes(parsedOutput, context);
|
|
4014
|
-
case "ResourceNotFoundException":
|
|
4015
|
-
case "com.amazonaws.comprehend#ResourceNotFoundException":
|
|
4016
|
-
throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
|
|
4017
|
-
case "TooManyTagsException":
|
|
4018
|
-
case "com.amazonaws.comprehend#TooManyTagsException":
|
|
4019
|
-
throw await de_TooManyTagsExceptionRes(parsedOutput, context);
|
|
4020
|
-
default:
|
|
4021
|
-
const parsedBody = parsedOutput.body;
|
|
4022
|
-
return throwDefaultError({
|
|
4023
|
-
output,
|
|
4024
|
-
parsedBody,
|
|
4025
|
-
errorCode,
|
|
4026
|
-
});
|
|
4027
|
-
}
|
|
4028
|
-
};
|
|
4029
1583
|
export const de_UntagResourceCommand = async (output, context) => {
|
|
4030
1584
|
if (output.statusCode >= 300) {
|
|
4031
|
-
return
|
|
1585
|
+
return de_CommandError(output, context);
|
|
4032
1586
|
}
|
|
4033
1587
|
const data = await parseBody(output.body, context);
|
|
4034
1588
|
let contents = {};
|
|
@@ -4039,40 +1593,9 @@ export const de_UntagResourceCommand = async (output, context) => {
|
|
|
4039
1593
|
};
|
|
4040
1594
|
return response;
|
|
4041
1595
|
};
|
|
4042
|
-
const de_UntagResourceCommandError = async (output, context) => {
|
|
4043
|
-
const parsedOutput = {
|
|
4044
|
-
...output,
|
|
4045
|
-
body: await parseErrorBody(output.body, context),
|
|
4046
|
-
};
|
|
4047
|
-
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
4048
|
-
switch (errorCode) {
|
|
4049
|
-
case "ConcurrentModificationException":
|
|
4050
|
-
case "com.amazonaws.comprehend#ConcurrentModificationException":
|
|
4051
|
-
throw await de_ConcurrentModificationExceptionRes(parsedOutput, context);
|
|
4052
|
-
case "InternalServerException":
|
|
4053
|
-
case "com.amazonaws.comprehend#InternalServerException":
|
|
4054
|
-
throw await de_InternalServerExceptionRes(parsedOutput, context);
|
|
4055
|
-
case "InvalidRequestException":
|
|
4056
|
-
case "com.amazonaws.comprehend#InvalidRequestException":
|
|
4057
|
-
throw await de_InvalidRequestExceptionRes(parsedOutput, context);
|
|
4058
|
-
case "ResourceNotFoundException":
|
|
4059
|
-
case "com.amazonaws.comprehend#ResourceNotFoundException":
|
|
4060
|
-
throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
|
|
4061
|
-
case "TooManyTagKeysException":
|
|
4062
|
-
case "com.amazonaws.comprehend#TooManyTagKeysException":
|
|
4063
|
-
throw await de_TooManyTagKeysExceptionRes(parsedOutput, context);
|
|
4064
|
-
default:
|
|
4065
|
-
const parsedBody = parsedOutput.body;
|
|
4066
|
-
return throwDefaultError({
|
|
4067
|
-
output,
|
|
4068
|
-
parsedBody,
|
|
4069
|
-
errorCode,
|
|
4070
|
-
});
|
|
4071
|
-
}
|
|
4072
|
-
};
|
|
4073
1596
|
export const de_UpdateEndpointCommand = async (output, context) => {
|
|
4074
1597
|
if (output.statusCode >= 300) {
|
|
4075
|
-
return
|
|
1598
|
+
return de_CommandError(output, context);
|
|
4076
1599
|
}
|
|
4077
1600
|
const data = await parseBody(output.body, context);
|
|
4078
1601
|
let contents = {};
|
|
@@ -4083,46 +1606,9 @@ export const de_UpdateEndpointCommand = async (output, context) => {
|
|
|
4083
1606
|
};
|
|
4084
1607
|
return response;
|
|
4085
1608
|
};
|
|
4086
|
-
const de_UpdateEndpointCommandError = async (output, context) => {
|
|
4087
|
-
const parsedOutput = {
|
|
4088
|
-
...output,
|
|
4089
|
-
body: await parseErrorBody(output.body, context),
|
|
4090
|
-
};
|
|
4091
|
-
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
4092
|
-
switch (errorCode) {
|
|
4093
|
-
case "InternalServerException":
|
|
4094
|
-
case "com.amazonaws.comprehend#InternalServerException":
|
|
4095
|
-
throw await de_InternalServerExceptionRes(parsedOutput, context);
|
|
4096
|
-
case "InvalidRequestException":
|
|
4097
|
-
case "com.amazonaws.comprehend#InvalidRequestException":
|
|
4098
|
-
throw await de_InvalidRequestExceptionRes(parsedOutput, context);
|
|
4099
|
-
case "ResourceInUseException":
|
|
4100
|
-
case "com.amazonaws.comprehend#ResourceInUseException":
|
|
4101
|
-
throw await de_ResourceInUseExceptionRes(parsedOutput, context);
|
|
4102
|
-
case "ResourceLimitExceededException":
|
|
4103
|
-
case "com.amazonaws.comprehend#ResourceLimitExceededException":
|
|
4104
|
-
throw await de_ResourceLimitExceededExceptionRes(parsedOutput, context);
|
|
4105
|
-
case "ResourceNotFoundException":
|
|
4106
|
-
case "com.amazonaws.comprehend#ResourceNotFoundException":
|
|
4107
|
-
throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
|
|
4108
|
-
case "ResourceUnavailableException":
|
|
4109
|
-
case "com.amazonaws.comprehend#ResourceUnavailableException":
|
|
4110
|
-
throw await de_ResourceUnavailableExceptionRes(parsedOutput, context);
|
|
4111
|
-
case "TooManyRequestsException":
|
|
4112
|
-
case "com.amazonaws.comprehend#TooManyRequestsException":
|
|
4113
|
-
throw await de_TooManyRequestsExceptionRes(parsedOutput, context);
|
|
4114
|
-
default:
|
|
4115
|
-
const parsedBody = parsedOutput.body;
|
|
4116
|
-
return throwDefaultError({
|
|
4117
|
-
output,
|
|
4118
|
-
parsedBody,
|
|
4119
|
-
errorCode,
|
|
4120
|
-
});
|
|
4121
|
-
}
|
|
4122
|
-
};
|
|
4123
1609
|
export const de_UpdateFlywheelCommand = async (output, context) => {
|
|
4124
1610
|
if (output.statusCode >= 300) {
|
|
4125
|
-
return
|
|
1611
|
+
return de_CommandError(output, context);
|
|
4126
1612
|
}
|
|
4127
1613
|
const data = await parseBody(output.body, context);
|
|
4128
1614
|
let contents = {};
|
|
@@ -4133,28 +1619,61 @@ export const de_UpdateFlywheelCommand = async (output, context) => {
|
|
|
4133
1619
|
};
|
|
4134
1620
|
return response;
|
|
4135
1621
|
};
|
|
4136
|
-
const
|
|
1622
|
+
const de_CommandError = async (output, context) => {
|
|
4137
1623
|
const parsedOutput = {
|
|
4138
1624
|
...output,
|
|
4139
1625
|
body: await parseErrorBody(output.body, context),
|
|
4140
1626
|
};
|
|
4141
1627
|
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
4142
1628
|
switch (errorCode) {
|
|
1629
|
+
case "BatchSizeLimitExceededException":
|
|
1630
|
+
case "com.amazonaws.comprehend#BatchSizeLimitExceededException":
|
|
1631
|
+
throw await de_BatchSizeLimitExceededExceptionRes(parsedOutput, context);
|
|
4143
1632
|
case "InternalServerException":
|
|
4144
1633
|
case "com.amazonaws.comprehend#InternalServerException":
|
|
4145
1634
|
throw await de_InternalServerExceptionRes(parsedOutput, context);
|
|
4146
1635
|
case "InvalidRequestException":
|
|
4147
1636
|
case "com.amazonaws.comprehend#InvalidRequestException":
|
|
4148
1637
|
throw await de_InvalidRequestExceptionRes(parsedOutput, context);
|
|
4149
|
-
case "
|
|
4150
|
-
case "com.amazonaws.comprehend#
|
|
4151
|
-
throw await
|
|
1638
|
+
case "TextSizeLimitExceededException":
|
|
1639
|
+
case "com.amazonaws.comprehend#TextSizeLimitExceededException":
|
|
1640
|
+
throw await de_TextSizeLimitExceededExceptionRes(parsedOutput, context);
|
|
1641
|
+
case "UnsupportedLanguageException":
|
|
1642
|
+
case "com.amazonaws.comprehend#UnsupportedLanguageException":
|
|
1643
|
+
throw await de_UnsupportedLanguageExceptionRes(parsedOutput, context);
|
|
1644
|
+
case "ResourceUnavailableException":
|
|
1645
|
+
case "com.amazonaws.comprehend#ResourceUnavailableException":
|
|
1646
|
+
throw await de_ResourceUnavailableExceptionRes(parsedOutput, context);
|
|
1647
|
+
case "ResourceInUseException":
|
|
1648
|
+
case "com.amazonaws.comprehend#ResourceInUseException":
|
|
1649
|
+
throw await de_ResourceInUseExceptionRes(parsedOutput, context);
|
|
1650
|
+
case "ResourceLimitExceededException":
|
|
1651
|
+
case "com.amazonaws.comprehend#ResourceLimitExceededException":
|
|
1652
|
+
throw await de_ResourceLimitExceededExceptionRes(parsedOutput, context);
|
|
4152
1653
|
case "ResourceNotFoundException":
|
|
4153
1654
|
case "com.amazonaws.comprehend#ResourceNotFoundException":
|
|
4154
1655
|
throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
|
|
4155
1656
|
case "TooManyRequestsException":
|
|
4156
1657
|
case "com.amazonaws.comprehend#TooManyRequestsException":
|
|
4157
1658
|
throw await de_TooManyRequestsExceptionRes(parsedOutput, context);
|
|
1659
|
+
case "TooManyTagsException":
|
|
1660
|
+
case "com.amazonaws.comprehend#TooManyTagsException":
|
|
1661
|
+
throw await de_TooManyTagsExceptionRes(parsedOutput, context);
|
|
1662
|
+
case "KmsKeyValidationException":
|
|
1663
|
+
case "com.amazonaws.comprehend#KmsKeyValidationException":
|
|
1664
|
+
throw await de_KmsKeyValidationExceptionRes(parsedOutput, context);
|
|
1665
|
+
case "JobNotFoundException":
|
|
1666
|
+
case "com.amazonaws.comprehend#JobNotFoundException":
|
|
1667
|
+
throw await de_JobNotFoundExceptionRes(parsedOutput, context);
|
|
1668
|
+
case "InvalidFilterException":
|
|
1669
|
+
case "com.amazonaws.comprehend#InvalidFilterException":
|
|
1670
|
+
throw await de_InvalidFilterExceptionRes(parsedOutput, context);
|
|
1671
|
+
case "ConcurrentModificationException":
|
|
1672
|
+
case "com.amazonaws.comprehend#ConcurrentModificationException":
|
|
1673
|
+
throw await de_ConcurrentModificationExceptionRes(parsedOutput, context);
|
|
1674
|
+
case "TooManyTagKeysException":
|
|
1675
|
+
case "com.amazonaws.comprehend#TooManyTagKeysException":
|
|
1676
|
+
throw await de_TooManyTagKeysExceptionRes(parsedOutput, context);
|
|
4158
1677
|
default:
|
|
4159
1678
|
const parsedBody = parsedOutput.body;
|
|
4160
1679
|
return throwDefaultError({
|