@aws-sdk/client-mturk 3.141.0 → 3.142.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/CHANGELOG.md +11 -0
- package/dist-cjs/protocols/Aws_json1_1.js +195 -345
- package/dist-es/protocols/Aws_json1_1.js +313 -346
- package/package.json +6 -6
|
@@ -415,7 +415,6 @@ const deserializeAws_json1_1AcceptQualificationRequestCommandError = async (outp
|
|
|
415
415
|
...output,
|
|
416
416
|
body: await parseBody(output.body, context),
|
|
417
417
|
};
|
|
418
|
-
let response;
|
|
419
418
|
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
420
419
|
switch (errorCode) {
|
|
421
420
|
case "RequestError":
|
|
@@ -426,14 +425,12 @@ const deserializeAws_json1_1AcceptQualificationRequestCommandError = async (outp
|
|
|
426
425
|
throw await deserializeAws_json1_1ServiceFaultResponse(parsedOutput, context);
|
|
427
426
|
default:
|
|
428
427
|
const parsedBody = parsedOutput.body;
|
|
429
|
-
|
|
430
|
-
|
|
431
|
-
|
|
432
|
-
|
|
433
|
-
|
|
434
|
-
$metadata,
|
|
428
|
+
(0, smithy_client_1.throwDefaultError)({
|
|
429
|
+
output,
|
|
430
|
+
parsedBody,
|
|
431
|
+
exceptionCtor: MTurkServiceException_1.MTurkServiceException,
|
|
432
|
+
errorCode,
|
|
435
433
|
});
|
|
436
|
-
throw (0, smithy_client_1.decorateServiceException)(response, parsedBody);
|
|
437
434
|
}
|
|
438
435
|
};
|
|
439
436
|
const deserializeAws_json1_1ApproveAssignmentCommand = async (output, context) => {
|
|
@@ -455,7 +452,6 @@ const deserializeAws_json1_1ApproveAssignmentCommandError = async (output, conte
|
|
|
455
452
|
...output,
|
|
456
453
|
body: await parseBody(output.body, context),
|
|
457
454
|
};
|
|
458
|
-
let response;
|
|
459
455
|
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
460
456
|
switch (errorCode) {
|
|
461
457
|
case "RequestError":
|
|
@@ -466,14 +462,12 @@ const deserializeAws_json1_1ApproveAssignmentCommandError = async (output, conte
|
|
|
466
462
|
throw await deserializeAws_json1_1ServiceFaultResponse(parsedOutput, context);
|
|
467
463
|
default:
|
|
468
464
|
const parsedBody = parsedOutput.body;
|
|
469
|
-
|
|
470
|
-
|
|
471
|
-
|
|
472
|
-
|
|
473
|
-
|
|
474
|
-
$metadata,
|
|
465
|
+
(0, smithy_client_1.throwDefaultError)({
|
|
466
|
+
output,
|
|
467
|
+
parsedBody,
|
|
468
|
+
exceptionCtor: MTurkServiceException_1.MTurkServiceException,
|
|
469
|
+
errorCode,
|
|
475
470
|
});
|
|
476
|
-
throw (0, smithy_client_1.decorateServiceException)(response, parsedBody);
|
|
477
471
|
}
|
|
478
472
|
};
|
|
479
473
|
const deserializeAws_json1_1AssociateQualificationWithWorkerCommand = async (output, context) => {
|
|
@@ -495,7 +489,6 @@ const deserializeAws_json1_1AssociateQualificationWithWorkerCommandError = async
|
|
|
495
489
|
...output,
|
|
496
490
|
body: await parseBody(output.body, context),
|
|
497
491
|
};
|
|
498
|
-
let response;
|
|
499
492
|
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
500
493
|
switch (errorCode) {
|
|
501
494
|
case "RequestError":
|
|
@@ -506,14 +499,12 @@ const deserializeAws_json1_1AssociateQualificationWithWorkerCommandError = async
|
|
|
506
499
|
throw await deserializeAws_json1_1ServiceFaultResponse(parsedOutput, context);
|
|
507
500
|
default:
|
|
508
501
|
const parsedBody = parsedOutput.body;
|
|
509
|
-
|
|
510
|
-
|
|
511
|
-
|
|
512
|
-
|
|
513
|
-
|
|
514
|
-
$metadata,
|
|
502
|
+
(0, smithy_client_1.throwDefaultError)({
|
|
503
|
+
output,
|
|
504
|
+
parsedBody,
|
|
505
|
+
exceptionCtor: MTurkServiceException_1.MTurkServiceException,
|
|
506
|
+
errorCode,
|
|
515
507
|
});
|
|
516
|
-
throw (0, smithy_client_1.decorateServiceException)(response, parsedBody);
|
|
517
508
|
}
|
|
518
509
|
};
|
|
519
510
|
const deserializeAws_json1_1CreateAdditionalAssignmentsForHITCommand = async (output, context) => {
|
|
@@ -535,7 +526,6 @@ const deserializeAws_json1_1CreateAdditionalAssignmentsForHITCommandError = asyn
|
|
|
535
526
|
...output,
|
|
536
527
|
body: await parseBody(output.body, context),
|
|
537
528
|
};
|
|
538
|
-
let response;
|
|
539
529
|
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
540
530
|
switch (errorCode) {
|
|
541
531
|
case "RequestError":
|
|
@@ -546,14 +536,12 @@ const deserializeAws_json1_1CreateAdditionalAssignmentsForHITCommandError = asyn
|
|
|
546
536
|
throw await deserializeAws_json1_1ServiceFaultResponse(parsedOutput, context);
|
|
547
537
|
default:
|
|
548
538
|
const parsedBody = parsedOutput.body;
|
|
549
|
-
|
|
550
|
-
|
|
551
|
-
|
|
552
|
-
|
|
553
|
-
|
|
554
|
-
$metadata,
|
|
539
|
+
(0, smithy_client_1.throwDefaultError)({
|
|
540
|
+
output,
|
|
541
|
+
parsedBody,
|
|
542
|
+
exceptionCtor: MTurkServiceException_1.MTurkServiceException,
|
|
543
|
+
errorCode,
|
|
555
544
|
});
|
|
556
|
-
throw (0, smithy_client_1.decorateServiceException)(response, parsedBody);
|
|
557
545
|
}
|
|
558
546
|
};
|
|
559
547
|
const deserializeAws_json1_1CreateHITCommand = async (output, context) => {
|
|
@@ -575,7 +563,6 @@ const deserializeAws_json1_1CreateHITCommandError = async (output, context) => {
|
|
|
575
563
|
...output,
|
|
576
564
|
body: await parseBody(output.body, context),
|
|
577
565
|
};
|
|
578
|
-
let response;
|
|
579
566
|
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
580
567
|
switch (errorCode) {
|
|
581
568
|
case "RequestError":
|
|
@@ -586,14 +573,12 @@ const deserializeAws_json1_1CreateHITCommandError = async (output, context) => {
|
|
|
586
573
|
throw await deserializeAws_json1_1ServiceFaultResponse(parsedOutput, context);
|
|
587
574
|
default:
|
|
588
575
|
const parsedBody = parsedOutput.body;
|
|
589
|
-
|
|
590
|
-
|
|
591
|
-
|
|
592
|
-
|
|
593
|
-
|
|
594
|
-
$metadata,
|
|
576
|
+
(0, smithy_client_1.throwDefaultError)({
|
|
577
|
+
output,
|
|
578
|
+
parsedBody,
|
|
579
|
+
exceptionCtor: MTurkServiceException_1.MTurkServiceException,
|
|
580
|
+
errorCode,
|
|
595
581
|
});
|
|
596
|
-
throw (0, smithy_client_1.decorateServiceException)(response, parsedBody);
|
|
597
582
|
}
|
|
598
583
|
};
|
|
599
584
|
const deserializeAws_json1_1CreateHITTypeCommand = async (output, context) => {
|
|
@@ -615,7 +600,6 @@ const deserializeAws_json1_1CreateHITTypeCommandError = async (output, context)
|
|
|
615
600
|
...output,
|
|
616
601
|
body: await parseBody(output.body, context),
|
|
617
602
|
};
|
|
618
|
-
let response;
|
|
619
603
|
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
620
604
|
switch (errorCode) {
|
|
621
605
|
case "RequestError":
|
|
@@ -626,14 +610,12 @@ const deserializeAws_json1_1CreateHITTypeCommandError = async (output, context)
|
|
|
626
610
|
throw await deserializeAws_json1_1ServiceFaultResponse(parsedOutput, context);
|
|
627
611
|
default:
|
|
628
612
|
const parsedBody = parsedOutput.body;
|
|
629
|
-
|
|
630
|
-
|
|
631
|
-
|
|
632
|
-
|
|
633
|
-
|
|
634
|
-
$metadata,
|
|
613
|
+
(0, smithy_client_1.throwDefaultError)({
|
|
614
|
+
output,
|
|
615
|
+
parsedBody,
|
|
616
|
+
exceptionCtor: MTurkServiceException_1.MTurkServiceException,
|
|
617
|
+
errorCode,
|
|
635
618
|
});
|
|
636
|
-
throw (0, smithy_client_1.decorateServiceException)(response, parsedBody);
|
|
637
619
|
}
|
|
638
620
|
};
|
|
639
621
|
const deserializeAws_json1_1CreateHITWithHITTypeCommand = async (output, context) => {
|
|
@@ -655,7 +637,6 @@ const deserializeAws_json1_1CreateHITWithHITTypeCommandError = async (output, co
|
|
|
655
637
|
...output,
|
|
656
638
|
body: await parseBody(output.body, context),
|
|
657
639
|
};
|
|
658
|
-
let response;
|
|
659
640
|
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
660
641
|
switch (errorCode) {
|
|
661
642
|
case "RequestError":
|
|
@@ -666,14 +647,12 @@ const deserializeAws_json1_1CreateHITWithHITTypeCommandError = async (output, co
|
|
|
666
647
|
throw await deserializeAws_json1_1ServiceFaultResponse(parsedOutput, context);
|
|
667
648
|
default:
|
|
668
649
|
const parsedBody = parsedOutput.body;
|
|
669
|
-
|
|
670
|
-
|
|
671
|
-
|
|
672
|
-
|
|
673
|
-
|
|
674
|
-
$metadata,
|
|
650
|
+
(0, smithy_client_1.throwDefaultError)({
|
|
651
|
+
output,
|
|
652
|
+
parsedBody,
|
|
653
|
+
exceptionCtor: MTurkServiceException_1.MTurkServiceException,
|
|
654
|
+
errorCode,
|
|
675
655
|
});
|
|
676
|
-
throw (0, smithy_client_1.decorateServiceException)(response, parsedBody);
|
|
677
656
|
}
|
|
678
657
|
};
|
|
679
658
|
const deserializeAws_json1_1CreateQualificationTypeCommand = async (output, context) => {
|
|
@@ -695,7 +674,6 @@ const deserializeAws_json1_1CreateQualificationTypeCommandError = async (output,
|
|
|
695
674
|
...output,
|
|
696
675
|
body: await parseBody(output.body, context),
|
|
697
676
|
};
|
|
698
|
-
let response;
|
|
699
677
|
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
700
678
|
switch (errorCode) {
|
|
701
679
|
case "RequestError":
|
|
@@ -706,14 +684,12 @@ const deserializeAws_json1_1CreateQualificationTypeCommandError = async (output,
|
|
|
706
684
|
throw await deserializeAws_json1_1ServiceFaultResponse(parsedOutput, context);
|
|
707
685
|
default:
|
|
708
686
|
const parsedBody = parsedOutput.body;
|
|
709
|
-
|
|
710
|
-
|
|
711
|
-
|
|
712
|
-
|
|
713
|
-
|
|
714
|
-
$metadata,
|
|
687
|
+
(0, smithy_client_1.throwDefaultError)({
|
|
688
|
+
output,
|
|
689
|
+
parsedBody,
|
|
690
|
+
exceptionCtor: MTurkServiceException_1.MTurkServiceException,
|
|
691
|
+
errorCode,
|
|
715
692
|
});
|
|
716
|
-
throw (0, smithy_client_1.decorateServiceException)(response, parsedBody);
|
|
717
693
|
}
|
|
718
694
|
};
|
|
719
695
|
const deserializeAws_json1_1CreateWorkerBlockCommand = async (output, context) => {
|
|
@@ -735,7 +711,6 @@ const deserializeAws_json1_1CreateWorkerBlockCommandError = async (output, conte
|
|
|
735
711
|
...output,
|
|
736
712
|
body: await parseBody(output.body, context),
|
|
737
713
|
};
|
|
738
|
-
let response;
|
|
739
714
|
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
740
715
|
switch (errorCode) {
|
|
741
716
|
case "RequestError":
|
|
@@ -746,14 +721,12 @@ const deserializeAws_json1_1CreateWorkerBlockCommandError = async (output, conte
|
|
|
746
721
|
throw await deserializeAws_json1_1ServiceFaultResponse(parsedOutput, context);
|
|
747
722
|
default:
|
|
748
723
|
const parsedBody = parsedOutput.body;
|
|
749
|
-
|
|
750
|
-
|
|
751
|
-
|
|
752
|
-
|
|
753
|
-
|
|
754
|
-
$metadata,
|
|
724
|
+
(0, smithy_client_1.throwDefaultError)({
|
|
725
|
+
output,
|
|
726
|
+
parsedBody,
|
|
727
|
+
exceptionCtor: MTurkServiceException_1.MTurkServiceException,
|
|
728
|
+
errorCode,
|
|
755
729
|
});
|
|
756
|
-
throw (0, smithy_client_1.decorateServiceException)(response, parsedBody);
|
|
757
730
|
}
|
|
758
731
|
};
|
|
759
732
|
const deserializeAws_json1_1DeleteHITCommand = async (output, context) => {
|
|
@@ -775,7 +748,6 @@ const deserializeAws_json1_1DeleteHITCommandError = async (output, context) => {
|
|
|
775
748
|
...output,
|
|
776
749
|
body: await parseBody(output.body, context),
|
|
777
750
|
};
|
|
778
|
-
let response;
|
|
779
751
|
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
780
752
|
switch (errorCode) {
|
|
781
753
|
case "RequestError":
|
|
@@ -786,14 +758,12 @@ const deserializeAws_json1_1DeleteHITCommandError = async (output, context) => {
|
|
|
786
758
|
throw await deserializeAws_json1_1ServiceFaultResponse(parsedOutput, context);
|
|
787
759
|
default:
|
|
788
760
|
const parsedBody = parsedOutput.body;
|
|
789
|
-
|
|
790
|
-
|
|
791
|
-
|
|
792
|
-
|
|
793
|
-
|
|
794
|
-
$metadata,
|
|
761
|
+
(0, smithy_client_1.throwDefaultError)({
|
|
762
|
+
output,
|
|
763
|
+
parsedBody,
|
|
764
|
+
exceptionCtor: MTurkServiceException_1.MTurkServiceException,
|
|
765
|
+
errorCode,
|
|
795
766
|
});
|
|
796
|
-
throw (0, smithy_client_1.decorateServiceException)(response, parsedBody);
|
|
797
767
|
}
|
|
798
768
|
};
|
|
799
769
|
const deserializeAws_json1_1DeleteQualificationTypeCommand = async (output, context) => {
|
|
@@ -815,7 +785,6 @@ const deserializeAws_json1_1DeleteQualificationTypeCommandError = async (output,
|
|
|
815
785
|
...output,
|
|
816
786
|
body: await parseBody(output.body, context),
|
|
817
787
|
};
|
|
818
|
-
let response;
|
|
819
788
|
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
820
789
|
switch (errorCode) {
|
|
821
790
|
case "RequestError":
|
|
@@ -826,14 +795,12 @@ const deserializeAws_json1_1DeleteQualificationTypeCommandError = async (output,
|
|
|
826
795
|
throw await deserializeAws_json1_1ServiceFaultResponse(parsedOutput, context);
|
|
827
796
|
default:
|
|
828
797
|
const parsedBody = parsedOutput.body;
|
|
829
|
-
|
|
830
|
-
|
|
831
|
-
|
|
832
|
-
|
|
833
|
-
|
|
834
|
-
$metadata,
|
|
798
|
+
(0, smithy_client_1.throwDefaultError)({
|
|
799
|
+
output,
|
|
800
|
+
parsedBody,
|
|
801
|
+
exceptionCtor: MTurkServiceException_1.MTurkServiceException,
|
|
802
|
+
errorCode,
|
|
835
803
|
});
|
|
836
|
-
throw (0, smithy_client_1.decorateServiceException)(response, parsedBody);
|
|
837
804
|
}
|
|
838
805
|
};
|
|
839
806
|
const deserializeAws_json1_1DeleteWorkerBlockCommand = async (output, context) => {
|
|
@@ -855,7 +822,6 @@ const deserializeAws_json1_1DeleteWorkerBlockCommandError = async (output, conte
|
|
|
855
822
|
...output,
|
|
856
823
|
body: await parseBody(output.body, context),
|
|
857
824
|
};
|
|
858
|
-
let response;
|
|
859
825
|
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
860
826
|
switch (errorCode) {
|
|
861
827
|
case "RequestError":
|
|
@@ -866,14 +832,12 @@ const deserializeAws_json1_1DeleteWorkerBlockCommandError = async (output, conte
|
|
|
866
832
|
throw await deserializeAws_json1_1ServiceFaultResponse(parsedOutput, context);
|
|
867
833
|
default:
|
|
868
834
|
const parsedBody = parsedOutput.body;
|
|
869
|
-
|
|
870
|
-
|
|
871
|
-
|
|
872
|
-
|
|
873
|
-
|
|
874
|
-
$metadata,
|
|
835
|
+
(0, smithy_client_1.throwDefaultError)({
|
|
836
|
+
output,
|
|
837
|
+
parsedBody,
|
|
838
|
+
exceptionCtor: MTurkServiceException_1.MTurkServiceException,
|
|
839
|
+
errorCode,
|
|
875
840
|
});
|
|
876
|
-
throw (0, smithy_client_1.decorateServiceException)(response, parsedBody);
|
|
877
841
|
}
|
|
878
842
|
};
|
|
879
843
|
const deserializeAws_json1_1DisassociateQualificationFromWorkerCommand = async (output, context) => {
|
|
@@ -895,7 +859,6 @@ const deserializeAws_json1_1DisassociateQualificationFromWorkerCommandError = as
|
|
|
895
859
|
...output,
|
|
896
860
|
body: await parseBody(output.body, context),
|
|
897
861
|
};
|
|
898
|
-
let response;
|
|
899
862
|
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
900
863
|
switch (errorCode) {
|
|
901
864
|
case "RequestError":
|
|
@@ -906,14 +869,12 @@ const deserializeAws_json1_1DisassociateQualificationFromWorkerCommandError = as
|
|
|
906
869
|
throw await deserializeAws_json1_1ServiceFaultResponse(parsedOutput, context);
|
|
907
870
|
default:
|
|
908
871
|
const parsedBody = parsedOutput.body;
|
|
909
|
-
|
|
910
|
-
|
|
911
|
-
|
|
912
|
-
|
|
913
|
-
|
|
914
|
-
$metadata,
|
|
872
|
+
(0, smithy_client_1.throwDefaultError)({
|
|
873
|
+
output,
|
|
874
|
+
parsedBody,
|
|
875
|
+
exceptionCtor: MTurkServiceException_1.MTurkServiceException,
|
|
876
|
+
errorCode,
|
|
915
877
|
});
|
|
916
|
-
throw (0, smithy_client_1.decorateServiceException)(response, parsedBody);
|
|
917
878
|
}
|
|
918
879
|
};
|
|
919
880
|
const deserializeAws_json1_1GetAccountBalanceCommand = async (output, context) => {
|
|
@@ -935,7 +896,6 @@ const deserializeAws_json1_1GetAccountBalanceCommandError = async (output, conte
|
|
|
935
896
|
...output,
|
|
936
897
|
body: await parseBody(output.body, context),
|
|
937
898
|
};
|
|
938
|
-
let response;
|
|
939
899
|
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
940
900
|
switch (errorCode) {
|
|
941
901
|
case "RequestError":
|
|
@@ -946,14 +906,12 @@ const deserializeAws_json1_1GetAccountBalanceCommandError = async (output, conte
|
|
|
946
906
|
throw await deserializeAws_json1_1ServiceFaultResponse(parsedOutput, context);
|
|
947
907
|
default:
|
|
948
908
|
const parsedBody = parsedOutput.body;
|
|
949
|
-
|
|
950
|
-
|
|
951
|
-
|
|
952
|
-
|
|
953
|
-
|
|
954
|
-
$metadata,
|
|
909
|
+
(0, smithy_client_1.throwDefaultError)({
|
|
910
|
+
output,
|
|
911
|
+
parsedBody,
|
|
912
|
+
exceptionCtor: MTurkServiceException_1.MTurkServiceException,
|
|
913
|
+
errorCode,
|
|
955
914
|
});
|
|
956
|
-
throw (0, smithy_client_1.decorateServiceException)(response, parsedBody);
|
|
957
915
|
}
|
|
958
916
|
};
|
|
959
917
|
const deserializeAws_json1_1GetAssignmentCommand = async (output, context) => {
|
|
@@ -975,7 +933,6 @@ const deserializeAws_json1_1GetAssignmentCommandError = async (output, context)
|
|
|
975
933
|
...output,
|
|
976
934
|
body: await parseBody(output.body, context),
|
|
977
935
|
};
|
|
978
|
-
let response;
|
|
979
936
|
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
980
937
|
switch (errorCode) {
|
|
981
938
|
case "RequestError":
|
|
@@ -986,14 +943,12 @@ const deserializeAws_json1_1GetAssignmentCommandError = async (output, context)
|
|
|
986
943
|
throw await deserializeAws_json1_1ServiceFaultResponse(parsedOutput, context);
|
|
987
944
|
default:
|
|
988
945
|
const parsedBody = parsedOutput.body;
|
|
989
|
-
|
|
990
|
-
|
|
991
|
-
|
|
992
|
-
|
|
993
|
-
|
|
994
|
-
$metadata,
|
|
946
|
+
(0, smithy_client_1.throwDefaultError)({
|
|
947
|
+
output,
|
|
948
|
+
parsedBody,
|
|
949
|
+
exceptionCtor: MTurkServiceException_1.MTurkServiceException,
|
|
950
|
+
errorCode,
|
|
995
951
|
});
|
|
996
|
-
throw (0, smithy_client_1.decorateServiceException)(response, parsedBody);
|
|
997
952
|
}
|
|
998
953
|
};
|
|
999
954
|
const deserializeAws_json1_1GetFileUploadURLCommand = async (output, context) => {
|
|
@@ -1015,7 +970,6 @@ const deserializeAws_json1_1GetFileUploadURLCommandError = async (output, contex
|
|
|
1015
970
|
...output,
|
|
1016
971
|
body: await parseBody(output.body, context),
|
|
1017
972
|
};
|
|
1018
|
-
let response;
|
|
1019
973
|
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1020
974
|
switch (errorCode) {
|
|
1021
975
|
case "RequestError":
|
|
@@ -1026,14 +980,12 @@ const deserializeAws_json1_1GetFileUploadURLCommandError = async (output, contex
|
|
|
1026
980
|
throw await deserializeAws_json1_1ServiceFaultResponse(parsedOutput, context);
|
|
1027
981
|
default:
|
|
1028
982
|
const parsedBody = parsedOutput.body;
|
|
1029
|
-
|
|
1030
|
-
|
|
1031
|
-
|
|
1032
|
-
|
|
1033
|
-
|
|
1034
|
-
$metadata,
|
|
983
|
+
(0, smithy_client_1.throwDefaultError)({
|
|
984
|
+
output,
|
|
985
|
+
parsedBody,
|
|
986
|
+
exceptionCtor: MTurkServiceException_1.MTurkServiceException,
|
|
987
|
+
errorCode,
|
|
1035
988
|
});
|
|
1036
|
-
throw (0, smithy_client_1.decorateServiceException)(response, parsedBody);
|
|
1037
989
|
}
|
|
1038
990
|
};
|
|
1039
991
|
const deserializeAws_json1_1GetHITCommand = async (output, context) => {
|
|
@@ -1055,7 +1007,6 @@ const deserializeAws_json1_1GetHITCommandError = async (output, context) => {
|
|
|
1055
1007
|
...output,
|
|
1056
1008
|
body: await parseBody(output.body, context),
|
|
1057
1009
|
};
|
|
1058
|
-
let response;
|
|
1059
1010
|
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1060
1011
|
switch (errorCode) {
|
|
1061
1012
|
case "RequestError":
|
|
@@ -1066,14 +1017,12 @@ const deserializeAws_json1_1GetHITCommandError = async (output, context) => {
|
|
|
1066
1017
|
throw await deserializeAws_json1_1ServiceFaultResponse(parsedOutput, context);
|
|
1067
1018
|
default:
|
|
1068
1019
|
const parsedBody = parsedOutput.body;
|
|
1069
|
-
|
|
1070
|
-
|
|
1071
|
-
|
|
1072
|
-
|
|
1073
|
-
|
|
1074
|
-
$metadata,
|
|
1020
|
+
(0, smithy_client_1.throwDefaultError)({
|
|
1021
|
+
output,
|
|
1022
|
+
parsedBody,
|
|
1023
|
+
exceptionCtor: MTurkServiceException_1.MTurkServiceException,
|
|
1024
|
+
errorCode,
|
|
1075
1025
|
});
|
|
1076
|
-
throw (0, smithy_client_1.decorateServiceException)(response, parsedBody);
|
|
1077
1026
|
}
|
|
1078
1027
|
};
|
|
1079
1028
|
const deserializeAws_json1_1GetQualificationScoreCommand = async (output, context) => {
|
|
@@ -1095,7 +1044,6 @@ const deserializeAws_json1_1GetQualificationScoreCommandError = async (output, c
|
|
|
1095
1044
|
...output,
|
|
1096
1045
|
body: await parseBody(output.body, context),
|
|
1097
1046
|
};
|
|
1098
|
-
let response;
|
|
1099
1047
|
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1100
1048
|
switch (errorCode) {
|
|
1101
1049
|
case "RequestError":
|
|
@@ -1106,14 +1054,12 @@ const deserializeAws_json1_1GetQualificationScoreCommandError = async (output, c
|
|
|
1106
1054
|
throw await deserializeAws_json1_1ServiceFaultResponse(parsedOutput, context);
|
|
1107
1055
|
default:
|
|
1108
1056
|
const parsedBody = parsedOutput.body;
|
|
1109
|
-
|
|
1110
|
-
|
|
1111
|
-
|
|
1112
|
-
|
|
1113
|
-
|
|
1114
|
-
$metadata,
|
|
1057
|
+
(0, smithy_client_1.throwDefaultError)({
|
|
1058
|
+
output,
|
|
1059
|
+
parsedBody,
|
|
1060
|
+
exceptionCtor: MTurkServiceException_1.MTurkServiceException,
|
|
1061
|
+
errorCode,
|
|
1115
1062
|
});
|
|
1116
|
-
throw (0, smithy_client_1.decorateServiceException)(response, parsedBody);
|
|
1117
1063
|
}
|
|
1118
1064
|
};
|
|
1119
1065
|
const deserializeAws_json1_1GetQualificationTypeCommand = async (output, context) => {
|
|
@@ -1135,7 +1081,6 @@ const deserializeAws_json1_1GetQualificationTypeCommandError = async (output, co
|
|
|
1135
1081
|
...output,
|
|
1136
1082
|
body: await parseBody(output.body, context),
|
|
1137
1083
|
};
|
|
1138
|
-
let response;
|
|
1139
1084
|
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1140
1085
|
switch (errorCode) {
|
|
1141
1086
|
case "RequestError":
|
|
@@ -1146,14 +1091,12 @@ const deserializeAws_json1_1GetQualificationTypeCommandError = async (output, co
|
|
|
1146
1091
|
throw await deserializeAws_json1_1ServiceFaultResponse(parsedOutput, context);
|
|
1147
1092
|
default:
|
|
1148
1093
|
const parsedBody = parsedOutput.body;
|
|
1149
|
-
|
|
1150
|
-
|
|
1151
|
-
|
|
1152
|
-
|
|
1153
|
-
|
|
1154
|
-
$metadata,
|
|
1094
|
+
(0, smithy_client_1.throwDefaultError)({
|
|
1095
|
+
output,
|
|
1096
|
+
parsedBody,
|
|
1097
|
+
exceptionCtor: MTurkServiceException_1.MTurkServiceException,
|
|
1098
|
+
errorCode,
|
|
1155
1099
|
});
|
|
1156
|
-
throw (0, smithy_client_1.decorateServiceException)(response, parsedBody);
|
|
1157
1100
|
}
|
|
1158
1101
|
};
|
|
1159
1102
|
const deserializeAws_json1_1ListAssignmentsForHITCommand = async (output, context) => {
|
|
@@ -1175,7 +1118,6 @@ const deserializeAws_json1_1ListAssignmentsForHITCommandError = async (output, c
|
|
|
1175
1118
|
...output,
|
|
1176
1119
|
body: await parseBody(output.body, context),
|
|
1177
1120
|
};
|
|
1178
|
-
let response;
|
|
1179
1121
|
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1180
1122
|
switch (errorCode) {
|
|
1181
1123
|
case "RequestError":
|
|
@@ -1186,14 +1128,12 @@ const deserializeAws_json1_1ListAssignmentsForHITCommandError = async (output, c
|
|
|
1186
1128
|
throw await deserializeAws_json1_1ServiceFaultResponse(parsedOutput, context);
|
|
1187
1129
|
default:
|
|
1188
1130
|
const parsedBody = parsedOutput.body;
|
|
1189
|
-
|
|
1190
|
-
|
|
1191
|
-
|
|
1192
|
-
|
|
1193
|
-
|
|
1194
|
-
$metadata,
|
|
1131
|
+
(0, smithy_client_1.throwDefaultError)({
|
|
1132
|
+
output,
|
|
1133
|
+
parsedBody,
|
|
1134
|
+
exceptionCtor: MTurkServiceException_1.MTurkServiceException,
|
|
1135
|
+
errorCode,
|
|
1195
1136
|
});
|
|
1196
|
-
throw (0, smithy_client_1.decorateServiceException)(response, parsedBody);
|
|
1197
1137
|
}
|
|
1198
1138
|
};
|
|
1199
1139
|
const deserializeAws_json1_1ListBonusPaymentsCommand = async (output, context) => {
|
|
@@ -1215,7 +1155,6 @@ const deserializeAws_json1_1ListBonusPaymentsCommandError = async (output, conte
|
|
|
1215
1155
|
...output,
|
|
1216
1156
|
body: await parseBody(output.body, context),
|
|
1217
1157
|
};
|
|
1218
|
-
let response;
|
|
1219
1158
|
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1220
1159
|
switch (errorCode) {
|
|
1221
1160
|
case "RequestError":
|
|
@@ -1226,14 +1165,12 @@ const deserializeAws_json1_1ListBonusPaymentsCommandError = async (output, conte
|
|
|
1226
1165
|
throw await deserializeAws_json1_1ServiceFaultResponse(parsedOutput, context);
|
|
1227
1166
|
default:
|
|
1228
1167
|
const parsedBody = parsedOutput.body;
|
|
1229
|
-
|
|
1230
|
-
|
|
1231
|
-
|
|
1232
|
-
|
|
1233
|
-
|
|
1234
|
-
$metadata,
|
|
1168
|
+
(0, smithy_client_1.throwDefaultError)({
|
|
1169
|
+
output,
|
|
1170
|
+
parsedBody,
|
|
1171
|
+
exceptionCtor: MTurkServiceException_1.MTurkServiceException,
|
|
1172
|
+
errorCode,
|
|
1235
1173
|
});
|
|
1236
|
-
throw (0, smithy_client_1.decorateServiceException)(response, parsedBody);
|
|
1237
1174
|
}
|
|
1238
1175
|
};
|
|
1239
1176
|
const deserializeAws_json1_1ListHITsCommand = async (output, context) => {
|
|
@@ -1255,7 +1192,6 @@ const deserializeAws_json1_1ListHITsCommandError = async (output, context) => {
|
|
|
1255
1192
|
...output,
|
|
1256
1193
|
body: await parseBody(output.body, context),
|
|
1257
1194
|
};
|
|
1258
|
-
let response;
|
|
1259
1195
|
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1260
1196
|
switch (errorCode) {
|
|
1261
1197
|
case "RequestError":
|
|
@@ -1266,14 +1202,12 @@ const deserializeAws_json1_1ListHITsCommandError = async (output, context) => {
|
|
|
1266
1202
|
throw await deserializeAws_json1_1ServiceFaultResponse(parsedOutput, context);
|
|
1267
1203
|
default:
|
|
1268
1204
|
const parsedBody = parsedOutput.body;
|
|
1269
|
-
|
|
1270
|
-
|
|
1271
|
-
|
|
1272
|
-
|
|
1273
|
-
|
|
1274
|
-
$metadata,
|
|
1205
|
+
(0, smithy_client_1.throwDefaultError)({
|
|
1206
|
+
output,
|
|
1207
|
+
parsedBody,
|
|
1208
|
+
exceptionCtor: MTurkServiceException_1.MTurkServiceException,
|
|
1209
|
+
errorCode,
|
|
1275
1210
|
});
|
|
1276
|
-
throw (0, smithy_client_1.decorateServiceException)(response, parsedBody);
|
|
1277
1211
|
}
|
|
1278
1212
|
};
|
|
1279
1213
|
const deserializeAws_json1_1ListHITsForQualificationTypeCommand = async (output, context) => {
|
|
@@ -1295,7 +1229,6 @@ const deserializeAws_json1_1ListHITsForQualificationTypeCommandError = async (ou
|
|
|
1295
1229
|
...output,
|
|
1296
1230
|
body: await parseBody(output.body, context),
|
|
1297
1231
|
};
|
|
1298
|
-
let response;
|
|
1299
1232
|
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1300
1233
|
switch (errorCode) {
|
|
1301
1234
|
case "RequestError":
|
|
@@ -1306,14 +1239,12 @@ const deserializeAws_json1_1ListHITsForQualificationTypeCommandError = async (ou
|
|
|
1306
1239
|
throw await deserializeAws_json1_1ServiceFaultResponse(parsedOutput, context);
|
|
1307
1240
|
default:
|
|
1308
1241
|
const parsedBody = parsedOutput.body;
|
|
1309
|
-
|
|
1310
|
-
|
|
1311
|
-
|
|
1312
|
-
|
|
1313
|
-
|
|
1314
|
-
$metadata,
|
|
1242
|
+
(0, smithy_client_1.throwDefaultError)({
|
|
1243
|
+
output,
|
|
1244
|
+
parsedBody,
|
|
1245
|
+
exceptionCtor: MTurkServiceException_1.MTurkServiceException,
|
|
1246
|
+
errorCode,
|
|
1315
1247
|
});
|
|
1316
|
-
throw (0, smithy_client_1.decorateServiceException)(response, parsedBody);
|
|
1317
1248
|
}
|
|
1318
1249
|
};
|
|
1319
1250
|
const deserializeAws_json1_1ListQualificationRequestsCommand = async (output, context) => {
|
|
@@ -1335,7 +1266,6 @@ const deserializeAws_json1_1ListQualificationRequestsCommandError = async (outpu
|
|
|
1335
1266
|
...output,
|
|
1336
1267
|
body: await parseBody(output.body, context),
|
|
1337
1268
|
};
|
|
1338
|
-
let response;
|
|
1339
1269
|
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1340
1270
|
switch (errorCode) {
|
|
1341
1271
|
case "RequestError":
|
|
@@ -1346,14 +1276,12 @@ const deserializeAws_json1_1ListQualificationRequestsCommandError = async (outpu
|
|
|
1346
1276
|
throw await deserializeAws_json1_1ServiceFaultResponse(parsedOutput, context);
|
|
1347
1277
|
default:
|
|
1348
1278
|
const parsedBody = parsedOutput.body;
|
|
1349
|
-
|
|
1350
|
-
|
|
1351
|
-
|
|
1352
|
-
|
|
1353
|
-
|
|
1354
|
-
$metadata,
|
|
1279
|
+
(0, smithy_client_1.throwDefaultError)({
|
|
1280
|
+
output,
|
|
1281
|
+
parsedBody,
|
|
1282
|
+
exceptionCtor: MTurkServiceException_1.MTurkServiceException,
|
|
1283
|
+
errorCode,
|
|
1355
1284
|
});
|
|
1356
|
-
throw (0, smithy_client_1.decorateServiceException)(response, parsedBody);
|
|
1357
1285
|
}
|
|
1358
1286
|
};
|
|
1359
1287
|
const deserializeAws_json1_1ListQualificationTypesCommand = async (output, context) => {
|
|
@@ -1375,7 +1303,6 @@ const deserializeAws_json1_1ListQualificationTypesCommandError = async (output,
|
|
|
1375
1303
|
...output,
|
|
1376
1304
|
body: await parseBody(output.body, context),
|
|
1377
1305
|
};
|
|
1378
|
-
let response;
|
|
1379
1306
|
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1380
1307
|
switch (errorCode) {
|
|
1381
1308
|
case "RequestError":
|
|
@@ -1386,14 +1313,12 @@ const deserializeAws_json1_1ListQualificationTypesCommandError = async (output,
|
|
|
1386
1313
|
throw await deserializeAws_json1_1ServiceFaultResponse(parsedOutput, context);
|
|
1387
1314
|
default:
|
|
1388
1315
|
const parsedBody = parsedOutput.body;
|
|
1389
|
-
|
|
1390
|
-
|
|
1391
|
-
|
|
1392
|
-
|
|
1393
|
-
|
|
1394
|
-
$metadata,
|
|
1316
|
+
(0, smithy_client_1.throwDefaultError)({
|
|
1317
|
+
output,
|
|
1318
|
+
parsedBody,
|
|
1319
|
+
exceptionCtor: MTurkServiceException_1.MTurkServiceException,
|
|
1320
|
+
errorCode,
|
|
1395
1321
|
});
|
|
1396
|
-
throw (0, smithy_client_1.decorateServiceException)(response, parsedBody);
|
|
1397
1322
|
}
|
|
1398
1323
|
};
|
|
1399
1324
|
const deserializeAws_json1_1ListReviewableHITsCommand = async (output, context) => {
|
|
@@ -1415,7 +1340,6 @@ const deserializeAws_json1_1ListReviewableHITsCommandError = async (output, cont
|
|
|
1415
1340
|
...output,
|
|
1416
1341
|
body: await parseBody(output.body, context),
|
|
1417
1342
|
};
|
|
1418
|
-
let response;
|
|
1419
1343
|
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1420
1344
|
switch (errorCode) {
|
|
1421
1345
|
case "RequestError":
|
|
@@ -1426,14 +1350,12 @@ const deserializeAws_json1_1ListReviewableHITsCommandError = async (output, cont
|
|
|
1426
1350
|
throw await deserializeAws_json1_1ServiceFaultResponse(parsedOutput, context);
|
|
1427
1351
|
default:
|
|
1428
1352
|
const parsedBody = parsedOutput.body;
|
|
1429
|
-
|
|
1430
|
-
|
|
1431
|
-
|
|
1432
|
-
|
|
1433
|
-
|
|
1434
|
-
$metadata,
|
|
1353
|
+
(0, smithy_client_1.throwDefaultError)({
|
|
1354
|
+
output,
|
|
1355
|
+
parsedBody,
|
|
1356
|
+
exceptionCtor: MTurkServiceException_1.MTurkServiceException,
|
|
1357
|
+
errorCode,
|
|
1435
1358
|
});
|
|
1436
|
-
throw (0, smithy_client_1.decorateServiceException)(response, parsedBody);
|
|
1437
1359
|
}
|
|
1438
1360
|
};
|
|
1439
1361
|
const deserializeAws_json1_1ListReviewPolicyResultsForHITCommand = async (output, context) => {
|
|
@@ -1455,7 +1377,6 @@ const deserializeAws_json1_1ListReviewPolicyResultsForHITCommandError = async (o
|
|
|
1455
1377
|
...output,
|
|
1456
1378
|
body: await parseBody(output.body, context),
|
|
1457
1379
|
};
|
|
1458
|
-
let response;
|
|
1459
1380
|
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1460
1381
|
switch (errorCode) {
|
|
1461
1382
|
case "RequestError":
|
|
@@ -1466,14 +1387,12 @@ const deserializeAws_json1_1ListReviewPolicyResultsForHITCommandError = async (o
|
|
|
1466
1387
|
throw await deserializeAws_json1_1ServiceFaultResponse(parsedOutput, context);
|
|
1467
1388
|
default:
|
|
1468
1389
|
const parsedBody = parsedOutput.body;
|
|
1469
|
-
|
|
1470
|
-
|
|
1471
|
-
|
|
1472
|
-
|
|
1473
|
-
|
|
1474
|
-
$metadata,
|
|
1390
|
+
(0, smithy_client_1.throwDefaultError)({
|
|
1391
|
+
output,
|
|
1392
|
+
parsedBody,
|
|
1393
|
+
exceptionCtor: MTurkServiceException_1.MTurkServiceException,
|
|
1394
|
+
errorCode,
|
|
1475
1395
|
});
|
|
1476
|
-
throw (0, smithy_client_1.decorateServiceException)(response, parsedBody);
|
|
1477
1396
|
}
|
|
1478
1397
|
};
|
|
1479
1398
|
const deserializeAws_json1_1ListWorkerBlocksCommand = async (output, context) => {
|
|
@@ -1495,7 +1414,6 @@ const deserializeAws_json1_1ListWorkerBlocksCommandError = async (output, contex
|
|
|
1495
1414
|
...output,
|
|
1496
1415
|
body: await parseBody(output.body, context),
|
|
1497
1416
|
};
|
|
1498
|
-
let response;
|
|
1499
1417
|
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1500
1418
|
switch (errorCode) {
|
|
1501
1419
|
case "RequestError":
|
|
@@ -1506,14 +1424,12 @@ const deserializeAws_json1_1ListWorkerBlocksCommandError = async (output, contex
|
|
|
1506
1424
|
throw await deserializeAws_json1_1ServiceFaultResponse(parsedOutput, context);
|
|
1507
1425
|
default:
|
|
1508
1426
|
const parsedBody = parsedOutput.body;
|
|
1509
|
-
|
|
1510
|
-
|
|
1511
|
-
|
|
1512
|
-
|
|
1513
|
-
|
|
1514
|
-
$metadata,
|
|
1427
|
+
(0, smithy_client_1.throwDefaultError)({
|
|
1428
|
+
output,
|
|
1429
|
+
parsedBody,
|
|
1430
|
+
exceptionCtor: MTurkServiceException_1.MTurkServiceException,
|
|
1431
|
+
errorCode,
|
|
1515
1432
|
});
|
|
1516
|
-
throw (0, smithy_client_1.decorateServiceException)(response, parsedBody);
|
|
1517
1433
|
}
|
|
1518
1434
|
};
|
|
1519
1435
|
const deserializeAws_json1_1ListWorkersWithQualificationTypeCommand = async (output, context) => {
|
|
@@ -1535,7 +1451,6 @@ const deserializeAws_json1_1ListWorkersWithQualificationTypeCommandError = async
|
|
|
1535
1451
|
...output,
|
|
1536
1452
|
body: await parseBody(output.body, context),
|
|
1537
1453
|
};
|
|
1538
|
-
let response;
|
|
1539
1454
|
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1540
1455
|
switch (errorCode) {
|
|
1541
1456
|
case "RequestError":
|
|
@@ -1546,14 +1461,12 @@ const deserializeAws_json1_1ListWorkersWithQualificationTypeCommandError = async
|
|
|
1546
1461
|
throw await deserializeAws_json1_1ServiceFaultResponse(parsedOutput, context);
|
|
1547
1462
|
default:
|
|
1548
1463
|
const parsedBody = parsedOutput.body;
|
|
1549
|
-
|
|
1550
|
-
|
|
1551
|
-
|
|
1552
|
-
|
|
1553
|
-
|
|
1554
|
-
$metadata,
|
|
1464
|
+
(0, smithy_client_1.throwDefaultError)({
|
|
1465
|
+
output,
|
|
1466
|
+
parsedBody,
|
|
1467
|
+
exceptionCtor: MTurkServiceException_1.MTurkServiceException,
|
|
1468
|
+
errorCode,
|
|
1555
1469
|
});
|
|
1556
|
-
throw (0, smithy_client_1.decorateServiceException)(response, parsedBody);
|
|
1557
1470
|
}
|
|
1558
1471
|
};
|
|
1559
1472
|
const deserializeAws_json1_1NotifyWorkersCommand = async (output, context) => {
|
|
@@ -1575,7 +1488,6 @@ const deserializeAws_json1_1NotifyWorkersCommandError = async (output, context)
|
|
|
1575
1488
|
...output,
|
|
1576
1489
|
body: await parseBody(output.body, context),
|
|
1577
1490
|
};
|
|
1578
|
-
let response;
|
|
1579
1491
|
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1580
1492
|
switch (errorCode) {
|
|
1581
1493
|
case "RequestError":
|
|
@@ -1586,14 +1498,12 @@ const deserializeAws_json1_1NotifyWorkersCommandError = async (output, context)
|
|
|
1586
1498
|
throw await deserializeAws_json1_1ServiceFaultResponse(parsedOutput, context);
|
|
1587
1499
|
default:
|
|
1588
1500
|
const parsedBody = parsedOutput.body;
|
|
1589
|
-
|
|
1590
|
-
|
|
1591
|
-
|
|
1592
|
-
|
|
1593
|
-
|
|
1594
|
-
$metadata,
|
|
1501
|
+
(0, smithy_client_1.throwDefaultError)({
|
|
1502
|
+
output,
|
|
1503
|
+
parsedBody,
|
|
1504
|
+
exceptionCtor: MTurkServiceException_1.MTurkServiceException,
|
|
1505
|
+
errorCode,
|
|
1595
1506
|
});
|
|
1596
|
-
throw (0, smithy_client_1.decorateServiceException)(response, parsedBody);
|
|
1597
1507
|
}
|
|
1598
1508
|
};
|
|
1599
1509
|
const deserializeAws_json1_1RejectAssignmentCommand = async (output, context) => {
|
|
@@ -1615,7 +1525,6 @@ const deserializeAws_json1_1RejectAssignmentCommandError = async (output, contex
|
|
|
1615
1525
|
...output,
|
|
1616
1526
|
body: await parseBody(output.body, context),
|
|
1617
1527
|
};
|
|
1618
|
-
let response;
|
|
1619
1528
|
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1620
1529
|
switch (errorCode) {
|
|
1621
1530
|
case "RequestError":
|
|
@@ -1626,14 +1535,12 @@ const deserializeAws_json1_1RejectAssignmentCommandError = async (output, contex
|
|
|
1626
1535
|
throw await deserializeAws_json1_1ServiceFaultResponse(parsedOutput, context);
|
|
1627
1536
|
default:
|
|
1628
1537
|
const parsedBody = parsedOutput.body;
|
|
1629
|
-
|
|
1630
|
-
|
|
1631
|
-
|
|
1632
|
-
|
|
1633
|
-
|
|
1634
|
-
$metadata,
|
|
1538
|
+
(0, smithy_client_1.throwDefaultError)({
|
|
1539
|
+
output,
|
|
1540
|
+
parsedBody,
|
|
1541
|
+
exceptionCtor: MTurkServiceException_1.MTurkServiceException,
|
|
1542
|
+
errorCode,
|
|
1635
1543
|
});
|
|
1636
|
-
throw (0, smithy_client_1.decorateServiceException)(response, parsedBody);
|
|
1637
1544
|
}
|
|
1638
1545
|
};
|
|
1639
1546
|
const deserializeAws_json1_1RejectQualificationRequestCommand = async (output, context) => {
|
|
@@ -1655,7 +1562,6 @@ const deserializeAws_json1_1RejectQualificationRequestCommandError = async (outp
|
|
|
1655
1562
|
...output,
|
|
1656
1563
|
body: await parseBody(output.body, context),
|
|
1657
1564
|
};
|
|
1658
|
-
let response;
|
|
1659
1565
|
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1660
1566
|
switch (errorCode) {
|
|
1661
1567
|
case "RequestError":
|
|
@@ -1666,14 +1572,12 @@ const deserializeAws_json1_1RejectQualificationRequestCommandError = async (outp
|
|
|
1666
1572
|
throw await deserializeAws_json1_1ServiceFaultResponse(parsedOutput, context);
|
|
1667
1573
|
default:
|
|
1668
1574
|
const parsedBody = parsedOutput.body;
|
|
1669
|
-
|
|
1670
|
-
|
|
1671
|
-
|
|
1672
|
-
|
|
1673
|
-
|
|
1674
|
-
$metadata,
|
|
1575
|
+
(0, smithy_client_1.throwDefaultError)({
|
|
1576
|
+
output,
|
|
1577
|
+
parsedBody,
|
|
1578
|
+
exceptionCtor: MTurkServiceException_1.MTurkServiceException,
|
|
1579
|
+
errorCode,
|
|
1675
1580
|
});
|
|
1676
|
-
throw (0, smithy_client_1.decorateServiceException)(response, parsedBody);
|
|
1677
1581
|
}
|
|
1678
1582
|
};
|
|
1679
1583
|
const deserializeAws_json1_1SendBonusCommand = async (output, context) => {
|
|
@@ -1695,7 +1599,6 @@ const deserializeAws_json1_1SendBonusCommandError = async (output, context) => {
|
|
|
1695
1599
|
...output,
|
|
1696
1600
|
body: await parseBody(output.body, context),
|
|
1697
1601
|
};
|
|
1698
|
-
let response;
|
|
1699
1602
|
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1700
1603
|
switch (errorCode) {
|
|
1701
1604
|
case "RequestError":
|
|
@@ -1706,14 +1609,12 @@ const deserializeAws_json1_1SendBonusCommandError = async (output, context) => {
|
|
|
1706
1609
|
throw await deserializeAws_json1_1ServiceFaultResponse(parsedOutput, context);
|
|
1707
1610
|
default:
|
|
1708
1611
|
const parsedBody = parsedOutput.body;
|
|
1709
|
-
|
|
1710
|
-
|
|
1711
|
-
|
|
1712
|
-
|
|
1713
|
-
|
|
1714
|
-
$metadata,
|
|
1612
|
+
(0, smithy_client_1.throwDefaultError)({
|
|
1613
|
+
output,
|
|
1614
|
+
parsedBody,
|
|
1615
|
+
exceptionCtor: MTurkServiceException_1.MTurkServiceException,
|
|
1616
|
+
errorCode,
|
|
1715
1617
|
});
|
|
1716
|
-
throw (0, smithy_client_1.decorateServiceException)(response, parsedBody);
|
|
1717
1618
|
}
|
|
1718
1619
|
};
|
|
1719
1620
|
const deserializeAws_json1_1SendTestEventNotificationCommand = async (output, context) => {
|
|
@@ -1735,7 +1636,6 @@ const deserializeAws_json1_1SendTestEventNotificationCommandError = async (outpu
|
|
|
1735
1636
|
...output,
|
|
1736
1637
|
body: await parseBody(output.body, context),
|
|
1737
1638
|
};
|
|
1738
|
-
let response;
|
|
1739
1639
|
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1740
1640
|
switch (errorCode) {
|
|
1741
1641
|
case "RequestError":
|
|
@@ -1746,14 +1646,12 @@ const deserializeAws_json1_1SendTestEventNotificationCommandError = async (outpu
|
|
|
1746
1646
|
throw await deserializeAws_json1_1ServiceFaultResponse(parsedOutput, context);
|
|
1747
1647
|
default:
|
|
1748
1648
|
const parsedBody = parsedOutput.body;
|
|
1749
|
-
|
|
1750
|
-
|
|
1751
|
-
|
|
1752
|
-
|
|
1753
|
-
|
|
1754
|
-
$metadata,
|
|
1649
|
+
(0, smithy_client_1.throwDefaultError)({
|
|
1650
|
+
output,
|
|
1651
|
+
parsedBody,
|
|
1652
|
+
exceptionCtor: MTurkServiceException_1.MTurkServiceException,
|
|
1653
|
+
errorCode,
|
|
1755
1654
|
});
|
|
1756
|
-
throw (0, smithy_client_1.decorateServiceException)(response, parsedBody);
|
|
1757
1655
|
}
|
|
1758
1656
|
};
|
|
1759
1657
|
const deserializeAws_json1_1UpdateExpirationForHITCommand = async (output, context) => {
|
|
@@ -1775,7 +1673,6 @@ const deserializeAws_json1_1UpdateExpirationForHITCommandError = async (output,
|
|
|
1775
1673
|
...output,
|
|
1776
1674
|
body: await parseBody(output.body, context),
|
|
1777
1675
|
};
|
|
1778
|
-
let response;
|
|
1779
1676
|
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1780
1677
|
switch (errorCode) {
|
|
1781
1678
|
case "RequestError":
|
|
@@ -1786,14 +1683,12 @@ const deserializeAws_json1_1UpdateExpirationForHITCommandError = async (output,
|
|
|
1786
1683
|
throw await deserializeAws_json1_1ServiceFaultResponse(parsedOutput, context);
|
|
1787
1684
|
default:
|
|
1788
1685
|
const parsedBody = parsedOutput.body;
|
|
1789
|
-
|
|
1790
|
-
|
|
1791
|
-
|
|
1792
|
-
|
|
1793
|
-
|
|
1794
|
-
$metadata,
|
|
1686
|
+
(0, smithy_client_1.throwDefaultError)({
|
|
1687
|
+
output,
|
|
1688
|
+
parsedBody,
|
|
1689
|
+
exceptionCtor: MTurkServiceException_1.MTurkServiceException,
|
|
1690
|
+
errorCode,
|
|
1795
1691
|
});
|
|
1796
|
-
throw (0, smithy_client_1.decorateServiceException)(response, parsedBody);
|
|
1797
1692
|
}
|
|
1798
1693
|
};
|
|
1799
1694
|
const deserializeAws_json1_1UpdateHITReviewStatusCommand = async (output, context) => {
|
|
@@ -1815,7 +1710,6 @@ const deserializeAws_json1_1UpdateHITReviewStatusCommandError = async (output, c
|
|
|
1815
1710
|
...output,
|
|
1816
1711
|
body: await parseBody(output.body, context),
|
|
1817
1712
|
};
|
|
1818
|
-
let response;
|
|
1819
1713
|
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1820
1714
|
switch (errorCode) {
|
|
1821
1715
|
case "RequestError":
|
|
@@ -1826,14 +1720,12 @@ const deserializeAws_json1_1UpdateHITReviewStatusCommandError = async (output, c
|
|
|
1826
1720
|
throw await deserializeAws_json1_1ServiceFaultResponse(parsedOutput, context);
|
|
1827
1721
|
default:
|
|
1828
1722
|
const parsedBody = parsedOutput.body;
|
|
1829
|
-
|
|
1830
|
-
|
|
1831
|
-
|
|
1832
|
-
|
|
1833
|
-
|
|
1834
|
-
$metadata,
|
|
1723
|
+
(0, smithy_client_1.throwDefaultError)({
|
|
1724
|
+
output,
|
|
1725
|
+
parsedBody,
|
|
1726
|
+
exceptionCtor: MTurkServiceException_1.MTurkServiceException,
|
|
1727
|
+
errorCode,
|
|
1835
1728
|
});
|
|
1836
|
-
throw (0, smithy_client_1.decorateServiceException)(response, parsedBody);
|
|
1837
1729
|
}
|
|
1838
1730
|
};
|
|
1839
1731
|
const deserializeAws_json1_1UpdateHITTypeOfHITCommand = async (output, context) => {
|
|
@@ -1855,7 +1747,6 @@ const deserializeAws_json1_1UpdateHITTypeOfHITCommandError = async (output, cont
|
|
|
1855
1747
|
...output,
|
|
1856
1748
|
body: await parseBody(output.body, context),
|
|
1857
1749
|
};
|
|
1858
|
-
let response;
|
|
1859
1750
|
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1860
1751
|
switch (errorCode) {
|
|
1861
1752
|
case "RequestError":
|
|
@@ -1866,14 +1757,12 @@ const deserializeAws_json1_1UpdateHITTypeOfHITCommandError = async (output, cont
|
|
|
1866
1757
|
throw await deserializeAws_json1_1ServiceFaultResponse(parsedOutput, context);
|
|
1867
1758
|
default:
|
|
1868
1759
|
const parsedBody = parsedOutput.body;
|
|
1869
|
-
|
|
1870
|
-
|
|
1871
|
-
|
|
1872
|
-
|
|
1873
|
-
|
|
1874
|
-
$metadata,
|
|
1760
|
+
(0, smithy_client_1.throwDefaultError)({
|
|
1761
|
+
output,
|
|
1762
|
+
parsedBody,
|
|
1763
|
+
exceptionCtor: MTurkServiceException_1.MTurkServiceException,
|
|
1764
|
+
errorCode,
|
|
1875
1765
|
});
|
|
1876
|
-
throw (0, smithy_client_1.decorateServiceException)(response, parsedBody);
|
|
1877
1766
|
}
|
|
1878
1767
|
};
|
|
1879
1768
|
const deserializeAws_json1_1UpdateNotificationSettingsCommand = async (output, context) => {
|
|
@@ -1895,7 +1784,6 @@ const deserializeAws_json1_1UpdateNotificationSettingsCommandError = async (outp
|
|
|
1895
1784
|
...output,
|
|
1896
1785
|
body: await parseBody(output.body, context),
|
|
1897
1786
|
};
|
|
1898
|
-
let response;
|
|
1899
1787
|
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1900
1788
|
switch (errorCode) {
|
|
1901
1789
|
case "RequestError":
|
|
@@ -1906,14 +1794,12 @@ const deserializeAws_json1_1UpdateNotificationSettingsCommandError = async (outp
|
|
|
1906
1794
|
throw await deserializeAws_json1_1ServiceFaultResponse(parsedOutput, context);
|
|
1907
1795
|
default:
|
|
1908
1796
|
const parsedBody = parsedOutput.body;
|
|
1909
|
-
|
|
1910
|
-
|
|
1911
|
-
|
|
1912
|
-
|
|
1913
|
-
|
|
1914
|
-
$metadata,
|
|
1797
|
+
(0, smithy_client_1.throwDefaultError)({
|
|
1798
|
+
output,
|
|
1799
|
+
parsedBody,
|
|
1800
|
+
exceptionCtor: MTurkServiceException_1.MTurkServiceException,
|
|
1801
|
+
errorCode,
|
|
1915
1802
|
});
|
|
1916
|
-
throw (0, smithy_client_1.decorateServiceException)(response, parsedBody);
|
|
1917
1803
|
}
|
|
1918
1804
|
};
|
|
1919
1805
|
const deserializeAws_json1_1UpdateQualificationTypeCommand = async (output, context) => {
|
|
@@ -1935,7 +1821,6 @@ const deserializeAws_json1_1UpdateQualificationTypeCommandError = async (output,
|
|
|
1935
1821
|
...output,
|
|
1936
1822
|
body: await parseBody(output.body, context),
|
|
1937
1823
|
};
|
|
1938
|
-
let response;
|
|
1939
1824
|
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1940
1825
|
switch (errorCode) {
|
|
1941
1826
|
case "RequestError":
|
|
@@ -1946,14 +1831,12 @@ const deserializeAws_json1_1UpdateQualificationTypeCommandError = async (output,
|
|
|
1946
1831
|
throw await deserializeAws_json1_1ServiceFaultResponse(parsedOutput, context);
|
|
1947
1832
|
default:
|
|
1948
1833
|
const parsedBody = parsedOutput.body;
|
|
1949
|
-
|
|
1950
|
-
|
|
1951
|
-
|
|
1952
|
-
|
|
1953
|
-
|
|
1954
|
-
$metadata,
|
|
1834
|
+
(0, smithy_client_1.throwDefaultError)({
|
|
1835
|
+
output,
|
|
1836
|
+
parsedBody,
|
|
1837
|
+
exceptionCtor: MTurkServiceException_1.MTurkServiceException,
|
|
1838
|
+
errorCode,
|
|
1955
1839
|
});
|
|
1956
|
-
throw (0, smithy_client_1.decorateServiceException)(response, parsedBody);
|
|
1957
1840
|
}
|
|
1958
1841
|
};
|
|
1959
1842
|
const deserializeAws_json1_1RequestErrorResponse = async (parsedOutput, context) => {
|
|
@@ -1991,9 +1874,6 @@ const serializeAws_json1_1AssignmentStatusList = (input, context) => {
|
|
|
1991
1874
|
return input
|
|
1992
1875
|
.filter((e) => e != null)
|
|
1993
1876
|
.map((entry) => {
|
|
1994
|
-
if (entry === null) {
|
|
1995
|
-
return null;
|
|
1996
|
-
}
|
|
1997
1877
|
return entry;
|
|
1998
1878
|
});
|
|
1999
1879
|
};
|
|
@@ -2103,9 +1983,6 @@ const serializeAws_json1_1CustomerIdList = (input, context) => {
|
|
|
2103
1983
|
return input
|
|
2104
1984
|
.filter((e) => e != null)
|
|
2105
1985
|
.map((entry) => {
|
|
2106
|
-
if (entry === null) {
|
|
2107
|
-
return null;
|
|
2108
|
-
}
|
|
2109
1986
|
return entry;
|
|
2110
1987
|
});
|
|
2111
1988
|
};
|
|
@@ -2136,9 +2013,6 @@ const serializeAws_json1_1EventTypeList = (input, context) => {
|
|
|
2136
2013
|
return input
|
|
2137
2014
|
.filter((e) => e != null)
|
|
2138
2015
|
.map((entry) => {
|
|
2139
|
-
if (entry === null) {
|
|
2140
|
-
return null;
|
|
2141
|
-
}
|
|
2142
2016
|
return entry;
|
|
2143
2017
|
});
|
|
2144
2018
|
};
|
|
@@ -2182,9 +2056,6 @@ const serializeAws_json1_1HITLayoutParameterList = (input, context) => {
|
|
|
2182
2056
|
return input
|
|
2183
2057
|
.filter((e) => e != null)
|
|
2184
2058
|
.map((entry) => {
|
|
2185
|
-
if (entry === null) {
|
|
2186
|
-
return null;
|
|
2187
|
-
}
|
|
2188
2059
|
return serializeAws_json1_1HITLayoutParameter(entry, context);
|
|
2189
2060
|
});
|
|
2190
2061
|
};
|
|
@@ -2192,9 +2063,6 @@ const serializeAws_json1_1IntegerList = (input, context) => {
|
|
|
2192
2063
|
return input
|
|
2193
2064
|
.filter((e) => e != null)
|
|
2194
2065
|
.map((entry) => {
|
|
2195
|
-
if (entry === null) {
|
|
2196
|
-
return null;
|
|
2197
|
-
}
|
|
2198
2066
|
return entry;
|
|
2199
2067
|
});
|
|
2200
2068
|
};
|
|
@@ -2289,9 +2157,6 @@ const serializeAws_json1_1LocaleList = (input, context) => {
|
|
|
2289
2157
|
return input
|
|
2290
2158
|
.filter((e) => e != null)
|
|
2291
2159
|
.map((entry) => {
|
|
2292
|
-
if (entry === null) {
|
|
2293
|
-
return null;
|
|
2294
|
-
}
|
|
2295
2160
|
return serializeAws_json1_1Locale(entry, context);
|
|
2296
2161
|
});
|
|
2297
2162
|
};
|
|
@@ -2320,9 +2185,6 @@ const serializeAws_json1_1ParameterMapEntryList = (input, context) => {
|
|
|
2320
2185
|
return input
|
|
2321
2186
|
.filter((e) => e != null)
|
|
2322
2187
|
.map((entry) => {
|
|
2323
|
-
if (entry === null) {
|
|
2324
|
-
return null;
|
|
2325
|
-
}
|
|
2326
2188
|
return serializeAws_json1_1ParameterMapEntry(entry, context);
|
|
2327
2189
|
});
|
|
2328
2190
|
};
|
|
@@ -2339,9 +2201,6 @@ const serializeAws_json1_1PolicyParameterList = (input, context) => {
|
|
|
2339
2201
|
return input
|
|
2340
2202
|
.filter((e) => e != null)
|
|
2341
2203
|
.map((entry) => {
|
|
2342
|
-
if (entry === null) {
|
|
2343
|
-
return null;
|
|
2344
|
-
}
|
|
2345
2204
|
return serializeAws_json1_1PolicyParameter(entry, context);
|
|
2346
2205
|
});
|
|
2347
2206
|
};
|
|
@@ -2361,9 +2220,6 @@ const serializeAws_json1_1QualificationRequirementList = (input, context) => {
|
|
|
2361
2220
|
return input
|
|
2362
2221
|
.filter((e) => e != null)
|
|
2363
2222
|
.map((entry) => {
|
|
2364
|
-
if (entry === null) {
|
|
2365
|
-
return null;
|
|
2366
|
-
}
|
|
2367
2223
|
return serializeAws_json1_1QualificationRequirement(entry, context);
|
|
2368
2224
|
});
|
|
2369
2225
|
};
|
|
@@ -2389,9 +2245,6 @@ const serializeAws_json1_1ReviewPolicyLevelList = (input, context) => {
|
|
|
2389
2245
|
return input
|
|
2390
2246
|
.filter((e) => e != null)
|
|
2391
2247
|
.map((entry) => {
|
|
2392
|
-
if (entry === null) {
|
|
2393
|
-
return null;
|
|
2394
|
-
}
|
|
2395
2248
|
return entry;
|
|
2396
2249
|
});
|
|
2397
2250
|
};
|
|
@@ -2416,9 +2269,6 @@ const serializeAws_json1_1StringList = (input, context) => {
|
|
|
2416
2269
|
return input
|
|
2417
2270
|
.filter((e) => e != null)
|
|
2418
2271
|
.map((entry) => {
|
|
2419
|
-
if (entry === null) {
|
|
2420
|
-
return null;
|
|
2421
|
-
}
|
|
2422
2272
|
return entry;
|
|
2423
2273
|
});
|
|
2424
2274
|
};
|