@aws-sdk/client-cost-explorer 3.310.0 → 3.315.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.
@@ -1,336 +1,225 @@
1
1
  import { HttpRequest as __HttpRequest } from "@aws-sdk/protocol-http";
2
- import { decorateServiceException as __decorateServiceException, expectBoolean as __expectBoolean, expectInt32 as __expectInt32, expectString as __expectString, limitedParseDouble as __limitedParseDouble, serializeFloat as __serializeFloat, throwDefaultError, } from "@aws-sdk/smithy-client";
2
+ import { _json, decorateServiceException as __decorateServiceException, expectInt32 as __expectInt32, expectString as __expectString, limitedParseDouble as __limitedParseDouble, serializeFloat as __serializeFloat, take, withBaseException, } from "@aws-sdk/smithy-client";
3
3
  import { CostExplorerServiceException as __BaseException } from "../models/CostExplorerServiceException";
4
4
  import { BillExpirationException, DataUnavailableException, GenerationExistsException, InvalidNextTokenException, LimitExceededException, RequestChangedException, ResourceNotFoundException, ServiceQuotaExceededException, TooManyTagsException, UnknownMonitorException, UnknownSubscriptionException, UnresolvableUsageUnitException, } from "../models/models_0";
5
5
  export const se_CreateAnomalyMonitorCommand = async (input, context) => {
6
- const headers = {
7
- "content-type": "application/x-amz-json-1.1",
8
- "x-amz-target": "AWSInsightsIndexService.CreateAnomalyMonitor",
9
- };
6
+ const headers = sharedHeaders("CreateAnomalyMonitor");
10
7
  let body;
11
8
  body = JSON.stringify(se_CreateAnomalyMonitorRequest(input, context));
12
9
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
13
10
  };
14
11
  export const se_CreateAnomalySubscriptionCommand = async (input, context) => {
15
- const headers = {
16
- "content-type": "application/x-amz-json-1.1",
17
- "x-amz-target": "AWSInsightsIndexService.CreateAnomalySubscription",
18
- };
12
+ const headers = sharedHeaders("CreateAnomalySubscription");
19
13
  let body;
20
14
  body = JSON.stringify(se_CreateAnomalySubscriptionRequest(input, context));
21
15
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
22
16
  };
23
17
  export const se_CreateCostCategoryDefinitionCommand = async (input, context) => {
24
- const headers = {
25
- "content-type": "application/x-amz-json-1.1",
26
- "x-amz-target": "AWSInsightsIndexService.CreateCostCategoryDefinition",
27
- };
18
+ const headers = sharedHeaders("CreateCostCategoryDefinition");
28
19
  let body;
29
20
  body = JSON.stringify(se_CreateCostCategoryDefinitionRequest(input, context));
30
21
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
31
22
  };
32
23
  export const se_DeleteAnomalyMonitorCommand = async (input, context) => {
33
- const headers = {
34
- "content-type": "application/x-amz-json-1.1",
35
- "x-amz-target": "AWSInsightsIndexService.DeleteAnomalyMonitor",
36
- };
24
+ const headers = sharedHeaders("DeleteAnomalyMonitor");
37
25
  let body;
38
- body = JSON.stringify(se_DeleteAnomalyMonitorRequest(input, context));
26
+ body = JSON.stringify(_json(input));
39
27
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
40
28
  };
41
29
  export const se_DeleteAnomalySubscriptionCommand = async (input, context) => {
42
- const headers = {
43
- "content-type": "application/x-amz-json-1.1",
44
- "x-amz-target": "AWSInsightsIndexService.DeleteAnomalySubscription",
45
- };
30
+ const headers = sharedHeaders("DeleteAnomalySubscription");
46
31
  let body;
47
- body = JSON.stringify(se_DeleteAnomalySubscriptionRequest(input, context));
32
+ body = JSON.stringify(_json(input));
48
33
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
49
34
  };
50
35
  export const se_DeleteCostCategoryDefinitionCommand = async (input, context) => {
51
- const headers = {
52
- "content-type": "application/x-amz-json-1.1",
53
- "x-amz-target": "AWSInsightsIndexService.DeleteCostCategoryDefinition",
54
- };
36
+ const headers = sharedHeaders("DeleteCostCategoryDefinition");
55
37
  let body;
56
- body = JSON.stringify(se_DeleteCostCategoryDefinitionRequest(input, context));
38
+ body = JSON.stringify(_json(input));
57
39
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
58
40
  };
59
41
  export const se_DescribeCostCategoryDefinitionCommand = async (input, context) => {
60
- const headers = {
61
- "content-type": "application/x-amz-json-1.1",
62
- "x-amz-target": "AWSInsightsIndexService.DescribeCostCategoryDefinition",
63
- };
42
+ const headers = sharedHeaders("DescribeCostCategoryDefinition");
64
43
  let body;
65
- body = JSON.stringify(se_DescribeCostCategoryDefinitionRequest(input, context));
44
+ body = JSON.stringify(_json(input));
66
45
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
67
46
  };
68
47
  export const se_GetAnomaliesCommand = async (input, context) => {
69
- const headers = {
70
- "content-type": "application/x-amz-json-1.1",
71
- "x-amz-target": "AWSInsightsIndexService.GetAnomalies",
72
- };
48
+ const headers = sharedHeaders("GetAnomalies");
73
49
  let body;
74
50
  body = JSON.stringify(se_GetAnomaliesRequest(input, context));
75
51
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
76
52
  };
77
53
  export const se_GetAnomalyMonitorsCommand = async (input, context) => {
78
- const headers = {
79
- "content-type": "application/x-amz-json-1.1",
80
- "x-amz-target": "AWSInsightsIndexService.GetAnomalyMonitors",
81
- };
54
+ const headers = sharedHeaders("GetAnomalyMonitors");
82
55
  let body;
83
- body = JSON.stringify(se_GetAnomalyMonitorsRequest(input, context));
56
+ body = JSON.stringify(_json(input));
84
57
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
85
58
  };
86
59
  export const se_GetAnomalySubscriptionsCommand = async (input, context) => {
87
- const headers = {
88
- "content-type": "application/x-amz-json-1.1",
89
- "x-amz-target": "AWSInsightsIndexService.GetAnomalySubscriptions",
90
- };
60
+ const headers = sharedHeaders("GetAnomalySubscriptions");
91
61
  let body;
92
- body = JSON.stringify(se_GetAnomalySubscriptionsRequest(input, context));
62
+ body = JSON.stringify(_json(input));
93
63
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
94
64
  };
95
65
  export const se_GetCostAndUsageCommand = async (input, context) => {
96
- const headers = {
97
- "content-type": "application/x-amz-json-1.1",
98
- "x-amz-target": "AWSInsightsIndexService.GetCostAndUsage",
99
- };
66
+ const headers = sharedHeaders("GetCostAndUsage");
100
67
  let body;
101
68
  body = JSON.stringify(se_GetCostAndUsageRequest(input, context));
102
69
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
103
70
  };
104
71
  export const se_GetCostAndUsageWithResourcesCommand = async (input, context) => {
105
- const headers = {
106
- "content-type": "application/x-amz-json-1.1",
107
- "x-amz-target": "AWSInsightsIndexService.GetCostAndUsageWithResources",
108
- };
72
+ const headers = sharedHeaders("GetCostAndUsageWithResources");
109
73
  let body;
110
74
  body = JSON.stringify(se_GetCostAndUsageWithResourcesRequest(input, context));
111
75
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
112
76
  };
113
77
  export const se_GetCostCategoriesCommand = async (input, context) => {
114
- const headers = {
115
- "content-type": "application/x-amz-json-1.1",
116
- "x-amz-target": "AWSInsightsIndexService.GetCostCategories",
117
- };
78
+ const headers = sharedHeaders("GetCostCategories");
118
79
  let body;
119
80
  body = JSON.stringify(se_GetCostCategoriesRequest(input, context));
120
81
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
121
82
  };
122
83
  export const se_GetCostForecastCommand = async (input, context) => {
123
- const headers = {
124
- "content-type": "application/x-amz-json-1.1",
125
- "x-amz-target": "AWSInsightsIndexService.GetCostForecast",
126
- };
84
+ const headers = sharedHeaders("GetCostForecast");
127
85
  let body;
128
86
  body = JSON.stringify(se_GetCostForecastRequest(input, context));
129
87
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
130
88
  };
131
89
  export const se_GetDimensionValuesCommand = async (input, context) => {
132
- const headers = {
133
- "content-type": "application/x-amz-json-1.1",
134
- "x-amz-target": "AWSInsightsIndexService.GetDimensionValues",
135
- };
90
+ const headers = sharedHeaders("GetDimensionValues");
136
91
  let body;
137
92
  body = JSON.stringify(se_GetDimensionValuesRequest(input, context));
138
93
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
139
94
  };
140
95
  export const se_GetReservationCoverageCommand = async (input, context) => {
141
- const headers = {
142
- "content-type": "application/x-amz-json-1.1",
143
- "x-amz-target": "AWSInsightsIndexService.GetReservationCoverage",
144
- };
96
+ const headers = sharedHeaders("GetReservationCoverage");
145
97
  let body;
146
98
  body = JSON.stringify(se_GetReservationCoverageRequest(input, context));
147
99
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
148
100
  };
149
101
  export const se_GetReservationPurchaseRecommendationCommand = async (input, context) => {
150
- const headers = {
151
- "content-type": "application/x-amz-json-1.1",
152
- "x-amz-target": "AWSInsightsIndexService.GetReservationPurchaseRecommendation",
153
- };
102
+ const headers = sharedHeaders("GetReservationPurchaseRecommendation");
154
103
  let body;
155
104
  body = JSON.stringify(se_GetReservationPurchaseRecommendationRequest(input, context));
156
105
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
157
106
  };
158
107
  export const se_GetReservationUtilizationCommand = async (input, context) => {
159
- const headers = {
160
- "content-type": "application/x-amz-json-1.1",
161
- "x-amz-target": "AWSInsightsIndexService.GetReservationUtilization",
162
- };
108
+ const headers = sharedHeaders("GetReservationUtilization");
163
109
  let body;
164
110
  body = JSON.stringify(se_GetReservationUtilizationRequest(input, context));
165
111
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
166
112
  };
167
113
  export const se_GetRightsizingRecommendationCommand = async (input, context) => {
168
- const headers = {
169
- "content-type": "application/x-amz-json-1.1",
170
- "x-amz-target": "AWSInsightsIndexService.GetRightsizingRecommendation",
171
- };
114
+ const headers = sharedHeaders("GetRightsizingRecommendation");
172
115
  let body;
173
116
  body = JSON.stringify(se_GetRightsizingRecommendationRequest(input, context));
174
117
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
175
118
  };
176
119
  export const se_GetSavingsPlansCoverageCommand = async (input, context) => {
177
- const headers = {
178
- "content-type": "application/x-amz-json-1.1",
179
- "x-amz-target": "AWSInsightsIndexService.GetSavingsPlansCoverage",
180
- };
120
+ const headers = sharedHeaders("GetSavingsPlansCoverage");
181
121
  let body;
182
122
  body = JSON.stringify(se_GetSavingsPlansCoverageRequest(input, context));
183
123
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
184
124
  };
185
125
  export const se_GetSavingsPlansPurchaseRecommendationCommand = async (input, context) => {
186
- const headers = {
187
- "content-type": "application/x-amz-json-1.1",
188
- "x-amz-target": "AWSInsightsIndexService.GetSavingsPlansPurchaseRecommendation",
189
- };
126
+ const headers = sharedHeaders("GetSavingsPlansPurchaseRecommendation");
190
127
  let body;
191
128
  body = JSON.stringify(se_GetSavingsPlansPurchaseRecommendationRequest(input, context));
192
129
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
193
130
  };
194
131
  export const se_GetSavingsPlansUtilizationCommand = async (input, context) => {
195
- const headers = {
196
- "content-type": "application/x-amz-json-1.1",
197
- "x-amz-target": "AWSInsightsIndexService.GetSavingsPlansUtilization",
198
- };
132
+ const headers = sharedHeaders("GetSavingsPlansUtilization");
199
133
  let body;
200
134
  body = JSON.stringify(se_GetSavingsPlansUtilizationRequest(input, context));
201
135
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
202
136
  };
203
137
  export const se_GetSavingsPlansUtilizationDetailsCommand = async (input, context) => {
204
- const headers = {
205
- "content-type": "application/x-amz-json-1.1",
206
- "x-amz-target": "AWSInsightsIndexService.GetSavingsPlansUtilizationDetails",
207
- };
138
+ const headers = sharedHeaders("GetSavingsPlansUtilizationDetails");
208
139
  let body;
209
140
  body = JSON.stringify(se_GetSavingsPlansUtilizationDetailsRequest(input, context));
210
141
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
211
142
  };
212
143
  export const se_GetTagsCommand = async (input, context) => {
213
- const headers = {
214
- "content-type": "application/x-amz-json-1.1",
215
- "x-amz-target": "AWSInsightsIndexService.GetTags",
216
- };
144
+ const headers = sharedHeaders("GetTags");
217
145
  let body;
218
146
  body = JSON.stringify(se_GetTagsRequest(input, context));
219
147
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
220
148
  };
221
149
  export const se_GetUsageForecastCommand = async (input, context) => {
222
- const headers = {
223
- "content-type": "application/x-amz-json-1.1",
224
- "x-amz-target": "AWSInsightsIndexService.GetUsageForecast",
225
- };
150
+ const headers = sharedHeaders("GetUsageForecast");
226
151
  let body;
227
152
  body = JSON.stringify(se_GetUsageForecastRequest(input, context));
228
153
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
229
154
  };
230
155
  export const se_ListCostAllocationTagsCommand = async (input, context) => {
231
- const headers = {
232
- "content-type": "application/x-amz-json-1.1",
233
- "x-amz-target": "AWSInsightsIndexService.ListCostAllocationTags",
234
- };
156
+ const headers = sharedHeaders("ListCostAllocationTags");
235
157
  let body;
236
- body = JSON.stringify(se_ListCostAllocationTagsRequest(input, context));
158
+ body = JSON.stringify(_json(input));
237
159
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
238
160
  };
239
161
  export const se_ListCostCategoryDefinitionsCommand = async (input, context) => {
240
- const headers = {
241
- "content-type": "application/x-amz-json-1.1",
242
- "x-amz-target": "AWSInsightsIndexService.ListCostCategoryDefinitions",
243
- };
162
+ const headers = sharedHeaders("ListCostCategoryDefinitions");
244
163
  let body;
245
- body = JSON.stringify(se_ListCostCategoryDefinitionsRequest(input, context));
164
+ body = JSON.stringify(_json(input));
246
165
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
247
166
  };
248
167
  export const se_ListSavingsPlansPurchaseRecommendationGenerationCommand = async (input, context) => {
249
- const headers = {
250
- "content-type": "application/x-amz-json-1.1",
251
- "x-amz-target": "AWSInsightsIndexService.ListSavingsPlansPurchaseRecommendationGeneration",
252
- };
168
+ const headers = sharedHeaders("ListSavingsPlansPurchaseRecommendationGeneration");
253
169
  let body;
254
- body = JSON.stringify(se_ListSavingsPlansPurchaseRecommendationGenerationRequest(input, context));
170
+ body = JSON.stringify(_json(input));
255
171
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
256
172
  };
257
173
  export const se_ListTagsForResourceCommand = async (input, context) => {
258
- const headers = {
259
- "content-type": "application/x-amz-json-1.1",
260
- "x-amz-target": "AWSInsightsIndexService.ListTagsForResource",
261
- };
174
+ const headers = sharedHeaders("ListTagsForResource");
262
175
  let body;
263
- body = JSON.stringify(se_ListTagsForResourceRequest(input, context));
176
+ body = JSON.stringify(_json(input));
264
177
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
265
178
  };
266
179
  export const se_ProvideAnomalyFeedbackCommand = async (input, context) => {
267
- const headers = {
268
- "content-type": "application/x-amz-json-1.1",
269
- "x-amz-target": "AWSInsightsIndexService.ProvideAnomalyFeedback",
270
- };
180
+ const headers = sharedHeaders("ProvideAnomalyFeedback");
271
181
  let body;
272
- body = JSON.stringify(se_ProvideAnomalyFeedbackRequest(input, context));
182
+ body = JSON.stringify(_json(input));
273
183
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
274
184
  };
275
185
  export const se_StartSavingsPlansPurchaseRecommendationGenerationCommand = async (input, context) => {
276
- const headers = {
277
- "content-type": "application/x-amz-json-1.1",
278
- "x-amz-target": "AWSInsightsIndexService.StartSavingsPlansPurchaseRecommendationGeneration",
279
- };
186
+ const headers = sharedHeaders("StartSavingsPlansPurchaseRecommendationGeneration");
280
187
  let body;
281
- body = JSON.stringify(se_StartSavingsPlansPurchaseRecommendationGenerationRequest(input, context));
188
+ body = JSON.stringify(_json(input));
282
189
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
283
190
  };
284
191
  export const se_TagResourceCommand = async (input, context) => {
285
- const headers = {
286
- "content-type": "application/x-amz-json-1.1",
287
- "x-amz-target": "AWSInsightsIndexService.TagResource",
288
- };
192
+ const headers = sharedHeaders("TagResource");
289
193
  let body;
290
- body = JSON.stringify(se_TagResourceRequest(input, context));
194
+ body = JSON.stringify(_json(input));
291
195
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
292
196
  };
293
197
  export const se_UntagResourceCommand = async (input, context) => {
294
- const headers = {
295
- "content-type": "application/x-amz-json-1.1",
296
- "x-amz-target": "AWSInsightsIndexService.UntagResource",
297
- };
198
+ const headers = sharedHeaders("UntagResource");
298
199
  let body;
299
- body = JSON.stringify(se_UntagResourceRequest(input, context));
200
+ body = JSON.stringify(_json(input));
300
201
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
301
202
  };
302
203
  export const se_UpdateAnomalyMonitorCommand = async (input, context) => {
303
- const headers = {
304
- "content-type": "application/x-amz-json-1.1",
305
- "x-amz-target": "AWSInsightsIndexService.UpdateAnomalyMonitor",
306
- };
204
+ const headers = sharedHeaders("UpdateAnomalyMonitor");
307
205
  let body;
308
- body = JSON.stringify(se_UpdateAnomalyMonitorRequest(input, context));
206
+ body = JSON.stringify(_json(input));
309
207
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
310
208
  };
311
209
  export const se_UpdateAnomalySubscriptionCommand = async (input, context) => {
312
- const headers = {
313
- "content-type": "application/x-amz-json-1.1",
314
- "x-amz-target": "AWSInsightsIndexService.UpdateAnomalySubscription",
315
- };
210
+ const headers = sharedHeaders("UpdateAnomalySubscription");
316
211
  let body;
317
212
  body = JSON.stringify(se_UpdateAnomalySubscriptionRequest(input, context));
318
213
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
319
214
  };
320
215
  export const se_UpdateCostAllocationTagsStatusCommand = async (input, context) => {
321
- const headers = {
322
- "content-type": "application/x-amz-json-1.1",
323
- "x-amz-target": "AWSInsightsIndexService.UpdateCostAllocationTagsStatus",
324
- };
216
+ const headers = sharedHeaders("UpdateCostAllocationTagsStatus");
325
217
  let body;
326
- body = JSON.stringify(se_UpdateCostAllocationTagsStatusRequest(input, context));
218
+ body = JSON.stringify(_json(input));
327
219
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
328
220
  };
329
221
  export const se_UpdateCostCategoryDefinitionCommand = async (input, context) => {
330
- const headers = {
331
- "content-type": "application/x-amz-json-1.1",
332
- "x-amz-target": "AWSInsightsIndexService.UpdateCostCategoryDefinition",
333
- };
222
+ const headers = sharedHeaders("UpdateCostCategoryDefinition");
334
223
  let body;
335
224
  body = JSON.stringify(se_UpdateCostCategoryDefinitionRequest(input, context));
336
225
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
@@ -341,12 +230,12 @@ export const de_CreateAnomalyMonitorCommand = async (output, context) => {
341
230
  }
342
231
  const data = await parseBody(output.body, context);
343
232
  let contents = {};
344
- contents = de_CreateAnomalyMonitorResponse(data, context);
233
+ contents = _json(data);
345
234
  const response = {
346
235
  $metadata: deserializeMetadata(output),
347
236
  ...contents,
348
237
  };
349
- return Promise.resolve(response);
238
+ return response;
350
239
  };
