@aws-sdk/client-ram 3.504.0 → 3.509.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 +122 -1334
- package/dist-es/protocols/Aws_restJson1.js +154 -1366
- package/package.json +3 -3
|
@@ -539,7 +539,7 @@ export const se_UpdateResourceShareCommand = async (input, context) => {
|
|
|
539
539
|
};
|
|
540
540
|
export const de_AcceptResourceShareInvitationCommand = async (output, context) => {
|
|
541
541
|
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
542
|
-
return
|
|
542
|
+
return de_CommandError(output, context);
|
|
543
543
|
}
|
|
544
544
|
const contents = map({
|
|
545
545
|
$metadata: deserializeMetadata(output),
|
|
@@ -552,55 +552,9 @@ export const de_AcceptResourceShareInvitationCommand = async (output, context) =
|
|
|
552
552
|
Object.assign(contents, doc);
|
|
553
553
|
return contents;
|
|
554
554
|
};
|
|
555
|
-
const de_AcceptResourceShareInvitationCommandError = async (output, context) => {
|
|
556
|
-
const parsedOutput = {
|
|
557
|
-
...output,
|
|
558
|
-
body: await parseErrorBody(output.body, context),
|
|
559
|
-
};
|
|
560
|
-
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
561
|
-
switch (errorCode) {
|
|
562
|
-
case "IdempotentParameterMismatchException":
|
|
563
|
-
case "com.amazonaws.ram#IdempotentParameterMismatchException":
|
|
564
|
-
throw await de_IdempotentParameterMismatchExceptionRes(parsedOutput, context);
|
|
565
|
-
case "InvalidClientTokenException":
|
|
566
|
-
case "com.amazonaws.ram#InvalidClientTokenException":
|
|
567
|
-
throw await de_InvalidClientTokenExceptionRes(parsedOutput, context);
|
|
568
|
-
case "MalformedArnException":
|
|
569
|
-
case "com.amazonaws.ram#MalformedArnException":
|
|
570
|
-
throw await de_MalformedArnExceptionRes(parsedOutput, context);
|
|
571
|
-
case "OperationNotPermittedException":
|
|
572
|
-
case "com.amazonaws.ram#OperationNotPermittedException":
|
|
573
|
-
throw await de_OperationNotPermittedExceptionRes(parsedOutput, context);
|
|
574
|
-
case "ResourceShareInvitationAlreadyAcceptedException":
|
|
575
|
-
case "com.amazonaws.ram#ResourceShareInvitationAlreadyAcceptedException":
|
|
576
|
-
throw await de_ResourceShareInvitationAlreadyAcceptedExceptionRes(parsedOutput, context);
|
|
577
|
-
case "ResourceShareInvitationAlreadyRejectedException":
|
|
578
|
-
case "com.amazonaws.ram#ResourceShareInvitationAlreadyRejectedException":
|
|
579
|
-
throw await de_ResourceShareInvitationAlreadyRejectedExceptionRes(parsedOutput, context);
|
|
580
|
-
case "ResourceShareInvitationArnNotFoundException":
|
|
581
|
-
case "com.amazonaws.ram#ResourceShareInvitationArnNotFoundException":
|
|
582
|
-
throw await de_ResourceShareInvitationArnNotFoundExceptionRes(parsedOutput, context);
|
|
583
|
-
case "ResourceShareInvitationExpiredException":
|
|
584
|
-
case "com.amazonaws.ram#ResourceShareInvitationExpiredException":
|
|
585
|
-
throw await de_ResourceShareInvitationExpiredExceptionRes(parsedOutput, context);
|
|
586
|
-
case "ServerInternalException":
|
|
587
|
-
case "com.amazonaws.ram#ServerInternalException":
|
|
588
|
-
throw await de_ServerInternalExceptionRes(parsedOutput, context);
|
|
589
|
-
case "ServiceUnavailableException":
|
|
590
|
-
case "com.amazonaws.ram#ServiceUnavailableException":
|
|
591
|
-
throw await de_ServiceUnavailableExceptionRes(parsedOutput, context);
|
|
592
|
-
default:
|
|
593
|
-
const parsedBody = parsedOutput.body;
|
|
594
|
-
return throwDefaultError({
|
|
595
|
-
output,
|
|
596
|
-
parsedBody,
|
|
597
|
-
errorCode,
|
|
598
|
-
});
|
|
599
|
-
}
|
|
600
|
-
};
|
|
601
555
|
export const de_AssociateResourceShareCommand = async (output, context) => {
|
|
602
556
|
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
603
|
-
return
|
|
557
|
+
return de_CommandError(output, context);
|
|
604
558
|
}
|
|
605
559
|
const contents = map({
|
|
606
560
|
$metadata: deserializeMetadata(output),
|
|
@@ -613,58 +567,9 @@ export const de_AssociateResourceShareCommand = async (output, context) => {
|
|
|
613
567
|
Object.assign(contents, doc);
|
|
614
568
|
return contents;
|
|
615
569
|
};
|
|
616
|
-
const de_AssociateResourceShareCommandError = async (output, context) => {
|
|
617
|
-
const parsedOutput = {
|
|
618
|
-
...output,
|
|
619
|
-
body: await parseErrorBody(output.body, context),
|
|
620
|
-
};
|
|
621
|
-
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
622
|
-
switch (errorCode) {
|
|
623
|
-
case "IdempotentParameterMismatchException":
|
|
624
|
-
case "com.amazonaws.ram#IdempotentParameterMismatchException":
|
|
625
|
-
throw await de_IdempotentParameterMismatchExceptionRes(parsedOutput, context);
|
|
626
|
-
case "InvalidClientTokenException":
|
|
627
|
-
case "com.amazonaws.ram#InvalidClientTokenException":
|
|
628
|
-
throw await de_InvalidClientTokenExceptionRes(parsedOutput, context);
|
|
629
|
-
case "InvalidParameterException":
|
|
630
|
-
case "com.amazonaws.ram#InvalidParameterException":
|
|
631
|
-
throw await de_InvalidParameterExceptionRes(parsedOutput, context);
|
|
632
|
-
case "InvalidStateTransitionException":
|
|
633
|
-
case "com.amazonaws.ram#InvalidStateTransitionException":
|
|
634
|
-
throw await de_InvalidStateTransitionExceptionRes(parsedOutput, context);
|
|
635
|
-
case "MalformedArnException":
|
|
636
|
-
case "com.amazonaws.ram#MalformedArnException":
|
|
637
|
-
throw await de_MalformedArnExceptionRes(parsedOutput, context);
|
|
638
|
-
case "OperationNotPermittedException":
|
|
639
|
-
case "com.amazonaws.ram#OperationNotPermittedException":
|
|
640
|
-
throw await de_OperationNotPermittedExceptionRes(parsedOutput, context);
|
|
641
|
-
case "ResourceShareLimitExceededException":
|
|
642
|
-
case "com.amazonaws.ram#ResourceShareLimitExceededException":
|
|
643
|
-
throw await de_ResourceShareLimitExceededExceptionRes(parsedOutput, context);
|
|
644
|
-
case "ServerInternalException":
|
|
645
|
-
case "com.amazonaws.ram#ServerInternalException":
|
|
646
|
-
throw await de_ServerInternalExceptionRes(parsedOutput, context);
|
|
647
|
-
case "ServiceUnavailableException":
|
|
648
|
-
case "com.amazonaws.ram#ServiceUnavailableException":
|
|
649
|
-
throw await de_ServiceUnavailableExceptionRes(parsedOutput, context);
|
|
650
|
-
case "ThrottlingException":
|
|
651
|
-
case "com.amazonaws.ram#ThrottlingException":
|
|
652
|
-
throw await de_ThrottlingExceptionRes(parsedOutput, context);
|
|
653
|
-
case "UnknownResourceException":
|
|
654
|
-
case "com.amazonaws.ram#UnknownResourceException":
|
|
655
|
-
throw await de_UnknownResourceExceptionRes(parsedOutput, context);
|
|
656
|
-
default:
|
|
657
|
-
const parsedBody = parsedOutput.body;
|
|
658
|
-
return throwDefaultError({
|
|
659
|
-
output,
|
|
660
|
-
parsedBody,
|
|
661
|
-
errorCode,
|
|
662
|
-
});
|
|
663
|
-
}
|
|
664
|
-
};
|
|
665
570
|
export const de_AssociateResourceSharePermissionCommand = async (output, context) => {
|
|
666
571
|
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
667
|
-
return
|
|
572
|
+
return de_CommandError(output, context);
|
|
668
573
|
}
|
|
669
574
|
const contents = map({
|
|
670
575
|
$metadata: deserializeMetadata(output),
|
|
@@ -677,46 +582,9 @@ export const de_AssociateResourceSharePermissionCommand = async (output, context
|
|
|
677
582
|
Object.assign(contents, doc);
|
|
678
583
|
return contents;
|
|
679
584
|
};
|
|
680
|
-
const de_AssociateResourceSharePermissionCommandError = async (output, context) => {
|
|
681
|
-
const parsedOutput = {
|
|
682
|
-
...output,
|
|
683
|
-
body: await parseErrorBody(output.body, context),
|
|
684
|
-
};
|
|
685
|
-
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
686
|
-
switch (errorCode) {
|
|
687
|
-
case "InvalidClientTokenException":
|
|
688
|
-
case "com.amazonaws.ram#InvalidClientTokenException":
|
|
689
|
-
throw await de_InvalidClientTokenExceptionRes(parsedOutput, context);
|
|
690
|
-
case "InvalidParameterException":
|
|
691
|
-
case "com.amazonaws.ram#InvalidParameterException":
|
|
692
|
-
throw await de_InvalidParameterExceptionRes(parsedOutput, context);
|
|
693
|
-
case "MalformedArnException":
|
|
694
|
-
case "com.amazonaws.ram#MalformedArnException":
|
|
695
|
-
throw await de_MalformedArnExceptionRes(parsedOutput, context);
|
|
696
|
-
case "OperationNotPermittedException":
|
|
697
|
-
case "com.amazonaws.ram#OperationNotPermittedException":
|
|
698
|
-
throw await de_OperationNotPermittedExceptionRes(parsedOutput, context);
|
|
699
|
-
case "ServerInternalException":
|
|
700
|
-
case "com.amazonaws.ram#ServerInternalException":
|
|
701
|
-
throw await de_ServerInternalExceptionRes(parsedOutput, context);
|
|
702
|
-
case "ServiceUnavailableException":
|
|
703
|
-
case "com.amazonaws.ram#ServiceUnavailableException":
|
|
704
|
-
throw await de_ServiceUnavailableExceptionRes(parsedOutput, context);
|
|
705
|
-
case "UnknownResourceException":
|
|
706
|
-
case "com.amazonaws.ram#UnknownResourceException":
|
|
707
|
-
throw await de_UnknownResourceExceptionRes(parsedOutput, context);
|
|
708
|
-
default:
|
|
709
|
-
const parsedBody = parsedOutput.body;
|
|
710
|
-
return throwDefaultError({
|
|
711
|
-
output,
|
|
712
|
-
parsedBody,
|
|
713
|
-
errorCode,
|
|
714
|
-
});
|
|
715
|
-
}
|
|
716
|
-
};
|
|
717
585
|
export const de_CreatePermissionCommand = async (output, context) => {
|
|
718
586
|
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
719
|
-
return
|
|
587
|
+
return de_CommandError(output, context);
|
|
720
588
|
}
|
|
721
589
|
const contents = map({
|
|
722
590
|
$metadata: deserializeMetadata(output),
|
|
@@ -729,55 +597,9 @@ export const de_CreatePermissionCommand = async (output, context) => {
|
|
|
729
597
|
Object.assign(contents, doc);
|
|
730
598
|
return contents;
|
|
731
599
|
};
|
|
732
|
-
const de_CreatePermissionCommandError = async (output, context) => {
|
|
733
|
-
const parsedOutput = {
|
|
734
|
-
...output,
|
|
735
|
-
body: await parseErrorBody(output.body, context),
|
|
736
|
-
};
|
|
737
|
-
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
738
|
-
switch (errorCode) {
|
|
739
|
-
case "IdempotentParameterMismatchException":
|
|
740
|
-
case "com.amazonaws.ram#IdempotentParameterMismatchException":
|
|
741
|
-
throw await de_IdempotentParameterMismatchExceptionRes(parsedOutput, context);
|
|
742
|
-
case "InvalidClientTokenException":
|
|
743
|
-
case "com.amazonaws.ram#InvalidClientTokenException":
|
|
744
|
-
throw await de_InvalidClientTokenExceptionRes(parsedOutput, context);
|
|
745
|
-
case "InvalidParameterException":
|
|
746
|
-
case "com.amazonaws.ram#InvalidParameterException":
|
|
747
|
-
throw await de_InvalidParameterExceptionRes(parsedOutput, context);
|
|
748
|
-
case "InvalidPolicyException":
|
|
749
|
-
case "com.amazonaws.ram#InvalidPolicyException":
|
|
750
|
-
throw await de_InvalidPolicyExceptionRes(parsedOutput, context);
|
|
751
|
-
case "MalformedPolicyTemplateException":
|
|
752
|
-
case "com.amazonaws.ram#MalformedPolicyTemplateException":
|
|
753
|
-
throw await de_MalformedPolicyTemplateExceptionRes(parsedOutput, context);
|
|
754
|
-
case "OperationNotPermittedException":
|
|
755
|
-
case "com.amazonaws.ram#OperationNotPermittedException":
|
|
756
|
-
throw await de_OperationNotPermittedExceptionRes(parsedOutput, context);
|
|
757
|
-
case "PermissionAlreadyExistsException":
|
|
758
|
-
case "com.amazonaws.ram#PermissionAlreadyExistsException":
|
|
759
|
-
throw await de_PermissionAlreadyExistsExceptionRes(parsedOutput, context);
|
|
760
|
-
case "PermissionLimitExceededException":
|
|
761
|
-
case "com.amazonaws.ram#PermissionLimitExceededException":
|
|
762
|
-
throw await de_PermissionLimitExceededExceptionRes(parsedOutput, context);
|
|
763
|
-
case "ServerInternalException":
|
|
764
|
-
case "com.amazonaws.ram#ServerInternalException":
|
|
765
|
-
throw await de_ServerInternalExceptionRes(parsedOutput, context);
|
|
766
|
-
case "ServiceUnavailableException":
|
|
767
|
-
case "com.amazonaws.ram#ServiceUnavailableException":
|
|
768
|
-
throw await de_ServiceUnavailableExceptionRes(parsedOutput, context);
|
|
769
|
-
default:
|
|
770
|
-
const parsedBody = parsedOutput.body;
|
|
771
|
-
return throwDefaultError({
|
|
772
|
-
output,
|
|
773
|
-
parsedBody,
|
|
774
|
-
errorCode,
|
|
775
|
-
});
|
|
776
|
-
}
|
|
777
|
-
};
|
|
778
600
|
export const de_CreatePermissionVersionCommand = async (output, context) => {
|
|
779
601
|
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
780
|
-
return
|
|
602
|
+
return de_CommandError(output, context);
|
|
781
603
|
}
|
|
782
604
|
const contents = map({
|
|
783
605
|
$metadata: deserializeMetadata(output),
|
|
@@ -790,55 +612,9 @@ export const de_CreatePermissionVersionCommand = async (output, context) => {
|
|
|
790
612
|
Object.assign(contents, doc);
|
|
791
613
|
return contents;
|
|
792
614
|
};
|
|
793
|
-
const de_CreatePermissionVersionCommandError = async (output, context) => {
|
|
794
|
-
const parsedOutput = {
|
|
795
|
-
...output,
|
|
796
|
-
body: await parseErrorBody(output.body, context),
|
|
797
|
-
};
|
|
798
|
-
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
799
|
-
switch (errorCode) {
|
|
800
|
-
case "IdempotentParameterMismatchException":
|
|
801
|
-
case "com.amazonaws.ram#IdempotentParameterMismatchException":
|
|
802
|
-
throw await de_IdempotentParameterMismatchExceptionRes(parsedOutput, context);
|
|
803
|
-
case "InvalidClientTokenException":
|
|
804
|
-
case "com.amazonaws.ram#InvalidClientTokenException":
|
|
805
|
-
throw await de_InvalidClientTokenExceptionRes(parsedOutput, context);
|
|
806
|
-
case "InvalidParameterException":
|
|
807
|
-
case "com.amazonaws.ram#InvalidParameterException":
|
|
808
|
-
throw await de_InvalidParameterExceptionRes(parsedOutput, context);
|
|
809
|
-
case "InvalidPolicyException":
|
|
810
|
-
case "com.amazonaws.ram#InvalidPolicyException":
|
|
811
|
-
throw await de_InvalidPolicyExceptionRes(parsedOutput, context);
|
|
812
|
-
case "MalformedArnException":
|
|
813
|
-
case "com.amazonaws.ram#MalformedArnException":
|
|
814
|
-
throw await de_MalformedArnExceptionRes(parsedOutput, context);
|
|
815
|
-
case "MalformedPolicyTemplateException":
|
|
816
|
-
case "com.amazonaws.ram#MalformedPolicyTemplateException":
|
|
817
|
-
throw await de_MalformedPolicyTemplateExceptionRes(parsedOutput, context);
|
|
818
|
-
case "PermissionVersionsLimitExceededException":
|
|
819
|
-
case "com.amazonaws.ram#PermissionVersionsLimitExceededException":
|
|
820
|
-
throw await de_PermissionVersionsLimitExceededExceptionRes(parsedOutput, context);
|
|
821
|
-
case "ServerInternalException":
|
|
822
|
-
case "com.amazonaws.ram#ServerInternalException":
|
|
823
|
-
throw await de_ServerInternalExceptionRes(parsedOutput, context);
|
|
824
|
-
case "ServiceUnavailableException":
|
|
825
|
-
case "com.amazonaws.ram#ServiceUnavailableException":
|
|
826
|
-
throw await de_ServiceUnavailableExceptionRes(parsedOutput, context);
|
|
827
|
-
case "UnknownResourceException":
|
|
828
|
-
case "com.amazonaws.ram#UnknownResourceException":
|
|
829
|
-
throw await de_UnknownResourceExceptionRes(parsedOutput, context);
|
|
830
|
-
default:
|
|
831
|
-
const parsedBody = parsedOutput.body;
|
|
832
|
-
return throwDefaultError({
|
|
833
|
-
output,
|
|
834
|
-
parsedBody,
|
|
835
|
-
errorCode,
|
|
836
|
-
});
|
|
837
|
-
}
|
|
838
|
-
};
|
|
839
615
|
export const de_CreateResourceShareCommand = async (output, context) => {
|
|
840
616
|
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
841
|
-
return
|
|
617
|
+
return de_CommandError(output, context);
|
|
842
618
|
}
|
|
843
619
|
const contents = map({
|
|
844
620
|
$metadata: deserializeMetadata(output),
|
|
@@ -851,61 +627,9 @@ export const de_CreateResourceShareCommand = async (output, context) => {
|
|
|
851
627
|
Object.assign(contents, doc);
|
|
852
628
|
return contents;
|
|
853
629
|
};
|
|
854
|
-
const de_CreateResourceShareCommandError = async (output, context) => {
|
|
855
|
-
const parsedOutput = {
|
|
856
|
-
...output,
|
|
857
|
-
body: await parseErrorBody(output.body, context),
|
|
858
|
-
};
|
|
859
|
-
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
860
|
-
switch (errorCode) {
|
|
861
|
-
case "IdempotentParameterMismatchException":
|
|
862
|
-
case "com.amazonaws.ram#IdempotentParameterMismatchException":
|
|
863
|
-
throw await de_IdempotentParameterMismatchExceptionRes(parsedOutput, context);
|
|
864
|
-
case "InvalidClientTokenException":
|
|
865
|
-
case "com.amazonaws.ram#InvalidClientTokenException":
|
|
866
|
-
throw await de_InvalidClientTokenExceptionRes(parsedOutput, context);
|
|
867
|
-
case "InvalidParameterException":
|
|
868
|
-
case "com.amazonaws.ram#InvalidParameterException":
|
|
869
|
-
throw await de_InvalidParameterExceptionRes(parsedOutput, context);
|
|
870
|
-
case "InvalidStateTransitionException":
|
|
871
|
-
case "com.amazonaws.ram#InvalidStateTransitionException":
|
|
872
|
-
throw await de_InvalidStateTransitionExceptionRes(parsedOutput, context);
|
|
873
|
-
case "MalformedArnException":
|
|
874
|
-
case "com.amazonaws.ram#MalformedArnException":
|
|
875
|
-
throw await de_MalformedArnExceptionRes(parsedOutput, context);
|
|
876
|
-
case "OperationNotPermittedException":
|
|
877
|
-
case "com.amazonaws.ram#OperationNotPermittedException":
|
|
878
|
-
throw await de_OperationNotPermittedExceptionRes(parsedOutput, context);
|
|
879
|
-
case "ResourceShareLimitExceededException":
|
|
880
|
-
case "com.amazonaws.ram#ResourceShareLimitExceededException":
|
|
881
|
-
throw await de_ResourceShareLimitExceededExceptionRes(parsedOutput, context);
|
|
882
|
-
case "ServerInternalException":
|
|
883
|
-
case "com.amazonaws.ram#ServerInternalException":
|
|
884
|
-
throw await de_ServerInternalExceptionRes(parsedOutput, context);
|
|
885
|
-
case "ServiceUnavailableException":
|
|
886
|
-
case "com.amazonaws.ram#ServiceUnavailableException":
|
|
887
|
-
throw await de_ServiceUnavailableExceptionRes(parsedOutput, context);
|
|
888
|
-
case "TagLimitExceededException":
|
|
889
|
-
case "com.amazonaws.ram#TagLimitExceededException":
|
|
890
|
-
throw await de_TagLimitExceededExceptionRes(parsedOutput, context);
|
|
891
|
-
case "TagPolicyViolationException":
|
|
892
|
-
case "com.amazonaws.ram#TagPolicyViolationException":
|
|
893
|
-
throw await de_TagPolicyViolationExceptionRes(parsedOutput, context);
|
|
894
|
-
case "UnknownResourceException":
|
|
895
|
-
case "com.amazonaws.ram#UnknownResourceException":
|
|
896
|
-
throw await de_UnknownResourceExceptionRes(parsedOutput, context);
|
|
897
|
-
default:
|
|
898
|
-
const parsedBody = parsedOutput.body;
|
|
899
|
-
return throwDefaultError({
|
|
900
|
-
output,
|
|
901
|
-
parsedBody,
|
|
902
|
-
errorCode,
|
|
903
|
-
});
|
|
904
|
-
}
|
|
905
|
-
};
|
|
906
630
|
export const de_DeletePermissionCommand = async (output, context) => {
|
|
907
631
|
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
908
|
-
return
|
|
632
|
+
return de_CommandError(output, context);
|
|
909
633
|
}
|
|
910
634
|
const contents = map({
|
|
911
635
|
$metadata: deserializeMetadata(output),
|
|
@@ -919,46 +643,9 @@ export const de_DeletePermissionCommand = async (output, context) => {
|
|
|
919
643
|
Object.assign(contents, doc);
|
|
920
644
|
return contents;
|
|
921
645
|
};
|
|
922
|
-
const de_DeletePermissionCommandError = async (output, context) => {
|
|
923
|
-
const parsedOutput = {
|
|
924
|
-
...output,
|
|
925
|
-
body: await parseErrorBody(output.body, context),
|
|
926
|
-
};
|
|
927
|
-
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
928
|
-
switch (errorCode) {
|
|
929
|
-
case "IdempotentParameterMismatchException":
|
|
930
|
-
case "com.amazonaws.ram#IdempotentParameterMismatchException":
|
|
931
|
-
throw await de_IdempotentParameterMismatchExceptionRes(parsedOutput, context);
|
|
932
|
-
case "InvalidClientTokenException":
|
|
933
|
-
case "com.amazonaws.ram#InvalidClientTokenException":
|
|
934
|
-
throw await de_InvalidClientTokenExceptionRes(parsedOutput, context);
|
|
935
|
-
case "MalformedArnException":
|
|
936
|
-
case "com.amazonaws.ram#MalformedArnException":
|
|
937
|
-
throw await de_MalformedArnExceptionRes(parsedOutput, context);
|
|
938
|
-
case "OperationNotPermittedException":
|
|
939
|
-
case "com.amazonaws.ram#OperationNotPermittedException":
|
|
940
|
-
throw await de_OperationNotPermittedExceptionRes(parsedOutput, context);
|
|
941
|
-
case "ServerInternalException":
|
|
942
|
-
case "com.amazonaws.ram#ServerInternalException":
|
|
943
|
-
throw await de_ServerInternalExceptionRes(parsedOutput, context);
|
|
944
|
-
case "ServiceUnavailableException":
|
|
945
|
-
case "com.amazonaws.ram#ServiceUnavailableException":
|
|
946
|
-
throw await de_ServiceUnavailableExceptionRes(parsedOutput, context);
|
|
947
|
-
case "UnknownResourceException":
|
|
948
|
-
case "com.amazonaws.ram#UnknownResourceException":
|
|
949
|
-
throw await de_UnknownResourceExceptionRes(parsedOutput, context);
|
|
950
|
-
default:
|
|
951
|
-
const parsedBody = parsedOutput.body;
|
|
952
|
-
return throwDefaultError({
|
|
953
|
-
output,
|
|
954
|
-
parsedBody,
|
|
955
|
-
errorCode,
|
|
956
|
-
});
|
|
957
|
-
}
|
|
958
|
-
};
|
|
959
646
|
export const de_DeletePermissionVersionCommand = async (output, context) => {
|
|
960
647
|
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
961
|
-
return
|
|
648
|
+
return de_CommandError(output, context);
|
|
962
649
|
}
|
|
963
650
|
const contents = map({
|
|
964
651
|
$metadata: deserializeMetadata(output),
|
|
@@ -972,49 +659,9 @@ export const de_DeletePermissionVersionCommand = async (output, context) => {
|
|
|
972
659
|
Object.assign(contents, doc);
|
|
973
660
|
return contents;
|
|
974
661
|
};
|
|
975
|
-
const de_DeletePermissionVersionCommandError = async (output, context) => {
|
|
976
|
-
const parsedOutput = {
|
|
977
|
-
...output,
|
|
978
|
-
body: await parseErrorBody(output.body, context),
|
|
979
|
-
};
|
|
980
|
-
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
981
|
-
switch (errorCode) {
|
|
982
|
-
case "IdempotentParameterMismatchException":
|
|
983
|
-
case "com.amazonaws.ram#IdempotentParameterMismatchException":
|
|
984
|
-
throw await de_IdempotentParameterMismatchExceptionRes(parsedOutput, context);
|
|
985
|
-
case "InvalidClientTokenException":
|
|
986
|
-
case "com.amazonaws.ram#InvalidClientTokenException":
|
|
987
|
-
throw await de_InvalidClientTokenExceptionRes(parsedOutput, context);
|
|
988
|
-
case "InvalidParameterException":
|
|
989
|
-
case "com.amazonaws.ram#InvalidParameterException":
|
|
990
|
-
throw await de_InvalidParameterExceptionRes(parsedOutput, context);
|
|
991
|
-
case "MalformedArnException":
|
|
992
|
-
case "com.amazonaws.ram#MalformedArnException":
|
|
993
|
-
throw await de_MalformedArnExceptionRes(parsedOutput, context);
|
|
994
|
-
case "OperationNotPermittedException":
|
|
995
|
-
case "com.amazonaws.ram#OperationNotPermittedException":
|
|
996
|
-
throw await de_OperationNotPermittedExceptionRes(parsedOutput, context);
|
|
997
|
-
case "ServerInternalException":
|
|
998
|
-
case "com.amazonaws.ram#ServerInternalException":
|
|
999
|
-
throw await de_ServerInternalExceptionRes(parsedOutput, context);
|
|
1000
|
-
case "ServiceUnavailableException":
|
|
1001
|
-
case "com.amazonaws.ram#ServiceUnavailableException":
|
|
1002
|
-
throw await de_ServiceUnavailableExceptionRes(parsedOutput, context);
|
|
1003
|
-
case "UnknownResourceException":
|
|
1004
|
-
case "com.amazonaws.ram#UnknownResourceException":
|
|
1005
|
-
throw await de_UnknownResourceExceptionRes(parsedOutput, context);
|
|
1006
|
-
default:
|
|
1007
|
-
const parsedBody = parsedOutput.body;
|
|
1008
|
-
return throwDefaultError({
|
|
1009
|
-
output,
|
|
1010
|
-
parsedBody,
|
|
1011
|
-
errorCode,
|
|
1012
|
-
});
|
|
1013
|
-
}
|
|
1014
|
-
};
|
|
1015
662
|
export const de_DeleteResourceShareCommand = async (output, context) => {
|
|
1016
663
|
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
1017
|
-
return
|
|
664
|
+
return de_CommandError(output, context);
|
|
1018
665
|
}
|
|
1019
666
|
const contents = map({
|
|
1020
667
|
$metadata: deserializeMetadata(output),
|
|
@@ -1027,52 +674,9 @@ export const de_DeleteResourceShareCommand = async (output, context) => {
|
|
|
1027
674
|
Object.assign(contents, doc);
|
|
1028
675
|
return contents;
|
|
1029
676
|
};
|
|
1030
|
-
const de_DeleteResourceShareCommandError = async (output, context) => {
|
|
1031
|
-
const parsedOutput = {
|
|
1032
|
-
...output,
|
|
1033
|
-
body: await parseErrorBody(output.body, context),
|
|
1034
|
-
};
|
|
1035
|
-
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1036
|
-
switch (errorCode) {
|
|
1037
|
-
case "IdempotentParameterMismatchException":
|
|
1038
|
-
case "com.amazonaws.ram#IdempotentParameterMismatchException":
|
|
1039
|
-
throw await de_IdempotentParameterMismatchExceptionRes(parsedOutput, context);
|
|
1040
|
-
case "InvalidClientTokenException":
|
|
1041
|
-
case "com.amazonaws.ram#InvalidClientTokenException":
|
|
1042
|
-
throw await de_InvalidClientTokenExceptionRes(parsedOutput, context);
|
|
1043
|
-
case "InvalidParameterException":
|
|
1044
|
-
case "com.amazonaws.ram#InvalidParameterException":
|
|
1045
|
-
throw await de_InvalidParameterExceptionRes(parsedOutput, context);
|
|
1046
|
-
case "InvalidStateTransitionException":
|
|
1047
|
-
case "com.amazonaws.ram#InvalidStateTransitionException":
|
|
1048
|
-
throw await de_InvalidStateTransitionExceptionRes(parsedOutput, context);
|
|
1049
|
-
case "MalformedArnException":
|
|
1050
|
-
case "com.amazonaws.ram#MalformedArnException":
|
|
1051
|
-
throw await de_MalformedArnExceptionRes(parsedOutput, context);
|
|
1052
|
-
case "OperationNotPermittedException":
|
|
1053
|
-
case "com.amazonaws.ram#OperationNotPermittedException":
|
|
1054
|
-
throw await de_OperationNotPermittedExceptionRes(parsedOutput, context);
|
|
1055
|
-
case "ServerInternalException":
|
|
1056
|
-
case "com.amazonaws.ram#ServerInternalException":
|
|
1057
|
-
throw await de_ServerInternalExceptionRes(parsedOutput, context);
|
|
1058
|
-
case "ServiceUnavailableException":
|
|
1059
|
-
case "com.amazonaws.ram#ServiceUnavailableException":
|
|
1060
|
-
throw await de_ServiceUnavailableExceptionRes(parsedOutput, context);
|
|
1061
|
-
case "UnknownResourceException":
|
|
1062
|
-
case "com.amazonaws.ram#UnknownResourceException":
|
|
1063
|
-
throw await de_UnknownResourceExceptionRes(parsedOutput, context);
|
|
1064
|
-
default:
|
|
1065
|
-
const parsedBody = parsedOutput.body;
|
|
1066
|
-
return throwDefaultError({
|
|
1067
|
-
output,
|
|
1068
|
-
parsedBody,
|
|
1069
|
-
errorCode,
|
|
1070
|
-
});
|
|
1071
|
-
}
|
|
1072
|
-
};
|
|
1073
677
|
export const de_DisassociateResourceShareCommand = async (output, context) => {
|
|
1074
678
|
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
1075
|
-
return
|
|
679
|
+
return de_CommandError(output, context);
|
|
1076
680
|
}
|
|
1077
681
|
const contents = map({
|
|
1078
682
|
$metadata: deserializeMetadata(output),
|
|
@@ -1085,55 +689,9 @@ export const de_DisassociateResourceShareCommand = async (output, context) => {
|
|
|
1085
689
|
Object.assign(contents, doc);
|
|
1086
690
|
return contents;
|
|
1087
691
|
};
|
|
1088
|
-
const de_DisassociateResourceShareCommandError = async (output, context) => {
|
|
1089
|
-
const parsedOutput = {
|
|
1090
|
-
...output,
|
|
1091
|
-
body: await parseErrorBody(output.body, context),
|
|
1092
|
-
};
|
|
1093
|
-
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1094
|
-
switch (errorCode) {
|
|
1095
|
-
case "IdempotentParameterMismatchException":
|
|
1096
|
-
case "com.amazonaws.ram#IdempotentParameterMismatchException":
|
|
1097
|
-
throw await de_IdempotentParameterMismatchExceptionRes(parsedOutput, context);
|
|
1098
|
-
case "InvalidClientTokenException":
|
|
1099
|
-
case "com.amazonaws.ram#InvalidClientTokenException":
|
|
1100
|
-
throw await de_InvalidClientTokenExceptionRes(parsedOutput, context);
|
|
1101
|
-
case "InvalidParameterException":
|
|
1102
|
-
case "com.amazonaws.ram#InvalidParameterException":
|
|
1103
|
-
throw await de_InvalidParameterExceptionRes(parsedOutput, context);
|
|
1104
|
-
case "InvalidStateTransitionException":
|
|
1105
|
-
case "com.amazonaws.ram#InvalidStateTransitionException":
|
|
1106
|
-
throw await de_InvalidStateTransitionExceptionRes(parsedOutput, context);
|
|
1107
|
-
case "MalformedArnException":
|
|
1108
|
-
case "com.amazonaws.ram#MalformedArnException":
|
|
1109
|
-
throw await de_MalformedArnExceptionRes(parsedOutput, context);
|
|
1110
|
-
case "OperationNotPermittedException":
|
|
1111
|
-
case "com.amazonaws.ram#OperationNotPermittedException":
|
|
1112
|
-
throw await de_OperationNotPermittedExceptionRes(parsedOutput, context);
|
|
1113
|
-
case "ResourceShareLimitExceededException":
|
|
1114
|
-
case "com.amazonaws.ram#ResourceShareLimitExceededException":
|
|
1115
|
-
throw await de_ResourceShareLimitExceededExceptionRes(parsedOutput, context);
|
|
1116
|
-
case "ServerInternalException":
|
|
1117
|
-
case "com.amazonaws.ram#ServerInternalException":
|
|
1118
|
-
throw await de_ServerInternalExceptionRes(parsedOutput, context);
|
|
1119
|
-
case "ServiceUnavailableException":
|
|
1120
|
-
case "com.amazonaws.ram#ServiceUnavailableException":
|
|
1121
|
-
throw await de_ServiceUnavailableExceptionRes(parsedOutput, context);
|
|
1122
|
-
case "UnknownResourceException":
|
|
1123
|
-
case "com.amazonaws.ram#UnknownResourceException":
|
|
1124
|
-
throw await de_UnknownResourceExceptionRes(parsedOutput, context);
|
|
1125
|
-
default:
|
|
1126
|
-
const parsedBody = parsedOutput.body;
|
|
1127
|
-
return throwDefaultError({
|
|
1128
|
-
output,
|
|
1129
|
-
parsedBody,
|
|
1130
|
-
errorCode,
|
|
1131
|
-
});
|
|
1132
|
-
}
|
|
1133
|
-
};
|
|
1134
692
|
export const de_DisassociateResourceSharePermissionCommand = async (output, context) => {
|
|
1135
693
|
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
1136
|
-
return
|
|
694
|
+
return de_CommandError(output, context);
|
|
1137
695
|
}
|
|
1138
696
|
const contents = map({
|
|
1139
697
|
$metadata: deserializeMetadata(output),
|
|
@@ -1146,49 +704,9 @@ export const de_DisassociateResourceSharePermissionCommand = async (output, cont
|
|
|
1146
704
|
Object.assign(contents, doc);
|
|
1147
705
|
return contents;
|
|
1148
706
|
};
|
|
1149
|
-
const de_DisassociateResourceSharePermissionCommandError = async (output, context) => {
|
|
1150
|
-
const parsedOutput = {
|
|
1151
|
-
...output,
|
|
1152
|
-
body: await parseErrorBody(output.body, context),
|
|
1153
|
-
};
|
|
1154
|
-
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1155
|
-
switch (errorCode) {
|
|
1156
|
-
case "InvalidClientTokenException":
|
|
1157
|
-
case "com.amazonaws.ram#InvalidClientTokenException":
|
|
1158
|
-
throw await de_InvalidClientTokenExceptionRes(parsedOutput, context);
|
|
1159
|
-
case "InvalidParameterException":
|
|
1160
|
-
case "com.amazonaws.ram#InvalidParameterException":
|
|
1161
|
-
throw await de_InvalidParameterExceptionRes(parsedOutput, context);
|
|
1162
|
-
case "InvalidStateTransitionException":
|
|
1163
|
-
case "com.amazonaws.ram#InvalidStateTransitionException":
|
|
1164
|
-
throw await de_InvalidStateTransitionExceptionRes(parsedOutput, context);
|
|
1165
|
-
case "MalformedArnException":
|
|
1166
|
-
case "com.amazonaws.ram#MalformedArnException":
|
|
1167
|
-
throw await de_MalformedArnExceptionRes(parsedOutput, context);
|
|
1168
|
-
case "OperationNotPermittedException":
|
|
1169
|
-
case "com.amazonaws.ram#OperationNotPermittedException":
|
|
1170
|
-
throw await de_OperationNotPermittedExceptionRes(parsedOutput, context);
|
|
1171
|
-
case "ServerInternalException":
|
|
1172
|
-
case "com.amazonaws.ram#ServerInternalException":
|
|
1173
|
-
throw await de_ServerInternalExceptionRes(parsedOutput, context);
|
|
1174
|
-
case "ServiceUnavailableException":
|
|
1175
|
-
case "com.amazonaws.ram#ServiceUnavailableException":
|
|
1176
|
-
throw await de_ServiceUnavailableExceptionRes(parsedOutput, context);
|
|
1177
|
-
case "UnknownResourceException":
|
|
1178
|
-
case "com.amazonaws.ram#UnknownResourceException":
|
|
1179
|
-
throw await de_UnknownResourceExceptionRes(parsedOutput, context);
|
|
1180
|
-
default:
|
|
1181
|
-
const parsedBody = parsedOutput.body;
|
|
1182
|
-
return throwDefaultError({
|
|
1183
|
-
output,
|
|
1184
|
-
parsedBody,
|
|
1185
|
-
errorCode,
|
|
1186
|
-
});
|
|
1187
|
-
}
|
|
1188
|
-
};
|
|
1189
707
|
export const de_EnableSharingWithAwsOrganizationCommand = async (output, context) => {
|
|
1190
708
|
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
1191
|
-
return
|
|
709
|
+
return de_CommandError(output, context);
|
|
1192
710
|
}
|
|
1193
711
|
const contents = map({
|
|
1194
712
|
$metadata: deserializeMetadata(output),
|
|
@@ -1200,34 +718,9 @@ export const de_EnableSharingWithAwsOrganizationCommand = async (output, context
|
|
|
1200
718
|
Object.assign(contents, doc);
|
|
1201
719
|
return contents;
|
|
1202
720
|
};
|
|
1203
|
-
const de_EnableSharingWithAwsOrganizationCommandError = async (output, context) => {
|
|
1204
|
-
const parsedOutput = {
|
|
1205
|
-
...output,
|
|
1206
|
-
body: await parseErrorBody(output.body, context),
|
|
1207
|
-
};
|
|
1208
|
-
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1209
|
-
switch (errorCode) {
|
|
1210
|
-
case "OperationNotPermittedException":
|
|
1211
|
-
case "com.amazonaws.ram#OperationNotPermittedException":
|
|
1212
|
-
throw await de_OperationNotPermittedExceptionRes(parsedOutput, context);
|
|
1213
|
-
case "ServerInternalException":
|
|
1214
|
-
case "com.amazonaws.ram#ServerInternalException":
|
|
1215
|
-
throw await de_ServerInternalExceptionRes(parsedOutput, context);
|
|
1216
|
-
case "ServiceUnavailableException":
|
|
1217
|
-
case "com.amazonaws.ram#ServiceUnavailableException":
|
|
1218
|
-
throw await de_ServiceUnavailableExceptionRes(parsedOutput, context);
|
|
1219
|
-
default:
|
|
1220
|
-
const parsedBody = parsedOutput.body;
|
|
1221
|
-
return throwDefaultError({
|
|
1222
|
-
output,
|
|
1223
|
-
parsedBody,
|
|
1224
|
-
errorCode,
|
|
1225
|
-
});
|
|
1226
|
-
}
|
|
1227
|
-
};
|
|
1228
721
|
export const de_GetPermissionCommand = async (output, context) => {
|
|
1229
722
|
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
1230
|
-
return
|
|
723
|
+
return de_CommandError(output, context);
|
|
1231
724
|
}
|
|
1232
725
|
const contents = map({
|
|
1233
726
|
$metadata: deserializeMetadata(output),
|
|
@@ -1239,43 +732,9 @@ export const de_GetPermissionCommand = async (output, context) => {
|
|
|
1239
732
|
Object.assign(contents, doc);
|
|
1240
733
|
return contents;
|
|
1241
734
|
};
|
|
1242
|
-
const de_GetPermissionCommandError = async (output, context) => {
|
|
1243
|
-
const parsedOutput = {
|
|
1244
|
-
...output,
|
|
1245
|
-
body: await parseErrorBody(output.body, context),
|
|
1246
|
-
};
|
|
1247
|
-
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1248
|
-
switch (errorCode) {
|
|
1249
|
-
case "InvalidParameterException":
|
|
1250
|
-
case "com.amazonaws.ram#InvalidParameterException":
|
|
1251
|
-
throw await de_InvalidParameterExceptionRes(parsedOutput, context);
|
|
1252
|
-
case "MalformedArnException":
|
|
1253
|
-
case "com.amazonaws.ram#MalformedArnException":
|
|
1254
|
-
throw await de_MalformedArnExceptionRes(parsedOutput, context);
|
|
1255
|
-
case "OperationNotPermittedException":
|
|
1256
|
-
case "com.amazonaws.ram#OperationNotPermittedException":
|
|
1257
|
-
throw await de_OperationNotPermittedExceptionRes(parsedOutput, context);
|
|
1258
|
-
case "ServerInternalException":
|
|
1259
|
-
case "com.amazonaws.ram#ServerInternalException":
|
|
1260
|
-
throw await de_ServerInternalExceptionRes(parsedOutput, context);
|
|
1261
|
-
case "ServiceUnavailableException":
|
|
1262
|
-
case "com.amazonaws.ram#ServiceUnavailableException":
|
|
1263
|
-
throw await de_ServiceUnavailableExceptionRes(parsedOutput, context);
|
|
1264
|
-
case "UnknownResourceException":
|
|
1265
|
-
case "com.amazonaws.ram#UnknownResourceException":
|
|
1266
|
-
throw await de_UnknownResourceExceptionRes(parsedOutput, context);
|
|
1267
|
-
default:
|
|
1268
|
-
const parsedBody = parsedOutput.body;
|
|
1269
|
-
return throwDefaultError({
|
|
1270
|
-
output,
|
|
1271
|
-
parsedBody,
|
|
1272
|
-
errorCode,
|
|
1273
|
-
});
|
|
1274
|
-
}
|
|
1275
|
-
};
|
|
1276
735
|
export const de_GetResourcePoliciesCommand = async (output, context) => {
|
|
1277
736
|
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
1278
|
-
return
|
|
737
|
+
return de_CommandError(output, context);
|
|
1279
738
|
}
|
|
1280
739
|
const contents = map({
|
|
1281
740
|
$metadata: deserializeMetadata(output),
|
|
@@ -1288,43 +747,9 @@ export const de_GetResourcePoliciesCommand = async (output, context) => {
|
|
|
1288
747
|
Object.assign(contents, doc);
|
|
1289
748
|
return contents;
|
|
1290
749
|
};
|
|
1291
|
-
const de_GetResourcePoliciesCommandError = async (output, context) => {
|
|
1292
|
-
const parsedOutput = {
|
|
1293
|
-
...output,
|
|
1294
|
-
body: await parseErrorBody(output.body, context),
|
|
1295
|
-
};
|
|
1296
|
-
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1297
|
-
switch (errorCode) {
|
|
1298
|
-
case "InvalidNextTokenException":
|
|
1299
|
-
case "com.amazonaws.ram#InvalidNextTokenException":
|
|
1300
|
-
throw await de_InvalidNextTokenExceptionRes(parsedOutput, context);
|
|
1301
|
-
case "InvalidParameterException":
|
|
1302
|
-
case "com.amazonaws.ram#InvalidParameterException":
|
|
1303
|
-
throw await de_InvalidParameterExceptionRes(parsedOutput, context);
|
|
1304
|
-
case "MalformedArnException":
|
|
1305
|
-
case "com.amazonaws.ram#MalformedArnException":
|
|
1306
|
-
throw await de_MalformedArnExceptionRes(parsedOutput, context);
|
|
1307
|
-
case "ResourceArnNotFoundException":
|
|
1308
|
-
case "com.amazonaws.ram#ResourceArnNotFoundException":
|
|
1309
|
-
throw await de_ResourceArnNotFoundExceptionRes(parsedOutput, context);
|
|
1310
|
-
case "ServerInternalException":
|
|
1311
|
-
case "com.amazonaws.ram#ServerInternalException":
|
|
1312
|
-
throw await de_ServerInternalExceptionRes(parsedOutput, context);
|
|
1313
|
-
case "ServiceUnavailableException":
|
|
1314
|
-
case "com.amazonaws.ram#ServiceUnavailableException":
|
|
1315
|
-
throw await de_ServiceUnavailableExceptionRes(parsedOutput, context);
|
|
1316
|
-
default:
|
|
1317
|
-
const parsedBody = parsedOutput.body;
|
|
1318
|
-
return throwDefaultError({
|
|
1319
|
-
output,
|
|
1320
|
-
parsedBody,
|
|
1321
|
-
errorCode,
|
|
1322
|
-
});
|
|
1323
|
-
}
|
|
1324
|
-
};
|
|
1325
750
|
export const de_GetResourceShareAssociationsCommand = async (output, context) => {
|
|
1326
751
|
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
1327
|
-
return
|
|
752
|
+
return de_CommandError(output, context);
|
|
1328
753
|
}
|
|
1329
754
|
const contents = map({
|
|
1330
755
|
$metadata: deserializeMetadata(output),
|
|
@@ -1337,46 +762,9 @@ export const de_GetResourceShareAssociationsCommand = async (output, context) =>
|
|
|
1337
762
|
Object.assign(contents, doc);
|
|
1338
763
|
return contents;
|
|
1339
764
|
};
|
|
1340
|
-
const de_GetResourceShareAssociationsCommandError = async (output, context) => {
|
|
1341
|
-
const parsedOutput = {
|
|
1342
|
-
...output,
|
|
1343
|
-
body: await parseErrorBody(output.body, context),
|
|
1344
|
-
};
|
|
1345
|
-
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1346
|
-
switch (errorCode) {
|
|
1347
|
-
case "InvalidNextTokenException":
|
|
1348
|
-
case "com.amazonaws.ram#InvalidNextTokenException":
|
|
1349
|
-
throw await de_InvalidNextTokenExceptionRes(parsedOutput, context);
|
|
1350
|
-
case "InvalidParameterException":
|
|
1351
|
-
case "com.amazonaws.ram#InvalidParameterException":
|
|
1352
|
-
throw await de_InvalidParameterExceptionRes(parsedOutput, context);
|
|
1353
|
-
case "MalformedArnException":
|
|
1354
|
-
case "com.amazonaws.ram#MalformedArnException":
|
|
1355
|
-
throw await de_MalformedArnExceptionRes(parsedOutput, context);
|
|
1356
|
-
case "OperationNotPermittedException":
|
|
1357
|
-
case "com.amazonaws.ram#OperationNotPermittedException":
|
|
1358
|
-
throw await de_OperationNotPermittedExceptionRes(parsedOutput, context);
|
|
1359
|
-
case "ServerInternalException":
|
|
1360
|
-
case "com.amazonaws.ram#ServerInternalException":
|
|
1361
|
-
throw await de_ServerInternalExceptionRes(parsedOutput, context);
|
|
1362
|
-
case "ServiceUnavailableException":
|
|
1363
|
-
case "com.amazonaws.ram#ServiceUnavailableException":
|
|
1364
|
-
throw await de_ServiceUnavailableExceptionRes(parsedOutput, context);
|
|
1365
|
-
case "UnknownResourceException":
|
|
1366
|
-
case "com.amazonaws.ram#UnknownResourceException":
|
|
1367
|
-
throw await de_UnknownResourceExceptionRes(parsedOutput, context);
|
|
1368
|
-
default:
|
|
1369
|
-
const parsedBody = parsedOutput.body;
|
|
1370
|
-
return throwDefaultError({
|
|
1371
|
-
output,
|
|
1372
|
-
parsedBody,
|
|
1373
|
-
errorCode,
|
|
1374
|
-
});
|
|
1375
|
-
}
|
|
1376
|
-
};
|
|
1377
765
|
export const de_GetResourceShareInvitationsCommand = async (output, context) => {
|
|
1378
766
|
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
1379
|
-
return
|
|
767
|
+
return de_CommandError(output, context);
|
|
1380
768
|
}
|
|
1381
769
|
const contents = map({
|
|
1382
770
|
$metadata: deserializeMetadata(output),
|
|
@@ -1389,49 +777,9 @@ export const de_GetResourceShareInvitationsCommand = async (output, context) =>
|
|
|
1389
777
|
Object.assign(contents, doc);
|
|
1390
778
|
return contents;
|
|
1391
779
|
};
|
|
1392
|
-
const de_GetResourceShareInvitationsCommandError = async (output, context) => {
|
|
1393
|
-
const parsedOutput = {
|
|
1394
|
-
...output,
|
|
1395
|
-
body: await parseErrorBody(output.body, context),
|
|
1396
|
-
};
|
|
1397
|
-
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1398
|
-
switch (errorCode) {
|
|
1399
|
-
case "InvalidMaxResultsException":
|
|
1400
|
-
case "com.amazonaws.ram#InvalidMaxResultsException":
|
|
1401
|
-
throw await de_InvalidMaxResultsExceptionRes(parsedOutput, context);
|
|
1402
|
-
case "InvalidNextTokenException":
|
|
1403
|
-
case "com.amazonaws.ram#InvalidNextTokenException":
|
|
1404
|
-
throw await de_InvalidNextTokenExceptionRes(parsedOutput, context);
|
|
1405
|
-
case "InvalidParameterException":
|
|
1406
|
-
case "com.amazonaws.ram#InvalidParameterException":
|
|
1407
|
-
throw await de_InvalidParameterExceptionRes(parsedOutput, context);
|
|
1408
|
-
case "MalformedArnException":
|
|
1409
|
-
case "com.amazonaws.ram#MalformedArnException":
|
|
1410
|
-
throw await de_MalformedArnExceptionRes(parsedOutput, context);
|
|
1411
|
-
case "ResourceShareInvitationArnNotFoundException":
|
|
1412
|
-
case "com.amazonaws.ram#ResourceShareInvitationArnNotFoundException":
|
|
1413
|
-
throw await de_ResourceShareInvitationArnNotFoundExceptionRes(parsedOutput, context);
|
|
1414
|
-
case "ServerInternalException":
|
|
1415
|
-
case "com.amazonaws.ram#ServerInternalException":
|
|
1416
|
-
throw await de_ServerInternalExceptionRes(parsedOutput, context);
|
|
1417
|
-
case "ServiceUnavailableException":
|
|
1418
|
-
case "com.amazonaws.ram#ServiceUnavailableException":
|
|
1419
|
-
throw await de_ServiceUnavailableExceptionRes(parsedOutput, context);
|
|
1420
|
-
case "UnknownResourceException":
|
|
1421
|
-
case "com.amazonaws.ram#UnknownResourceException":
|
|
1422
|
-
throw await de_UnknownResourceExceptionRes(parsedOutput, context);
|
|
1423
|
-
default:
|
|
1424
|
-
const parsedBody = parsedOutput.body;
|
|
1425
|
-
return throwDefaultError({
|
|
1426
|
-
output,
|
|
1427
|
-
parsedBody,
|
|
1428
|
-
errorCode,
|
|
1429
|
-
});
|
|
1430
|
-
}
|
|
1431
|
-
};
|
|
1432
780
|
export const de_GetResourceSharesCommand = async (output, context) => {
|
|
1433
781
|
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
1434
|
-
return
|
|
782
|
+
return de_CommandError(output, context);
|
|
1435
783
|
}
|
|
1436
784
|
const contents = map({
|
|
1437
785
|
$metadata: deserializeMetadata(output),
|
|
@@ -1444,43 +792,9 @@ export const de_GetResourceSharesCommand = async (output, context) => {
|
|
|
1444
792
|
Object.assign(contents, doc);
|
|
1445
793
|
return contents;
|
|
1446
794
|
};
|
|
1447
|
-
const de_GetResourceSharesCommandError = async (output, context) => {
|
|
1448
|
-
const parsedOutput = {
|
|
1449
|
-
...output,
|
|
1450
|
-
body: await parseErrorBody(output.body, context),
|
|
1451
|
-
};
|
|
1452
|
-
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1453
|
-
switch (errorCode) {
|
|
1454
|
-
case "InvalidNextTokenException":
|
|
1455
|
-
case "com.amazonaws.ram#InvalidNextTokenException":
|
|
1456
|
-
throw await de_InvalidNextTokenExceptionRes(parsedOutput, context);
|
|
1457
|
-
case "InvalidParameterException":
|
|
1458
|
-
case "com.amazonaws.ram#InvalidParameterException":
|
|
1459
|
-
throw await de_InvalidParameterExceptionRes(parsedOutput, context);
|
|
1460
|
-
case "MalformedArnException":
|
|
1461
|
-
case "com.amazonaws.ram#MalformedArnException":
|
|
1462
|
-
throw await de_MalformedArnExceptionRes(parsedOutput, context);
|
|
1463
|
-
case "ServerInternalException":
|
|
1464
|
-
case "com.amazonaws.ram#ServerInternalException":
|
|
1465
|
-
throw await de_ServerInternalExceptionRes(parsedOutput, context);
|
|
1466
|
-
case "ServiceUnavailableException":
|
|
1467
|
-
case "com.amazonaws.ram#ServiceUnavailableException":
|
|
1468
|
-
throw await de_ServiceUnavailableExceptionRes(parsedOutput, context);
|
|
1469
|
-
case "UnknownResourceException":
|
|
1470
|
-
case "com.amazonaws.ram#UnknownResourceException":
|
|
1471
|
-
throw await de_UnknownResourceExceptionRes(parsedOutput, context);
|
|
1472
|
-
default:
|
|
1473
|
-
const parsedBody = parsedOutput.body;
|
|
1474
|
-
return throwDefaultError({
|
|
1475
|
-
output,
|
|
1476
|
-
parsedBody,
|
|
1477
|
-
errorCode,
|
|
1478
|
-
});
|
|
1479
|
-
}
|
|
1480
|
-
};
|
|
1481
795
|
export const de_ListPendingInvitationResourcesCommand = async (output, context) => {
|
|
1482
796
|
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
1483
|
-
return
|
|
797
|
+
return de_CommandError(output, context);
|
|
1484
798
|
}
|
|
1485
799
|
const contents = map({
|
|
1486
800
|
$metadata: deserializeMetadata(output),
|
|
@@ -1493,52 +807,9 @@ export const de_ListPendingInvitationResourcesCommand = async (output, context)
|
|
|
1493
807
|
Object.assign(contents, doc);
|
|
1494
808
|
return contents;
|
|
1495
809
|
};
|
|
1496
|
-
const de_ListPendingInvitationResourcesCommandError = async (output, context) => {
|
|
1497
|
-
const parsedOutput = {
|
|
1498
|
-
...output,
|
|
1499
|
-
body: await parseErrorBody(output.body, context),
|
|
1500
|
-
};
|
|
1501
|
-
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1502
|
-
switch (errorCode) {
|
|
1503
|
-
case "InvalidNextTokenException":
|
|
1504
|
-
case "com.amazonaws.ram#InvalidNextTokenException":
|
|
1505
|
-
throw await de_InvalidNextTokenExceptionRes(parsedOutput, context);
|
|
1506
|
-
case "InvalidParameterException":
|
|
1507
|
-
case "com.amazonaws.ram#InvalidParameterException":
|
|
1508
|
-
throw await de_InvalidParameterExceptionRes(parsedOutput, context);
|
|
1509
|
-
case "MalformedArnException":
|
|
1510
|
-
case "com.amazonaws.ram#MalformedArnException":
|
|
1511
|
-
throw await de_MalformedArnExceptionRes(parsedOutput, context);
|
|
1512
|
-
case "MissingRequiredParameterException":
|
|
1513
|
-
case "com.amazonaws.ram#MissingRequiredParameterException":
|
|
1514
|
-
throw await de_MissingRequiredParameterExceptionRes(parsedOutput, context);
|
|
1515
|
-
case "ResourceShareInvitationAlreadyRejectedException":
|
|
1516
|
-
case "com.amazonaws.ram#ResourceShareInvitationAlreadyRejectedException":
|
|
1517
|
-
throw await de_ResourceShareInvitationAlreadyRejectedExceptionRes(parsedOutput, context);
|
|
1518
|
-
case "ResourceShareInvitationArnNotFoundException":
|
|
1519
|
-
case "com.amazonaws.ram#ResourceShareInvitationArnNotFoundException":
|
|
1520
|
-
throw await de_ResourceShareInvitationArnNotFoundExceptionRes(parsedOutput, context);
|
|
1521
|
-
case "ResourceShareInvitationExpiredException":
|
|
1522
|
-
case "com.amazonaws.ram#ResourceShareInvitationExpiredException":
|
|
1523
|
-
throw await de_ResourceShareInvitationExpiredExceptionRes(parsedOutput, context);
|
|
1524
|
-
case "ServerInternalException":
|
|
1525
|
-
case "com.amazonaws.ram#ServerInternalException":
|
|
1526
|
-
throw await de_ServerInternalExceptionRes(parsedOutput, context);
|
|
1527
|
-
case "ServiceUnavailableException":
|
|
1528
|
-
case "com.amazonaws.ram#ServiceUnavailableException":
|
|
1529
|
-
throw await de_ServiceUnavailableExceptionRes(parsedOutput, context);
|
|
1530
|
-
default:
|
|
1531
|
-
const parsedBody = parsedOutput.body;
|
|
1532
|
-
return throwDefaultError({
|
|
1533
|
-
output,
|
|
1534
|
-
parsedBody,
|
|
1535
|
-
errorCode,
|
|
1536
|
-
});
|
|
1537
|
-
}
|
|
1538
|
-
};
|
|
1539
810
|
export const de_ListPermissionAssociationsCommand = async (output, context) => {
|
|
1540
811
|
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
1541
|
-
return
|
|
812
|
+
return de_CommandError(output, context);
|
|
1542
813
|
}
|
|
1543
814
|
const contents = map({
|
|
1544
815
|
$metadata: deserializeMetadata(output),
|
|
@@ -1551,40 +822,24 @@ export const de_ListPermissionAssociationsCommand = async (output, context) => {
|
|
|
1551
822
|
Object.assign(contents, doc);
|
|
1552
823
|
return contents;
|
|
1553
824
|
};
|
|
1554
|
-
const
|
|
1555
|
-
|
|
1556
|
-
|
|
1557
|
-
body: await parseErrorBody(output.body, context),
|
|
1558
|
-
};
|
|
1559
|
-
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1560
|
-
switch (errorCode) {
|
|
1561
|
-
case "InvalidNextTokenException":
|
|
1562
|
-
case "com.amazonaws.ram#InvalidNextTokenException":
|
|
1563
|
-
throw await de_InvalidNextTokenExceptionRes(parsedOutput, context);
|
|
1564
|
-
case "InvalidParameterException":
|
|
1565
|
-
case "com.amazonaws.ram#InvalidParameterException":
|
|
1566
|
-
throw await de_InvalidParameterExceptionRes(parsedOutput, context);
|
|
1567
|
-
case "MalformedArnException":
|
|
1568
|
-
case "com.amazonaws.ram#MalformedArnException":
|
|
1569
|
-
throw await de_MalformedArnExceptionRes(parsedOutput, context);
|
|
1570
|
-
case "ServerInternalException":
|
|
1571
|
-
case "com.amazonaws.ram#ServerInternalException":
|
|
1572
|
-
throw await de_ServerInternalExceptionRes(parsedOutput, context);
|
|
1573
|
-
case "ServiceUnavailableException":
|
|
1574
|
-
case "com.amazonaws.ram#ServiceUnavailableException":
|
|
1575
|
-
throw await de_ServiceUnavailableExceptionRes(parsedOutput, context);
|
|
1576
|
-
default:
|
|
1577
|
-
const parsedBody = parsedOutput.body;
|
|
1578
|
-
return throwDefaultError({
|
|
1579
|
-
output,
|
|
1580
|
-
parsedBody,
|
|
1581
|
-
errorCode,
|
|
1582
|
-
});
|
|
825
|
+
export const de_ListPermissionsCommand = async (output, context) => {
|
|
826
|
+
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
827
|
+
return de_CommandError(output, context);
|
|
1583
828
|
}
|
|
829
|
+
const contents = map({
|
|
830
|
+
$metadata: deserializeMetadata(output),
|
|
831
|
+
});
|
|
832
|
+
const data = __expectNonNull(__expectObject(await parseBody(output.body, context)), "body");
|
|
833
|
+
const doc = take(data, {
|
|
834
|
+
nextToken: __expectString,
|
|
835
|
+
permissions: (_) => de_ResourceSharePermissionList(_, context),
|
|
836
|
+
});
|
|
837
|
+
Object.assign(contents, doc);
|
|
838
|
+
return contents;
|
|
1584
839
|
};
|
|
1585
|
-
export const
|
|
840
|
+
export const de_ListPermissionVersionsCommand = async (output, context) => {
|
|
1586
841
|
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
1587
|
-
return
|
|
842
|
+
return de_CommandError(output, context);
|
|
1588
843
|
}
|
|
1589
844
|
const contents = map({
|
|
1590
845
|
$metadata: deserializeMetadata(output),
|
|
@@ -1597,92 +852,9 @@ export const de_ListPermissionsCommand = async (output, context) => {
|
|
|
1597
852
|
Object.assign(contents, doc);
|
|
1598
853
|
return contents;
|
|
1599
854
|
};
|
|
1600
|
-
const de_ListPermissionsCommandError = async (output, context) => {
|
|
1601
|
-
const parsedOutput = {
|
|
1602
|
-
...output,
|
|
1603
|
-
body: await parseErrorBody(output.body, context),
|
|
1604
|
-
};
|
|
1605
|
-
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1606
|
-
switch (errorCode) {
|
|
1607
|
-
case "InvalidNextTokenException":
|
|
1608
|
-
case "com.amazonaws.ram#InvalidNextTokenException":
|
|
1609
|
-
throw await de_InvalidNextTokenExceptionRes(parsedOutput, context);
|
|
1610
|
-
case "InvalidParameterException":
|
|
1611
|
-
case "com.amazonaws.ram#InvalidParameterException":
|
|
1612
|
-
throw await de_InvalidParameterExceptionRes(parsedOutput, context);
|
|
1613
|
-
case "OperationNotPermittedException":
|
|
1614
|
-
case "com.amazonaws.ram#OperationNotPermittedException":
|
|
1615
|
-
throw await de_OperationNotPermittedExceptionRes(parsedOutput, context);
|
|
1616
|
-
case "ServerInternalException":
|
|
1617
|
-
case "com.amazonaws.ram#ServerInternalException":
|
|
1618
|
-
throw await de_ServerInternalExceptionRes(parsedOutput, context);
|
|
1619
|
-
case "ServiceUnavailableException":
|
|
1620
|
-
case "com.amazonaws.ram#ServiceUnavailableException":
|
|
1621
|
-
throw await de_ServiceUnavailableExceptionRes(parsedOutput, context);
|
|
1622
|
-
default:
|
|
1623
|
-
const parsedBody = parsedOutput.body;
|
|
1624
|
-
return throwDefaultError({
|
|
1625
|
-
output,
|
|
1626
|
-
parsedBody,
|
|
1627
|
-
errorCode,
|
|
1628
|
-
});
|
|
1629
|
-
}
|
|
1630
|
-
};
|
|
1631
|
-
export const de_ListPermissionVersionsCommand = async (output, context) => {
|
|
1632
|
-
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
1633
|
-
return de_ListPermissionVersionsCommandError(output, context);
|
|
1634
|
-
}
|
|
1635
|
-
const contents = map({
|
|
1636
|
-
$metadata: deserializeMetadata(output),
|
|
1637
|
-
});
|
|
1638
|
-
const data = __expectNonNull(__expectObject(await parseBody(output.body, context)), "body");
|
|
1639
|
-
const doc = take(data, {
|
|
1640
|
-
nextToken: __expectString,
|
|
1641
|
-
permissions: (_) => de_ResourceSharePermissionList(_, context),
|
|
1642
|
-
});
|
|
1643
|
-
Object.assign(contents, doc);
|
|
1644
|
-
return contents;
|
|
1645
|
-
};
|
|
1646
|
-
const de_ListPermissionVersionsCommandError = async (output, context) => {
|
|
1647
|
-
const parsedOutput = {
|
|
1648
|
-
...output,
|
|
1649
|
-
body: await parseErrorBody(output.body, context),
|
|
1650
|
-
};
|
|
1651
|
-
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1652
|
-
switch (errorCode) {
|
|
1653
|
-
case "InvalidNextTokenException":
|
|
1654
|
-
case "com.amazonaws.ram#InvalidNextTokenException":
|
|
1655
|
-
throw await de_InvalidNextTokenExceptionRes(parsedOutput, context);
|
|
1656
|
-
case "InvalidParameterException":
|
|
1657
|
-
case "com.amazonaws.ram#InvalidParameterException":
|
|
1658
|
-
throw await de_InvalidParameterExceptionRes(parsedOutput, context);
|
|
1659
|
-
case "MalformedArnException":
|
|
1660
|
-
case "com.amazonaws.ram#MalformedArnException":
|
|
1661
|
-
throw await de_MalformedArnExceptionRes(parsedOutput, context);
|
|
1662
|
-
case "OperationNotPermittedException":
|
|
1663
|
-
case "com.amazonaws.ram#OperationNotPermittedException":
|
|
1664
|
-
throw await de_OperationNotPermittedExceptionRes(parsedOutput, context);
|
|
1665
|
-
case "ServerInternalException":
|
|
1666
|
-
case "com.amazonaws.ram#ServerInternalException":
|
|
1667
|
-
throw await de_ServerInternalExceptionRes(parsedOutput, context);
|
|
1668
|
-
case "ServiceUnavailableException":
|
|
1669
|
-
case "com.amazonaws.ram#ServiceUnavailableException":
|
|
1670
|
-
throw await de_ServiceUnavailableExceptionRes(parsedOutput, context);
|
|
1671
|
-
case "UnknownResourceException":
|
|
1672
|
-
case "com.amazonaws.ram#UnknownResourceException":
|
|
1673
|
-
throw await de_UnknownResourceExceptionRes(parsedOutput, context);
|
|
1674
|
-
default:
|
|
1675
|
-
const parsedBody = parsedOutput.body;
|
|
1676
|
-
return throwDefaultError({
|
|
1677
|
-
output,
|
|
1678
|
-
parsedBody,
|
|
1679
|
-
errorCode,
|
|
1680
|
-
});
|
|
1681
|
-
}
|
|
1682
|
-
};
|
|
1683
855
|
export const de_ListPrincipalsCommand = async (output, context) => {
|
|
1684
856
|
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
1685
|
-
return
|
|
857
|
+
return de_CommandError(output, context);
|
|
1686
858
|
}
|
|
1687
859
|
const contents = map({
|
|
1688
860
|
$metadata: deserializeMetadata(output),
|
|
@@ -1695,43 +867,9 @@ export const de_ListPrincipalsCommand = async (output, context) => {
|
|
|
1695
867
|
Object.assign(contents, doc);
|
|
1696
868
|
return contents;
|
|
1697
869
|
};
|
|
1698
|
-
const de_ListPrincipalsCommandError = async (output, context) => {
|
|
1699
|
-
const parsedOutput = {
|
|
1700
|
-
...output,
|
|
1701
|
-
body: await parseErrorBody(output.body, context),
|
|
1702
|
-
};
|
|
1703
|
-
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1704
|
-
switch (errorCode) {
|
|
1705
|
-
case "InvalidNextTokenException":
|
|
1706
|
-
case "com.amazonaws.ram#InvalidNextTokenException":
|
|
1707
|
-
throw await de_InvalidNextTokenExceptionRes(parsedOutput, context);
|
|
1708
|
-
case "InvalidParameterException":
|
|
1709
|
-
case "com.amazonaws.ram#InvalidParameterException":
|
|
1710
|
-
throw await de_InvalidParameterExceptionRes(parsedOutput, context);
|
|
1711
|
-
case "MalformedArnException":
|
|
1712
|
-
case "com.amazonaws.ram#MalformedArnException":
|
|
1713
|
-
throw await de_MalformedArnExceptionRes(parsedOutput, context);
|
|
1714
|
-
case "ServerInternalException":
|
|
1715
|
-
case "com.amazonaws.ram#ServerInternalException":
|
|
1716
|
-
throw await de_ServerInternalExceptionRes(parsedOutput, context);
|
|
1717
|
-
case "ServiceUnavailableException":
|
|
1718
|
-
case "com.amazonaws.ram#ServiceUnavailableException":
|
|
1719
|
-
throw await de_ServiceUnavailableExceptionRes(parsedOutput, context);
|
|
1720
|
-
case "UnknownResourceException":
|
|
1721
|
-
case "com.amazonaws.ram#UnknownResourceException":
|
|
1722
|
-
throw await de_UnknownResourceExceptionRes(parsedOutput, context);
|
|
1723
|
-
default:
|
|
1724
|
-
const parsedBody = parsedOutput.body;
|
|
1725
|
-
return throwDefaultError({
|
|
1726
|
-
output,
|
|
1727
|
-
parsedBody,
|
|
1728
|
-
errorCode,
|
|
1729
|
-
});
|
|
1730
|
-
}
|
|
1731
|
-
};
|
|
1732
870
|
export const de_ListReplacePermissionAssociationsWorkCommand = async (output, context) => {
|
|
1733
871
|
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
1734
|
-
return
|
|
872
|
+
return de_CommandError(output, context);
|
|
1735
873
|
}
|
|
1736
874
|
const contents = map({
|
|
1737
875
|
$metadata: deserializeMetadata(output),
|
|
@@ -1744,37 +882,9 @@ export const de_ListReplacePermissionAssociationsWorkCommand = async (output, co
|
|
|
1744
882
|
Object.assign(contents, doc);
|
|
1745
883
|
return contents;
|
|
1746
884
|
};
|
|
1747
|
-
const de_ListReplacePermissionAssociationsWorkCommandError = async (output, context) => {
|
|
1748
|
-
const parsedOutput = {
|
|
1749
|
-
...output,
|
|
1750
|
-
body: await parseErrorBody(output.body, context),
|
|
1751
|
-
};
|
|
1752
|
-
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1753
|
-
switch (errorCode) {
|
|
1754
|
-
case "InvalidNextTokenException":
|
|
1755
|
-
case "com.amazonaws.ram#InvalidNextTokenException":
|
|
1756
|
-
throw await de_InvalidNextTokenExceptionRes(parsedOutput, context);
|
|
1757
|
-
case "InvalidParameterException":
|
|
1758
|
-
case "com.amazonaws.ram#InvalidParameterException":
|
|
1759
|
-
throw await de_InvalidParameterExceptionRes(parsedOutput, context);
|
|
1760
|
-
case "ServerInternalException":
|
|
1761
|
-
case "com.amazonaws.ram#ServerInternalException":
|
|
1762
|
-
throw await de_ServerInternalExceptionRes(parsedOutput, context);
|
|
1763
|
-
case "ServiceUnavailableException":
|
|
1764
|
-
case "com.amazonaws.ram#ServiceUnavailableException":
|
|
1765
|
-
throw await de_ServiceUnavailableExceptionRes(parsedOutput, context);
|
|
1766
|
-
default:
|
|
1767
|
-
const parsedBody = parsedOutput.body;
|
|
1768
|
-
return throwDefaultError({
|
|
1769
|
-
output,
|
|
1770
|
-
parsedBody,
|
|
1771
|
-
errorCode,
|
|
1772
|
-
});
|
|
1773
|
-
}
|
|
1774
|
-
};
|
|
1775
885
|
export const de_ListResourcesCommand = async (output, context) => {
|
|
1776
886
|
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
1777
|
-
return
|
|
887
|
+
return de_CommandError(output, context);
|
|
1778
888
|
}
|
|
1779
889
|
const contents = map({
|
|
1780
890
|
$metadata: deserializeMetadata(output),
|
|
@@ -1787,46 +897,9 @@ export const de_ListResourcesCommand = async (output, context) => {
|
|
|
1787
897
|
Object.assign(contents, doc);
|
|
1788
898
|
return contents;
|
|
1789
899
|
};
|
|
1790
|
-
const de_ListResourcesCommandError = async (output, context) => {
|
|
1791
|
-
const parsedOutput = {
|
|
1792
|
-
...output,
|
|
1793
|
-
body: await parseErrorBody(output.body, context),
|
|
1794
|
-
};
|
|
1795
|
-
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1796
|
-
switch (errorCode) {
|
|
1797
|
-
case "InvalidNextTokenException":
|
|
1798
|
-
case "com.amazonaws.ram#InvalidNextTokenException":
|
|
1799
|
-
throw await de_InvalidNextTokenExceptionRes(parsedOutput, context);
|
|
1800
|
-
case "InvalidParameterException":
|
|
1801
|
-
case "com.amazonaws.ram#InvalidParameterException":
|
|
1802
|
-
throw await de_InvalidParameterExceptionRes(parsedOutput, context);
|
|
1803
|
-
case "InvalidResourceTypeException":
|
|
1804
|
-
case "com.amazonaws.ram#InvalidResourceTypeException":
|
|
1805
|
-
throw await de_InvalidResourceTypeExceptionRes(parsedOutput, context);
|
|
1806
|
-
case "MalformedArnException":
|
|
1807
|
-
case "com.amazonaws.ram#MalformedArnException":
|
|
1808
|
-
throw await de_MalformedArnExceptionRes(parsedOutput, context);
|
|
1809
|
-
case "ServerInternalException":
|
|
1810
|
-
case "com.amazonaws.ram#ServerInternalException":
|
|
1811
|
-
throw await de_ServerInternalExceptionRes(parsedOutput, context);
|
|
1812
|
-
case "ServiceUnavailableException":
|
|
1813
|
-
case "com.amazonaws.ram#ServiceUnavailableException":
|
|
1814
|
-
throw await de_ServiceUnavailableExceptionRes(parsedOutput, context);
|
|
1815
|
-
case "UnknownResourceException":
|
|
1816
|
-
case "com.amazonaws.ram#UnknownResourceException":
|
|
1817
|
-
throw await de_UnknownResourceExceptionRes(parsedOutput, context);
|
|
1818
|
-
default:
|
|
1819
|
-
const parsedBody = parsedOutput.body;
|
|
1820
|
-
return throwDefaultError({
|
|
1821
|
-
output,
|
|
1822
|
-
parsedBody,
|
|
1823
|
-
errorCode,
|
|
1824
|
-
});
|
|
1825
|
-
}
|
|
1826
|
-
};
|
|
1827
900
|
export const de_ListResourceSharePermissionsCommand = async (output, context) => {
|
|
1828
901
|
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
1829
|
-
return
|
|
902
|
+
return de_CommandError(output, context);
|
|
1830
903
|
}
|
|
1831
904
|
const contents = map({
|
|
1832
905
|
$metadata: deserializeMetadata(output),
|
|
@@ -1839,46 +912,9 @@ export const de_ListResourceSharePermissionsCommand = async (output, context) =>
|
|
|
1839
912
|
Object.assign(contents, doc);
|
|
1840
913
|
return contents;
|
|
1841
914
|
};
|
|
1842
|
-
const de_ListResourceSharePermissionsCommandError = async (output, context) => {
|
|
1843
|
-
const parsedOutput = {
|
|
1844
|
-
...output,
|
|
1845
|
-
body: await parseErrorBody(output.body, context),
|
|
1846
|
-
};
|
|
1847
|
-
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1848
|
-
switch (errorCode) {
|
|
1849
|
-
case "InvalidNextTokenException":
|
|
1850
|
-
case "com.amazonaws.ram#InvalidNextTokenException":
|
|
1851
|
-
throw await de_InvalidNextTokenExceptionRes(parsedOutput, context);
|
|
1852
|
-
case "InvalidParameterException":
|
|
1853
|
-
case "com.amazonaws.ram#InvalidParameterException":
|
|
1854
|
-
throw await de_InvalidParameterExceptionRes(parsedOutput, context);
|
|
1855
|
-
case "MalformedArnException":
|
|
1856
|
-
case "com.amazonaws.ram#MalformedArnException":
|
|
1857
|
-
throw await de_MalformedArnExceptionRes(parsedOutput, context);
|
|
1858
|
-
case "OperationNotPermittedException":
|
|
1859
|
-
case "com.amazonaws.ram#OperationNotPermittedException":
|
|
1860
|
-
throw await de_OperationNotPermittedExceptionRes(parsedOutput, context);
|
|
1861
|
-
case "ServerInternalException":
|
|
1862
|
-
case "com.amazonaws.ram#ServerInternalException":
|
|
1863
|
-
throw await de_ServerInternalExceptionRes(parsedOutput, context);
|
|
1864
|
-
case "ServiceUnavailableException":
|
|
1865
|
-
case "com.amazonaws.ram#ServiceUnavailableException":
|
|
1866
|
-
throw await de_ServiceUnavailableExceptionRes(parsedOutput, context);
|
|
1867
|
-
case "UnknownResourceException":
|
|
1868
|
-
case "com.amazonaws.ram#UnknownResourceException":
|
|
1869
|
-
throw await de_UnknownResourceExceptionRes(parsedOutput, context);
|
|
1870
|
-
default:
|
|
1871
|
-
const parsedBody = parsedOutput.body;
|
|
1872
|
-
return throwDefaultError({
|
|
1873
|
-
output,
|
|
1874
|
-
parsedBody,
|
|
1875
|
-
errorCode,
|
|
1876
|
-
});
|
|
1877
|
-
}
|
|
1878
|
-
};
|
|
1879
915
|
export const de_ListResourceTypesCommand = async (output, context) => {
|
|
1880
916
|
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
1881
|
-
return
|
|
917
|
+
return de_CommandError(output, context);
|
|
1882
918
|
}
|
|
1883
919
|
const contents = map({
|
|
1884
920
|
$metadata: deserializeMetadata(output),
|
|
@@ -1887,214 +923,42 @@ export const de_ListResourceTypesCommand = async (output, context) => {
|
|
|
1887
923
|
const doc = take(data, {
|
|
1888
924
|
nextToken: __expectString,
|
|
1889
925
|
resourceTypes: _json,
|
|
1890
|
-
});
|
|
1891
|
-
Object.assign(contents, doc);
|
|
1892
|
-
return contents;
|
|
1893
|
-
};
|
|
1894
|
-
const
|
|
1895
|
-
|
|
1896
|
-
|
|
1897
|
-
|
|
1898
|
-
|
|
1899
|
-
|
|
1900
|
-
|
|
1901
|
-
|
|
1902
|
-
|
|
1903
|
-
|
|
1904
|
-
|
|
1905
|
-
|
|
1906
|
-
|
|
1907
|
-
|
|
1908
|
-
|
|
1909
|
-
|
|
1910
|
-
|
|
1911
|
-
|
|
1912
|
-
throw await de_ServiceUnavailableExceptionRes(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_PromotePermissionCreatedFromPolicyCommand = async (output, context) => {
|
|
1923
|
-
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
1924
|
-
return de_PromotePermissionCreatedFromPolicyCommandError(output, context);
|
|
1925
|
-
}
|
|
1926
|
-
const contents = map({
|
|
1927
|
-
$metadata: deserializeMetadata(output),
|
|
1928
|
-
});
|
|
1929
|
-
const data = __expectNonNull(__expectObject(await parseBody(output.body, context)), "body");
|
|
1930
|
-
const doc = take(data, {
|
|
1931
|
-
clientToken: __expectString,
|
|
1932
|
-
permission: (_) => de_ResourceSharePermissionSummary(_, context),
|
|
1933
|
-
});
|
|
1934
|
-
Object.assign(contents, doc);
|
|
1935
|
-
return contents;
|
|
1936
|
-
};
|
|
1937
|
-
const de_PromotePermissionCreatedFromPolicyCommandError = async (output, context) => {
|
|
1938
|
-
const parsedOutput = {
|
|
1939
|
-
...output,
|
|
1940
|
-
body: await parseErrorBody(output.body, context),
|
|
1941
|
-
};
|
|
1942
|
-
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1943
|
-
switch (errorCode) {
|
|
1944
|
-
case "InvalidParameterException":
|
|
1945
|
-
case "com.amazonaws.ram#InvalidParameterException":
|
|
1946
|
-
throw await de_InvalidParameterExceptionRes(parsedOutput, context);
|
|
1947
|
-
case "MalformedArnException":
|
|
1948
|
-
case "com.amazonaws.ram#MalformedArnException":
|
|
1949
|
-
throw await de_MalformedArnExceptionRes(parsedOutput, context);
|
|
1950
|
-
case "MissingRequiredParameterException":
|
|
1951
|
-
case "com.amazonaws.ram#MissingRequiredParameterException":
|
|
1952
|
-
throw await de_MissingRequiredParameterExceptionRes(parsedOutput, context);
|
|
1953
|
-
case "OperationNotPermittedException":
|
|
1954
|
-
case "com.amazonaws.ram#OperationNotPermittedException":
|
|
1955
|
-
throw await de_OperationNotPermittedExceptionRes(parsedOutput, context);
|
|
1956
|
-
case "ServerInternalException":
|
|
1957
|
-
case "com.amazonaws.ram#ServerInternalException":
|
|
1958
|
-
throw await de_ServerInternalExceptionRes(parsedOutput, context);
|
|
1959
|
-
case "ServiceUnavailableException":
|
|
1960
|
-
case "com.amazonaws.ram#ServiceUnavailableException":
|
|
1961
|
-
throw await de_ServiceUnavailableExceptionRes(parsedOutput, context);
|
|
1962
|
-
case "UnknownResourceException":
|
|
1963
|
-
case "com.amazonaws.ram#UnknownResourceException":
|
|
1964
|
-
throw await de_UnknownResourceExceptionRes(parsedOutput, context);
|
|
1965
|
-
default:
|
|
1966
|
-
const parsedBody = parsedOutput.body;
|
|
1967
|
-
return throwDefaultError({
|
|
1968
|
-
output,
|
|
1969
|
-
parsedBody,
|
|
1970
|
-
errorCode,
|
|
1971
|
-
});
|
|
1972
|
-
}
|
|
1973
|
-
};
|
|
1974
|
-
export const de_PromoteResourceShareCreatedFromPolicyCommand = async (output, context) => {
|
|
1975
|
-
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
1976
|
-
return de_PromoteResourceShareCreatedFromPolicyCommandError(output, context);
|
|
1977
|
-
}
|
|
1978
|
-
const contents = map({
|
|
1979
|
-
$metadata: deserializeMetadata(output),
|
|
1980
|
-
});
|
|
1981
|
-
const data = __expectNonNull(__expectObject(await parseBody(output.body, context)), "body");
|
|
1982
|
-
const doc = take(data, {
|
|
1983
|
-
returnValue: __expectBoolean,
|
|
1984
|
-
});
|
|
1985
|
-
Object.assign(contents, doc);
|
|
1986
|
-
return contents;
|
|
1987
|
-
};
|
|
1988
|
-
const de_PromoteResourceShareCreatedFromPolicyCommandError = async (output, context) => {
|
|
1989
|
-
const parsedOutput = {
|
|
1990
|
-
...output,
|
|
1991
|
-
body: await parseErrorBody(output.body, context),
|
|
1992
|
-
};
|
|
1993
|
-
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1994
|
-
switch (errorCode) {
|
|
1995
|
-
case "InvalidParameterException":
|
|
1996
|
-
case "com.amazonaws.ram#InvalidParameterException":
|
|
1997
|
-
throw await de_InvalidParameterExceptionRes(parsedOutput, context);
|
|
1998
|
-
case "InvalidStateTransitionException":
|
|
1999
|
-
case "com.amazonaws.ram#InvalidStateTransitionException":
|
|
2000
|
-
throw await de_InvalidStateTransitionExceptionRes(parsedOutput, context);
|
|
2001
|
-
case "MalformedArnException":
|
|
2002
|
-
case "com.amazonaws.ram#MalformedArnException":
|
|
2003
|
-
throw await de_MalformedArnExceptionRes(parsedOutput, context);
|
|
2004
|
-
case "MissingRequiredParameterException":
|
|
2005
|
-
case "com.amazonaws.ram#MissingRequiredParameterException":
|
|
2006
|
-
throw await de_MissingRequiredParameterExceptionRes(parsedOutput, context);
|
|
2007
|
-
case "OperationNotPermittedException":
|
|
2008
|
-
case "com.amazonaws.ram#OperationNotPermittedException":
|
|
2009
|
-
throw await de_OperationNotPermittedExceptionRes(parsedOutput, context);
|
|
2010
|
-
case "ResourceShareLimitExceededException":
|
|
2011
|
-
case "com.amazonaws.ram#ResourceShareLimitExceededException":
|
|
2012
|
-
throw await de_ResourceShareLimitExceededExceptionRes(parsedOutput, context);
|
|
2013
|
-
case "ServerInternalException":
|
|
2014
|
-
case "com.amazonaws.ram#ServerInternalException":
|
|
2015
|
-
throw await de_ServerInternalExceptionRes(parsedOutput, context);
|
|
2016
|
-
case "ServiceUnavailableException":
|
|
2017
|
-
case "com.amazonaws.ram#ServiceUnavailableException":
|
|
2018
|
-
throw await de_ServiceUnavailableExceptionRes(parsedOutput, context);
|
|
2019
|
-
case "UnknownResourceException":
|
|
2020
|
-
case "com.amazonaws.ram#UnknownResourceException":
|
|
2021
|
-
throw await de_UnknownResourceExceptionRes(parsedOutput, context);
|
|
2022
|
-
case "UnmatchedPolicyPermissionException":
|
|
2023
|
-
case "com.amazonaws.ram#UnmatchedPolicyPermissionException":
|
|
2024
|
-
throw await de_UnmatchedPolicyPermissionExceptionRes(parsedOutput, context);
|
|
2025
|
-
default:
|
|
2026
|
-
const parsedBody = parsedOutput.body;
|
|
2027
|
-
return throwDefaultError({
|
|
2028
|
-
output,
|
|
2029
|
-
parsedBody,
|
|
2030
|
-
errorCode,
|
|
2031
|
-
});
|
|
2032
|
-
}
|
|
2033
|
-
};
|
|
2034
|
-
export const de_RejectResourceShareInvitationCommand = async (output, context) => {
|
|
2035
|
-
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
2036
|
-
return de_RejectResourceShareInvitationCommandError(output, context);
|
|
2037
|
-
}
|
|
2038
|
-
const contents = map({
|
|
2039
|
-
$metadata: deserializeMetadata(output),
|
|
2040
|
-
});
|
|
2041
|
-
const data = __expectNonNull(__expectObject(await parseBody(output.body, context)), "body");
|
|
2042
|
-
const doc = take(data, {
|
|
2043
|
-
clientToken: __expectString,
|
|
2044
|
-
resourceShareInvitation: (_) => de_ResourceShareInvitation(_, context),
|
|
2045
|
-
});
|
|
2046
|
-
Object.assign(contents, doc);
|
|
2047
|
-
return contents;
|
|
2048
|
-
};
|
|
2049
|
-
const de_RejectResourceShareInvitationCommandError = async (output, context) => {
|
|
2050
|
-
const parsedOutput = {
|
|
2051
|
-
...output,
|
|
2052
|
-
body: await parseErrorBody(output.body, context),
|
|
2053
|
-
};
|
|
2054
|
-
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
2055
|
-
switch (errorCode) {
|
|
2056
|
-
case "IdempotentParameterMismatchException":
|
|
2057
|
-
case "com.amazonaws.ram#IdempotentParameterMismatchException":
|
|
2058
|
-
throw await de_IdempotentParameterMismatchExceptionRes(parsedOutput, context);
|
|
2059
|
-
case "InvalidClientTokenException":
|
|
2060
|
-
case "com.amazonaws.ram#InvalidClientTokenException":
|
|
2061
|
-
throw await de_InvalidClientTokenExceptionRes(parsedOutput, context);
|
|
2062
|
-
case "MalformedArnException":
|
|
2063
|
-
case "com.amazonaws.ram#MalformedArnException":
|
|
2064
|
-
throw await de_MalformedArnExceptionRes(parsedOutput, context);
|
|
2065
|
-
case "OperationNotPermittedException":
|
|
2066
|
-
case "com.amazonaws.ram#OperationNotPermittedException":
|
|
2067
|
-
throw await de_OperationNotPermittedExceptionRes(parsedOutput, context);
|
|
2068
|
-
case "ResourceShareInvitationAlreadyAcceptedException":
|
|
2069
|
-
case "com.amazonaws.ram#ResourceShareInvitationAlreadyAcceptedException":
|
|
2070
|
-
throw await de_ResourceShareInvitationAlreadyAcceptedExceptionRes(parsedOutput, context);
|
|
2071
|
-
case "ResourceShareInvitationAlreadyRejectedException":
|
|
2072
|
-
case "com.amazonaws.ram#ResourceShareInvitationAlreadyRejectedException":
|
|
2073
|
-
throw await de_ResourceShareInvitationAlreadyRejectedExceptionRes(parsedOutput, context);
|
|
2074
|
-
case "ResourceShareInvitationArnNotFoundException":
|
|
2075
|
-
case "com.amazonaws.ram#ResourceShareInvitationArnNotFoundException":
|
|
2076
|
-
throw await de_ResourceShareInvitationArnNotFoundExceptionRes(parsedOutput, context);
|
|
2077
|
-
case "ResourceShareInvitationExpiredException":
|
|
2078
|
-
case "com.amazonaws.ram#ResourceShareInvitationExpiredException":
|
|
2079
|
-
throw await de_ResourceShareInvitationExpiredExceptionRes(parsedOutput, context);
|
|
2080
|
-
case "ServerInternalException":
|
|
2081
|
-
case "com.amazonaws.ram#ServerInternalException":
|
|
2082
|
-
throw await de_ServerInternalExceptionRes(parsedOutput, context);
|
|
2083
|
-
case "ServiceUnavailableException":
|
|
2084
|
-
case "com.amazonaws.ram#ServiceUnavailableException":
|
|
2085
|
-
throw await de_ServiceUnavailableExceptionRes(parsedOutput, context);
|
|
2086
|
-
default:
|
|
2087
|
-
const parsedBody = parsedOutput.body;
|
|
2088
|
-
return throwDefaultError({
|
|
2089
|
-
output,
|
|
2090
|
-
parsedBody,
|
|
2091
|
-
errorCode,
|
|
2092
|
-
});
|
|
926
|
+
});
|
|
927
|
+
Object.assign(contents, doc);
|
|
928
|
+
return contents;
|
|
929
|
+
};
|
|
930
|
+
export const de_PromotePermissionCreatedFromPolicyCommand = async (output, context) => {
|
|
931
|
+
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
932
|
+
return de_CommandError(output, context);
|
|
933
|
+
}
|
|
934
|
+
const contents = map({
|
|
935
|
+
$metadata: deserializeMetadata(output),
|
|
936
|
+
});
|
|
937
|
+
const data = __expectNonNull(__expectObject(await parseBody(output.body, context)), "body");
|
|
938
|
+
const doc = take(data, {
|
|
939
|
+
clientToken: __expectString,
|
|
940
|
+
permission: (_) => de_ResourceSharePermissionSummary(_, context),
|
|
941
|
+
});
|
|
942
|
+
Object.assign(contents, doc);
|
|
943
|
+
return contents;
|
|
944
|
+
};
|
|
945
|
+
export const de_PromoteResourceShareCreatedFromPolicyCommand = async (output, context) => {
|
|
946
|
+
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
947
|
+
return de_CommandError(output, context);
|
|
2093
948
|
}
|
|
949
|
+
const contents = map({
|
|
950
|
+
$metadata: deserializeMetadata(output),
|
|
951
|
+
});
|
|
952
|
+
const data = __expectNonNull(__expectObject(await parseBody(output.body, context)), "body");
|
|
953
|
+
const doc = take(data, {
|
|
954
|
+
returnValue: __expectBoolean,
|
|
955
|
+
});
|
|
956
|
+
Object.assign(contents, doc);
|
|
957
|
+
return contents;
|
|
2094
958
|
};
|
|
2095
|
-
export const
|
|
959
|
+
export const de_RejectResourceShareInvitationCommand = async (output, context) => {
|
|
2096
960
|
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
2097
|
-
return
|
|
961
|
+
return de_CommandError(output, context);
|
|
2098
962
|
}
|
|
2099
963
|
const contents = map({
|
|
2100
964
|
$metadata: deserializeMetadata(output),
|
|
@@ -2102,54 +966,29 @@ export const de_ReplacePermissionAssociationsCommand = async (output, context) =
|
|
|
2102
966
|
const data = __expectNonNull(__expectObject(await parseBody(output.body, context)), "body");
|
|
2103
967
|
const doc = take(data, {
|
|
2104
968
|
clientToken: __expectString,
|
|
2105
|
-
|
|
969
|
+
resourceShareInvitation: (_) => de_ResourceShareInvitation(_, context),
|
|
2106
970
|
});
|
|
2107
971
|
Object.assign(contents, doc);
|
|
2108
972
|
return contents;
|
|
2109
973
|
};
|
|
2110
|
-
const
|
|
2111
|
-
|
|
2112
|
-
|
|
2113
|
-
body: await parseErrorBody(output.body, context),
|
|
2114
|
-
};
|
|
2115
|
-
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
2116
|
-
switch (errorCode) {
|
|
2117
|
-
case "IdempotentParameterMismatchException":
|
|
2118
|
-
case "com.amazonaws.ram#IdempotentParameterMismatchException":
|
|
2119
|
-
throw await de_IdempotentParameterMismatchExceptionRes(parsedOutput, context);
|
|
2120
|
-
case "InvalidClientTokenException":
|
|
2121
|
-
case "com.amazonaws.ram#InvalidClientTokenException":
|
|
2122
|
-
throw await de_InvalidClientTokenExceptionRes(parsedOutput, context);
|
|
2123
|
-
case "InvalidParameterException":
|
|
2124
|
-
case "com.amazonaws.ram#InvalidParameterException":
|
|
2125
|
-
throw await de_InvalidParameterExceptionRes(parsedOutput, context);
|
|
2126
|
-
case "MalformedArnException":
|
|
2127
|
-
case "com.amazonaws.ram#MalformedArnException":
|
|
2128
|
-
throw await de_MalformedArnExceptionRes(parsedOutput, context);
|
|
2129
|
-
case "OperationNotPermittedException":
|
|
2130
|
-
case "com.amazonaws.ram#OperationNotPermittedException":
|
|
2131
|
-
throw await de_OperationNotPermittedExceptionRes(parsedOutput, context);
|
|
2132
|
-
case "ServerInternalException":
|
|
2133
|
-
case "com.amazonaws.ram#ServerInternalException":
|
|
2134
|
-
throw await de_ServerInternalExceptionRes(parsedOutput, context);
|
|
2135
|
-
case "ServiceUnavailableException":
|
|
2136
|
-
case "com.amazonaws.ram#ServiceUnavailableException":
|
|
2137
|
-
throw await de_ServiceUnavailableExceptionRes(parsedOutput, context);
|
|
2138
|
-
case "UnknownResourceException":
|
|
2139
|
-
case "com.amazonaws.ram#UnknownResourceException":
|
|
2140
|
-
throw await de_UnknownResourceExceptionRes(parsedOutput, context);
|
|
2141
|
-
default:
|
|
2142
|
-
const parsedBody = parsedOutput.body;
|
|
2143
|
-
return throwDefaultError({
|
|
2144
|
-
output,
|
|
2145
|
-
parsedBody,
|
|
2146
|
-
errorCode,
|
|
2147
|
-
});
|
|
974
|
+
export const de_ReplacePermissionAssociationsCommand = async (output, context) => {
|
|
975
|
+
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
976
|
+
return de_CommandError(output, context);
|
|
2148
977
|
}
|
|
978
|
+
const contents = map({
|
|
979
|
+
$metadata: deserializeMetadata(output),
|
|
980
|
+
});
|
|
981
|
+
const data = __expectNonNull(__expectObject(await parseBody(output.body, context)), "body");
|
|
982
|
+
const doc = take(data, {
|
|
983
|
+
clientToken: __expectString,
|
|
984
|
+
replacePermissionAssociationsWork: (_) => de_ReplacePermissionAssociationsWork(_, context),
|
|
985
|
+
});
|
|
986
|
+
Object.assign(contents, doc);
|
|
987
|
+
return contents;
|
|
2149
988
|
};
|
|
2150
989
|
export const de_SetDefaultPermissionVersionCommand = async (output, context) => {
|
|
2151
990
|
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
2152
|
-
return
|
|
991
|
+
return de_CommandError(output, context);
|
|
2153
992
|
}
|
|
2154
993
|
const contents = map({
|
|
2155
994
|
$metadata: deserializeMetadata(output),
|
|
@@ -2162,46 +1001,9 @@ export const de_SetDefaultPermissionVersionCommand = async (output, context) =>
|
|
|
2162
1001
|
Object.assign(contents, doc);
|
|
2163
1002
|
return contents;
|
|
2164
1003
|
};
|
|
2165
|
-
const de_SetDefaultPermissionVersionCommandError = async (output, context) => {
|
|
2166
|
-
const parsedOutput = {
|
|
2167
|
-
...output,
|
|
2168
|
-
body: await parseErrorBody(output.body, context),
|
|
2169
|
-
};
|
|
2170
|
-
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
2171
|
-
switch (errorCode) {
|
|
2172
|
-
case "IdempotentParameterMismatchException":
|
|
2173
|
-
case "com.amazonaws.ram#IdempotentParameterMismatchException":
|
|
2174
|
-
throw await de_IdempotentParameterMismatchExceptionRes(parsedOutput, context);
|
|
2175
|
-
case "InvalidClientTokenException":
|
|
2176
|
-
case "com.amazonaws.ram#InvalidClientTokenException":
|
|
2177
|
-
throw await de_InvalidClientTokenExceptionRes(parsedOutput, context);
|
|
2178
|
-
case "InvalidParameterException":
|
|
2179
|
-
case "com.amazonaws.ram#InvalidParameterException":
|
|
2180
|
-
throw await de_InvalidParameterExceptionRes(parsedOutput, context);
|
|
2181
|
-
case "MalformedArnException":
|
|
2182
|
-
case "com.amazonaws.ram#MalformedArnException":
|
|
2183
|
-
throw await de_MalformedArnExceptionRes(parsedOutput, context);
|
|
2184
|
-
case "ServerInternalException":
|
|
2185
|
-
case "com.amazonaws.ram#ServerInternalException":
|
|
2186
|
-
throw await de_ServerInternalExceptionRes(parsedOutput, context);
|
|
2187
|
-
case "ServiceUnavailableException":
|
|
2188
|
-
case "com.amazonaws.ram#ServiceUnavailableException":
|
|
2189
|
-
throw await de_ServiceUnavailableExceptionRes(parsedOutput, context);
|
|
2190
|
-
case "UnknownResourceException":
|
|
2191
|
-
case "com.amazonaws.ram#UnknownResourceException":
|
|
2192
|
-
throw await de_UnknownResourceExceptionRes(parsedOutput, context);
|
|
2193
|
-
default:
|
|
2194
|
-
const parsedBody = parsedOutput.body;
|
|
2195
|
-
return throwDefaultError({
|
|
2196
|
-
output,
|
|
2197
|
-
parsedBody,
|
|
2198
|
-
errorCode,
|
|
2199
|
-
});
|
|
2200
|
-
}
|
|
2201
|
-
};
|
|
2202
1004
|
export const de_TagResourceCommand = async (output, context) => {
|
|
2203
1005
|
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
2204
|
-
return
|
|
1006
|
+
return de_CommandError(output, context);
|
|
2205
1007
|
}
|
|
2206
1008
|
const contents = map({
|
|
2207
1009
|
$metadata: deserializeMetadata(output),
|
|
@@ -2209,49 +1011,9 @@ export const de_TagResourceCommand = async (output, context) => {
|
|
|
2209
1011
|
await collectBody(output.body, context);
|
|
2210
1012
|
return contents;
|
|
2211
1013
|
};
|
|
2212
|
-
const de_TagResourceCommandError = async (output, context) => {
|
|
2213
|
-
const parsedOutput = {
|
|
2214
|
-
...output,
|
|
2215
|
-
body: await parseErrorBody(output.body, context),
|
|
2216
|
-
};
|
|
2217
|
-
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
2218
|
-
switch (errorCode) {
|
|
2219
|
-
case "InvalidParameterException":
|
|
2220
|
-
case "com.amazonaws.ram#InvalidParameterException":
|
|
2221
|
-
throw await de_InvalidParameterExceptionRes(parsedOutput, context);
|
|
2222
|
-
case "MalformedArnException":
|
|
2223
|
-
case "com.amazonaws.ram#MalformedArnException":
|
|
2224
|
-
throw await de_MalformedArnExceptionRes(parsedOutput, context);
|
|
2225
|
-
case "ResourceArnNotFoundException":
|
|
2226
|
-
case "com.amazonaws.ram#ResourceArnNotFoundException":
|
|
2227
|
-
throw await de_ResourceArnNotFoundExceptionRes(parsedOutput, context);
|
|
2228
|
-
case "ServerInternalException":
|
|
2229
|
-
case "com.amazonaws.ram#ServerInternalException":
|
|
2230
|
-
throw await de_ServerInternalExceptionRes(parsedOutput, context);
|
|
2231
|
-
case "ServiceUnavailableException":
|
|
2232
|
-
case "com.amazonaws.ram#ServiceUnavailableException":
|
|
2233
|
-
throw await de_ServiceUnavailableExceptionRes(parsedOutput, context);
|
|
2234
|
-
case "TagLimitExceededException":
|
|
2235
|
-
case "com.amazonaws.ram#TagLimitExceededException":
|
|
2236
|
-
throw await de_TagLimitExceededExceptionRes(parsedOutput, context);
|
|
2237
|
-
case "TagPolicyViolationException":
|
|
2238
|
-
case "com.amazonaws.ram#TagPolicyViolationException":
|
|
2239
|
-
throw await de_TagPolicyViolationExceptionRes(parsedOutput, context);
|
|
2240
|
-
case "UnknownResourceException":
|
|
2241
|
-
case "com.amazonaws.ram#UnknownResourceException":
|
|
2242
|
-
throw await de_UnknownResourceExceptionRes(parsedOutput, context);
|
|
2243
|
-
default:
|
|
2244
|
-
const parsedBody = parsedOutput.body;
|
|
2245
|
-
return throwDefaultError({
|
|
2246
|
-
output,
|
|
2247
|
-
parsedBody,
|
|
2248
|
-
errorCode,
|
|
2249
|
-
});
|
|
2250
|
-
}
|
|
2251
|
-
};
|
|
2252
1014
|
export const de_UntagResourceCommand = async (output, context) => {
|
|
2253
1015
|
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
2254
|
-
return
|
|
1016
|
+
return de_CommandError(output, context);
|
|
2255
1017
|
}
|
|
2256
1018
|
const contents = map({
|
|
2257
1019
|
$metadata: deserializeMetadata(output),
|
|
@@ -2259,40 +1021,9 @@ export const de_UntagResourceCommand = async (output, context) => {
|
|
|
2259
1021
|
await collectBody(output.body, context);
|
|
2260
1022
|
return contents;
|
|
2261
1023
|
};
|
|
2262
|
-
const de_UntagResourceCommandError = async (output, context) => {
|
|
2263
|
-
const parsedOutput = {
|
|
2264
|
-
...output,
|
|
2265
|
-
body: await parseErrorBody(output.body, context),
|
|
2266
|
-
};
|
|
2267
|
-
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
2268
|
-
switch (errorCode) {
|
|
2269
|
-
case "InvalidParameterException":
|
|
2270
|
-
case "com.amazonaws.ram#InvalidParameterException":
|
|
2271
|
-
throw await de_InvalidParameterExceptionRes(parsedOutput, context);
|
|
2272
|
-
case "MalformedArnException":
|
|
2273
|
-
case "com.amazonaws.ram#MalformedArnException":
|
|
2274
|
-
throw await de_MalformedArnExceptionRes(parsedOutput, context);
|
|
2275
|
-
case "ServerInternalException":
|
|
2276
|
-
case "com.amazonaws.ram#ServerInternalException":
|
|
2277
|
-
throw await de_ServerInternalExceptionRes(parsedOutput, context);
|
|
2278
|
-
case "ServiceUnavailableException":
|
|
2279
|
-
case "com.amazonaws.ram#ServiceUnavailableException":
|
|
2280
|
-
throw await de_ServiceUnavailableExceptionRes(parsedOutput, context);
|
|
2281
|
-
case "UnknownResourceException":
|
|
2282
|
-
case "com.amazonaws.ram#UnknownResourceException":
|
|
2283
|
-
throw await de_UnknownResourceExceptionRes(parsedOutput, context);
|
|
2284
|
-
default:
|
|
2285
|
-
const parsedBody = parsedOutput.body;
|
|
2286
|
-
return throwDefaultError({
|
|
2287
|
-
output,
|
|
2288
|
-
parsedBody,
|
|
2289
|
-
errorCode,
|
|
2290
|
-
});
|
|
2291
|
-
}
|
|
2292
|
-
};
|
|
2293
1024
|
export const de_UpdateResourceShareCommand = async (output, context) => {
|
|
2294
1025
|
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
2295
|
-
return
|
|
1026
|
+
return de_CommandError(output, context);
|
|
2296
1027
|
}
|
|
2297
1028
|
const contents = map({
|
|
2298
1029
|
$metadata: deserializeMetadata(output),
|
|
@@ -2305,7 +1036,7 @@ export const de_UpdateResourceShareCommand = async (output, context) => {
|
|
|
2305
1036
|
Object.assign(contents, doc);
|
|
2306
1037
|
return contents;
|
|
2307
1038
|
};
|
|
2308
|
-
const
|
|
1039
|
+
const de_CommandError = async (output, context) => {
|
|
2309
1040
|
const parsedOutput = {
|
|
2310
1041
|
...output,
|
|
2311
1042
|
body: await parseErrorBody(output.body, context),
|
|
@@ -2318,27 +1049,84 @@ const de_UpdateResourceShareCommandError = async (output, context) => {
|
|
|
2318
1049
|
case "InvalidClientTokenException":
|
|
2319
1050
|
case "com.amazonaws.ram#InvalidClientTokenException":
|
|
2320
1051
|
throw await de_InvalidClientTokenExceptionRes(parsedOutput, context);
|
|
2321
|
-
case "InvalidParameterException":
|
|
2322
|
-
case "com.amazonaws.ram#InvalidParameterException":
|
|
2323
|
-
throw await de_InvalidParameterExceptionRes(parsedOutput, context);
|
|
2324
1052
|
case "MalformedArnException":
|
|
2325
1053
|
case "com.amazonaws.ram#MalformedArnException":
|
|
2326
1054
|
throw await de_MalformedArnExceptionRes(parsedOutput, context);
|
|
2327
|
-
case "MissingRequiredParameterException":
|
|
2328
|
-
case "com.amazonaws.ram#MissingRequiredParameterException":
|
|
2329
|
-
throw await de_MissingRequiredParameterExceptionRes(parsedOutput, context);
|
|
2330
1055
|
case "OperationNotPermittedException":
|
|
2331
1056
|
case "com.amazonaws.ram#OperationNotPermittedException":
|
|
2332
1057
|
throw await de_OperationNotPermittedExceptionRes(parsedOutput, context);
|
|
1058
|
+
case "ResourceShareInvitationAlreadyAcceptedException":
|
|
1059
|
+
case "com.amazonaws.ram#ResourceShareInvitationAlreadyAcceptedException":
|
|
1060
|
+
throw await de_ResourceShareInvitationAlreadyAcceptedExceptionRes(parsedOutput, context);
|
|
1061
|
+
case "ResourceShareInvitationAlreadyRejectedException":
|
|
1062
|
+
case "com.amazonaws.ram#ResourceShareInvitationAlreadyRejectedException":
|
|
1063
|
+
throw await de_ResourceShareInvitationAlreadyRejectedExceptionRes(parsedOutput, context);
|
|
1064
|
+
case "ResourceShareInvitationArnNotFoundException":
|
|
1065
|
+
case "com.amazonaws.ram#ResourceShareInvitationArnNotFoundException":
|
|
1066
|
+
throw await de_ResourceShareInvitationArnNotFoundExceptionRes(parsedOutput, context);
|
|
1067
|
+
case "ResourceShareInvitationExpiredException":
|
|
1068
|
+
case "com.amazonaws.ram#ResourceShareInvitationExpiredException":
|
|
1069
|
+
throw await de_ResourceShareInvitationExpiredExceptionRes(parsedOutput, context);
|
|
2333
1070
|
case "ServerInternalException":
|
|
2334
1071
|
case "com.amazonaws.ram#ServerInternalException":
|
|
2335
1072
|
throw await de_ServerInternalExceptionRes(parsedOutput, context);
|
|
2336
1073
|
case "ServiceUnavailableException":
|
|
2337
1074
|
case "com.amazonaws.ram#ServiceUnavailableException":
|
|
2338
1075
|
throw await de_ServiceUnavailableExceptionRes(parsedOutput, context);
|
|
1076
|
+
case "InvalidParameterException":
|
|
1077
|
+
case "com.amazonaws.ram#InvalidParameterException":
|
|
1078
|
+
throw await de_InvalidParameterExceptionRes(parsedOutput, context);
|
|
1079
|
+
case "InvalidStateTransitionException":
|
|
1080
|
+
case "com.amazonaws.ram#InvalidStateTransitionException":
|
|
1081
|
+
throw await de_InvalidStateTransitionExceptionRes(parsedOutput, context);
|
|
1082
|
+
case "ResourceShareLimitExceededException":
|
|
1083
|
+
case "com.amazonaws.ram#ResourceShareLimitExceededException":
|
|
1084
|
+
throw await de_ResourceShareLimitExceededExceptionRes(parsedOutput, context);
|
|
1085
|
+
case "ThrottlingException":
|
|
1086
|
+
case "com.amazonaws.ram#ThrottlingException":
|
|
1087
|
+
throw await de_ThrottlingExceptionRes(parsedOutput, context);
|
|
2339
1088
|
case "UnknownResourceException":
|
|
2340
1089
|
case "com.amazonaws.ram#UnknownResourceException":
|
|
2341
1090
|
throw await de_UnknownResourceExceptionRes(parsedOutput, context);
|
|
1091
|
+
case "InvalidPolicyException":
|
|
1092
|
+
case "com.amazonaws.ram#InvalidPolicyException":
|
|
1093
|
+
throw await de_InvalidPolicyExceptionRes(parsedOutput, context);
|
|
1094
|
+
case "MalformedPolicyTemplateException":
|
|
1095
|
+
case "com.amazonaws.ram#MalformedPolicyTemplateException":
|
|
1096
|
+
throw await de_MalformedPolicyTemplateExceptionRes(parsedOutput, context);
|
|
1097
|
+
case "PermissionAlreadyExistsException":
|
|
1098
|
+
case "com.amazonaws.ram#PermissionAlreadyExistsException":
|
|
1099
|
+
throw await de_PermissionAlreadyExistsExceptionRes(parsedOutput, context);
|
|
1100
|
+
case "PermissionLimitExceededException":
|
|
1101
|
+
case "com.amazonaws.ram#PermissionLimitExceededException":
|
|
1102
|
+
throw await de_PermissionLimitExceededExceptionRes(parsedOutput, context);
|
|
1103
|
+
case "PermissionVersionsLimitExceededException":
|
|
1104
|
+
case "com.amazonaws.ram#PermissionVersionsLimitExceededException":
|
|
1105
|
+
throw await de_PermissionVersionsLimitExceededExceptionRes(parsedOutput, context);
|
|
1106
|
+
case "TagLimitExceededException":
|
|
1107
|
+
case "com.amazonaws.ram#TagLimitExceededException":
|
|
1108
|
+
throw await de_TagLimitExceededExceptionRes(parsedOutput, context);
|
|
1109
|
+
case "TagPolicyViolationException":
|
|
1110
|
+
case "com.amazonaws.ram#TagPolicyViolationException":
|
|
1111
|
+
throw await de_TagPolicyViolationExceptionRes(parsedOutput, context);
|
|
1112
|
+
case "InvalidNextTokenException":
|
|
1113
|
+
case "com.amazonaws.ram#InvalidNextTokenException":
|
|
1114
|
+
throw await de_InvalidNextTokenExceptionRes(parsedOutput, context);
|
|
1115
|
+
case "ResourceArnNotFoundException":
|
|
1116
|
+
case "com.amazonaws.ram#ResourceArnNotFoundException":
|
|
1117
|
+
throw await de_ResourceArnNotFoundExceptionRes(parsedOutput, context);
|
|
1118
|
+
case "InvalidMaxResultsException":
|
|
1119
|
+
case "com.amazonaws.ram#InvalidMaxResultsException":
|
|
1120
|
+
throw await de_InvalidMaxResultsExceptionRes(parsedOutput, context);
|
|
1121
|
+
case "MissingRequiredParameterException":
|
|
1122
|
+
case "com.amazonaws.ram#MissingRequiredParameterException":
|
|
1123
|
+
throw await de_MissingRequiredParameterExceptionRes(parsedOutput, context);
|
|
1124
|
+
case "InvalidResourceTypeException":
|
|
1125
|
+
case "com.amazonaws.ram#InvalidResourceTypeException":
|
|
1126
|
+
throw await de_InvalidResourceTypeExceptionRes(parsedOutput, context);
|
|
1127
|
+
case "UnmatchedPolicyPermissionException":
|
|
1128
|
+
case "com.amazonaws.ram#UnmatchedPolicyPermissionException":
|
|
1129
|
+
throw await de_UnmatchedPolicyPermissionExceptionRes(parsedOutput, context);
|
|
2342
1130
|
default:
|
|
2343
1131
|
const parsedBody = parsedOutput.body;
|
|
2344
1132
|
return throwDefaultError({
|