@aws-sdk/client-cloudwatch 3.201.0 → 3.202.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/CHANGELOG.md CHANGED
@@ -3,6 +3,17 @@
3
3
  All notable changes to this project will be documented in this file.
4
4
  See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
5
5
 
6
+ # [3.202.0](https://github.com/aws/aws-sdk-js-v3/compare/v3.201.0...v3.202.0) (2022-11-02)
7
+
8
+
9
+ ### Bug Fixes
10
+
11
+ * **codegen:** aws-query protocol, distinguish explicit empty list ([#4003](https://github.com/aws/aws-sdk-js-v3/issues/4003)) ([8e10769](https://github.com/aws/aws-sdk-js-v3/commit/8e10769b6146f93c0674686fa547290292714917))
12
+
13
+
14
+
15
+
16
+
6
17
  # [3.201.0](https://github.com/aws/aws-sdk-js-v3/compare/v3.200.0...v3.201.0) (2022-11-01)
7
18
 
8
19
 
@@ -2076,6 +2076,9 @@ const serializeAws_queryAnomalyDetectorConfiguration = (input, context) => {
2076
2076
  const entries = {};
2077
2077
  if (input.ExcludedTimeRanges != null) {
2078
2078
  const memberEntries = serializeAws_queryAnomalyDetectorExcludedTimeRanges(input.ExcludedTimeRanges, context);
2079
+ if (input.ExcludedTimeRanges?.length === 0) {
2080
+ entries.ExcludedTimeRanges = [];
2081
+ }
2079
2082
  Object.entries(memberEntries).forEach(([key, value]) => {
2080
2083
  const loc = `ExcludedTimeRanges.${key}`;
2081
2084
  entries[loc] = value;
@@ -2141,6 +2144,9 @@ const serializeAws_queryDeleteAlarmsInput = (input, context) => {
2141
2144
  const entries = {};
2142
2145
  if (input.AlarmNames != null) {
2143
2146
  const memberEntries = serializeAws_queryAlarmNames(input.AlarmNames, context);
2147
+ if (input.AlarmNames?.length === 0) {
2148
+ entries.AlarmNames = [];
2149
+ }
2144
2150
  Object.entries(memberEntries).forEach(([key, value]) => {
2145
2151
  const loc = `AlarmNames.${key}`;
2146
2152
  entries[loc] = value;
@@ -2158,6 +2164,9 @@ const serializeAws_queryDeleteAnomalyDetectorInput = (input, context) => {
2158
2164
  }
2159
2165
  if (input.Dimensions != null) {
2160
2166
  const memberEntries = serializeAws_queryDimensions(input.Dimensions, context);
2167
+ if (input.Dimensions?.length === 0) {
2168
+ entries.Dimensions = [];
2169
+ }
2161
2170
  Object.entries(memberEntries).forEach(([key, value]) => {
2162
2171
  const loc = `Dimensions.${key}`;
2163
2172
  entries[loc] = value;
@@ -2186,6 +2195,9 @@ const serializeAws_queryDeleteDashboardsInput = (input, context) => {
2186
2195
  const entries = {};
2187
2196
  if (input.DashboardNames != null) {
2188
2197
  const memberEntries = serializeAws_queryDashboardNames(input.DashboardNames, context);
2198
+ if (input.DashboardNames?.length === 0) {
2199
+ entries.DashboardNames = [];
2200
+ }
2189
2201
  Object.entries(memberEntries).forEach(([key, value]) => {
2190
2202
  const loc = `DashboardNames.${key}`;
2191
2203
  entries[loc] = value;
@@ -2197,6 +2209,9 @@ const serializeAws_queryDeleteInsightRulesInput = (input, context) => {
2197
2209
  const entries = {};
2198
2210
  if (input.RuleNames != null) {
2199
2211
  const memberEntries = serializeAws_queryInsightRuleNames(input.RuleNames, context);
2212
+ if (input.RuleNames?.length === 0) {
2213
+ entries.RuleNames = [];
2214
+ }
2200
2215
  Object.entries(memberEntries).forEach(([key, value]) => {
2201
2216
  const loc = `RuleNames.${key}`;
2202
2217
  entries[loc] = value;
@@ -2218,6 +2233,9 @@ const serializeAws_queryDescribeAlarmHistoryInput = (input, context) => {
2218
2233
  }
2219
2234
  if (input.AlarmTypes != null) {
2220
2235
  const memberEntries = serializeAws_queryAlarmTypes(input.AlarmTypes, context);
2236
+ if (input.AlarmTypes?.length === 0) {
2237
+ entries.AlarmTypes = [];
2238
+ }
2221
2239
  Object.entries(memberEntries).forEach(([key, value]) => {
2222
2240
  const loc = `AlarmTypes.${key}`;
2223
2241
  entries[loc] = value;
@@ -2259,6 +2277,9 @@ const serializeAws_queryDescribeAlarmsForMetricInput = (input, context) => {
2259
2277
  }
2260
2278
  if (input.Dimensions != null) {
2261
2279
  const memberEntries = serializeAws_queryDimensions(input.Dimensions, context);
2280
+ if (input.Dimensions?.length === 0) {
2281
+ entries.Dimensions = [];
2282
+ }
2262
2283
  Object.entries(memberEntries).forEach(([key, value]) => {
2263
2284
  const loc = `Dimensions.${key}`;
2264
2285
  entries[loc] = value;
@@ -2276,6 +2297,9 @@ const serializeAws_queryDescribeAlarmsInput = (input, context) => {
2276
2297
  const entries = {};
2277
2298
  if (input.AlarmNames != null) {
2278
2299
  const memberEntries = serializeAws_queryAlarmNames(input.AlarmNames, context);
2300
+ if (input.AlarmNames?.length === 0) {
2301
+ entries.AlarmNames = [];
2302
+ }
2279
2303
  Object.entries(memberEntries).forEach(([key, value]) => {
2280
2304
  const loc = `AlarmNames.${key}`;
2281
2305
  entries[loc] = value;
@@ -2286,6 +2310,9 @@ const serializeAws_queryDescribeAlarmsInput = (input, context) => {
2286
2310
  }
2287
2311
  if (input.AlarmTypes != null) {
2288
2312
  const memberEntries = serializeAws_queryAlarmTypes(input.AlarmTypes, context);
2313
+ if (input.AlarmTypes?.length === 0) {
2314
+ entries.AlarmTypes = [];
2315
+ }
2289
2316
  Object.entries(memberEntries).forEach(([key, value]) => {
2290
2317
  const loc = `AlarmTypes.${key}`;
2291
2318
  entries[loc] = value;
@@ -2327,6 +2354,9 @@ const serializeAws_queryDescribeAnomalyDetectorsInput = (input, context) => {
2327
2354
  }
2328
2355
  if (input.Dimensions != null) {
2329
2356
  const memberEntries = serializeAws_queryDimensions(input.Dimensions, context);
2357
+ if (input.Dimensions?.length === 0) {
2358
+ entries.Dimensions = [];
2359
+ }
2330
2360
  Object.entries(memberEntries).forEach(([key, value]) => {
2331
2361
  const loc = `Dimensions.${key}`;
2332
2362
  entries[loc] = value;
@@ -2334,6 +2364,9 @@ const serializeAws_queryDescribeAnomalyDetectorsInput = (input, context) => {
2334
2364
  }
2335
2365
  if (input.AnomalyDetectorTypes != null) {
2336
2366
  const memberEntries = serializeAws_queryAnomalyDetectorTypes(input.AnomalyDetectorTypes, context);
2367
+ if (input.AnomalyDetectorTypes?.length === 0) {
2368
+ entries.AnomalyDetectorTypes = [];
2369
+ }
2337
2370
  Object.entries(memberEntries).forEach(([key, value]) => {
2338
2371
  const loc = `AnomalyDetectorTypes.${key}`;
2339
2372
  entries[loc] = value;
@@ -2405,6 +2438,9 @@ const serializeAws_queryDisableAlarmActionsInput = (input, context) => {
2405
2438
  const entries = {};
2406
2439
  if (input.AlarmNames != null) {
2407
2440
  const memberEntries = serializeAws_queryAlarmNames(input.AlarmNames, context);
2441
+ if (input.AlarmNames?.length === 0) {
2442
+ entries.AlarmNames = [];
2443
+ }
2408
2444
  Object.entries(memberEntries).forEach(([key, value]) => {
2409
2445
  const loc = `AlarmNames.${key}`;
2410
2446
  entries[loc] = value;
@@ -2416,6 +2452,9 @@ const serializeAws_queryDisableInsightRulesInput = (input, context) => {
2416
2452
  const entries = {};
2417
2453
  if (input.RuleNames != null) {
2418
2454
  const memberEntries = serializeAws_queryInsightRuleNames(input.RuleNames, context);
2455
+ if (input.RuleNames?.length === 0) {
2456
+ entries.RuleNames = [];
2457
+ }
2419
2458
  Object.entries(memberEntries).forEach(([key, value]) => {
2420
2459
  const loc = `RuleNames.${key}`;
2421
2460
  entries[loc] = value;
@@ -2427,6 +2466,9 @@ const serializeAws_queryEnableAlarmActionsInput = (input, context) => {
2427
2466
  const entries = {};
2428
2467
  if (input.AlarmNames != null) {
2429
2468
  const memberEntries = serializeAws_queryAlarmNames(input.AlarmNames, context);
2469
+ if (input.AlarmNames?.length === 0) {
2470
+ entries.AlarmNames = [];
2471
+ }
2430
2472
  Object.entries(memberEntries).forEach(([key, value]) => {
2431
2473
  const loc = `AlarmNames.${key}`;
2432
2474
  entries[loc] = value;
@@ -2438,6 +2480,9 @@ const serializeAws_queryEnableInsightRulesInput = (input, context) => {
2438
2480
  const entries = {};
2439
2481
  if (input.RuleNames != null) {
2440
2482
  const memberEntries = serializeAws_queryInsightRuleNames(input.RuleNames, context);
2483
+ if (input.RuleNames?.length === 0) {
2484
+ entries.RuleNames = [];
2485
+ }
2441
2486
  Object.entries(memberEntries).forEach(([key, value]) => {
2442
2487
  const loc = `RuleNames.${key}`;
2443
2488
  entries[loc] = value;
@@ -2483,6 +2528,9 @@ const serializeAws_queryGetInsightRuleReportInput = (input, context) => {
2483
2528
  }
2484
2529
  if (input.Metrics != null) {
2485
2530
  const memberEntries = serializeAws_queryInsightRuleMetricList(input.Metrics, context);
2531
+ if (input.Metrics?.length === 0) {
2532
+ entries.Metrics = [];
2533
+ }
2486
2534
  Object.entries(memberEntries).forEach(([key, value]) => {
2487
2535
  const loc = `Metrics.${key}`;
2488
2536
  entries[loc] = value;
@@ -2497,6 +2545,9 @@ const serializeAws_queryGetMetricDataInput = (input, context) => {
2497
2545
  const entries = {};
2498
2546
  if (input.MetricDataQueries != null) {
2499
2547
  const memberEntries = serializeAws_queryMetricDataQueries(input.MetricDataQueries, context);
2548
+ if (input.MetricDataQueries?.length === 0) {
2549
+ entries.MetricDataQueries = [];
2550
+ }
2500
2551
  Object.entries(memberEntries).forEach(([key, value]) => {
2501
2552
  const loc = `MetricDataQueries.${key}`;
2502
2553
  entries[loc] = value;
@@ -2536,6 +2587,9 @@ const serializeAws_queryGetMetricStatisticsInput = (input, context) => {
2536
2587
  }
2537
2588
  if (input.Dimensions != null) {
2538
2589
  const memberEntries = serializeAws_queryDimensions(input.Dimensions, context);
2590
+ if (input.Dimensions?.length === 0) {
2591
+ entries.Dimensions = [];
2592
+ }
2539
2593
  Object.entries(memberEntries).forEach(([key, value]) => {
2540
2594
  const loc = `Dimensions.${key}`;
2541
2595
  entries[loc] = value;
@@ -2552,6 +2606,9 @@ const serializeAws_queryGetMetricStatisticsInput = (input, context) => {
2552
2606
  }
2553
2607
  if (input.Statistics != null) {
2554
2608
  const memberEntries = serializeAws_queryStatistics(input.Statistics, context);
2609
+ if (input.Statistics?.length === 0) {
2610
+ entries.Statistics = [];
2611
+ }
2555
2612
  Object.entries(memberEntries).forEach(([key, value]) => {
2556
2613
  const loc = `Statistics.${key}`;
2557
2614
  entries[loc] = value;
@@ -2559,6 +2616,9 @@ const serializeAws_queryGetMetricStatisticsInput = (input, context) => {
2559
2616
  }
2560
2617
  if (input.ExtendedStatistics != null) {
2561
2618
  const memberEntries = serializeAws_queryExtendedStatistics(input.ExtendedStatistics, context);
2619
+ if (input.ExtendedStatistics?.length === 0) {
2620
+ entries.ExtendedStatistics = [];
2621
+ }
2562
2622
  Object.entries(memberEntries).forEach(([key, value]) => {
2563
2623
  const loc = `ExtendedStatistics.${key}`;
2564
2624
  entries[loc] = value;
@@ -2650,6 +2710,9 @@ const serializeAws_queryListMetricsInput = (input, context) => {
2650
2710
  }
2651
2711
  if (input.Dimensions != null) {
2652
2712
  const memberEntries = serializeAws_queryDimensionFilters(input.Dimensions, context);
2713
+ if (input.Dimensions?.length === 0) {
2714
+ entries.Dimensions = [];
2715
+ }
2653
2716
  Object.entries(memberEntries).forEach(([key, value]) => {
2654
2717
  const loc = `Dimensions.${key}`;
2655
2718
  entries[loc] = value;
@@ -2690,6 +2753,9 @@ const serializeAws_queryManagedRule = (input, context) => {
2690
2753
  }
2691
2754
  if (input.Tags != null) {
2692
2755
  const memberEntries = serializeAws_queryTagList(input.Tags, context);
2756
+ if (input.Tags?.length === 0) {
2757
+ entries.Tags = [];
2758
+ }
2693
2759
  Object.entries(memberEntries).forEach(([key, value]) => {
2694
2760
  const loc = `Tags.${key}`;
2695
2761
  entries[loc] = value;
@@ -2722,6 +2788,9 @@ const serializeAws_queryMetric = (input, context) => {
2722
2788
  }
2723
2789
  if (input.Dimensions != null) {
2724
2790
  const memberEntries = serializeAws_queryDimensions(input.Dimensions, context);
2791
+ if (input.Dimensions?.length === 0) {
2792
+ entries.Dimensions = [];
2793
+ }
2725
2794
  Object.entries(memberEntries).forEach(([key, value]) => {
2726
2795
  const loc = `Dimensions.${key}`;
2727
2796
  entries[loc] = value;
@@ -2795,6 +2864,9 @@ const serializeAws_queryMetricDatum = (input, context) => {
2795
2864
  }
2796
2865
  if (input.Dimensions != null) {
2797
2866
  const memberEntries = serializeAws_queryDimensions(input.Dimensions, context);
2867
+ if (input.Dimensions?.length === 0) {
2868
+ entries.Dimensions = [];
2869
+ }
2798
2870
  Object.entries(memberEntries).forEach(([key, value]) => {
2799
2871
  const loc = `Dimensions.${key}`;
2800
2872
  entries[loc] = value;
@@ -2815,6 +2887,9 @@ const serializeAws_queryMetricDatum = (input, context) => {
2815
2887
  }
2816
2888
  if (input.Values != null) {
2817
2889
  const memberEntries = serializeAws_queryValues(input.Values, context);
2890
+ if (input.Values?.length === 0) {
2891
+ entries.Values = [];
2892
+ }
2818
2893
  Object.entries(memberEntries).forEach(([key, value]) => {
2819
2894
  const loc = `Values.${key}`;
2820
2895
  entries[loc] = value;
@@ -2822,6 +2897,9 @@ const serializeAws_queryMetricDatum = (input, context) => {
2822
2897
  }
2823
2898
  if (input.Counts != null) {
2824
2899
  const memberEntries = serializeAws_queryCounts(input.Counts, context);
2900
+ if (input.Counts?.length === 0) {
2901
+ entries.Counts = [];
2902
+ }
2825
2903
  Object.entries(memberEntries).forEach(([key, value]) => {
2826
2904
  const loc = `Counts.${key}`;
2827
2905
  entries[loc] = value;
@@ -2839,6 +2917,9 @@ const serializeAws_queryMetricMathAnomalyDetector = (input, context) => {
2839
2917
  const entries = {};
2840
2918
  if (input.MetricDataQueries != null) {
2841
2919
  const memberEntries = serializeAws_queryMetricDataQueries(input.MetricDataQueries, context);
2920
+ if (input.MetricDataQueries?.length === 0) {
2921
+ entries.MetricDataQueries = [];
2922
+ }
2842
2923
  Object.entries(memberEntries).forEach(([key, value]) => {
2843
2924
  const loc = `MetricDataQueries.${key}`;
2844
2925
  entries[loc] = value;
@@ -2916,6 +2997,9 @@ const serializeAws_queryMetricStreamStatisticsConfiguration = (input, context) =
2916
2997
  const entries = {};
2917
2998
  if (input.IncludeMetrics != null) {
2918
2999
  const memberEntries = serializeAws_queryMetricStreamStatisticsIncludeMetrics(input.IncludeMetrics, context);
3000
+ if (input.IncludeMetrics?.length === 0) {
3001
+ entries.IncludeMetrics = [];
3002
+ }
2919
3003
  Object.entries(memberEntries).forEach(([key, value]) => {
2920
3004
  const loc = `IncludeMetrics.${key}`;
2921
3005
  entries[loc] = value;
@@ -2923,6 +3007,9 @@ const serializeAws_queryMetricStreamStatisticsConfiguration = (input, context) =
2923
3007
  }
2924
3008
  if (input.AdditionalStatistics != null) {
2925
3009
  const memberEntries = serializeAws_queryMetricStreamStatisticsAdditionalStatistics(input.AdditionalStatistics, context);
3010
+ if (input.AdditionalStatistics?.length === 0) {
3011
+ entries.AdditionalStatistics = [];
3012
+ }
2926
3013
  Object.entries(memberEntries).forEach(([key, value]) => {
2927
3014
  const loc = `AdditionalStatistics.${key}`;
2928
3015
  entries[loc] = value;
@@ -2980,6 +3067,9 @@ const serializeAws_queryPutAnomalyDetectorInput = (input, context) => {
2980
3067
  }
2981
3068
  if (input.Dimensions != null) {
2982
3069
  const memberEntries = serializeAws_queryDimensions(input.Dimensions, context);
3070
+ if (input.Dimensions?.length === 0) {
3071
+ entries.Dimensions = [];
3072
+ }
2983
3073
  Object.entries(memberEntries).forEach(([key, value]) => {
2984
3074
  const loc = `Dimensions.${key}`;
2985
3075
  entries[loc] = value;
@@ -3018,6 +3108,9 @@ const serializeAws_queryPutCompositeAlarmInput = (input, context) => {
3018
3108
  }
3019
3109
  if (input.AlarmActions != null) {
3020
3110
  const memberEntries = serializeAws_queryResourceList(input.AlarmActions, context);
3111
+ if (input.AlarmActions?.length === 0) {
3112
+ entries.AlarmActions = [];
3113
+ }
3021
3114
  Object.entries(memberEntries).forEach(([key, value]) => {
3022
3115
  const loc = `AlarmActions.${key}`;
3023
3116
  entries[loc] = value;
@@ -3034,6 +3127,9 @@ const serializeAws_queryPutCompositeAlarmInput = (input, context) => {
3034
3127
  }
3035
3128
  if (input.InsufficientDataActions != null) {
3036
3129
  const memberEntries = serializeAws_queryResourceList(input.InsufficientDataActions, context);
3130
+ if (input.InsufficientDataActions?.length === 0) {
3131
+ entries.InsufficientDataActions = [];
3132
+ }
3037
3133
  Object.entries(memberEntries).forEach(([key, value]) => {
3038
3134
  const loc = `InsufficientDataActions.${key}`;
3039
3135
  entries[loc] = value;
@@ -3041,6 +3137,9 @@ const serializeAws_queryPutCompositeAlarmInput = (input, context) => {
3041
3137
  }
3042
3138
  if (input.OKActions != null) {
3043
3139
  const memberEntries = serializeAws_queryResourceList(input.OKActions, context);
3140
+ if (input.OKActions?.length === 0) {
3141
+ entries.OKActions = [];
3142
+ }
3044
3143
  Object.entries(memberEntries).forEach(([key, value]) => {
3045
3144
  const loc = `OKActions.${key}`;
3046
3145
  entries[loc] = value;
@@ -3048,6 +3147,9 @@ const serializeAws_queryPutCompositeAlarmInput = (input, context) => {
3048
3147
  }
3049
3148
  if (input.Tags != null) {
3050
3149
  const memberEntries = serializeAws_queryTagList(input.Tags, context);
3150
+ if (input.Tags?.length === 0) {
3151
+ entries.Tags = [];
3152
+ }
3051
3153
  Object.entries(memberEntries).forEach(([key, value]) => {
3052
3154
  const loc = `Tags.${key}`;
3053
3155
  entries[loc] = value;
@@ -3087,6 +3189,9 @@ const serializeAws_queryPutInsightRuleInput = (input, context) => {
3087
3189
  }
3088
3190
  if (input.Tags != null) {
3089
3191
  const memberEntries = serializeAws_queryTagList(input.Tags, context);
3192
+ if (input.Tags?.length === 0) {
3193
+ entries.Tags = [];
3194
+ }
3090
3195
  Object.entries(memberEntries).forEach(([key, value]) => {
3091
3196
  const loc = `Tags.${key}`;
3092
3197
  entries[loc] = value;
@@ -3098,6 +3203,9 @@ const serializeAws_queryPutManagedInsightRulesInput = (input, context) => {
3098
3203
  const entries = {};
3099
3204
  if (input.ManagedRules != null) {
3100
3205
  const memberEntries = serializeAws_queryManagedRules(input.ManagedRules, context);
3206
+ if (input.ManagedRules?.length === 0) {
3207
+ entries.ManagedRules = [];
3208
+ }
3101
3209
  Object.entries(memberEntries).forEach(([key, value]) => {
3102
3210
  const loc = `ManagedRules.${key}`;
3103
3211
  entries[loc] = value;
@@ -3118,6 +3226,9 @@ const serializeAws_queryPutMetricAlarmInput = (input, context) => {
3118
3226
  }
3119
3227
  if (input.OKActions != null) {
3120
3228
  const memberEntries = serializeAws_queryResourceList(input.OKActions, context);
3229
+ if (input.OKActions?.length === 0) {
3230
+ entries.OKActions = [];
3231
+ }
3121
3232
  Object.entries(memberEntries).forEach(([key, value]) => {
3122
3233
  const loc = `OKActions.${key}`;
3123
3234
  entries[loc] = value;
@@ -3125,6 +3236,9 @@ const serializeAws_queryPutMetricAlarmInput = (input, context) => {
3125
3236
  }
3126
3237
  if (input.AlarmActions != null) {
3127
3238
  const memberEntries = serializeAws_queryResourceList(input.AlarmActions, context);
3239
+ if (input.AlarmActions?.length === 0) {
3240
+ entries.AlarmActions = [];
3241
+ }
3128
3242
  Object.entries(memberEntries).forEach(([key, value]) => {
3129
3243
  const loc = `AlarmActions.${key}`;
3130
3244
  entries[loc] = value;
@@ -3132,6 +3246,9 @@ const serializeAws_queryPutMetricAlarmInput = (input, context) => {
3132
3246
  }
3133
3247
  if (input.InsufficientDataActions != null) {
3134
3248
  const memberEntries = serializeAws_queryResourceList(input.InsufficientDataActions, context);
3249
+ if (input.InsufficientDataActions?.length === 0) {
3250
+ entries.InsufficientDataActions = [];
3251
+ }
3135
3252
  Object.entries(memberEntries).forEach(([key, value]) => {
3136
3253
  const loc = `InsufficientDataActions.${key}`;
3137
3254
  entries[loc] = value;
@@ -3151,6 +3268,9 @@ const serializeAws_queryPutMetricAlarmInput = (input, context) => {
3151
3268
  }
3152
3269
  if (input.Dimensions != null) {
3153
3270
  const memberEntries = serializeAws_queryDimensions(input.Dimensions, context);
3271
+ if (input.Dimensions?.length === 0) {
3272
+ entries.Dimensions = [];
3273
+ }
3154
3274
  Object.entries(memberEntries).forEach(([key, value]) => {
3155
3275
  const loc = `Dimensions.${key}`;
3156
3276
  entries[loc] = value;
@@ -3182,6 +3302,9 @@ const serializeAws_queryPutMetricAlarmInput = (input, context) => {
3182
3302
  }
3183
3303
  if (input.Metrics != null) {
3184
3304
  const memberEntries = serializeAws_queryMetricDataQueries(input.Metrics, context);
3305
+ if (input.Metrics?.length === 0) {
3306
+ entries.Metrics = [];
3307
+ }
3185
3308
  Object.entries(memberEntries).forEach(([key, value]) => {
3186
3309
  const loc = `Metrics.${key}`;
3187
3310
  entries[loc] = value;
@@ -3189,6 +3312,9 @@ const serializeAws_queryPutMetricAlarmInput = (input, context) => {
3189
3312
  }
3190
3313
  if (input.Tags != null) {
3191
3314
  const memberEntries = serializeAws_queryTagList(input.Tags, context);
3315
+ if (input.Tags?.length === 0) {
3316
+ entries.Tags = [];
3317
+ }
3192
3318
  Object.entries(memberEntries).forEach(([key, value]) => {
3193
3319
  const loc = `Tags.${key}`;
3194
3320
  entries[loc] = value;
@@ -3206,6 +3332,9 @@ const serializeAws_queryPutMetricDataInput = (input, context) => {
3206
3332
  }
3207
3333
  if (input.MetricData != null) {
3208
3334
  const memberEntries = serializeAws_queryMetricData(input.MetricData, context);
3335
+ if (input.MetricData?.length === 0) {
3336
+ entries.MetricData = [];
3337
+ }
3209
3338
  Object.entries(memberEntries).forEach(([key, value]) => {
3210
3339
  const loc = `MetricData.${key}`;
3211
3340
  entries[loc] = value;
@@ -3220,6 +3349,9 @@ const serializeAws_queryPutMetricStreamInput = (input, context) => {
3220
3349
  }
3221
3350
  if (input.IncludeFilters != null) {
3222
3351
  const memberEntries = serializeAws_queryMetricStreamFilters(input.IncludeFilters, context);
3352
+ if (input.IncludeFilters?.length === 0) {
3353
+ entries.IncludeFilters = [];
3354
+ }
3223
3355
  Object.entries(memberEntries).forEach(([key, value]) => {
3224
3356
  const loc = `IncludeFilters.${key}`;
3225
3357
  entries[loc] = value;
@@ -3227,6 +3359,9 @@ const serializeAws_queryPutMetricStreamInput = (input, context) => {
3227
3359
  }
3228
3360
  if (input.ExcludeFilters != null) {
3229
3361
  const memberEntries = serializeAws_queryMetricStreamFilters(input.ExcludeFilters, context);
3362
+ if (input.ExcludeFilters?.length === 0) {
3363
+ entries.ExcludeFilters = [];
3364
+ }
3230
3365
  Object.entries(memberEntries).forEach(([key, value]) => {
3231
3366
  const loc = `ExcludeFilters.${key}`;
3232
3367
  entries[loc] = value;
@@ -3243,6 +3378,9 @@ const serializeAws_queryPutMetricStreamInput = (input, context) => {
3243
3378
  }
3244
3379
  if (input.Tags != null) {
3245
3380
  const memberEntries = serializeAws_queryTagList(input.Tags, context);
3381
+ if (input.Tags?.length === 0) {
3382
+ entries.Tags = [];
3383
+ }
3246
3384
  Object.entries(memberEntries).forEach(([key, value]) => {
3247
3385
  const loc = `Tags.${key}`;
3248
3386
  entries[loc] = value;
@@ -3250,6 +3388,9 @@ const serializeAws_queryPutMetricStreamInput = (input, context) => {
3250
3388
  }
3251
3389
  if (input.StatisticsConfigurations != null) {
3252
3390
  const memberEntries = serializeAws_queryMetricStreamStatisticsConfigurations(input.StatisticsConfigurations, context);
3391
+ if (input.StatisticsConfigurations?.length === 0) {
3392
+ entries.StatisticsConfigurations = [];
3393
+ }
3253
3394
  Object.entries(memberEntries).forEach(([key, value]) => {
3254
3395
  const loc = `StatisticsConfigurations.${key}`;
3255
3396
  entries[loc] = value;
@@ -3305,6 +3446,9 @@ const serializeAws_querySingleMetricAnomalyDetector = (input, context) => {
3305
3446
  }
3306
3447
  if (input.Dimensions != null) {
3307
3448
  const memberEntries = serializeAws_queryDimensions(input.Dimensions, context);
3449
+ if (input.Dimensions?.length === 0) {
3450
+ entries.Dimensions = [];
3451
+ }
3308
3452
  Object.entries(memberEntries).forEach(([key, value]) => {
3309
3453
  const loc = `Dimensions.${key}`;
3310
3454
  entries[loc] = value;
@@ -3319,6 +3463,9 @@ const serializeAws_queryStartMetricStreamsInput = (input, context) => {
3319
3463
  const entries = {};
3320
3464
  if (input.Names != null) {
3321
3465
  const memberEntries = serializeAws_queryMetricStreamNames(input.Names, context);
3466
+ if (input.Names?.length === 0) {
3467
+ entries.Names = [];
3468
+ }
3322
3469
  Object.entries(memberEntries).forEach(([key, value]) => {
3323
3470
  const loc = `Names.${key}`;
3324
3471
  entries[loc] = value;
@@ -3358,6 +3505,9 @@ const serializeAws_queryStopMetricStreamsInput = (input, context) => {
3358
3505
  const entries = {};
3359
3506
  if (input.Names != null) {
3360
3507
  const memberEntries = serializeAws_queryMetricStreamNames(input.Names, context);
3508
+ if (input.Names?.length === 0) {
3509
+ entries.Names = [];
3510
+ }
3361
3511
  Object.entries(memberEntries).forEach(([key, value]) => {
3362
3512
  const loc = `Names.${key}`;
3363
3513
  entries[loc] = value;
@@ -3409,6 +3559,9 @@ const serializeAws_queryTagResourceInput = (input, context) => {
3409
3559
  }
3410
3560
  if (input.Tags != null) {
3411
3561
  const memberEntries = serializeAws_queryTagList(input.Tags, context);
3562
+ if (input.Tags?.length === 0) {
3563
+ entries.Tags = [];
3564
+ }
3412
3565
  Object.entries(memberEntries).forEach(([key, value]) => {
3413
3566
  const loc = `Tags.${key}`;
3414
3567
  entries[loc] = value;
@@ -3423,6 +3576,9 @@ const serializeAws_queryUntagResourceInput = (input, context) => {
3423
3576
  }
3424
3577
  if (input.TagKeys != null) {
3425
3578
  const memberEntries = serializeAws_queryTagKeyList(input.TagKeys, context);
3579
+ if (input.TagKeys?.length === 0) {
3580
+ entries.TagKeys = [];
3581
+ }
3426
3582
  Object.entries(memberEntries).forEach(([key, value]) => {
3427
3583
  const loc = `TagKeys.${key}`;
3428
3584
  entries[loc] = value;
@@ -1996,6 +1996,9 @@ const serializeAws_queryAnomalyDetectorConfiguration = (input, context) => {
1996
1996
  const entries = {};
1997
1997
  if (input.ExcludedTimeRanges != null) {
1998
1998
  const memberEntries = serializeAws_queryAnomalyDetectorExcludedTimeRanges(input.ExcludedTimeRanges, context);
1999
+ if (input.ExcludedTimeRanges?.length === 0) {
2000
+ entries.ExcludedTimeRanges = [];
2001
+ }
1999
2002
  Object.entries(memberEntries).forEach(([key, value]) => {
2000
2003
  const loc = `ExcludedTimeRanges.${key}`;
2001
2004
  entries[loc] = value;
@@ -2061,6 +2064,9 @@ const serializeAws_queryDeleteAlarmsInput = (input, context) => {
2061
2064
  const entries = {};
2062
2065
  if (input.AlarmNames != null) {
2063
2066
  const memberEntries = serializeAws_queryAlarmNames(input.AlarmNames, context);
2067
+ if (input.AlarmNames?.length === 0) {
2068
+ entries.AlarmNames = [];
2069
+ }
2064
2070
  Object.entries(memberEntries).forEach(([key, value]) => {
2065
2071
  const loc = `AlarmNames.${key}`;
2066
2072
  entries[loc] = value;
@@ -2078,6 +2084,9 @@ const serializeAws_queryDeleteAnomalyDetectorInput = (input, context) => {
2078
2084
  }
2079
2085
  if (input.Dimensions != null) {
2080
2086
  const memberEntries = serializeAws_queryDimensions(input.Dimensions, context);
2087
+ if (input.Dimensions?.length === 0) {
2088
+ entries.Dimensions = [];
2089
+ }
2081
2090
  Object.entries(memberEntries).forEach(([key, value]) => {
2082
2091
  const loc = `Dimensions.${key}`;
2083
2092
  entries[loc] = value;
@@ -2106,6 +2115,9 @@ const serializeAws_queryDeleteDashboardsInput = (input, context) => {
2106
2115
  const entries = {};
2107
2116
  if (input.DashboardNames != null) {
2108
2117
  const memberEntries = serializeAws_queryDashboardNames(input.DashboardNames, context);
2118
+ if (input.DashboardNames?.length === 0) {
2119
+ entries.DashboardNames = [];
2120
+ }
2109
2121
  Object.entries(memberEntries).forEach(([key, value]) => {
2110
2122
  const loc = `DashboardNames.${key}`;
2111
2123
  entries[loc] = value;
@@ -2117,6 +2129,9 @@ const serializeAws_queryDeleteInsightRulesInput = (input, context) => {
2117
2129
  const entries = {};
2118
2130
  if (input.RuleNames != null) {
2119
2131
  const memberEntries = serializeAws_queryInsightRuleNames(input.RuleNames, context);
2132
+ if (input.RuleNames?.length === 0) {
2133
+ entries.RuleNames = [];
2134
+ }
2120
2135
  Object.entries(memberEntries).forEach(([key, value]) => {
2121
2136
  const loc = `RuleNames.${key}`;
2122
2137
  entries[loc] = value;
@@ -2138,6 +2153,9 @@ const serializeAws_queryDescribeAlarmHistoryInput = (input, context) => {
2138
2153
  }
2139
2154
  if (input.AlarmTypes != null) {
2140
2155
  const memberEntries = serializeAws_queryAlarmTypes(input.AlarmTypes, context);
2156
+ if (input.AlarmTypes?.length === 0) {
2157
+ entries.AlarmTypes = [];
2158
+ }
2141
2159
  Object.entries(memberEntries).forEach(([key, value]) => {
2142
2160
  const loc = `AlarmTypes.${key}`;
2143
2161
  entries[loc] = value;
@@ -2179,6 +2197,9 @@ const serializeAws_queryDescribeAlarmsForMetricInput = (input, context) => {
2179
2197
  }
2180
2198
  if (input.Dimensions != null) {
2181
2199
  const memberEntries = serializeAws_queryDimensions(input.Dimensions, context);
2200
+ if (input.Dimensions?.length === 0) {
2201
+ entries.Dimensions = [];
2202
+ }
2182
2203
  Object.entries(memberEntries).forEach(([key, value]) => {
2183
2204
  const loc = `Dimensions.${key}`;
2184
2205
  entries[loc] = value;
@@ -2196,6 +2217,9 @@ const serializeAws_queryDescribeAlarmsInput = (input, context) => {
2196
2217
  const entries = {};
2197
2218
  if (input.AlarmNames != null) {
2198
2219
  const memberEntries = serializeAws_queryAlarmNames(input.AlarmNames, context);
2220
+ if (input.AlarmNames?.length === 0) {
2221
+ entries.AlarmNames = [];
2222
+ }
2199
2223
  Object.entries(memberEntries).forEach(([key, value]) => {
2200
2224
  const loc = `AlarmNames.${key}`;
2201
2225
  entries[loc] = value;
@@ -2206,6 +2230,9 @@ const serializeAws_queryDescribeAlarmsInput = (input, context) => {
2206
2230
  }
2207
2231
  if (input.AlarmTypes != null) {
2208
2232
  const memberEntries = serializeAws_queryAlarmTypes(input.AlarmTypes, context);
2233
+ if (input.AlarmTypes?.length === 0) {
2234
+ entries.AlarmTypes = [];
2235
+ }
2209
2236
  Object.entries(memberEntries).forEach(([key, value]) => {
2210
2237
  const loc = `AlarmTypes.${key}`;
2211
2238
  entries[loc] = value;
@@ -2247,6 +2274,9 @@ const serializeAws_queryDescribeAnomalyDetectorsInput = (input, context) => {
2247
2274
  }
2248
2275
  if (input.Dimensions != null) {
2249
2276
  const memberEntries = serializeAws_queryDimensions(input.Dimensions, context);
2277
+ if (input.Dimensions?.length === 0) {
2278
+ entries.Dimensions = [];
2279
+ }
2250
2280
  Object.entries(memberEntries).forEach(([key, value]) => {
2251
2281
  const loc = `Dimensions.${key}`;
2252
2282
  entries[loc] = value;
@@ -2254,6 +2284,9 @@ const serializeAws_queryDescribeAnomalyDetectorsInput = (input, context) => {
2254
2284
  }
2255
2285
  if (input.AnomalyDetectorTypes != null) {
2256
2286
  const memberEntries = serializeAws_queryAnomalyDetectorTypes(input.AnomalyDetectorTypes, context);
2287
+ if (input.AnomalyDetectorTypes?.length === 0) {
2288
+ entries.AnomalyDetectorTypes = [];
2289
+ }
2257
2290
  Object.entries(memberEntries).forEach(([key, value]) => {
2258
2291
  const loc = `AnomalyDetectorTypes.${key}`;
2259
2292
  entries[loc] = value;
@@ -2325,6 +2358,9 @@ const serializeAws_queryDisableAlarmActionsInput = (input, context) => {
2325
2358
  const entries = {};
2326
2359
  if (input.AlarmNames != null) {
2327
2360
  const memberEntries = serializeAws_queryAlarmNames(input.AlarmNames, context);
2361
+ if (input.AlarmNames?.length === 0) {
2362
+ entries.AlarmNames = [];
2363
+ }
2328
2364
  Object.entries(memberEntries).forEach(([key, value]) => {
2329
2365
  const loc = `AlarmNames.${key}`;
2330
2366
  entries[loc] = value;
@@ -2336,6 +2372,9 @@ const serializeAws_queryDisableInsightRulesInput = (input, context) => {
2336
2372
  const entries = {};
2337
2373
  if (input.RuleNames != null) {
2338
2374
  const memberEntries = serializeAws_queryInsightRuleNames(input.RuleNames, context);
2375
+ if (input.RuleNames?.length === 0) {
2376
+ entries.RuleNames = [];
2377
+ }
2339
2378
  Object.entries(memberEntries).forEach(([key, value]) => {
2340
2379
  const loc = `RuleNames.${key}`;
2341
2380
  entries[loc] = value;
@@ -2347,6 +2386,9 @@ const serializeAws_queryEnableAlarmActionsInput = (input, context) => {
2347
2386
  const entries = {};
2348
2387
  if (input.AlarmNames != null) {
2349
2388
  const memberEntries = serializeAws_queryAlarmNames(input.AlarmNames, context);
2389
+ if (input.AlarmNames?.length === 0) {
2390
+ entries.AlarmNames = [];
2391
+ }
2350
2392
  Object.entries(memberEntries).forEach(([key, value]) => {
2351
2393
  const loc = `AlarmNames.${key}`;
2352
2394
  entries[loc] = value;
@@ -2358,6 +2400,9 @@ const serializeAws_queryEnableInsightRulesInput = (input, context) => {
2358
2400
  const entries = {};
2359
2401
  if (input.RuleNames != null) {
2360
2402
  const memberEntries = serializeAws_queryInsightRuleNames(input.RuleNames, context);
2403
+ if (input.RuleNames?.length === 0) {
2404
+ entries.RuleNames = [];
2405
+ }
2361
2406
  Object.entries(memberEntries).forEach(([key, value]) => {
2362
2407
  const loc = `RuleNames.${key}`;
2363
2408
  entries[loc] = value;
@@ -2403,6 +2448,9 @@ const serializeAws_queryGetInsightRuleReportInput = (input, context) => {
2403
2448
  }
2404
2449
  if (input.Metrics != null) {
2405
2450
  const memberEntries = serializeAws_queryInsightRuleMetricList(input.Metrics, context);
2451
+ if (input.Metrics?.length === 0) {
2452
+ entries.Metrics = [];
2453
+ }
2406
2454
  Object.entries(memberEntries).forEach(([key, value]) => {
2407
2455
  const loc = `Metrics.${key}`;
2408
2456
  entries[loc] = value;
@@ -2417,6 +2465,9 @@ const serializeAws_queryGetMetricDataInput = (input, context) => {
2417
2465
  const entries = {};
2418
2466
  if (input.MetricDataQueries != null) {
2419
2467
  const memberEntries = serializeAws_queryMetricDataQueries(input.MetricDataQueries, context);
2468
+ if (input.MetricDataQueries?.length === 0) {
2469
+ entries.MetricDataQueries = [];
2470
+ }
2420
2471
  Object.entries(memberEntries).forEach(([key, value]) => {
2421
2472
  const loc = `MetricDataQueries.${key}`;
2422
2473
  entries[loc] = value;
@@ -2456,6 +2507,9 @@ const serializeAws_queryGetMetricStatisticsInput = (input, context) => {
2456
2507
  }
2457
2508
  if (input.Dimensions != null) {
2458
2509
  const memberEntries = serializeAws_queryDimensions(input.Dimensions, context);
2510
+ if (input.Dimensions?.length === 0) {
2511
+ entries.Dimensions = [];
2512
+ }
2459
2513
  Object.entries(memberEntries).forEach(([key, value]) => {
2460
2514
  const loc = `Dimensions.${key}`;
2461
2515
  entries[loc] = value;
@@ -2472,6 +2526,9 @@ const serializeAws_queryGetMetricStatisticsInput = (input, context) => {
2472
2526
  }
2473
2527
  if (input.Statistics != null) {
2474
2528
  const memberEntries = serializeAws_queryStatistics(input.Statistics, context);
2529
+ if (input.Statistics?.length === 0) {
2530
+ entries.Statistics = [];
2531
+ }
2475
2532
  Object.entries(memberEntries).forEach(([key, value]) => {
2476
2533
  const loc = `Statistics.${key}`;
2477
2534
  entries[loc] = value;
@@ -2479,6 +2536,9 @@ const serializeAws_queryGetMetricStatisticsInput = (input, context) => {
2479
2536
  }
2480
2537
  if (input.ExtendedStatistics != null) {
2481
2538
  const memberEntries = serializeAws_queryExtendedStatistics(input.ExtendedStatistics, context);
2539
+ if (input.ExtendedStatistics?.length === 0) {
2540
+ entries.ExtendedStatistics = [];
2541
+ }
2482
2542
  Object.entries(memberEntries).forEach(([key, value]) => {
2483
2543
  const loc = `ExtendedStatistics.${key}`;
2484
2544
  entries[loc] = value;
@@ -2570,6 +2630,9 @@ const serializeAws_queryListMetricsInput = (input, context) => {
2570
2630
  }
2571
2631
  if (input.Dimensions != null) {
2572
2632
  const memberEntries = serializeAws_queryDimensionFilters(input.Dimensions, context);
2633
+ if (input.Dimensions?.length === 0) {
2634
+ entries.Dimensions = [];
2635
+ }
2573
2636
  Object.entries(memberEntries).forEach(([key, value]) => {
2574
2637
  const loc = `Dimensions.${key}`;
2575
2638
  entries[loc] = value;
@@ -2610,6 +2673,9 @@ const serializeAws_queryManagedRule = (input, context) => {
2610
2673
  }
2611
2674
  if (input.Tags != null) {
2612
2675
  const memberEntries = serializeAws_queryTagList(input.Tags, context);
2676
+ if (input.Tags?.length === 0) {
2677
+ entries.Tags = [];
2678
+ }
2613
2679
  Object.entries(memberEntries).forEach(([key, value]) => {
2614
2680
  const loc = `Tags.${key}`;
2615
2681
  entries[loc] = value;
@@ -2642,6 +2708,9 @@ const serializeAws_queryMetric = (input, context) => {
2642
2708
  }
2643
2709
  if (input.Dimensions != null) {
2644
2710
  const memberEntries = serializeAws_queryDimensions(input.Dimensions, context);
2711
+ if (input.Dimensions?.length === 0) {
2712
+ entries.Dimensions = [];
2713
+ }
2645
2714
  Object.entries(memberEntries).forEach(([key, value]) => {
2646
2715
  const loc = `Dimensions.${key}`;
2647
2716
  entries[loc] = value;
@@ -2715,6 +2784,9 @@ const serializeAws_queryMetricDatum = (input, context) => {
2715
2784
  }
2716
2785
  if (input.Dimensions != null) {
2717
2786
  const memberEntries = serializeAws_queryDimensions(input.Dimensions, context);
2787
+ if (input.Dimensions?.length === 0) {
2788
+ entries.Dimensions = [];
2789
+ }
2718
2790
  Object.entries(memberEntries).forEach(([key, value]) => {
2719
2791
  const loc = `Dimensions.${key}`;
2720
2792
  entries[loc] = value;
@@ -2735,6 +2807,9 @@ const serializeAws_queryMetricDatum = (input, context) => {
2735
2807
  }
2736
2808
  if (input.Values != null) {
2737
2809
  const memberEntries = serializeAws_queryValues(input.Values, context);
2810
+ if (input.Values?.length === 0) {
2811
+ entries.Values = [];
2812
+ }
2738
2813
  Object.entries(memberEntries).forEach(([key, value]) => {
2739
2814
  const loc = `Values.${key}`;
2740
2815
  entries[loc] = value;
@@ -2742,6 +2817,9 @@ const serializeAws_queryMetricDatum = (input, context) => {
2742
2817
  }
2743
2818
  if (input.Counts != null) {
2744
2819
  const memberEntries = serializeAws_queryCounts(input.Counts, context);
2820
+ if (input.Counts?.length === 0) {
2821
+ entries.Counts = [];
2822
+ }
2745
2823
  Object.entries(memberEntries).forEach(([key, value]) => {
2746
2824
  const loc = `Counts.${key}`;
2747
2825
  entries[loc] = value;
@@ -2759,6 +2837,9 @@ const serializeAws_queryMetricMathAnomalyDetector = (input, context) => {
2759
2837
  const entries = {};
2760
2838
  if (input.MetricDataQueries != null) {
2761
2839
  const memberEntries = serializeAws_queryMetricDataQueries(input.MetricDataQueries, context);
2840
+ if (input.MetricDataQueries?.length === 0) {
2841
+ entries.MetricDataQueries = [];
2842
+ }
2762
2843
  Object.entries(memberEntries).forEach(([key, value]) => {
2763
2844
  const loc = `MetricDataQueries.${key}`;
2764
2845
  entries[loc] = value;
@@ -2836,6 +2917,9 @@ const serializeAws_queryMetricStreamStatisticsConfiguration = (input, context) =
2836
2917
  const entries = {};
2837
2918
  if (input.IncludeMetrics != null) {
2838
2919
  const memberEntries = serializeAws_queryMetricStreamStatisticsIncludeMetrics(input.IncludeMetrics, context);
2920
+ if (input.IncludeMetrics?.length === 0) {
2921
+ entries.IncludeMetrics = [];
2922
+ }
2839
2923
  Object.entries(memberEntries).forEach(([key, value]) => {
2840
2924
  const loc = `IncludeMetrics.${key}`;
2841
2925
  entries[loc] = value;
@@ -2843,6 +2927,9 @@ const serializeAws_queryMetricStreamStatisticsConfiguration = (input, context) =
2843
2927
  }
2844
2928
  if (input.AdditionalStatistics != null) {
2845
2929
  const memberEntries = serializeAws_queryMetricStreamStatisticsAdditionalStatistics(input.AdditionalStatistics, context);
2930
+ if (input.AdditionalStatistics?.length === 0) {
2931
+ entries.AdditionalStatistics = [];
2932
+ }
2846
2933
  Object.entries(memberEntries).forEach(([key, value]) => {
2847
2934
  const loc = `AdditionalStatistics.${key}`;
2848
2935
  entries[loc] = value;
@@ -2900,6 +2987,9 @@ const serializeAws_queryPutAnomalyDetectorInput = (input, context) => {
2900
2987
  }
2901
2988
  if (input.Dimensions != null) {
2902
2989
  const memberEntries = serializeAws_queryDimensions(input.Dimensions, context);
2990
+ if (input.Dimensions?.length === 0) {
2991
+ entries.Dimensions = [];
2992
+ }
2903
2993
  Object.entries(memberEntries).forEach(([key, value]) => {
2904
2994
  const loc = `Dimensions.${key}`;
2905
2995
  entries[loc] = value;
@@ -2938,6 +3028,9 @@ const serializeAws_queryPutCompositeAlarmInput = (input, context) => {
2938
3028
  }
2939
3029
  if (input.AlarmActions != null) {
2940
3030
  const memberEntries = serializeAws_queryResourceList(input.AlarmActions, context);
3031
+ if (input.AlarmActions?.length === 0) {
3032
+ entries.AlarmActions = [];
3033
+ }
2941
3034
  Object.entries(memberEntries).forEach(([key, value]) => {
2942
3035
  const loc = `AlarmActions.${key}`;
2943
3036
  entries[loc] = value;
@@ -2954,6 +3047,9 @@ const serializeAws_queryPutCompositeAlarmInput = (input, context) => {
2954
3047
  }
2955
3048
  if (input.InsufficientDataActions != null) {
2956
3049
  const memberEntries = serializeAws_queryResourceList(input.InsufficientDataActions, context);
3050
+ if (input.InsufficientDataActions?.length === 0) {
3051
+ entries.InsufficientDataActions = [];
3052
+ }
2957
3053
  Object.entries(memberEntries).forEach(([key, value]) => {
2958
3054
  const loc = `InsufficientDataActions.${key}`;
2959
3055
  entries[loc] = value;
@@ -2961,6 +3057,9 @@ const serializeAws_queryPutCompositeAlarmInput = (input, context) => {
2961
3057
  }
2962
3058
  if (input.OKActions != null) {
2963
3059
  const memberEntries = serializeAws_queryResourceList(input.OKActions, context);
3060
+ if (input.OKActions?.length === 0) {
3061
+ entries.OKActions = [];
3062
+ }
2964
3063
  Object.entries(memberEntries).forEach(([key, value]) => {
2965
3064
  const loc = `OKActions.${key}`;
2966
3065
  entries[loc] = value;
@@ -2968,6 +3067,9 @@ const serializeAws_queryPutCompositeAlarmInput = (input, context) => {
2968
3067
  }
2969
3068
  if (input.Tags != null) {
2970
3069
  const memberEntries = serializeAws_queryTagList(input.Tags, context);
3070
+ if (input.Tags?.length === 0) {
3071
+ entries.Tags = [];
3072
+ }
2971
3073
  Object.entries(memberEntries).forEach(([key, value]) => {
2972
3074
  const loc = `Tags.${key}`;
2973
3075
  entries[loc] = value;
@@ -3007,6 +3109,9 @@ const serializeAws_queryPutInsightRuleInput = (input, context) => {
3007
3109
  }
3008
3110
  if (input.Tags != null) {
3009
3111
  const memberEntries = serializeAws_queryTagList(input.Tags, context);
3112
+ if (input.Tags?.length === 0) {
3113
+ entries.Tags = [];
3114
+ }
3010
3115
  Object.entries(memberEntries).forEach(([key, value]) => {
3011
3116
  const loc = `Tags.${key}`;
3012
3117
  entries[loc] = value;
@@ -3018,6 +3123,9 @@ const serializeAws_queryPutManagedInsightRulesInput = (input, context) => {
3018
3123
  const entries = {};
3019
3124
  if (input.ManagedRules != null) {
3020
3125
  const memberEntries = serializeAws_queryManagedRules(input.ManagedRules, context);
3126
+ if (input.ManagedRules?.length === 0) {
3127
+ entries.ManagedRules = [];
3128
+ }
3021
3129
  Object.entries(memberEntries).forEach(([key, value]) => {
3022
3130
  const loc = `ManagedRules.${key}`;
3023
3131
  entries[loc] = value;
@@ -3038,6 +3146,9 @@ const serializeAws_queryPutMetricAlarmInput = (input, context) => {
3038
3146
  }
3039
3147
  if (input.OKActions != null) {
3040
3148
  const memberEntries = serializeAws_queryResourceList(input.OKActions, context);
3149
+ if (input.OKActions?.length === 0) {
3150
+ entries.OKActions = [];
3151
+ }
3041
3152
  Object.entries(memberEntries).forEach(([key, value]) => {
3042
3153
  const loc = `OKActions.${key}`;
3043
3154
  entries[loc] = value;
@@ -3045,6 +3156,9 @@ const serializeAws_queryPutMetricAlarmInput = (input, context) => {
3045
3156
  }
3046
3157
  if (input.AlarmActions != null) {
3047
3158
  const memberEntries = serializeAws_queryResourceList(input.AlarmActions, context);
3159
+ if (input.AlarmActions?.length === 0) {
3160
+ entries.AlarmActions = [];
3161
+ }
3048
3162
  Object.entries(memberEntries).forEach(([key, value]) => {
3049
3163
  const loc = `AlarmActions.${key}`;
3050
3164
  entries[loc] = value;
@@ -3052,6 +3166,9 @@ const serializeAws_queryPutMetricAlarmInput = (input, context) => {
3052
3166
  }
3053
3167
  if (input.InsufficientDataActions != null) {
3054
3168
  const memberEntries = serializeAws_queryResourceList(input.InsufficientDataActions, context);
3169
+ if (input.InsufficientDataActions?.length === 0) {
3170
+ entries.InsufficientDataActions = [];
3171
+ }
3055
3172
  Object.entries(memberEntries).forEach(([key, value]) => {
3056
3173
  const loc = `InsufficientDataActions.${key}`;
3057
3174
  entries[loc] = value;
@@ -3071,6 +3188,9 @@ const serializeAws_queryPutMetricAlarmInput = (input, context) => {
3071
3188
  }
3072
3189
  if (input.Dimensions != null) {
3073
3190
  const memberEntries = serializeAws_queryDimensions(input.Dimensions, context);
3191
+ if (input.Dimensions?.length === 0) {
3192
+ entries.Dimensions = [];
3193
+ }
3074
3194
  Object.entries(memberEntries).forEach(([key, value]) => {
3075
3195
  const loc = `Dimensions.${key}`;
3076
3196
  entries[loc] = value;
@@ -3102,6 +3222,9 @@ const serializeAws_queryPutMetricAlarmInput = (input, context) => {
3102
3222
  }
3103
3223
  if (input.Metrics != null) {
3104
3224
  const memberEntries = serializeAws_queryMetricDataQueries(input.Metrics, context);
3225
+ if (input.Metrics?.length === 0) {
3226
+ entries.Metrics = [];
3227
+ }
3105
3228
  Object.entries(memberEntries).forEach(([key, value]) => {
3106
3229
  const loc = `Metrics.${key}`;
3107
3230
  entries[loc] = value;
@@ -3109,6 +3232,9 @@ const serializeAws_queryPutMetricAlarmInput = (input, context) => {
3109
3232
  }
3110
3233
  if (input.Tags != null) {
3111
3234
  const memberEntries = serializeAws_queryTagList(input.Tags, context);
3235
+ if (input.Tags?.length === 0) {
3236
+ entries.Tags = [];
3237
+ }
3112
3238
  Object.entries(memberEntries).forEach(([key, value]) => {
3113
3239
  const loc = `Tags.${key}`;
3114
3240
  entries[loc] = value;
@@ -3126,6 +3252,9 @@ const serializeAws_queryPutMetricDataInput = (input, context) => {
3126
3252
  }
3127
3253
  if (input.MetricData != null) {
3128
3254
  const memberEntries = serializeAws_queryMetricData(input.MetricData, context);
3255
+ if (input.MetricData?.length === 0) {
3256
+ entries.MetricData = [];
3257
+ }
3129
3258
  Object.entries(memberEntries).forEach(([key, value]) => {
3130
3259
  const loc = `MetricData.${key}`;
3131
3260
  entries[loc] = value;
@@ -3140,6 +3269,9 @@ const serializeAws_queryPutMetricStreamInput = (input, context) => {
3140
3269
  }
3141
3270
  if (input.IncludeFilters != null) {
3142
3271
  const memberEntries = serializeAws_queryMetricStreamFilters(input.IncludeFilters, context);
3272
+ if (input.IncludeFilters?.length === 0) {
3273
+ entries.IncludeFilters = [];
3274
+ }
3143
3275
  Object.entries(memberEntries).forEach(([key, value]) => {
3144
3276
  const loc = `IncludeFilters.${key}`;
3145
3277
  entries[loc] = value;
@@ -3147,6 +3279,9 @@ const serializeAws_queryPutMetricStreamInput = (input, context) => {
3147
3279
  }
3148
3280
  if (input.ExcludeFilters != null) {
3149
3281
  const memberEntries = serializeAws_queryMetricStreamFilters(input.ExcludeFilters, context);
3282
+ if (input.ExcludeFilters?.length === 0) {
3283
+ entries.ExcludeFilters = [];
3284
+ }
3150
3285
  Object.entries(memberEntries).forEach(([key, value]) => {
3151
3286
  const loc = `ExcludeFilters.${key}`;
3152
3287
  entries[loc] = value;
@@ -3163,6 +3298,9 @@ const serializeAws_queryPutMetricStreamInput = (input, context) => {
3163
3298
  }
3164
3299
  if (input.Tags != null) {
3165
3300
  const memberEntries = serializeAws_queryTagList(input.Tags, context);
3301
+ if (input.Tags?.length === 0) {
3302
+ entries.Tags = [];
3303
+ }
3166
3304
  Object.entries(memberEntries).forEach(([key, value]) => {
3167
3305
  const loc = `Tags.${key}`;
3168
3306
  entries[loc] = value;
@@ -3170,6 +3308,9 @@ const serializeAws_queryPutMetricStreamInput = (input, context) => {
3170
3308
  }
3171
3309
  if (input.StatisticsConfigurations != null) {
3172
3310
  const memberEntries = serializeAws_queryMetricStreamStatisticsConfigurations(input.StatisticsConfigurations, context);
3311
+ if (input.StatisticsConfigurations?.length === 0) {
3312
+ entries.StatisticsConfigurations = [];
3313
+ }
3173
3314
  Object.entries(memberEntries).forEach(([key, value]) => {
3174
3315
  const loc = `StatisticsConfigurations.${key}`;
3175
3316
  entries[loc] = value;
@@ -3225,6 +3366,9 @@ const serializeAws_querySingleMetricAnomalyDetector = (input, context) => {
3225
3366
  }
3226
3367
  if (input.Dimensions != null) {
3227
3368
  const memberEntries = serializeAws_queryDimensions(input.Dimensions, context);
3369
+ if (input.Dimensions?.length === 0) {
3370
+ entries.Dimensions = [];
3371
+ }
3228
3372
  Object.entries(memberEntries).forEach(([key, value]) => {
3229
3373
  const loc = `Dimensions.${key}`;
3230
3374
  entries[loc] = value;
@@ -3239,6 +3383,9 @@ const serializeAws_queryStartMetricStreamsInput = (input, context) => {
3239
3383
  const entries = {};
3240
3384
  if (input.Names != null) {
3241
3385
  const memberEntries = serializeAws_queryMetricStreamNames(input.Names, context);
3386
+ if (input.Names?.length === 0) {
3387
+ entries.Names = [];
3388
+ }
3242
3389
  Object.entries(memberEntries).forEach(([key, value]) => {
3243
3390
  const loc = `Names.${key}`;
3244
3391
  entries[loc] = value;
@@ -3278,6 +3425,9 @@ const serializeAws_queryStopMetricStreamsInput = (input, context) => {
3278
3425
  const entries = {};
3279
3426
  if (input.Names != null) {
3280
3427
  const memberEntries = serializeAws_queryMetricStreamNames(input.Names, context);
3428
+ if (input.Names?.length === 0) {
3429
+ entries.Names = [];
3430
+ }
3281
3431
  Object.entries(memberEntries).forEach(([key, value]) => {
3282
3432
  const loc = `Names.${key}`;
3283
3433
  entries[loc] = value;
@@ -3329,6 +3479,9 @@ const serializeAws_queryTagResourceInput = (input, context) => {
3329
3479
  }
3330
3480
  if (input.Tags != null) {
3331
3481
  const memberEntries = serializeAws_queryTagList(input.Tags, context);
3482
+ if (input.Tags?.length === 0) {
3483
+ entries.Tags = [];
3484
+ }
3332
3485
  Object.entries(memberEntries).forEach(([key, value]) => {
3333
3486
  const loc = `Tags.${key}`;
3334
3487
  entries[loc] = value;
@@ -3343,6 +3496,9 @@ const serializeAws_queryUntagResourceInput = (input, context) => {
3343
3496
  }
3344
3497
  if (input.TagKeys != null) {
3345
3498
  const memberEntries = serializeAws_queryTagKeyList(input.TagKeys, context);
3499
+ if (input.TagKeys?.length === 0) {
3500
+ entries.TagKeys = [];
3501
+ }
3346
3502
  Object.entries(memberEntries).forEach(([key, value]) => {
3347
3503
  const loc = `TagKeys.${key}`;
3348
3504
  entries[loc] = value;
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@aws-sdk/client-cloudwatch",
3
3
  "description": "AWS SDK for JavaScript Cloudwatch Client for Node.js, Browser and React Native",
4
- "version": "3.201.0",
4
+ "version": "3.202.0",
5
5
  "scripts": {
6
6
  "build": "concurrently 'yarn:build:cjs' 'yarn:build:es' 'yarn:build:types'",
7
7
  "build:cjs": "tsc -p tsconfig.cjs.json",
@@ -19,9 +19,9 @@
19
19
  "dependencies": {
20
20
  "@aws-crypto/sha256-browser": "2.0.0",
21
21
  "@aws-crypto/sha256-js": "2.0.0",
22
- "@aws-sdk/client-sts": "3.201.0",
22
+ "@aws-sdk/client-sts": "3.202.0",
23
23
  "@aws-sdk/config-resolver": "3.201.0",
24
- "@aws-sdk/credential-provider-node": "3.201.0",
24
+ "@aws-sdk/credential-provider-node": "3.202.0",
25
25
  "@aws-sdk/fetch-http-handler": "3.201.0",
26
26
  "@aws-sdk/hash-node": "3.201.0",
27
27
  "@aws-sdk/invalid-dependency": "3.201.0",
@@ -47,7 +47,7 @@
47
47
  "@aws-sdk/util-body-length-node": "3.201.0",
48
48
  "@aws-sdk/util-defaults-mode-browser": "3.201.0",
49
49
  "@aws-sdk/util-defaults-mode-node": "3.201.0",
50
- "@aws-sdk/util-endpoints": "3.201.0",
50
+ "@aws-sdk/util-endpoints": "3.202.0",
51
51
  "@aws-sdk/util-user-agent-browser": "3.201.0",
52
52
  "@aws-sdk/util-user-agent-node": "3.201.0",
53
53
  "@aws-sdk/util-utf8-browser": "3.188.0",