@aws-sdk/client-cloudwatch-events 3.118.1 → 3.128.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.
@@ -534,8 +534,7 @@ const deserializeAws_json1_1ActivateEventSourceCommandError = async (output, con
534
534
  body: await parseBody(output.body, context),
535
535
  };
536
536
  let response;
537
- let errorCode = "UnknownError";
538
- errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
537
+ const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
539
538
  switch (errorCode) {
540
539
  case "ConcurrentModificationException":
541
540
  case "com.amazonaws.cloudwatchevents#ConcurrentModificationException":
@@ -554,10 +553,12 @@ const deserializeAws_json1_1ActivateEventSourceCommandError = async (output, con
554
553
  throw await deserializeAws_json1_1ResourceNotFoundExceptionResponse(parsedOutput, context);
555
554
  default:
556
555
  const parsedBody = parsedOutput.body;
556
+ const $metadata = deserializeMetadata(output);
557
+ const statusCode = $metadata.httpStatusCode ? $metadata.httpStatusCode + "" : undefined;
557
558
  response = new CloudWatchEventsServiceException_1.CloudWatchEventsServiceException({
558
- name: parsedBody.code || parsedBody.Code || errorCode,
559
+ name: parsedBody.code || parsedBody.Code || errorCode || statusCode || "UnknowError",
559
560
  $fault: "client",
560
- $metadata: deserializeMetadata(output),
561
+ $metadata,
561
562
  });
562
563
  throw (0, smithy_client_1.decorateServiceException)(response, parsedBody);
563
564
  }
@@ -582,8 +583,7 @@ const deserializeAws_json1_1CancelReplayCommandError = async (output, context) =
582
583
  body: await parseBody(output.body, context),
583
584
  };
584
585
  let response;
585
- let errorCode = "UnknownError";
586
- errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
586
+ const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
587
587
  switch (errorCode) {
588
588
  case "ConcurrentModificationException":
589
589
  case "com.amazonaws.cloudwatchevents#ConcurrentModificationException":
@@ -599,10 +599,12 @@ const deserializeAws_json1_1CancelReplayCommandError = async (output, context) =
599
599
  throw await deserializeAws_json1_1ResourceNotFoundExceptionResponse(parsedOutput, context);
600
600
  default:
601
601
  const parsedBody = parsedOutput.body;
602
+ const $metadata = deserializeMetadata(output);
603
+ const statusCode = $metadata.httpStatusCode ? $metadata.httpStatusCode + "" : undefined;
602
604
  response = new CloudWatchEventsServiceException_1.CloudWatchEventsServiceException({
603
- name: parsedBody.code || parsedBody.Code || errorCode,
605
+ name: parsedBody.code || parsedBody.Code || errorCode || statusCode || "UnknowError",
604
606
  $fault: "client",
605
- $metadata: deserializeMetadata(output),
607
+ $metadata,
606
608
  });
607
609
  throw (0, smithy_client_1.decorateServiceException)(response, parsedBody);
608
610
  }
@@ -627,8 +629,7 @@ const deserializeAws_json1_1CreateApiDestinationCommandError = async (output, co
627
629
  body: await parseBody(output.body, context),
628
630
  };
629
631
  let response;
630
- let errorCode = "UnknownError";
631
- errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
632
+ const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
632
633
  switch (errorCode) {
633
634
  case "InternalException":
634
635
  case "com.amazonaws.cloudwatchevents#InternalException":
@@ -644,10 +645,12 @@ const deserializeAws_json1_1CreateApiDestinationCommandError = async (output, co
644
645
  throw await deserializeAws_json1_1ResourceNotFoundExceptionResponse(parsedOutput, context);
645
646
  default:
646
647
  const parsedBody = parsedOutput.body;
648
+ const $metadata = deserializeMetadata(output);
649
+ const statusCode = $metadata.httpStatusCode ? $metadata.httpStatusCode + "" : undefined;
647
650
  response = new CloudWatchEventsServiceException_1.CloudWatchEventsServiceException({
648
- name: parsedBody.code || parsedBody.Code || errorCode,
651
+ name: parsedBody.code || parsedBody.Code || errorCode || statusCode || "UnknowError",
649
652
  $fault: "client",
650
- $metadata: deserializeMetadata(output),
653
+ $metadata,
651
654
  });
652
655
  throw (0, smithy_client_1.decorateServiceException)(response, parsedBody);
653
656
  }
@@ -672,8 +675,7 @@ const deserializeAws_json1_1CreateArchiveCommandError = async (output, context)
672
675
  body: await parseBody(output.body, context),
673
676
  };
674
677
  let response;
675
- let errorCode = "UnknownError";
676
- errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
678
+ const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
677
679
  switch (errorCode) {
678
680
  case "ConcurrentModificationException":
679
681
  case "com.amazonaws.cloudwatchevents#ConcurrentModificationException":
@@ -695,10 +697,12 @@ const deserializeAws_json1_1CreateArchiveCommandError = async (output, context)
695
697
  throw await deserializeAws_json1_1ResourceNotFoundExceptionResponse(parsedOutput, context);
696
698
  default:
697
699
  const parsedBody = parsedOutput.body;
700
+ const $metadata = deserializeMetadata(output);
701
+ const statusCode = $metadata.httpStatusCode ? $metadata.httpStatusCode + "" : undefined;
698
702
  response = new CloudWatchEventsServiceException_1.CloudWatchEventsServiceException({
699
- name: parsedBody.code || parsedBody.Code || errorCode,
703
+ name: parsedBody.code || parsedBody.Code || errorCode || statusCode || "UnknowError",
700
704
  $fault: "client",
701
- $metadata: deserializeMetadata(output),
705
+ $metadata,
702
706
  });
703
707
  throw (0, smithy_client_1.decorateServiceException)(response, parsedBody);
704
708
  }
@@ -723,8 +727,7 @@ const deserializeAws_json1_1CreateConnectionCommandError = async (output, contex
723
727
  body: await parseBody(output.body, context),
724
728
  };
725
729
  let response;
726
- let errorCode = "UnknownError";
727
- errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
730
+ const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
728
731
  switch (errorCode) {
729
732
  case "InternalException":
730
733
  case "com.amazonaws.cloudwatchevents#InternalException":
@@ -737,10 +740,12 @@ const deserializeAws_json1_1CreateConnectionCommandError = async (output, contex
737
740
  throw await deserializeAws_json1_1ResourceAlreadyExistsExceptionResponse(parsedOutput, context);
738
741
  default:
739
742
  const parsedBody = parsedOutput.body;
743
+ const $metadata = deserializeMetadata(output);
744
+ const statusCode = $metadata.httpStatusCode ? $metadata.httpStatusCode + "" : undefined;
740
745
  response = new CloudWatchEventsServiceException_1.CloudWatchEventsServiceException({
741
- name: parsedBody.code || parsedBody.Code || errorCode,
746
+ name: parsedBody.code || parsedBody.Code || errorCode || statusCode || "UnknowError",
742
747
  $fault: "client",
743
- $metadata: deserializeMetadata(output),
748
+ $metadata,
744
749
  });
745
750
  throw (0, smithy_client_1.decorateServiceException)(response, parsedBody);
746
751
  }
@@ -765,8 +770,7 @@ const deserializeAws_json1_1CreateEventBusCommandError = async (output, context)
765
770
  body: await parseBody(output.body, context),
766
771
  };
767
772
  let response;
768
- let errorCode = "UnknownError";
769
- errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
773
+ const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
770
774
  switch (errorCode) {
771
775
  case "ConcurrentModificationException":
772
776
  case "com.amazonaws.cloudwatchevents#ConcurrentModificationException":
@@ -791,10 +795,12 @@ const deserializeAws_json1_1CreateEventBusCommandError = async (output, context)
791
795
  throw await deserializeAws_json1_1ResourceNotFoundExceptionResponse(parsedOutput, context);
792
796
  default:
793
797
  const parsedBody = parsedOutput.body;
798
+ const $metadata = deserializeMetadata(output);
799
+ const statusCode = $metadata.httpStatusCode ? $metadata.httpStatusCode + "" : undefined;
794
800
  response = new CloudWatchEventsServiceException_1.CloudWatchEventsServiceException({
795
- name: parsedBody.code || parsedBody.Code || errorCode,
801
+ name: parsedBody.code || parsedBody.Code || errorCode || statusCode || "UnknowError",
796
802
  $fault: "client",
797
- $metadata: deserializeMetadata(output),
803
+ $metadata,
798
804
  });
799
805
  throw (0, smithy_client_1.decorateServiceException)(response, parsedBody);
800
806
  }
@@ -819,8 +825,7 @@ const deserializeAws_json1_1CreatePartnerEventSourceCommandError = async (output
819
825
  body: await parseBody(output.body, context),
820
826
  };
821
827
  let response;