351
240
  const de_CreateAnomalyMonitorCommandError = async (output, context) => {
352
241
  const parsedOutput = {
@@ -360,10 +249,9 @@ const de_CreateAnomalyMonitorCommandError = async (output, context) => {
360
249
  throw await de_LimitExceededExceptionRes(parsedOutput, context);
361
250
  default:
362
251
  const parsedBody = parsedOutput.body;
363
- throwDefaultError({
252
+ return throwDefaultError({
364
253
  output,
365
254
  parsedBody,
366
- exceptionCtor: __BaseException,
367
255
  errorCode,
368
256
  });
369
257
  }
@@ -374,12 +262,12 @@ export const de_CreateAnomalySubscriptionCommand = async (output, context) => {
374
262
  }
375
263
  const data = await parseBody(output.body, context);
376
264
  let contents = {};
377
- contents = de_CreateAnomalySubscriptionResponse(data, context);
265
+ contents = _json(data);
378
266
  const response = {
379
267
  $metadata: deserializeMetadata(output),
380
268
  ...contents,
381
269
  };
382
- return Promise.resolve(response);
270
+ return response;
383
271
  };
384
272
  const de_CreateAnomalySubscriptionCommandError = async (output, context) => {
385
273
  const parsedOutput = {
@@ -396,10 +284,9 @@ const de_CreateAnomalySubscriptionCommandError = async (output, context) => {
396
284
  throw await de_UnknownMonitorExceptionRes(parsedOutput, context);
397
285
  default:
398
286
  const parsedBody = parsedOutput.body;
399
- throwDefaultError({
287
+ return throwDefaultError({
400
288
  output,
401
289
  parsedBody,
402
- exceptionCtor: __BaseException,
403
290
  errorCode,
404
291
  });
405
292
  }
@@ -410,12 +297,12 @@ export const de_CreateCostCategoryDefinitionCommand = async (output, context) =>
410
297
  }
411
298
  const data = await parseBody(output.body, context);
412
299
  let contents = {};
413
- contents = de_CreateCostCategoryDefinitionResponse(data, context);
300
+ contents = _json(data);
414
301
  const response = {
415
302
  $metadata: deserializeMetadata(output),
416
303
  ...contents,
417
304
  };
418
- return Promise.resolve(response);
305
+ return response;
419
306
  };
420
307
  const de_CreateCostCategoryDefinitionCommandError = async (output, context) => {
421
308
  const parsedOutput = {
@@ -432,10 +319,9 @@ const de_CreateCostCategoryDefinitionCommandError = async (output, context) => {
432
319
  throw await de_ServiceQuotaExceededExceptionRes(parsedOutput, context);
433
320
  default:
434
321
  const parsedBody = parsedOutput.body;
435
- throwDefaultError({
322
+ return throwDefaultError({
436
323
  output,
437
324
  parsedBody,
438
- exceptionCtor: __BaseException,
439
325
  errorCode,
440
326
  });
441
327
  }
@@ -446,12 +332,12 @@ export const de_DeleteAnomalyMonitorCommand = async (output, context) => {
446
332
  }
447
333
  const data = await parseBody(output.body, context);
448
334
  let contents = {};
449
- contents = de_DeleteAnomalyMonitorResponse(data, context);
335
+ contents = _json(data);
450
336
  const response = {
451
337
  $metadata: deserializeMetadata(output),
452
338
  ...contents,
453
339
  };
454
- return Promise.resolve(response);
340
+ return response;
455
341
  };
456
342
  const de_DeleteAnomalyMonitorCommandError = async (output, context) => {
457
343
  const parsedOutput = {
@@ -468,10 +354,9 @@ const de_DeleteAnomalyMonitorCommandError = async (output, context) => {
468
354
  throw await de_UnknownMonitorExceptionRes(parsedOutput, context);
469
355
  default:
470
356
  const parsedBody = parsedOutput.body;
471
- throwDefaultError({
357
+ return throwDefaultError({
472
358
  output,
473
359
  parsedBody,
474
- exceptionCtor: __BaseException,
475
360
  errorCode,
476
361
  });
477
362
  }
@@ -482,12 +367,12 @@ export const de_DeleteAnomalySubscriptionCommand = async (output, context) => {
482
367
  }
483
368
  const data = await parseBody(output.body, context);
484
369
  let contents = {};
485
- contents = de_DeleteAnomalySubscriptionResponse(data, context);
370
+ contents = _json(data);
486
371
  const response = {
487
372
  $metadata: deserializeMetadata(output),
488
373
  ...contents,
489
374
  };
490
- return Promise.resolve(response);
375
+ return response;
491
376
  };
492
377
  const de_DeleteAnomalySubscriptionCommandError = async (output, context) => {
493
378
  const parsedOutput = {
@@ -504,10 +389,9 @@ const de_DeleteAnomalySubscriptionCommandError = async (output, context) => {
504
389
  throw await de_UnknownSubscriptionExceptionRes(parsedOutput, context);
505
390
  default:
506
391
  const parsedBody = parsedOutput.body;
507
- throwDefaultError({
392
+ return throwDefaultError({
508
393
  output,
509
394
  parsedBody,
510
- exceptionCtor: __BaseException,
511
395
  errorCode,
512
396
  });
513
397
  }
@@ -518,12 +402,12 @@ export const de_DeleteCostCategoryDefinitionCommand = async (output, context) =>
518
402
  }
519
403
  const data = await parseBody(output.body, context);
520
404
  let contents = {};
521
- contents = de_DeleteCostCategoryDefinitionResponse(data, context);
405
+ contents = _json(data);
522
406
  const response = {
523
407
  $metadata: deserializeMetadata(output),
524
408
  ...contents,
525
409
  };
526
- return Promise.resolve(response);
410
+ return response;
527
411
  };
528
412
  const de_DeleteCostCategoryDefinitionCommandError = async (output, context) => {
529
413
  const parsedOutput = {
@@ -540,10 +424,9 @@ const de_DeleteCostCategoryDefinitionCommandError = async (output, context) => {
540
424
  throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
541
425
  default:
542
426
  const parsedBody = parsedOutput.body;
543
- throwDefaultError({
427
+ return throwDefaultError({
544
428
  output,
545
429
  parsedBody,
546
- exceptionCtor: __BaseException,
547
430
  errorCode,
548
431
  });
549
432
  }
@@ -559,7 +442,7 @@ export const de_DescribeCostCategoryDefinitionCommand = async (output, context)
559
442
  $metadata: deserializeMetadata(output),
560
443
  ...contents,
561
444
  };
562
- return Promise.resolve(response);
445
+ return response;
563
446
  };
564
447
  const de_DescribeCostCategoryDefinitionCommandError = async (output, context) => {
565
448
  const parsedOutput = {
@@ -576,10 +459,9 @@ const de_DescribeCostCategoryDefinitionCommandError = async (output, context) =>
576
459
  throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
577
460
  default:
578
461
  const parsedBody = parsedOutput.body;
579
- throwDefaultError({
462
+ return throwDefaultError({
580
463
  output,
581
464
  parsedBody,
582
- exceptionCtor: __BaseException,
583
465
  errorCode,
584
466
  });
585
467
  }
@@ -595,7 +477,7 @@ export const de_GetAnomaliesCommand = async (output, context) => {
595
477
  $metadata: deserializeMetadata(output),
596
478
  ...contents,
597
479
  };
598
- return Promise.resolve(response);
480
+ return response;
599
481
  };
600
482
  const de_GetAnomaliesCommandError = async (output, context) => {
601
483
  const parsedOutput = {
@@ -612,10 +494,9 @@ const de_GetAnomaliesCommandError = async (output, context) => {
612
494
  throw await de_LimitExceededExceptionRes(parsedOutput, context);
613
495
  default:
614
496
  const parsedBody = parsedOutput.body;
615
- throwDefaultError({
497
+ return throwDefaultError({
616
498
  output,
617
499
  parsedBody,
618
- exceptionCtor: __BaseException,
619
500
  errorCode,
620
501
  });
621
502
  }
@@ -631,7 +512,7 @@ export const de_GetAnomalyMonitorsCommand = async (output, context) => {
631
512
  $metadata: deserializeMetadata(output),
632
513
  ...contents,
633
514
  };
634
- return Promise.resolve(response);
515
+ return response;
635
516
  };
636
517
  const de_GetAnomalyMonitorsCommandError = async (output, context) => {
637
518
  const parsedOutput = {
@@ -651,10 +532,9 @@ const de_GetAnomalyMonitorsCommandError = async (output, context) => {
651
532
  throw await de_UnknownMonitorExceptionRes(parsedOutput, context);
652
533
  default:
653
534
  const parsedBody = parsedOutput.body;
654
- throwDefaultError({
535
+ return throwDefaultError({
655
536
  output,
656
537
  parsedBody,
657
- exceptionCtor: __BaseException,
658
538
  errorCode,
659
539
  });
660
540
  }
@@ -670,7 +550,7 @@ export const de_GetAnomalySubscriptionsCommand = async (output, context) => {
670
550
  $metadata: deserializeMetadata(output),
671
551
  ...contents,
672
552
  };
673
- return Promise.resolve(response);
553
+ return response;
674
554
  };
675
555
  const de_GetAnomalySubscriptionsCommandError = async (output, context) => {
676
556
  const parsedOutput = {
@@ -690,10 +570,9 @@ const de_GetAnomalySubscriptionsCommandError = async (output, context) => {
690
570
  throw await de_UnknownSubscriptionExceptionRes(parsedOutput, context);
691
571
  default:
692
572
  const parsedBody = parsedOutput.body;
693
- throwDefaultError({
573
+ return throwDefaultError({
694
574
  output,
695
575
  parsedBody,
696
- exceptionCtor: __BaseException,
697
576
  errorCode,
698
577
  });
699
578
  }
@@ -704,12 +583,12 @@ export const de_GetCostAndUsageCommand = async (output, context) => {
704
583
  }
705
584
  const data = await parseBody(output.body, context);
706
585
  let contents = {};
707
- contents = de_GetCostAndUsageResponse(data, context);
586
+ contents = _json(data);
708
587
  const response = {
709
588
  $metadata: deserializeMetadata(output),
710
589
  ...contents,
711
590
  };
712
- return Promise.resolve(response);
591
+ return response;
713
592
  };
714
593
  const de_GetCostAndUsageCommandError = async (output, context) => {
715
594
  const parsedOutput = {
@@ -735,10 +614,9 @@ const de_GetCostAndUsageCommandError = async (output, context) => {
735
614
  throw await de_RequestChangedExceptionRes(parsedOutput, context);
736
615
  default:
737
616
  const parsedBody = parsedOutput.body;
738
- throwDefaultError({
617
+ return throwDefaultError({
739
618
  output,
740
619
  parsedBody,
741
- exceptionCtor: __BaseException,
742
620
  errorCode,
743
621
  });
744
622
  }
@@ -749,12 +627,12 @@ export const de_GetCostAndUsageWithResourcesCommand = async (output, context) =>
749
627
  }
750
628
  const data = await parseBody(output.body, context);
751
629
  let contents = {};
752
- contents = de_GetCostAndUsageWithResourcesResponse(data, context);
630
+ contents = _json(data);
753
631
  const response = {
754
632
  $metadata: deserializeMetadata(output),
755
633
  ...contents,
756
634
  };
757
- return Promise.resolve(response);
635
+ return response;
758
636
  };
759
637
  const de_GetCostAndUsageWithResourcesCommandError = async (output, context) => {
760
638
  const parsedOutput = {
@@ -780,10 +658,9 @@ const de_GetCostAndUsageWithResourcesCommandError = async (output, context) => {
780
658
  throw await de_RequestChangedExceptionRes(parsedOutput, context);
781
659
  default:
782
660
  const parsedBody = parsedOutput.body;
783
- throwDefaultError({
661
+ return throwDefaultError({
784
662
  output,
785
663
  parsedBody,
786
- exceptionCtor: __BaseException,
787
664
  errorCode,
788
665
  });
789
666
  }
@@ -794,12 +671,12 @@ export const de_GetCostCategoriesCommand = async (output, context) => {
794
671
  }
795
672
  const data = await parseBody(output.body, context);
796
673
  let contents = {};
797
- contents = de_GetCostCategoriesResponse(data, context);
674
+ contents = _json(data);
798
675
  const response = {
799
676
  $metadata: deserializeMetadata(output),
800
677
  ...contents,
801
678
  };
802
- return Promise.resolve(response);
679
+ return response;
803
680
  };
804
681
  const de_GetCostCategoriesCommandError = async (output, context) => {
805
682
  const parsedOutput = {
@@ -825,10 +702,9 @@ const de_GetCostCategoriesCommandError = async (output, context) => {
825
702
  throw await de_RequestChangedExceptionRes(parsedOutput, context);
826
703
  default:
827
704
  const parsedBody = parsedOutput.body;
828
- throwDefaultError({
705
+ return throwDefaultError({
829
706
  output,
830
707
  parsedBody,
831
- exceptionCtor: __BaseException,
832
708
  errorCode,
833
709
  });
834
710
  }
@@ -839,12 +715,12 @@ export const de_GetCostForecastCommand = async (output, context) => {
839
715
  }
840
716
  const data = await parseBody(output.body, context);
841
717
  let contents = {};
842
- contents = de_GetCostForecastResponse(data, context);
718
+ contents = _json(data);
843
719
  const response = {
844
720
  $metadata: deserializeMetadata(output),
845
721
  ...contents,
846
722
  };
847
- return Promise.resolve(response);
723
+ return response;
848
724
  };
849
725
  const de_GetCostForecastCommandError = async (output, context) => {
850
726
  const parsedOutput = {
@@ -861,10 +737,9 @@ const de_GetCostForecastCommandError = async (output, context) => {
861
737
  throw await de_LimitExceededExceptionRes(parsedOutput, context);
862
738
  default:
863
739
  const parsedBody = parsedOutput.body;
864
- throwDefaultError({
740
+ return throwDefaultError({
865
741
  output,
866
742
  parsedBody,
867
- exceptionCtor: __BaseException,
868
743
  errorCode,
869
744
  });
870
745
  }
@@ -875,12 +750,12 @@ export const de_GetDimensionValuesCommand = async (output, context) => {
875
750
  }
876
751
  const data = await parseBody(output.body, context);
877
752
  let contents = {};
878
- contents = de_GetDimensionValuesResponse(data, context);
753
+ contents = _json(data);
879
754
  const response = {
880
755
  $metadata: deserializeMetadata(output),
881
756
  ...contents,
882
757
  };
883
- return Promise.resolve(response);
758
+ return response;
884
759
  };
885
760
  const de_GetDimensionValuesCommandError = async (output, context) => {
886
761
  const parsedOutput = {
@@ -906,10 +781,9 @@ const de_GetDimensionValuesCommandError = async (output, context) => {
906
781
  throw await de_RequestChangedExceptionRes(parsedOutput, context);
907
782
  default:
908
783
  const parsedBody = parsedOutput.body;
909
- throwDefaultError({
784
+ return throwDefaultError({
910
785
  output,
911
786
  parsedBody,
912
- exceptionCtor: __BaseException,
913
787
  errorCode,
914
788
  });
915
789
  }
@@ -920,12 +794,12 @@ export const de_GetReservationCoverageCommand = async (output, context) => {
920
794
  }
921
795
  const data = await parseBody(output.body, context);
922
796
  let contents = {};
923
- contents = de_GetReservationCoverageResponse(data, context);
797
+ contents = _json(data);
924
798
  const response = {
925
799
  $metadata: deserializeMetadata(output),
926
800
  ...contents,
927
801
  };
928
- return Promise.resolve(response);
802
+ return response;
929
803
  };
930
804
  const de_GetReservationCoverageCommandError = async (output, context) => {
931
805
  const parsedOutput = {
@@ -945,10 +819,9 @@ const de_GetReservationCoverageCommandError = async (output, context) => {
945
819
  throw await de_LimitExceededExceptionRes(parsedOutput, context);
946
820
  default:
947
821
  const parsedBody = parsedOutput.body;
948
- throwDefaultError({
822
+ return throwDefaultError({
949
823
  output,
950
824
  parsedBody,
951
- exceptionCtor: __BaseException,
952
825
  errorCode,
953
826
  });
954
827
  }
@@ -959,12 +832,12 @@ export const de_GetReservationPurchaseRecommendationCommand = async (output, con
959
832
  }
960
833
  const data = await parseBody(output.body, context);
961
834
  let contents = {};
962
- contents = de_GetReservationPurchaseRecommendationResponse(data, context);
835
+ contents = _json(data);
963
836
  const response = {
964
837
  $metadata: deserializeMetadata(output),
965
838
  ...contents,
966
839
  };
967
- return Promise.resolve(response);
840
+ return response;
968
841
  };
969
842
  const de_GetReservationPurchaseRecommendationCommandError = async (output, context) => {
970
843
  const parsedOutput = {
@@ -984,10 +857,9 @@ const de_GetReservationPurchaseRecommendationCommandError = async (output, conte
984
857
  throw await de_LimitExceededExceptionRes(parsedOutput, context);
985
858
  default:
986
859
  const parsedBody = parsedOutput.body;
987
- throwDefaultError({
860
+ return throwDefaultError({
988
861
  output,
989
862
  parsedBody,
990
- exceptionCtor: __BaseException,
991
863
  errorCode,
992
864
  });
993
865
  }
@@ -998,12 +870,12 @@ export const de_GetReservationUtilizationCommand = async (output, context) => {
998
870
  }
999
871
  const data = await parseBody(output.body, context);
1000
872
  let contents = {};
1001
- contents = de_GetReservationUtilizationResponse(data, context);
873
+ contents = _json(data);
1002
874
  const response = {
1003
875
  $metadata: deserializeMetadata(output),
1004
876
  ...contents,
1005
877
  };
1006
- return Promise.resolve(response);
878
+ return response;
1007
879
  };
1008
880
  const de_GetReservationUtilizationCommandError = async (output, context) => {
1009
881
  const parsedOutput = {
@@ -1023,10 +895,9 @@ const de_GetReservationUtilizationCommandError = async (output, context) => {
1023
895
  throw await de_LimitExceededExceptionRes(parsedOutput, context);
1024
896
  default:
1025
897
  const parsedBody = parsedOutput.body;
1026
- throwDefaultError({
898
+ return throwDefaultError({
1027
899
  output,
1028
900
  parsedBody,
1029
- exceptionCtor: __BaseException,
1030
901
  errorCode,
1031
902
  });
1032
903
  }
@@ -1037,12 +908,12 @@ export const de_GetRightsizingRecommendationCommand = async (output, context) =>
1037
908
  }
1038
909
  const data = await parseBody(output.body, context);
1039
910
  let contents = {};
1040
- contents = de_GetRightsizingRecommendationResponse(data, context);
911
+ contents = _json(data);
1041
912
  const response = {
1042
913
  $metadata: deserializeMetadata(output),
1043
914
  ...contents,
1044
915
  };
1045
- return Promise.resolve(response);
916
+ return response;
1046
917
  };
1047
918
  const de_GetRightsizingRecommendationCommandError = async (output, context) => {
1048
919
  const parsedOutput = {
@@ -1059,10 +930,9 @@ const de_GetRightsizingRecommendationCommandError = async (output, context) => {
1059
930
  throw await de_LimitExceededExceptionRes(parsedOutput, context);
1060
931
  default:
1061
932
  const parsedBody = parsedOutput.body;
1062
- throwDefaultError({
933
+ return throwDefaultError({
1063
934
  output,
1064
935
  parsedBody,
1065
- exceptionCtor: __BaseException,
1066
936
  errorCode,
1067
937
  });
1068
938
  }
@@ -1073,12 +943,12 @@ export const de_GetSavingsPlansCoverageCommand = async (output, context) => {
1073
943
  }
1074
944
  const data = await parseBody(output.body, context);
1075
945
  let contents = {};
1076
- contents = de_GetSavingsPlansCoverageResponse(data, context);
946
+ contents = _json(data);
1077
947
  const response = {
1078
948
  $metadata: deserializeMetadata(output),
1079
949
  ...contents,
1080
950
  };
1081
- return Promise.resolve(response);
951
+ return response;
1082
952
  };
1083
953
  const de_GetSavingsPlansCoverageCommandError = async (output, context) => {
1084
954
  const parsedOutput = {
@@ -1098,10 +968,9 @@ const de_GetSavingsPlansCoverageCommandError = async (output, context) => {
1098
968
  throw await de_LimitExceededExceptionRes(parsedOutput, context);
1099
969
  default:
1100
970
  const parsedBody = parsedOutput.body;
1101
- throwDefaultError({
971
+ return throwDefaultError({
1102
972
  output,
1103
973
  parsedBody,
1104
- exceptionCtor: __BaseException,
1105
974
  errorCode,
1106
975
  });
1107
976
  }
@@ -1112,12 +981,12 @@ export const de_GetSavingsPlansPurchaseRecommendationCommand = async (output, co
1112
981
  }
1113
982
  const data = await parseBody(output.body, context);
1114
983
  let contents = {};
1115
- contents = de_GetSavingsPlansPurchaseRecommendationResponse(data, context);
984
+ contents = _json(data);
1116
985
  const response = {
1117
986
  $metadata: deserializeMetadata(output),
1118
987
  ...contents,
1119
988
  };
1120
- return Promise.resolve(response);
989
+ return response;
1121
990
  };
1122
991
  const de_GetSavingsPlansPurchaseRecommendationCommandError = async (output, context) => {
1123
992
  const parsedOutput = {
@@ -1134,10 +1003,9 @@ const de_GetSavingsPlansPurchaseRecommendationCommandError = async (output, cont
1134
1003
  throw await de_LimitExceededExceptionRes(parsedOutput, context);
1135
1004
  default:
1136
1005
  const parsedBody = parsedOutput.body;
1137
- throwDefaultError({
1006
+ return throwDefaultError({
1138
1007
  output,
1139
1008
  parsedBody,
1140
- exceptionCtor: __BaseException,
1141
1009
  errorCode,
1142
1010
  });
1143
1011
  }
@@ -1148,12 +1016,12 @@ export const de_GetSavingsPlansUtilizationCommand = async (output, context) => {
1148
1016
  }
1149
1017
  const data = await parseBody(output.body, context);
1150
1018
  let contents = {};
1151
- contents = de_GetSavingsPlansUtilizationResponse(data, context);
1019
+ contents = _json(data);
1152
1020
  const response = {
1153
1021
  $metadata: deserializeMetadata(output),
1154
1022
  ...contents,
1155
1023
  };
1156
- return Promise.resolve(response);
1024
+ return response;
1157
1025
  };
1158
1026
  const de_GetSavingsPlansUtilizationCommandError = async (output, context) => {
1159
1027
  const parsedOutput = {
@@ -1170,10 +1038,9 @@ const de_GetSavingsPlansUtilizationCommandError = async (output, context) => {
1170
1038
  throw await de_LimitExceededExceptionRes(parsedOutput, context);
1171
1039
  default:
1172
1040
  const parsedBody = parsedOutput.body;
1173
- throwDefaultError({
1041
+ return throwDefaultError({
1174
1042
  output,
1175
1043
  parsedBody,
1176
- exceptionCtor: __BaseException,
1177
1044
  errorCode,
1178
1045
  });
1179
1046
  }
@@ -1184,12 +1051,12 @@ export const de_GetSavingsPlansUtilizationDetailsCommand = async (output, contex
1184
1051
  }
1185
1052
  const data = await parseBody(output.body, context);
1186
1053
  let contents = {};
1187
- contents = de_GetSavingsPlansUtilizationDetailsResponse(data, context);
1054
+ contents = _json(data);
1188
1055
  const response = {
1189
1056
  $metadata: deserializeMetadata(output),
1190
1057
  ...contents,
1191
1058
  };
1192
- return Promise.resolve(response);
1059
+ return response;
1193
1060
  };
1194
1061
  const de_GetSavingsPlansUtilizationDetailsCommandError = async (output, context) => {
1195
1062
  const parsedOutput = {
@@ -1209,10 +1076,9 @@ const de_GetSavingsPlansUtilizationDetailsCommandError = async (output, context)
1209
1076
  throw await de_LimitExceededExceptionRes(parsedOutput, context);
1210
1077
  default:
1211
1078
  const parsedBody = parsedOutput.body;
1212
- throwDefaultError({
1079
+ return throwDefaultError({
1213
1080
  output,
1214
1081
  parsedBody,
1215
- exceptionCtor: __BaseException,
1216
1082
  errorCode,
1217
1083
  });
1218
1084
  }
@@ -1223,12 +1089,12 @@ export const de_GetTagsCommand = async (output, context) => {
1223
1089
  }
1224
1090
  const data = await parseBody(output.body, context);
1225
1091
  let contents = {};
1226
- contents = de_GetTagsResponse(data, context);
1092
+ contents = _json(data);
1227
1093
  const response = {
1228
1094
  $metadata: deserializeMetadata(output),
1229
1095
  ...contents,
1230
1096
  };
1231
- return Promise.resolve(response);
1097
+ return response;
1232
1098
  };
1233
1099
  const de_GetTagsCommandError = async (output, context) => {
1234
1100
  const parsedOutput = {
@@ -1254,10 +1120,9 @@ const de_GetTagsCommandError = async (output, context) => {
1254
1120
  throw await de_RequestChangedExceptionRes(parsedOutput, context);
1255
1121
  default:
1256
1122
  const parsedBody = parsedOutput.body;
1257
- throwDefaultError({
1123
+ return throwDefaultError({
1258
1124
  output,
1259
1125
  parsedBody,
1260
- exceptionCtor: __BaseException,
1261
1126
  errorCode,
1262
1127
  });
1263
1128
  }
@@ -1268,12 +1133,12 @@ export const de_GetUsageForecastCommand = async (output, context) => {
1268
1133
  }
1269
1134
  const data = await parseBody(output.body, context);
1270
1135
  let contents = {};
1271
- contents = de_GetUsageForecastResponse(data, context);
1136
+ contents = _json(data);
1272
1137
  const response = {
1273
1138
  $metadata: deserializeMetadata(output),
1274
1139
  ...contents,
1275
1140
  };
1276
- return Promise.resolve(response);
1141
+ return response;
1277
1142
  };
1278
1143
  const de_GetUsageForecastCommandError = async (output, context) => {
1279
1144
  const parsedOutput = {
@@ -1293,10 +1158,9 @@ const de_GetUsageForecastCommandError = async (output, context) => {
1293
1158
  throw await de_UnresolvableUsageUnitExceptionRes(parsedOutput, context);
1294
1159
  default:
1295
1160
  const parsedBody = parsedOutput.body;
1296
- throwDefaultError({
1161
+ return throwDefaultError({
1297
1162
  output,
1298
1163
  parsedBody,
1299
- exceptionCtor: __BaseException,
1300
1164
  errorCode,
1301
1165
  });
1302
1166
  }
@@ -1307,12 +1171,12 @@ export const de_ListCostAllocationTagsCommand = async (output, context) => {
1307
1171
  }
1308
1172
  const data = await parseBody(output.body, context);
1309
1173
  let contents = {};
1310
- contents = de_ListCostAllocationTagsResponse(data, context);
1174
+ contents = _json(data);
1311
1175
  const response = {
1312
1176
  $metadata: deserializeMetadata(output),
1313
1177
  ...contents,
1314
1178
  };
1315
- return Promise.resolve(response);
1179
+ return response;
1316
1180
  };
1317
1181
  const de_ListCostAllocationTagsCommandError = async (output, context) => {
1318
1182
  const parsedOutput = {
@@ -1329,10 +1193,9 @@ const de_ListCostAllocationTagsCommandError = async (output, context) => {
1329
1193
  throw await de_LimitExceededExceptionRes(parsedOutput, context);
1330
1194
  default:
1331
1195
  const parsedBody = parsedOutput.body;
1332
- throwDefaultError({
1196
+ return throwDefaultError({
1333
1197
  output,
1334
1198
  parsedBody,
1335
- exceptionCtor: __BaseException,
1336
1199
  errorCode,
1337
1200
  });
1338
1201
  }
@@ -1343,12 +1206,12 @@ export const de_ListCostCategoryDefinitionsCommand = async (output, context) =>
1343
1206
  }
1344
1207
  const data = await parseBody(output.body, context);
1345
1208
  let contents = {};
1346
- contents = de_ListCostCategoryDefinitionsResponse(data, context);
1209
+ contents = _json(data);
1347
1210
  const response = {
1348
1211
  $metadata: deserializeMetadata(output),
1349
1212
  ...contents,
1350
1213
  };
1351
- return Promise.resolve(response);
1214
+ return response;
1352
1215
  };
1353
1216
  const de_ListCostCategoryDefinitionsCommandError = async (output, context) => {
1354
1217
  const parsedOutput = {
@@ -1362,10 +1225,9 @@ const de_ListCostCategoryDefinitionsCommandError = async (output, context) => {
1362
1225
  throw await de_LimitExceededExceptionRes(parsedOutput, context);
1363
1226
  default:
1364
1227
  const parsedBody = parsedOutput.body;
1365
- throwDefaultError({
1228
+ return throwDefaultError({
1366
1229
  output,
1367
1230
  parsedBody,
1368
- exceptionCtor: __BaseException,
1369
1231
  errorCode,
1370
1232
  });
1371
1233
  }
@@ -1376,12 +1238,12 @@ export const de_ListSavingsPlansPurchaseRecommendationGenerationCommand = async
1376
1238
  }
1377
1239
  const data = await parseBody(output.body, context);
1378
1240
  let contents = {};
1379
- contents = de_ListSavingsPlansPurchaseRecommendationGenerationResponse(data, context);
1241
+ contents = _json(data);
1380
1242
  const response = {
1381
1243
  $metadata: deserializeMetadata(output),
1382
1244
  ...contents,
1383
1245
  };
1384
- return Promise.resolve(response);
1246
+ return response;
1385
1247
  };
1386
1248
  const de_ListSavingsPlansPurchaseRecommendationGenerationCommandError = async (output, context) => {
1387
1249
  const parsedOutput = {
@@ -1398,10 +1260,9 @@ const de_ListSavingsPlansPurchaseRecommendationGenerationCommandError = async (o
1398
1260
  throw await de_LimitExceededExceptionRes(parsedOutput, context);
1399
1261
  default:
1400
1262
  const parsedBody = parsedOutput.body;
1401
- throwDefaultError({
1263
+ return throwDefaultError({
1402
1264
  output,
1403
1265
  parsedBody,
1404
- exceptionCtor: __BaseException,
1405
1266
  errorCode,
1406
1267
  });
1407
1268
  }
@@ -1412,12 +1273,12 @@ export const de_ListTagsForResourceCommand = async (output, context) => {
1412
1273
  }
1413
1274
  const data = await parseBody(output.body, context);
1414
1275
  let contents = {};
1415
- contents = de_ListTagsForResourceResponse(data, context);
1276
+ contents = _json(data);
1416
1277
  const response = {
1417
1278
  $metadata: deserializeMetadata(output),
1418
1279
  ...contents,
1419
1280
  };
1420
- return Promise.resolve(response);
1281
+ return response;
1421
1282
  };
1422
1283
  const de_ListTagsForResourceCommandError = async (output, context) => {
1423
1284
  const parsedOutput = {
@@ -1434,10 +1295,9 @@ const de_ListTagsForResourceCommandError = async (output, context) => {
1434
1295
  throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
1435
1296
  default:
1436
1297
  const parsedBody = parsedOutput.body;
1437
- throwDefaultError({
1298
+ return throwDefaultError({
1438
1299
  output,
1439
1300
  parsedBody,
1440
- exceptionCtor: __BaseException,
1441
1301
  errorCode,
1442
1302
  });
1443
1303
  }
@@ -1448,12 +1308,12 @@ export const de_ProvideAnomalyFeedbackCommand = async (output, context) => {
1448
1308
  }
1449
1309
  const data = await parseBody(output.body, context);
1450
1310
  let contents = {};
1451
- contents = de_ProvideAnomalyFeedbackResponse(data, context);
1311
+ contents = _json(data);
1452
1312
  const response = {
1453
1313
  $metadata: deserializeMetadata(output),
1454
1314
  ...contents,
1455
1315
  };
1456
- return Promise.resolve(response);
1316
+ return response;
1457
1317
  };
1458
1318
  const de_ProvideAnomalyFeedbackCommandError = async (output, context) => {
1459
1319
  const parsedOutput = {
@@ -1467,10 +1327,9 @@ const de_ProvideAnomalyFeedbackCommandError = async (output, context) => {
1467
1327
  throw await de_LimitExceededExceptionRes(parsedOutput, context);
1468
1328
  default:
1469
1329
  const parsedBody = parsedOutput.body;
1470
- throwDefaultError({
1330
+ return throwDefaultError({
1471
1331
  output,
1472
1332
  parsedBody,
1473
- exceptionCtor: __BaseException,
1474
1333
  errorCode,
1475
1334
  });
1476
1335
  }
@@ -1481,12 +1340,12 @@ export const de_StartSavingsPlansPurchaseRecommendationGenerationCommand = async
1481
1340
  }
1482
1341
  const data = await parseBody(output.body, context);
1483
1342
  let contents = {};
1484
- contents = de_StartSavingsPlansPurchaseRecommendationGenerationResponse(data, context);
1343
+ contents = _json(data);
1485
1344
  const response = {
1486
1345
  $metadata: deserializeMetadata(output),
1487
1346
  ...contents,
1488
1347
  };
1489
- return Promise.resolve(response);
1348
+ return response;
1490
1349
  };
1491
1350
  const de_StartSavingsPlansPurchaseRecommendationGenerationCommandError = async (output, context) => {
1492
1351
  const parsedOutput = {
@@ -1506,10 +1365,9 @@ const de_StartSavingsPlansPurchaseRecommendationGenerationCommandError = async (
1506
1365
  throw await de_ServiceQuotaExceededExceptionRes(parsedOutput, context);
1507
1366
  default:
1508
1367
  const parsedBody = parsedOutput.body;
1509
- throwDefaultError({
1368
+ return throwDefaultError({
1510
1369
  output,
1511
1370
  parsedBody,
1512
- exceptionCtor: __BaseException,
1513
1371
  errorCode,
1514
1372
  });
1515
1373
  }
@@ -1520,12 +1378,12 @@ export const de_TagResourceCommand = async (output, context) => {
1520
1378
  }
1521
1379
  const data = await parseBody(output.body, context);
1522
1380
  let contents = {};
1523
- contents = de_TagResourceResponse(data, context);
1381
+ contents = _json(data);
1524
1382
  const response = {
1525
1383
  $metadata: deserializeMetadata(output),
1526
1384
  ...contents,
1527
1385
  };
1528
- return Promise.resolve(response);
1386
+ return response;
1529
1387
  };
1530
1388
  const de_TagResourceCommandError = async (output, context) => {
1531
1389
  const parsedOutput = {
@@ -1545,10 +1403,9 @@ const de_TagResourceCommandError = async (output, context) => {
1545
1403
  throw await de_TooManyTagsExceptionRes(parsedOutput, context);
1546
1404
  default:
1547
1405
  const parsedBody = parsedOutput.body;
1548
- throwDefaultError({
1406
+ return throwDefaultError({
1549
1407
  output,
1550
1408
  parsedBody,
1551
- exceptionCtor: __BaseException,
1552
1409
  errorCode,
1553
1410
  });
1554
1411
  }
@@ -1559,12 +1416,12 @@ export const de_UntagResourceCommand = async (output, context) => {
1559
1416
  }
1560
1417
  const data = await parseBody(output.body, context);
1561
1418
  let contents = {};
1562
- contents = de_UntagResourceResponse(data, context);
1419
+ contents = _json(data);
1563
1420
  const response = {
1564
1421
  $metadata: deserializeMetadata(output),
1565
1422
  ...contents,
1566
1423
  };
1567
- return Promise.resolve(response);
1424
+ return response;
1568
1425
  };
1569
1426
  const de_UntagResourceCommandError = async (output, context) => {
1570
1427
  const parsedOutput = {
@@ -1581,10 +1438,9 @@ const de_UntagResourceCommandError = async (output, context) => {
1581
1438
  throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
1582
1439
  default:
1583
1440
  const parsedBody = parsedOutput.body;
1584
- throwDefaultError({
1441
+ return throwDefaultError({
1585
1442
  output,
1586
1443
  parsedBody,
1587
- exceptionCtor: __BaseException,
1588
1444
  errorCode,
1589
1445
  });
1590
1446
  }
@@ -1595,12 +1451,12 @@ export const de_UpdateAnomalyMonitorCommand = async (output, context) => {
1595
1451
  }
1596
1452
  const data = await parseBody(output.body, context);
1597
1453
  let contents = {};
1598
- contents = de_UpdateAnomalyMonitorResponse(data, context);
1454
+ contents = _json(data);
1599
1455
  const response = {
1600
1456
  $metadata: deserializeMetadata(output),
1601
1457
  ...contents,
1602
1458
  };
1603
- return Promise.resolve(response);
1459
+ return response;
1604
1460
  };
1605
1461
  const de_UpdateAnomalyMonitorCommandError = async (output, context) => {
1606
1462
  const parsedOutput = {
@@ -1617,10 +1473,9 @@ const de_UpdateAnomalyMonitorCommandError = async (output, context) => {
1617
1473
  throw await de_UnknownMonitorExceptionRes(parsedOutput, context);
1618
1474
  default:
1619
1475
  const parsedBody = parsedOutput.body;
1620
- throwDefaultError({
1476
+ return throwDefaultError({
1621
1477
  output,
1622
1478
  parsedBody,
1623
- exceptionCtor: __BaseException,
1624
1479
  errorCode,
1625
1480
  });
1626
1481
  }
@@ -1631,12 +1486,12 @@ export const de_UpdateAnomalySubscriptionCommand = async (output, context) => {
1631
1486
  }
1632
1487
  const data = await parseBody(output.body, context);
1633
1488
  let contents = {};
1634
- contents = de_UpdateAnomalySubscriptionResponse(data, context);
1489
+ contents = _json(data);
1635
1490
  const response = {
1636
1491
  $metadata: deserializeMetadata(output),
1637
1492
  ...contents,
1638
1493
  };
1639
- return Promise.resolve(response);
1494
+ return response;
1640
1495
  };
1641
1496
  const de_UpdateAnomalySubscriptionCommandError = async (output, context) => {
1642
1497
  const parsedOutput = {
@@ -1656,10 +1511,9 @@ const de_UpdateAnomalySubscriptionCommandError = async (output, context) => {
1656
1511
  throw await de_UnknownSubscriptionExceptionRes(parsedOutput, context);
1657
1512
  default:
1658
1513
  const parsedBody = parsedOutput.body;
1659
- throwDefaultError({
1514
+ return throwDefaultError({
1660
1515
  output,
1661
1516
  parsedBody,
1662
- exceptionCtor: __BaseException,
1663
1517
  errorCode,
1664
1518
  });
1665
1519
  }
@@ -1670,12 +1524,12 @@ export const de_UpdateCostAllocationTagsStatusCommand = async (output, context)
1670
1524
  }
1671
1525
  const data = await parseBody(output.body, context);
1672
1526
  let contents = {};
1673
- contents = de_UpdateCostAllocationTagsStatusResponse(data, context);
1527
+ contents = _json(data);
1674
1528
  const response = {
1675
1529
  $metadata: deserializeMetadata(output),
1676
1530
  ...contents,
1677
1531
  };
1678
- return Promise.resolve(response);
1532
+ return response;
1679
1533
  };
1680
1534
  const de_UpdateCostAllocationTagsStatusCommandError = async (output, context) => {
1681
1535
  const parsedOutput = {
@@ -1689,10 +1543,9 @@ const de_UpdateCostAllocationTagsStatusCommandError = async (output, context) =>
1689
1543
  throw await de_LimitExceededExceptionRes(parsedOutput, context);
1690
1544
  default:
1691
1545
  const parsedBody = parsedOutput.body;
1692
- throwDefaultError({
1546
+ return throwDefaultError({
1693
1547
  output,
1694
1548
  parsedBody,
1695
- exceptionCtor: __BaseException,
1696
1549
  errorCode,
1697
1550
  });
1698
1551
  }
@@ -1703,12 +1556,12 @@ export const de_UpdateCostCategoryDefinitionCommand = async (output, context) =>
1703
1556
  }
1704
1557
  const data = await parseBody(output.body, context);
1705
1558
  let contents = {};
1706
- contents = de_UpdateCostCategoryDefinitionResponse(data, context);
1559
+ contents = _json(data);
1707
1560
  const response = {
1708
1561
  $metadata: deserializeMetadata(output),
1709
1562
  ...contents,
1710
1563
  };
1711
- return Promise.resolve(response);
1564
+ return response;
1712
1565
  };
1713
1566
  const de_UpdateCostCategoryDefinitionCommandError = async (output, context) => {
1714
1567
  const parsedOutput = {
@@ -1728,17 +1581,16 @@ const de_UpdateCostCategoryDefinitionCommandError = async (output, context) => {
1728
1581
  throw await de_ServiceQuotaExceededExceptionRes(parsedOutput, context);
1729
1582
  default:
1730
1583
  const parsedBody = parsedOutput.body;
1731
- throwDefaultError({
1584
+ return throwDefaultError({
1732
1585
  output,
1733
1586
  parsedBody,
1734
- exceptionCtor: __BaseException,
1735
1587
  errorCode,
1736
1588
  });
1737
1589
  }
1738
1590
  };
1739
1591
  const de_BillExpirationExceptionRes = async (parsedOutput, context) => {
1740
1592
  const body = parsedOutput.body;
1741
- const deserialized = de_BillExpirationException(body, context);
1593
+ const deserialized = _json(body);
1742
1594
  const exception = new BillExpirationException({
1743
1595
  $metadata: deserializeMetadata(parsedOutput),
1744
1596
  ...deserialized,
@@ -1747,7 +1599,7 @@ const de_BillExpirationExceptionRes = async (parsedOutput, context) => {
1747
1599
  };
1748
1600
  const de_DataUnavailableExceptionRes = async (parsedOutput, context) => {
1749
1601
  const body = parsedOutput.body;
1750
- const deserialized = de_DataUnavailableException(body, context);
1602
+ const deserialized = _json(body);
1751
1603
  const exception = new DataUnavailableException({
1752
1604
  $metadata: deserializeMetadata(parsedOutput),
1753
1605
  ...deserialized,
@@ -1756,7 +1608,7 @@ const de_DataUnavailableExceptionRes = async (parsedOutput, context) => {
1756
1608
  };
1757
1609
  const de_GenerationExistsExceptionRes = async (parsedOutput, context) => {
1758
1610
  const body = parsedOutput.body;
1759
- const deserialized = de_GenerationExistsException(body, context);
1611
+ const deserialized = _json(body);
1760
1612
  const exception = new GenerationExistsException({
1761
1613
  $metadata: deserializeMetadata(parsedOutput),
1762
1614
  ...deserialized,
@@ -1765,7 +1617,7 @@ const de_GenerationExistsExceptionRes = async (parsedOutput, context) => {
1765
1617
  };
1766
1618
  const de_InvalidNextTokenExceptionRes = async (parsedOutput, context) => {
1767
1619
  const body = parsedOutput.body;
1768
- const deserialized = de_InvalidNextTokenException(body, context);
1620
+ const deserialized = _json(body);
1769
1621
  const exception = new InvalidNextTokenException({
1770
1622
  $metadata: deserializeMetadata(parsedOutput),
1771
1623
  ...deserialized,
@@ -1774,7 +1626,7 @@ const de_InvalidNextTokenExceptionRes = async (parsedOutput, context) => {
1774
1626
  };
1775
1627
  const de_LimitExceededExceptionRes = async (parsedOutput, context) => {
1776
1628
  const body = parsedOutput.body;
1777
- const deserialized = de_LimitExceededException(body, context);
1629
+ const deserialized = _json(body);
1778
1630
  const exception = new LimitExceededException({
1779
1631
  $metadata: deserializeMetadata(parsedOutput),
1780
1632
  ...deserialized,
@@ -1783,7 +1635,7 @@ const de_LimitExceededExceptionRes = async (parsedOutput, context) => {
1783
1635
  };
1784
1636
  const de_RequestChangedExceptionRes = async (parsedOutput, context) => {
1785
1637
  const body = parsedOutput.body;
1786
- const deserialized = de_RequestChangedException(body, context);
1638
+ const deserialized = _json(body);
1787
1639
  const exception = new RequestChangedException({
1788
1640
  $metadata: deserializeMetadata(parsedOutput),
1789
1641
  ...deserialized,
@@ -1792,7 +1644,7 @@ const de_RequestChangedExceptionRes = async (parsedOutput, context) => {
1792
1644
  };
1793
1645
  const de_ResourceNotFoundExceptionRes = async (parsedOutput, context) => {
1794
1646
  const body = parsedOutput.body;
1795
- const deserialized = de_ResourceNotFoundException(body, context);
1647
+ const deserialized = _json(body);
1796
1648
  const exception = new ResourceNotFoundException({
1797
1649
  $metadata: deserializeMetadata(parsedOutput),
1798
1650
  ...deserialized,
@@ -1801,7 +1653,7 @@ const de_ResourceNotFoundExceptionRes = async (parsedOutput, context) => {
1801
1653
  };
1802
1654
  const de_ServiceQuotaExceededExceptionRes = async (parsedOutput, context) => {
1803
1655
  const body = parsedOutput.body;
1804
- const deserialized = de_ServiceQuotaExceededException(body, context);
1656
+ const deserialized = _json(body);
1805
1657
  const exception = new ServiceQuotaExceededException({
1806
1658
  $metadata: deserializeMetadata(parsedOutput),
1807
1659
  ...deserialized,
@@ -1810,7 +1662,7 @@ const de_ServiceQuotaExceededExceptionRes = async (parsedOutput, context) => {
1810
1662
  };
1811
1663
  const de_TooManyTagsExceptionRes = async (parsedOutput, context) => {
1812
1664
  const body = parsedOutput.body;
1813
- const deserialized = de_TooManyTagsException(body, context);
1665
+ const deserialized = _json(body);
1814
1666
  const exception = new TooManyTagsException({
1815
1667
  $metadata: deserializeMetadata(parsedOutput),
1816
1668
  ...deserialized,
@@ -1819,7 +1671,7 @@ const de_TooManyTagsExceptionRes = async (parsedOutput, context) => {
1819
1671
  };
1820
1672
  const de_UnknownMonitorExceptionRes = async (parsedOutput, context) => {
1821
1673
  const body = parsedOutput.body;
1822
- const deserialized = de_UnknownMonitorException(body, context);
1674
+ const deserialized = _json(body);
1823
1675
  const exception = new UnknownMonitorException({
1824
1676
  $metadata: deserializeMetadata(parsedOutput),
1825
1677
  ...deserialized,
@@ -1828,7 +1680,7 @@ const de_UnknownMonitorExceptionRes = async (parsedOutput, context) => {
1828
1680
  };
1829
1681
  const de_UnknownSubscriptionExceptionRes = async (parsedOutput, context) => {
1830
1682
  const body = parsedOutput.body;
1831
- const deserialized = de_UnknownSubscriptionException(body, context);
1683
+ const deserialized = _json(body);
1832
1684
  const exception = new UnknownSubscriptionException({
1833
1685
  $metadata: deserializeMetadata(parsedOutput),
1834
1686
  ...deserialized,
@@ -1837,83 +1689,45 @@ const de_UnknownSubscriptionExceptionRes = async (parsedOutput, context) => {
1837
1689
  };
1838
1690
  const de_UnresolvableUsageUnitExceptionRes = async (parsedOutput, context) => {
1839
1691
  const body = parsedOutput.body;
1840
- const deserialized = de_UnresolvableUsageUnitException(body, context);
1692
+ const deserialized = _json(body);
1841
1693
  const exception = new UnresolvableUsageUnitException({
1842
1694
  $metadata: deserializeMetadata(parsedOutput),
1843
1695
  ...deserialized,
1844
1696
  });
1845
1697
  return __decorateServiceException(exception, body);
1846
1698
  };
1847
- const se_AnomalyDateInterval = (input, context) => {
1848
- return {
1849
- ...(input.EndDate != null && { EndDate: input.EndDate }),
1850
- ...(input.StartDate != null && { StartDate: input.StartDate }),
1851
- };
1852
- };
1853
1699
  const se_AnomalyMonitor = (input, context) => {
1854
- return {
1855
- ...(input.CreationDate != null && { CreationDate: input.CreationDate }),
1856
- ...(input.DimensionalValueCount != null && { DimensionalValueCount: input.DimensionalValueCount }),
1857
- ...(input.LastEvaluatedDate != null && { LastEvaluatedDate: input.LastEvaluatedDate }),
1858
- ...(input.LastUpdatedDate != null && { LastUpdatedDate: input.LastUpdatedDate }),
1859
- ...(input.MonitorArn != null && { MonitorArn: input.MonitorArn }),
1860
- ...(input.MonitorDimension != null && { MonitorDimension: input.MonitorDimension }),
1861
- ...(input.MonitorName != null && { MonitorName: input.MonitorName }),
1862
- ...(input.MonitorSpecification != null && {
1863
- MonitorSpecification: se_Expression(input.MonitorSpecification, context),
1864
- }),
1865
- ...(input.MonitorType != null && { MonitorType: input.MonitorType }),
1866
- };
1867
- };
1868
- const se_AnomalySubscription = (input, context) => {
1869
- return {
1870
- ...(input.AccountId != null && { AccountId: input.AccountId }),
1871
- ...(input.Frequency != null && { Frequency: input.Frequency }),
1872
- ...(input.MonitorArnList != null && { MonitorArnList: se_MonitorArnList(input.MonitorArnList, context) }),
1873
- ...(input.Subscribers != null && { Subscribers: se_Subscribers(input.Subscribers, context) }),
1874
- ...(input.SubscriptionArn != null && { SubscriptionArn: input.SubscriptionArn }),
1875
- ...(input.SubscriptionName != null && { SubscriptionName: input.SubscriptionName }),
1876
- ...(input.Threshold != null && { Threshold: __serializeFloat(input.Threshold) }),
1877
- ...(input.ThresholdExpression != null && {
1878
- ThresholdExpression: se_Expression(input.ThresholdExpression, context),
1879
- }),
1880
- };
1881
- };
1882
- const se_CostAllocationTagKeyList = (input, context) => {
1883
- return input
1884
- .filter((e) => e != null)
1885
- .map((entry) => {
1886
- return entry;
1700
+ return take(input, {
1701
+ CreationDate: [],
1702
+ DimensionalValueCount: [],
1703
+ LastEvaluatedDate: [],
1704
+ LastUpdatedDate: [],
1705
+ MonitorArn: [],
1706
+ MonitorDimension: [],
1707
+ MonitorName: [],
1708
+ MonitorSpecification: (_) => se_Expression(_, context),
1709
+ MonitorType: [],
1887
1710
  });
1888
1711
  };
1889
- const se_CostAllocationTagStatusEntry = (input, context) => {
1890
- return {
1891
- ...(input.Status != null && { Status: input.Status }),
1892
- ...(input.TagKey != null && { TagKey: input.TagKey }),
1893
- };
1894
- };
1895
- const se_CostAllocationTagStatusList = (input, context) => {
1896
- return input
1897
- .filter((e) => e != null)
1898
- .map((entry) => {
1899
- return se_CostAllocationTagStatusEntry(entry, context);
1712
+ const se_AnomalySubscription = (input, context) => {
1713
+ return take(input, {
1714
+ AccountId: [],
1715
+ Frequency: [],
1716
+ MonitorArnList: _json,
1717
+ Subscribers: _json,
1718
+ SubscriptionArn: [],
1719
+ SubscriptionName: [],
1720
+ Threshold: __serializeFloat,
1721
+ ThresholdExpression: (_) => se_Expression(_, context),
1900
1722
  });
1901
1723
  };
1902
- const se_CostCategoryInheritedValueDimension = (input, context) => {
1903
- return {
1904
- ...(input.DimensionKey != null && { DimensionKey: input.DimensionKey }),
1905
- ...(input.DimensionName != null && { DimensionName: input.DimensionName }),
1906
- };
1907
- };
1908
1724
  const se_CostCategoryRule = (input, context) => {
1909
- return {
1910
- ...(input.InheritedValue != null && {
1911
- InheritedValue: se_CostCategoryInheritedValueDimension(input.InheritedValue, context),
1912
- }),
1913
- ...(input.Rule != null && { Rule: se_Expression(input.Rule, context) }),
1914
- ...(input.Type != null && { Type: input.Type }),
1915
- ...(input.Value != null && { Value: input.Value }),
1916
- };
1725
+ return take(input, {
1726
+ InheritedValue: _json,
1727
+ Rule: (_) => se_Expression(_, context),
1728
+ Type: [],
1729
+ Value: [],
1730
+ });
1917
1731
  };
1918
1732
  const se_CostCategoryRulesList = (input, context) => {
1919
1733
  return input
@@ -1922,132 +1736,38 @@ const se_CostCategoryRulesList = (input, context) => {
1922
1736
  return se_CostCategoryRule(entry, context);
1923
1737
  });
1924
1738
  };
1925
- const se_CostCategorySplitChargeRule = (input, context) => {
1926
- return {
1927
- ...(input.Method != null && { Method: input.Method }),
1928
- ...(input.Parameters != null && {
1929
- Parameters: se_CostCategorySplitChargeRuleParametersList(input.Parameters, context),
1930
- }),
1931
- ...(input.Source != null && { Source: input.Source }),
1932
- ...(input.Targets != null && { Targets: se_CostCategorySplitChargeRuleTargetsList(input.Targets, context) }),
1933
- };
1934
- };
1935
- const se_CostCategorySplitChargeRuleParameter = (input, context) => {
1936
- return {
1937
- ...(input.Type != null && { Type: input.Type }),
1938
- ...(input.Values != null && { Values: se_CostCategorySplitChargeRuleParameterValuesList(input.Values, context) }),
1939
- };
1940
- };
1941
- const se_CostCategorySplitChargeRuleParametersList = (input, context) => {
1942
- return input
1943
- .filter((e) => e != null)
1944
- .map((entry) => {
1945
- return se_CostCategorySplitChargeRuleParameter(entry, context);
1946
- });
1947
- };
1948
- const se_CostCategorySplitChargeRuleParameterValuesList = (input, context) => {
1949
- return input
1950
- .filter((e) => e != null)
1951
- .map((entry) => {
1952
- return entry;
1953
- });
1954
- };
1955
- const se_CostCategorySplitChargeRulesList = (input, context) => {
1956
- return input
1957
- .filter((e) => e != null)
1958
- .map((entry) => {
1959
- return se_CostCategorySplitChargeRule(entry, context);
1960
- });
1961
- };
1962
- const se_CostCategorySplitChargeRuleTargetsList = (input, context) => {
1963
- return input
1964
- .filter((e) => e != null)
1965
- .map((entry) => {
1966
- return entry;
1967
- });
1968
- };
1969
- const se_CostCategoryValues = (input, context) => {
1970
- return {
1971
- ...(input.Key != null && { Key: input.Key }),
1972
- ...(input.MatchOptions != null && { MatchOptions: se_MatchOptions(input.MatchOptions, context) }),
1973
- ...(input.Values != null && { Values: se_Values(input.Values, context) }),
1974
- };
1975
- };
1976
1739
  const se_CreateAnomalyMonitorRequest = (input, context) => {
1977
- return {
1978
- ...(input.AnomalyMonitor != null && { AnomalyMonitor: se_AnomalyMonitor(input.AnomalyMonitor, context) }),
1979
- ...(input.ResourceTags != null && { ResourceTags: se_ResourceTagList(input.ResourceTags, context) }),
1980
- };
1740
+ return take(input, {
1741
+ AnomalyMonitor: (_) => se_AnomalyMonitor(_, context),
1742
+ ResourceTags: _json,
1743
+ });
1981
1744
  };
1982
1745
  const se_CreateAnomalySubscriptionRequest = (input, context) => {
1983
- return {
1984
- ...(input.AnomalySubscription != null && {
1985
- AnomalySubscription: se_AnomalySubscription(input.AnomalySubscription, context),
1986
- }),
1987
- ...(input.ResourceTags != null && { ResourceTags: se_ResourceTagList(input.ResourceTags, context) }),
1988
- };
1746
+ return take(input, {
1747
+ AnomalySubscription: (_) => se_AnomalySubscription(_, context),
1748
+ ResourceTags: _json,
1749
+ });
1989
1750
  };
1990
1751
  const se_CreateCostCategoryDefinitionRequest = (input, context) => {
1991
- return {
1992
- ...(input.DefaultValue != null && { DefaultValue: input.DefaultValue }),
1993
- ...(input.EffectiveStart != null && { EffectiveStart: input.EffectiveStart }),
1994
- ...(input.Name != null && { Name: input.Name }),
1995
- ...(input.ResourceTags != null && { ResourceTags: se_ResourceTagList(input.ResourceTags, context) }),
1996
- ...(input.RuleVersion != null && { RuleVersion: input.RuleVersion }),
1997
- ...(input.Rules != null && { Rules: se_CostCategoryRulesList(input.Rules, context) }),
1998
- ...(input.SplitChargeRules != null && {
1999
- SplitChargeRules: se_CostCategorySplitChargeRulesList(input.SplitChargeRules, context),
2000
- }),
2001
- };
2002
- };
2003
- const se_DateInterval = (input, context) => {
2004
- return {
2005
- ...(input.End != null && { End: input.End }),
2006
- ...(input.Start != null && { Start: input.Start }),
2007
- };
2008
- };
2009
- const se_DeleteAnomalyMonitorRequest = (input, context) => {
2010
- return {
2011
- ...(input.MonitorArn != null && { MonitorArn: input.MonitorArn }),
2012
- };
2013
- };
2014
- const se_DeleteAnomalySubscriptionRequest = (input, context) => {
2015
- return {
2016
- ...(input.SubscriptionArn != null && { SubscriptionArn: input.SubscriptionArn }),
2017
- };
2018
- };
2019
- const se_DeleteCostCategoryDefinitionRequest = (input, context) => {
2020
- return {
2021
- ...(input.CostCategoryArn != null && { CostCategoryArn: input.CostCategoryArn }),
2022
- };
2023
- };
2024
- const se_DescribeCostCategoryDefinitionRequest = (input, context) => {
2025
- return {
2026
- ...(input.CostCategoryArn != null && { CostCategoryArn: input.CostCategoryArn }),
2027
- ...(input.EffectiveOn != null && { EffectiveOn: input.EffectiveOn }),
2028
- };
2029
- };
2030
- const se_DimensionValues = (input, context) => {
2031
- return {
2032
- ...(input.Key != null && { Key: input.Key }),
2033
- ...(input.MatchOptions != null && { MatchOptions: se_MatchOptions(input.MatchOptions, context) }),
2034
- ...(input.Values != null && { Values: se_Values(input.Values, context) }),
2035
- };
2036
- };
2037
- const se_EC2Specification = (input, context) => {
2038
- return {
2039
- ...(input.OfferingClass != null && { OfferingClass: input.OfferingClass }),
2040
- };
1752
+ return take(input, {
1753
+ DefaultValue: [],
1754
+ EffectiveStart: [],
1755
+ Name: [],
1756
+ ResourceTags: _json,
1757
+ RuleVersion: [],
1758
+ Rules: (_) => se_CostCategoryRulesList(_, context),
1759
+ SplitChargeRules: _json,
1760
+ });
2041
1761
  };
2042
1762
  const se_Expression = (input, context) => {
2043
- return {
2044
- ...(input.And != null && { And: se_Expressions(input.And, context) }),
2045
- ...(input.CostCategories != null && { CostCategories: se_CostCategoryValues(input.CostCategories, context) }),
2046
- ...(input.Dimensions != null && { Dimensions: se_DimensionValues(input.Dimensions, context) }),
2047
- ...(input.Not != null && { Not: se_Expression(input.Not, context) }),
2048
- ...(input.Or != null && { Or: se_Expressions(input.Or, context) }),
2049
- ...(input.Tags != null && { Tags: se_TagValues(input.Tags, context) }),
2050
- };
1763
+ return take(input, {
1764
+ And: (_) => se_Expressions(_, context),
1765
+ CostCategories: _json,
1766
+ Dimensions: _json,
1767
+ Not: (_) => se_Expression(_, context),
1768
+ Or: (_) => se_Expressions(_, context),
1769
+ Tags: _json,
1770
+ });
2051
1771
  };
2052
1772
  const se_Expressions = (input, context) => {
2053
1773
  return input
@@ -2057,1943 +1777,349 @@ const se_Expressions = (input, context) => {
2057
1777
  });
2058
1778
  };
2059
1779
  const se_GetAnomaliesRequest = (input, context) => {
2060
- return {
2061
- ...(input.DateInterval != null && { DateInterval: se_AnomalyDateInterval(input.DateInterval, context) }),
2062
- ...(input.Feedback != null && { Feedback: input.Feedback }),
2063
- ...(input.MaxResults != null && { MaxResults: input.MaxResults }),
2064
- ...(input.MonitorArn != null && { MonitorArn: input.MonitorArn }),
2065
- ...(input.NextPageToken != null && { NextPageToken: input.NextPageToken }),
2066
- ...(input.TotalImpact != null && { TotalImpact: se_TotalImpactFilter(input.TotalImpact, context) }),
2067
- };
2068
- };
2069
- const se_GetAnomalyMonitorsRequest = (input, context) => {
2070
- return {
2071
- ...(input.MaxResults != null && { MaxResults: input.MaxResults }),
2072
- ...(input.MonitorArnList != null && { MonitorArnList: se_Values(input.MonitorArnList, context) }),
2073
- ...(input.NextPageToken != null && { NextPageToken: input.NextPageToken }),
2074
- };
2075
- };
2076
- const se_GetAnomalySubscriptionsRequest = (input, context) => {
2077
- return {
2078
- ...(input.MaxResults != null && { MaxResults: input.MaxResults }),
2079
- ...(input.MonitorArn != null && { MonitorArn: input.MonitorArn }),
2080
- ...(input.NextPageToken != null && { NextPageToken: input.NextPageToken }),
2081
- ...(input.SubscriptionArnList != null && { SubscriptionArnList: se_Values(input.SubscriptionArnList, context) }),
2082
- };
1780
+ return take(input, {
1781
+ DateInterval: _json,
1782
+ Feedback: [],
1783
+ MaxResults: [],
1784
+ MonitorArn: [],
1785
+ NextPageToken: [],
1786
+ TotalImpact: (_) => se_TotalImpactFilter(_, context),
1787
+ });
2083
1788
  };
2084
1789
  const se_GetCostAndUsageRequest = (input, context) => {
2085
- return {
2086
- ...(input.Filter != null && { Filter: se_Expression(input.Filter, context) }),
2087
- ...(input.Granularity != null && { Granularity: input.Granularity }),
2088
- ...(input.GroupBy != null && { GroupBy: se_GroupDefinitions(input.GroupBy, context) }),
2089
- ...(input.Metrics != null && { Metrics: se_MetricNames(input.Metrics, context) }),
2090
- ...(input.NextPageToken != null && { NextPageToken: input.NextPageToken }),
2091
- ...(input.TimePeriod != null && { TimePeriod: se_DateInterval(input.TimePeriod, context) }),
2092
- };
1790
+ return take(input, {
1791
+ Filter: (_) => se_Expression(_, context),
1792
+ Granularity: [],
1793
+ GroupBy: _json,
1794
+ Metrics: _json,
1795
+ NextPageToken: [],
1796
+ TimePeriod: _json,
1797
+ });
2093
1798
  };
2094
1799
  const se_GetCostAndUsageWithResourcesRequest = (input, context) => {
2095
- return {
2096
- ...(input.Filter != null && { Filter: se_Expression(input.Filter, context) }),
2097
- ...(input.Granularity != null && { Granularity: input.Granularity }),
2098
- ...(input.GroupBy != null && { GroupBy: se_GroupDefinitions(input.GroupBy, context) }),
2099
- ...(input.Metrics != null && { Metrics: se_MetricNames(input.Metrics, context) }),
2100
- ...(input.NextPageToken != null && { NextPageToken: input.NextPageToken }),
2101
- ...(input.TimePeriod != null && { TimePeriod: se_DateInterval(input.TimePeriod, context) }),
2102
- };
1800
+ return take(input, {
1801
+ Filter: (_) => se_Expression(_, context),
1802
+ Granularity: [],
1803
+ GroupBy: _json,
1804
+ Metrics: _json,
1805
+ NextPageToken: [],
1806
+ TimePeriod: _json,
1807
+ });
2103
1808
  };
2104
1809
  const se_GetCostCategoriesRequest = (input, context) => {
2105
- return {
2106
- ...(input.CostCategoryName != null && { CostCategoryName: input.CostCategoryName }),
2107
- ...(input.Filter != null && { Filter: se_Expression(input.Filter, context) }),
2108
- ...(input.MaxResults != null && { MaxResults: input.MaxResults }),
2109
- ...(input.NextPageToken != null && { NextPageToken: input.NextPageToken }),
2110
- ...(input.SearchString != null && { SearchString: input.SearchString }),
2111
- ...(input.SortBy != null && { SortBy: se_SortDefinitions(input.SortBy, context) }),
2112
- ...(input.TimePeriod != null && { TimePeriod: se_DateInterval(input.TimePeriod, context) }),
2113
- };
1810
+ return take(input, {
1811
+ CostCategoryName: [],
1812
+ Filter: (_) => se_Expression(_, context),
1813
+ MaxResults: [],
1814
+ NextPageToken: [],
1815
+ SearchString: [],
1816
+ SortBy: _json,
1817
+ TimePeriod: _json,
1818
+ });
2114
1819
  };
2115
1820
  const se_GetCostForecastRequest = (input, context) => {
2116
- return {
2117
- ...(input.Filter != null && { Filter: se_Expression(input.Filter, context) }),
2118
- ...(input.Granularity != null && { Granularity: input.Granularity }),
2119
- ...(input.Metric != null && { Metric: input.Metric }),
2120
- ...(input.PredictionIntervalLevel != null && { PredictionIntervalLevel: input.PredictionIntervalLevel }),
2121
- ...(input.TimePeriod != null && { TimePeriod: se_DateInterval(input.TimePeriod, context) }),
2122
- };
1821
+ return take(input, {
1822
+ Filter: (_) => se_Expression(_, context),
1823
+ Granularity: [],
1824
+ Metric: [],
1825
+ PredictionIntervalLevel: [],
1826
+ TimePeriod: _json,
1827
+ });
2123
1828
  };
2124
1829
  const se_GetDimensionValuesRequest = (input, context) => {
2125
- return {
2126
- ...(input.Context != null && { Context: input.Context }),
2127
- ...(input.Dimension != null && { Dimension: input.Dimension }),
2128
- ...(input.Filter != null && { Filter: se_Expression(input.Filter, context) }),
2129
- ...(input.MaxResults != null && { MaxResults: input.MaxResults }),
2130
- ...(input.NextPageToken != null && { NextPageToken: input.NextPageToken }),
2131
- ...(input.SearchString != null && { SearchString: input.SearchString }),
2132
- ...(input.SortBy != null && { SortBy: se_SortDefinitions(input.SortBy, context) }),
2133
- ...(input.TimePeriod != null && { TimePeriod: se_DateInterval(input.TimePeriod, context) }),
2134
- };
1830
+ return take(input, {
1831
+ Context: [],
1832
+ Dimension: [],
1833
+ Filter: (_) => se_Expression(_, context),
1834
+ MaxResults: [],
1835
+ NextPageToken: [],
1836
+ SearchString: [],
1837
+ SortBy: _json,
1838
+ TimePeriod: _json,
1839
+ });
2135
1840
  };
2136
1841
  const se_GetReservationCoverageRequest = (input, context) => {
2137
- return {
2138
- ...(input.Filter != null && { Filter: se_Expression(input.Filter, context) }),
2139
- ...(input.Granularity != null && { Granularity: input.Granularity }),
2140
- ...(input.GroupBy != null && { GroupBy: se_GroupDefinitions(input.GroupBy, context) }),
2141
- ...(input.MaxResults != null && { MaxResults: input.MaxResults }),
2142
- ...(input.Metrics != null && { Metrics: se_MetricNames(input.Metrics, context) }),
2143
- ...(input.NextPageToken != null && { NextPageToken: input.NextPageToken }),
2144
- ...(input.SortBy != null && { SortBy: se_SortDefinition(input.SortBy, context) }),
2145
- ...(input.TimePeriod != null && { TimePeriod: se_DateInterval(input.TimePeriod, context) }),
2146
- };
1842
+ return take(input, {
1843
+ Filter: (_) => se_Expression(_, context),
1844
+ Granularity: [],
1845
+ GroupBy: _json,
1846
+ MaxResults: [],
1847
+ Metrics: _json,
1848
+ NextPageToken: [],
1849
+ SortBy: _json,
1850
+ TimePeriod: _json,
1851
+ });
2147
1852
  };
2148
1853
  const se_GetReservationPurchaseRecommendationRequest = (input, context) => {
2149
- return {
2150
- ...(input.AccountId != null && { AccountId: input.AccountId }),
2151
- ...(input.AccountScope != null && { AccountScope: input.AccountScope }),
2152
- ...(input.Filter != null && { Filter: se_Expression(input.Filter, context) }),
2153
- ...(input.LookbackPeriodInDays != null && { LookbackPeriodInDays: input.LookbackPeriodInDays }),
2154
- ...(input.NextPageToken != null && { NextPageToken: input.NextPageToken }),
2155
- ...(input.PageSize != null && { PageSize: input.PageSize }),
2156
- ...(input.PaymentOption != null && { PaymentOption: input.PaymentOption }),
2157
- ...(input.Service != null && { Service: input.Service }),
2158
- ...(input.ServiceSpecification != null && {
2159
- ServiceSpecification: se_ServiceSpecification(input.ServiceSpecification, context),
2160
- }),
2161
- ...(input.TermInYears != null && { TermInYears: input.TermInYears }),
2162
- };
1854
+ return take(input, {
1855
+ AccountId: [],
1856
+ AccountScope: [],
1857
+ Filter: (_) => se_Expression(_, context),
1858
+ LookbackPeriodInDays: [],
1859
+ NextPageToken: [],
1860
+ PageSize: [],
1861
+ PaymentOption: [],
1862
+ Service: [],
1863
+ ServiceSpecification: _json,
1864
+ TermInYears: [],
1865
+ });
2163
1866
  };
2164
1867
  const se_GetReservationUtilizationRequest = (input, context) => {
2165
- return {
2166
- ...(input.Filter != null && { Filter: se_Expression(input.Filter, context) }),
2167
- ...(input.Granularity != null && { Granularity: input.Granularity }),
2168
- ...(input.GroupBy != null && { GroupBy: se_GroupDefinitions(input.GroupBy, context) }),
2169
- ...(input.MaxResults != null && { MaxResults: input.MaxResults }),
2170
- ...(input.NextPageToken != null && { NextPageToken: input.NextPageToken }),
2171
- ...(input.SortBy != null && { SortBy: se_SortDefinition(input.SortBy, context) }),
2172
- ...(input.TimePeriod != null && { TimePeriod: se_DateInterval(input.TimePeriod, context) }),
2173
- };
1868
+ return take(input, {
1869
+ Filter: (_) => se_Expression(_, context),
1870
+ Granularity: [],
1871
+ GroupBy: _json,
1872
+ MaxResults: [],
1873
+ NextPageToken: [],
1874
+ SortBy: _json,
1875
+ TimePeriod: _json,
1876
+ });
2174
1877
  };
2175
1878
  const se_GetRightsizingRecommendationRequest = (input, context) => {
2176
- return {
2177
- ...(input.Configuration != null && {
2178
- Configuration: se_RightsizingRecommendationConfiguration(input.Configuration, context),
2179
- }),
2180
- ...(input.Filter != null && { Filter: se_Expression(input.Filter, context) }),
2181
- ...(input.NextPageToken != null && { NextPageToken: input.NextPageToken }),
2182
- ...(input.PageSize != null && { PageSize: input.PageSize }),
2183
- ...(input.Service != null && { Service: input.Service }),
2184
- };
1879
+ return take(input, {
1880
+ Configuration: _json,
1881
+ Filter: (_) => se_Expression(_, context),
1882
+ NextPageToken: [],
1883
+ PageSize: [],
1884
+ Service: [],
1885
+ });
2185
1886
  };
2186
1887
  const se_GetSavingsPlansCoverageRequest = (input, context) => {
2187
- return {
2188
- ...(input.Filter != null && { Filter: se_Expression(input.Filter, context) }),
2189
- ...(input.Granularity != null && { Granularity: input.Granularity }),
2190
- ...(input.GroupBy != null && { GroupBy: se_GroupDefinitions(input.GroupBy, context) }),
2191
- ...(input.MaxResults != null && { MaxResults: input.MaxResults }),
2192
- ...(input.Metrics != null && { Metrics: se_MetricNames(input.Metrics, context) }),
2193
- ...(input.NextToken != null && { NextToken: input.NextToken }),
2194
- ...(input.SortBy != null && { SortBy: se_SortDefinition(input.SortBy, context) }),
2195
- ...(input.TimePeriod != null && { TimePeriod: se_DateInterval(input.TimePeriod, context) }),
2196
- };
1888
+ return take(input, {
1889
+ Filter: (_) => se_Expression(_, context),
1890
+ Granularity: [],
1891
+ GroupBy: _json,
1892
+ MaxResults: [],
1893
+ Metrics: _json,
1894
+ NextToken: [],
1895
+ SortBy: _json,
1896
+ TimePeriod: _json,
1897
+ });
2197
1898
  };
2198
1899
  const se_GetSavingsPlansPurchaseRecommendationRequest = (input, context) => {
2199
- return {
2200
- ...(input.AccountScope != null && { AccountScope: input.AccountScope }),
2201
- ...(input.Filter != null && { Filter: se_Expression(input.Filter, context) }),
2202
- ...(input.LookbackPeriodInDays != null && { LookbackPeriodInDays: input.LookbackPeriodInDays }),
2203
- ...(input.NextPageToken != null && { NextPageToken: input.NextPageToken }),
2204
- ...(input.PageSize != null && { PageSize: input.PageSize }),
2205
- ...(input.PaymentOption != null && { PaymentOption: input.PaymentOption }),
2206
- ...(input.SavingsPlansType != null && { SavingsPlansType: input.SavingsPlansType }),
2207
- ...(input.TermInYears != null && { TermInYears: input.TermInYears }),
2208
- };
1900
+ return take(input, {
1901
+ AccountScope: [],
1902
+ Filter: (_) => se_Expression(_, context),
1903
+ LookbackPeriodInDays: [],
1904
+ NextPageToken: [],
1905
+ PageSize: [],
1906
+ PaymentOption: [],
1907
+ SavingsPlansType: [],
1908
+ TermInYears: [],
1909
+ });
2209
1910
  };
2210
1911
  const se_GetSavingsPlansUtilizationDetailsRequest = (input, context) => {
2211
- return {
2212
- ...(input.DataType != null && { DataType: se_SavingsPlansDataTypes(input.DataType, context) }),
2213
- ...(input.Filter != null && { Filter: se_Expression(input.Filter, context) }),
2214
- ...(input.MaxResults != null && { MaxResults: input.MaxResults }),
2215
- ...(input.NextToken != null && { NextToken: input.NextToken }),
2216
- ...(input.SortBy != null && { SortBy: se_SortDefinition(input.SortBy, context) }),
2217
- ...(input.TimePeriod != null && { TimePeriod: se_DateInterval(input.TimePeriod, context) }),
2218
- };
1912
+ return take(input, {
1913
+ DataType: _json,
1914
+ Filter: (_) => se_Expression(_, context),
1915
+ MaxResults: [],
1916
+ NextToken: [],
1917
+ SortBy: _json,
1918
+ TimePeriod: _json,
1919
+ });
2219
1920
  };
2220
1921
  const se_GetSavingsPlansUtilizationRequest = (input, context) => {
2221
- return {
2222
- ...(input.Filter != null && { Filter: se_Expression(input.Filter, context) }),
2223
- ...(input.Granularity != null && { Granularity: input.Granularity }),
2224
- ...(input.SortBy != null && { SortBy: se_SortDefinition(input.SortBy, context) }),
2225
- ...(input.TimePeriod != null && { TimePeriod: se_DateInterval(input.TimePeriod, context) }),
2226
- };
1922
+ return take(input, {
1923
+ Filter: (_) => se_Expression(_, context),
1924
+ Granularity: [],
1925
+ SortBy: _json,
1926
+ TimePeriod: _json,
1927
+ });
2227
1928
  };
2228
1929
  const se_GetTagsRequest = (input, context) => {
2229
- return {
2230
- ...(input.Filter != null && { Filter: se_Expression(input.Filter, context) }),
2231
- ...(input.MaxResults != null && { MaxResults: input.MaxResults }),
2232
- ...(input.NextPageToken != null && { NextPageToken: input.NextPageToken }),
2233
- ...(input.SearchString != null && { SearchString: input.SearchString }),
2234
- ...(input.SortBy != null && { SortBy: se_SortDefinitions(input.SortBy, context) }),
2235
- ...(input.TagKey != null && { TagKey: input.TagKey }),
2236
- ...(input.TimePeriod != null && { TimePeriod: se_DateInterval(input.TimePeriod, context) }),
2237
- };
1930
+ return take(input, {
1931
+ Filter: (_) => se_Expression(_, context),
1932
+ MaxResults: [],
1933
+ NextPageToken: [],
1934
+ SearchString: [],
1935
+ SortBy: _json,
1936
+ TagKey: [],
1937
+ TimePeriod: _json,
1938
+ });
2238
1939
  };
2239
1940
  const se_GetUsageForecastRequest = (input, context) => {
2240
- return {
2241
- ...(input.Filter != null && { Filter: se_Expression(input.Filter, context) }),
2242
- ...(input.Granularity != null && { Granularity: input.Granularity }),
2243
- ...(input.Metric != null && { Metric: input.Metric }),
2244
- ...(input.PredictionIntervalLevel != null && { PredictionIntervalLevel: input.PredictionIntervalLevel }),
2245
- ...(input.TimePeriod != null && { TimePeriod: se_DateInterval(input.TimePeriod, context) }),
2246
- };
2247
- };
2248
- const se_GroupDefinition = (input, context) => {
2249
- return {
2250
- ...(input.Key != null && { Key: input.Key }),
2251
- ...(input.Type != null && { Type: input.Type }),
2252
- };
2253
- };
2254
- const se_GroupDefinitions = (input, context) => {
2255
- return input
2256
- .filter((e) => e != null)
2257
- .map((entry) => {
2258
- return se_GroupDefinition(entry, context);
1941
+ return take(input, {
1942
+ Filter: (_) => se_Expression(_, context),
1943
+ Granularity: [],
1944
+ Metric: [],
1945
+ PredictionIntervalLevel: [],
1946
+ TimePeriod: _json,
2259
1947
  });
2260
1948
  };
2261
- const se_ListCostAllocationTagsRequest = (input, context) => {
2262
- return {
2263
- ...(input.MaxResults != null && { MaxResults: input.MaxResults }),
2264
- ...(input.NextToken != null && { NextToken: input.NextToken }),
2265
- ...(input.Status != null && { Status: input.Status }),
2266
- ...(input.TagKeys != null && { TagKeys: se_CostAllocationTagKeyList(input.TagKeys, context) }),
2267
- ...(input.Type != null && { Type: input.Type }),
2268
- };
2269
- };
2270
- const se_ListCostCategoryDefinitionsRequest = (input, context) => {
2271
- return {
2272
- ...(input.EffectiveOn != null && { EffectiveOn: input.EffectiveOn }),
2273
- ...(input.MaxResults != null && { MaxResults: input.MaxResults }),
2274
- ...(input.NextToken != null && { NextToken: input.NextToken }),
2275
- };
2276
- };
2277
- const se_ListSavingsPlansPurchaseRecommendationGenerationRequest = (input, context) => {
2278
- return {
2279
- ...(input.GenerationStatus != null && { GenerationStatus: input.GenerationStatus }),
2280
- ...(input.NextPageToken != null && { NextPageToken: input.NextPageToken }),
2281
- ...(input.PageSize != null && { PageSize: input.PageSize }),
2282
- ...(input.RecommendationIds != null && {
2283
- RecommendationIds: se_RecommendationIdList(input.RecommendationIds, context),
2284
- }),
2285
- };
1949
+ const se_TotalImpactFilter = (input, context) => {
1950
+ return take(input, {
1951
+ EndValue: __serializeFloat,
1952
+ NumericOperator: [],
1953
+ StartValue: __serializeFloat,
1954
+ });
2286
1955
  };
2287
- const se_ListTagsForResourceRequest = (input, context) => {
2288
- return {
2289
- ...(input.ResourceArn != null && { ResourceArn: input.ResourceArn }),
2290
- };
1956
+ const se_UpdateAnomalySubscriptionRequest = (input, context) => {
1957
+ return take(input, {
1958
+ Frequency: [],
1959
+ MonitorArnList: _json,
1960
+ Subscribers: _json,
1961
+ SubscriptionArn: [],
1962
+ SubscriptionName: [],
1963
+ Threshold: __serializeFloat,
1964
+ ThresholdExpression: (_) => se_Expression(_, context),
1965
+ });
2291
1966
  };
2292
- const se_MatchOptions = (input, context) => {
2293
- return input
2294
- .filter((e) => e != null)
2295
- .map((entry) => {
2296
- return entry;
1967
+ const se_UpdateCostCategoryDefinitionRequest = (input, context) => {
1968
+ return take(input, {
1969
+ CostCategoryArn: [],
1970
+ DefaultValue: [],
1971
+ EffectiveStart: [],
1972
+ RuleVersion: [],
1973
+ Rules: (_) => se_CostCategoryRulesList(_, context),
1974
+ SplitChargeRules: _json,
2297
1975
  });
2298
1976
  };
2299
- const se_MetricNames = (input, context) => {
2300
- return input
1977
+ const de_Anomalies = (output, context) => {
1978
+ const retVal = (output || [])
2301
1979
  .filter((e) => e != null)
2302
1980
  .map((entry) => {
2303
- return entry;
1981
+ return de_Anomaly(entry, context);
2304
1982
  });
1983
+ return retVal;
2305
1984
  };
2306
- const se_MonitorArnList = (input, context) => {
2307
- return input
2308
- .filter((e) => e != null)
2309
- .map((entry) => {
2310
- return entry;
1985
+ const de_Anomaly = (output, context) => {
1986
+ return take(output, {
1987
+ AnomalyEndDate: __expectString,
1988
+ AnomalyId: __expectString,
1989
+ AnomalyScore: (_) => de_AnomalyScore(_, context),
1990
+ AnomalyStartDate: __expectString,
1991
+ DimensionValue: __expectString,
1992
+ Feedback: __expectString,
1993
+ Impact: (_) => de_Impact(_, context),
1994
+ MonitorArn: __expectString,
1995
+ RootCauses: _json,
2311
1996
  });
2312
1997
  };
2313
- const se_ProvideAnomalyFeedbackRequest = (input, context) => {
2314
- return {
2315
- ...(input.AnomalyId != null && { AnomalyId: input.AnomalyId }),
2316
- ...(input.Feedback != null && { Feedback: input.Feedback }),
2317
- };
1998
+ const de_AnomalyMonitor = (output, context) => {
1999
+ return take(output, {
2000
+ CreationDate: __expectString,
2001
+ DimensionalValueCount: __expectInt32,
2002
+ LastEvaluatedDate: __expectString,
2003
+ LastUpdatedDate: __expectString,
2004
+ MonitorArn: __expectString,
2005
+ MonitorDimension: __expectString,
2006
+ MonitorName: __expectString,
2007
+ MonitorSpecification: (_) => de_Expression(_, context),
2008
+ MonitorType: __expectString,
2009
+ });
2318
2010
  };
2319
- const se_RecommendationIdList = (input, context) => {
2320
- return input
2011
+ const de_AnomalyMonitors = (output, context) => {
2012
+ const retVal = (output || [])
2321
2013
  .filter((e) => e != null)
2322
2014
  .map((entry) => {
2323
- return entry;
2015
+ return de_AnomalyMonitor(entry, context);
2324
2016
  });
2017
+ return retVal;
2325
2018
  };
2326
- const se_ResourceTag = (input, context) => {
2327
- return {
2328
- ...(input.Key != null && { Key: input.Key }),
2329
- ...(input.Value != null && { Value: input.Value }),
2330
- };
2331
- };
2332
- const se_ResourceTagKeyList = (input, context) => {
2333
- return input
2334
- .filter((e) => e != null)
2335
- .map((entry) => {
2336
- return entry;
2337
- });
2338
- };
2339
- const se_ResourceTagList = (input, context) => {
2340
- return input
2341
- .filter((e) => e != null)
2342
- .map((entry) => {
2343
- return se_ResourceTag(entry, context);
2344
- });
2345
- };
2346
- const se_RightsizingRecommendationConfiguration = (input, context) => {
2347
- return {
2348
- ...(input.BenefitsConsidered != null && { BenefitsConsidered: input.BenefitsConsidered }),
2349
- ...(input.RecommendationTarget != null && { RecommendationTarget: input.RecommendationTarget }),
2350
- };
2351
- };
2352
- const se_SavingsPlansDataTypes = (input, context) => {
2353
- return input
2354
- .filter((e) => e != null)
2355
- .map((entry) => {
2356
- return entry;
2357
- });
2358
- };
2359
- const se_ServiceSpecification = (input, context) => {
2360
- return {
2361
- ...(input.EC2Specification != null && { EC2Specification: se_EC2Specification(input.EC2Specification, context) }),
2362
- };
2363
- };
2364
- const se_SortDefinition = (input, context) => {
2365
- return {
2366
- ...(input.Key != null && { Key: input.Key }),
2367
- ...(input.SortOrder != null && { SortOrder: input.SortOrder }),
2368
- };
2369
- };
2370
- const se_SortDefinitions = (input, context) => {
2371
- return input
2372
- .filter((e) => e != null)
2373
- .map((entry) => {
2374
- return se_SortDefinition(entry, context);
2375
- });
2376
- };
2377
- const se_StartSavingsPlansPurchaseRecommendationGenerationRequest = (input, context) => {
2378
- return {};
2379
- };
2380
- const se_Subscriber = (input, context) => {
2381
- return {
2382
- ...(input.Address != null && { Address: input.Address }),
2383
- ...(input.Status != null && { Status: input.Status }),
2384
- ...(input.Type != null && { Type: input.Type }),
2385
- };
2386
- };
2387
- const se_Subscribers = (input, context) => {
2388
- return input
2389
- .filter((e) => e != null)
2390
- .map((entry) => {
2391
- return se_Subscriber(entry, context);
2392
- });
2393
- };
2394
- const se_TagResourceRequest = (input, context) => {
2395
- return {
2396
- ...(input.ResourceArn != null && { ResourceArn: input.ResourceArn }),
2397
- ...(input.ResourceTags != null && { ResourceTags: se_ResourceTagList(input.ResourceTags, context) }),
2398
- };
2399
- };
2400
- const se_TagValues = (input, context) => {
2401
- return {
2402
- ...(input.Key != null && { Key: input.Key }),
2403
- ...(input.MatchOptions != null && { MatchOptions: se_MatchOptions(input.MatchOptions, context) }),
2404
- ...(input.Values != null && { Values: se_Values(input.Values, context) }),
2405
- };
2406
- };
2407
- const se_TotalImpactFilter = (input, context) => {
2408
- return {
2409
- ...(input.EndValue != null && { EndValue: __serializeFloat(input.EndValue) }),
2410
- ...(input.NumericOperator != null && { NumericOperator: input.NumericOperator }),
2411
- ...(input.StartValue != null && { StartValue: __serializeFloat(input.StartValue) }),
2412
- };
2413
- };
2414
- const se_UntagResourceRequest = (input, context) => {
2415
- return {
2416
- ...(input.ResourceArn != null && { ResourceArn: input.ResourceArn }),
2417
- ...(input.ResourceTagKeys != null && { ResourceTagKeys: se_ResourceTagKeyList(input.ResourceTagKeys, context) }),
2418
- };
2419
- };
2420
- const se_UpdateAnomalyMonitorRequest = (input, context) => {
2421
- return {
2422
- ...(input.MonitorArn != null && { MonitorArn: input.MonitorArn }),
2423
- ...(input.MonitorName != null && { MonitorName: input.MonitorName }),
2424
- };
2425
- };
2426
- const se_UpdateAnomalySubscriptionRequest = (input, context) => {
2427
- return {
2428
- ...(input.Frequency != null && { Frequency: input.Frequency }),
2429
- ...(input.MonitorArnList != null && { MonitorArnList: se_MonitorArnList(input.MonitorArnList, context) }),
2430
- ...(input.Subscribers != null && { Subscribers: se_Subscribers(input.Subscribers, context) }),
2431
- ...(input.SubscriptionArn != null && { SubscriptionArn: input.SubscriptionArn }),
2432
- ...(input.SubscriptionName != null && { SubscriptionName: input.SubscriptionName }),
2433
- ...(input.Threshold != null && { Threshold: __serializeFloat(input.Threshold) }),
2434
- ...(input.ThresholdExpression != null && {
2435
- ThresholdExpression: se_Expression(input.ThresholdExpression, context),
2436
- }),
2437
- };
2438
- };
2439
- const se_UpdateCostAllocationTagsStatusRequest = (input, context) => {
2440
- return {
2441
- ...(input.CostAllocationTagsStatus != null && {
2442
- CostAllocationTagsStatus: se_CostAllocationTagStatusList(input.CostAllocationTagsStatus, context),
2443
- }),
2444
- };
2445
- };
2446
- const se_UpdateCostCategoryDefinitionRequest = (input, context) => {
2447
- return {
2448
- ...(input.CostCategoryArn != null && { CostCategoryArn: input.CostCategoryArn }),
2449
- ...(input.DefaultValue != null && { DefaultValue: input.DefaultValue }),
2450
- ...(input.EffectiveStart != null && { EffectiveStart: input.EffectiveStart }),
2451
- ...(input.RuleVersion != null && { RuleVersion: input.RuleVersion }),
2452
- ...(input.Rules != null && { Rules: se_CostCategoryRulesList(input.Rules, context) }),
2453
- ...(input.SplitChargeRules != null && {
2454
- SplitChargeRules: se_CostCategorySplitChargeRulesList(input.SplitChargeRules, context),
2455
- }),
2456
- };
2457
- };
2458
- const se_Values = (input, context) => {
2459
- return input
2460
- .filter((e) => e != null)
2461
- .map((entry) => {
2462
- return entry;
2463
- });
2464
- };
2465
- const de_Anomalies = (output, context) => {
2466
- const retVal = (output || [])
2467
- .filter((e) => e != null)
2468
- .map((entry) => {
2469
- if (entry === null) {
2470
- return null;
2471
- }
2472
- return de_Anomaly(entry, context);
2473
- });
2474
- return retVal;
2475
- };
2476
- const de_Anomaly = (output, context) => {
2477
- return {
2478
- AnomalyEndDate: __expectString(output.AnomalyEndDate),
2479
- AnomalyId: __expectString(output.AnomalyId),
2480
- AnomalyScore: output.AnomalyScore != null ? de_AnomalyScore(output.AnomalyScore, context) : undefined,
2481
- AnomalyStartDate: __expectString(output.AnomalyStartDate),
2482
- DimensionValue: __expectString(output.DimensionValue),
2483
- Feedback: __expectString(output.Feedback),
2484
- Impact: output.Impact != null ? de_Impact(output.Impact, context) : undefined,
2485
- MonitorArn: __expectString(output.MonitorArn),
2486
- RootCauses: output.RootCauses != null ? de_RootCauses(output.RootCauses, context) : undefined,
2487
- };
2488
- };
2489
- const de_AnomalyMonitor = (output, context) => {
2490
- return {
2491
- CreationDate: __expectString(output.CreationDate),
2492
- DimensionalValueCount: __expectInt32(output.DimensionalValueCount),
2493
- LastEvaluatedDate: __expectString(output.LastEvaluatedDate),
2494
- LastUpdatedDate: __expectString(output.LastUpdatedDate),
2495
- MonitorArn: __expectString(output.MonitorArn),
2496
- MonitorDimension: __expectString(output.MonitorDimension),
2497
- MonitorName: __expectString(output.MonitorName),
2498
- MonitorSpecification: output.MonitorSpecification != null ? de_Expression(output.MonitorSpecification, context) : undefined,
2499
- MonitorType: __expectString(output.MonitorType),
2500
- };
2501
- };
2502
- const de_AnomalyMonitors = (output, context) => {
2503
- const retVal = (output || [])
2504
- .filter((e) => e != null)
2505
- .map((entry) => {
2506
- if (entry === null) {
2507
- return null;
2508
- }
2509
- return de_AnomalyMonitor(entry, context);
2510
- });
2511
- return retVal;
2512
- };
2513
- const de_AnomalyScore = (output, context) => {
2514
- return {
2515
- CurrentScore: __limitedParseDouble(output.CurrentScore),
2516
- MaxScore: __limitedParseDouble(output.MaxScore),
2517
- };
2518
- };
2519
- const de_AnomalySubscription = (output, context) => {
2520
- return {
2521
- AccountId: __expectString(output.AccountId),
2522
- Frequency: __expectString(output.Frequency),
2523
- MonitorArnList: output.MonitorArnList != null ? de_MonitorArnList(output.MonitorArnList, context) : undefined,
2524
- Subscribers: output.Subscribers != null ? de_Subscribers(output.Subscribers, context) : undefined,
2525
- SubscriptionArn: __expectString(output.SubscriptionArn),
2526
- SubscriptionName: __expectString(output.SubscriptionName),
2527
- Threshold: __limitedParseDouble(output.Threshold),
2528
- ThresholdExpression: output.ThresholdExpression != null ? de_Expression(output.ThresholdExpression, context) : undefined,
2529
- };
2530
- };
2531
- const de_AnomalySubscriptions = (output, context) => {
2532
- const retVal = (output || [])
2533
- .filter((e) => e != null)
2534
- .map((entry) => {
2535
- if (entry === null) {
2536
- return null;
2537
- }
2538
- return de_AnomalySubscription(entry, context);
2539
- });
2540
- return retVal;
2541
- };
2542
- const de_Attributes = (output, context) => {
2543
- return Object.entries(output).reduce((acc, [key, value]) => {
2544
- if (value === null) {
2545
- return acc;
2546
- }
2547
- acc[key] = __expectString(value);
2548
- return acc;
2549
- }, {});
2550
- };
2551
- const de_BillExpirationException = (output, context) => {
2552
- return {
2553
- Message: __expectString(output.Message),
2554
- };
2555
- };
2556
- const de_CostAllocationTag = (output, context) => {
2557
- return {
2558
- Status: __expectString(output.Status),
2559
- TagKey: __expectString(output.TagKey),
2560
- Type: __expectString(output.Type),
2561
- };
2562
- };
2563
- const de_CostAllocationTagList = (output, context) => {
2564
- const retVal = (output || [])
2565
- .filter((e) => e != null)
2566
- .map((entry) => {
2567
- if (entry === null) {
2568
- return null;
2569
- }
2570
- return de_CostAllocationTag(entry, context);
2571
- });
2572
- return retVal;
2573
- };
2574
- const de_CostCategory = (output, context) => {
2575
- return {
2576
- CostCategoryArn: __expectString(output.CostCategoryArn),
2577
- DefaultValue: __expectString(output.DefaultValue),
2578
- EffectiveEnd: __expectString(output.EffectiveEnd),
2579
- EffectiveStart: __expectString(output.EffectiveStart),
2580
- Name: __expectString(output.Name),
2581
- ProcessingStatus: output.ProcessingStatus != null
2582
- ? de_CostCategoryProcessingStatusList(output.ProcessingStatus, context)
2583
- : undefined,
2584
- RuleVersion: __expectString(output.RuleVersion),
2585
- Rules: output.Rules != null ? de_CostCategoryRulesList(output.Rules, context) : undefined,
2586
- SplitChargeRules: output.SplitChargeRules != null
2587
- ? de_CostCategorySplitChargeRulesList(output.SplitChargeRules, context)
2588
- : undefined,
2589
- };
2590
- };
2591
- const de_CostCategoryInheritedValueDimension = (output, context) => {
2592
- return {
2593
- DimensionKey: __expectString(output.DimensionKey),
2594
- DimensionName: __expectString(output.DimensionName),
2595
- };
2596
- };
2597
- const de_CostCategoryNamesList = (output, context) => {
2598
- const retVal = (output || [])
2599
- .filter((e) => e != null)
2600
- .map((entry) => {
2601
- if (entry === null) {
2602
- return null;
2603
- }
2604
- return __expectString(entry);
2605
- });
2606
- return retVal;
2607
- };
2608
- const de_CostCategoryProcessingStatus = (output, context) => {
2609
- return {
2610
- Component: __expectString(output.Component),
2611
- Status: __expectString(output.Status),
2612
- };
2613
- };
2614
- const de_CostCategoryProcessingStatusList = (output, context) => {
2615
- const retVal = (output || [])
2616
- .filter((e) => e != null)
2617
- .map((entry) => {
2618
- if (entry === null) {
2619
- return null;
2620
- }
2621
- return de_CostCategoryProcessingStatus(entry, context);
2622
- });
2623
- return retVal;
2624
- };
2625
- const de_CostCategoryReference = (output, context) => {
2626
- return {
2627
- CostCategoryArn: __expectString(output.CostCategoryArn),
2628
- DefaultValue: __expectString(output.DefaultValue),
2629
- EffectiveEnd: __expectString(output.EffectiveEnd),
2630
- EffectiveStart: __expectString(output.EffectiveStart),
2631
- Name: __expectString(output.Name),
2632
- NumberOfRules: __expectInt32(output.NumberOfRules),
2633
- ProcessingStatus: output.ProcessingStatus != null
2634
- ? de_CostCategoryProcessingStatusList(output.ProcessingStatus, context)
2635
- : undefined,
2636
- Values: output.Values != null ? de_CostCategoryValuesList(output.Values, context) : undefined,
2637
- };
2638
- };
2639
- const de_CostCategoryReferencesList = (output, context) => {
2640
- const retVal = (output || [])
2641
- .filter((e) => e != null)
2642
- .map((entry) => {
2643
- if (entry === null) {
2644
- return null;
2645
- }
2646
- return de_CostCategoryReference(entry, context);
2647
- });
2648
- return retVal;
2649
- };
2650
- const de_CostCategoryRule = (output, context) => {
2651
- return {
2652
- InheritedValue: output.InheritedValue != null
2653
- ? de_CostCategoryInheritedValueDimension(output.InheritedValue, context)
2654
- : undefined,
2655
- Rule: output.Rule != null ? de_Expression(output.Rule, context) : undefined,
2656
- Type: __expectString(output.Type),
2657
- Value: __expectString(output.Value),
2658
- };
2659
- };
2660
- const de_CostCategoryRulesList = (output, context) => {
2661
- const retVal = (output || [])
2662
- .filter((e) => e != null)
2663
- .map((entry) => {
2664
- if (entry === null) {
2665
- return null;
2666
- }
2667
- return de_CostCategoryRule(entry, context);
2668
- });
2669
- return retVal;
2670
- };
2671
- const de_CostCategorySplitChargeRule = (output, context) => {
2672
- return {
2673
- Method: __expectString(output.Method),
2674
- Parameters: output.Parameters != null ? de_CostCategorySplitChargeRuleParametersList(output.Parameters, context) : undefined,
2675
- Source: __expectString(output.Source),
2676
- Targets: output.Targets != null ? de_CostCategorySplitChargeRuleTargetsList(output.Targets, context) : undefined,
2677
- };
2678
- };
2679
- const de_CostCategorySplitChargeRuleParameter = (output, context) => {
2680
- return {
2681
- Type: __expectString(output.Type),
2682
- Values: output.Values != null ? de_CostCategorySplitChargeRuleParameterValuesList(output.Values, context) : undefined,
2683
- };
2684
- };
2685
- const de_CostCategorySplitChargeRuleParametersList = (output, context) => {
2686
- const retVal = (output || [])
2687
- .filter((e) => e != null)
2688
- .map((entry) => {
2689
- if (entry === null) {
2690
- return null;
2691
- }
2692
- return de_CostCategorySplitChargeRuleParameter(entry, context);
2693
- });
2694
- return retVal;
2695
- };
2696
- const de_CostCategorySplitChargeRuleParameterValuesList = (output, context) => {
2697
- const retVal = (output || [])
2698
- .filter((e) => e != null)
2699
- .map((entry) => {
2700
- if (entry === null) {
2701
- return null;
2702
- }
2703
- return __expectString(entry);
2704
- });
2705
- return retVal;
2706
- };
2707
- const de_CostCategorySplitChargeRulesList = (output, context) => {
2708
- const retVal = (output || [])
2709
- .filter((e) => e != null)
2710
- .map((entry) => {
2711
- if (entry === null) {
2712
- return null;
2713
- }
2714
- return de_CostCategorySplitChargeRule(entry, context);
2715
- });
2716
- return retVal;
2717
- };
2718
- const de_CostCategorySplitChargeRuleTargetsList = (output, context) => {
2719
- const retVal = (output || [])
2720
- .filter((e) => e != null)
2721
- .map((entry) => {
2722
- if (entry === null) {
2723
- return null;
2724
- }
2725
- return __expectString(entry);
2726
- });
2727
- return retVal;
2728
- };
2729
- const de_CostCategoryValues = (output, context) => {
2730
- return {
2731
- Key: __expectString(output.Key),
2732
- MatchOptions: output.MatchOptions != null ? de_MatchOptions(output.MatchOptions, context) : undefined,
2733
- Values: output.Values != null ? de_Values(output.Values, context) : undefined,
2734
- };
2735
- };
2736
- const de_CostCategoryValuesList = (output, context) => {
2737
- const retVal = (output || [])
2738
- .filter((e) => e != null)
2739
- .map((entry) => {
2740
- if (entry === null) {
2741
- return null;
2742
- }
2743
- return __expectString(entry);
2744
- });
2745
- return retVal;
2746
- };
2747
- const de_Coverage = (output, context) => {
2748
- return {
2749
- CoverageCost: output.CoverageCost != null ? de_CoverageCost(output.CoverageCost, context) : undefined,
2750
- CoverageHours: output.CoverageHours != null ? de_CoverageHours(output.CoverageHours, context) : undefined,
2751
- CoverageNormalizedUnits: output.CoverageNormalizedUnits != null
2752
- ? de_CoverageNormalizedUnits(output.CoverageNormalizedUnits, context)
2753
- : undefined,
2754
- };
2755
- };
2756
- const de_CoverageByTime = (output, context) => {
2757
- return {
2758
- Groups: output.Groups != null ? de_ReservationCoverageGroups(output.Groups, context) : undefined,
2759
- TimePeriod: output.TimePeriod != null ? de_DateInterval(output.TimePeriod, context) : undefined,
2760
- Total: output.Total != null ? de_Coverage(output.Total, context) : undefined,
2761
- };
2762
- };
2763
- const de_CoverageCost = (output, context) => {
2764
- return {
2765
- OnDemandCost: __expectString(output.OnDemandCost),
2766
- };
2767
- };
2768
- const de_CoverageHours = (output, context) => {
2769
- return {
2770
- CoverageHoursPercentage: __expectString(output.CoverageHoursPercentage),
2771
- OnDemandHours: __expectString(output.OnDemandHours),
2772
- ReservedHours: __expectString(output.ReservedHours),
2773
- TotalRunningHours: __expectString(output.TotalRunningHours),
2774
- };
2775
- };
2776
- const de_CoverageNormalizedUnits = (output, context) => {
2777
- return {
2778
- CoverageNormalizedUnitsPercentage: __expectString(output.CoverageNormalizedUnitsPercentage),
2779
- OnDemandNormalizedUnits: __expectString(output.OnDemandNormalizedUnits),
2780
- ReservedNormalizedUnits: __expectString(output.ReservedNormalizedUnits),
2781
- TotalRunningNormalizedUnits: __expectString(output.TotalRunningNormalizedUnits),
2782
- };
2783
- };
2784
- const de_CoveragesByTime = (output, context) => {
2785
- const retVal = (output || [])
2786
- .filter((e) => e != null)
2787
- .map((entry) => {
2788
- if (entry === null) {
2789
- return null;
2790
- }
2791
- return de_CoverageByTime(entry, context);
2792
- });
2793
- return retVal;
2794
- };
2795
- const de_CreateAnomalyMonitorResponse = (output, context) => {
2796
- return {
2797
- MonitorArn: __expectString(output.MonitorArn),
2798
- };
2799
- };
2800
- const de_CreateAnomalySubscriptionResponse = (output, context) => {
2801
- return {
2802
- SubscriptionArn: __expectString(output.SubscriptionArn),
2803
- };
2804
- };
2805
- const de_CreateCostCategoryDefinitionResponse = (output, context) => {
2806
- return {
2807
- CostCategoryArn: __expectString(output.CostCategoryArn),
2808
- EffectiveStart: __expectString(output.EffectiveStart),
2809
- };
2810
- };
2811
- const de_CurrentInstance = (output, context) => {
2812
- return {
2813
- CurrencyCode: __expectString(output.CurrencyCode),
2814
- InstanceName: __expectString(output.InstanceName),
2815
- MonthlyCost: __expectString(output.MonthlyCost),
2816
- OnDemandHoursInLookbackPeriod: __expectString(output.OnDemandHoursInLookbackPeriod),
2817
- ReservationCoveredHoursInLookbackPeriod: __expectString(output.ReservationCoveredHoursInLookbackPeriod),
2818
- ResourceDetails: output.ResourceDetails != null ? de_ResourceDetails(output.ResourceDetails, context) : undefined,
2819
- ResourceId: __expectString(output.ResourceId),
2820
- ResourceUtilization: output.ResourceUtilization != null ? de_ResourceUtilization(output.ResourceUtilization, context) : undefined,
2821
- SavingsPlansCoveredHoursInLookbackPeriod: __expectString(output.SavingsPlansCoveredHoursInLookbackPeriod),
2822
- Tags: output.Tags != null ? de_TagValuesList(output.Tags, context) : undefined,
2823
- TotalRunningHoursInLookbackPeriod: __expectString(output.TotalRunningHoursInLookbackPeriod),
2824
- };
2825
- };
2826
- const de_DataUnavailableException = (output, context) => {
2827
- return {
2828
- Message: __expectString(output.Message),
2829
- };
2830
- };
2831
- const de_DateInterval = (output, context) => {
2832
- return {
2833
- End: __expectString(output.End),
2834
- Start: __expectString(output.Start),
2835
- };
2836
- };
2837
- const de_DeleteAnomalyMonitorResponse = (output, context) => {
2838
- return {};
2839
- };
2840
- const de_DeleteAnomalySubscriptionResponse = (output, context) => {
2841
- return {};
2842
- };
2843
- const de_DeleteCostCategoryDefinitionResponse = (output, context) => {
2844
- return {
2845
- CostCategoryArn: __expectString(output.CostCategoryArn),
2846
- EffectiveEnd: __expectString(output.EffectiveEnd),
2847
- };
2848
- };
2849
- const de_DescribeCostCategoryDefinitionResponse = (output, context) => {
2850
- return {
2851
- CostCategory: output.CostCategory != null ? de_CostCategory(output.CostCategory, context) : undefined,
2852
- };
2853
- };
2854
- const de_DimensionValues = (output, context) => {
2855
- return {
2856
- Key: __expectString(output.Key),
2857
- MatchOptions: output.MatchOptions != null ? de_MatchOptions(output.MatchOptions, context) : undefined,
2858
- Values: output.Values != null ? de_Values(output.Values, context) : undefined,
2859
- };
2860
- };
2861
- const de_DimensionValuesWithAttributes = (output, context) => {
2862
- return {
2863
- Attributes: output.Attributes != null ? de_Attributes(output.Attributes, context) : undefined,
2864
- Value: __expectString(output.Value),
2865
- };
2866
- };
2867
- const de_DimensionValuesWithAttributesList = (output, context) => {
2868
- const retVal = (output || [])
2869
- .filter((e) => e != null)
2870
- .map((entry) => {
2871
- if (entry === null) {
2872
- return null;
2873
- }
2874
- return de_DimensionValuesWithAttributes(entry, context);
2875
- });
2876
- return retVal;
2877
- };
2878
- const de_DiskResourceUtilization = (output, context) => {
2879
- return {
2880
- DiskReadBytesPerSecond: __expectString(output.DiskReadBytesPerSecond),
2881
- DiskReadOpsPerSecond: __expectString(output.DiskReadOpsPerSecond),
2882
- DiskWriteBytesPerSecond: __expectString(output.DiskWriteBytesPerSecond),
2883
- DiskWriteOpsPerSecond: __expectString(output.DiskWriteOpsPerSecond),
2884
- };
2885
- };
2886
- const de_EBSResourceUtilization = (output, context) => {
2887
- return {
2888
- EbsReadBytesPerSecond: __expectString(output.EbsReadBytesPerSecond),
2889
- EbsReadOpsPerSecond: __expectString(output.EbsReadOpsPerSecond),
2890
- EbsWriteBytesPerSecond: __expectString(output.EbsWriteBytesPerSecond),
2891
- EbsWriteOpsPerSecond: __expectString(output.EbsWriteOpsPerSecond),
2892
- };
2893
- };
2894
- const de_EC2InstanceDetails = (output, context) => {
2895
- return {
2896
- AvailabilityZone: __expectString(output.AvailabilityZone),
2897
- CurrentGeneration: __expectBoolean(output.CurrentGeneration),
2898
- Family: __expectString(output.Family),
2899
- InstanceType: __expectString(output.InstanceType),
2900
- Platform: __expectString(output.Platform),
2901
- Region: __expectString(output.Region),
2902
- SizeFlexEligible: __expectBoolean(output.SizeFlexEligible),
2903
- Tenancy: __expectString(output.Tenancy),
2904
- };
2905
- };
2906
- const de_EC2ResourceDetails = (output, context) => {
2907
- return {
2908
- HourlyOnDemandRate: __expectString(output.HourlyOnDemandRate),
2909
- InstanceType: __expectString(output.InstanceType),
2910
- Memory: __expectString(output.Memory),
2911
- NetworkPerformance: __expectString(output.NetworkPerformance),
2912
- Platform: __expectString(output.Platform),
2913
- Region: __expectString(output.Region),
2914
- Sku: __expectString(output.Sku),
2915
- Storage: __expectString(output.Storage),
2916
- Vcpu: __expectString(output.Vcpu),
2917
- };
2918
- };
2919
- const de_EC2ResourceUtilization = (output, context) => {
2920
- return {
2921
- DiskResourceUtilization: output.DiskResourceUtilization != null
2922
- ? de_DiskResourceUtilization(output.DiskResourceUtilization, context)
2923
- : undefined,
2924
- EBSResourceUtilization: output.EBSResourceUtilization != null
2925
- ? de_EBSResourceUtilization(output.EBSResourceUtilization, context)
2926
- : undefined,
2927
- MaxCpuUtilizationPercentage: __expectString(output.MaxCpuUtilizationPercentage),
2928
- MaxMemoryUtilizationPercentage: __expectString(output.MaxMemoryUtilizationPercentage),
2929
- MaxStorageUtilizationPercentage: __expectString(output.MaxStorageUtilizationPercentage),
2930
- NetworkResourceUtilization: output.NetworkResourceUtilization != null
2931
- ? de_NetworkResourceUtilization(output.NetworkResourceUtilization, context)
2932
- : undefined,
2933
- };
2934
- };
2935
- const de_EC2Specification = (output, context) => {
2936
- return {
2937
- OfferingClass: __expectString(output.OfferingClass),
2938
- };
2939
- };
2940
- const de_ElastiCacheInstanceDetails = (output, context) => {
2941
- return {
2942
- CurrentGeneration: __expectBoolean(output.CurrentGeneration),
2943
- Family: __expectString(output.Family),
2944
- NodeType: __expectString(output.NodeType),
2945
- ProductDescription: __expectString(output.ProductDescription),
2946
- Region: __expectString(output.Region),
2947
- SizeFlexEligible: __expectBoolean(output.SizeFlexEligible),
2948
- };
2949
- };
2950
- const de_ESInstanceDetails = (output, context) => {
2951
- return {
2952
- CurrentGeneration: __expectBoolean(output.CurrentGeneration),
2953
- InstanceClass: __expectString(output.InstanceClass),
2954
- InstanceSize: __expectString(output.InstanceSize),
2955
- Region: __expectString(output.Region),
2956
- SizeFlexEligible: __expectBoolean(output.SizeFlexEligible),
2957
- };
2958
- };
2959
- const de_Expression = (output, context) => {
2960
- return {
2961
- And: output.And != null ? de_Expressions(output.And, context) : undefined,
2962
- CostCategories: output.CostCategories != null ? de_CostCategoryValues(output.CostCategories, context) : undefined,
2963
- Dimensions: output.Dimensions != null ? de_DimensionValues(output.Dimensions, context) : undefined,
2964
- Not: output.Not != null ? de_Expression(output.Not, context) : undefined,
2965
- Or: output.Or != null ? de_Expressions(output.Or, context) : undefined,
2966
- Tags: output.Tags != null ? de_TagValues(output.Tags, context) : undefined,
2967
- };
2968
- };
2969
- const de_Expressions = (output, context) => {
2970
- const retVal = (output || [])
2971
- .filter((e) => e != null)
2972
- .map((entry) => {
2973
- if (entry === null) {
2974
- return null;
2975
- }
2976
- return de_Expression(entry, context);
2977
- });
2978
- return retVal;
2979
- };
2980
- const de_FindingReasonCodes = (output, context) => {
2981
- const retVal = (output || [])
2982
- .filter((e) => e != null)
2983
- .map((entry) => {
2984
- if (entry === null) {
2985
- return null;
2986
- }
2987
- return __expectString(entry);
2988
- });
2989
- return retVal;
2990
- };
2991
- const de_ForecastResult = (output, context) => {
2992
- return {
2993
- MeanValue: __expectString(output.MeanValue),
2994
- PredictionIntervalLowerBound: __expectString(output.PredictionIntervalLowerBound),
2995
- PredictionIntervalUpperBound: __expectString(output.PredictionIntervalUpperBound),
2996
- TimePeriod: output.TimePeriod != null ? de_DateInterval(output.TimePeriod, context) : undefined,
2997
- };
2998
- };
2999
- const de_ForecastResultsByTime = (output, context) => {
3000
- const retVal = (output || [])
3001
- .filter((e) => e != null)
3002
- .map((entry) => {
3003
- if (entry === null) {
3004
- return null;
3005
- }
3006
- return de_ForecastResult(entry, context);
3007
- });
3008
- return retVal;
3009
- };
3010
- const de_GenerationExistsException = (output, context) => {
3011
- return {
3012
- Message: __expectString(output.Message),
3013
- };
3014
- };
3015
- const de_GenerationSummary = (output, context) => {
3016
- return {
3017
- EstimatedCompletionTime: __expectString(output.EstimatedCompletionTime),
3018
- GenerationCompletionTime: __expectString(output.GenerationCompletionTime),
3019
- GenerationStartedTime: __expectString(output.GenerationStartedTime),
3020
- GenerationStatus: __expectString(output.GenerationStatus),
3021
- RecommendationId: __expectString(output.RecommendationId),
3022
- };
3023
- };
3024
- const de_GenerationSummaryList = (output, context) => {
3025
- const retVal = (output || [])
3026
- .filter((e) => e != null)
3027
- .map((entry) => {
3028
- if (entry === null) {
3029
- return null;
3030
- }
3031
- return de_GenerationSummary(entry, context);
3032
- });
3033
- return retVal;
3034
- };
3035
- const de_GetAnomaliesResponse = (output, context) => {
3036
- return {
3037
- Anomalies: output.Anomalies != null ? de_Anomalies(output.Anomalies, context) : undefined,
3038
- NextPageToken: __expectString(output.NextPageToken),
3039
- };
3040
- };
3041
- const de_GetAnomalyMonitorsResponse = (output, context) => {
3042
- return {
3043
- AnomalyMonitors: output.AnomalyMonitors != null ? de_AnomalyMonitors(output.AnomalyMonitors, context) : undefined,
3044
- NextPageToken: __expectString(output.NextPageToken),
3045
- };
3046
- };
3047
- const de_GetAnomalySubscriptionsResponse = (output, context) => {
3048
- return {
3049
- AnomalySubscriptions: output.AnomalySubscriptions != null ? de_AnomalySubscriptions(output.AnomalySubscriptions, context) : undefined,
3050
- NextPageToken: __expectString(output.NextPageToken),
3051
- };
3052
- };
3053
- const de_GetCostAndUsageResponse = (output, context) => {
3054
- return {
3055
- DimensionValueAttributes: output.DimensionValueAttributes != null
3056
- ? de_DimensionValuesWithAttributesList(output.DimensionValueAttributes, context)
3057
- : undefined,
3058
- GroupDefinitions: output.GroupDefinitions != null ? de_GroupDefinitions(output.GroupDefinitions, context) : undefined,
3059
- NextPageToken: __expectString(output.NextPageToken),
3060
- ResultsByTime: output.ResultsByTime != null ? de_ResultsByTime(output.ResultsByTime, context) : undefined,
3061
- };
3062
- };
3063
- const de_GetCostAndUsageWithResourcesResponse = (output, context) => {
3064
- return {
3065
- DimensionValueAttributes: output.DimensionValueAttributes != null
3066
- ? de_DimensionValuesWithAttributesList(output.DimensionValueAttributes, context)
3067
- : undefined,
3068
- GroupDefinitions: output.GroupDefinitions != null ? de_GroupDefinitions(output.GroupDefinitions, context) : undefined,
3069
- NextPageToken: __expectString(output.NextPageToken),
3070
- ResultsByTime: output.ResultsByTime != null ? de_ResultsByTime(output.ResultsByTime, context) : undefined,
3071
- };
3072
- };
3073
- const de_GetCostCategoriesResponse = (output, context) => {
3074
- return {
3075
- CostCategoryNames: output.CostCategoryNames != null ? de_CostCategoryNamesList(output.CostCategoryNames, context) : undefined,
3076
- CostCategoryValues: output.CostCategoryValues != null ? de_CostCategoryValuesList(output.CostCategoryValues, context) : undefined,
3077
- NextPageToken: __expectString(output.NextPageToken),
3078
- ReturnSize: __expectInt32(output.ReturnSize),
3079
- TotalSize: __expectInt32(output.TotalSize),
3080
- };
3081
- };
3082
- const de_GetCostForecastResponse = (output, context) => {
3083
- return {
3084
- ForecastResultsByTime: output.ForecastResultsByTime != null
3085
- ? de_ForecastResultsByTime(output.ForecastResultsByTime, context)
3086
- : undefined,
3087
- Total: output.Total != null ? de_MetricValue(output.Total, context) : undefined,
3088
- };
3089
- };
3090
- const de_GetDimensionValuesResponse = (output, context) => {
3091
- return {
3092
- DimensionValues: output.DimensionValues != null
3093
- ? de_DimensionValuesWithAttributesList(output.DimensionValues, context)
3094
- : undefined,
3095
- NextPageToken: __expectString(output.NextPageToken),
3096
- ReturnSize: __expectInt32(output.ReturnSize),
3097
- TotalSize: __expectInt32(output.TotalSize),
3098
- };
3099
- };
3100
- const de_GetReservationCoverageResponse = (output, context) => {
3101
- return {
3102
- CoveragesByTime: output.CoveragesByTime != null ? de_CoveragesByTime(output.CoveragesByTime, context) : undefined,
3103
- NextPageToken: __expectString(output.NextPageToken),
3104
- Total: output.Total != null ? de_Coverage(output.Total, context) : undefined,
3105
- };
3106
- };
3107
- const de_GetReservationPurchaseRecommendationResponse = (output, context) => {
3108
- return {
3109
- Metadata: output.Metadata != null ? de_ReservationPurchaseRecommendationMetadata(output.Metadata, context) : undefined,
3110
- NextPageToken: __expectString(output.NextPageToken),
3111
- Recommendations: output.Recommendations != null
3112
- ? de_ReservationPurchaseRecommendations(output.Recommendations, context)
3113
- : undefined,
3114
- };
3115
- };
3116
- const de_GetReservationUtilizationResponse = (output, context) => {
3117
- return {
3118
- NextPageToken: __expectString(output.NextPageToken),
3119
- Total: output.Total != null ? de_ReservationAggregates(output.Total, context) : undefined,
3120
- UtilizationsByTime: output.UtilizationsByTime != null ? de_UtilizationsByTime(output.UtilizationsByTime, context) : undefined,
3121
- };
3122
- };
3123
- const de_GetRightsizingRecommendationResponse = (output, context) => {
3124
- return {
3125
- Configuration: output.Configuration != null
3126
- ? de_RightsizingRecommendationConfiguration(output.Configuration, context)
3127
- : undefined,
3128
- Metadata: output.Metadata != null ? de_RightsizingRecommendationMetadata(output.Metadata, context) : undefined,
3129
- NextPageToken: __expectString(output.NextPageToken),
3130
- RightsizingRecommendations: output.RightsizingRecommendations != null
3131
- ? de_RightsizingRecommendationList(output.RightsizingRecommendations, context)
3132
- : undefined,
3133
- Summary: output.Summary != null ? de_RightsizingRecommendationSummary(output.Summary, context) : undefined,
3134
- };
3135
- };
3136
- const de_GetSavingsPlansCoverageResponse = (output, context) => {
3137
- return {
3138
- NextToken: __expectString(output.NextToken),
3139
- SavingsPlansCoverages: output.SavingsPlansCoverages != null
3140
- ? de_SavingsPlansCoverages(output.SavingsPlansCoverages, context)
3141
- : undefined,
3142
- };
3143
- };
3144
- const de_GetSavingsPlansPurchaseRecommendationResponse = (output, context) => {
3145
- return {
3146
- Metadata: output.Metadata != null ? de_SavingsPlansPurchaseRecommendationMetadata(output.Metadata, context) : undefined,
3147
- NextPageToken: __expectString(output.NextPageToken),
3148
- SavingsPlansPurchaseRecommendation: output.SavingsPlansPurchaseRecommendation != null
3149
- ? de_SavingsPlansPurchaseRecommendation(output.SavingsPlansPurchaseRecommendation, context)
3150
- : undefined,
3151
- };
3152
- };
3153
- const de_GetSavingsPlansUtilizationDetailsResponse = (output, context) => {
3154
- return {
3155
- NextToken: __expectString(output.NextToken),
3156
- SavingsPlansUtilizationDetails: output.SavingsPlansUtilizationDetails != null
3157
- ? de_SavingsPlansUtilizationDetails(output.SavingsPlansUtilizationDetails, context)
3158
- : undefined,
3159
- TimePeriod: output.TimePeriod != null ? de_DateInterval(output.TimePeriod, context) : undefined,
3160
- Total: output.Total != null ? de_SavingsPlansUtilizationAggregates(output.Total, context) : undefined,
3161
- };
3162
- };
3163
- const de_GetSavingsPlansUtilizationResponse = (output, context) => {
3164
- return {
3165
- SavingsPlansUtilizationsByTime: output.SavingsPlansUtilizationsByTime != null
3166
- ? de_SavingsPlansUtilizationsByTime(output.SavingsPlansUtilizationsByTime, context)
3167
- : undefined,
3168
- Total: output.Total != null ? de_SavingsPlansUtilizationAggregates(output.Total, context) : undefined,
3169
- };
3170
- };
3171
- const de_GetTagsResponse = (output, context) => {
3172
- return {
3173
- NextPageToken: __expectString(output.NextPageToken),
3174
- ReturnSize: __expectInt32(output.ReturnSize),
3175
- Tags: output.Tags != null ? de_TagList(output.Tags, context) : undefined,
3176
- TotalSize: __expectInt32(output.TotalSize),
3177
- };
3178
- };
3179
- const de_GetUsageForecastResponse = (output, context) => {
3180
- return {
3181
- ForecastResultsByTime: output.ForecastResultsByTime != null
3182
- ? de_ForecastResultsByTime(output.ForecastResultsByTime, context)
3183
- : undefined,
3184
- Total: output.Total != null ? de_MetricValue(output.Total, context) : undefined,
3185
- };
3186
- };
3187
- const de_Group = (output, context) => {
3188
- return {
3189
- Keys: output.Keys != null ? de_Keys(output.Keys, context) : undefined,
3190
- Metrics: output.Metrics != null ? de_Metrics(output.Metrics, context) : undefined,
3191
- };
3192
- };
3193
- const de_GroupDefinition = (output, context) => {
3194
- return {
3195
- Key: __expectString(output.Key),
3196
- Type: __expectString(output.Type),
3197
- };
3198
- };
3199
- const de_GroupDefinitions = (output, context) => {
3200
- const retVal = (output || [])
3201
- .filter((e) => e != null)
3202
- .map((entry) => {
3203
- if (entry === null) {
3204
- return null;
3205
- }
3206
- return de_GroupDefinition(entry, context);
3207
- });
3208
- return retVal;
3209
- };
3210
- const de_Groups = (output, context) => {
3211
- const retVal = (output || [])
3212
- .filter((e) => e != null)
3213
- .map((entry) => {
3214
- if (entry === null) {
3215
- return null;
3216
- }
3217
- return de_Group(entry, context);
3218
- });
3219
- return retVal;
3220
- };
3221
- const de_Impact = (output, context) => {
3222
- return {
3223
- MaxImpact: __limitedParseDouble(output.MaxImpact),
3224
- TotalActualSpend: __limitedParseDouble(output.TotalActualSpend),
3225
- TotalExpectedSpend: __limitedParseDouble(output.TotalExpectedSpend),
3226
- TotalImpact: __limitedParseDouble(output.TotalImpact),
3227
- TotalImpactPercentage: __limitedParseDouble(output.TotalImpactPercentage),
3228
- };
3229
- };
3230
- const de_InstanceDetails = (output, context) => {
3231
- return {
3232
- EC2InstanceDetails: output.EC2InstanceDetails != null ? de_EC2InstanceDetails(output.EC2InstanceDetails, context) : undefined,
3233
- ESInstanceDetails: output.ESInstanceDetails != null ? de_ESInstanceDetails(output.ESInstanceDetails, context) : undefined,
3234
- ElastiCacheInstanceDetails: output.ElastiCacheInstanceDetails != null
3235
- ? de_ElastiCacheInstanceDetails(output.ElastiCacheInstanceDetails, context)
3236
- : undefined,
3237
- RDSInstanceDetails: output.RDSInstanceDetails != null ? de_RDSInstanceDetails(output.RDSInstanceDetails, context) : undefined,
3238
- RedshiftInstanceDetails: output.RedshiftInstanceDetails != null
3239
- ? de_RedshiftInstanceDetails(output.RedshiftInstanceDetails, context)
3240
- : undefined,
3241
- };
3242
- };
3243
- const de_InvalidNextTokenException = (output, context) => {
3244
- return {
3245
- Message: __expectString(output.Message),
3246
- };
3247
- };
3248
- const de_Keys = (output, context) => {
3249
- const retVal = (output || [])
3250
- .filter((e) => e != null)
3251
- .map((entry) => {
3252
- if (entry === null) {
3253
- return null;
3254
- }
3255
- return __expectString(entry);
3256
- });
3257
- return retVal;
3258
- };
3259
- const de_LimitExceededException = (output, context) => {
3260
- return {
3261
- Message: __expectString(output.Message),
3262
- };
3263
- };
3264
- const de_ListCostAllocationTagsResponse = (output, context) => {
3265
- return {
3266
- CostAllocationTags: output.CostAllocationTags != null ? de_CostAllocationTagList(output.CostAllocationTags, context) : undefined,
3267
- NextToken: __expectString(output.NextToken),
3268
- };
3269
- };
3270
- const de_ListCostCategoryDefinitionsResponse = (output, context) => {
3271
- return {
3272
- CostCategoryReferences: output.CostCategoryReferences != null
3273
- ? de_CostCategoryReferencesList(output.CostCategoryReferences, context)
3274
- : undefined,
3275
- NextToken: __expectString(output.NextToken),
3276
- };
3277
- };
3278
- const de_ListSavingsPlansPurchaseRecommendationGenerationResponse = (output, context) => {
3279
- return {
3280
- GenerationSummaryList: output.GenerationSummaryList != null
3281
- ? de_GenerationSummaryList(output.GenerationSummaryList, context)
3282
- : undefined,
3283
- NextPageToken: __expectString(output.NextPageToken),
3284
- };
3285
- };
3286
- const de_ListTagsForResourceResponse = (output, context) => {
3287
- return {
3288
- ResourceTags: output.ResourceTags != null ? de_ResourceTagList(output.ResourceTags, context) : undefined,
3289
- };
3290
- };
3291
- const de_MatchOptions = (output, context) => {
3292
- const retVal = (output || [])
3293
- .filter((e) => e != null)
3294
- .map((entry) => {
3295
- if (entry === null) {
3296
- return null;
3297
- }
3298
- return __expectString(entry);
3299
- });
3300
- return retVal;
3301
- };
3302
- const de_Metrics = (output, context) => {
3303
- return Object.entries(output).reduce((acc, [key, value]) => {
3304
- if (value === null) {
3305
- return acc;
3306
- }
3307
- acc[key] = de_MetricValue(value, context);
3308
- return acc;
3309
- }, {});
3310
- };
3311
- const de_MetricValue = (output, context) => {
3312
- return {
3313
- Amount: __expectString(output.Amount),
3314
- Unit: __expectString(output.Unit),
3315
- };
3316
- };
3317
- const de_ModifyRecommendationDetail = (output, context) => {
3318
- return {
3319
- TargetInstances: output.TargetInstances != null ? de_TargetInstancesList(output.TargetInstances, context) : undefined,
3320
- };
3321
- };
3322
- const de_MonitorArnList = (output, context) => {
3323
- const retVal = (output || [])
3324
- .filter((e) => e != null)
3325
- .map((entry) => {
3326
- if (entry === null) {
3327
- return null;
3328
- }
3329
- return __expectString(entry);
3330
- });
3331
- return retVal;
3332
- };
3333
- const de_NetworkResourceUtilization = (output, context) => {
3334
- return {
3335
- NetworkInBytesPerSecond: __expectString(output.NetworkInBytesPerSecond),
3336
- NetworkOutBytesPerSecond: __expectString(output.NetworkOutBytesPerSecond),
3337
- NetworkPacketsInPerSecond: __expectString(output.NetworkPacketsInPerSecond),
3338
- NetworkPacketsOutPerSecond: __expectString(output.NetworkPacketsOutPerSecond),
3339
- };
3340
- };
3341
- const de_PlatformDifferences = (output, context) => {
3342
- const retVal = (output || [])
3343
- .filter((e) => e != null)
3344
- .map((entry) => {
3345
- if (entry === null) {
3346
- return null;
3347
- }
3348
- return __expectString(entry);
3349
- });
3350
- return retVal;
3351
- };
3352
- const de_ProvideAnomalyFeedbackResponse = (output, context) => {
3353
- return {
3354
- AnomalyId: __expectString(output.AnomalyId),
3355
- };
3356
- };
3357
- const de_RDSInstanceDetails = (output, context) => {
3358
- return {
3359
- CurrentGeneration: __expectBoolean(output.CurrentGeneration),
3360
- DatabaseEdition: __expectString(output.DatabaseEdition),
3361
- DatabaseEngine: __expectString(output.DatabaseEngine),
3362
- DeploymentOption: __expectString(output.DeploymentOption),
3363
- Family: __expectString(output.Family),
3364
- InstanceType: __expectString(output.InstanceType),
3365
- LicenseModel: __expectString(output.LicenseModel),
3366
- Region: __expectString(output.Region),
3367
- SizeFlexEligible: __expectBoolean(output.SizeFlexEligible),
3368
- };
3369
- };
3370
- const de_RedshiftInstanceDetails = (output, context) => {
3371
- return {
3372
- CurrentGeneration: __expectBoolean(output.CurrentGeneration),
3373
- Family: __expectString(output.Family),
3374
- NodeType: __expectString(output.NodeType),
3375
- Region: __expectString(output.Region),
3376
- SizeFlexEligible: __expectBoolean(output.SizeFlexEligible),
3377
- };
3378
- };
3379
- const de_RequestChangedException = (output, context) => {
3380
- return {
3381
- Message: __expectString(output.Message),
3382
- };
3383
- };
3384
- const de_ReservationAggregates = (output, context) => {
3385
- return {
3386
- AmortizedRecurringFee: __expectString(output.AmortizedRecurringFee),
3387
- AmortizedUpfrontFee: __expectString(output.AmortizedUpfrontFee),
3388
- NetRISavings: __expectString(output.NetRISavings),
3389
- OnDemandCostOfRIHoursUsed: __expectString(output.OnDemandCostOfRIHoursUsed),
3390
- PurchasedHours: __expectString(output.PurchasedHours),
3391
- PurchasedUnits: __expectString(output.PurchasedUnits),
3392
- RICostForUnusedHours: __expectString(output.RICostForUnusedHours),
3393
- RealizedSavings: __expectString(output.RealizedSavings),
3394
- TotalActualHours: __expectString(output.TotalActualHours),
3395
- TotalActualUnits: __expectString(output.TotalActualUnits),
3396
- TotalAmortizedFee: __expectString(output.TotalAmortizedFee),
3397
- TotalPotentialRISavings: __expectString(output.TotalPotentialRISavings),
3398
- UnrealizedSavings: __expectString(output.UnrealizedSavings),
3399
- UnusedHours: __expectString(output.UnusedHours),
3400
- UnusedUnits: __expectString(output.UnusedUnits),
3401
- UtilizationPercentage: __expectString(output.UtilizationPercentage),
3402
- UtilizationPercentageInUnits: __expectString(output.UtilizationPercentageInUnits),
3403
- };
3404
- };
3405
- const de_ReservationCoverageGroup = (output, context) => {
3406
- return {
3407
- Attributes: output.Attributes != null ? de_Attributes(output.Attributes, context) : undefined,
3408
- Coverage: output.Coverage != null ? de_Coverage(output.Coverage, context) : undefined,
3409
- };
3410
- };
3411
- const de_ReservationCoverageGroups = (output, context) => {
3412
- const retVal = (output || [])
3413
- .filter((e) => e != null)
3414
- .map((entry) => {
3415
- if (entry === null) {
3416
- return null;
3417
- }
3418
- return de_ReservationCoverageGroup(entry, context);
3419
- });
3420
- return retVal;
3421
- };
3422
- const de_ReservationPurchaseRecommendation = (output, context) => {
3423
- return {
3424
- AccountScope: __expectString(output.AccountScope),
3425
- LookbackPeriodInDays: __expectString(output.LookbackPeriodInDays),
3426
- PaymentOption: __expectString(output.PaymentOption),
3427
- RecommendationDetails: output.RecommendationDetails != null
3428
- ? de_ReservationPurchaseRecommendationDetails(output.RecommendationDetails, context)
3429
- : undefined,
3430
- RecommendationSummary: output.RecommendationSummary != null
3431
- ? de_ReservationPurchaseRecommendationSummary(output.RecommendationSummary, context)
3432
- : undefined,
3433
- ServiceSpecification: output.ServiceSpecification != null ? de_ServiceSpecification(output.ServiceSpecification, context) : undefined,
3434
- TermInYears: __expectString(output.TermInYears),
3435
- };
3436
- };
3437
- const de_ReservationPurchaseRecommendationDetail = (output, context) => {
3438
- return {
3439
- AccountId: __expectString(output.AccountId),
3440
- AverageNormalizedUnitsUsedPerHour: __expectString(output.AverageNormalizedUnitsUsedPerHour),
3441
- AverageNumberOfInstancesUsedPerHour: __expectString(output.AverageNumberOfInstancesUsedPerHour),
3442
- AverageUtilization: __expectString(output.AverageUtilization),
3443
- CurrencyCode: __expectString(output.CurrencyCode),
3444
- EstimatedBreakEvenInMonths: __expectString(output.EstimatedBreakEvenInMonths),
3445
- EstimatedMonthlyOnDemandCost: __expectString(output.EstimatedMonthlyOnDemandCost),
3446
- EstimatedMonthlySavingsAmount: __expectString(output.EstimatedMonthlySavingsAmount),
3447
- EstimatedMonthlySavingsPercentage: __expectString(output.EstimatedMonthlySavingsPercentage),
3448
- EstimatedReservationCostForLookbackPeriod: __expectString(output.EstimatedReservationCostForLookbackPeriod),
3449
- InstanceDetails: output.InstanceDetails != null ? de_InstanceDetails(output.InstanceDetails, context) : undefined,
3450
- MaximumNormalizedUnitsUsedPerHour: __expectString(output.MaximumNormalizedUnitsUsedPerHour),
3451
- MaximumNumberOfInstancesUsedPerHour: __expectString(output.MaximumNumberOfInstancesUsedPerHour),
3452
- MinimumNormalizedUnitsUsedPerHour: __expectString(output.MinimumNormalizedUnitsUsedPerHour),
3453
- MinimumNumberOfInstancesUsedPerHour: __expectString(output.MinimumNumberOfInstancesUsedPerHour),
3454
- RecommendedNormalizedUnitsToPurchase: __expectString(output.RecommendedNormalizedUnitsToPurchase),
3455
- RecommendedNumberOfInstancesToPurchase: __expectString(output.RecommendedNumberOfInstancesToPurchase),
3456
- RecurringStandardMonthlyCost: __expectString(output.RecurringStandardMonthlyCost),
3457
- UpfrontCost: __expectString(output.UpfrontCost),
3458
- };
3459
- };
3460
- const de_ReservationPurchaseRecommendationDetails = (output, context) => {
3461
- const retVal = (output || [])
3462
- .filter((e) => e != null)
3463
- .map((entry) => {
3464
- if (entry === null) {
3465
- return null;
3466
- }
3467
- return de_ReservationPurchaseRecommendationDetail(entry, context);
3468
- });
3469
- return retVal;
3470
- };
3471
- const de_ReservationPurchaseRecommendationMetadata = (output, context) => {
3472
- return {
3473
- GenerationTimestamp: __expectString(output.GenerationTimestamp),
3474
- RecommendationId: __expectString(output.RecommendationId),
3475
- };
3476
- };
3477
- const de_ReservationPurchaseRecommendations = (output, context) => {
3478
- const retVal = (output || [])
3479
- .filter((e) => e != null)
3480
- .map((entry) => {
3481
- if (entry === null) {
3482
- return null;
3483
- }
3484
- return de_ReservationPurchaseRecommendation(entry, context);
3485
- });
3486
- return retVal;
3487
- };
3488
- const de_ReservationPurchaseRecommendationSummary = (output, context) => {
3489
- return {
3490
- CurrencyCode: __expectString(output.CurrencyCode),
3491
- TotalEstimatedMonthlySavingsAmount: __expectString(output.TotalEstimatedMonthlySavingsAmount),
3492
- TotalEstimatedMonthlySavingsPercentage: __expectString(output.TotalEstimatedMonthlySavingsPercentage),
3493
- };
3494
- };
3495
- const de_ReservationUtilizationGroup = (output, context) => {
3496
- return {
3497
- Attributes: output.Attributes != null ? de_Attributes(output.Attributes, context) : undefined,
3498
- Key: __expectString(output.Key),
3499
- Utilization: output.Utilization != null ? de_ReservationAggregates(output.Utilization, context) : undefined,
3500
- Value: __expectString(output.Value),
3501
- };
3502
- };
3503
- const de_ReservationUtilizationGroups = (output, context) => {
3504
- const retVal = (output || [])
3505
- .filter((e) => e != null)
3506
- .map((entry) => {
3507
- if (entry === null) {
3508
- return null;
3509
- }
3510
- return de_ReservationUtilizationGroup(entry, context);
3511
- });
3512
- return retVal;
3513
- };
3514
- const de_ResourceDetails = (output, context) => {
3515
- return {
3516
- EC2ResourceDetails: output.EC2ResourceDetails != null ? de_EC2ResourceDetails(output.EC2ResourceDetails, context) : undefined,
3517
- };
3518
- };
3519
- const de_ResourceNotFoundException = (output, context) => {
3520
- return {
3521
- Message: __expectString(output.Message),
3522
- ResourceName: __expectString(output.ResourceName),
3523
- };
3524
- };
3525
- const de_ResourceTag = (output, context) => {
3526
- return {
3527
- Key: __expectString(output.Key),
3528
- Value: __expectString(output.Value),
3529
- };
3530
- };
3531
- const de_ResourceTagList = (output, context) => {
3532
- const retVal = (output || [])
3533
- .filter((e) => e != null)
3534
- .map((entry) => {
3535
- if (entry === null) {
3536
- return null;
3537
- }
3538
- return de_ResourceTag(entry, context);
3539
- });
3540
- return retVal;
3541
- };
3542
- const de_ResourceUtilization = (output, context) => {
3543
- return {
3544
- EC2ResourceUtilization: output.EC2ResourceUtilization != null
3545
- ? de_EC2ResourceUtilization(output.EC2ResourceUtilization, context)
3546
- : undefined,
3547
- };
3548
- };
3549
- const de_ResultByTime = (output, context) => {
3550
- return {
3551
- Estimated: __expectBoolean(output.Estimated),
3552
- Groups: output.Groups != null ? de_Groups(output.Groups, context) : undefined,
3553
- TimePeriod: output.TimePeriod != null ? de_DateInterval(output.TimePeriod, context) : undefined,
3554
- Total: output.Total != null ? de_Metrics(output.Total, context) : undefined,
3555
- };
3556
- };
3557
- const de_ResultsByTime = (output, context) => {
3558
- const retVal = (output || [])
3559
- .filter((e) => e != null)
3560
- .map((entry) => {
3561
- if (entry === null) {
3562
- return null;
3563
- }
3564
- return de_ResultByTime(entry, context);
3565
- });
3566
- return retVal;
3567
- };
3568
- const de_RightsizingRecommendation = (output, context) => {
3569
- return {
3570
- AccountId: __expectString(output.AccountId),
3571
- CurrentInstance: output.CurrentInstance != null ? de_CurrentInstance(output.CurrentInstance, context) : undefined,
3572
- FindingReasonCodes: output.FindingReasonCodes != null ? de_FindingReasonCodes(output.FindingReasonCodes, context) : undefined,
3573
- ModifyRecommendationDetail: output.ModifyRecommendationDetail != null
3574
- ? de_ModifyRecommendationDetail(output.ModifyRecommendationDetail, context)
3575
- : undefined,
3576
- RightsizingType: __expectString(output.RightsizingType),
3577
- TerminateRecommendationDetail: output.TerminateRecommendationDetail != null
3578
- ? de_TerminateRecommendationDetail(output.TerminateRecommendationDetail, context)
3579
- : undefined,
3580
- };
3581
- };
3582
- const de_RightsizingRecommendationConfiguration = (output, context) => {
3583
- return {
3584
- BenefitsConsidered: __expectBoolean(output.BenefitsConsidered),
3585
- RecommendationTarget: __expectString(output.RecommendationTarget),
3586
- };
3587
- };
3588
- const de_RightsizingRecommendationList = (output, context) => {
3589
- const retVal = (output || [])
3590
- .filter((e) => e != null)
3591
- .map((entry) => {
3592
- if (entry === null) {
3593
- return null;
3594
- }
3595
- return de_RightsizingRecommendation(entry, context);
2019
+ const de_AnomalyScore = (output, context) => {
2020
+ return take(output, {
2021
+ CurrentScore: __limitedParseDouble,
2022
+ MaxScore: __limitedParseDouble,
3596
2023
  });
3597
- return retVal;
3598
- };
3599
- const de_RightsizingRecommendationMetadata = (output, context) => {
3600
- return {
3601
- AdditionalMetadata: __expectString(output.AdditionalMetadata),
3602
- GenerationTimestamp: __expectString(output.GenerationTimestamp),
3603
- LookbackPeriodInDays: __expectString(output.LookbackPeriodInDays),
3604
- RecommendationId: __expectString(output.RecommendationId),
3605
- };
3606
- };
3607
- const de_RightsizingRecommendationSummary = (output, context) => {
3608
- return {
3609
- EstimatedTotalMonthlySavingsAmount: __expectString(output.EstimatedTotalMonthlySavingsAmount),
3610
- SavingsCurrencyCode: __expectString(output.SavingsCurrencyCode),
3611
- SavingsPercentage: __expectString(output.SavingsPercentage),
3612
- TotalRecommendationCount: __expectString(output.TotalRecommendationCount),
3613
- };
3614
- };
3615
- const de_RootCause = (output, context) => {
3616
- return {
3617
- LinkedAccount: __expectString(output.LinkedAccount),
3618
- LinkedAccountName: __expectString(output.LinkedAccountName),
3619
- Region: __expectString(output.Region),
3620
- Service: __expectString(output.Service),
3621
- UsageType: __expectString(output.UsageType),
3622
- };
3623
2024
  };
3624
- const de_RootCauses = (output, context) => {
3625
- const retVal = (output || [])
3626
- .filter((e) => e != null)
3627
- .map((entry) => {
3628
- if (entry === null) {
3629
- return null;
3630
- }
3631
- return de_RootCause(entry, context);
2025
+ const de_AnomalySubscription = (output, context) => {
2026
+ return take(output, {
2027
+ AccountId: __expectString,
2028
+ Frequency: __expectString,
2029
+ MonitorArnList: _json,
2030
+ Subscribers: _json,
2031
+ SubscriptionArn: __expectString,
2032
+ SubscriptionName: __expectString,
2033
+ Threshold: __limitedParseDouble,
2034
+ ThresholdExpression: (_) => de_Expression(_, context),
3632
2035
  });
3633
- return retVal;
3634
- };
3635
- const de_SavingsPlansAmortizedCommitment = (output, context) => {
3636
- return {
3637
- AmortizedRecurringCommitment: __expectString(output.AmortizedRecurringCommitment),
3638
- AmortizedUpfrontCommitment: __expectString(output.AmortizedUpfrontCommitment),
3639
- TotalAmortizedCommitment: __expectString(output.TotalAmortizedCommitment),
3640
- };
3641
- };
3642
- const de_SavingsPlansCoverage = (output, context) => {
3643
- return {
3644
- Attributes: output.Attributes != null ? de_Attributes(output.Attributes, context) : undefined,
3645
- Coverage: output.Coverage != null ? de_SavingsPlansCoverageData(output.Coverage, context) : undefined,
3646
- TimePeriod: output.TimePeriod != null ? de_DateInterval(output.TimePeriod, context) : undefined,
3647
- };
3648
2036
  };
3649
- const de_SavingsPlansCoverageData = (output, context) => {
3650
- return {
3651
- CoveragePercentage: __expectString(output.CoveragePercentage),
3652
- OnDemandCost: __expectString(output.OnDemandCost),
3653
- SpendCoveredBySavingsPlans: __expectString(output.SpendCoveredBySavingsPlans),
3654
- TotalCost: __expectString(output.TotalCost),
3655
- };
3656
- };
3657
- const de_SavingsPlansCoverages = (output, context) => {
2037
+ const de_AnomalySubscriptions = (output, context) => {
3658
2038
  const retVal = (output || [])
3659
2039
  .filter((e) => e != null)
3660
2040
  .map((entry) => {
3661
- if (entry === null) {
3662
- return null;
3663
- }
3664
- return de_SavingsPlansCoverage(entry, context);
2041
+ return de_AnomalySubscription(entry, context);
3665
2042
  });
3666
2043
  return retVal;
3667
2044
  };
3668
- const de_SavingsPlansDetails = (output, context) => {
3669
- return {
3670
- InstanceFamily: __expectString(output.InstanceFamily),
3671
- OfferingId: __expectString(output.OfferingId),
3672
- Region: __expectString(output.Region),
3673
- };
3674
- };
3675
- const de_SavingsPlansPurchaseRecommendation = (output, context) => {
3676
- return {
3677
- AccountScope: __expectString(output.AccountScope),
3678
- LookbackPeriodInDays: __expectString(output.LookbackPeriodInDays),
3679
- PaymentOption: __expectString(output.PaymentOption),
3680
- SavingsPlansPurchaseRecommendationDetails: output.SavingsPlansPurchaseRecommendationDetails != null
3681
- ? de_SavingsPlansPurchaseRecommendationDetailList(output.SavingsPlansPurchaseRecommendationDetails, context)
3682
- : undefined,
3683
- SavingsPlansPurchaseRecommendationSummary: output.SavingsPlansPurchaseRecommendationSummary != null
3684
- ? de_SavingsPlansPurchaseRecommendationSummary(output.SavingsPlansPurchaseRecommendationSummary, context)
3685
- : undefined,
3686
- SavingsPlansType: __expectString(output.SavingsPlansType),
3687
- TermInYears: __expectString(output.TermInYears),
3688
- };
3689
- };
3690
- const de_SavingsPlansPurchaseRecommendationDetail = (output, context) => {
3691
- return {
3692
- AccountId: __expectString(output.AccountId),
3693
- CurrencyCode: __expectString(output.CurrencyCode),
3694
- CurrentAverageHourlyOnDemandSpend: __expectString(output.CurrentAverageHourlyOnDemandSpend),
3695
- CurrentMaximumHourlyOnDemandSpend: __expectString(output.CurrentMaximumHourlyOnDemandSpend),
3696
- CurrentMinimumHourlyOnDemandSpend: __expectString(output.CurrentMinimumHourlyOnDemandSpend),
3697
- EstimatedAverageUtilization: __expectString(output.EstimatedAverageUtilization),
3698
- EstimatedMonthlySavingsAmount: __expectString(output.EstimatedMonthlySavingsAmount),
3699
- EstimatedOnDemandCost: __expectString(output.EstimatedOnDemandCost),
3700
- EstimatedOnDemandCostWithCurrentCommitment: __expectString(output.EstimatedOnDemandCostWithCurrentCommitment),
3701
- EstimatedROI: __expectString(output.EstimatedROI),
3702
- EstimatedSPCost: __expectString(output.EstimatedSPCost),
3703
- EstimatedSavingsAmount: __expectString(output.EstimatedSavingsAmount),
3704
- EstimatedSavingsPercentage: __expectString(output.EstimatedSavingsPercentage),
3705
- HourlyCommitmentToPurchase: __expectString(output.HourlyCommitmentToPurchase),
3706
- SavingsPlansDetails: output.SavingsPlansDetails != null ? de_SavingsPlansDetails(output.SavingsPlansDetails, context) : undefined,
3707
- UpfrontCost: __expectString(output.UpfrontCost),
3708
- };
3709
- };
3710
- const de_SavingsPlansPurchaseRecommendationDetailList = (output, context) => {
3711
- const retVal = (output || [])
3712
- .filter((e) => e != null)
3713
- .map((entry) => {
3714
- if (entry === null) {
3715
- return null;
3716
- }
3717
- return de_SavingsPlansPurchaseRecommendationDetail(entry, context);
2045
+ const de_CostCategory = (output, context) => {
2046
+ return take(output, {
2047
+ CostCategoryArn: __expectString,
2048
+ DefaultValue: __expectString,
2049
+ EffectiveEnd: __expectString,
2050
+ EffectiveStart: __expectString,
2051
+ Name: __expectString,
2052
+ ProcessingStatus: _json,
2053
+ RuleVersion: __expectString,
2054
+ Rules: (_) => de_CostCategoryRulesList(_, context),
2055
+ SplitChargeRules: _json,
3718
2056
  });
3719
- return retVal;
3720
- };
3721
- const de_SavingsPlansPurchaseRecommendationMetadata = (output, context) => {
3722
- return {
3723
- AdditionalMetadata: __expectString(output.AdditionalMetadata),
3724
- GenerationTimestamp: __expectString(output.GenerationTimestamp),
3725
- RecommendationId: __expectString(output.RecommendationId),
3726
- };
3727
- };
3728
- const de_SavingsPlansPurchaseRecommendationSummary = (output, context) => {
3729
- return {
3730
- CurrencyCode: __expectString(output.CurrencyCode),
3731
- CurrentOnDemandSpend: __expectString(output.CurrentOnDemandSpend),
3732
- DailyCommitmentToPurchase: __expectString(output.DailyCommitmentToPurchase),
3733
- EstimatedMonthlySavingsAmount: __expectString(output.EstimatedMonthlySavingsAmount),
3734
- EstimatedOnDemandCostWithCurrentCommitment: __expectString(output.EstimatedOnDemandCostWithCurrentCommitment),
3735
- EstimatedROI: __expectString(output.EstimatedROI),
3736
- EstimatedSavingsAmount: __expectString(output.EstimatedSavingsAmount),
3737
- EstimatedSavingsPercentage: __expectString(output.EstimatedSavingsPercentage),
3738
- EstimatedTotalCost: __expectString(output.EstimatedTotalCost),
3739
- HourlyCommitmentToPurchase: __expectString(output.HourlyCommitmentToPurchase),
3740
- TotalRecommendationCount: __expectString(output.TotalRecommendationCount),
3741
- };
3742
- };
3743
- const de_SavingsPlansSavings = (output, context) => {
3744
- return {
3745
- NetSavings: __expectString(output.NetSavings),
3746
- OnDemandCostEquivalent: __expectString(output.OnDemandCostEquivalent),
3747
- };
3748
- };
3749
- const de_SavingsPlansUtilization = (output, context) => {
3750
- return {
3751
- TotalCommitment: __expectString(output.TotalCommitment),
3752
- UnusedCommitment: __expectString(output.UnusedCommitment),
3753
- UsedCommitment: __expectString(output.UsedCommitment),
3754
- UtilizationPercentage: __expectString(output.UtilizationPercentage),
3755
- };
3756
- };
3757
- const de_SavingsPlansUtilizationAggregates = (output, context) => {
3758
- return {
3759
- AmortizedCommitment: output.AmortizedCommitment != null
3760
- ? de_SavingsPlansAmortizedCommitment(output.AmortizedCommitment, context)
3761
- : undefined,
3762
- Savings: output.Savings != null ? de_SavingsPlansSavings(output.Savings, context) : undefined,
3763
- Utilization: output.Utilization != null ? de_SavingsPlansUtilization(output.Utilization, context) : undefined,
3764
- };
3765
- };
3766
- const de_SavingsPlansUtilizationByTime = (output, context) => {
3767
- return {
3768
- AmortizedCommitment: output.AmortizedCommitment != null
3769
- ? de_SavingsPlansAmortizedCommitment(output.AmortizedCommitment, context)
3770
- : undefined,
3771
- Savings: output.Savings != null ? de_SavingsPlansSavings(output.Savings, context) : undefined,
3772
- TimePeriod: output.TimePeriod != null ? de_DateInterval(output.TimePeriod, context) : undefined,
3773
- Utilization: output.Utilization != null ? de_SavingsPlansUtilization(output.Utilization, context) : undefined,
3774
- };
3775
- };
3776
- const de_SavingsPlansUtilizationDetail = (output, context) => {
3777
- return {
3778
- AmortizedCommitment: output.AmortizedCommitment != null
3779
- ? de_SavingsPlansAmortizedCommitment(output.AmortizedCommitment, context)
3780
- : undefined,
3781
- Attributes: output.Attributes != null ? de_Attributes(output.Attributes, context) : undefined,
3782
- Savings: output.Savings != null ? de_SavingsPlansSavings(output.Savings, context) : undefined,
3783
- SavingsPlanArn: __expectString(output.SavingsPlanArn),
3784
- Utilization: output.Utilization != null ? de_SavingsPlansUtilization(output.Utilization, context) : undefined,
3785
- };
3786
2057
  };
3787
- const de_SavingsPlansUtilizationDetails = (output, context) => {
3788
- const retVal = (output || [])
3789
- .filter((e) => e != null)
3790
- .map((entry) => {
3791
- if (entry === null) {
3792
- return null;
3793
- }
3794
- return de_SavingsPlansUtilizationDetail(entry, context);
2058
+ const de_CostCategoryRule = (output, context) => {
2059
+ return take(output, {
2060
+ InheritedValue: _json,
2061
+ Rule: (_) => de_Expression(_, context),
2062
+ Type: __expectString,
2063
+ Value: __expectString,
3795
2064
  });
3796
- return retVal;
3797
2065
  };
3798
- const de_SavingsPlansUtilizationsByTime = (output, context) => {
2066
+ const de_CostCategoryRulesList = (output, context) => {
3799
2067
  const retVal = (output || [])
3800
2068
  .filter((e) => e != null)
3801
2069
  .map((entry) => {
3802
- if (entry === null) {
3803
- return null;
3804
- }
3805
- return de_SavingsPlansUtilizationByTime(entry, context);
2070
+ return de_CostCategoryRule(entry, context);
3806
2071
  });
3807
2072
  return retVal;
3808
2073
  };
3809
- const de_ServiceQuotaExceededException = (output, context) => {
3810
- return {
3811
- Message: __expectString(output.Message),
3812
- };
3813
- };
3814
- const de_ServiceSpecification = (output, context) => {
3815
- return {
3816
- EC2Specification: output.EC2Specification != null ? de_EC2Specification(output.EC2Specification, context) : undefined,
3817
- };
3818
- };
3819
- const de_StartSavingsPlansPurchaseRecommendationGenerationResponse = (output, context) => {
3820
- return {
3821
- EstimatedCompletionTime: __expectString(output.EstimatedCompletionTime),
3822
- GenerationStartedTime: __expectString(output.GenerationStartedTime),
3823
- RecommendationId: __expectString(output.RecommendationId),
3824
- };
3825
- };
3826
- const de_Subscriber = (output, context) => {
3827
- return {
3828
- Address: __expectString(output.Address),
3829
- Status: __expectString(output.Status),
3830
- Type: __expectString(output.Type),
3831
- };
3832
- };
3833
- const de_Subscribers = (output, context) => {
3834
- const retVal = (output || [])
3835
- .filter((e) => e != null)
3836
- .map((entry) => {
3837
- if (entry === null) {
3838
- return null;
3839
- }
3840
- return de_Subscriber(entry, context);
2074
+ const de_DescribeCostCategoryDefinitionResponse = (output, context) => {
2075
+ return take(output, {
2076
+ CostCategory: (_) => de_CostCategory(_, context),
3841
2077
  });
3842
- return retVal;
3843
2078
  };
3844
- const de_TagList = (output, context) => {
3845
- const retVal = (output || [])
3846
- .filter((e) => e != null)
3847
- .map((entry) => {
3848
- if (entry === null) {
3849
- return null;
3850
- }
3851
- return __expectString(entry);
2079
+ const de_Expression = (output, context) => {
2080
+ return take(output, {
2081
+ And: (_) => de_Expressions(_, context),
2082
+ CostCategories: _json,
2083
+ Dimensions: _json,
2084
+ Not: (_) => de_Expression(_, context),
2085
+ Or: (_) => de_Expressions(_, context),
2086
+ Tags: _json,
3852
2087
  });
3853
- return retVal;
3854
- };
3855
- const de_TagResourceResponse = (output, context) => {
3856
- return {};
3857
- };
3858
- const de_TagValues = (output, context) => {
3859
- return {
3860
- Key: __expectString(output.Key),
3861
- MatchOptions: output.MatchOptions != null ? de_MatchOptions(output.MatchOptions, context) : undefined,
3862
- Values: output.Values != null ? de_Values(output.Values, context) : undefined,
3863
- };
3864
2088
  };
3865
- const de_TagValuesList = (output, context) => {
2089
+ const de_Expressions = (output, context) => {
3866
2090
  const retVal = (output || [])
3867
2091
  .filter((e) => e != null)
3868
2092
  .map((entry) => {
3869
- if (entry === null) {
3870
- return null;
3871
- }
3872
- return de_TagValues(entry, context);
2093
+ return de_Expression(entry, context);
3873
2094
  });
3874
2095
  return retVal;
3875
2096
  };
3876
- const de_TargetInstance = (output, context) => {
3877
- return {
3878
- CurrencyCode: __expectString(output.CurrencyCode),
3879
- DefaultTargetInstance: __expectBoolean(output.DefaultTargetInstance),
3880
- EstimatedMonthlyCost: __expectString(output.EstimatedMonthlyCost),
3881
- EstimatedMonthlySavings: __expectString(output.EstimatedMonthlySavings),
3882
- ExpectedResourceUtilization: output.ExpectedResourceUtilization != null
3883
- ? de_ResourceUtilization(output.ExpectedResourceUtilization, context)
3884
- : undefined,
3885
- PlatformDifferences: output.PlatformDifferences != null ? de_PlatformDifferences(output.PlatformDifferences, context) : undefined,
3886
- ResourceDetails: output.ResourceDetails != null ? de_ResourceDetails(output.ResourceDetails, context) : undefined,
3887
- };
3888
- };
3889
- const de_TargetInstancesList = (output, context) => {
3890
- const retVal = (output || [])
3891
- .filter((e) => e != null)
3892
- .map((entry) => {
3893
- if (entry === null) {
3894
- return null;
3895
- }
3896
- return de_TargetInstance(entry, context);
2097
+ const de_GetAnomaliesResponse = (output, context) => {
2098
+ return take(output, {
2099
+ Anomalies: (_) => de_Anomalies(_, context),
2100
+ NextPageToken: __expectString,
3897
2101
  });
3898
- return retVal;
3899
- };
3900
- const de_TerminateRecommendationDetail = (output, context) => {
3901
- return {
3902
- CurrencyCode: __expectString(output.CurrencyCode),
3903
- EstimatedMonthlySavings: __expectString(output.EstimatedMonthlySavings),
3904
- };
3905
- };
3906
- const de_TooManyTagsException = (output, context) => {
3907
- return {
3908
- Message: __expectString(output.Message),
3909
- ResourceName: __expectString(output.ResourceName),
3910
- };
3911
- };
3912
- const de_UnknownMonitorException = (output, context) => {
3913
- return {
3914
- Message: __expectString(output.Message),
3915
- };
3916
- };
3917
- const de_UnknownSubscriptionException = (output, context) => {
3918
- return {
3919
- Message: __expectString(output.Message),
3920
- };
3921
- };
3922
- const de_UnresolvableUsageUnitException = (output, context) => {
3923
- return {
3924
- Message: __expectString(output.Message),
3925
- };
3926
- };
3927
- const de_UntagResourceResponse = (output, context) => {
3928
- return {};
3929
- };
3930
- const de_UpdateAnomalyMonitorResponse = (output, context) => {
3931
- return {
3932
- MonitorArn: __expectString(output.MonitorArn),
3933
- };
3934
- };
3935
- const de_UpdateAnomalySubscriptionResponse = (output, context) => {
3936
- return {
3937
- SubscriptionArn: __expectString(output.SubscriptionArn),
3938
- };
3939
- };
3940
- const de_UpdateCostAllocationTagsStatusError = (output, context) => {
3941
- return {
3942
- Code: __expectString(output.Code),
3943
- Message: __expectString(output.Message),
3944
- TagKey: __expectString(output.TagKey),
3945
- };
3946
2102
  };
3947
- const de_UpdateCostAllocationTagsStatusErrors = (output, context) => {
3948
- const retVal = (output || [])
3949
- .filter((e) => e != null)
3950
- .map((entry) => {
3951
- if (entry === null) {
3952
- return null;
3953
- }
3954
- return de_UpdateCostAllocationTagsStatusError(entry, context);
2103
+ const de_GetAnomalyMonitorsResponse = (output, context) => {
2104
+ return take(output, {
2105
+ AnomalyMonitors: (_) => de_AnomalyMonitors(_, context),
2106
+ NextPageToken: __expectString,
3955
2107
  });
3956
- return retVal;
3957
- };
3958
- const de_UpdateCostAllocationTagsStatusResponse = (output, context) => {
3959
- return {
3960
- Errors: output.Errors != null ? de_UpdateCostAllocationTagsStatusErrors(output.Errors, context) : undefined,
3961
- };
3962
- };
3963
- const de_UpdateCostCategoryDefinitionResponse = (output, context) => {
3964
- return {
3965
- CostCategoryArn: __expectString(output.CostCategoryArn),
3966
- EffectiveStart: __expectString(output.EffectiveStart),
3967
- };
3968
- };
3969
- const de_UtilizationByTime = (output, context) => {
3970
- return {
3971
- Groups: output.Groups != null ? de_ReservationUtilizationGroups(output.Groups, context) : undefined,
3972
- TimePeriod: output.TimePeriod != null ? de_DateInterval(output.TimePeriod, context) : undefined,
3973
- Total: output.Total != null ? de_ReservationAggregates(output.Total, context) : undefined,
3974
- };
3975
2108
  };
3976
- const de_UtilizationsByTime = (output, context) => {
3977
- const retVal = (output || [])
3978
- .filter((e) => e != null)
3979
- .map((entry) => {
3980
- if (entry === null) {
3981
- return null;
3982
- }
3983
- return de_UtilizationByTime(entry, context);
2109
+ const de_GetAnomalySubscriptionsResponse = (output, context) => {
2110
+ return take(output, {
2111
+ AnomalySubscriptions: (_) => de_AnomalySubscriptions(_, context),
2112
+ NextPageToken: __expectString,
3984
2113
  });
3985
- return retVal;
3986
2114
  };
3987
- const de_Values = (output, context) => {
3988
- const retVal = (output || [])
3989
- .filter((e) => e != null)
3990
- .map((entry) => {
3991
- if (entry === null) {
3992
- return null;
3993
- }
3994
- return __expectString(entry);
2115
+ const de_Impact = (output, context) => {
2116
+ return take(output, {
2117
+ MaxImpact: __limitedParseDouble,
2118
+ TotalActualSpend: __limitedParseDouble,
2119
+ TotalExpectedSpend: __limitedParseDouble,
2120
+ TotalImpact: __limitedParseDouble,
2121
+ TotalImpactPercentage: __limitedParseDouble,
3995
2122
  });
3996
- return retVal;
3997
2123
  };
3998
2124
  const deserializeMetadata = (output) => ({
3999
2125
  httpStatusCode: output.statusCode,
@@ -4008,6 +2134,7 @@ const collectBody = (streamBody = new Uint8Array(), context) => {
4008
2134
  return context.streamCollector(streamBody) || Promise.resolve(new Uint8Array());
4009
2135
  };
4010
2136
  const collectBodyString = (streamBody, context) => collectBody(streamBody, context).then((body) => context.utf8Encoder(body));
2137
+ const throwDefaultError = withBaseException(__BaseException);
4011
2138
  const buildHttpRpcRequest = async (context, headers, path, resolvedHostname, body) => {
4012
2139
  const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
4013
2140
  const contents = {
@@ -4026,6 +2153,12 @@ const buildHttpRpcRequest = async (context, headers, path, resolvedHostname, bod
4026
2153
  }
4027
2154
  return new __HttpRequest(contents);
4028
2155
  };
2156
+ function sharedHeaders(operation) {
2157
+ return {
2158
+ "content-type": "application/x-amz-json-1.1",
2159
+ "x-amz-target": `AWSInsightsIndexService.${operation}`,
2160
+ };
2161
+ }
4029
2162
  const parseBody = (streamBody, context) => collectBodyString(streamBody, context).then((encoded) => {
4030
2163
  if (encoded.length) {
4031
2164
  return JSON.parse(encoded);