@aws-sdk/client-greengrassv2 3.927.0 → 3.929.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.
Files changed (50) hide show
  1. package/dist-cjs/index.js +1621 -1496
  2. package/dist-cjs/runtimeConfig.shared.js +2 -0
  3. package/dist-es/GreengrassV2Client.js +2 -0
  4. package/dist-es/commands/AssociateServiceRoleToAccountCommand.js +3 -9
  5. package/dist-es/commands/BatchAssociateClientDeviceWithCoreDeviceCommand.js +3 -9
  6. package/dist-es/commands/BatchDisassociateClientDeviceFromCoreDeviceCommand.js +3 -9
  7. package/dist-es/commands/CancelDeploymentCommand.js +3 -9
  8. package/dist-es/commands/CreateComponentVersionCommand.js +3 -9
  9. package/dist-es/commands/CreateDeploymentCommand.js +3 -9
  10. package/dist-es/commands/DeleteComponentCommand.js +3 -9
  11. package/dist-es/commands/DeleteCoreDeviceCommand.js +3 -9
  12. package/dist-es/commands/DeleteDeploymentCommand.js +3 -9
  13. package/dist-es/commands/DescribeComponentCommand.js +3 -9
  14. package/dist-es/commands/DisassociateServiceRoleFromAccountCommand.js +3 -9
  15. package/dist-es/commands/GetComponentCommand.js +3 -9
  16. package/dist-es/commands/GetComponentVersionArtifactCommand.js +3 -9
  17. package/dist-es/commands/GetConnectivityInfoCommand.js +3 -9
  18. package/dist-es/commands/GetCoreDeviceCommand.js +3 -9
  19. package/dist-es/commands/GetDeploymentCommand.js +3 -9
  20. package/dist-es/commands/GetServiceRoleForAccountCommand.js +3 -9
  21. package/dist-es/commands/ListClientDevicesAssociatedWithCoreDeviceCommand.js +3 -9
  22. package/dist-es/commands/ListComponentVersionsCommand.js +3 -9
  23. package/dist-es/commands/ListComponentsCommand.js +3 -9
  24. package/dist-es/commands/ListCoreDevicesCommand.js +3 -9
  25. package/dist-es/commands/ListDeploymentsCommand.js +3 -9
  26. package/dist-es/commands/ListEffectiveDeploymentsCommand.js +3 -9
  27. package/dist-es/commands/ListInstalledComponentsCommand.js +3 -9
  28. package/dist-es/commands/ListTagsForResourceCommand.js +3 -9
  29. package/dist-es/commands/ResolveComponentCandidatesCommand.js +3 -9
  30. package/dist-es/commands/TagResourceCommand.js +3 -9
  31. package/dist-es/commands/UntagResourceCommand.js +3 -9
  32. package/dist-es/commands/UpdateConnectivityInfoCommand.js +3 -9
  33. package/dist-es/runtimeConfig.shared.js +2 -0
  34. package/dist-es/schemas/schemas_0.js +1561 -0
  35. package/dist-types/GreengrassV2Client.d.ts +10 -1
  36. package/dist-types/runtimeConfig.browser.d.ts +1 -0
  37. package/dist-types/runtimeConfig.d.ts +1 -0
  38. package/dist-types/runtimeConfig.native.d.ts +1 -0
  39. package/dist-types/runtimeConfig.shared.d.ts +1 -0
  40. package/dist-types/schemas/schemas_0.d.ts +169 -0
  41. package/dist-types/ts3.4/GreengrassV2Client.d.ts +4 -0
  42. package/dist-types/ts3.4/runtimeConfig.browser.d.ts +4 -0
  43. package/dist-types/ts3.4/runtimeConfig.d.ts +4 -0
  44. package/dist-types/ts3.4/runtimeConfig.native.d.ts +4 -0
  45. package/dist-types/ts3.4/runtimeConfig.shared.d.ts +4 -0
  46. package/dist-types/ts3.4/schemas/schemas_0.d.ts +175 -0
  47. package/package.json +5 -6
  48. package/dist-es/protocols/Aws_restJson1.js +0 -1283
  49. package/dist-types/protocols/Aws_restJson1.d.ts +0 -263
  50. package/dist-types/ts3.4/protocols/Aws_restJson1.d.ts +0 -353