822
- let errorCode = "UnknownError";
823
- errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
828
+ const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
824
829
  switch (errorCode) {
825
830
  case "ConcurrentModificationException":
826
831
  case "com.amazonaws.cloudwatchevents#ConcurrentModificationException":
@@ -839,10 +844,12 @@ const deserializeAws_json1_1CreatePartnerEventSourceCommandError = async (output
839
844
  throw await deserializeAws_json1_1ResourceAlreadyExistsExceptionResponse(parsedOutput, context);
840
845
  default:
841
846
  const parsedBody = parsedOutput.body;
847
+ const $metadata = deserializeMetadata(output);
848
+ const statusCode = $metadata.httpStatusCode ? $metadata.httpStatusCode + "" : undefined;
842
849
  response = new CloudWatchEventsServiceException_1.CloudWatchEventsServiceException({
843
- name: parsedBody.code || parsedBody.Code || errorCode,
850
+ name: parsedBody.code || parsedBody.Code || errorCode || statusCode || "UnknowError",
844
851
  $fault: "client",
845
- $metadata: deserializeMetadata(output),
852
+ $metadata,
846
853
  });
847
854
  throw (0, smithy_client_1.decorateServiceException)(response, parsedBody);
848
855
  }
@@ -864,8 +871,7 @@ const deserializeAws_json1_1DeactivateEventSourceCommandError = async (output, c
864
871
  body: await parseBody(output.body, context),
865
872
  };
866
873
  let response;
867
- let errorCode = "UnknownError";
868
- errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
874
+ const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
869
875
  switch (errorCode) {
870
876
  case "ConcurrentModificationException":
871
877
  case "com.amazonaws.cloudwatchevents#ConcurrentModificationException":
@@ -884,10 +890,12 @@ const deserializeAws_json1_1DeactivateEventSourceCommandError = async (output, c
884
890
  throw await deserializeAws_json1_1ResourceNotFoundExceptionResponse(parsedOutput, context);
885
891
  default:
886
892
  const parsedBody = parsedOutput.body;
893
+ const $metadata = deserializeMetadata(output);
894
+ const statusCode = $metadata.httpStatusCode ? $metadata.httpStatusCode + "" : undefined;
887
895
  response = new CloudWatchEventsServiceException_1.CloudWatchEventsServiceException({
888
- name: parsedBody.code || parsedBody.Code || errorCode,
896
+ name: parsedBody.code || parsedBody.Code || errorCode || statusCode || "UnknowError",
889
897
  $fault: "client",
890
- $metadata: deserializeMetadata(output),
898
+ $metadata,
891
899
  });
892
900
  throw (0, smithy_client_1.decorateServiceException)(response, parsedBody);
893
901
  }
@@ -912,8 +920,7 @@ const deserializeAws_json1_1DeauthorizeConnectionCommandError = async (output, c
912
920
  body: await parseBody(output.body, context),
913
921
  };
914
922
  let response;
915
- let errorCode = "UnknownError";
916
- errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
923
+ const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
917
924
  switch (errorCode) {
918
925
  case "ConcurrentModificationException":
919
926
  case "com.amazonaws.cloudwatchevents#ConcurrentModificationException":
@@ -926,10 +933,12 @@ const deserializeAws_json1_1DeauthorizeConnectionCommandError = async (output, c
926
933
  throw await deserializeAws_json1_1ResourceNotFoundExceptionResponse(parsedOutput, context);
927
934
  default:
928
935
  const parsedBody = parsedOutput.body;
936
+ const $metadata = deserializeMetadata(output);
937
+ const statusCode = $metadata.httpStatusCode ? $metadata.httpStatusCode + "" : undefined;
929
938
  response = new CloudWatchEventsServiceException_1.CloudWatchEventsServiceException({
930
- name: parsedBody.code || parsedBody.Code || errorCode,
939
+ name: parsedBody.code || parsedBody.Code || errorCode || statusCode || "UnknowError",
931
940
  $fault: "client",
932
- $metadata: deserializeMetadata(output),
941
+ $metadata,
933
942
  });
934
943
  throw (0, smithy_client_1.decorateServiceException)(response, parsedBody);
935
944
  }
@@ -954,8 +963,7 @@ const deserializeAws_json1_1DeleteApiDestinationCommandError = async (output, co
954
963
  body: await parseBody(output.body, context),
955
964
  };
956
965
  let response;
957
- let errorCode = "UnknownError";
958
- errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
966
+ const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
959
967
  switch (errorCode) {
960
968
  case "ConcurrentModificationException":
961
969
  case "com.amazonaws.cloudwatchevents#ConcurrentModificationException":
@@ -968,10 +976,12 @@ const deserializeAws_json1_1DeleteApiDestinationCommandError = async (output, co
968
976
  throw await deserializeAws_json1_1ResourceNotFoundExceptionResponse(parsedOutput, context);
969
977
  default:
970
978
  const parsedBody = parsedOutput.body;
979
+ const $metadata = deserializeMetadata(output);
980
+ const statusCode = $metadata.httpStatusCode ? $metadata.httpStatusCode + "" : undefined;
971
981
  response = new CloudWatchEventsServiceException_1.CloudWatchEventsServiceException({
972
- name: parsedBody.code || parsedBody.Code || errorCode,
982
+ name: parsedBody.code || parsedBody.Code || errorCode || statusCode || "UnknowError",
973
983
  $fault: "client",
974
- $metadata: deserializeMetadata(output),
984
+ $metadata,
975
985
  });
976
986
  throw (0, smithy_client_1.decorateServiceException)(response, parsedBody);
977
987
  }
@@ -996,8 +1006,7 @@ const deserializeAws_json1_1DeleteArchiveCommandError = async (output, context)
996
1006
  body: await parseBody(output.body, context),
997
1007
  };
998
1008
  let response;
999
- let errorCode = "UnknownError";
1000
- errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1009
+ const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1001
1010
  switch (errorCode) {
1002
1011
  case "ConcurrentModificationException":
1003
1012
  case "com.amazonaws.cloudwatchevents#ConcurrentModificationException":
@@ -1010,10 +1019,12 @@ const deserializeAws_json1_1DeleteArchiveCommandError = async (output, context)
1010
1019
  throw await deserializeAws_json1_1ResourceNotFoundExceptionResponse(parsedOutput, context);
1011
1020
  default:
1012
1021
  const parsedBody = parsedOutput.body;
1022
+ const $metadata = deserializeMetadata(output);
1023
+ const statusCode = $metadata.httpStatusCode ? $metadata.httpStatusCode + "" : undefined;
1013
1024
  response = new CloudWatchEventsServiceException_1.CloudWatchEventsServiceException({
1014
- name: parsedBody.code || parsedBody.Code || errorCode,
1025
+ name: parsedBody.code || parsedBody.Code || errorCode || statusCode || "UnknowError",
1015
1026
  $fault: "client",
1016
- $metadata: deserializeMetadata(output),
1027
+ $metadata,
1017
1028
  });
1018
1029
  throw (0, smithy_client_1.decorateServiceException)(response, parsedBody);
1019
1030
  }
@@ -1038,8 +1049,7 @@ const deserializeAws_json1_1DeleteConnectionCommandError = async (output, contex
1038
1049
  body: await parseBody(output.body, context),
1039
1050
  };
1040
1051
  let response;
1041
- let errorCode = "UnknownError";
1042
- errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1052
+ const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1043
1053
  switch (errorCode) {
1044
1054
  case "ConcurrentModificationException":
1045
1055
  case "com.amazonaws.cloudwatchevents#ConcurrentModificationException":
@@ -1052,10 +1062,12 @@ const deserializeAws_json1_1DeleteConnectionCommandError = async (output, contex
1052
1062
  throw await deserializeAws_json1_1ResourceNotFoundExceptionResponse(parsedOutput, context);
1053
1063
  default:
1054
1064
  const parsedBody = parsedOutput.body;
1065
+ const $metadata = deserializeMetadata(output);
1066
+ const statusCode = $metadata.httpStatusCode ? $metadata.httpStatusCode + "" : undefined;
1055
1067
  response = new CloudWatchEventsServiceException_1.CloudWatchEventsServiceException({
1056
- name: parsedBody.code || parsedBody.Code || errorCode,
1068
+ name: parsedBody.code || parsedBody.Code || errorCode || statusCode || "UnknowError",
1057
1069
  $fault: "client",
1058
- $metadata: deserializeMetadata(output),
1070
+ $metadata,
1059
1071
  });
1060
1072
  throw (0, smithy_client_1.decorateServiceException)(response, parsedBody);
1061
1073
  }
@@ -1077,8 +1089,7 @@ const deserializeAws_json1_1DeleteEventBusCommandError = async (output, context)
1077
1089
  body: await parseBody(output.body, context),
1078
1090
  };
1079
1091
  let response;
1080
- let errorCode = "UnknownError";
1081
- errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1092
+ const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1082
1093
  switch (errorCode) {
1083
1094
  case "ConcurrentModificationException":
1084
1095
  case "com.amazonaws.cloudwatchevents#ConcurrentModificationException":
@@ -1088,10 +1099,12 @@ const deserializeAws_json1_1DeleteEventBusCommandError = async (output, context)
1088
1099
  throw await deserializeAws_json1_1InternalExceptionResponse(parsedOutput, context);
1089
1100
  default:
1090
1101
  const parsedBody = parsedOutput.body;
1102
+ const $metadata = deserializeMetadata(output);
1103
+ const statusCode = $metadata.httpStatusCode ? $metadata.httpStatusCode + "" : undefined;
1091
1104
  response = new CloudWatchEventsServiceException_1.CloudWatchEventsServiceException({
1092
- name: parsedBody.code || parsedBody.Code || errorCode,
1105
+ name: parsedBody.code || parsedBody.Code || errorCode || statusCode || "UnknowError",
1093
1106
  $fault: "client",
1094
- $metadata: deserializeMetadata(output),
1107
+ $metadata,
1095
1108
  });
1096
1109
  throw (0, smithy_client_1.decorateServiceException)(response, parsedBody);
1097
1110
  }
@@ -1113,8 +1126,7 @@ const deserializeAws_json1_1DeletePartnerEventSourceCommandError = async (output
1113
1126
  body: await parseBody(output.body, context),
1114
1127
  };
1115
1128
  let response;
1116
- let errorCode = "UnknownError";
1117
- errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1129
+ const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1118
1130
  switch (errorCode) {
1119
1131
  case "ConcurrentModificationException":
1120
1132
  case "com.amazonaws.cloudwatchevents#ConcurrentModificationException":
@@ -1127,10 +1139,12 @@ const deserializeAws_json1_1DeletePartnerEventSourceCommandError = async (output
1127
1139
  throw await deserializeAws_json1_1OperationDisabledExceptionResponse(parsedOutput, context);
1128
1140
  default:
1129
1141
  const parsedBody = parsedOutput.body;
1142
+ const $metadata = deserializeMetadata(output);
1143
+ const statusCode = $metadata.httpStatusCode ? $metadata.httpStatusCode + "" : undefined;
1130
1144
  response = new CloudWatchEventsServiceException_1.CloudWatchEventsServiceException({
1131
- name: parsedBody.code || parsedBody.Code || errorCode,
1145
+ name: parsedBody.code || parsedBody.Code || errorCode || statusCode || "UnknowError",
1132
1146
  $fault: "client",
1133
- $metadata: deserializeMetadata(output),
1147
+ $metadata,
1134
1148
  });
1135
1149
  throw (0, smithy_client_1.decorateServiceException)(response, parsedBody);
1136
1150
  }
@@ -1152,8 +1166,7 @@ const deserializeAws_json1_1DeleteRuleCommandError = async (output, context) =>
1152
1166
  body: await parseBody(output.body, context),
1153
1167
  };
1154
1168
  let response;
1155
- let errorCode = "UnknownError";
1156
- errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1169
+ const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1157
1170
  switch (errorCode) {
1158
1171
  case "ConcurrentModificationException":
1159
1172
  case "com.amazonaws.cloudwatchevents#ConcurrentModificationException":
@@ -1169,10 +1182,12 @@ const deserializeAws_json1_1DeleteRuleCommandError = async (output, context) =>
1169
1182
  throw await deserializeAws_json1_1ResourceNotFoundExceptionResponse(parsedOutput, context);
1170
1183
  default:
1171
1184
  const parsedBody = parsedOutput.body;
1185
+ const $metadata = deserializeMetadata(output);
1186
+ const statusCode = $metadata.httpStatusCode ? $metadata.httpStatusCode + "" : undefined;
1172
1187
  response = new CloudWatchEventsServiceException_1.CloudWatchEventsServiceException({
1173
- name: parsedBody.code || parsedBody.Code || errorCode,
1188
+ name: parsedBody.code || parsedBody.Code || errorCode || statusCode || "UnknowError",
1174
1189
  $fault: "client",
1175
- $metadata: deserializeMetadata(output),
1190
+ $metadata,
1176
1191
  });
1177
1192
  throw (0, smithy_client_1.decorateServiceException)(response, parsedBody);
1178
1193
  }
@@ -1197,8 +1212,7 @@ const deserializeAws_json1_1DescribeApiDestinationCommandError = async (output,
1197
1212
  body: await parseBody(output.body, context),
1198
1213
  };
1199
1214
  let response;
1200
- let errorCode = "UnknownError";
1201
- errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1215
+ const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1202
1216
  switch (errorCode) {
1203
1217
  case "InternalException":
1204
1218
  case "com.amazonaws.cloudwatchevents#InternalException":
@@ -1208,10 +1222,12 @@ const deserializeAws_json1_1DescribeApiDestinationCommandError = async (output,
1208
1222
  throw await deserializeAws_json1_1ResourceNotFoundExceptionResponse(parsedOutput, context);
1209
1223
  default:
1210
1224
  const parsedBody = parsedOutput.body;
1225
+ const $metadata = deserializeMetadata(output);
1226
+ const statusCode = $metadata.httpStatusCode ? $metadata.httpStatusCode + "" : undefined;
1211
1227
  response = new CloudWatchEventsServiceException_1.CloudWatchEventsServiceException({
1212
- name: parsedBody.code || parsedBody.Code || errorCode,
1228
+ name: parsedBody.code || parsedBody.Code || errorCode || statusCode || "UnknowError",
1213
1229
  $fault: "client",
1214
- $metadata: deserializeMetadata(output),
1230
+ $metadata,
1215
1231
  });
1216
1232
  throw (0, smithy_client_1.decorateServiceException)(response, parsedBody);
1217
1233
  }
@@ -1236,8 +1252,7 @@ const deserializeAws_json1_1DescribeArchiveCommandError = async (output, context
1236
1252
  body: await parseBody(output.body, context),
1237
1253
  };
1238
1254
  let response;
1239
- let errorCode = "UnknownError";
1240
- errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1255
+ const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1241
1256
  switch (errorCode) {
1242
1257
  case "InternalException":
1243
1258
  case "com.amazonaws.cloudwatchevents#InternalException":
@@ -1250,10 +1265,12 @@ const deserializeAws_json1_1DescribeArchiveCommandError = async (output, context
1250
1265
  throw await deserializeAws_json1_1ResourceNotFoundExceptionResponse(parsedOutput, context);
1251
1266
  default:
1252
1267
  const parsedBody = parsedOutput.body;
1268
+ const $metadata = deserializeMetadata(output);
1269
+ const statusCode = $metadata.httpStatusCode ? $metadata.httpStatusCode + "" : undefined;
1253
1270
  response = new CloudWatchEventsServiceException_1.CloudWatchEventsServiceException({
1254
- name: parsedBody.code || parsedBody.Code || errorCode,
1271
+ name: parsedBody.code || parsedBody.Code || errorCode || statusCode || "UnknowError",
1255
1272
  $fault: "client",
1256
- $metadata: deserializeMetadata(output),
1273
+ $metadata,
1257
1274
  });
1258
1275
  throw (0, smithy_client_1.decorateServiceException)(response, parsedBody);
1259
1276
  }
@@ -1278,8 +1295,7 @@ const deserializeAws_json1_1DescribeConnectionCommandError = async (output, cont
1278
1295
  body: await parseBody(output.body, context),
1279
1296
  };
1280
1297
  let response;
1281
- let errorCode = "UnknownError";
1282
- errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1298
+ const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1283
1299
  switch (errorCode) {
1284
1300
  case "InternalException":
1285
1301
  case "com.amazonaws.cloudwatchevents#InternalException":
@@ -1289,10 +1305,12 @@ const deserializeAws_json1_1DescribeConnectionCommandError = async (output, cont
1289
1305
  throw await deserializeAws_json1_1ResourceNotFoundExceptionResponse(parsedOutput, context);
1290
1306
  default:
1291
1307
  const parsedBody = parsedOutput.body;
1308
+ const $metadata = deserializeMetadata(output);
1309
+ const statusCode = $metadata.httpStatusCode ? $metadata.httpStatusCode + "" : undefined;
1292
1310
  response = new CloudWatchEventsServiceException_1.CloudWatchEventsServiceException({
1293
- name: parsedBody.code || parsedBody.Code || errorCode,
1311
+ name: parsedBody.code || parsedBody.Code || errorCode || statusCode || "UnknowError",
1294
1312
  $fault: "client",
1295
- $metadata: deserializeMetadata(output),
1313
+ $metadata,
1296
1314
  });
1297
1315
  throw (0, smithy_client_1.decorateServiceException)(response, parsedBody);
1298
1316
  }
@@ -1317,8 +1335,7 @@ const deserializeAws_json1_1DescribeEventBusCommandError = async (output, contex
1317
1335
  body: await parseBody(output.body, context),
1318
1336
  };
1319
1337
  let response;
1320
- let errorCode = "UnknownError";
1321
- errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1338
+ const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1322
1339
  switch (errorCode) {
1323
1340
  case "InternalException":
1324
1341
  case "com.amazonaws.cloudwatchevents#InternalException":
@@ -1328,10 +1345,12 @@ const deserializeAws_json1_1DescribeEventBusCommandError = async (output, contex
1328
1345
  throw await deserializeAws_json1_1ResourceNotFoundExceptionResponse(parsedOutput, context);
1329
1346
  default:
1330
1347
  const parsedBody = parsedOutput.body;
1348
+ const $metadata = deserializeMetadata(output);
1349
+ const statusCode = $metadata.httpStatusCode ? $metadata.httpStatusCode + "" : undefined;
1331
1350
  response = new CloudWatchEventsServiceException_1.CloudWatchEventsServiceException({
1332
- name: parsedBody.code || parsedBody.Code || errorCode,
1351
+ name: parsedBody.code || parsedBody.Code || errorCode || statusCode || "UnknowError",
1333
1352
  $fault: "client",
1334
- $metadata: deserializeMetadata(output),
1353
+ $metadata,
1335
1354
  });
1336
1355
  throw (0, smithy_client_1.decorateServiceException)(response, parsedBody);
1337
1356
  }
@@ -1356,8 +1375,7 @@ const deserializeAws_json1_1DescribeEventSourceCommandError = async (output, con
1356
1375
  body: await parseBody(output.body, context),
1357
1376
  };
1358
1377
  let response;
1359
- let errorCode = "UnknownError";
1360
- errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1378
+ const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1361
1379
  switch (errorCode) {
1362
1380
  case "InternalException":
1363
1381
  case "com.amazonaws.cloudwatchevents#InternalException":
@@ -1370,10 +1388,12 @@ const deserializeAws_json1_1DescribeEventSourceCommandError = async (output, con
1370
1388
  throw await deserializeAws_json1_1ResourceNotFoundExceptionResponse(parsedOutput, context);
1371
1389
  default:
1372
1390
  const parsedBody = parsedOutput.body;
1391
+ const $metadata = deserializeMetadata(output);
1392
+ const statusCode = $metadata.httpStatusCode ? $metadata.httpStatusCode + "" : undefined;
1373
1393
  response = new CloudWatchEventsServiceException_1.CloudWatchEventsServiceException({
1374
- name: parsedBody.code || parsedBody.Code || errorCode,
1394
+ name: parsedBody.code || parsedBody.Code || errorCode || statusCode || "UnknowError",
1375
1395
  $fault: "client",
1376
- $metadata: deserializeMetadata(output),
1396
+ $metadata,
1377
1397
  });
1378
1398
  throw (0, smithy_client_1.decorateServiceException)(response, parsedBody);
1379
1399
  }
@@ -1398,8 +1418,7 @@ const deserializeAws_json1_1DescribePartnerEventSourceCommandError = async (outp
1398
1418
  body: await parseBody(output.body, context),
1399
1419
  };
1400
1420
  let response;
1401
- let errorCode = "UnknownError";
1402
- errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1421
+ const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1403
1422
  switch (errorCode) {
1404
1423
  case "InternalException":
1405
1424
  case "com.amazonaws.cloudwatchevents#InternalException":
@@ -1412,10 +1431,12 @@ const deserializeAws_json1_1DescribePartnerEventSourceCommandError = async (outp
1412
1431
  throw await deserializeAws_json1_1ResourceNotFoundExceptionResponse(parsedOutput, context);
1413
1432
  default:
1414
1433
  const parsedBody = parsedOutput.body;
1434
+ const $metadata = deserializeMetadata(output);
1435
+ const statusCode = $metadata.httpStatusCode ? $metadata.httpStatusCode + "" : undefined;
1415
1436
  response = new CloudWatchEventsServiceException_1.CloudWatchEventsServiceException({
1416
- name: parsedBody.code || parsedBody.Code || errorCode,
1437
+ name: parsedBody.code || parsedBody.Code || errorCode || statusCode || "UnknowError",
1417
1438
  $fault: "client",
1418
- $metadata: deserializeMetadata(output),
1439
+ $metadata,
1419
1440
  });
1420
1441
  throw (0, smithy_client_1.decorateServiceException)(response, parsedBody);
1421
1442
  }
@@ -1440,8 +1461,7 @@ const deserializeAws_json1_1DescribeReplayCommandError = async (output, context)
1440
1461
  body: await parseBody(output.body, context),
1441
1462
  };
1442
1463
  let response;
1443
- let errorCode = "UnknownError";
1444
- errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1464
+ const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1445
1465
  switch (errorCode) {
1446
1466
  case "InternalException":
1447
1467
  case "com.amazonaws.cloudwatchevents#InternalException":
@@ -1451,10 +1471,12 @@ const deserializeAws_json1_1DescribeReplayCommandError = async (output, context)
1451
1471
  throw await deserializeAws_json1_1ResourceNotFoundExceptionResponse(parsedOutput, context);
1452
1472
  default:
1453
1473
  const parsedBody = parsedOutput.body;
1474
+ const $metadata = deserializeMetadata(output);
1475
+ const statusCode = $metadata.httpStatusCode ? $metadata.httpStatusCode + "" : undefined;
1454
1476
  response = new CloudWatchEventsServiceException_1.CloudWatchEventsServiceException({
1455
- name: parsedBody.code || parsedBody.Code || errorCode,
1477
+ name: parsedBody.code || parsedBody.Code || errorCode || statusCode || "UnknowError",
1456
1478
  $fault: "client",
1457
- $metadata: deserializeMetadata(output),
1479
+ $metadata,
1458
1480
  });
1459
1481
  throw (0, smithy_client_1.decorateServiceException)(response, parsedBody);
1460
1482
  }
@@ -1479,8 +1501,7 @@ const deserializeAws_json1_1DescribeRuleCommandError = async (output, context) =
1479
1501
  body: await parseBody(output.body, context),
1480
1502
  };
1481
1503
  let response;
1482
- let errorCode = "UnknownError";
1483
- errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1504
+ const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1484
1505
  switch (errorCode) {
1485
1506
  case "InternalException":
1486
1507
  case "com.amazonaws.cloudwatchevents#InternalException":
@@ -1490,10 +1511,12 @@ const deserializeAws_json1_1DescribeRuleCommandError = async (output, context) =
1490
1511
  throw await deserializeAws_json1_1ResourceNotFoundExceptionResponse(parsedOutput, context);
1491
1512
  default:
1492
1513
  const parsedBody = parsedOutput.body;
1514
+ const $metadata = deserializeMetadata(output);
1515
+ const statusCode = $metadata.httpStatusCode ? $metadata.httpStatusCode + "" : undefined;
1493
1516
  response = new CloudWatchEventsServiceException_1.CloudWatchEventsServiceException({
1494
- name: parsedBody.code || parsedBody.Code || errorCode,
1517
+ name: parsedBody.code || parsedBody.Code || errorCode || statusCode || "UnknowError",
1495
1518
  $fault: "client",
1496
- $metadata: deserializeMetadata(output),
1519
+ $metadata,
1497
1520
  });
1498
1521
  throw (0, smithy_client_1.decorateServiceException)(response, parsedBody);
1499
1522
  }
@@ -1515,8 +1538,7 @@ const deserializeAws_json1_1DisableRuleCommandError = async (output, context) =>
1515
1538
  body: await parseBody(output.body, context),
1516
1539
  };
1517
1540
  let response;
1518
- let errorCode = "UnknownError";
1519
- errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1541
+ const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1520
1542
  switch (errorCode) {
1521
1543
  case "ConcurrentModificationException":
1522
1544
  case "com.amazonaws.cloudwatchevents#ConcurrentModificationException":
@@ -1532,10 +1554,12 @@ const deserializeAws_json1_1DisableRuleCommandError = async (output, context) =>
1532
1554
  throw await deserializeAws_json1_1ResourceNotFoundExceptionResponse(parsedOutput, context);
1533
1555
  default:
1534
1556
  const parsedBody = parsedOutput.body;
1557
+ const $metadata = deserializeMetadata(output);
1558
+ const statusCode = $metadata.httpStatusCode ? $metadata.httpStatusCode + "" : undefined;
1535
1559
  response = new CloudWatchEventsServiceException_1.CloudWatchEventsServiceException({
1536
- name: parsedBody.code || parsedBody.Code || errorCode,
1560
+ name: parsedBody.code || parsedBody.Code || errorCode || statusCode || "UnknowError",
1537
1561
  $fault: "client",
1538
- $metadata: deserializeMetadata(output),
1562
+ $metadata,
1539
1563
  });
1540
1564
  throw (0, smithy_client_1.decorateServiceException)(response, parsedBody);
1541
1565
  }
@@ -1557,8 +1581,7 @@ const deserializeAws_json1_1EnableRuleCommandError = async (output, context) =>
1557
1581
  body: await parseBody(output.body, context),
1558
1582
  };
1559
1583
  let response;
1560
- let errorCode = "UnknownError";
1561
- errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1584
+ const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1562
1585
  switch (errorCode) {
1563
1586
  case "ConcurrentModificationException":
1564
1587
  case "com.amazonaws.cloudwatchevents#ConcurrentModificationException":
@@ -1574,10 +1597,12 @@ const deserializeAws_json1_1EnableRuleCommandError = async (output, context) =>
1574
1597
  throw await deserializeAws_json1_1ResourceNotFoundExceptionResponse(parsedOutput, context);
1575
1598
  default:
1576
1599
  const parsedBody = parsedOutput.body;
1600
+ const $metadata = deserializeMetadata(output);
1601
+ const statusCode = $metadata.httpStatusCode ? $metadata.httpStatusCode + "" : undefined;
1577
1602
  response = new CloudWatchEventsServiceException_1.CloudWatchEventsServiceException({
1578
- name: parsedBody.code || parsedBody.Code || errorCode,
1603
+ name: parsedBody.code || parsedBody.Code || errorCode || statusCode || "UnknowError",
1579
1604
  $fault: "client",
1580
- $metadata: deserializeMetadata(output),
1605
+ $metadata,
1581
1606
  });
1582
1607
  throw (0, smithy_client_1.decorateServiceException)(response, parsedBody);
1583
1608
  }
@@ -1602,18 +1627,19 @@ const deserializeAws_json1_1ListApiDestinationsCommandError = async (output, con
1602
1627
  body: await parseBody(output.body, context),
1603
1628
  };
1604
1629
  let response;
1605
- let errorCode = "UnknownError";
1606
- errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1630
+ const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1607
1631
  switch (errorCode) {
1608
1632
  case "InternalException":
1609
1633
  case "com.amazonaws.cloudwatchevents#InternalException":
1610
1634
  throw await deserializeAws_json1_1InternalExceptionResponse(parsedOutput, context);
1611
1635
  default:
1612
1636
  const parsedBody = parsedOutput.body;
1637
+ const $metadata = deserializeMetadata(output);
1638
+ const statusCode = $metadata.httpStatusCode ? $metadata.httpStatusCode + "" : undefined;
1613
1639
  response = new CloudWatchEventsServiceException_1.CloudWatchEventsServiceException({
1614
- name: parsedBody.code || parsedBody.Code || errorCode,
1640
+ name: parsedBody.code || parsedBody.Code || errorCode || statusCode || "UnknowError",
1615
1641
  $fault: "client",
1616
- $metadata: deserializeMetadata(output),
1642
+ $metadata,
1617
1643
  });
1618
1644
  throw (0, smithy_client_1.decorateServiceException)(response, parsedBody);
1619
1645
  }
@@ -1638,8 +1664,7 @@ const deserializeAws_json1_1ListArchivesCommandError = async (output, context) =
1638
1664
  body: await parseBody(output.body, context),
1639
1665
  };
1640
1666
  let response;
1641
- let errorCode = "UnknownError";
1642
- errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1667
+ const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1643
1668
  switch (errorCode) {
1644
1669
  case "InternalException":
1645
1670
  case "com.amazonaws.cloudwatchevents#InternalException":
@@ -1649,10 +1674,12 @@ const deserializeAws_json1_1ListArchivesCommandError = async (output, context) =
1649
1674
  throw await deserializeAws_json1_1ResourceNotFoundExceptionResponse(parsedOutput, context);
1650
1675
  default:
1651
1676
  const parsedBody = parsedOutput.body;
1677
+ const $metadata = deserializeMetadata(output);
1678
+ const statusCode = $metadata.httpStatusCode ? $metadata.httpStatusCode + "" : undefined;
1652
1679
  response = new CloudWatchEventsServiceException_1.CloudWatchEventsServiceException({
1653
- name: parsedBody.code || parsedBody.Code || errorCode,
1680
+ name: parsedBody.code || parsedBody.Code || errorCode || statusCode || "UnknowError",
1654
1681
  $fault: "client",
1655
- $metadata: deserializeMetadata(output),
1682
+ $metadata,
1656
1683
  });
1657
1684
  throw (0, smithy_client_1.decorateServiceException)(response, parsedBody);
1658
1685
  }
@@ -1677,18 +1704,19 @@ const deserializeAws_json1_1ListConnectionsCommandError = async (output, context
1677
1704
  body: await parseBody(output.body, context),
1678
1705
  };
1679
1706
  let response;
1680
- let errorCode = "UnknownError";
1681
- errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1707
+ const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1682
1708
  switch (errorCode) {
1683
1709
  case "InternalException":
1684
1710
  case "com.amazonaws.cloudwatchevents#InternalException":
1685
1711
  throw await deserializeAws_json1_1InternalExceptionResponse(parsedOutput, context);
1686
1712
  default:
1687
1713
  const parsedBody = parsedOutput.body;
1714
+ const $metadata = deserializeMetadata(output);
1715
+ const statusCode = $metadata.httpStatusCode ? $metadata.httpStatusCode + "" : undefined;
1688
1716
  response = new CloudWatchEventsServiceException_1.CloudWatchEventsServiceException({
1689
- name: parsedBody.code || parsedBody.Code || errorCode,
1717
+ name: parsedBody.code || parsedBody.Code || errorCode || statusCode || "UnknowError",
1690
1718
  $fault: "client",
1691
- $metadata: deserializeMetadata(output),
1719
+ $metadata,
1692
1720
  });
1693
1721
  throw (0, smithy_client_1.decorateServiceException)(response, parsedBody);
1694
1722
  }
@@ -1713,18 +1741,19 @@ const deserializeAws_json1_1ListEventBusesCommandError = async (output, context)
1713
1741
  body: await parseBody(output.body, context),
1714
1742
  };
1715
1743
  let response;
1716
- let errorCode = "UnknownError";
1717
- errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1744
+ const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1718
1745
  switch (errorCode) {
1719
1746
  case "InternalException":
1720
1747
  case "com.amazonaws.cloudwatchevents#InternalException":
1721
1748
  throw await deserializeAws_json1_1InternalExceptionResponse(parsedOutput, context);
1722
1749
  default:
1723
1750
  const parsedBody = parsedOutput.body;
1751
+ const $metadata = deserializeMetadata(output);
1752
+ const statusCode = $metadata.httpStatusCode ? $metadata.httpStatusCode + "" : undefined;
1724
1753
  response = new CloudWatchEventsServiceException_1.CloudWatchEventsServiceException({
1725
- name: parsedBody.code || parsedBody.Code || errorCode,
1754
+ name: parsedBody.code || parsedBody.Code || errorCode || statusCode || "UnknowError",
1726
1755
  $fault: "client",
1727
- $metadata: deserializeMetadata(output),
1756
+ $metadata,
1728
1757
  });
1729
1758
  throw (0, smithy_client_1.decorateServiceException)(response, parsedBody);
1730
1759
  }
@@ -1749,8 +1778,7 @@ const deserializeAws_json1_1ListEventSourcesCommandError = async (output, contex
1749
1778
  body: await parseBody(output.body, context),
1750
1779
  };
1751
1780
  let response;
1752
- let errorCode = "UnknownError";
1753
- errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1781
+ const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1754
1782
  switch (errorCode) {
1755
1783
  case "InternalException":
1756
1784
  case "com.amazonaws.cloudwatchevents#InternalException":
@@ -1760,10 +1788,12 @@ const deserializeAws_json1_1ListEventSourcesCommandError = async (output, contex
1760
1788
  throw await deserializeAws_json1_1OperationDisabledExceptionResponse(parsedOutput, context);
1761
1789
  default:
1762
1790
  const parsedBody = parsedOutput.body;
1791
+ const $metadata = deserializeMetadata(output);
1792
+ const statusCode = $metadata.httpStatusCode ? $metadata.httpStatusCode + "" : undefined;
1763
1793
  response = new CloudWatchEventsServiceException_1.CloudWatchEventsServiceException({
1764
- name: parsedBody.code || parsedBody.Code || errorCode,
1794
+ name: parsedBody.code || parsedBody.Code || errorCode || statusCode || "UnknowError",
1765
1795
  $fault: "client",
1766
- $metadata: deserializeMetadata(output),
1796
+ $metadata,
1767
1797
  });
1768
1798
  throw (0, smithy_client_1.decorateServiceException)(response, parsedBody);
1769
1799
  }
@@ -1788,8 +1818,7 @@ const deserializeAws_json1_1ListPartnerEventSourceAccountsCommandError = async (
1788
1818
  body: await parseBody(output.body, context),
1789
1819
  };
1790
1820
  let response;
1791
- let errorCode = "UnknownError";
1792
- errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1821
+ const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1793
1822
  switch (errorCode) {
1794
1823
  case "InternalException":
1795
1824
  case "com.amazonaws.cloudwatchevents#InternalException":
@@ -1802,10 +1831,12 @@ const deserializeAws_json1_1ListPartnerEventSourceAccountsCommandError = async (
1802
1831
  throw await deserializeAws_json1_1ResourceNotFoundExceptionResponse(parsedOutput, context);
1803
1832
  default:
1804
1833
  const parsedBody = parsedOutput.body;
1834
+ const $metadata = deserializeMetadata(output);
1835
+ const statusCode = $metadata.httpStatusCode ? $metadata.httpStatusCode + "" : undefined;
1805
1836
  response = new CloudWatchEventsServiceException_1.CloudWatchEventsServiceException({
1806
- name: parsedBody.code || parsedBody.Code || errorCode,
1837
+ name: parsedBody.code || parsedBody.Code || errorCode || statusCode || "UnknowError",
1807
1838
  $fault: "client",
1808
- $metadata: deserializeMetadata(output),
1839
+ $metadata,
1809
1840
  });
1810
1841
  throw (0, smithy_client_1.decorateServiceException)(response, parsedBody);
1811
1842
  }
@@ -1830,8 +1861,7 @@ const deserializeAws_json1_1ListPartnerEventSourcesCommandError = async (output,
1830
1861
  body: await parseBody(output.body, context),
1831
1862
  };
1832
1863
  let response;
1833
- let errorCode = "UnknownError";
1834
- errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1864
+ const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1835
1865
  switch (errorCode) {
1836
1866
  case "InternalException":
1837
1867
  case "com.amazonaws.cloudwatchevents#InternalException":
@@ -1841,10 +1871,12 @@ const deserializeAws_json1_1ListPartnerEventSourcesCommandError = async (output,
1841
1871
  throw await deserializeAws_json1_1OperationDisabledExceptionResponse(parsedOutput, context);
1842
1872
  default:
1843
1873
  const parsedBody = parsedOutput.body;
1874
+ const $metadata = deserializeMetadata(output);
1875
+ const statusCode = $metadata.httpStatusCode ? $metadata.httpStatusCode + "" : undefined;
1844
1876
  response = new CloudWatchEventsServiceException_1.CloudWatchEventsServiceException({
1845
- name: parsedBody.code || parsedBody.Code || errorCode,
1877
+ name: parsedBody.code || parsedBody.Code || errorCode || statusCode || "UnknowError",
1846
1878
  $fault: "client",
1847
- $metadata: deserializeMetadata(output),
1879
+ $metadata,
1848
1880
  });
1849
1881
  throw (0, smithy_client_1.decorateServiceException)(response, parsedBody);
1850
1882
  }
@@ -1869,18 +1901,19 @@ const deserializeAws_json1_1ListReplaysCommandError = async (output, context) =>
1869
1901
  body: await parseBody(output.body, context),
1870
1902
  };
1871
1903
  let response;
1872
- let errorCode = "UnknownError";
1873
- errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1904
+ const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1874
1905
  switch (errorCode) {
1875
1906
  case "InternalException":
1876
1907
  case "com.amazonaws.cloudwatchevents#InternalException":
1877
1908
  throw await deserializeAws_json1_1InternalExceptionResponse(parsedOutput, context);
1878
1909
  default:
1879
1910
  const parsedBody = parsedOutput.body;
1911
+ const $metadata = deserializeMetadata(output);
1912
+ const statusCode = $metadata.httpStatusCode ? $metadata.httpStatusCode + "" : undefined;
1880
1913
  response = new CloudWatchEventsServiceException_1.CloudWatchEventsServiceException({
1881
- name: parsedBody.code || parsedBody.Code || errorCode,
1914
+ name: parsedBody.code || parsedBody.Code || errorCode || statusCode || "UnknowError",
1882
1915
  $fault: "client",
1883
- $metadata: deserializeMetadata(output),
1916
+ $metadata,
1884
1917
  });
1885
1918
  throw (0, smithy_client_1.decorateServiceException)(response, parsedBody);
1886
1919
  }
@@ -1905,8 +1938,7 @@ const deserializeAws_json1_1ListRuleNamesByTargetCommandError = async (output, c
1905
1938
  body: await parseBody(output.body, context),
1906
1939
  };
1907
1940
  let response;
1908
- let errorCode = "UnknownError";
1909
- errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1941
+ const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1910
1942
  switch (errorCode) {
1911
1943
  case "InternalException":
1912
1944
  case "com.amazonaws.cloudwatchevents#InternalException":
@@ -1916,10 +1948,12 @@ const deserializeAws_json1_1ListRuleNamesByTargetCommandError = async (output, c
1916
1948
  throw await deserializeAws_json1_1ResourceNotFoundExceptionResponse(parsedOutput, context);
1917
1949
  default:
1918
1950
  const parsedBody = parsedOutput.body;
1951
+ const $metadata = deserializeMetadata(output);
1952
+ const statusCode = $metadata.httpStatusCode ? $metadata.httpStatusCode + "" : undefined;
1919
1953
  response = new CloudWatchEventsServiceException_1.CloudWatchEventsServiceException({
1920
- name: parsedBody.code || parsedBody.Code || errorCode,
1954
+ name: parsedBody.code || parsedBody.Code || errorCode || statusCode || "UnknowError",
1921
1955
  $fault: "client",
1922
- $metadata: deserializeMetadata(output),
1956
+ $metadata,
1923
1957
  });
1924
1958
  throw (0, smithy_client_1.decorateServiceException)(response, parsedBody);
1925
1959
  }
@@ -1944,8 +1978,7 @@ const deserializeAws_json1_1ListRulesCommandError = async (output, context) => {
1944
1978
  body: await parseBody(output.body, context),
1945
1979
  };
1946
1980
  let response;
1947
- let errorCode = "UnknownError";
1948
- errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1981
+ const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1949
1982
  switch (errorCode) {
1950
1983
  case "InternalException":
1951
1984
  case "com.amazonaws.cloudwatchevents#InternalException":
@@ -1955,10 +1988,12 @@ const deserializeAws_json1_1ListRulesCommandError = async (output, context) => {
1955
1988
  throw await deserializeAws_json1_1ResourceNotFoundExceptionResponse(parsedOutput, context);
1956
1989
  default:
1957
1990
  const parsedBody = parsedOutput.body;
1991
+ const $metadata = deserializeMetadata(output);
1992
+ const statusCode = $metadata.httpStatusCode ? $metadata.httpStatusCode + "" : undefined;
1958
1993
  response = new CloudWatchEventsServiceException_1.CloudWatchEventsServiceException({
1959
- name: parsedBody.code || parsedBody.Code || errorCode,
1994
+ name: parsedBody.code || parsedBody.Code || errorCode || statusCode || "UnknowError",
1960
1995
  $fault: "client",
1961
- $metadata: deserializeMetadata(output),
1996
+ $metadata,
1962
1997
  });
1963
1998
  throw (0, smithy_client_1.decorateServiceException)(response, parsedBody);
1964
1999
  }
@@ -1983,8 +2018,7 @@ const deserializeAws_json1_1ListTagsForResourceCommandError = async (output, con
1983
2018
  body: await parseBody(output.body, context),
1984
2019
  };
1985
2020
  let response;
1986
- let errorCode = "UnknownError";
1987
- errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
2021
+ const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1988
2022
  switch (errorCode) {
1989
2023
  case "InternalException":
1990
2024
  case "com.amazonaws.cloudwatchevents#InternalException":
@@ -1994,10 +2028,12 @@ const deserializeAws_json1_1ListTagsForResourceCommandError = async (output, con
1994
2028
  throw await deserializeAws_json1_1ResourceNotFoundExceptionResponse(parsedOutput, context);
1995
2029
  default:
1996
2030
  const parsedBody = parsedOutput.body;
2031
+ const $metadata = deserializeMetadata(output);
2032
+ const statusCode = $metadata.httpStatusCode ? $metadata.httpStatusCode + "" : undefined;
1997
2033
  response = new CloudWatchEventsServiceException_1.CloudWatchEventsServiceException({
1998
- name: parsedBody.code || parsedBody.Code || errorCode,
2034
+ name: parsedBody.code || parsedBody.Code || errorCode || statusCode || "UnknowError",
1999
2035
  $fault: "client",
2000
- $metadata: deserializeMetadata(output),
2036
+ $metadata,
2001
2037
  });
2002
2038
  throw (0, smithy_client_1.decorateServiceException)(response, parsedBody);
2003
2039
  }
@@ -2022,8 +2058,7 @@ const deserializeAws_json1_1ListTargetsByRuleCommandError = async (output, conte
2022
2058
  body: await parseBody(output.body, context),
2023
2059
  };
2024
2060
  let response;
2025
- let errorCode = "UnknownError";
2026
- errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
2061
+ const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
2027
2062
  switch (errorCode) {
2028
2063
  case "InternalException":
2029
2064
  case "com.amazonaws.cloudwatchevents#InternalException":
@@ -2033,10 +2068,12 @@ const deserializeAws_json1_1ListTargetsByRuleCommandError = async (output, conte
2033
2068
  throw await deserializeAws_json1_1ResourceNotFoundExceptionResponse(parsedOutput, context);
2034
2069
  default:
2035
2070
  const parsedBody = parsedOutput.body;
2071
+ const $metadata = deserializeMetadata(output);
2072
+ const statusCode = $metadata.httpStatusCode ? $metadata.httpStatusCode + "" : undefined;
2036
2073
  response = new CloudWatchEventsServiceException_1.CloudWatchEventsServiceException({
2037
- name: parsedBody.code || parsedBody.Code || errorCode,
2074
+ name: parsedBody.code || parsedBody.Code || errorCode || statusCode || "UnknowError",
2038
2075
  $fault: "client",
2039
- $metadata: deserializeMetadata(output),
2076
+ $metadata,
2040
2077
  });
2041
2078
  throw (0, smithy_client_1.decorateServiceException)(response, parsedBody);
2042
2079
  }
@@ -2061,18 +2098,19 @@ const deserializeAws_json1_1PutEventsCommandError = async (output, context) => {
2061
2098
  body: await parseBody(output.body, context),
2062
2099
  };
2063
2100
  let response;
2064
- let errorCode = "UnknownError";
2065
- errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
2101
+ const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
2066
2102
  switch (errorCode) {
2067
2103
  case "InternalException":
2068
2104
  case "com.amazonaws.cloudwatchevents#InternalException":
2069
2105
  throw await deserializeAws_json1_1InternalExceptionResponse(parsedOutput, context);
2070
2106
  default:
2071
2107
  const parsedBody = parsedOutput.body;
2108
+ const $metadata = deserializeMetadata(output);
2109
+ const statusCode = $metadata.httpStatusCode ? $metadata.httpStatusCode + "" : undefined;
2072
2110
  response = new CloudWatchEventsServiceException_1.CloudWatchEventsServiceException({
2073
- name: parsedBody.code || parsedBody.Code || errorCode,
2111
+ name: parsedBody.code || parsedBody.Code || errorCode || statusCode || "UnknowError",
2074
2112
  $fault: "client",
2075
- $metadata: deserializeMetadata(output),
2113
+ $metadata,
2076
2114
  });
2077
2115
  throw (0, smithy_client_1.decorateServiceException)(response, parsedBody);
2078
2116
  }
@@ -2097,8 +2135,7 @@ const deserializeAws_json1_1PutPartnerEventsCommandError = async (output, contex
2097
2135
  body: await parseBody(output.body, context),
2098
2136
  };
2099
2137
  let response;
2100
- let errorCode = "UnknownError";
2101
- errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
2138
+ const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
2102
2139
  switch (errorCode) {
2103
2140
  case "InternalException":
2104
2141
  case "com.amazonaws.cloudwatchevents#InternalException":
@@ -2108,10 +2145,12 @@ const deserializeAws_json1_1PutPartnerEventsCommandError = async (output, contex
2108
2145
  throw await deserializeAws_json1_1OperationDisabledExceptionResponse(parsedOutput, context);
2109
2146
  default:
2110
2147
  const parsedBody = parsedOutput.body;
2148
+ const $metadata = deserializeMetadata(output);
2149
+ const statusCode = $metadata.httpStatusCode ? $metadata.httpStatusCode + "" : undefined;
2111
2150
  response = new CloudWatchEventsServiceException_1.CloudWatchEventsServiceException({
2112
- name: parsedBody.code || parsedBody.Code || errorCode,
2151
+ name: parsedBody.code || parsedBody.Code || errorCode || statusCode || "UnknowError",
2113
2152
  $fault: "client",
2114
- $metadata: deserializeMetadata(output),
2153
+ $metadata,
2115
2154
  });
2116
2155
  throw (0, smithy_client_1.decorateServiceException)(response, parsedBody);
2117
2156
  }
@@ -2133,8 +2172,7 @@ const deserializeAws_json1_1PutPermissionCommandError = async (output, context)
2133
2172
  body: await parseBody(output.body, context),
2134
2173
  };
2135
2174
  let response;
2136
- let errorCode = "UnknownError";
2137
- errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
2175
+ const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
2138
2176
  switch (errorCode) {
2139
2177
  case "ConcurrentModificationException":
2140
2178
  case "com.amazonaws.cloudwatchevents#ConcurrentModificationException":
@@ -2153,10 +2191,12 @@ const deserializeAws_json1_1PutPermissionCommandError = async (output, context)
2153
2191
  throw await deserializeAws_json1_1ResourceNotFoundExceptionResponse(parsedOutput, context);
2154
2192
  default:
2155
2193
  const parsedBody = parsedOutput.body;
2194
+ const $metadata = deserializeMetadata(output);
2195
+ const statusCode = $metadata.httpStatusCode ? $metadata.httpStatusCode + "" : undefined;
2156
2196
  response = new CloudWatchEventsServiceException_1.CloudWatchEventsServiceException({
2157
- name: parsedBody.code || parsedBody.Code || errorCode,
2197
+ name: parsedBody.code || parsedBody.Code || errorCode || statusCode || "UnknowError",
2158
2198
  $fault: "client",
2159
- $metadata: deserializeMetadata(output),
2199
+ $metadata,
2160
2200
  });
2161
2201
  throw (0, smithy_client_1.decorateServiceException)(response, parsedBody);
2162
2202
  }
@@ -2181,8 +2221,7 @@ const deserializeAws_json1_1PutRuleCommandError = async (output, context) => {
2181
2221
  body: await parseBody(output.body, context),
2182
2222
  };
2183
2223
  let response;
2184
- let errorCode = "UnknownError";
2185
- errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
2224
+ const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
2186
2225
  switch (errorCode) {
2187
2226
  case "ConcurrentModificationException":
2188
2227
  case "com.amazonaws.cloudwatchevents#ConcurrentModificationException":
@@ -2204,10 +2243,12 @@ const deserializeAws_json1_1PutRuleCommandError = async (output, context) => {
2204
2243
  throw await deserializeAws_json1_1ResourceNotFoundExceptionResponse(parsedOutput, context);
2205
2244
  default:
2206
2245
  const parsedBody = parsedOutput.body;
2246
+ const $metadata = deserializeMetadata(output);
2247
+ const statusCode = $metadata.httpStatusCode ? $metadata.httpStatusCode + "" : undefined;
2207
2248
  response = new CloudWatchEventsServiceException_1.CloudWatchEventsServiceException({
2208
- name: parsedBody.code || parsedBody.Code || errorCode,
2249
+ name: parsedBody.code || parsedBody.Code || errorCode || statusCode || "UnknowError",
2209
2250
  $fault: "client",
2210
- $metadata: deserializeMetadata(output),
2251
+ $metadata,
2211
2252
  });
2212
2253
  throw (0, smithy_client_1.decorateServiceException)(response, parsedBody);
2213
2254
  }
@@ -2232,8 +2273,7 @@ const deserializeAws_json1_1PutTargetsCommandError = async (output, context) =>
2232
2273
  body: await parseBody(output.body, context),
2233
2274
  };
2234
2275
  let response;
2235
- let errorCode = "UnknownError";
2236
- errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
2276
+ const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
2237
2277
  switch (errorCode) {
2238
2278
  case "ConcurrentModificationException":
2239
2279
  case "com.amazonaws.cloudwatchevents#ConcurrentModificationException":
@@ -2252,10 +2292,12 @@ const deserializeAws_json1_1PutTargetsCommandError = async (output, context) =>
2252
2292
  throw await deserializeAws_json1_1ResourceNotFoundExceptionResponse(parsedOutput, context);
2253
2293
  default:
2254
2294
  const parsedBody = parsedOutput.body;
2295
+ const $metadata = deserializeMetadata(output);
2296
+ const statusCode = $metadata.httpStatusCode ? $metadata.httpStatusCode + "" : undefined;
2255
2297
  response = new CloudWatchEventsServiceException_1.CloudWatchEventsServiceException({
2256
- name: parsedBody.code || parsedBody.Code || errorCode,
2298
+ name: parsedBody.code || parsedBody.Code || errorCode || statusCode || "UnknowError",
2257
2299
  $fault: "client",
2258
- $metadata: deserializeMetadata(output),
2300
+ $metadata,
2259
2301
  });
2260
2302
  throw (0, smithy_client_1.decorateServiceException)(response, parsedBody);
2261
2303
  }
@@ -2277,8 +2319,7 @@ const deserializeAws_json1_1RemovePermissionCommandError = async (output, contex
2277
2319
  body: await parseBody(output.body, context),
2278
2320
  };
2279
2321
  let response;
2280
- let errorCode = "UnknownError";
2281
- errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
2322
+ const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
2282
2323
  switch (errorCode) {
2283
2324
  case "ConcurrentModificationException":
2284
2325
  case "com.amazonaws.cloudwatchevents#ConcurrentModificationException":
@@ -2294,10 +2335,12 @@ const deserializeAws_json1_1RemovePermissionCommandError = async (output, contex
2294
2335
  throw await deserializeAws_json1_1ResourceNotFoundExceptionResponse(parsedOutput, context);
2295
2336
  default:
2296
2337
  const parsedBody = parsedOutput.body;
2338
+ const $metadata = deserializeMetadata(output);
2339
+ const statusCode = $metadata.httpStatusCode ? $metadata.httpStatusCode + "" : undefined;
2297
2340
  response = new CloudWatchEventsServiceException_1.CloudWatchEventsServiceException({
2298
- name: parsedBody.code || parsedBody.Code || errorCode,
2341
+ name: parsedBody.code || parsedBody.Code || errorCode || statusCode || "UnknowError",
2299
2342
  $fault: "client",
2300
- $metadata: deserializeMetadata(output),
2343
+ $metadata,
2301
2344
  });
2302
2345
  throw (0, smithy_client_1.decorateServiceException)(response, parsedBody);
2303
2346
  }
@@ -2322,8 +2365,7 @@ const deserializeAws_json1_1RemoveTargetsCommandError = async (output, context)
2322
2365
  body: await parseBody(output.body, context),
2323
2366
  };
2324
2367
  let response;
2325
- let errorCode = "UnknownError";
2326
- errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
2368
+ const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
2327
2369
  switch (errorCode) {
2328
2370
  case "ConcurrentModificationException":
2329
2371
  case "com.amazonaws.cloudwatchevents#ConcurrentModificationException":
@@ -2339,10 +2381,12 @@ const deserializeAws_json1_1RemoveTargetsCommandError = async (output, context)
2339
2381
  throw await deserializeAws_json1_1ResourceNotFoundExceptionResponse(parsedOutput, context);
2340
2382
  default:
2341
2383
  const parsedBody = parsedOutput.body;
2384
+ const $metadata = deserializeMetadata(output);
2385
+ const statusCode = $metadata.httpStatusCode ? $metadata.httpStatusCode + "" : undefined;
2342
2386
  response = new CloudWatchEventsServiceException_1.CloudWatchEventsServiceException({
2343
- name: parsedBody.code || parsedBody.Code || errorCode,
2387
+ name: parsedBody.code || parsedBody.Code || errorCode || statusCode || "UnknowError",
2344
2388
  $fault: "client",
2345
- $metadata: deserializeMetadata(output),
2389
+ $metadata,
2346
2390
  });
2347
2391
  throw (0, smithy_client_1.decorateServiceException)(response, parsedBody);
2348
2392
  }
@@ -2367,8 +2411,7 @@ const deserializeAws_json1_1StartReplayCommandError = async (output, context) =>
2367
2411
  body: await parseBody(output.body, context),
2368
2412
  };
2369
2413
  let response;
2370
- let errorCode = "UnknownError";
2371
- errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
2414
+ const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
2372
2415
  switch (errorCode) {
2373
2416
  case "InternalException":
2374
2417
  case "com.amazonaws.cloudwatchevents#InternalException":
@@ -2387,10 +2430,12 @@ const deserializeAws_json1_1StartReplayCommandError = async (output, context) =>
2387
2430
  throw await deserializeAws_json1_1ResourceNotFoundExceptionResponse(parsedOutput, context);
2388
2431
  default:
2389
2432
  const parsedBody = parsedOutput.body;
2433
+ const $metadata = deserializeMetadata(output);
2434
+ const statusCode = $metadata.httpStatusCode ? $metadata.httpStatusCode + "" : undefined;
2390
2435
  response = new CloudWatchEventsServiceException_1.CloudWatchEventsServiceException({
2391
- name: parsedBody.code || parsedBody.Code || errorCode,
2436
+ name: parsedBody.code || parsedBody.Code || errorCode || statusCode || "UnknowError",
2392
2437
  $fault: "client",
2393
- $metadata: deserializeMetadata(output),
2438
+ $metadata,
2394
2439
  });
2395
2440
  throw (0, smithy_client_1.decorateServiceException)(response, parsedBody);
2396
2441
  }
@@ -2415,8 +2460,7 @@ const deserializeAws_json1_1TagResourceCommandError = async (output, context) =>
2415
2460
  body: await parseBody(output.body, context),
2416
2461
  };
2417
2462
  let response;
2418
- let errorCode = "UnknownError";
2419
- errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
2463
+ const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
2420
2464
  switch (errorCode) {
2421
2465
  case "ConcurrentModificationException":
2422
2466
  case "com.amazonaws.cloudwatchevents#ConcurrentModificationException":
@@ -2432,10 +2476,12 @@ const deserializeAws_json1_1TagResourceCommandError = async (output, context) =>
2432
2476
  throw await deserializeAws_json1_1ResourceNotFoundExceptionResponse(parsedOutput, context);
2433
2477
  default:
2434
2478
  const parsedBody = parsedOutput.body;
2479
+ const $metadata = deserializeMetadata(output);
2480
+ const statusCode = $metadata.httpStatusCode ? $metadata.httpStatusCode + "" : undefined;
2435
2481
  response = new CloudWatchEventsServiceException_1.CloudWatchEventsServiceException({
2436
- name: parsedBody.code || parsedBody.Code || errorCode,
2482
+ name: parsedBody.code || parsedBody.Code || errorCode || statusCode || "UnknowError",
2437
2483
  $fault: "client",
2438
- $metadata: deserializeMetadata(output),
2484
+ $metadata,
2439
2485
  });
2440
2486
  throw (0, smithy_client_1.decorateServiceException)(response, parsedBody);
2441
2487
  }
@@ -2460,8 +2506,7 @@ const deserializeAws_json1_1TestEventPatternCommandError = async (output, contex
2460
2506
  body: await parseBody(output.body, context),
2461
2507
  };
2462
2508
  let response;
2463
- let errorCode = "UnknownError";
2464
- errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
2509
+ const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
2465
2510
  switch (errorCode) {
2466
2511
  case "InternalException":
2467
2512
  case "com.amazonaws.cloudwatchevents#InternalException":
@@ -2471,10 +2516,12 @@ const deserializeAws_json1_1TestEventPatternCommandError = async (output, contex
2471
2516
  throw await deserializeAws_json1_1InvalidEventPatternExceptionResponse(parsedOutput, context);
2472
2517
  default:
2473
2518
  const parsedBody = parsedOutput.body;
2519
+ const $metadata = deserializeMetadata(output);
2520
+ const statusCode = $metadata.httpStatusCode ? $metadata.httpStatusCode + "" : undefined;
2474
2521
  response = new CloudWatchEventsServiceException_1.CloudWatchEventsServiceException({
2475
- name: parsedBody.code || parsedBody.Code || errorCode,
2522
+ name: parsedBody.code || parsedBody.Code || errorCode || statusCode || "UnknowError",
2476
2523
  $fault: "client",
2477
- $metadata: deserializeMetadata(output),
2524
+ $metadata,
2478
2525
  });
2479
2526
  throw (0, smithy_client_1.decorateServiceException)(response, parsedBody);
2480
2527
  }
@@ -2499,8 +2546,7 @@ const deserializeAws_json1_1UntagResourceCommandError = async (output, context)
2499
2546
  body: await parseBody(output.body, context),
2500
2547
  };
2501
2548
  let response;
2502
- let errorCode = "UnknownError";
2503
- errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
2549
+ const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
2504
2550
  switch (errorCode) {
2505
2551
  case "ConcurrentModificationException":
2506
2552
  case "com.amazonaws.cloudwatchevents#ConcurrentModificationException":
@@ -2516,10 +2562,12 @@ const deserializeAws_json1_1UntagResourceCommandError = async (output, context)
2516
2562
  throw await deserializeAws_json1_1ResourceNotFoundExceptionResponse(parsedOutput, context);
2517
2563
  default:
2518
2564
  const parsedBody = parsedOutput.body;
2565
+ const $metadata = deserializeMetadata(output);
2566
+ const statusCode = $metadata.httpStatusCode ? $metadata.httpStatusCode + "" : undefined;
2519
2567
  response = new CloudWatchEventsServiceException_1.CloudWatchEventsServiceException({
2520
- name: parsedBody.code || parsedBody.Code || errorCode,
2568
+ name: parsedBody.code || parsedBody.Code || errorCode || statusCode || "UnknowError",
2521
2569
  $fault: "client",
2522
- $metadata: deserializeMetadata(output),
2570
+ $metadata,
2523
2571
  });
2524
2572
  throw (0, smithy_client_1.decorateServiceException)(response, parsedBody);
2525
2573
  }
@@ -2544,8 +2592,7 @@ const deserializeAws_json1_1UpdateApiDestinationCommandError = async (output, co
2544
2592
  body: await parseBody(output.body, context),
2545
2593
  };
2546
2594
  let response;
2547
- let errorCode = "UnknownError";
2548
- errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
2595
+ const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
2549
2596
  switch (errorCode) {
2550
2597
  case "ConcurrentModificationException":
2551
2598
  case "com.amazonaws.cloudwatchevents#ConcurrentModificationException":
@@ -2561,10 +2608,12 @@ const deserializeAws_json1_1UpdateApiDestinationCommandError = async (output, co
2561
2608
  throw await deserializeAws_json1_1ResourceNotFoundExceptionResponse(parsedOutput, context);
2562
2609
  default:
2563
2610
  const parsedBody = parsedOutput.body;
2611
+ const $metadata = deserializeMetadata(output);
2612
+ const statusCode = $metadata.httpStatusCode ? $metadata.httpStatusCode + "" : undefined;
2564
2613
  response = new CloudWatchEventsServiceException_1.CloudWatchEventsServiceException({
2565
- name: parsedBody.code || parsedBody.Code || errorCode,
2614
+ name: parsedBody.code || parsedBody.Code || errorCode || statusCode || "UnknowError",
2566
2615
  $fault: "client",
2567
- $metadata: deserializeMetadata(output),
2616
+ $metadata,
2568
2617
  });
2569
2618
  throw (0, smithy_client_1.decorateServiceException)(response, parsedBody);
2570
2619
  }
@@ -2589,8 +2638,7 @@ const deserializeAws_json1_1UpdateArchiveCommandError = async (output, context)
2589
2638
  body: await parseBody(output.body, context),
2590
2639
  };
2591
2640
  let response;
2592
- let errorCode = "UnknownError";
2593
- errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
2641
+ const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
2594
2642
  switch (errorCode) {
2595
2643
  case "ConcurrentModificationException":
2596
2644
  case "com.amazonaws.cloudwatchevents#ConcurrentModificationException":
@@ -2609,10 +2657,12 @@ const deserializeAws_json1_1UpdateArchiveCommandError = async (output, context)
2609
2657
  throw await deserializeAws_json1_1ResourceNotFoundExceptionResponse(parsedOutput, context);
2610
2658
  default:
2611
2659
  const parsedBody = parsedOutput.body;
2660
+ const $metadata = deserializeMetadata(output);
2661
+ const statusCode = $metadata.httpStatusCode ? $metadata.httpStatusCode + "" : undefined;
2612
2662
  response = new CloudWatchEventsServiceException_1.CloudWatchEventsServiceException({
2613
- name: parsedBody.code || parsedBody.Code || errorCode,
2663
+ name: parsedBody.code || parsedBody.Code || errorCode || statusCode || "UnknowError",
2614
2664
  $fault: "client",
2615
- $metadata: deserializeMetadata(output),
2665
+ $metadata,
2616
2666
  });
2617
2667
  throw (0, smithy_client_1.decorateServiceException)(response, parsedBody);
2618
2668
  }
@@ -2637,8 +2687,7 @@ const deserializeAws_json1_1UpdateConnectionCommandError = async (output, contex
2637
2687
  body: await parseBody(output.body, context),
2638
2688
  };
2639
2689
  let response;
2640
- let errorCode = "UnknownError";
2641
- errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
2690
+ const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
2642
2691
  switch (errorCode) {
2643
2692
  case "ConcurrentModificationException":
2644
2693
  case "com.amazonaws.cloudwatchevents#ConcurrentModificationException":
@@ -2654,10 +2703,12 @@ const deserializeAws_json1_1UpdateConnectionCommandError = async (output, contex
2654
2703
  throw await deserializeAws_json1_1ResourceNotFoundExceptionResponse(parsedOutput, context);
2655
2704
  default:
2656
2705
  const parsedBody = parsedOutput.body;
2706
+ const $metadata = deserializeMetadata(output);
2707
+ const statusCode = $metadata.httpStatusCode ? $metadata.httpStatusCode + "" : undefined;
2657
2708
  response = new CloudWatchEventsServiceException_1.CloudWatchEventsServiceException({
2658
- name: parsedBody.code || parsedBody.Code || errorCode,
2709
+ name: parsedBody.code || parsedBody.Code || errorCode || statusCode || "UnknowError",
2659
2710
  $fault: "client",
2660
- $metadata: deserializeMetadata(output),
2711
+ $metadata,
2661
2712
  });
2662
2713
  throw (0, smithy_client_1.decorateServiceException)(response, parsedBody);
2663
2714
  }
@@ -2763,48 +2814,43 @@ const deserializeAws_json1_1ResourceNotFoundExceptionResponse = async (parsedOut
2763
2814
  };
2764
2815
  const serializeAws_json1_1ActivateEventSourceRequest = (input, context) => {
2765
2816
  return {
2766
- ...(input.Name !== undefined && input.Name !== null && { Name: input.Name }),
2817
+ ...(input.Name != null && { Name: input.Name }),
2767
2818
  };
2768
2819
  };
2769
2820
  const serializeAws_json1_1AwsVpcConfiguration = (input, context) => {
2770
2821
  return {
2771
- ...(input.AssignPublicIp !== undefined &&
2772
- input.AssignPublicIp !== null && { AssignPublicIp: input.AssignPublicIp }),
2773
- ...(input.SecurityGroups !== undefined &&
2774
- input.SecurityGroups !== null && {
2822
+ ...(input.AssignPublicIp != null && { AssignPublicIp: input.AssignPublicIp }),
2823
+ ...(input.SecurityGroups != null && {
2775
2824
  SecurityGroups: serializeAws_json1_1StringList(input.SecurityGroups, context),
2776
2825
  }),
2777
- ...(input.Subnets !== undefined &&
2778
- input.Subnets !== null && { Subnets: serializeAws_json1_1StringList(input.Subnets, context) }),
2826
+ ...(input.Subnets != null && { Subnets: serializeAws_json1_1StringList(input.Subnets, context) }),
2779
2827
  };
2780
2828
  };
2781
2829
  const serializeAws_json1_1BatchArrayProperties = (input, context) => {
2782
2830
  return {
2783
- ...(input.Size !== undefined && input.Size !== null && { Size: input.Size }),
2831
+ ...(input.Size != null && { Size: input.Size }),
2784
2832
  };
2785
2833
  };
2786
2834
  const serializeAws_json1_1BatchParameters = (input, context) => {
2787
2835
  return {
2788
- ...(input.ArrayProperties !== undefined &&
2789
- input.ArrayProperties !== null && {
2836
+ ...(input.ArrayProperties != null && {
2790
2837
  ArrayProperties: serializeAws_json1_1BatchArrayProperties(input.ArrayProperties, context),
2791
2838
  }),
2792
- ...(input.JobDefinition !== undefined && input.JobDefinition !== null && { JobDefinition: input.JobDefinition }),
2793
- ...(input.JobName !== undefined && input.JobName !== null && { JobName: input.JobName }),
2794
- ...(input.RetryStrategy !== undefined &&
2795
- input.RetryStrategy !== null && {
2839
+ ...(input.JobDefinition != null && { JobDefinition: input.JobDefinition }),
2840
+ ...(input.JobName != null && { JobName: input.JobName }),
2841
+ ...(input.RetryStrategy != null && {
2796
2842
  RetryStrategy: serializeAws_json1_1BatchRetryStrategy(input.RetryStrategy, context),
2797
2843
  }),
2798
2844
  };
2799
2845
  };
2800
2846
  const serializeAws_json1_1BatchRetryStrategy = (input, context) => {
2801
2847
  return {
2802
- ...(input.Attempts !== undefined && input.Attempts !== null && { Attempts: input.Attempts }),
2848
+ ...(input.Attempts != null && { Attempts: input.Attempts }),
2803
2849
  };
2804
2850
  };
2805
2851
  const serializeAws_json1_1CancelReplayRequest = (input, context) => {
2806
2852
  return {
2807
- ...(input.ReplayName !== undefined && input.ReplayName !== null && { ReplayName: input.ReplayName }),
2853
+ ...(input.ReplayName != null && { ReplayName: input.ReplayName }),
2808
2854
  };
2809
2855
  };
2810
2856
  const serializeAws_json1_1CapacityProviderStrategy = (input, context) => {
@@ -2819,24 +2865,23 @@ const serializeAws_json1_1CapacityProviderStrategy = (input, context) => {
2819
2865
  };
2820
2866
  const serializeAws_json1_1CapacityProviderStrategyItem = (input, context) => {
2821
2867
  return {
2822
- ...(input.base !== undefined && input.base !== null && { base: input.base }),
2823
- ...(input.capacityProvider !== undefined &&
2824
- input.capacityProvider !== null && { capacityProvider: input.capacityProvider }),
2825
- ...(input.weight !== undefined && input.weight !== null && { weight: input.weight }),
2868
+ ...(input.base != null && { base: input.base }),
2869
+ ...(input.capacityProvider != null && { capacityProvider: input.capacityProvider }),
2870
+ ...(input.weight != null && { weight: input.weight }),
2826
2871
  };
2827
2872
  };
2828
2873
  const serializeAws_json1_1Condition = (input, context) => {
2829
2874
  return {
2830
- ...(input.Key !== undefined && input.Key !== null && { Key: input.Key }),
2831
- ...(input.Type !== undefined && input.Type !== null && { Type: input.Type }),
2832
- ...(input.Value !== undefined && input.Value !== null && { Value: input.Value }),
2875
+ ...(input.Key != null && { Key: input.Key }),
2876
+ ...(input.Type != null && { Type: input.Type }),
2877
+ ...(input.Value != null && { Value: input.Value }),
2833
2878
  };
2834
2879
  };
2835
2880
  const serializeAws_json1_1ConnectionBodyParameter = (input, context) => {
2836
2881
  return {
2837
- ...(input.IsValueSecret !== undefined && input.IsValueSecret !== null && { IsValueSecret: input.IsValueSecret }),
2838
- ...(input.Key !== undefined && input.Key !== null && { Key: input.Key }),
2839
- ...(input.Value !== undefined && input.Value !== null && { Value: input.Value }),
2882
+ ...(input.IsValueSecret != null && { IsValueSecret: input.IsValueSecret }),
2883
+ ...(input.Key != null && { Key: input.Key }),
2884
+ ...(input.Value != null && { Value: input.Value }),
2840
2885
  };
2841
2886
  };
2842
2887
  const serializeAws_json1_1ConnectionBodyParametersList = (input, context) => {
@@ -2851,9 +2896,9 @@ const serializeAws_json1_1ConnectionBodyParametersList = (input, context) => {
2851
2896
  };
2852
2897
  const serializeAws_json1_1ConnectionHeaderParameter = (input, context) => {
2853
2898
  return {
2854
- ...(input.IsValueSecret !== undefined && input.IsValueSecret !== null && { IsValueSecret: input.IsValueSecret }),
2855
- ...(input.Key !== undefined && input.Key !== null && { Key: input.Key }),
2856
- ...(input.Value !== undefined && input.Value !== null && { Value: input.Value }),
2899
+ ...(input.IsValueSecret != null && { IsValueSecret: input.IsValueSecret }),
2900
+ ...(input.Key != null && { Key: input.Key }),
2901
+ ...(input.Value != null && { Value: input.Value }),
2857
2902
  };
2858
2903
  };
2859
2904
  const serializeAws_json1_1ConnectionHeaderParametersList = (input, context) => {
@@ -2868,25 +2913,22 @@ const serializeAws_json1_1ConnectionHeaderParametersList = (input, context) => {
2868
2913
  };
2869
2914
  const serializeAws_json1_1ConnectionHttpParameters = (input, context) => {
2870
2915
  return {
2871
- ...(input.BodyParameters !== undefined &&
2872
- input.BodyParameters !== null && {
2916
+ ...(input.BodyParameters != null && {
2873
2917
  BodyParameters: serializeAws_json1_1ConnectionBodyParametersList(input.BodyParameters, context),
2874
2918
  }),
2875
- ...(input.HeaderParameters !== undefined &&
2876
- input.HeaderParameters !== null && {
2919
+ ...(input.HeaderParameters != null && {
2877
2920
  HeaderParameters: serializeAws_json1_1ConnectionHeaderParametersList(input.HeaderParameters, context),
2878
2921
  }),
2879
- ...(input.QueryStringParameters !== undefined &&
2880
- input.QueryStringParameters !== null && {
2922
+ ...(input.QueryStringParameters != null && {
2881
2923
  QueryStringParameters: serializeAws_json1_1ConnectionQueryStringParametersList(input.QueryStringParameters, context),
2882
2924
  }),
2883
2925
  };
2884
2926
  };
2885
2927
  const serializeAws_json1_1ConnectionQueryStringParameter = (input, context) => {
2886
2928
  return {
2887
- ...(input.IsValueSecret !== undefined && input.IsValueSecret !== null && { IsValueSecret: input.IsValueSecret }),
2888
- ...(input.Key !== undefined && input.Key !== null && { Key: input.Key }),
2889
- ...(input.Value !== undefined && input.Value !== null && { Value: input.Value }),
2929
+ ...(input.IsValueSecret != null && { IsValueSecret: input.IsValueSecret }),
2930
+ ...(input.Key != null && { Key: input.Key }),
2931
+ ...(input.Value != null && { Value: input.Value }),
2890
2932
  };
2891
2933
  };
2892
2934
  const serializeAws_json1_1ConnectionQueryStringParametersList = (input, context) => {
@@ -2901,240 +2943,219 @@ const serializeAws_json1_1ConnectionQueryStringParametersList = (input, context)
2901
2943
  };
2902
2944
  const serializeAws_json1_1CreateApiDestinationRequest = (input, context) => {
2903
2945
  return {
2904
- ...(input.ConnectionArn !== undefined && input.ConnectionArn !== null && { ConnectionArn: input.ConnectionArn }),
2905
- ...(input.Description !== undefined && input.Description !== null && { Description: input.Description }),
2906
- ...(input.HttpMethod !== undefined && input.HttpMethod !== null && { HttpMethod: input.HttpMethod }),
2907
- ...(input.InvocationEndpoint !== undefined &&
2908
- input.InvocationEndpoint !== null && { InvocationEndpoint: input.InvocationEndpoint }),
2909
- ...(input.InvocationRateLimitPerSecond !== undefined &&
2910
- input.InvocationRateLimitPerSecond !== null && {
2946
+ ...(input.ConnectionArn != null && { ConnectionArn: input.ConnectionArn }),
2947
+ ...(input.Description != null && { Description: input.Description }),
2948
+ ...(input.HttpMethod != null && { HttpMethod: input.HttpMethod }),
2949
+ ...(input.InvocationEndpoint != null && { InvocationEndpoint: input.InvocationEndpoint }),
2950
+ ...(input.InvocationRateLimitPerSecond != null && {
2911
2951
  InvocationRateLimitPerSecond: input.InvocationRateLimitPerSecond,
2912
2952
  }),
2913
- ...(input.Name !== undefined && input.Name !== null && { Name: input.Name }),
2953
+ ...(input.Name != null && { Name: input.Name }),
2914
2954
  };
2915
2955
  };
2916
2956
  const serializeAws_json1_1CreateArchiveRequest = (input, context) => {
2917
2957
  return {
2918
- ...(input.ArchiveName !== undefined && input.ArchiveName !== null && { ArchiveName: input.ArchiveName }),
2919
- ...(input.Description !== undefined && input.Description !== null && { Description: input.Description }),
2920
- ...(input.EventPattern !== undefined && input.EventPattern !== null && { EventPattern: input.EventPattern }),
2921
- ...(input.EventSourceArn !== undefined &&
2922
- input.EventSourceArn !== null && { EventSourceArn: input.EventSourceArn }),
2923
- ...(input.RetentionDays !== undefined && input.RetentionDays !== null && { RetentionDays: input.RetentionDays }),
2958
+ ...(input.ArchiveName != null && { ArchiveName: input.ArchiveName }),
2959
+ ...(input.Description != null && { Description: input.Description }),
2960
+ ...(input.EventPattern != null && { EventPattern: input.EventPattern }),
2961
+ ...(input.EventSourceArn != null && { EventSourceArn: input.EventSourceArn }),
2962
+ ...(input.RetentionDays != null && { RetentionDays: input.RetentionDays }),
2924
2963
  };
2925
2964
  };
2926
2965
  const serializeAws_json1_1CreateConnectionApiKeyAuthRequestParameters = (input, context) => {
2927
2966
  return {
2928
- ...(input.ApiKeyName !== undefined && input.ApiKeyName !== null && { ApiKeyName: input.ApiKeyName }),
2929
- ...(input.ApiKeyValue !== undefined && input.ApiKeyValue !== null && { ApiKeyValue: input.ApiKeyValue }),
2967
+ ...(input.ApiKeyName != null && { ApiKeyName: input.ApiKeyName }),
2968
+ ...(input.ApiKeyValue != null && { ApiKeyValue: input.ApiKeyValue }),
2930
2969
  };
2931
2970
  };
2932
2971
  const serializeAws_json1_1CreateConnectionAuthRequestParameters = (input, context) => {
2933
2972
  return {
2934
- ...(input.ApiKeyAuthParameters !== undefined &&
2935
- input.ApiKeyAuthParameters !== null && {
2973
+ ...(input.ApiKeyAuthParameters != null && {
2936
2974
  ApiKeyAuthParameters: serializeAws_json1_1CreateConnectionApiKeyAuthRequestParameters(input.ApiKeyAuthParameters, context),
2937
2975
  }),
2938
- ...(input.BasicAuthParameters !== undefined &&
2939
- input.BasicAuthParameters !== null && {
2976
+ ...(input.BasicAuthParameters != null && {
2940
2977
  BasicAuthParameters: serializeAws_json1_1CreateConnectionBasicAuthRequestParameters(input.BasicAuthParameters, context),
2941
2978
  }),
2942
- ...(input.InvocationHttpParameters !== undefined &&
2943
- input.InvocationHttpParameters !== null && {
2979
+ ...(input.InvocationHttpParameters != null && {
2944
2980
  InvocationHttpParameters: serializeAws_json1_1ConnectionHttpParameters(input.InvocationHttpParameters, context),
2945
2981
  }),
2946
- ...(input.OAuthParameters !== undefined &&
2947
- input.OAuthParameters !== null && {
2982
+ ...(input.OAuthParameters != null && {
2948
2983
  OAuthParameters: serializeAws_json1_1CreateConnectionOAuthRequestParameters(input.OAuthParameters, context),
2949
2984
  }),
2950
2985
  };
2951
2986
  };
2952
2987
  const serializeAws_json1_1CreateConnectionBasicAuthRequestParameters = (input, context) => {
2953
2988
  return {
2954
- ...(input.Password !== undefined && input.Password !== null && { Password: input.Password }),
2955
- ...(input.Username !== undefined && input.Username !== null && { Username: input.Username }),
2989
+ ...(input.Password != null && { Password: input.Password }),
2990
+ ...(input.Username != null && { Username: input.Username }),
2956
2991
  };
2957
2992
  };
2958
2993
  const serializeAws_json1_1CreateConnectionOAuthClientRequestParameters = (input, context) => {
2959
2994
  return {
2960
- ...(input.ClientID !== undefined && input.ClientID !== null && { ClientID: input.ClientID }),
2961
- ...(input.ClientSecret !== undefined && input.ClientSecret !== null && { ClientSecret: input.ClientSecret }),
2995
+ ...(input.ClientID != null && { ClientID: input.ClientID }),
2996
+ ...(input.ClientSecret != null && { ClientSecret: input.ClientSecret }),
2962
2997
  };
2963
2998
  };
2964
2999
  const serializeAws_json1_1CreateConnectionOAuthRequestParameters = (input, context) => {
2965
3000
  return {
2966
- ...(input.AuthorizationEndpoint !== undefined &&
2967
- input.AuthorizationEndpoint !== null && { AuthorizationEndpoint: input.AuthorizationEndpoint }),
2968
- ...(input.ClientParameters !== undefined &&
2969
- input.ClientParameters !== null && {
3001
+ ...(input.AuthorizationEndpoint != null && { AuthorizationEndpoint: input.AuthorizationEndpoint }),
3002
+ ...(input.ClientParameters != null && {
2970
3003
  ClientParameters: serializeAws_json1_1CreateConnectionOAuthClientRequestParameters(input.ClientParameters, context),
2971
3004
  }),
2972
- ...(input.HttpMethod !== undefined && input.HttpMethod !== null && { HttpMethod: input.HttpMethod }),
2973
- ...(input.OAuthHttpParameters !== undefined &&
2974
- input.OAuthHttpParameters !== null && {
3005
+ ...(input.HttpMethod != null && { HttpMethod: input.HttpMethod }),
3006
+ ...(input.OAuthHttpParameters != null && {
2975
3007
  OAuthHttpParameters: serializeAws_json1_1ConnectionHttpParameters(input.OAuthHttpParameters, context),
2976
3008
  }),
2977
3009
  };
2978
3010
  };
2979
3011
  const serializeAws_json1_1CreateConnectionRequest = (input, context) => {
2980
3012
  return {
2981
- ...(input.AuthParameters !== undefined &&
2982
- input.AuthParameters !== null && {
3013
+ ...(input.AuthParameters != null && {
2983
3014
  AuthParameters: serializeAws_json1_1CreateConnectionAuthRequestParameters(input.AuthParameters, context),
2984
3015
  }),
2985
- ...(input.AuthorizationType !== undefined &&
2986
- input.AuthorizationType !== null && { AuthorizationType: input.AuthorizationType }),
2987
- ...(input.Description !== undefined && input.Description !== null && { Description: input.Description }),
2988
- ...(input.Name !== undefined && input.Name !== null && { Name: input.Name }),
3016
+ ...(input.AuthorizationType != null && { AuthorizationType: input.AuthorizationType }),
3017
+ ...(input.Description != null && { Description: input.Description }),
3018
+ ...(input.Name != null && { Name: input.Name }),
2989
3019
  };
2990
3020
  };
2991
3021
  const serializeAws_json1_1CreateEventBusRequest = (input, context) => {
2992
3022
  return {
2993
- ...(input.EventSourceName !== undefined &&
2994
- input.EventSourceName !== null && { EventSourceName: input.EventSourceName }),
2995
- ...(input.Name !== undefined && input.Name !== null && { Name: input.Name }),
2996
- ...(input.Tags !== undefined && input.Tags !== null && { Tags: serializeAws_json1_1TagList(input.Tags, context) }),
3023
+ ...(input.EventSourceName != null && { EventSourceName: input.EventSourceName }),
3024
+ ...(input.Name != null && { Name: input.Name }),
3025
+ ...(input.Tags != null && { Tags: serializeAws_json1_1TagList(input.Tags, context) }),
2997
3026
  };
2998
3027
  };
2999
3028
  const serializeAws_json1_1CreatePartnerEventSourceRequest = (input, context) => {
3000
3029
  return {
3001
- ...(input.Account !== undefined && input.Account !== null && { Account: input.Account }),
3002
- ...(input.Name !== undefined && input.Name !== null && { Name: input.Name }),
3030
+ ...(input.Account != null && { Account: input.Account }),
3031
+ ...(input.Name != null && { Name: input.Name }),
3003
3032
  };
3004
3033
  };
3005
3034
  const serializeAws_json1_1DeactivateEventSourceRequest = (input, context) => {
3006
3035
  return {
3007
- ...(input.Name !== undefined && input.Name !== null && { Name: input.Name }),
3036
+ ...(input.Name != null && { Name: input.Name }),
3008
3037
  };
3009
3038
  };
3010
3039
  const serializeAws_json1_1DeadLetterConfig = (input, context) => {
3011
3040
  return {
3012
- ...(input.Arn !== undefined && input.Arn !== null && { Arn: input.Arn }),
3041
+ ...(input.Arn != null && { Arn: input.Arn }),
3013
3042
  };
3014
3043
  };
3015
3044
  const serializeAws_json1_1DeauthorizeConnectionRequest = (input, context) => {
3016
3045
  return {
3017
- ...(input.Name !== undefined && input.Name !== null && { Name: input.Name }),
3046
+ ...(input.Name != null && { Name: input.Name }),
3018
3047
  };
3019
3048
  };
3020
3049
  const serializeAws_json1_1DeleteApiDestinationRequest = (input, context) => {
3021
3050
  return {
3022
- ...(input.Name !== undefined && input.Name !== null && { Name: input.Name }),
3051
+ ...(input.Name != null && { Name: input.Name }),
3023
3052
  };
3024
3053
  };
3025
3054
  const serializeAws_json1_1DeleteArchiveRequest = (input, context) => {
3026
3055
  return {
3027
- ...(input.ArchiveName !== undefined && input.ArchiveName !== null && { ArchiveName: input.ArchiveName }),
3056
+ ...(input.ArchiveName != null && { ArchiveName: input.ArchiveName }),
3028
3057
  };
3029
3058
  };
3030
3059
  const serializeAws_json1_1DeleteConnectionRequest = (input, context) => {
3031
3060
  return {
3032
- ...(input.Name !== undefined && input.Name !== null && { Name: input.Name }),
3061
+ ...(input.Name != null && { Name: input.Name }),
3033
3062
  };
3034
3063
  };
3035
3064
  const serializeAws_json1_1DeleteEventBusRequest = (input, context) => {
3036
3065
  return {
3037
- ...(input.Name !== undefined && input.Name !== null && { Name: input.Name }),
3066
+ ...(input.Name != null && { Name: input.Name }),
3038
3067
  };
3039
3068
  };
3040
3069
  const serializeAws_json1_1DeletePartnerEventSourceRequest = (input, context) => {
3041
3070
  return {
3042
- ...(input.Account !== undefined && input.Account !== null && { Account: input.Account }),
3043
- ...(input.Name !== undefined && input.Name !== null && { Name: input.Name }),
3071
+ ...(input.Account != null && { Account: input.Account }),
3072
+ ...(input.Name != null && { Name: input.Name }),
3044
3073
  };
3045
3074
  };
3046
3075
  const serializeAws_json1_1DeleteRuleRequest = (input, context) => {
3047
3076
  return {
3048
- ...(input.EventBusName !== undefined && input.EventBusName !== null && { EventBusName: input.EventBusName }),
3049
- ...(input.Force !== undefined && input.Force !== null && { Force: input.Force }),
3050
- ...(input.Name !== undefined && input.Name !== null && { Name: input.Name }),
3077
+ ...(input.EventBusName != null && { EventBusName: input.EventBusName }),
3078
+ ...(input.Force != null && { Force: input.Force }),
3079
+ ...(input.Name != null && { Name: input.Name }),
3051
3080
  };
3052
3081
  };
3053
3082
  const serializeAws_json1_1DescribeApiDestinationRequest = (input, context) => {
3054
3083
  return {
3055
- ...(input.Name !== undefined && input.Name !== null && { Name: input.Name }),
3084
+ ...(input.Name != null && { Name: input.Name }),
3056
3085
  };
3057
3086
  };
3058
3087
  const serializeAws_json1_1DescribeArchiveRequest = (input, context) => {
3059
3088
  return {
3060
- ...(input.ArchiveName !== undefined && input.ArchiveName !== null && { ArchiveName: input.ArchiveName }),
3089
+ ...(input.ArchiveName != null && { ArchiveName: input.ArchiveName }),
3061
3090
  };
3062
3091
  };
3063
3092
  const serializeAws_json1_1DescribeConnectionRequest = (input, context) => {
3064
3093
  return {
3065
- ...(input.Name !== undefined && input.Name !== null && { Name: input.Name }),
3094
+ ...(input.Name != null && { Name: input.Name }),
3066
3095
  };
3067
3096
  };
3068
3097
  const serializeAws_json1_1DescribeEventBusRequest = (input, context) => {
3069
3098
  return {
3070
- ...(input.Name !== undefined && input.Name !== null && { Name: input.Name }),
3099
+ ...(input.Name != null && { Name: input.Name }),
3071
3100
  };
3072
3101
  };
3073
3102
  const serializeAws_json1_1DescribeEventSourceRequest = (input, context) => {
3074
3103
  return {
3075
- ...(input.Name !== undefined && input.Name !== null && { Name: input.Name }),
3104
+ ...(input.Name != null && { Name: input.Name }),
3076
3105
  };
3077
3106
  };
3078
3107
  const serializeAws_json1_1DescribePartnerEventSourceRequest = (input, context) => {
3079
3108
  return {
3080
- ...(input.Name !== undefined && input.Name !== null && { Name: input.Name }),
3109
+ ...(input.Name != null && { Name: input.Name }),
3081
3110
  };
3082
3111
  };
3083
3112
  const serializeAws_json1_1DescribeReplayRequest = (input, context) => {
3084
3113
  return {
3085
- ...(input.ReplayName !== undefined && input.ReplayName !== null && { ReplayName: input.ReplayName }),
3114
+ ...(input.ReplayName != null && { ReplayName: input.ReplayName }),
3086
3115
  };
3087
3116
  };
3088
3117
  const serializeAws_json1_1DescribeRuleRequest = (input, context) => {
3089
3118
  return {
3090
- ...(input.EventBusName !== undefined && input.EventBusName !== null && { EventBusName: input.EventBusName }),
3091
- ...(input.Name !== undefined && input.Name !== null && { Name: input.Name }),
3119
+ ...(input.EventBusName != null && { EventBusName: input.EventBusName }),
3120
+ ...(input.Name != null && { Name: input.Name }),
3092
3121
  };
3093
3122
  };
3094
3123
  const serializeAws_json1_1DisableRuleRequest = (input, context) => {
3095
3124
  return {
3096
- ...(input.EventBusName !== undefined && input.EventBusName !== null && { EventBusName: input.EventBusName }),
3097
- ...(input.Name !== undefined && input.Name !== null && { Name: input.Name }),
3125
+ ...(input.EventBusName != null && { EventBusName: input.EventBusName }),
3126
+ ...(input.Name != null && { Name: input.Name }),
3098
3127
  };
3099
3128
  };
3100
3129
  const serializeAws_json1_1EcsParameters = (input, context) => {
3101
3130
  return {
3102
- ...(input.CapacityProviderStrategy !== undefined &&
3103
- input.CapacityProviderStrategy !== null && {
3131
+ ...(input.CapacityProviderStrategy != null && {
3104
3132
  CapacityProviderStrategy: serializeAws_json1_1CapacityProviderStrategy(input.CapacityProviderStrategy, context),
3105
3133
  }),
3106
- ...(input.EnableECSManagedTags !== undefined &&
3107
- input.EnableECSManagedTags !== null && { EnableECSManagedTags: input.EnableECSManagedTags }),
3108
- ...(input.EnableExecuteCommand !== undefined &&
3109
- input.EnableExecuteCommand !== null && { EnableExecuteCommand: input.EnableExecuteCommand }),
3110
- ...(input.Group !== undefined && input.Group !== null && { Group: input.Group }),
3111
- ...(input.LaunchType !== undefined && input.LaunchType !== null && { LaunchType: input.LaunchType }),
3112
- ...(input.NetworkConfiguration !== undefined &&
3113
- input.NetworkConfiguration !== null && {
3134
+ ...(input.EnableECSManagedTags != null && { EnableECSManagedTags: input.EnableECSManagedTags }),
3135
+ ...(input.EnableExecuteCommand != null && { EnableExecuteCommand: input.EnableExecuteCommand }),
3136
+ ...(input.Group != null && { Group: input.Group }),
3137
+ ...(input.LaunchType != null && { LaunchType: input.LaunchType }),
3138
+ ...(input.NetworkConfiguration != null && {
3114
3139
  NetworkConfiguration: serializeAws_json1_1NetworkConfiguration(input.NetworkConfiguration, context),
3115
3140
  }),
3116
- ...(input.PlacementConstraints !== undefined &&
3117
- input.PlacementConstraints !== null && {
3141
+ ...(input.PlacementConstraints != null && {
3118
3142
  PlacementConstraints: serializeAws_json1_1PlacementConstraints(input.PlacementConstraints, context),
3119
3143
  }),
3120
- ...(input.PlacementStrategy !== undefined &&
3121
- input.PlacementStrategy !== null && {
3144
+ ...(input.PlacementStrategy != null && {
3122
3145
  PlacementStrategy: serializeAws_json1_1PlacementStrategies(input.PlacementStrategy, context),
3123
3146
  }),
3124
- ...(input.PlatformVersion !== undefined &&
3125
- input.PlatformVersion !== null && { PlatformVersion: input.PlatformVersion }),
3126
- ...(input.PropagateTags !== undefined && input.PropagateTags !== null && { PropagateTags: input.PropagateTags }),
3127
- ...(input.ReferenceId !== undefined && input.ReferenceId !== null && { ReferenceId: input.ReferenceId }),
3128
- ...(input.Tags !== undefined && input.Tags !== null && { Tags: serializeAws_json1_1TagList(input.Tags, context) }),
3129
- ...(input.TaskCount !== undefined && input.TaskCount !== null && { TaskCount: input.TaskCount }),
3130
- ...(input.TaskDefinitionArn !== undefined &&
3131
- input.TaskDefinitionArn !== null && { TaskDefinitionArn: input.TaskDefinitionArn }),
3147
+ ...(input.PlatformVersion != null && { PlatformVersion: input.PlatformVersion }),
3148
+ ...(input.PropagateTags != null && { PropagateTags: input.PropagateTags }),
3149
+ ...(input.ReferenceId != null && { ReferenceId: input.ReferenceId }),
3150
+ ...(input.Tags != null && { Tags: serializeAws_json1_1TagList(input.Tags, context) }),
3151
+ ...(input.TaskCount != null && { TaskCount: input.TaskCount }),
3152
+ ...(input.TaskDefinitionArn != null && { TaskDefinitionArn: input.TaskDefinitionArn }),
3132
3153
  };
3133
3154
  };
3134
3155
  const serializeAws_json1_1EnableRuleRequest = (input, context) => {
3135
3156
  return {
3136
- ...(input.EventBusName !== undefined && input.EventBusName !== null && { EventBusName: input.EventBusName }),
3137
- ...(input.Name !== undefined && input.Name !== null && { Name: input.Name }),
3157
+ ...(input.EventBusName != null && { EventBusName: input.EventBusName }),
3158
+ ...(input.Name != null && { Name: input.Name }),
3138
3159
  };
3139
3160
  };
3140
3161
  const serializeAws_json1_1EventResourceList = (input, context) => {
@@ -3160,134 +3181,124 @@ const serializeAws_json1_1HeaderParametersMap = (input, context) => {
3160
3181
  };
3161
3182
  const serializeAws_json1_1HttpParameters = (input, context) => {
3162
3183
  return {
3163
- ...(input.HeaderParameters !== undefined &&
3164
- input.HeaderParameters !== null && {
3184
+ ...(input.HeaderParameters != null && {
3165
3185
  HeaderParameters: serializeAws_json1_1HeaderParametersMap(input.HeaderParameters, context),
3166
3186
  }),
3167
- ...(input.PathParameterValues !== undefined &&
3168
- input.PathParameterValues !== null && {
3187
+ ...(input.PathParameterValues != null && {
3169
3188
  PathParameterValues: serializeAws_json1_1PathParameterList(input.PathParameterValues, context),
3170
3189
  }),
3171
- ...(input.QueryStringParameters !== undefined &&
3172
- input.QueryStringParameters !== null && {
3190
+ ...(input.QueryStringParameters != null && {
3173
3191
  QueryStringParameters: serializeAws_json1_1QueryStringParametersMap(input.QueryStringParameters, context),
3174
3192
  }),
3175
3193
  };
3176
3194
  };
3177
3195
  const serializeAws_json1_1InputTransformer = (input, context) => {
3178
3196
  return {
3179
- ...(input.InputPathsMap !== undefined &&
3180
- input.InputPathsMap !== null && {
3197
+ ...(input.InputPathsMap != null && {
3181
3198
  InputPathsMap: serializeAws_json1_1TransformerPaths(input.InputPathsMap, context),
3182
3199
  }),
3183
- ...(input.InputTemplate !== undefined && input.InputTemplate !== null && { InputTemplate: input.InputTemplate }),
3200
+ ...(input.InputTemplate != null && { InputTemplate: input.InputTemplate }),
3184
3201
  };
3185
3202
  };
3186
3203
  const serializeAws_json1_1KinesisParameters = (input, context) => {
3187
3204
  return {
3188
- ...(input.PartitionKeyPath !== undefined &&
3189
- input.PartitionKeyPath !== null && { PartitionKeyPath: input.PartitionKeyPath }),
3205
+ ...(input.PartitionKeyPath != null && { PartitionKeyPath: input.PartitionKeyPath }),
3190
3206
  };
3191
3207
  };
3192
3208
  const serializeAws_json1_1ListApiDestinationsRequest = (input, context) => {
3193
3209
  return {
3194
- ...(input.ConnectionArn !== undefined && input.ConnectionArn !== null && { ConnectionArn: input.ConnectionArn }),
3195
- ...(input.Limit !== undefined && input.Limit !== null && { Limit: input.Limit }),
3196
- ...(input.NamePrefix !== undefined && input.NamePrefix !== null && { NamePrefix: input.NamePrefix }),
3197
- ...(input.NextToken !== undefined && input.NextToken !== null && { NextToken: input.NextToken }),
3210
+ ...(input.ConnectionArn != null && { ConnectionArn: input.ConnectionArn }),
3211
+ ...(input.Limit != null && { Limit: input.Limit }),
3212
+ ...(input.NamePrefix != null && { NamePrefix: input.NamePrefix }),
3213
+ ...(input.NextToken != null && { NextToken: input.NextToken }),
3198
3214
  };
3199
3215
  };
3200
3216
  const serializeAws_json1_1ListArchivesRequest = (input, context) => {
3201
3217
  return {
3202
- ...(input.EventSourceArn !== undefined &&
3203
- input.EventSourceArn !== null && { EventSourceArn: input.EventSourceArn }),
3204
- ...(input.Limit !== undefined && input.Limit !== null && { Limit: input.Limit }),
3205
- ...(input.NamePrefix !== undefined && input.NamePrefix !== null && { NamePrefix: input.NamePrefix }),
3206
- ...(input.NextToken !== undefined && input.NextToken !== null && { NextToken: input.NextToken }),
3207
- ...(input.State !== undefined && input.State !== null && { State: input.State }),
3218
+ ...(input.EventSourceArn != null && { EventSourceArn: input.EventSourceArn }),
3219
+ ...(input.Limit != null && { Limit: input.Limit }),
3220
+ ...(input.NamePrefix != null && { NamePrefix: input.NamePrefix }),
3221
+ ...(input.NextToken != null && { NextToken: input.NextToken }),
3222
+ ...(input.State != null && { State: input.State }),
3208
3223
  };
3209
3224
  };
3210
3225
  const serializeAws_json1_1ListConnectionsRequest = (input, context) => {
3211
3226
  return {
3212
- ...(input.ConnectionState !== undefined &&
3213
- input.ConnectionState !== null && { ConnectionState: input.ConnectionState }),
3214
- ...(input.Limit !== undefined && input.Limit !== null && { Limit: input.Limit }),
3215
- ...(input.NamePrefix !== undefined && input.NamePrefix !== null && { NamePrefix: input.NamePrefix }),
3216
- ...(input.NextToken !== undefined && input.NextToken !== null && { NextToken: input.NextToken }),
3227
+ ...(input.ConnectionState != null && { ConnectionState: input.ConnectionState }),
3228
+ ...(input.Limit != null && { Limit: input.Limit }),
3229
+ ...(input.NamePrefix != null && { NamePrefix: input.NamePrefix }),
3230
+ ...(input.NextToken != null && { NextToken: input.NextToken }),
3217
3231
  };
3218
3232
  };
3219
3233
  const serializeAws_json1_1ListEventBusesRequest = (input, context) => {
3220
3234
  return {
3221
- ...(input.Limit !== undefined && input.Limit !== null && { Limit: input.Limit }),
3222
- ...(input.NamePrefix !== undefined && input.NamePrefix !== null && { NamePrefix: input.NamePrefix }),
3223
- ...(input.NextToken !== undefined && input.NextToken !== null && { NextToken: input.NextToken }),
3235
+ ...(input.Limit != null && { Limit: input.Limit }),
3236
+ ...(input.NamePrefix != null && { NamePrefix: input.NamePrefix }),
3237
+ ...(input.NextToken != null && { NextToken: input.NextToken }),
3224
3238
  };
3225
3239
  };
3226
3240
  const serializeAws_json1_1ListEventSourcesRequest = (input, context) => {
3227
3241
  return {
3228
- ...(input.Limit !== undefined && input.Limit !== null && { Limit: input.Limit }),
3229
- ...(input.NamePrefix !== undefined && input.NamePrefix !== null && { NamePrefix: input.NamePrefix }),
3230
- ...(input.NextToken !== undefined && input.NextToken !== null && { NextToken: input.NextToken }),
3242
+ ...(input.Limit != null && { Limit: input.Limit }),
3243
+ ...(input.NamePrefix != null && { NamePrefix: input.NamePrefix }),
3244
+ ...(input.NextToken != null && { NextToken: input.NextToken }),
3231
3245
  };
3232
3246
  };
3233
3247
  const serializeAws_json1_1ListPartnerEventSourceAccountsRequest = (input, context) => {
3234
3248
  return {
3235
- ...(input.EventSourceName !== undefined &&
3236
- input.EventSourceName !== null && { EventSourceName: input.EventSourceName }),
3237
- ...(input.Limit !== undefined && input.Limit !== null && { Limit: input.Limit }),
3238
- ...(input.NextToken !== undefined && input.NextToken !== null && { NextToken: input.NextToken }),
3249
+ ...(input.EventSourceName != null && { EventSourceName: input.EventSourceName }),
3250
+ ...(input.Limit != null && { Limit: input.Limit }),
3251
+ ...(input.NextToken != null && { NextToken: input.NextToken }),
3239
3252
  };
3240
3253
  };
3241
3254
  const serializeAws_json1_1ListPartnerEventSourcesRequest = (input, context) => {
3242
3255
  return {
3243
- ...(input.Limit !== undefined && input.Limit !== null && { Limit: input.Limit }),
3244
- ...(input.NamePrefix !== undefined && input.NamePrefix !== null && { NamePrefix: input.NamePrefix }),
3245
- ...(input.NextToken !== undefined && input.NextToken !== null && { NextToken: input.NextToken }),
3256
+ ...(input.Limit != null && { Limit: input.Limit }),
3257
+ ...(input.NamePrefix != null && { NamePrefix: input.NamePrefix }),
3258
+ ...(input.NextToken != null && { NextToken: input.NextToken }),
3246
3259
  };
3247
3260
  };
3248
3261
  const serializeAws_json1_1ListReplaysRequest = (input, context) => {
3249
3262
  return {
3250
- ...(input.EventSourceArn !== undefined &&
3251
- input.EventSourceArn !== null && { EventSourceArn: input.EventSourceArn }),
3252
- ...(input.Limit !== undefined && input.Limit !== null && { Limit: input.Limit }),
3253
- ...(input.NamePrefix !== undefined && input.NamePrefix !== null && { NamePrefix: input.NamePrefix }),
3254
- ...(input.NextToken !== undefined && input.NextToken !== null && { NextToken: input.NextToken }),
3255
- ...(input.State !== undefined && input.State !== null && { State: input.State }),
3263
+ ...(input.EventSourceArn != null && { EventSourceArn: input.EventSourceArn }),
3264
+ ...(input.Limit != null && { Limit: input.Limit }),
3265
+ ...(input.NamePrefix != null && { NamePrefix: input.NamePrefix }),
3266
+ ...(input.NextToken != null && { NextToken: input.NextToken }),
3267
+ ...(input.State != null && { State: input.State }),
3256
3268
  };
3257
3269
  };
3258
3270
  const serializeAws_json1_1ListRuleNamesByTargetRequest = (input, context) => {
3259
3271
  return {
3260
- ...(input.EventBusName !== undefined && input.EventBusName !== null && { EventBusName: input.EventBusName }),
3261
- ...(input.Limit !== undefined && input.Limit !== null && { Limit: input.Limit }),
3262
- ...(input.NextToken !== undefined && input.NextToken !== null && { NextToken: input.NextToken }),
3263
- ...(input.TargetArn !== undefined && input.TargetArn !== null && { TargetArn: input.TargetArn }),
3272
+ ...(input.EventBusName != null && { EventBusName: input.EventBusName }),
3273
+ ...(input.Limit != null && { Limit: input.Limit }),
3274
+ ...(input.NextToken != null && { NextToken: input.NextToken }),
3275
+ ...(input.TargetArn != null && { TargetArn: input.TargetArn }),
3264
3276
  };
3265
3277
  };
3266
3278
  const serializeAws_json1_1ListRulesRequest = (input, context) => {
3267
3279
  return {
3268
- ...(input.EventBusName !== undefined && input.EventBusName !== null && { EventBusName: input.EventBusName }),
3269
- ...(input.Limit !== undefined && input.Limit !== null && { Limit: input.Limit }),
3270
- ...(input.NamePrefix !== undefined && input.NamePrefix !== null && { NamePrefix: input.NamePrefix }),
3271
- ...(input.NextToken !== undefined && input.NextToken !== null && { NextToken: input.NextToken }),
3280
+ ...(input.EventBusName != null && { EventBusName: input.EventBusName }),
3281
+ ...(input.Limit != null && { Limit: input.Limit }),
3282
+ ...(input.NamePrefix != null && { NamePrefix: input.NamePrefix }),
3283
+ ...(input.NextToken != null && { NextToken: input.NextToken }),
3272
3284
  };
3273
3285
  };
3274
3286
  const serializeAws_json1_1ListTagsForResourceRequest = (input, context) => {
3275
3287
  return {
3276
- ...(input.ResourceARN !== undefined && input.ResourceARN !== null && { ResourceARN: input.ResourceARN }),
3288
+ ...(input.ResourceARN != null && { ResourceARN: input.ResourceARN }),
3277
3289
  };
3278
3290
  };
3279
3291
  const serializeAws_json1_1ListTargetsByRuleRequest = (input, context) => {
3280
3292
  return {
3281
- ...(input.EventBusName !== undefined && input.EventBusName !== null && { EventBusName: input.EventBusName }),
3282
- ...(input.Limit !== undefined && input.Limit !== null && { Limit: input.Limit }),
3283
- ...(input.NextToken !== undefined && input.NextToken !== null && { NextToken: input.NextToken }),
3284
- ...(input.Rule !== undefined && input.Rule !== null && { Rule: input.Rule }),
3293
+ ...(input.EventBusName != null && { EventBusName: input.EventBusName }),
3294
+ ...(input.Limit != null && { Limit: input.Limit }),
3295
+ ...(input.NextToken != null && { NextToken: input.NextToken }),
3296
+ ...(input.Rule != null && { Rule: input.Rule }),
3285
3297
  };
3286
3298
  };
3287
3299
  const serializeAws_json1_1NetworkConfiguration = (input, context) => {
3288
3300
  return {
3289
- ...(input.awsvpcConfiguration !== undefined &&
3290
- input.awsvpcConfiguration !== null && {
3301
+ ...(input.awsvpcConfiguration != null && {
3291
3302
  awsvpcConfiguration: serializeAws_json1_1AwsVpcConfiguration(input.awsvpcConfiguration, context),
3292
3303
  }),
3293
3304
  };
@@ -3304,8 +3315,8 @@ const serializeAws_json1_1PathParameterList = (input, context) => {
3304
3315
  };
3305
3316
  const serializeAws_json1_1PlacementConstraint = (input, context) => {
3306
3317
  return {
3307
- ...(input.expression !== undefined && input.expression !== null && { expression: input.expression }),
3308
- ...(input.type !== undefined && input.type !== null && { type: input.type }),
3318
+ ...(input.expression != null && { expression: input.expression }),
3319
+ ...(input.type != null && { type: input.type }),
3309
3320
  };
3310
3321
  };
3311
3322
  const serializeAws_json1_1PlacementConstraints = (input, context) => {
@@ -3330,26 +3341,24 @@ const serializeAws_json1_1PlacementStrategies = (input, context) => {
3330
3341
  };
3331
3342
  const serializeAws_json1_1PlacementStrategy = (input, context) => {
3332
3343
  return {
3333
- ...(input.field !== undefined && input.field !== null && { field: input.field }),
3334
- ...(input.type !== undefined && input.type !== null && { type: input.type }),
3344
+ ...(input.field != null && { field: input.field }),
3345
+ ...(input.type != null && { type: input.type }),
3335
3346
  };
3336
3347
  };
3337
3348
  const serializeAws_json1_1PutEventsRequest = (input, context) => {
3338
3349
  return {
3339
- ...(input.Entries !== undefined &&
3340
- input.Entries !== null && { Entries: serializeAws_json1_1PutEventsRequestEntryList(input.Entries, context) }),
3350
+ ...(input.Entries != null && { Entries: serializeAws_json1_1PutEventsRequestEntryList(input.Entries, context) }),
3341
3351
  };
3342
3352
  };
3343
3353
  const serializeAws_json1_1PutEventsRequestEntry = (input, context) => {
3344
3354
  return {
3345
- ...(input.Detail !== undefined && input.Detail !== null && { Detail: input.Detail }),
3346
- ...(input.DetailType !== undefined && input.DetailType !== null && { DetailType: input.DetailType }),
3347
- ...(input.EventBusName !== undefined && input.EventBusName !== null && { EventBusName: input.EventBusName }),
3348
- ...(input.Resources !== undefined &&
3349
- input.Resources !== null && { Resources: serializeAws_json1_1EventResourceList(input.Resources, context) }),
3350
- ...(input.Source !== undefined && input.Source !== null && { Source: input.Source }),
3351
- ...(input.Time !== undefined && input.Time !== null && { Time: Math.round(input.Time.getTime() / 1000) }),
3352
- ...(input.TraceHeader !== undefined && input.TraceHeader !== null && { TraceHeader: input.TraceHeader }),
3355
+ ...(input.Detail != null && { Detail: input.Detail }),
3356
+ ...(input.DetailType != null && { DetailType: input.DetailType }),
3357
+ ...(input.EventBusName != null && { EventBusName: input.EventBusName }),
3358
+ ...(input.Resources != null && { Resources: serializeAws_json1_1EventResourceList(input.Resources, context) }),
3359
+ ...(input.Source != null && { Source: input.Source }),
3360
+ ...(input.Time != null && { Time: Math.round(input.Time.getTime() / 1000) }),
3361
+ ...(input.TraceHeader != null && { TraceHeader: input.TraceHeader }),
3353
3362
  };
3354
3363
  };
3355
3364
  const serializeAws_json1_1PutEventsRequestEntryList = (input, context) => {
@@ -3364,20 +3373,18 @@ const serializeAws_json1_1PutEventsRequestEntryList = (input, context) => {
3364
3373
  };
3365
3374
  const serializeAws_json1_1PutPartnerEventsRequest = (input, context) => {
3366
3375
  return {
3367
- ...(input.Entries !== undefined &&
3368
- input.Entries !== null && {
3376
+ ...(input.Entries != null && {
3369
3377
  Entries: serializeAws_json1_1PutPartnerEventsRequestEntryList(input.Entries, context),
3370
3378
  }),
3371
3379
  };
3372
3380
  };
3373
3381
  const serializeAws_json1_1PutPartnerEventsRequestEntry = (input, context) => {
3374
3382
  return {
3375
- ...(input.Detail !== undefined && input.Detail !== null && { Detail: input.Detail }),
3376
- ...(input.DetailType !== undefined && input.DetailType !== null && { DetailType: input.DetailType }),
3377
- ...(input.Resources !== undefined &&
3378
- input.Resources !== null && { Resources: serializeAws_json1_1EventResourceList(input.Resources, context) }),
3379
- ...(input.Source !== undefined && input.Source !== null && { Source: input.Source }),
3380
- ...(input.Time !== undefined && input.Time !== null && { Time: Math.round(input.Time.getTime() / 1000) }),
3383
+ ...(input.Detail != null && { Detail: input.Detail }),
3384
+ ...(input.DetailType != null && { DetailType: input.DetailType }),
3385
+ ...(input.Resources != null && { Resources: serializeAws_json1_1EventResourceList(input.Resources, context) }),
3386
+ ...(input.Source != null && { Source: input.Source }),
3387
+ ...(input.Time != null && { Time: Math.round(input.Time.getTime() / 1000) }),
3381
3388
  };
3382
3389
  };
3383
3390
  const serializeAws_json1_1PutPartnerEventsRequestEntryList = (input, context) => {
@@ -3392,34 +3399,31 @@ const serializeAws_json1_1PutPartnerEventsRequestEntryList = (input, context) =>
3392
3399
  };
3393
3400
  const serializeAws_json1_1PutPermissionRequest = (input, context) => {
3394
3401
  return {
3395
- ...(input.Action !== undefined && input.Action !== null && { Action: input.Action }),
3396
- ...(input.Condition !== undefined &&
3397
- input.Condition !== null && { Condition: serializeAws_json1_1Condition(input.Condition, context) }),
3398
- ...(input.EventBusName !== undefined && input.EventBusName !== null && { EventBusName: input.EventBusName }),
3399
- ...(input.Policy !== undefined && input.Policy !== null && { Policy: input.Policy }),
3400
- ...(input.Principal !== undefined && input.Principal !== null && { Principal: input.Principal }),
3401
- ...(input.StatementId !== undefined && input.StatementId !== null && { StatementId: input.StatementId }),
3402
+ ...(input.Action != null && { Action: input.Action }),
3403
+ ...(input.Condition != null && { Condition: serializeAws_json1_1Condition(input.Condition, context) }),
3404
+ ...(input.EventBusName != null && { EventBusName: input.EventBusName }),
3405
+ ...(input.Policy != null && { Policy: input.Policy }),
3406
+ ...(input.Principal != null && { Principal: input.Principal }),
3407
+ ...(input.StatementId != null && { StatementId: input.StatementId }),
3402
3408
  };
3403
3409
  };
3404
3410
  const serializeAws_json1_1PutRuleRequest = (input, context) => {
3405
3411
  return {
3406
- ...(input.Description !== undefined && input.Description !== null && { Description: input.Description }),
3407
- ...(input.EventBusName !== undefined && input.EventBusName !== null && { EventBusName: input.EventBusName }),
3408
- ...(input.EventPattern !== undefined && input.EventPattern !== null && { EventPattern: input.EventPattern }),
3409
- ...(input.Name !== undefined && input.Name !== null && { Name: input.Name }),
3410
- ...(input.RoleArn !== undefined && input.RoleArn !== null && { RoleArn: input.RoleArn }),
3411
- ...(input.ScheduleExpression !== undefined &&
3412
- input.ScheduleExpression !== null && { ScheduleExpression: input.ScheduleExpression }),
3413
- ...(input.State !== undefined && input.State !== null && { State: input.State }),
3414
- ...(input.Tags !== undefined && input.Tags !== null && { Tags: serializeAws_json1_1TagList(input.Tags, context) }),
3412
+ ...(input.Description != null && { Description: input.Description }),
3413
+ ...(input.EventBusName != null && { EventBusName: input.EventBusName }),
3414
+ ...(input.EventPattern != null && { EventPattern: input.EventPattern }),
3415
+ ...(input.Name != null && { Name: input.Name }),
3416
+ ...(input.RoleArn != null && { RoleArn: input.RoleArn }),
3417
+ ...(input.ScheduleExpression != null && { ScheduleExpression: input.ScheduleExpression }),
3418
+ ...(input.State != null && { State: input.State }),
3419
+ ...(input.Tags != null && { Tags: serializeAws_json1_1TagList(input.Tags, context) }),
3415
3420
  };
3416
3421
  };
3417
3422
  const serializeAws_json1_1PutTargetsRequest = (input, context) => {
3418
3423
  return {
3419
- ...(input.EventBusName !== undefined && input.EventBusName !== null && { EventBusName: input.EventBusName }),
3420
- ...(input.Rule !== undefined && input.Rule !== null && { Rule: input.Rule }),
3421
- ...(input.Targets !== undefined &&
3422
- input.Targets !== null && { Targets: serializeAws_json1_1TargetList(input.Targets, context) }),
3424
+ ...(input.EventBusName != null && { EventBusName: input.EventBusName }),
3425
+ ...(input.Rule != null && { Rule: input.Rule }),
3426
+ ...(input.Targets != null && { Targets: serializeAws_json1_1TargetList(input.Targets, context) }),
3423
3427
  };
3424
3428
  };
3425
3429
  const serializeAws_json1_1QueryStringParametersMap = (input, context) => {
@@ -3435,36 +3439,33 @@ const serializeAws_json1_1QueryStringParametersMap = (input, context) => {
3435
3439
  };
3436
3440
  const serializeAws_json1_1RedshiftDataParameters = (input, context) => {
3437
3441
  return {
3438
- ...(input.Database !== undefined && input.Database !== null && { Database: input.Database }),
3439
- ...(input.DbUser !== undefined && input.DbUser !== null && { DbUser: input.DbUser }),
3440
- ...(input.SecretManagerArn !== undefined &&
3441
- input.SecretManagerArn !== null && { SecretManagerArn: input.SecretManagerArn }),
3442
- ...(input.Sql !== undefined && input.Sql !== null && { Sql: input.Sql }),
3443
- ...(input.StatementName !== undefined && input.StatementName !== null && { StatementName: input.StatementName }),
3444
- ...(input.WithEvent !== undefined && input.WithEvent !== null && { WithEvent: input.WithEvent }),
3442
+ ...(input.Database != null && { Database: input.Database }),
3443
+ ...(input.DbUser != null && { DbUser: input.DbUser }),
3444
+ ...(input.SecretManagerArn != null && { SecretManagerArn: input.SecretManagerArn }),
3445
+ ...(input.Sql != null && { Sql: input.Sql }),
3446
+ ...(input.StatementName != null && { StatementName: input.StatementName }),
3447
+ ...(input.WithEvent != null && { WithEvent: input.WithEvent }),
3445
3448
  };
3446
3449
  };
3447
3450
  const serializeAws_json1_1RemovePermissionRequest = (input, context) => {
3448
3451
  return {
3449
- ...(input.EventBusName !== undefined && input.EventBusName !== null && { EventBusName: input.EventBusName }),
3450
- ...(input.RemoveAllPermissions !== undefined &&
3451
- input.RemoveAllPermissions !== null && { RemoveAllPermissions: input.RemoveAllPermissions }),
3452
- ...(input.StatementId !== undefined && input.StatementId !== null && { StatementId: input.StatementId }),
3452
+ ...(input.EventBusName != null && { EventBusName: input.EventBusName }),
3453
+ ...(input.RemoveAllPermissions != null && { RemoveAllPermissions: input.RemoveAllPermissions }),
3454
+ ...(input.StatementId != null && { StatementId: input.StatementId }),
3453
3455
  };
3454
3456
  };
3455
3457
  const serializeAws_json1_1RemoveTargetsRequest = (input, context) => {
3456
3458
  return {
3457
- ...(input.EventBusName !== undefined && input.EventBusName !== null && { EventBusName: input.EventBusName }),
3458
- ...(input.Force !== undefined && input.Force !== null && { Force: input.Force }),
3459
- ...(input.Ids !== undefined && input.Ids !== null && { Ids: serializeAws_json1_1TargetIdList(input.Ids, context) }),
3460
- ...(input.Rule !== undefined && input.Rule !== null && { Rule: input.Rule }),
3459
+ ...(input.EventBusName != null && { EventBusName: input.EventBusName }),
3460
+ ...(input.Force != null && { Force: input.Force }),
3461
+ ...(input.Ids != null && { Ids: serializeAws_json1_1TargetIdList(input.Ids, context) }),
3462
+ ...(input.Rule != null && { Rule: input.Rule }),
3461
3463
  };
3462
3464
  };
3463
3465
  const serializeAws_json1_1ReplayDestination = (input, context) => {
3464
3466
  return {
3465
- ...(input.Arn !== undefined && input.Arn !== null && { Arn: input.Arn }),
3466
- ...(input.FilterArns !== undefined &&
3467
- input.FilterArns !== null && {
3467
+ ...(input.Arn != null && { Arn: input.Arn }),
3468
+ ...(input.FilterArns != null && {
3468
3469
  FilterArns: serializeAws_json1_1ReplayDestinationFilters(input.FilterArns, context),
3469
3470
  }),
3470
3471
  };
@@ -3481,25 +3482,21 @@ const serializeAws_json1_1ReplayDestinationFilters = (input, context) => {
3481
3482
  };
3482
3483
  const serializeAws_json1_1RetryPolicy = (input, context) => {
3483
3484
  return {
3484
- ...(input.MaximumEventAgeInSeconds !== undefined &&
3485
- input.MaximumEventAgeInSeconds !== null && { MaximumEventAgeInSeconds: input.MaximumEventAgeInSeconds }),
3486
- ...(input.MaximumRetryAttempts !== undefined &&
3487
- input.MaximumRetryAttempts !== null && { MaximumRetryAttempts: input.MaximumRetryAttempts }),
3485
+ ...(input.MaximumEventAgeInSeconds != null && { MaximumEventAgeInSeconds: input.MaximumEventAgeInSeconds }),
3486
+ ...(input.MaximumRetryAttempts != null && { MaximumRetryAttempts: input.MaximumRetryAttempts }),
3488
3487
  };
3489
3488
  };
3490
3489
  const serializeAws_json1_1RunCommandParameters = (input, context) => {
3491
3490
  return {
3492
- ...(input.RunCommandTargets !== undefined &&
3493
- input.RunCommandTargets !== null && {
3491
+ ...(input.RunCommandTargets != null && {
3494
3492
  RunCommandTargets: serializeAws_json1_1RunCommandTargets(input.RunCommandTargets, context),
3495
3493
  }),
3496
3494
  };
3497
3495
  };
3498
3496
  const serializeAws_json1_1RunCommandTarget = (input, context) => {
3499
3497
  return {
3500
- ...(input.Key !== undefined && input.Key !== null && { Key: input.Key }),
3501
- ...(input.Values !== undefined &&
3502
- input.Values !== null && { Values: serializeAws_json1_1RunCommandTargetValues(input.Values, context) }),
3498
+ ...(input.Key != null && { Key: input.Key }),
3499
+ ...(input.Values != null && { Values: serializeAws_json1_1RunCommandTargetValues(input.Values, context) }),
3503
3500
  };
3504
3501
  };
3505
3502
  const serializeAws_json1_1RunCommandTargets = (input, context) => {
@@ -3524,8 +3521,8 @@ const serializeAws_json1_1RunCommandTargetValues = (input, context) => {
3524
3521
  };
3525
3522
  const serializeAws_json1_1SageMakerPipelineParameter = (input, context) => {
3526
3523
  return {
3527
- ...(input.Name !== undefined && input.Name !== null && { Name: input.Name }),
3528
- ...(input.Value !== undefined && input.Value !== null && { Value: input.Value }),
3524
+ ...(input.Name != null && { Name: input.Name }),
3525
+ ...(input.Value != null && { Value: input.Value }),
3529
3526
  };
3530
3527
  };
3531
3528
  const serializeAws_json1_1SageMakerPipelineParameterList = (input, context) => {
@@ -3540,30 +3537,26 @@ const serializeAws_json1_1SageMakerPipelineParameterList = (input, context) => {
3540
3537
  };
3541
3538
  const serializeAws_json1_1SageMakerPipelineParameters = (input, context) => {
3542
3539
  return {
3543
- ...(input.PipelineParameterList !== undefined &&
3544
- input.PipelineParameterList !== null && {
3540
+ ...(input.PipelineParameterList != null && {
3545
3541
  PipelineParameterList: serializeAws_json1_1SageMakerPipelineParameterList(input.PipelineParameterList, context),
3546
3542
  }),
3547
3543
  };
3548
3544
  };
3549
3545
  const serializeAws_json1_1SqsParameters = (input, context) => {
3550
3546
  return {
3551
- ...(input.MessageGroupId !== undefined &&
3552
- input.MessageGroupId !== null && { MessageGroupId: input.MessageGroupId }),
3547
+ ...(input.MessageGroupId != null && { MessageGroupId: input.MessageGroupId }),
3553
3548
  };
3554
3549
  };
3555
3550
  const serializeAws_json1_1StartReplayRequest = (input, context) => {
3556
3551
  return {
3557
- ...(input.Description !== undefined && input.Description !== null && { Description: input.Description }),
3558
- ...(input.Destination !== undefined &&
3559
- input.Destination !== null && { Destination: serializeAws_json1_1ReplayDestination(input.Destination, context) }),
3560
- ...(input.EventEndTime !== undefined &&
3561
- input.EventEndTime !== null && { EventEndTime: Math.round(input.EventEndTime.getTime() / 1000) }),
3562
- ...(input.EventSourceArn !== undefined &&
3563
- input.EventSourceArn !== null && { EventSourceArn: input.EventSourceArn }),
3564
- ...(input.EventStartTime !== undefined &&
3565
- input.EventStartTime !== null && { EventStartTime: Math.round(input.EventStartTime.getTime() / 1000) }),
3566
- ...(input.ReplayName !== undefined && input.ReplayName !== null && { ReplayName: input.ReplayName }),
3552
+ ...(input.Description != null && { Description: input.Description }),
3553
+ ...(input.Destination != null && {
3554
+ Destination: serializeAws_json1_1ReplayDestination(input.Destination, context),
3555
+ }),
3556
+ ...(input.EventEndTime != null && { EventEndTime: Math.round(input.EventEndTime.getTime() / 1000) }),
3557
+ ...(input.EventSourceArn != null && { EventSourceArn: input.EventSourceArn }),
3558
+ ...(input.EventStartTime != null && { EventStartTime: Math.round(input.EventStartTime.getTime() / 1000) }),
3559
+ ...(input.ReplayName != null && { ReplayName: input.ReplayName }),
3567
3560
  };
3568
3561
  };
3569
3562
  const serializeAws_json1_1StringList = (input, context) => {
@@ -3578,8 +3571,8 @@ const serializeAws_json1_1StringList = (input, context) => {
3578
3571
  };
3579
3572
  const serializeAws_json1_1Tag = (input, context) => {
3580
3573
  return {
3581
- ...(input.Key !== undefined && input.Key !== null && { Key: input.Key }),
3582
- ...(input.Value !== undefined && input.Value !== null && { Value: input.Value }),
3574
+ ...(input.Key != null && { Key: input.Key }),
3575
+ ...(input.Value != null && { Value: input.Value }),
3583
3576
  };
3584
3577
  };
3585
3578
  const serializeAws_json1_1TagKeyList = (input, context) => {
@@ -3604,57 +3597,46 @@ const serializeAws_json1_1TagList = (input, context) => {
3604
3597
  };
3605
3598
  const serializeAws_json1_1TagResourceRequest = (input, context) => {
3606
3599
  return {
3607
- ...(input.ResourceARN !== undefined && input.ResourceARN !== null && { ResourceARN: input.ResourceARN }),
3608
- ...(input.Tags !== undefined && input.Tags !== null && { Tags: serializeAws_json1_1TagList(input.Tags, context) }),
3600
+ ...(input.ResourceARN != null && { ResourceARN: input.ResourceARN }),
3601
+ ...(input.Tags != null && { Tags: serializeAws_json1_1TagList(input.Tags, context) }),
3609
3602
  };
3610
3603
  };
3611
3604
  const serializeAws_json1_1Target = (input, context) => {
3612
3605
  return {
3613
- ...(input.Arn !== undefined && input.Arn !== null && { Arn: input.Arn }),
3614
- ...(input.BatchParameters !== undefined &&
3615
- input.BatchParameters !== null && {
3606
+ ...(input.Arn != null && { Arn: input.Arn }),
3607
+ ...(input.BatchParameters != null && {
3616
3608
  BatchParameters: serializeAws_json1_1BatchParameters(input.BatchParameters, context),
3617
3609
  }),
3618
- ...(input.DeadLetterConfig !== undefined &&
3619
- input.DeadLetterConfig !== null && {
3610
+ ...(input.DeadLetterConfig != null && {
3620
3611
  DeadLetterConfig: serializeAws_json1_1DeadLetterConfig(input.DeadLetterConfig, context),
3621
3612
  }),
3622
- ...(input.EcsParameters !== undefined &&
3623
- input.EcsParameters !== null && {
3613
+ ...(input.EcsParameters != null && {
3624
3614
  EcsParameters: serializeAws_json1_1EcsParameters(input.EcsParameters, context),
3625
3615
  }),
3626
- ...(input.HttpParameters !== undefined &&
3627
- input.HttpParameters !== null && {
3616
+ ...(input.HttpParameters != null && {
3628
3617
  HttpParameters: serializeAws_json1_1HttpParameters(input.HttpParameters, context),
3629
3618
  }),
3630
- ...(input.Id !== undefined && input.Id !== null && { Id: input.Id }),
3631
- ...(input.Input !== undefined && input.Input !== null && { Input: input.Input }),
3632
- ...(input.InputPath !== undefined && input.InputPath !== null && { InputPath: input.InputPath }),
3633
- ...(input.InputTransformer !== undefined &&
3634
- input.InputTransformer !== null && {
3619
+ ...(input.Id != null && { Id: input.Id }),
3620
+ ...(input.Input != null && { Input: input.Input }),
3621
+ ...(input.InputPath != null && { InputPath: input.InputPath }),
3622
+ ...(input.InputTransformer != null && {
3635
3623
  InputTransformer: serializeAws_json1_1InputTransformer(input.InputTransformer, context),
3636
3624
  }),
3637
- ...(input.KinesisParameters !== undefined &&
3638
- input.KinesisParameters !== null && {
3625
+ ...(input.KinesisParameters != null && {
3639
3626
  KinesisParameters: serializeAws_json1_1KinesisParameters(input.KinesisParameters, context),
3640
3627
  }),
3641
- ...(input.RedshiftDataParameters !== undefined &&
3642
- input.RedshiftDataParameters !== null && {
3628
+ ...(input.RedshiftDataParameters != null && {
3643
3629
  RedshiftDataParameters: serializeAws_json1_1RedshiftDataParameters(input.RedshiftDataParameters, context),
3644
3630
  }),
3645
- ...(input.RetryPolicy !== undefined &&
3646
- input.RetryPolicy !== null && { RetryPolicy: serializeAws_json1_1RetryPolicy(input.RetryPolicy, context) }),
3647
- ...(input.RoleArn !== undefined && input.RoleArn !== null && { RoleArn: input.RoleArn }),
3648
- ...(input.RunCommandParameters !== undefined &&
3649
- input.RunCommandParameters !== null && {
3631
+ ...(input.RetryPolicy != null && { RetryPolicy: serializeAws_json1_1RetryPolicy(input.RetryPolicy, context) }),
3632
+ ...(input.RoleArn != null && { RoleArn: input.RoleArn }),
3633
+ ...(input.RunCommandParameters != null && {
3650
3634
  RunCommandParameters: serializeAws_json1_1RunCommandParameters(input.RunCommandParameters, context),
3651
3635
  }),
3652
- ...(input.SageMakerPipelineParameters !== undefined &&
3653
- input.SageMakerPipelineParameters !== null && {
3636
+ ...(input.SageMakerPipelineParameters != null && {
3654
3637
  SageMakerPipelineParameters: serializeAws_json1_1SageMakerPipelineParameters(input.SageMakerPipelineParameters, context),
3655
3638
  }),
3656
- ...(input.SqsParameters !== undefined &&
3657
- input.SqsParameters !== null && {
3639
+ ...(input.SqsParameters != null && {
3658
3640
  SqsParameters: serializeAws_json1_1SqsParameters(input.SqsParameters, context),
3659
3641
  }),
3660
3642
  };
@@ -3681,8 +3663,8 @@ const serializeAws_json1_1TargetList = (input, context) => {
3681
3663
  };
3682
3664
  const serializeAws_json1_1TestEventPatternRequest = (input, context) => {
3683
3665
  return {
3684
- ...(input.Event !== undefined && input.Event !== null && { Event: input.Event }),
3685
- ...(input.EventPattern !== undefined && input.EventPattern !== null && { EventPattern: input.EventPattern }),
3666
+ ...(input.Event != null && { Event: input.Event }),
3667
+ ...(input.EventPattern != null && { EventPattern: input.EventPattern }),
3686
3668
  };
3687
3669
  };
3688
3670
  const serializeAws_json1_1TransformerPaths = (input, context) => {
@@ -3698,96 +3680,84 @@ const serializeAws_json1_1TransformerPaths = (input, context) => {
3698
3680
  };
3699
3681
  const serializeAws_json1_1UntagResourceRequest = (input, context) => {
3700
3682
  return {
3701
- ...(input.ResourceARN !== undefined && input.ResourceARN !== null && { ResourceARN: input.ResourceARN }),
3702
- ...(input.TagKeys !== undefined &&
3703
- input.TagKeys !== null && { TagKeys: serializeAws_json1_1TagKeyList(input.TagKeys, context) }),
3683
+ ...(input.ResourceARN != null && { ResourceARN: input.ResourceARN }),
3684
+ ...(input.TagKeys != null && { TagKeys: serializeAws_json1_1TagKeyList(input.TagKeys, context) }),
3704
3685
  };
3705
3686
  };
3706
3687
  const serializeAws_json1_1UpdateApiDestinationRequest = (input, context) => {
3707
3688
  return {
3708
- ...(input.ConnectionArn !== undefined && input.ConnectionArn !== null && { ConnectionArn: input.ConnectionArn }),
3709
- ...(input.Description !== undefined && input.Description !== null && { Description: input.Description }),
3710
- ...(input.HttpMethod !== undefined && input.HttpMethod !== null && { HttpMethod: input.HttpMethod }),
3711
- ...(input.InvocationEndpoint !== undefined &&
3712
- input.InvocationEndpoint !== null && { InvocationEndpoint: input.InvocationEndpoint }),
3713
- ...(input.InvocationRateLimitPerSecond !== undefined &&
3714
- input.InvocationRateLimitPerSecond !== null && {
3689
+ ...(input.ConnectionArn != null && { ConnectionArn: input.ConnectionArn }),
3690
+ ...(input.Description != null && { Description: input.Description }),
3691
+ ...(input.HttpMethod != null && { HttpMethod: input.HttpMethod }),
3692
+ ...(input.InvocationEndpoint != null && { InvocationEndpoint: input.InvocationEndpoint }),
3693
+ ...(input.InvocationRateLimitPerSecond != null && {
3715
3694
  InvocationRateLimitPerSecond: input.InvocationRateLimitPerSecond,
3716
3695
  }),
3717
- ...(input.Name !== undefined && input.Name !== null && { Name: input.Name }),
3696
+ ...(input.Name != null && { Name: input.Name }),
3718
3697
  };
3719
3698
  };
3720
3699
  const serializeAws_json1_1UpdateArchiveRequest = (input, context) => {
3721
3700
  return {
3722
- ...(input.ArchiveName !== undefined && input.ArchiveName !== null && { ArchiveName: input.ArchiveName }),
3723
- ...(input.Description !== undefined && input.Description !== null && { Description: input.Description }),
3724
- ...(input.EventPattern !== undefined && input.EventPattern !== null && { EventPattern: input.EventPattern }),
3725
- ...(input.RetentionDays !== undefined && input.RetentionDays !== null && { RetentionDays: input.RetentionDays }),
3701
+ ...(input.ArchiveName != null && { ArchiveName: input.ArchiveName }),
3702
+ ...(input.Description != null && { Description: input.Description }),
3703
+ ...(input.EventPattern != null && { EventPattern: input.EventPattern }),
3704
+ ...(input.RetentionDays != null && { RetentionDays: input.RetentionDays }),
3726
3705
  };
3727
3706
  };
3728
3707
  const serializeAws_json1_1UpdateConnectionApiKeyAuthRequestParameters = (input, context) => {
3729
3708
  return {
3730
- ...(input.ApiKeyName !== undefined && input.ApiKeyName !== null && { ApiKeyName: input.ApiKeyName }),
3731
- ...(input.ApiKeyValue !== undefined && input.ApiKeyValue !== null && { ApiKeyValue: input.ApiKeyValue }),
3709
+ ...(input.ApiKeyName != null && { ApiKeyName: input.ApiKeyName }),
3710
+ ...(input.ApiKeyValue != null && { ApiKeyValue: input.ApiKeyValue }),
3732
3711
  };
3733
3712
  };
3734
3713
  const serializeAws_json1_1UpdateConnectionAuthRequestParameters = (input, context) => {
3735
3714
  return {
3736
- ...(input.ApiKeyAuthParameters !== undefined &&
3737
- input.ApiKeyAuthParameters !== null && {
3715
+ ...(input.ApiKeyAuthParameters != null && {
3738
3716
  ApiKeyAuthParameters: serializeAws_json1_1UpdateConnectionApiKeyAuthRequestParameters(input.ApiKeyAuthParameters, context),
3739
3717
  }),
3740
- ...(input.BasicAuthParameters !== undefined &&
3741
- input.BasicAuthParameters !== null && {
3718
+ ...(input.BasicAuthParameters != null && {
3742
3719
  BasicAuthParameters: serializeAws_json1_1UpdateConnectionBasicAuthRequestParameters(input.BasicAuthParameters, context),
3743
3720
  }),
3744
- ...(input.InvocationHttpParameters !== undefined &&
3745
- input.InvocationHttpParameters !== null && {
3721
+ ...(input.InvocationHttpParameters != null && {
3746
3722
  InvocationHttpParameters: serializeAws_json1_1ConnectionHttpParameters(input.InvocationHttpParameters, context),
3747
3723
  }),
3748
- ...(input.OAuthParameters !== undefined &&
3749
- input.OAuthParameters !== null && {
3724
+ ...(input.OAuthParameters != null && {
3750
3725
  OAuthParameters: serializeAws_json1_1UpdateConnectionOAuthRequestParameters(input.OAuthParameters, context),
3751
3726
  }),
3752
3727
  };
3753
3728
  };
3754
3729
  const serializeAws_json1_1UpdateConnectionBasicAuthRequestParameters = (input, context) => {
3755
3730
  return {
3756
- ...(input.Password !== undefined && input.Password !== null && { Password: input.Password }),
3757
- ...(input.Username !== undefined && input.Username !== null && { Username: input.Username }),
3731
+ ...(input.Password != null && { Password: input.Password }),
3732
+ ...(input.Username != null && { Username: input.Username }),
3758
3733
  };
3759
3734
  };
3760
3735
  const serializeAws_json1_1UpdateConnectionOAuthClientRequestParameters = (input, context) => {
3761
3736
  return {
3762
- ...(input.ClientID !== undefined && input.ClientID !== null && { ClientID: input.ClientID }),
3763
- ...(input.ClientSecret !== undefined && input.ClientSecret !== null && { ClientSecret: input.ClientSecret }),
3737
+ ...(input.ClientID != null && { ClientID: input.ClientID }),
3738
+ ...(input.ClientSecret != null && { ClientSecret: input.ClientSecret }),
3764
3739
  };
3765
3740
  };
3766
3741
  const serializeAws_json1_1UpdateConnectionOAuthRequestParameters = (input, context) => {
3767
3742
  return {
3768
- ...(input.AuthorizationEndpoint !== undefined &&
3769
- input.AuthorizationEndpoint !== null && { AuthorizationEndpoint: input.AuthorizationEndpoint }),
3770
- ...(input.ClientParameters !== undefined &&
3771
- input.ClientParameters !== null && {
3743
+ ...(input.AuthorizationEndpoint != null && { AuthorizationEndpoint: input.AuthorizationEndpoint }),
3744
+ ...(input.ClientParameters != null && {
3772
3745
  ClientParameters: serializeAws_json1_1UpdateConnectionOAuthClientRequestParameters(input.ClientParameters, context),
3773
3746
  }),
3774
- ...(input.HttpMethod !== undefined && input.HttpMethod !== null && { HttpMethod: input.HttpMethod }),
3775
- ...(input.OAuthHttpParameters !== undefined &&
3776
- input.OAuthHttpParameters !== null && {
3747
+ ...(input.HttpMethod != null && { HttpMethod: input.HttpMethod }),
3748
+ ...(input.OAuthHttpParameters != null && {
3777
3749
  OAuthHttpParameters: serializeAws_json1_1ConnectionHttpParameters(input.OAuthHttpParameters, context),
3778
3750
  }),
3779
3751
  };
3780
3752
  };
3781
3753
  const serializeAws_json1_1UpdateConnectionRequest = (input, context) => {
3782
3754
  return {
3783
- ...(input.AuthParameters !== undefined &&
3784
- input.AuthParameters !== null && {
3755
+ ...(input.AuthParameters != null && {
3785
3756
  AuthParameters: serializeAws_json1_1UpdateConnectionAuthRequestParameters(input.AuthParameters, context),
3786
3757
  }),
3787
- ...(input.AuthorizationType !== undefined &&
3788
- input.AuthorizationType !== null && { AuthorizationType: input.AuthorizationType }),
3789
- ...(input.Description !== undefined && input.Description !== null && { Description: input.Description }),
3790
- ...(input.Name !== undefined && input.Name !== null && { Name: input.Name }),
3758
+ ...(input.AuthorizationType != null && { AuthorizationType: input.AuthorizationType }),
3759
+ ...(input.Description != null && { Description: input.Description }),
3760
+ ...(input.Name != null && { Name: input.Name }),
3791
3761
  };
3792
3762
  };
3793
3763
  const deserializeAws_json1_1ApiDestination = (output, context) => {
@@ -3795,13 +3765,13 @@ const deserializeAws_json1_1ApiDestination = (output, context) => {
3795
3765
  ApiDestinationArn: (0, smithy_client_1.expectString)(output.ApiDestinationArn),
3796
3766
  ApiDestinationState: (0, smithy_client_1.expectString)(output.ApiDestinationState),
3797
3767
  ConnectionArn: (0, smithy_client_1.expectString)(output.ConnectionArn),
3798
- CreationTime: output.CreationTime !== undefined && output.CreationTime !== null
3768
+ CreationTime: output.CreationTime != null
3799
3769
  ? (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseEpochTimestamp)((0, smithy_client_1.expectNumber)(output.CreationTime)))
3800
3770
  : undefined,
3801
3771
  HttpMethod: (0, smithy_client_1.expectString)(output.HttpMethod),
3802
3772
  InvocationEndpoint: (0, smithy_client_1.expectString)(output.InvocationEndpoint),
3803
3773
  InvocationRateLimitPerSecond: (0, smithy_client_1.expectInt32)(output.InvocationRateLimitPerSecond),
3804
- LastModifiedTime: output.LastModifiedTime !== undefined && output.LastModifiedTime !== null
3774
+ LastModifiedTime: output.LastModifiedTime != null
3805
3775
  ? (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseEpochTimestamp)((0, smithy_client_1.expectNumber)(output.LastModifiedTime)))
3806
3776
  : undefined,
3807
3777
  Name: (0, smithy_client_1.expectString)(output.Name),
@@ -3821,7 +3791,7 @@ const deserializeAws_json1_1ApiDestinationResponseList = (output, context) => {
3821
3791
  const deserializeAws_json1_1Archive = (output, context) => {
3822
3792
  return {
3823
3793
  ArchiveName: (0, smithy_client_1.expectString)(output.ArchiveName),
3824
- CreationTime: output.CreationTime !== undefined && output.CreationTime !== null
3794
+ CreationTime: output.CreationTime != null
3825
3795
  ? (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseEpochTimestamp)((0, smithy_client_1.expectNumber)(output.CreationTime)))
3826
3796
  : undefined,
3827
3797
  EventCount: (0, smithy_client_1.expectLong)(output.EventCount),
@@ -3846,12 +3816,8 @@ const deserializeAws_json1_1ArchiveResponseList = (output, context) => {
3846
3816
  const deserializeAws_json1_1AwsVpcConfiguration = (output, context) => {
3847
3817
  return {
3848
3818
  AssignPublicIp: (0, smithy_client_1.expectString)(output.AssignPublicIp),
3849
- SecurityGroups: output.SecurityGroups !== undefined && output.SecurityGroups !== null
3850
- ? deserializeAws_json1_1StringList(output.SecurityGroups, context)
3851
- : undefined,
3852
- Subnets: output.Subnets !== undefined && output.Subnets !== null
3853
- ? deserializeAws_json1_1StringList(output.Subnets, context)
3854
- : undefined,
3819
+ SecurityGroups: output.SecurityGroups != null ? deserializeAws_json1_1StringList(output.SecurityGroups, context) : undefined,
3820
+ Subnets: output.Subnets != null ? deserializeAws_json1_1StringList(output.Subnets, context) : undefined,
3855
3821
  };
3856
3822
  };
3857
3823
  const deserializeAws_json1_1BatchArrayProperties = (output, context) => {
@@ -3861,12 +3827,12 @@ const deserializeAws_json1_1BatchArrayProperties = (output, context) => {
3861
3827
  };
3862
3828
  const deserializeAws_json1_1BatchParameters = (output, context) => {
3863
3829
  return {
3864
- ArrayProperties: output.ArrayProperties !== undefined && output.ArrayProperties !== null
3830
+ ArrayProperties: output.ArrayProperties != null
3865
3831
  ? deserializeAws_json1_1BatchArrayProperties(output.ArrayProperties, context)
3866
3832
  : undefined,
3867
3833
  JobDefinition: (0, smithy_client_1.expectString)(output.JobDefinition),
3868
3834
  JobName: (0, smithy_client_1.expectString)(output.JobName),
3869
- RetryStrategy: output.RetryStrategy !== undefined && output.RetryStrategy !== null
3835
+ RetryStrategy: output.RetryStrategy != null
3870
3836
  ? deserializeAws_json1_1BatchRetryStrategy(output.RetryStrategy, context)
3871
3837
  : undefined,
3872
3838
  };
@@ -3911,13 +3877,13 @@ const deserializeAws_json1_1Connection = (output, context) => {
3911
3877
  AuthorizationType: (0, smithy_client_1.expectString)(output.AuthorizationType),
3912
3878
  ConnectionArn: (0, smithy_client_1.expectString)(output.ConnectionArn),
3913
3879
  ConnectionState: (0, smithy_client_1.expectString)(output.ConnectionState),
3914
- CreationTime: output.CreationTime !== undefined && output.CreationTime !== null
3880
+ CreationTime: output.CreationTime != null
3915
3881
  ? (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseEpochTimestamp)((0, smithy_client_1.expectNumber)(output.CreationTime)))
3916
3882
  : undefined,
3917
- LastAuthorizedTime: output.LastAuthorizedTime !== undefined && output.LastAuthorizedTime !== null
3883
+ LastAuthorizedTime: output.LastAuthorizedTime != null
3918
3884
  ? (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseEpochTimestamp)((0, smithy_client_1.expectNumber)(output.LastAuthorizedTime)))
3919
3885
  : undefined,
3920
- LastModifiedTime: output.LastModifiedTime !== undefined && output.LastModifiedTime !== null
3886
+ LastModifiedTime: output.LastModifiedTime != null
3921
3887
  ? (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseEpochTimestamp)((0, smithy_client_1.expectNumber)(output.LastModifiedTime)))
3922
3888
  : undefined,
3923
3889
  Name: (0, smithy_client_1.expectString)(output.Name),
@@ -3931,16 +3897,16 @@ const deserializeAws_json1_1ConnectionApiKeyAuthResponseParameters = (output, co
3931
3897
  };
3932
3898
  const deserializeAws_json1_1ConnectionAuthResponseParameters = (output, context) => {
3933
3899
  return {
3934
- ApiKeyAuthParameters: output.ApiKeyAuthParameters !== undefined && output.ApiKeyAuthParameters !== null
3900
+ ApiKeyAuthParameters: output.ApiKeyAuthParameters != null
3935
3901
  ? deserializeAws_json1_1ConnectionApiKeyAuthResponseParameters(output.ApiKeyAuthParameters, context)
3936
3902
  : undefined,
3937
- BasicAuthParameters: output.BasicAuthParameters !== undefined && output.BasicAuthParameters !== null
3903
+ BasicAuthParameters: output.BasicAuthParameters != null
3938
3904
  ? deserializeAws_json1_1ConnectionBasicAuthResponseParameters(output.BasicAuthParameters, context)
3939
3905
  : undefined,
3940
- InvocationHttpParameters: output.InvocationHttpParameters !== undefined && output.InvocationHttpParameters !== null
3906
+ InvocationHttpParameters: output.InvocationHttpParameters != null
3941
3907
  ? deserializeAws_json1_1ConnectionHttpParameters(output.InvocationHttpParameters, context)
3942
3908
  : undefined,
3943
- OAuthParameters: output.OAuthParameters !== undefined && output.OAuthParameters !== null
3909
+ OAuthParameters: output.OAuthParameters != null
3944
3910
  ? deserializeAws_json1_1ConnectionOAuthResponseParameters(output.OAuthParameters, context)
3945
3911
  : undefined,
3946
3912
  };
@@ -3988,13 +3954,13 @@ const deserializeAws_json1_1ConnectionHeaderParametersList = (output, context) =
3988
3954
  };
3989
3955
  const deserializeAws_json1_1ConnectionHttpParameters = (output, context) => {
3990
3956
  return {
3991
- BodyParameters: output.BodyParameters !== undefined && output.BodyParameters !== null
3957
+ BodyParameters: output.BodyParameters != null
3992
3958
  ? deserializeAws_json1_1ConnectionBodyParametersList(output.BodyParameters, context)
3993
3959
  : undefined,
3994
- HeaderParameters: output.HeaderParameters !== undefined && output.HeaderParameters !== null
3960
+ HeaderParameters: output.HeaderParameters != null
3995
3961
  ? deserializeAws_json1_1ConnectionHeaderParametersList(output.HeaderParameters, context)
3996
3962
  : undefined,
3997
- QueryStringParameters: output.QueryStringParameters !== undefined && output.QueryStringParameters !== null
3963
+ QueryStringParameters: output.QueryStringParameters != null
3998
3964
  ? deserializeAws_json1_1ConnectionQueryStringParametersList(output.QueryStringParameters, context)
3999
3965
  : undefined,
4000
3966
  };
@@ -4007,11 +3973,11 @@ const deserializeAws_json1_1ConnectionOAuthClientResponseParameters = (output, c
4007
3973
  const deserializeAws_json1_1ConnectionOAuthResponseParameters = (output, context) => {
4008
3974
  return {
4009
3975
  AuthorizationEndpoint: (0, smithy_client_1.expectString)(output.AuthorizationEndpoint),
4010
- ClientParameters: output.ClientParameters !== undefined && output.ClientParameters !== null
3976
+ ClientParameters: output.ClientParameters != null
4011
3977
  ? deserializeAws_json1_1ConnectionOAuthClientResponseParameters(output.ClientParameters, context)
4012
3978
  : undefined,
4013
3979
  HttpMethod: (0, smithy_client_1.expectString)(output.HttpMethod),
4014
- OAuthHttpParameters: output.OAuthHttpParameters !== undefined && output.OAuthHttpParameters !== null
3980
+ OAuthHttpParameters: output.OAuthHttpParameters != null
4015
3981
  ? deserializeAws_json1_1ConnectionHttpParameters(output.OAuthHttpParameters, context)
4016
3982
  : undefined,
4017
3983
  };
@@ -4049,10 +4015,10 @@ const deserializeAws_json1_1CreateApiDestinationResponse = (output, context) =>
4049
4015
  return {
4050
4016
  ApiDestinationArn: (0, smithy_client_1.expectString)(output.ApiDestinationArn),
4051
4017
  ApiDestinationState: (0, smithy_client_1.expectString)(output.ApiDestinationState),
4052
- CreationTime: output.CreationTime !== undefined && output.CreationTime !== null
4018
+ CreationTime: output.CreationTime != null
4053
4019
  ? (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseEpochTimestamp)((0, smithy_client_1.expectNumber)(output.CreationTime)))
4054
4020
  : undefined,
4055
- LastModifiedTime: output.LastModifiedTime !== undefined && output.LastModifiedTime !== null
4021
+ LastModifiedTime: output.LastModifiedTime != null
4056
4022
  ? (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseEpochTimestamp)((0, smithy_client_1.expectNumber)(output.LastModifiedTime)))
4057
4023
  : undefined,
4058
4024
  };
@@ -4060,7 +4026,7 @@ const deserializeAws_json1_1CreateApiDestinationResponse = (output, context) =>
4060
4026
  const deserializeAws_json1_1CreateArchiveResponse = (output, context) => {
4061
4027
  return {
4062
4028
  ArchiveArn: (0, smithy_client_1.expectString)(output.ArchiveArn),
4063
- CreationTime: output.CreationTime !== undefined && output.CreationTime !== null
4029
+ CreationTime: output.CreationTime != null
4064
4030
  ? (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseEpochTimestamp)((0, smithy_client_1.expectNumber)(output.CreationTime)))
4065
4031
  : undefined,
4066
4032
  State: (0, smithy_client_1.expectString)(output.State),
@@ -4071,10 +4037,10 @@ const deserializeAws_json1_1CreateConnectionResponse = (output, context) => {
4071
4037
  return {
4072
4038
  ConnectionArn: (0, smithy_client_1.expectString)(output.ConnectionArn),
4073
4039
  ConnectionState: (0, smithy_client_1.expectString)(output.ConnectionState),
4074
- CreationTime: output.CreationTime !== undefined && output.CreationTime !== null
4040
+ CreationTime: output.CreationTime != null
4075
4041
  ? (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseEpochTimestamp)((0, smithy_client_1.expectNumber)(output.CreationTime)))
4076
4042
  : undefined,
4077
- LastModifiedTime: output.LastModifiedTime !== undefined && output.LastModifiedTime !== null
4043
+ LastModifiedTime: output.LastModifiedTime != null
4078
4044
  ? (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseEpochTimestamp)((0, smithy_client_1.expectNumber)(output.LastModifiedTime)))
4079
4045
  : undefined,
4080
4046
  };
@@ -4098,13 +4064,13 @@ const deserializeAws_json1_1DeauthorizeConnectionResponse = (output, context) =>
4098
4064
  return {
4099
4065
  ConnectionArn: (0, smithy_client_1.expectString)(output.ConnectionArn),
4100
4066
  ConnectionState: (0, smithy_client_1.expectString)(output.ConnectionState),
4101
- CreationTime: output.CreationTime !== undefined && output.CreationTime !== null
4067
+ CreationTime: output.CreationTime != null
4102
4068
  ? (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseEpochTimestamp)((0, smithy_client_1.expectNumber)(output.CreationTime)))
4103
4069
  : undefined,
4104
- LastAuthorizedTime: output.LastAuthorizedTime !== undefined && output.LastAuthorizedTime !== null
4070
+ LastAuthorizedTime: output.LastAuthorizedTime != null
4105
4071
  ? (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseEpochTimestamp)((0, smithy_client_1.expectNumber)(output.LastAuthorizedTime)))
4106
4072
  : undefined,
4107
- LastModifiedTime: output.LastModifiedTime !== undefined && output.LastModifiedTime !== null
4073
+ LastModifiedTime: output.LastModifiedTime != null
4108
4074
  ? (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseEpochTimestamp)((0, smithy_client_1.expectNumber)(output.LastModifiedTime)))
4109
4075
  : undefined,
4110
4076
  };
@@ -4119,13 +4085,13 @@ const deserializeAws_json1_1DeleteConnectionResponse = (output, context) => {
4119
4085
  return {
4120
4086
  ConnectionArn: (0, smithy_client_1.expectString)(output.ConnectionArn),
4121
4087
  ConnectionState: (0, smithy_client_1.expectString)(output.ConnectionState),
4122
- CreationTime: output.CreationTime !== undefined && output.CreationTime !== null
4088
+ CreationTime: output.CreationTime != null
4123
4089
  ? (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseEpochTimestamp)((0, smithy_client_1.expectNumber)(output.CreationTime)))
4124
4090
  : undefined,
4125
- LastAuthorizedTime: output.LastAuthorizedTime !== undefined && output.LastAuthorizedTime !== null
4091
+ LastAuthorizedTime: output.LastAuthorizedTime != null
4126
4092
  ? (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseEpochTimestamp)((0, smithy_client_1.expectNumber)(output.LastAuthorizedTime)))
4127
4093
  : undefined,
4128
- LastModifiedTime: output.LastModifiedTime !== undefined && output.LastModifiedTime !== null
4094
+ LastModifiedTime: output.LastModifiedTime != null
4129
4095
  ? (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseEpochTimestamp)((0, smithy_client_1.expectNumber)(output.LastModifiedTime)))
4130
4096
  : undefined,
4131
4097
  };
@@ -4135,14 +4101,14 @@ const deserializeAws_json1_1DescribeApiDestinationResponse = (output, context) =
4135
4101
  ApiDestinationArn: (0, smithy_client_1.expectString)(output.ApiDestinationArn),
4136
4102
  ApiDestinationState: (0, smithy_client_1.expectString)(output.ApiDestinationState),
4137
4103
  ConnectionArn: (0, smithy_client_1.expectString)(output.ConnectionArn),
4138
- CreationTime: output.CreationTime !== undefined && output.CreationTime !== null
4104
+ CreationTime: output.CreationTime != null
4139
4105
  ? (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseEpochTimestamp)((0, smithy_client_1.expectNumber)(output.CreationTime)))
4140
4106
  : undefined,
4141
4107
  Description: (0, smithy_client_1.expectString)(output.Description),
4142
4108
  HttpMethod: (0, smithy_client_1.expectString)(output.HttpMethod),
4143
4109
  InvocationEndpoint: (0, smithy_client_1.expectString)(output.InvocationEndpoint),
4144
4110
  InvocationRateLimitPerSecond: (0, smithy_client_1.expectInt32)(output.InvocationRateLimitPerSecond),
4145
- LastModifiedTime: output.LastModifiedTime !== undefined && output.LastModifiedTime !== null
4111
+ LastModifiedTime: output.LastModifiedTime != null
4146
4112
  ? (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseEpochTimestamp)((0, smithy_client_1.expectNumber)(output.LastModifiedTime)))
4147
4113
  : undefined,
4148
4114
  Name: (0, smithy_client_1.expectString)(output.Name),
@@ -4152,7 +4118,7 @@ const deserializeAws_json1_1DescribeArchiveResponse = (output, context) => {
4152
4118
  return {
4153
4119
  ArchiveArn: (0, smithy_client_1.expectString)(output.ArchiveArn),
4154
4120
  ArchiveName: (0, smithy_client_1.expectString)(output.ArchiveName),
4155
- CreationTime: output.CreationTime !== undefined && output.CreationTime !== null
4121
+ CreationTime: output.CreationTime != null
4156
4122
  ? (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseEpochTimestamp)((0, smithy_client_1.expectNumber)(output.CreationTime)))
4157
4123
  : undefined,
4158
4124
  Description: (0, smithy_client_1.expectString)(output.Description),
@@ -4167,20 +4133,20 @@ const deserializeAws_json1_1DescribeArchiveResponse = (output, context) => {
4167
4133
  };
4168
4134
  const deserializeAws_json1_1DescribeConnectionResponse = (output, context) => {
4169
4135
  return {
4170
- AuthParameters: output.AuthParameters !== undefined && output.AuthParameters !== null
4136
+ AuthParameters: output.AuthParameters != null
4171
4137
  ? deserializeAws_json1_1ConnectionAuthResponseParameters(output.AuthParameters, context)
4172
4138
  : undefined,
4173
4139
  AuthorizationType: (0, smithy_client_1.expectString)(output.AuthorizationType),
4174
4140
  ConnectionArn: (0, smithy_client_1.expectString)(output.ConnectionArn),
4175
4141
  ConnectionState: (0, smithy_client_1.expectString)(output.ConnectionState),
4176
- CreationTime: output.CreationTime !== undefined && output.CreationTime !== null
4142
+ CreationTime: output.CreationTime != null
4177
4143
  ? (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseEpochTimestamp)((0, smithy_client_1.expectNumber)(output.CreationTime)))
4178
4144
  : undefined,
4179
4145
  Description: (0, smithy_client_1.expectString)(output.Description),
4180
- LastAuthorizedTime: output.LastAuthorizedTime !== undefined && output.LastAuthorizedTime !== null
4146
+ LastAuthorizedTime: output.LastAuthorizedTime != null
4181
4147
  ? (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseEpochTimestamp)((0, smithy_client_1.expectNumber)(output.LastAuthorizedTime)))
4182
4148
  : undefined,
4183
- LastModifiedTime: output.LastModifiedTime !== undefined && output.LastModifiedTime !== null
4149
+ LastModifiedTime: output.LastModifiedTime != null
4184
4150
  ? (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseEpochTimestamp)((0, smithy_client_1.expectNumber)(output.LastModifiedTime)))
4185
4151
  : undefined,
4186
4152
  Name: (0, smithy_client_1.expectString)(output.Name),
@@ -4199,10 +4165,10 @@ const deserializeAws_json1_1DescribeEventSourceResponse = (output, context) => {
4199
4165
  return {
4200
4166
  Arn: (0, smithy_client_1.expectString)(output.Arn),
4201
4167
  CreatedBy: (0, smithy_client_1.expectString)(output.CreatedBy),
4202
- CreationTime: output.CreationTime !== undefined && output.CreationTime !== null
4168
+ CreationTime: output.CreationTime != null
4203
4169
  ? (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseEpochTimestamp)((0, smithy_client_1.expectNumber)(output.CreationTime)))
4204
4170
  : undefined,
4205
- ExpirationTime: output.ExpirationTime !== undefined && output.ExpirationTime !== null
4171
+ ExpirationTime: output.ExpirationTime != null
4206
4172
  ? (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseEpochTimestamp)((0, smithy_client_1.expectNumber)(output.ExpirationTime)))
4207
4173
  : undefined,
4208
4174
  Name: (0, smithy_client_1.expectString)(output.Name),
@@ -4218,25 +4184,23 @@ const deserializeAws_json1_1DescribePartnerEventSourceResponse = (output, contex
4218
4184
  const deserializeAws_json1_1DescribeReplayResponse = (output, context) => {
4219
4185
  return {
4220
4186
  Description: (0, smithy_client_1.expectString)(output.Description),
4221
- Destination: output.Destination !== undefined && output.Destination !== null
4222
- ? deserializeAws_json1_1ReplayDestination(output.Destination, context)
4223
- : undefined,
4224
- EventEndTime: output.EventEndTime !== undefined && output.EventEndTime !== null
4187
+ Destination: output.Destination != null ? deserializeAws_json1_1ReplayDestination(output.Destination, context) : undefined,
4188
+ EventEndTime: output.EventEndTime != null
4225
4189
  ? (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseEpochTimestamp)((0, smithy_client_1.expectNumber)(output.EventEndTime)))
4226
4190
  : undefined,
4227
- EventLastReplayedTime: output.EventLastReplayedTime !== undefined && output.EventLastReplayedTime !== null
4191
+ EventLastReplayedTime: output.EventLastReplayedTime != null
4228
4192
  ? (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseEpochTimestamp)((0, smithy_client_1.expectNumber)(output.EventLastReplayedTime)))
4229
4193
  : undefined,
4230
4194
  EventSourceArn: (0, smithy_client_1.expectString)(output.EventSourceArn),
4231
- EventStartTime: output.EventStartTime !== undefined && output.EventStartTime !== null
4195
+ EventStartTime: output.EventStartTime != null
4232
4196
  ? (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseEpochTimestamp)((0, smithy_client_1.expectNumber)(output.EventStartTime)))
4233
4197
  : undefined,
4234
4198
  ReplayArn: (0, smithy_client_1.expectString)(output.ReplayArn),
4235
- ReplayEndTime: output.ReplayEndTime !== undefined && output.ReplayEndTime !== null
4199
+ ReplayEndTime: output.ReplayEndTime != null
4236
4200
  ? (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseEpochTimestamp)((0, smithy_client_1.expectNumber)(output.ReplayEndTime)))
4237
4201
  : undefined,
4238
4202
  ReplayName: (0, smithy_client_1.expectString)(output.ReplayName),
4239
- ReplayStartTime: output.ReplayStartTime !== undefined && output.ReplayStartTime !== null
4203
+ ReplayStartTime: output.ReplayStartTime != null
4240
4204
  ? (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseEpochTimestamp)((0, smithy_client_1.expectNumber)(output.ReplayStartTime)))
4241
4205
  : undefined,
4242
4206
  State: (0, smithy_client_1.expectString)(output.State),
@@ -4259,28 +4223,26 @@ const deserializeAws_json1_1DescribeRuleResponse = (output, context) => {
4259
4223
  };
4260
4224
  const deserializeAws_json1_1EcsParameters = (output, context) => {
4261
4225
  return {
4262
- CapacityProviderStrategy: output.CapacityProviderStrategy !== undefined && output.CapacityProviderStrategy !== null
4226
+ CapacityProviderStrategy: output.CapacityProviderStrategy != null
4263
4227
  ? deserializeAws_json1_1CapacityProviderStrategy(output.CapacityProviderStrategy, context)
4264
4228
  : undefined,
4265
4229
  EnableECSManagedTags: (0, smithy_client_1.expectBoolean)(output.EnableECSManagedTags),
4266
4230
  EnableExecuteCommand: (0, smithy_client_1.expectBoolean)(output.EnableExecuteCommand),
4267
4231
  Group: (0, smithy_client_1.expectString)(output.Group),
4268
4232
  LaunchType: (0, smithy_client_1.expectString)(output.LaunchType),
4269
- NetworkConfiguration: output.NetworkConfiguration !== undefined && output.NetworkConfiguration !== null
4233
+ NetworkConfiguration: output.NetworkConfiguration != null
4270
4234
  ? deserializeAws_json1_1NetworkConfiguration(output.NetworkConfiguration, context)
4271
4235
  : undefined,
4272
- PlacementConstraints: output.PlacementConstraints !== undefined && output.PlacementConstraints !== null
4236
+ PlacementConstraints: output.PlacementConstraints != null
4273
4237
  ? deserializeAws_json1_1PlacementConstraints(output.PlacementConstraints, context)
4274
4238
  : undefined,
4275
- PlacementStrategy: output.PlacementStrategy !== undefined && output.PlacementStrategy !== null
4239
+ PlacementStrategy: output.PlacementStrategy != null
4276
4240
  ? deserializeAws_json1_1PlacementStrategies(output.PlacementStrategy, context)
4277
4241
  : undefined,
4278
4242
  PlatformVersion: (0, smithy_client_1.expectString)(output.PlatformVersion),
4279
4243
  PropagateTags: (0, smithy_client_1.expectString)(output.PropagateTags),
4280
4244
  ReferenceId: (0, smithy_client_1.expectString)(output.ReferenceId),
4281
- Tags: output.Tags !== undefined && output.Tags !== null
4282
- ? deserializeAws_json1_1TagList(output.Tags, context)
4283
- : undefined,
4245
+ Tags: output.Tags != null ? deserializeAws_json1_1TagList(output.Tags, context) : undefined,
4284
4246
  TaskCount: (0, smithy_client_1.expectInt32)(output.TaskCount),
4285
4247
  TaskDefinitionArn: (0, smithy_client_1.expectString)(output.TaskDefinitionArn),
4286
4248
  };
@@ -4307,10 +4269,10 @@ const deserializeAws_json1_1EventSource = (output, context) => {
4307
4269
  return {
4308
4270
  Arn: (0, smithy_client_1.expectString)(output.Arn),
4309
4271
  CreatedBy: (0, smithy_client_1.expectString)(output.CreatedBy),
4310
- CreationTime: output.CreationTime !== undefined && output.CreationTime !== null
4272
+ CreationTime: output.CreationTime != null
4311
4273
  ? (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseEpochTimestamp)((0, smithy_client_1.expectNumber)(output.CreationTime)))
4312
4274
  : undefined,
4313
- ExpirationTime: output.ExpirationTime !== undefined && output.ExpirationTime !== null
4275
+ ExpirationTime: output.ExpirationTime != null
4314
4276
  ? (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseEpochTimestamp)((0, smithy_client_1.expectNumber)(output.ExpirationTime)))
4315
4277
  : undefined,
4316
4278
  Name: (0, smithy_client_1.expectString)(output.Name),
@@ -4341,13 +4303,13 @@ const deserializeAws_json1_1HeaderParametersMap = (output, context) => {
4341
4303
  };
4342
4304
  const deserializeAws_json1_1HttpParameters = (output, context) => {
4343
4305
  return {
4344
- HeaderParameters: output.HeaderParameters !== undefined && output.HeaderParameters !== null
4306
+ HeaderParameters: output.HeaderParameters != null
4345
4307
  ? deserializeAws_json1_1HeaderParametersMap(output.HeaderParameters, context)
4346
4308
  : undefined,
4347
- PathParameterValues: output.PathParameterValues !== undefined && output.PathParameterValues !== null
4309
+ PathParameterValues: output.PathParameterValues != null
4348
4310
  ? deserializeAws_json1_1PathParameterList(output.PathParameterValues, context)
4349
4311
  : undefined,
4350
- QueryStringParameters: output.QueryStringParameters !== undefined && output.QueryStringParameters !== null
4312
+ QueryStringParameters: output.QueryStringParameters != null
4351
4313
  ? deserializeAws_json1_1QueryStringParametersMap(output.QueryStringParameters, context)
4352
4314
  : undefined,
4353
4315
  };
@@ -4359,9 +4321,7 @@ const deserializeAws_json1_1IllegalStatusException = (output, context) => {
4359
4321
  };
4360
4322
  const deserializeAws_json1_1InputTransformer = (output, context) => {
4361
4323
  return {
4362
- InputPathsMap: output.InputPathsMap !== undefined && output.InputPathsMap !== null
4363
- ? deserializeAws_json1_1TransformerPaths(output.InputPathsMap, context)
4364
- : undefined,
4324
+ InputPathsMap: output.InputPathsMap != null ? deserializeAws_json1_1TransformerPaths(output.InputPathsMap, context) : undefined,
4365
4325
  InputTemplate: (0, smithy_client_1.expectString)(output.InputTemplate),
4366
4326
  };
4367
4327
  };
@@ -4392,7 +4352,7 @@ const deserializeAws_json1_1LimitExceededException = (output, context) => {
4392
4352
  };
4393
4353
  const deserializeAws_json1_1ListApiDestinationsResponse = (output, context) => {
4394
4354
  return {
4395
- ApiDestinations: output.ApiDestinations !== undefined && output.ApiDestinations !== null
4355
+ ApiDestinations: output.ApiDestinations != null
4396
4356
  ? deserializeAws_json1_1ApiDestinationResponseList(output.ApiDestinations, context)
4397
4357
  : undefined,
4398
4358
  NextToken: (0, smithy_client_1.expectString)(output.NextToken),
@@ -4400,15 +4360,13 @@ const deserializeAws_json1_1ListApiDestinationsResponse = (output, context) => {
4400
4360
  };
4401
4361
  const deserializeAws_json1_1ListArchivesResponse = (output, context) => {
4402
4362
  return {
4403
- Archives: output.Archives !== undefined && output.Archives !== null
4404
- ? deserializeAws_json1_1ArchiveResponseList(output.Archives, context)
4405
- : undefined,
4363
+ Archives: output.Archives != null ? deserializeAws_json1_1ArchiveResponseList(output.Archives, context) : undefined,
4406
4364
  NextToken: (0, smithy_client_1.expectString)(output.NextToken),
4407
4365
  };
4408
4366
  };
4409
4367
  const deserializeAws_json1_1ListConnectionsResponse = (output, context) => {
4410
4368
  return {
4411
- Connections: output.Connections !== undefined && output.Connections !== null
4369
+ Connections: output.Connections != null
4412
4370
  ? deserializeAws_json1_1ConnectionResponseList(output.Connections, context)
4413
4371
  : undefined,
4414
4372
  NextToken: (0, smithy_client_1.expectString)(output.NextToken),
@@ -4416,24 +4374,20 @@ const deserializeAws_json1_1ListConnectionsResponse = (output, context) => {
4416
4374
  };
4417
4375
  const deserializeAws_json1_1ListEventBusesResponse = (output, context) => {
4418
4376
  return {
4419
- EventBuses: output.EventBuses !== undefined && output.EventBuses !== null
4420
- ? deserializeAws_json1_1EventBusList(output.EventBuses, context)
4421
- : undefined,
4377
+ EventBuses: output.EventBuses != null ? deserializeAws_json1_1EventBusList(output.EventBuses, context) : undefined,
4422
4378
  NextToken: (0, smithy_client_1.expectString)(output.NextToken),
4423
4379
  };
4424
4380
  };
4425
4381
  const deserializeAws_json1_1ListEventSourcesResponse = (output, context) => {
4426
4382
  return {
4427
- EventSources: output.EventSources !== undefined && output.EventSources !== null
4428
- ? deserializeAws_json1_1EventSourceList(output.EventSources, context)
4429
- : undefined,
4383
+ EventSources: output.EventSources != null ? deserializeAws_json1_1EventSourceList(output.EventSources, context) : undefined,
4430
4384
  NextToken: (0, smithy_client_1.expectString)(output.NextToken),
4431
4385
  };
4432
4386
  };
4433
4387
  const deserializeAws_json1_1ListPartnerEventSourceAccountsResponse = (output, context) => {
4434
4388
  return {
4435
4389
  NextToken: (0, smithy_client_1.expectString)(output.NextToken),
4436
- PartnerEventSourceAccounts: output.PartnerEventSourceAccounts !== undefined && output.PartnerEventSourceAccounts !== null
4390
+ PartnerEventSourceAccounts: output.PartnerEventSourceAccounts != null
4437
4391
  ? deserializeAws_json1_1PartnerEventSourceAccountList(output.PartnerEventSourceAccounts, context)
4438
4392
  : undefined,
4439
4393
  };
@@ -4441,7 +4395,7 @@ const deserializeAws_json1_1ListPartnerEventSourceAccountsResponse = (output, co
4441
4395
  const deserializeAws_json1_1ListPartnerEventSourcesResponse = (output, context) => {
4442
4396
  return {
4443
4397
  NextToken: (0, smithy_client_1.expectString)(output.NextToken),
4444
- PartnerEventSources: output.PartnerEventSources !== undefined && output.PartnerEventSources !== null
4398
+ PartnerEventSources: output.PartnerEventSources != null
4445
4399
  ? deserializeAws_json1_1PartnerEventSourceList(output.PartnerEventSources, context)
4446
4400
  : undefined,
4447
4401
  };
@@ -4449,40 +4403,30 @@ const deserializeAws_json1_1ListPartnerEventSourcesResponse = (output, context)
4449
4403
  const deserializeAws_json1_1ListReplaysResponse = (output, context) => {
4450
4404
  return {
4451
4405
  NextToken: (0, smithy_client_1.expectString)(output.NextToken),
4452
- Replays: output.Replays !== undefined && output.Replays !== null
4453
- ? deserializeAws_json1_1ReplayList(output.Replays, context)
4454
- : undefined,
4406
+ Replays: output.Replays != null ? deserializeAws_json1_1ReplayList(output.Replays, context) : undefined,
4455
4407
  };
4456
4408
  };
4457
4409
  const deserializeAws_json1_1ListRuleNamesByTargetResponse = (output, context) => {
4458
4410
  return {
4459
4411
  NextToken: (0, smithy_client_1.expectString)(output.NextToken),
4460
- RuleNames: output.RuleNames !== undefined && output.RuleNames !== null
4461
- ? deserializeAws_json1_1RuleNameList(output.RuleNames, context)
4462
- : undefined,
4412
+ RuleNames: output.RuleNames != null ? deserializeAws_json1_1RuleNameList(output.RuleNames, context) : undefined,
4463
4413
  };
4464
4414
  };
4465
4415
  const deserializeAws_json1_1ListRulesResponse = (output, context) => {
4466
4416
  return {
4467
4417
  NextToken: (0, smithy_client_1.expectString)(output.NextToken),
4468
- Rules: output.Rules !== undefined && output.Rules !== null
4469
- ? deserializeAws_json1_1RuleResponseList(output.Rules, context)
4470
- : undefined,
4418
+ Rules: output.Rules != null ? deserializeAws_json1_1RuleResponseList(output.Rules, context) : undefined,
4471
4419
  };
4472
4420
  };
4473
4421
  const deserializeAws_json1_1ListTagsForResourceResponse = (output, context) => {
4474
4422
  return {
4475
- Tags: output.Tags !== undefined && output.Tags !== null
4476
- ? deserializeAws_json1_1TagList(output.Tags, context)
4477
- : undefined,
4423
+ Tags: output.Tags != null ? deserializeAws_json1_1TagList(output.Tags, context) : undefined,
4478
4424
  };
4479
4425
  };
4480
4426
  const deserializeAws_json1_1ListTargetsByRuleResponse = (output, context) => {
4481
4427
  return {
4482
4428
  NextToken: (0, smithy_client_1.expectString)(output.NextToken),
4483
- Targets: output.Targets !== undefined && output.Targets !== null
4484
- ? deserializeAws_json1_1TargetList(output.Targets, context)
4485
- : undefined,
4429
+ Targets: output.Targets != null ? deserializeAws_json1_1TargetList(output.Targets, context) : undefined,
4486
4430
  };
4487
4431
  };
4488
4432
  const deserializeAws_json1_1ManagedRuleException = (output, context) => {
@@ -4492,7 +4436,7 @@ const deserializeAws_json1_1ManagedRuleException = (output, context) => {
4492
4436
  };
4493
4437
  const deserializeAws_json1_1NetworkConfiguration = (output, context) => {
4494
4438
  return {
4495
- awsvpcConfiguration: output.awsvpcConfiguration !== undefined && output.awsvpcConfiguration !== null
4439
+ awsvpcConfiguration: output.awsvpcConfiguration != null
4496
4440
  ? deserializeAws_json1_1AwsVpcConfiguration(output.awsvpcConfiguration, context)
4497
4441
  : undefined,
4498
4442
  };
@@ -4511,10 +4455,10 @@ const deserializeAws_json1_1PartnerEventSource = (output, context) => {
4511
4455
  const deserializeAws_json1_1PartnerEventSourceAccount = (output, context) => {
4512
4456
  return {
4513
4457
  Account: (0, smithy_client_1.expectString)(output.Account),
4514
- CreationTime: output.CreationTime !== undefined && output.CreationTime !== null
4458
+ CreationTime: output.CreationTime != null
4515
4459
  ? (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseEpochTimestamp)((0, smithy_client_1.expectNumber)(output.CreationTime)))
4516
4460
  : undefined,
4517
- ExpirationTime: output.ExpirationTime !== undefined && output.ExpirationTime !== null
4461
+ ExpirationTime: output.ExpirationTime != null
4518
4462
  ? (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseEpochTimestamp)((0, smithy_client_1.expectNumber)(output.ExpirationTime)))
4519
4463
  : undefined,
4520
4464
  State: (0, smithy_client_1.expectString)(output.State),
@@ -4594,9 +4538,7 @@ const deserializeAws_json1_1PolicyLengthExceededException = (output, context) =>
4594
4538
  };
4595
4539
  const deserializeAws_json1_1PutEventsResponse = (output, context) => {
4596
4540
  return {
4597
- Entries: output.Entries !== undefined && output.Entries !== null
4598
- ? deserializeAws_json1_1PutEventsResultEntryList(output.Entries, context)
4599
- : undefined,
4541
+ Entries: output.Entries != null ? deserializeAws_json1_1PutEventsResultEntryList(output.Entries, context) : undefined,
4600
4542
  FailedEntryCount: (0, smithy_client_1.expectInt32)(output.FailedEntryCount),
4601
4543
  };
4602
4544
  };
@@ -4620,7 +4562,7 @@ const deserializeAws_json1_1PutEventsResultEntryList = (output, context) => {
4620
4562
  };
4621
4563
  const deserializeAws_json1_1PutPartnerEventsResponse = (output, context) => {
4622
4564
  return {
4623
- Entries: output.Entries !== undefined && output.Entries !== null
4565
+ Entries: output.Entries != null
4624
4566
  ? deserializeAws_json1_1PutPartnerEventsResultEntryList(output.Entries, context)
4625
4567
  : undefined,
4626
4568
  FailedEntryCount: (0, smithy_client_1.expectInt32)(output.FailedEntryCount),
@@ -4651,7 +4593,7 @@ const deserializeAws_json1_1PutRuleResponse = (output, context) => {
4651
4593
  };
4652
4594
  const deserializeAws_json1_1PutTargetsResponse = (output, context) => {
4653
4595
  return {
4654
- FailedEntries: output.FailedEntries !== undefined && output.FailedEntries !== null
4596
+ FailedEntries: output.FailedEntries != null
4655
4597
  ? deserializeAws_json1_1PutTargetsResultEntryList(output.FailedEntries, context)
4656
4598
  : undefined,
4657
4599
  FailedEntryCount: (0, smithy_client_1.expectInt32)(output.FailedEntryCount),
@@ -4698,7 +4640,7 @@ const deserializeAws_json1_1RedshiftDataParameters = (output, context) => {
4698
4640
  };
4699
4641
  const deserializeAws_json1_1RemoveTargetsResponse = (output, context) => {
4700
4642
  return {
4701
- FailedEntries: output.FailedEntries !== undefined && output.FailedEntries !== null
4643
+ FailedEntries: output.FailedEntries != null
4702
4644
  ? deserializeAws_json1_1RemoveTargetsResultEntryList(output.FailedEntries, context)
4703
4645
  : undefined,
4704
4646
  FailedEntryCount: (0, smithy_client_1.expectInt32)(output.FailedEntryCount),
@@ -4724,21 +4666,21 @@ const deserializeAws_json1_1RemoveTargetsResultEntryList = (output, context) =>
4724
4666
  };
4725
4667
  const deserializeAws_json1_1Replay = (output, context) => {
4726
4668
  return {
4727
- EventEndTime: output.EventEndTime !== undefined && output.EventEndTime !== null
4669
+ EventEndTime: output.EventEndTime != null
4728
4670
  ? (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseEpochTimestamp)((0, smithy_client_1.expectNumber)(output.EventEndTime)))
4729
4671
  : undefined,
4730
- EventLastReplayedTime: output.EventLastReplayedTime !== undefined && output.EventLastReplayedTime !== null
4672
+ EventLastReplayedTime: output.EventLastReplayedTime != null
4731
4673
  ? (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseEpochTimestamp)((0, smithy_client_1.expectNumber)(output.EventLastReplayedTime)))
4732
4674
  : undefined,
4733
4675
  EventSourceArn: (0, smithy_client_1.expectString)(output.EventSourceArn),
4734
- EventStartTime: output.EventStartTime !== undefined && output.EventStartTime !== null
4676
+ EventStartTime: output.EventStartTime != null
4735
4677
  ? (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseEpochTimestamp)((0, smithy_client_1.expectNumber)(output.EventStartTime)))
4736
4678
  : undefined,
4737
- ReplayEndTime: output.ReplayEndTime !== undefined && output.ReplayEndTime !== null
4679
+ ReplayEndTime: output.ReplayEndTime != null
4738
4680
  ? (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseEpochTimestamp)((0, smithy_client_1.expectNumber)(output.ReplayEndTime)))
4739
4681
  : undefined,
4740
4682
  ReplayName: (0, smithy_client_1.expectString)(output.ReplayName),
4741
- ReplayStartTime: output.ReplayStartTime !== undefined && output.ReplayStartTime !== null
4683
+ ReplayStartTime: output.ReplayStartTime != null
4742
4684
  ? (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseEpochTimestamp)((0, smithy_client_1.expectNumber)(output.ReplayStartTime)))
4743
4685
  : undefined,
4744
4686
  State: (0, smithy_client_1.expectString)(output.State),
@@ -4748,7 +4690,7 @@ const deserializeAws_json1_1Replay = (output, context) => {
4748
4690
  const deserializeAws_json1_1ReplayDestination = (output, context) => {
4749
4691
  return {
4750
4692
  Arn: (0, smithy_client_1.expectString)(output.Arn),
4751
- FilterArns: output.FilterArns !== undefined && output.FilterArns !== null
4693
+ FilterArns: output.FilterArns != null
4752
4694
  ? deserializeAws_json1_1ReplayDestinationFilters(output.FilterArns, context)
4753
4695
  : undefined,
4754
4696
  };
@@ -4828,7 +4770,7 @@ const deserializeAws_json1_1RuleResponseList = (output, context) => {
4828
4770
  };
4829
4771
  const deserializeAws_json1_1RunCommandParameters = (output, context) => {
4830
4772
  return {
4831
- RunCommandTargets: output.RunCommandTargets !== undefined && output.RunCommandTargets !== null
4773
+ RunCommandTargets: output.RunCommandTargets != null
4832
4774
  ? deserializeAws_json1_1RunCommandTargets(output.RunCommandTargets, context)
4833
4775
  : undefined,
4834
4776
  };
@@ -4836,9 +4778,7 @@ const deserializeAws_json1_1RunCommandParameters = (output, context) => {
4836
4778
  const deserializeAws_json1_1RunCommandTarget = (output, context) => {
4837
4779
  return {
4838
4780
  Key: (0, smithy_client_1.expectString)(output.Key),
4839
- Values: output.Values !== undefined && output.Values !== null
4840
- ? deserializeAws_json1_1RunCommandTargetValues(output.Values, context)
4841
- : undefined,
4781
+ Values: output.Values != null ? deserializeAws_json1_1RunCommandTargetValues(output.Values, context) : undefined,
4842
4782
  };
4843
4783
  };
4844
4784
  const deserializeAws_json1_1RunCommandTargets = (output, context) => {
@@ -4882,7 +4822,7 @@ const deserializeAws_json1_1SageMakerPipelineParameterList = (output, context) =
4882
4822
  };
4883
4823
  const deserializeAws_json1_1SageMakerPipelineParameters = (output, context) => {
4884
4824
  return {
4885
- PipelineParameterList: output.PipelineParameterList !== undefined && output.PipelineParameterList !== null
4825
+ PipelineParameterList: output.PipelineParameterList != null
4886
4826
  ? deserializeAws_json1_1SageMakerPipelineParameterList(output.PipelineParameterList, context)
4887
4827
  : undefined,
4888
4828
  };
@@ -4895,7 +4835,7 @@ const deserializeAws_json1_1SqsParameters = (output, context) => {
4895
4835
  const deserializeAws_json1_1StartReplayResponse = (output, context) => {
4896
4836
  return {
4897
4837
  ReplayArn: (0, smithy_client_1.expectString)(output.ReplayArn),
4898
- ReplayStartTime: output.ReplayStartTime !== undefined && output.ReplayStartTime !== null
4838
+ ReplayStartTime: output.ReplayStartTime != null
4899
4839
  ? (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseEpochTimestamp)((0, smithy_client_1.expectNumber)(output.ReplayStartTime)))
4900
4840
  : undefined,
4901
4841
  State: (0, smithy_client_1.expectString)(output.State),
@@ -4936,43 +4876,35 @@ const deserializeAws_json1_1TagResourceResponse = (output, context) => {
4936
4876
  const deserializeAws_json1_1Target = (output, context) => {
4937
4877
  return {
4938
4878
  Arn: (0, smithy_client_1.expectString)(output.Arn),
4939
- BatchParameters: output.BatchParameters !== undefined && output.BatchParameters !== null
4879
+ BatchParameters: output.BatchParameters != null
4940
4880
  ? deserializeAws_json1_1BatchParameters(output.BatchParameters, context)
4941
4881
  : undefined,
4942
- DeadLetterConfig: output.DeadLetterConfig !== undefined && output.DeadLetterConfig !== null
4882
+ DeadLetterConfig: output.DeadLetterConfig != null
4943
4883
  ? deserializeAws_json1_1DeadLetterConfig(output.DeadLetterConfig, context)
4944
4884
  : undefined,
4945
- EcsParameters: output.EcsParameters !== undefined && output.EcsParameters !== null
4946
- ? deserializeAws_json1_1EcsParameters(output.EcsParameters, context)
4947
- : undefined,
4948
- HttpParameters: output.HttpParameters !== undefined && output.HttpParameters !== null
4949
- ? deserializeAws_json1_1HttpParameters(output.HttpParameters, context)
4950
- : undefined,
4885
+ EcsParameters: output.EcsParameters != null ? deserializeAws_json1_1EcsParameters(output.EcsParameters, context) : undefined,
4886
+ HttpParameters: output.HttpParameters != null ? deserializeAws_json1_1HttpParameters(output.HttpParameters, context) : undefined,
4951
4887
  Id: (0, smithy_client_1.expectString)(output.Id),
4952
4888
  Input: (0, smithy_client_1.expectString)(output.Input),
4953
4889
  InputPath: (0, smithy_client_1.expectString)(output.InputPath),
4954
- InputTransformer: output.InputTransformer !== undefined && output.InputTransformer !== null
4890
+ InputTransformer: output.InputTransformer != null
4955
4891
  ? deserializeAws_json1_1InputTransformer(output.InputTransformer, context)
4956
4892
  : undefined,
4957
- KinesisParameters: output.KinesisParameters !== undefined && output.KinesisParameters !== null
4893
+ KinesisParameters: output.KinesisParameters != null
4958
4894
  ? deserializeAws_json1_1KinesisParameters(output.KinesisParameters, context)
4959
4895
  : undefined,
4960
- RedshiftDataParameters: output.RedshiftDataParameters !== undefined && output.RedshiftDataParameters !== null
4896
+ RedshiftDataParameters: output.RedshiftDataParameters != null
4961
4897
  ? deserializeAws_json1_1RedshiftDataParameters(output.RedshiftDataParameters, context)
4962
4898
  : undefined,
4963
- RetryPolicy: output.RetryPolicy !== undefined && output.RetryPolicy !== null
4964
- ? deserializeAws_json1_1RetryPolicy(output.RetryPolicy, context)
4965
- : undefined,
4899
+ RetryPolicy: output.RetryPolicy != null ? deserializeAws_json1_1RetryPolicy(output.RetryPolicy, context) : undefined,
4966
4900
  RoleArn: (0, smithy_client_1.expectString)(output.RoleArn),
4967
- RunCommandParameters: output.RunCommandParameters !== undefined && output.RunCommandParameters !== null
4901
+ RunCommandParameters: output.RunCommandParameters != null
4968
4902
  ? deserializeAws_json1_1RunCommandParameters(output.RunCommandParameters, context)
4969
4903
  : undefined,
4970
- SageMakerPipelineParameters: output.SageMakerPipelineParameters !== undefined && output.SageMakerPipelineParameters !== null
4904
+ SageMakerPipelineParameters: output.SageMakerPipelineParameters != null
4971
4905
  ? deserializeAws_json1_1SageMakerPipelineParameters(output.SageMakerPipelineParameters, context)
4972
4906
  : undefined,
4973
- SqsParameters: output.SqsParameters !== undefined && output.SqsParameters !== null
4974
- ? deserializeAws_json1_1SqsParameters(output.SqsParameters, context)
4975
- : undefined,
4907
+ SqsParameters: output.SqsParameters != null ? deserializeAws_json1_1SqsParameters(output.SqsParameters, context) : undefined,
4976
4908
  };
4977
4909
  };
4978
4910
  const deserializeAws_json1_1TargetList = (output, context) => {
@@ -5009,10 +4941,10 @@ const deserializeAws_json1_1UpdateApiDestinationResponse = (output, context) =>
5009
4941
  return {
5010
4942
  ApiDestinationArn: (0, smithy_client_1.expectString)(output.ApiDestinationArn),
5011
4943
  ApiDestinationState: (0, smithy_client_1.expectString)(output.ApiDestinationState),
5012
- CreationTime: output.CreationTime !== undefined && output.CreationTime !== null
4944
+ CreationTime: output.CreationTime != null
5013
4945
  ? (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseEpochTimestamp)((0, smithy_client_1.expectNumber)(output.CreationTime)))
5014
4946
  : undefined,
5015
- LastModifiedTime: output.LastModifiedTime !== undefined && output.LastModifiedTime !== null
4947
+ LastModifiedTime: output.LastModifiedTime != null
5016
4948
  ? (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseEpochTimestamp)((0, smithy_client_1.expectNumber)(output.LastModifiedTime)))
5017
4949
  : undefined,
5018
4950
  };
@@ -5020,7 +4952,7 @@ const deserializeAws_json1_1UpdateApiDestinationResponse = (output, context) =>
5020
4952
  const deserializeAws_json1_1UpdateArchiveResponse = (output, context) => {
5021
4953
  return {
5022
4954
  ArchiveArn: (0, smithy_client_1.expectString)(output.ArchiveArn),
5023
- CreationTime: output.CreationTime !== undefined && output.CreationTime !== null
4955
+ CreationTime: output.CreationTime != null
5024
4956
  ? (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseEpochTimestamp)((0, smithy_client_1.expectNumber)(output.CreationTime)))
5025
4957
  : undefined,
5026
4958
  State: (0, smithy_client_1.expectString)(output.State),
@@ -5031,13 +4963,13 @@ const deserializeAws_json1_1UpdateConnectionResponse = (output, context) => {
5031
4963
  return {
5032
4964
  ConnectionArn: (0, smithy_client_1.expectString)(output.ConnectionArn),
5033
4965
  ConnectionState: (0, smithy_client_1.expectString)(output.ConnectionState),
5034
- CreationTime: output.CreationTime !== undefined && output.CreationTime !== null
4966
+ CreationTime: output.CreationTime != null
5035
4967
  ? (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseEpochTimestamp)((0, smithy_client_1.expectNumber)(output.CreationTime)))
5036
4968
  : undefined,
5037
- LastAuthorizedTime: output.LastAuthorizedTime !== undefined && output.LastAuthorizedTime !== null
4969
+ LastAuthorizedTime: output.LastAuthorizedTime != null
5038
4970
  ? (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseEpochTimestamp)((0, smithy_client_1.expectNumber)(output.LastAuthorizedTime)))
5039
4971
  : undefined,
5040
- LastModifiedTime: output.LastModifiedTime !== undefined && output.LastModifiedTime !== null
4972
+ LastModifiedTime: output.LastModifiedTime != null
5041
4973
  ? (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseEpochTimestamp)((0, smithy_client_1.expectNumber)(output.LastModifiedTime)))
5042
4974
  : undefined,
5043
4975
  };
@@ -5104,5 +5036,4 @@ const loadRestJsonErrorCode = (output, data) => {
5104
5036
  if (data["__type"] !== undefined) {
5105
5037
  return sanitizeErrorCode(data["__type"]);
5106
5038
  }
5107
- return "";
5108
5039
  };