@@ -1,1283 +0,0 @@
1
- import { loadRestJsonErrorCode, parseJsonBody as parseBody, parseJsonErrorBody as parseErrorBody } from "@aws-sdk/core";
2
- import { requestBuilder as rb } from "@smithy/core";
3
- import { _json, collectBody, decorateServiceException as __decorateServiceException, expectBoolean as __expectBoolean, expectInt32 as __expectInt32, expectLong as __expectLong, expectNonNull as __expectNonNull, expectNumber as __expectNumber, expectObject as __expectObject, expectString as __expectString, isSerializableHeaderValue, limitedParseDouble as __limitedParseDouble, map, parseEpochTimestamp as __parseEpochTimestamp, serializeFloat as __serializeFloat, strictParseInt32 as __strictParseInt32, take, withBaseException, } from "@smithy/smithy-client";
4
- import { v4 as generateIdempotencyToken } from "@smithy/uuid";
5
- import { GreengrassV2ServiceException as __BaseException } from "../models/GreengrassV2ServiceException";
6
- import { AccessDeniedException, ConflictException, InternalServerException, RequestAlreadyInProgressException, ResourceNotFoundException, ServiceQuotaExceededException, ThrottlingException, ValidationException, } from "../models/models_0";
7
- export const se_AssociateServiceRoleToAccountCommand = async (input, context) => {
8
- const b = rb(input, context);
9
- const headers = {
10
- "content-type": "application/json",
11
- };
12
- b.bp("/greengrass/servicerole");
13
- let body;
14
- body = JSON.stringify(take(input, {
15
- RoleArn: [, , `roleArn`],
16
- }));
17
- b.m("PUT").h(headers).b(body);
18
- return b.build();
19
- };
20
- export const se_BatchAssociateClientDeviceWithCoreDeviceCommand = async (input, context) => {
21
- const b = rb(input, context);
22
- const headers = {
23
- "content-type": "application/json",
24
- };
25
- b.bp("/greengrass/v2/coreDevices/{coreDeviceThingName}/associateClientDevices");
26
- b.p("coreDeviceThingName", () => input.coreDeviceThingName, "{coreDeviceThingName}", false);
27
- let body;
28
- body = JSON.stringify(take(input, {
29
- entries: (_) => _json(_),
30
- }));
31
- b.m("POST").h(headers).b(body);
32
- return b.build();
33
- };
34
- export const se_BatchDisassociateClientDeviceFromCoreDeviceCommand = async (input, context) => {
35
- const b = rb(input, context);
36
- const headers = {
37
- "content-type": "application/json",
38
- };
39
- b.bp("/greengrass/v2/coreDevices/{coreDeviceThingName}/disassociateClientDevices");
40
- b.p("coreDeviceThingName", () => input.coreDeviceThingName, "{coreDeviceThingName}", false);
41
- let body;
42
- body = JSON.stringify(take(input, {
43
- entries: (_) => _json(_),
44
- }));
45
- b.m("POST").h(headers).b(body);
46
- return b.build();
47
- };
48
- export const se_CancelDeploymentCommand = async (input, context) => {
49
- const b = rb(input, context);
50
- const headers = {};
51
- b.bp("/greengrass/v2/deployments/{deploymentId}/cancel");
52
- b.p("deploymentId", () => input.deploymentId, "{deploymentId}", false);
53
- let body;
54
- b.m("POST").h(headers).b(body);
55
- return b.build();
56
- };
57
- export const se_CreateComponentVersionCommand = async (input, context) => {
58
- const b = rb(input, context);
59
- const headers = {
60
- "content-type": "application/json",
61
- };
62
- b.bp("/greengrass/v2/createComponentVersion");
63
- let body;
64
- body = JSON.stringify(take(input, {
65
- clientToken: [true, (_) => _ ?? generateIdempotencyToken()],
66
- inlineRecipe: (_) => context.base64Encoder(_),
67
- lambdaFunction: (_) => _json(_),
68
- tags: (_) => _json(_),
69
- }));
70
- b.m("POST").h(headers).b(body);
71
- return b.build();
72
- };
73
- export const se_CreateDeploymentCommand = async (input, context) => {
74
- const b = rb(input, context);
75
- const headers = {
76
- "content-type": "application/json",
77
- };
78
- b.bp("/greengrass/v2/deployments");
79
- let body;
80
- body = JSON.stringify(take(input, {
81
- clientToken: [true, (_) => _ ?? generateIdempotencyToken()],
82
- components: (_) => se_ComponentDeploymentSpecifications(_, context),
83
- deploymentName: [],
84
- deploymentPolicies: (_) => _json(_),
85
- iotJobConfiguration: (_) => se_DeploymentIoTJobConfiguration(_, context),
86
- parentTargetArn: [],
87
- tags: (_) => _json(_),
88
- targetArn: [],
89
- }));
90
- b.m("POST").h(headers).b(body);
91
- return b.build();
92
- };
93
- export const se_DeleteComponentCommand = async (input, context) => {
94
- const b = rb(input, context);
95
- const headers = {};
96
- b.bp("/greengrass/v2/components/{arn}");
97
- b.p("arn", () => input.arn, "{arn}", false);
98
- let body;
99
- b.m("DELETE").h(headers).b(body);
100
- return b.build();
101
- };
102
- export const se_DeleteCoreDeviceCommand = async (input, context) => {
103
- const b = rb(input, context);
104
- const headers = {};
105
- b.bp("/greengrass/v2/coreDevices/{coreDeviceThingName}");
106
- b.p("coreDeviceThingName", () => input.coreDeviceThingName, "{coreDeviceThingName}", false);
107
- let body;
108
- b.m("DELETE").h(headers).b(body);
109
- return b.build();
110
- };
111
- export const se_DeleteDeploymentCommand = async (input, context) => {
112
- const b = rb(input, context);
113
- const headers = {};
114
- b.bp("/greengrass/v2/deployments/{deploymentId}");
115
- b.p("deploymentId", () => input.deploymentId, "{deploymentId}", false);
116
- let body;
117
- b.m("DELETE").h(headers).b(body);
118
- return b.build();
119
- };
120
- export const se_DescribeComponentCommand = async (input, context) => {
121
- const b = rb(input, context);
122
- const headers = {};
123
- b.bp("/greengrass/v2/components/{arn}/metadata");
124
- b.p("arn", () => input.arn, "{arn}", false);
125
- let body;
126
- b.m("GET").h(headers).b(body);
127
- return b.build();
128
- };
129
- export const se_DisassociateServiceRoleFromAccountCommand = async (input, context) => {
130
- const b = rb(input, context);
131
- const headers = {};
132
- b.bp("/greengrass/servicerole");
133
- let body;
134
- b.m("DELETE").h(headers).b(body);
135
- return b.build();
136
- };
137
- export const se_GetComponentCommand = async (input, context) => {
138
- const b = rb(input, context);
139
- const headers = {};
140
- b.bp("/greengrass/v2/components/{arn}");
141
- b.p("arn", () => input.arn, "{arn}", false);
142
- const query = map({
143
- [_rOF]: [, input[_rOF]],
144
- });
145
- let body;
146
- b.m("GET").h(headers).q(query).b(body);
147
- return b.build();
148
- };
149
- export const se_GetComponentVersionArtifactCommand = async (input, context) => {
150
- const b = rb(input, context);
151
- const headers = map({}, isSerializableHeaderValue, {
152
- [_xaiet]: input[_iET],
153
- });
154
- b.bp("/greengrass/v2/components/{arn}/artifacts/{artifactName+}");
155
- b.p("arn", () => input.arn, "{arn}", false);
156
- b.p("artifactName", () => input.artifactName, "{artifactName+}", true);
157
- const query = map({
158
- [_sET]: [, input[_sET]],
159
- });
160
- let body;
161
- b.m("GET").h(headers).q(query).b(body);
162
- return b.build();
163
- };
164
- export const se_GetConnectivityInfoCommand = async (input, context) => {
165
- const b = rb(input, context);
166
- const headers = {};
167
- b.bp("/greengrass/things/{thingName}/connectivityInfo");
168
- b.p("thingName", () => input.thingName, "{thingName}", false);
169
- let body;
170
- b.m("GET").h(headers).b(body);
171
- return b.build();
172
- };
173
- export const se_GetCoreDeviceCommand = async (input, context) => {
174
- const b = rb(input, context);
175
- const headers = {};
176
- b.bp("/greengrass/v2/coreDevices/{coreDeviceThingName}");
177
- b.p("coreDeviceThingName", () => input.coreDeviceThingName, "{coreDeviceThingName}", false);
178
- let body;
179
- b.m("GET").h(headers).b(body);
180
- return b.build();
181
- };
182
- export const se_GetDeploymentCommand = async (input, context) => {
183
- const b = rb(input, context);
184
- const headers = {};
185
- b.bp("/greengrass/v2/deployments/{deploymentId}");
186
- b.p("deploymentId", () => input.deploymentId, "{deploymentId}", false);
187
- let body;
188
- b.m("GET").h(headers).b(body);
189
- return b.build();
190
- };
191
- export const se_GetServiceRoleForAccountCommand = async (input, context) => {
192
- const b = rb(input, context);
193
- const headers = {};
194
- b.bp("/greengrass/servicerole");
195
- let body;
196
- b.m("GET").h(headers).b(body);
197
- return b.build();
198
- };
199
- export const se_ListClientDevicesAssociatedWithCoreDeviceCommand = async (input, context) => {
200
- const b = rb(input, context);
201
- const headers = {};
202
- b.bp("/greengrass/v2/coreDevices/{coreDeviceThingName}/associatedClientDevices");
203
- b.p("coreDeviceThingName", () => input.coreDeviceThingName, "{coreDeviceThingName}", false);
204
- const query = map({
205
- [_mR]: [() => input.maxResults !== void 0, () => input[_mR].toString()],
206
- [_nT]: [, input[_nT]],
207
- });
208
- let body;
209
- b.m("GET").h(headers).q(query).b(body);
210
- return b.build();
211
- };
212
- export const se_ListComponentsCommand = async (input, context) => {
213
- const b = rb(input, context);
214
- const headers = {};
215
- b.bp("/greengrass/v2/components");
216
- const query = map({
217
- [_s]: [, input[_s]],
218
- [_mR]: [() => input.maxResults !== void 0, () => input[_mR].toString()],
219
- [_nT]: [, input[_nT]],
220
- });
221
- let body;
222
- b.m("GET").h(headers).q(query).b(body);
223
- return b.build();
224
- };
225
- export const se_ListComponentVersionsCommand = async (input, context) => {
226
- const b = rb(input, context);
227
- const headers = {};
228
- b.bp("/greengrass/v2/components/{arn}/versions");
229
- b.p("arn", () => input.arn, "{arn}", false);
230
- const query = map({
231
- [_mR]: [() => input.maxResults !== void 0, () => input[_mR].toString()],
232
- [_nT]: [, input[_nT]],
233
- });
234
- let body;
235
- b.m("GET").h(headers).q(query).b(body);
236
- return b.build();
237
- };
238
- export const se_ListCoreDevicesCommand = async (input, context) => {
239
- const b = rb(input, context);
240
- const headers = {};
241
- b.bp("/greengrass/v2/coreDevices");
242
- const query = map({
243
- [_tGA]: [, input[_tGA]],
244
- [_st]: [, input[_st]],
245
- [_mR]: [() => input.maxResults !== void 0, () => input[_mR].toString()],
246
- [_nT]: [, input[_nT]],
247
- [_r]: [, input[_r]],
248
- });
249
- let body;
250
- b.m("GET").h(headers).q(query).b(body);
251
- return b.build();
252
- };
253
- export const se_ListDeploymentsCommand = async (input, context) => {
254
- const b = rb(input, context);
255
- const headers = {};
256
- b.bp("/greengrass/v2/deployments");
257
- const query = map({
258
- [_tA]: [, input[_tA]],
259
- [_hF]: [, input[_hF]],
260
- [_pTA]: [, input[_pTA]],
261
- [_mR]: [() => input.maxResults !== void 0, () => input[_mR].toString()],
262
- [_nT]: [, input[_nT]],
263
- });
264
- let body;
265
- b.m("GET").h(headers).q(query).b(body);
266
- return b.build();
267
- };
268
- export const se_ListEffectiveDeploymentsCommand = async (input, context) => {
269
- const b = rb(input, context);
270
- const headers = {};
271
- b.bp("/greengrass/v2/coreDevices/{coreDeviceThingName}/effectiveDeployments");
272
- b.p("coreDeviceThingName", () => input.coreDeviceThingName, "{coreDeviceThingName}", false);
273
- const query = map({
274
- [_mR]: [() => input.maxResults !== void 0, () => input[_mR].toString()],
275
- [_nT]: [, input[_nT]],
276
- });
277
- let body;
278
- b.m("GET").h(headers).q(query).b(body);
279
- return b.build();
280
- };
281
- export const se_ListInstalledComponentsCommand = async (input, context) => {
282
- const b = rb(input, context);
283
- const headers = {};
284
- b.bp("/greengrass/v2/coreDevices/{coreDeviceThingName}/installedComponents");
285
- b.p("coreDeviceThingName", () => input.coreDeviceThingName, "{coreDeviceThingName}", false);
286
- const query = map({
287
- [_mR]: [() => input.maxResults !== void 0, () => input[_mR].toString()],
288
- [_nT]: [, input[_nT]],
289
- [_tF]: [, input[_tF]],
290
- });
291
- let body;
292
- b.m("GET").h(headers).q(query).b(body);
293
- return b.build();
294
- };
295
- export const se_ListTagsForResourceCommand = async (input, context) => {
296
- const b = rb(input, context);
297
- const headers = {};
298
- b.bp("/tags/{resourceArn}");
299
- b.p("resourceArn", () => input.resourceArn, "{resourceArn}", false);
300
- let body;
301
- b.m("GET").h(headers).b(body);
302
- return b.build();
303
- };
304
- export const se_ResolveComponentCandidatesCommand = async (input, context) => {
305
- const b = rb(input, context);
306
- const headers = {
307
- "content-type": "application/json",
308
- };
309
- b.bp("/greengrass/v2/resolveComponentCandidates");
310
- let body;
311
- body = JSON.stringify(take(input, {
312
- componentCandidates: (_) => _json(_),
313
- platform: (_) => _json(_),
314
- }));
315
- b.m("POST").h(headers).b(body);
316
- return b.build();
317
- };
318
- export const se_TagResourceCommand = async (input, context) => {
319
- const b = rb(input, context);
320
- const headers = {
321
- "content-type": "application/json",
322
- };
323
- b.bp("/tags/{resourceArn}");
324
- b.p("resourceArn", () => input.resourceArn, "{resourceArn}", false);
325
- let body;
326
- body = JSON.stringify(take(input, {
327
- tags: (_) => _json(_),
328
- }));
329
- b.m("POST").h(headers).b(body);
330
- return b.build();
331
- };
332
- export const se_UntagResourceCommand = async (input, context) => {
333
- const b = rb(input, context);
334
- const headers = {};
335
- b.bp("/tags/{resourceArn}");
336
- b.p("resourceArn", () => input.resourceArn, "{resourceArn}", false);
337
- const query = map({
338
- [_tK]: [__expectNonNull(input.tagKeys, `tagKeys`) != null, () => input[_tK] || []],
339
- });
340
- let body;
341
- b.m("DELETE").h(headers).q(query).b(body);
342
- return b.build();
343
- };
344
- export const se_UpdateConnectivityInfoCommand = async (input, context) => {
345
- const b = rb(input, context);
346
- const headers = {
347
- "content-type": "application/json",
348
- };
349
- b.bp("/greengrass/things/{thingName}/connectivityInfo");
350
- b.p("thingName", () => input.thingName, "{thingName}", false);
351
- let body;
352
- body = JSON.stringify(take(input, {
353
- ConnectivityInfo: [, (_) => se_connectivityInfoList(_, context), `connectivityInfo`],
354
- }));
355
- b.m("PUT").h(headers).b(body);
356
- return b.build();
357
- };
358
- export const de_AssociateServiceRoleToAccountCommand = async (output, context) => {
359
- if (output.statusCode !== 200 && output.statusCode >= 300) {
360
- return de_CommandError(output, context);
361
- }
362
- const contents = map({
363
- $metadata: deserializeMetadata(output),
364
- });
365
- const data = __expectNonNull(__expectObject(await parseBody(output.body, context)), "body");
366
- const doc = take(data, {
367
- associatedAt: [, __expectString, `AssociatedAt`],
368
- });
369
- Object.assign(contents, doc);
370
- return contents;
371
- };
372
- export const de_BatchAssociateClientDeviceWithCoreDeviceCommand = async (output, context) => {
373
- if (output.statusCode !== 200 && output.statusCode >= 300) {
374
- return de_CommandError(output, context);
375
- }
376
- const contents = map({
377
- $metadata: deserializeMetadata(output),
378
- });
379
- const data = __expectNonNull(__expectObject(await parseBody(output.body, context)), "body");
380
- const doc = take(data, {
381
- errorEntries: _json,
382
- });
383
- Object.assign(contents, doc);
384
- return contents;
385
- };
386
- export const de_BatchDisassociateClientDeviceFromCoreDeviceCommand = async (output, context) => {
387
- if (output.statusCode !== 200 && output.statusCode >= 300) {
388
- return de_CommandError(output, context);
389
- }
390
- const contents = map({
391
- $metadata: deserializeMetadata(output),
392
- });
393
- const data = __expectNonNull(__expectObject(await parseBody(output.body, context)), "body");
394
- const doc = take(data, {
395
- errorEntries: _json,
396
- });
397
- Object.assign(contents, doc);
398
- return contents;
399
- };
400
- export const de_CancelDeploymentCommand = async (output, context) => {
401
- if (output.statusCode !== 200 && output.statusCode >= 300) {
402
- return de_CommandError(output, context);
403
- }
404
- const contents = map({
405
- $metadata: deserializeMetadata(output),
406
- });
407
- const data = __expectNonNull(__expectObject(await parseBody(output.body, context)), "body");
408
- const doc = take(data, {
409
- message: __expectString,
410
- });
411
- Object.assign(contents, doc);
412
- return contents;
413
- };
414
- export const de_CreateComponentVersionCommand = async (output, context) => {
415
- if (output.statusCode !== 201 && output.statusCode >= 300) {
416
- return de_CommandError(output, context);
417
- }
418
- const contents = map({
419
- $metadata: deserializeMetadata(output),
420
- });
421
- const data = __expectNonNull(__expectObject(await parseBody(output.body, context)), "body");
422
- const doc = take(data, {
423
- arn: __expectString,
424
- componentName: __expectString,
425
- componentVersion: __expectString,
426
- creationTimestamp: (_) => __expectNonNull(__parseEpochTimestamp(__expectNumber(_))),
427
- status: _json,
428
- });
429
- Object.assign(contents, doc);
430
- return contents;
431
- };
432
- export const de_CreateDeploymentCommand = async (output, context) => {
433
- if (output.statusCode !== 201 && output.statusCode >= 300) {
434
- return de_CommandError(output, context);
435
- }
436
- const contents = map({
437
- $metadata: deserializeMetadata(output),
438
- });
439
- const data = __expectNonNull(__expectObject(await parseBody(output.body, context)), "body");
440
- const doc = take(data, {
441
- deploymentId: __expectString,
442
- iotJobArn: __expectString,
443
- iotJobId: __expectString,
444
- });
445
- Object.assign(contents, doc);
446
- return contents;
447
- };
448
- export const de_DeleteComponentCommand = async (output, context) => {
449
- if (output.statusCode !== 204 && output.statusCode >= 300) {
450
- return de_CommandError(output, context);
451
- }
452
- const contents = map({
453
- $metadata: deserializeMetadata(output),
454
- });
455
- await collectBody(output.body, context);
456
- return contents;
457
- };
458
- export const de_DeleteCoreDeviceCommand = async (output, context) => {
459
- if (output.statusCode !== 204 && output.statusCode >= 300) {
460
- return de_CommandError(output, context);
461
- }
462
- const contents = map({
463
- $metadata: deserializeMetadata(output),
464
- });
465
- await collectBody(output.body, context);
466
- return contents;
467
- };
468
- export const de_DeleteDeploymentCommand = async (output, context) => {
469
- if (output.statusCode !== 204 && output.statusCode >= 300) {
470
- return de_CommandError(output, context);
471
- }
472
- const contents = map({
473
- $metadata: deserializeMetadata(output),
474
- });
475
- await collectBody(output.body, context);
476
- return contents;
477
- };
478
- export const de_DescribeComponentCommand = async (output, context) => {
479
- if (output.statusCode !== 200 && output.statusCode >= 300) {
480
- return de_CommandError(output, context);
481
- }
482
- const contents = map({
483
- $metadata: deserializeMetadata(output),
484
- });
485
- const data = __expectNonNull(__expectObject(await parseBody(output.body, context)), "body");
486
- const doc = take(data, {
487
- arn: __expectString,
488
- componentName: __expectString,
489
- componentVersion: __expectString,
490
- creationTimestamp: (_) => __expectNonNull(__parseEpochTimestamp(__expectNumber(_))),
491
- description: __expectString,
492
- platforms: _json,
493
- publisher: __expectString,
494
- status: _json,
495
- tags: _json,
496
- });
497
- Object.assign(contents, doc);
498
- return contents;
499
- };
500
- export const de_DisassociateServiceRoleFromAccountCommand = async (output, context) => {
501
- if (output.statusCode !== 200 && output.statusCode >= 300) {
502
- return de_CommandError(output, context);
503
- }
504
- const contents = map({
505
- $metadata: deserializeMetadata(output),
506
- });
507
- const data = __expectNonNull(__expectObject(await parseBody(output.body, context)), "body");
508
- const doc = take(data, {
509
- disassociatedAt: [, __expectString, `DisassociatedAt`],
510
- });
511
- Object.assign(contents, doc);
512
- return contents;
513
- };
514
- export const de_GetComponentCommand = async (output, context) => {
515
- if (output.statusCode !== 200 && output.statusCode >= 300) {
516
- return de_CommandError(output, context);
517
- }
518
- const contents = map({
519
- $metadata: deserializeMetadata(output),
520
- });
521
- const data = __expectNonNull(__expectObject(await parseBody(output.body, context)), "body");
522
- const doc = take(data, {
523
- recipe: context.base64Decoder,
524
- recipeOutputFormat: __expectString,
525
- tags: _json,
526
- });
527
- Object.assign(contents, doc);
528
- return contents;
529
- };
530
- export const de_GetComponentVersionArtifactCommand = async (output, context) => {
531
- if (output.statusCode !== 200 && output.statusCode >= 300) {
532
- return de_CommandError(output, context);
533
- }
534
- const contents = map({
535
- $metadata: deserializeMetadata(output),
536
- });
537
- const data = __expectNonNull(__expectObject(await parseBody(output.body, context)), "body");
538
- const doc = take(data, {
539
- preSignedUrl: __expectString,
540
- });
541
- Object.assign(contents, doc);
542
- return contents;
543
- };
544
- export const de_GetConnectivityInfoCommand = async (output, context) => {
545
- if (output.statusCode !== 200 && output.statusCode >= 300) {
546
- return de_CommandError(output, context);
547
- }
548
- const contents = map({
549
- $metadata: deserializeMetadata(output),
550
- });
551
- const data = __expectNonNull(__expectObject(await parseBody(output.body, context)), "body");
552
- const doc = take(data, {
553
- connectivityInfo: [, (_) => de_connectivityInfoList(_, context), `ConnectivityInfo`],
554
- message: [, __expectString, `Message`],
555
- });
556
- Object.assign(contents, doc);
557
- return contents;
558
- };
559
- export const de_GetCoreDeviceCommand = async (output, context) => {
560
- if (output.statusCode !== 200 && output.statusCode >= 300) {
561
- return de_CommandError(output, context);
562
- }
563
- const contents = map({
564
- $metadata: deserializeMetadata(output),
565
- });
566
- const data = __expectNonNull(__expectObject(await parseBody(output.body, context)), "body");
567
- const doc = take(data, {
568
- architecture: __expectString,
569
- coreDeviceThingName: __expectString,
570
- coreVersion: __expectString,
571
- lastStatusUpdateTimestamp: (_) => __expectNonNull(__parseEpochTimestamp(__expectNumber(_))),
572
- platform: __expectString,
573
- runtime: __expectString,
574
- status: __expectString,
575
- tags: _json,
576
- });
577
- Object.assign(contents, doc);
578
- return contents;
579
- };
580
- export const de_GetDeploymentCommand = async (output, context) => {
581
- if (output.statusCode !== 200 && output.statusCode >= 300) {
582
- return de_CommandError(output, context);
583
- }
584
- const contents = map({
585
- $metadata: deserializeMetadata(output),
586
- });
587
- const data = __expectNonNull(__expectObject(await parseBody(output.body, context)), "body");
588
- const doc = take(data, {
589
- components: (_) => de_ComponentDeploymentSpecifications(_, context),
590
- creationTimestamp: (_) => __expectNonNull(__parseEpochTimestamp(__expectNumber(_))),
591
- deploymentId: __expectString,
592
- deploymentName: __expectString,
593
- deploymentPolicies: _json,
594
- deploymentStatus: __expectString,
595
- iotJobArn: __expectString,
596
- iotJobConfiguration: (_) => de_DeploymentIoTJobConfiguration(_, context),
597
- iotJobId: __expectString,
598
- isLatestForTarget: __expectBoolean,
599
- parentTargetArn: __expectString,
600
- revisionId: __expectString,
601
- tags: _json,
602
- targetArn: __expectString,
603
- });
604
- Object.assign(contents, doc);
605
- return contents;
606
- };
607
- export const de_GetServiceRoleForAccountCommand = async (output, context) => {
608
- if (output.statusCode !== 200 && output.statusCode >= 300) {
609
- return de_CommandError(output, context);
610
- }
611
- const contents = map({
612
- $metadata: deserializeMetadata(output),
613
- });
614
- const data = __expectNonNull(__expectObject(await parseBody(output.body, context)), "body");
615
- const doc = take(data, {
616
- associatedAt: [, __expectString, `AssociatedAt`],
617
- roleArn: [, __expectString, `RoleArn`],
618
- });
619
- Object.assign(contents, doc);
620
- return contents;
621
- };
622
- export const de_ListClientDevicesAssociatedWithCoreDeviceCommand = async (output, context) => {
623
- if (output.statusCode !== 200 && output.statusCode >= 300) {
624
- return de_CommandError(output, context);
625
- }
626
- const contents = map({
627
- $metadata: deserializeMetadata(output),
628
- });
629
- const data = __expectNonNull(__expectObject(await parseBody(output.body, context)), "body");
630
- const doc = take(data, {
631
- associatedClientDevices: (_) => de_AssociatedClientDeviceList(_, context),
632
- nextToken: __expectString,
633
- });
634
- Object.assign(contents, doc);
635
- return contents;
636
- };
637
- export const de_ListComponentsCommand = async (output, context) => {
638
- if (output.statusCode !== 200 && output.statusCode >= 300) {
639
- return de_CommandError(output, context);
640
- }
641
- const contents = map({
642
- $metadata: deserializeMetadata(output),
643
- });
644
- const data = __expectNonNull(__expectObject(await parseBody(output.body, context)), "body");
645
- const doc = take(data, {
646
- components: (_) => de_ComponentList(_, context),
647
- nextToken: __expectString,
648
- });
649
- Object.assign(contents, doc);
650
- return contents;
651
- };
652
- export const de_ListComponentVersionsCommand = async (output, context) => {
653
- if (output.statusCode !== 200 && output.statusCode >= 300) {
654
- return de_CommandError(output, context);
655
- }
656
- const contents = map({
657
- $metadata: deserializeMetadata(output),
658
- });
659
- const data = __expectNonNull(__expectObject(await parseBody(output.body, context)), "body");
660
- const doc = take(data, {
661
- componentVersions: _json,
662
- nextToken: __expectString,
663
- });
664
- Object.assign(contents, doc);
665
- return contents;
666
- };
667
- export const de_ListCoreDevicesCommand = async (output, context) => {
668
- if (output.statusCode !== 200 && output.statusCode >= 300) {
669
- return de_CommandError(output, context);
670
- }
671
- const contents = map({
672
- $metadata: deserializeMetadata(output),
673
- });
674
- const data = __expectNonNull(__expectObject(await parseBody(output.body, context)), "body");
675
- const doc = take(data, {
676
- coreDevices: (_) => de_CoreDevicesList(_, context),
677
- nextToken: __expectString,
678
- });
679
- Object.assign(contents, doc);
680
- return contents;
681
- };
682
- export const de_ListDeploymentsCommand = async (output, context) => {
683
- if (output.statusCode !== 200 && output.statusCode >= 300) {
684
- return de_CommandError(output, context);
685
- }
686
- const contents = map({
687
- $metadata: deserializeMetadata(output),
688
- });
689
- const data = __expectNonNull(__expectObject(await parseBody(output.body, context)), "body");
690
- const doc = take(data, {
691
- deployments: (_) => de_DeploymentList(_, context),
692
- nextToken: __expectString,
693
- });
694
- Object.assign(contents, doc);
695
- return contents;
696
- };
697
- export const de_ListEffectiveDeploymentsCommand = async (output, context) => {
698
- if (output.statusCode !== 200 && output.statusCode >= 300) {
699
- return de_CommandError(output, context);
700
- }
701
- const contents = map({
702
- $metadata: deserializeMetadata(output),
703
- });
704
- const data = __expectNonNull(__expectObject(await parseBody(output.body, context)), "body");
705
- const doc = take(data, {
706
- effectiveDeployments: (_) => de_EffectiveDeploymentsList(_, context),
707
- nextToken: __expectString,
708
- });
709
- Object.assign(contents, doc);
710
- return contents;
711
- };
712
- export const de_ListInstalledComponentsCommand = async (output, context) => {
713
- if (output.statusCode !== 200 && output.statusCode >= 300) {
714
- return de_CommandError(output, context);
715
- }
716
- const contents = map({
717
- $metadata: deserializeMetadata(output),
718
- });
719
- const data = __expectNonNull(__expectObject(await parseBody(output.body, context)), "body");
720
- const doc = take(data, {
721
- installedComponents: (_) => de_InstalledComponentList(_, context),
722
- nextToken: __expectString,
723
- });
724
- Object.assign(contents, doc);
725
- return contents;
726
- };
727
- export const de_ListTagsForResourceCommand = async (output, context) => {
728
- if (output.statusCode !== 200 && output.statusCode >= 300) {
729
- return de_CommandError(output, context);
730
- }
731
- const contents = map({
732
- $metadata: deserializeMetadata(output),
733
- });
734
- const data = __expectNonNull(__expectObject(await parseBody(output.body, context)), "body");
735
- const doc = take(data, {
736
- tags: _json,
737
- });
738
- Object.assign(contents, doc);
739
- return contents;
740
- };
741
- export const de_ResolveComponentCandidatesCommand = async (output, context) => {
742
- if (output.statusCode !== 200 && output.statusCode >= 300) {
743
- return de_CommandError(output, context);
744
- }
745
- const contents = map({
746
- $metadata: deserializeMetadata(output),
747
- });
748
- const data = __expectNonNull(__expectObject(await parseBody(output.body, context)), "body");
749
- const doc = take(data, {
750
- resolvedComponentVersions: (_) => de_ResolvedComponentVersionsList(_, context),
751
- });
752
- Object.assign(contents, doc);
753
- return contents;
754
- };
755
- export const de_TagResourceCommand = async (output, context) => {
756
- if (output.statusCode !== 200 && output.statusCode >= 300) {
757
- return de_CommandError(output, context);
758
- }
759
- const contents = map({
760
- $metadata: deserializeMetadata(output),
761
- });
762
- await collectBody(output.body, context);
763
- return contents;
764
- };
765
- export const de_UntagResourceCommand = async (output, context) => {
766
- if (output.statusCode !== 200 && output.statusCode >= 300) {
767
- return de_CommandError(output, context);
768
- }
769
- const contents = map({
770
- $metadata: deserializeMetadata(output),
771
- });
772
- await collectBody(output.body, context);
773
- return contents;
774
- };
775
- export const de_UpdateConnectivityInfoCommand = async (output, context) => {
776
- if (output.statusCode !== 200 && output.statusCode >= 300) {
777
- return de_CommandError(output, context);
778
- }
779
- const contents = map({
780
- $metadata: deserializeMetadata(output),
781
- });
782
- const data = __expectNonNull(__expectObject(await parseBody(output.body, context)), "body");
783
- const doc = take(data, {
784
- message: [, __expectString, `Message`],
785
- version: [, __expectString, `Version`],
786
- });
787
- Object.assign(contents, doc);
788
- return contents;
789
- };
790
- const de_CommandError = async (output, context) => {
791
- const parsedOutput = {
792
- ...output,
793
- body: await parseErrorBody(output.body, context),
794
- };
795
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
796
- switch (errorCode) {
797
- case "InternalServerException":
798
- case "com.amazonaws.greengrassv2#InternalServerException":
799
- throw await de_InternalServerExceptionRes(parsedOutput, context);
800
- case "ValidationException":
801
- case "com.amazonaws.greengrassv2#ValidationException":
802
- throw await de_ValidationExceptionRes(parsedOutput, context);
803
- case "AccessDeniedException":
804
- case "com.amazonaws.greengrassv2#AccessDeniedException":
805
- throw await de_AccessDeniedExceptionRes(parsedOutput, context);
806
- case "ResourceNotFoundException":
807
- case "com.amazonaws.greengrassv2#ResourceNotFoundException":
808
- throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
809
- case "ThrottlingException":
810
- case "com.amazonaws.greengrassv2#ThrottlingException":
811
- throw await de_ThrottlingExceptionRes(parsedOutput, context);
812
- case "ConflictException":
813
- case "com.amazonaws.greengrassv2#ConflictException":
814
- throw await de_ConflictExceptionRes(parsedOutput, context);
815
- case "RequestAlreadyInProgressException":
816
- case "com.amazonaws.greengrassv2#RequestAlreadyInProgressException":
817
- throw await de_RequestAlreadyInProgressExceptionRes(parsedOutput, context);
818
- case "ServiceQuotaExceededException":
819
- case "com.amazonaws.greengrassv2#ServiceQuotaExceededException":
820
- throw await de_ServiceQuotaExceededExceptionRes(parsedOutput, context);
821
- default:
822
- const parsedBody = parsedOutput.body;
823
- return throwDefaultError({
824
- output,
825
- parsedBody,
826
- errorCode,
827
- });
828
- }
829
- };
830
- const throwDefaultError = withBaseException(__BaseException);
831
- const de_AccessDeniedExceptionRes = async (parsedOutput, context) => {
832
- const contents = map({});
833
- const data = parsedOutput.body;
834
- const doc = take(data, {
835
- message: __expectString,
836
- });
837
- Object.assign(contents, doc);
838
- const exception = new AccessDeniedException({
839
- $metadata: deserializeMetadata(parsedOutput),
840
- ...contents,
841
- });
842
- return __decorateServiceException(exception, parsedOutput.body);
843
- };
844
- const de_ConflictExceptionRes = async (parsedOutput, context) => {
845
- const contents = map({});
846
- const data = parsedOutput.body;
847
- const doc = take(data, {
848
- message: __expectString,
849
- resourceId: __expectString,
850
- resourceType: __expectString,
851
- });
852
- Object.assign(contents, doc);
853
- const exception = new ConflictException({
854
- $metadata: deserializeMetadata(parsedOutput),
855
- ...contents,
856
- });
857
- return __decorateServiceException(exception, parsedOutput.body);
858
- };
859
- const de_InternalServerExceptionRes = async (parsedOutput, context) => {
860
- const contents = map({
861
- [_rAS]: [() => void 0 !== parsedOutput.headers[_ra], () => __strictParseInt32(parsedOutput.headers[_ra])],
862
- });
863
- const data = parsedOutput.body;
864
- const doc = take(data, {
865
- message: __expectString,
866
- });
867
- Object.assign(contents, doc);
868
- const exception = new InternalServerException({
869
- $metadata: deserializeMetadata(parsedOutput),
870
- ...contents,
871
- });
872
- return __decorateServiceException(exception, parsedOutput.body);
873
- };
874
- const de_RequestAlreadyInProgressExceptionRes = async (parsedOutput, context) => {
875
- const contents = map({});
876
- const data = parsedOutput.body;
877
- const doc = take(data, {
878
- message: __expectString,
879
- });
880
- Object.assign(contents, doc);
881
- const exception = new RequestAlreadyInProgressException({
882
- $metadata: deserializeMetadata(parsedOutput),
883
- ...contents,
884
- });
885
- return __decorateServiceException(exception, parsedOutput.body);
886
- };
887
- const de_ResourceNotFoundExceptionRes = async (parsedOutput, context) => {
888
- const contents = map({});
889
- const data = parsedOutput.body;
890
- const doc = take(data, {
891
- message: __expectString,
892
- resourceId: __expectString,
893
- resourceType: __expectString,
894
- });
895
- Object.assign(contents, doc);
896
- const exception = new ResourceNotFoundException({
897
- $metadata: deserializeMetadata(parsedOutput),
898
- ...contents,
899
- });
900
- return __decorateServiceException(exception, parsedOutput.body);
901
- };
902
- const de_ServiceQuotaExceededExceptionRes = async (parsedOutput, context) => {
903
- const contents = map({});
904
- const data = parsedOutput.body;
905
- const doc = take(data, {
906
- message: __expectString,
907
- quotaCode: __expectString,
908
- resourceId: __expectString,
909
- resourceType: __expectString,
910
- serviceCode: __expectString,
911
- });
912
- Object.assign(contents, doc);
913
- const exception = new ServiceQuotaExceededException({
914
- $metadata: deserializeMetadata(parsedOutput),
915
- ...contents,
916
- });
917
- return __decorateServiceException(exception, parsedOutput.body);
918
- };
919
- const de_ThrottlingExceptionRes = async (parsedOutput, context) => {
920
- const contents = map({
921
- [_rAS]: [() => void 0 !== parsedOutput.headers[_ra], () => __strictParseInt32(parsedOutput.headers[_ra])],
922
- });
923
- const data = parsedOutput.body;
924
- const doc = take(data, {
925
- message: __expectString,
926
- quotaCode: __expectString,
927
- serviceCode: __expectString,
928
- });
929
- Object.assign(contents, doc);
930
- const exception = new ThrottlingException({
931
- $metadata: deserializeMetadata(parsedOutput),
932
- ...contents,
933
- });
934
- return __decorateServiceException(exception, parsedOutput.body);
935
- };
936
- const de_ValidationExceptionRes = async (parsedOutput, context) => {
937
- const contents = map({});
938
- const data = parsedOutput.body;
939
- const doc = take(data, {
940
- fields: _json,
941
- message: __expectString,
942
- reason: __expectString,
943
- });
944
- Object.assign(contents, doc);
945
- const exception = new ValidationException({
946
- $metadata: deserializeMetadata(parsedOutput),
947
- ...contents,
948
- });
949
- return __decorateServiceException(exception, parsedOutput.body);
950
- };
951
- const se_ComponentDeploymentSpecification = (input, context) => {
952
- return take(input, {
953
- componentVersion: [],
954
- configurationUpdate: _json,
955
- runWith: (_) => se_ComponentRunWith(_, context),
956
- });
957
- };
958
- const se_ComponentDeploymentSpecifications = (input, context) => {
959
- return Object.entries(input).reduce((acc, [key, value]) => {
960
- if (value === null) {
961
- return acc;
962
- }
963
- acc[key] = se_ComponentDeploymentSpecification(value, context);
964
- return acc;
965
- }, {});
966
- };
967
- const se_ComponentRunWith = (input, context) => {
968
- return take(input, {
969
- posixUser: [],
970
- systemResourceLimits: (_) => se_SystemResourceLimits(_, context),
971
- windowsUser: [],
972
- });
973
- };
974
- const se_ConnectivityInfo = (input, context) => {
975
- return take(input, {
976
- HostAddress: [, , `hostAddress`],
977
- Id: [, , `id`],
978
- Metadata: [, , `metadata`],
979
- PortNumber: [, , `portNumber`],
980
- });
981
- };
982
- const se_connectivityInfoList = (input, context) => {
983
- return input
984
- .filter((e) => e != null)
985
- .map((entry) => {
986
- return se_ConnectivityInfo(entry, context);
987
- });
988
- };
989
- const se_DeploymentIoTJobConfiguration = (input, context) => {
990
- return take(input, {
991
- abortConfig: (_) => se_IoTJobAbortConfig(_, context),
992
- jobExecutionsRolloutConfig: (_) => se_IoTJobExecutionsRolloutConfig(_, context),
993
- timeoutConfig: _json,
994
- });
995
- };
996
- const se_IoTJobAbortConfig = (input, context) => {
997
- return take(input, {
998
- criteriaList: (_) => se_IoTJobAbortCriteriaList(_, context),
999
- });
1000
- };
1001
- const se_IoTJobAbortCriteria = (input, context) => {
1002
- return take(input, {
1003
- action: [],
1004
- failureType: [],
1005
- minNumberOfExecutedThings: [],
1006
- thresholdPercentage: __serializeFloat,
1007
- });
1008
- };
1009
- const se_IoTJobAbortCriteriaList = (input, context) => {
1010
- return input
1011
- .filter((e) => e != null)
1012
- .map((entry) => {
1013
- return se_IoTJobAbortCriteria(entry, context);
1014
- });
1015
- };
1016
- const se_IoTJobExecutionsRolloutConfig = (input, context) => {
1017
- return take(input, {
1018
- exponentialRate: (_) => se_IoTJobExponentialRolloutRate(_, context),
1019
- maximumPerMinute: [],
1020
- });
1021
- };
1022
- const se_IoTJobExponentialRolloutRate = (input, context) => {
1023
- return take(input, {
1024
- baseRatePerMinute: [],
1025
- incrementFactor: __serializeFloat,
1026
- rateIncreaseCriteria: _json,
1027
- });
1028
- };
1029
- const se_SystemResourceLimits = (input, context) => {
1030
- return take(input, {
1031
- cpus: __serializeFloat,
1032
- memory: [],
1033
- });
1034
- };
1035
- const de_AssociatedClientDevice = (output, context) => {
1036
- return take(output, {
1037
- associationTimestamp: (_) => __expectNonNull(__parseEpochTimestamp(__expectNumber(_))),
1038
- thingName: __expectString,
1039
- });
1040
- };
1041
- const de_AssociatedClientDeviceList = (output, context) => {
1042
- const retVal = (output || [])
1043
- .filter((e) => e != null)
1044
- .map((entry) => {
1045
- return de_AssociatedClientDevice(entry, context);
1046
- });
1047
- return retVal;
1048
- };
1049
- const de_Component = (output, context) => {
1050
- return take(output, {
1051
- arn: __expectString,
1052
- componentName: __expectString,
1053
- latestVersion: (_) => de_ComponentLatestVersion(_, context),
1054
- });
1055
- };
1056
- const de_ComponentDeploymentSpecification = (output, context) => {
1057
- return take(output, {
1058
- componentVersion: __expectString,
1059
- configurationUpdate: _json,
1060
- runWith: (_) => de_ComponentRunWith(_, context),
1061
- });
1062
- };
1063
- const de_ComponentDeploymentSpecifications = (output, context) => {
1064
- return Object.entries(output).reduce((acc, [key, value]) => {
1065
- if (value === null) {
1066
- return acc;
1067
- }
1068
- acc[key] = de_ComponentDeploymentSpecification(value, context);
1069
- return acc;
1070
- }, {});
1071
- };
1072
- const de_ComponentLatestVersion = (output, context) => {
1073
- return take(output, {
1074
- arn: __expectString,
1075
- componentVersion: __expectString,
1076
- creationTimestamp: (_) => __expectNonNull(__parseEpochTimestamp(__expectNumber(_))),
1077
- description: __expectString,
1078
- platforms: _json,
1079
- publisher: __expectString,
1080
- });
1081
- };
1082
- const de_ComponentList = (output, context) => {
1083
- const retVal = (output || [])
1084
- .filter((e) => e != null)
1085
- .map((entry) => {
1086
- return de_Component(entry, context);
1087
- });
1088
- return retVal;
1089
- };
1090
- const de_ComponentRunWith = (output, context) => {
1091
- return take(output, {
1092
- posixUser: __expectString,
1093
- systemResourceLimits: (_) => de_SystemResourceLimits(_, context),
1094
- windowsUser: __expectString,
1095
- });
1096
- };
1097
- const de_ConnectivityInfo = (output, context) => {
1098
- return take(output, {
1099
- hostAddress: [, __expectString, `HostAddress`],
1100
- id: [, __expectString, `Id`],
1101
- metadata: [, __expectString, `Metadata`],
1102
- portNumber: [, __expectInt32, `PortNumber`],
1103
- });
1104
- };
1105
- const de_connectivityInfoList = (output, context) => {
1106
- const retVal = (output || [])
1107
- .filter((e) => e != null)
1108
- .map((entry) => {
1109
- return de_ConnectivityInfo(entry, context);
1110
- });
1111
- return retVal;
1112
- };
1113
- const de_CoreDevice = (output, context) => {
1114
- return take(output, {
1115
- architecture: __expectString,
1116
- coreDeviceThingName: __expectString,
1117
- lastStatusUpdateTimestamp: (_) => __expectNonNull(__parseEpochTimestamp(__expectNumber(_))),
1118
- platform: __expectString,
1119
- runtime: __expectString,
1120
- status: __expectString,
1121
- });
1122
- };
1123
- const de_CoreDevicesList = (output, context) => {
1124
- const retVal = (output || [])
1125
- .filter((e) => e != null)
1126
- .map((entry) => {
1127
- return de_CoreDevice(entry, context);
1128
- });
1129
- return retVal;
1130
- };
1131
- const de_Deployment = (output, context) => {
1132
- return take(output, {
1133
- creationTimestamp: (_) => __expectNonNull(__parseEpochTimestamp(__expectNumber(_))),
1134
- deploymentId: __expectString,
1135
- deploymentName: __expectString,
1136
- deploymentStatus: __expectString,
1137
- isLatestForTarget: __expectBoolean,
1138
- parentTargetArn: __expectString,
1139
- revisionId: __expectString,
1140
- targetArn: __expectString,
1141
- });
1142
- };
1143
- const de_DeploymentIoTJobConfiguration = (output, context) => {
1144
- return take(output, {
1145
- abortConfig: (_) => de_IoTJobAbortConfig(_, context),
1146
- jobExecutionsRolloutConfig: (_) => de_IoTJobExecutionsRolloutConfig(_, context),
1147
- timeoutConfig: _json,
1148
- });
1149
- };
1150
- const de_DeploymentList = (output, context) => {
1151
- const retVal = (output || [])
1152
- .filter((e) => e != null)
1153
- .map((entry) => {
1154
- return de_Deployment(entry, context);
1155
- });
1156
- return retVal;
1157
- };
1158
- const de_EffectiveDeployment = (output, context) => {
1159
- return take(output, {
1160
- coreDeviceExecutionStatus: __expectString,
1161
- creationTimestamp: (_) => __expectNonNull(__parseEpochTimestamp(__expectNumber(_))),
1162
- deploymentId: __expectString,
1163
- deploymentName: __expectString,
1164
- description: __expectString,
1165
- iotJobArn: __expectString,
1166
- iotJobId: __expectString,
1167
- modifiedTimestamp: (_) => __expectNonNull(__parseEpochTimestamp(__expectNumber(_))),
1168
- reason: __expectString,
1169
- statusDetails: _json,
1170
- targetArn: __expectString,
1171
- });
1172
- };
1173
- const de_EffectiveDeploymentsList = (output, context) => {
1174
- const retVal = (output || [])
1175
- .filter((e) => e != null)
1176
- .map((entry) => {
1177
- return de_EffectiveDeployment(entry, context);
1178
- });
1179
- return retVal;
1180
- };
1181
- const de_InstalledComponent = (output, context) => {
1182
- return take(output, {
1183
- componentName: __expectString,
1184
- componentVersion: __expectString,
1185
- isRoot: __expectBoolean,
1186
- lastInstallationSource: __expectString,
1187
- lastReportedTimestamp: (_) => __expectNonNull(__parseEpochTimestamp(__expectNumber(_))),
1188
- lastStatusChangeTimestamp: (_) => __expectNonNull(__parseEpochTimestamp(__expectNumber(_))),
1189
- lifecycleState: __expectString,
1190
- lifecycleStateDetails: __expectString,
1191
- lifecycleStatusCodes: _json,
1192
- });
1193
- };
1194
- const de_InstalledComponentList = (output, context) => {
1195
- const retVal = (output || [])
1196
- .filter((e) => e != null)
1197
- .map((entry) => {
1198
- return de_InstalledComponent(entry, context);
1199
- });
1200
- return retVal;
1201
- };
1202
- const de_IoTJobAbortConfig = (output, context) => {
1203
- return take(output, {
1204
- criteriaList: (_) => de_IoTJobAbortCriteriaList(_, context),
1205
- });
1206
- };
1207
- const de_IoTJobAbortCriteria = (output, context) => {
1208
- return take(output, {
1209
- action: __expectString,
1210
- failureType: __expectString,
1211
- minNumberOfExecutedThings: __expectInt32,
1212
- thresholdPercentage: __limitedParseDouble,
1213
- });
1214
- };
1215
- const de_IoTJobAbortCriteriaList = (output, context) => {
1216
- const retVal = (output || [])
1217
- .filter((e) => e != null)
1218
- .map((entry) => {
1219
- return de_IoTJobAbortCriteria(entry, context);
1220
- });
1221
- return retVal;
1222
- };
1223
- const de_IoTJobExecutionsRolloutConfig = (output, context) => {
1224
- return take(output, {
1225
- exponentialRate: (_) => de_IoTJobExponentialRolloutRate(_, context),
1226
- maximumPerMinute: __expectInt32,
1227
- });
1228
- };
1229
- const de_IoTJobExponentialRolloutRate = (output, context) => {
1230
- return take(output, {
1231
- baseRatePerMinute: __expectInt32,
1232
- incrementFactor: __limitedParseDouble,
1233
- rateIncreaseCriteria: _json,
1234
- });
1235
- };
1236
- const de_ResolvedComponentVersion = (output, context) => {
1237
- return take(output, {
1238
- arn: __expectString,
1239
- componentName: __expectString,
1240
- componentVersion: __expectString,
1241
- message: __expectString,
1242
- recipe: context.base64Decoder,
1243
- vendorGuidance: __expectString,
1244
- });
1245
- };
1246
- const de_ResolvedComponentVersionsList = (output, context) => {
1247
- const retVal = (output || [])
1248
- .filter((e) => e != null)
1249
- .map((entry) => {
1250
- return de_ResolvedComponentVersion(entry, context);
1251
- });
1252
- return retVal;
1253
- };
1254
- const de_SystemResourceLimits = (output, context) => {
1255
- return take(output, {
1256
- cpus: __limitedParseDouble,
1257
- memory: __expectLong,
1258
- });
1259
- };
1260
- const deserializeMetadata = (output) => ({
1261
- httpStatusCode: output.statusCode,
1262
- requestId: output.headers["x-amzn-requestid"] ?? output.headers["x-amzn-request-id"] ?? output.headers["x-amz-request-id"],
1263
- extendedRequestId: output.headers["x-amz-id-2"],
1264
- cfId: output.headers["x-amz-cf-id"],
1265
- });
1266
- const collectBodyString = (streamBody, context) => collectBody(streamBody, context).then((body) => context.utf8Encoder(body));
1267
- const _hF = "historyFilter";
1268
- const _iET = "iotEndpointType";
1269
- const _mR = "maxResults";
1270
- const _nT = "nextToken";
1271
- const _pTA = "parentTargetArn";
1272
- const _r = "runtime";
1273
- const _rAS = "retryAfterSeconds";
1274
- const _rOF = "recipeOutputFormat";
1275
- const _ra = "retry-after";
1276
- const _s = "scope";
1277
- const _sET = "s3EndpointType";
1278
- const _st = "status";
1279
- const _tA = "targetArn";
1280
- const _tF = "topologyFilter";
1281
- const _tGA = "thingGroupArn";
1282
- const _tK = "tagKeys";
1283
- const _xaiet = "x-amz-iot-endpoint-type";