@aws-sdk/client-iot 3.42.0 → 3.43.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 (53) hide show
  1. package/CHANGELOG.md +11 -0
  2. package/dist-cjs/IoT.js +30 -0
  3. package/dist-cjs/commands/DescribeManagedJobTemplateCommand.js +36 -0
  4. package/dist-cjs/commands/ListManagedJobTemplatesCommand.js +36 -0
  5. package/dist-cjs/commands/ListThingTypesCommand.js +1 -2
  6. package/dist-cjs/commands/ListThingsCommand.js +2 -1
  7. package/dist-cjs/commands/ListThingsInBillingGroupCommand.js +3 -3
  8. package/dist-cjs/commands/ListThingsInThingGroupCommand.js +3 -3
  9. package/dist-cjs/commands/index.js +2 -0
  10. package/dist-cjs/models/models_1.js +47 -47
  11. package/dist-cjs/models/models_2.js +45 -3
  12. package/dist-cjs/protocols/Aws_restJson1.js +325 -9
  13. package/dist-es/IoT.js +30 -0
  14. package/dist-es/commands/DescribeManagedJobTemplateCommand.js +39 -0
  15. package/dist-es/commands/ListManagedJobTemplatesCommand.js +39 -0
  16. package/dist-es/commands/ListThingTypesCommand.js +1 -2
  17. package/dist-es/commands/ListThingsCommand.js +2 -1
  18. package/dist-es/commands/ListThingsInBillingGroupCommand.js +1 -1
  19. package/dist-es/commands/ListThingsInThingGroupCommand.js +1 -1
  20. package/dist-es/commands/index.js +2 -0
  21. package/dist-es/models/models_1.js +28 -28
  22. package/dist-es/models/models_2.js +28 -0
  23. package/dist-es/protocols/Aws_restJson1.js +350 -2
  24. package/dist-types/IoT.d.ts +24 -3
  25. package/dist-types/IoTClient.d.ts +4 -2
  26. package/dist-types/commands/CreateCertificateFromCsrCommand.d.ts +3 -2
  27. package/dist-types/commands/DescribeManagedJobTemplateCommand.d.ts +35 -0
  28. package/dist-types/commands/ListManagedJobTemplatesCommand.d.ts +35 -0
  29. package/dist-types/commands/ListThingTypesCommand.d.ts +1 -2
  30. package/dist-types/commands/ListThingsCommand.d.ts +2 -1
  31. package/dist-types/commands/ListThingsInBillingGroupCommand.d.ts +1 -1
  32. package/dist-types/commands/ListThingsInThingGroupCommand.d.ts +1 -1
  33. package/dist-types/commands/RegisterCertificateWithoutCACommand.d.ts +4 -1
  34. package/dist-types/commands/RemoveThingFromBillingGroupCommand.d.ts +3 -0
  35. package/dist-types/commands/index.d.ts +2 -0
  36. package/dist-types/models/models_0.d.ts +11 -3
  37. package/dist-types/models/models_1.d.ts +188 -164
  38. package/dist-types/models/models_2.d.ts +159 -0
  39. package/dist-types/protocols/Aws_restJson1.d.ts +6 -0
  40. package/dist-types/ts3.4/IoT.d.ts +10 -0
  41. package/dist-types/ts3.4/IoTClient.d.ts +4 -2
  42. package/dist-types/ts3.4/commands/DescribeManagedJobTemplateCommand.d.ts +17 -0
  43. package/dist-types/ts3.4/commands/ListManagedJobTemplatesCommand.d.ts +17 -0
  44. package/dist-types/ts3.4/commands/ListThingTypesCommand.d.ts +1 -2
  45. package/dist-types/ts3.4/commands/ListThingsCommand.d.ts +2 -1
  46. package/dist-types/ts3.4/commands/ListThingsInBillingGroupCommand.d.ts +1 -1
  47. package/dist-types/ts3.4/commands/ListThingsInThingGroupCommand.d.ts +1 -1
  48. package/dist-types/ts3.4/commands/index.d.ts +2 -0
  49. package/dist-types/ts3.4/models/models_0.d.ts +4 -0
  50. package/dist-types/ts3.4/models/models_1.d.ts +100 -89
  51. package/dist-types/ts3.4/models/models_2.d.ts +89 -0
  52. package/dist-types/ts3.4/protocols/Aws_restJson1.d.ts +6 -0
  53. package/package.json +2 -2
@@ -0,0 +1,39 @@
1
+ import { __extends } from "tslib";
2
+ import { getSerdePlugin } from "@aws-sdk/middleware-serde";
3
+ import { Command as $Command } from "@aws-sdk/smithy-client";
4
+ import { ListManagedJobTemplatesRequest, ListManagedJobTemplatesResponse } from "../models/models_1";
5
+ import { deserializeAws_restJson1ListManagedJobTemplatesCommand, serializeAws_restJson1ListManagedJobTemplatesCommand, } from "../protocols/Aws_restJson1";
6
+ var ListManagedJobTemplatesCommand = (function (_super) {
7
+ __extends(ListManagedJobTemplatesCommand, _super);
8
+ function ListManagedJobTemplatesCommand(input) {
9
+ var _this = _super.call(this) || this;
10
+ _this.input = input;
11
+ return _this;
12
+ }
13
+ ListManagedJobTemplatesCommand.prototype.resolveMiddleware = function (clientStack, configuration, options) {
14
+ this.middlewareStack.use(getSerdePlugin(configuration, this.serialize, this.deserialize));
15
+ var stack = clientStack.concat(this.middlewareStack);
16
+ var logger = configuration.logger;
17
+ var clientName = "IoTClient";
18
+ var commandName = "ListManagedJobTemplatesCommand";
19
+ var handlerExecutionContext = {
20
+ logger: logger,
21
+ clientName: clientName,
22
+ commandName: commandName,
23
+ inputFilterSensitiveLog: ListManagedJobTemplatesRequest.filterSensitiveLog,
24
+ outputFilterSensitiveLog: ListManagedJobTemplatesResponse.filterSensitiveLog,
25
+ };
26
+ var requestHandler = configuration.requestHandler;
27
+ return stack.resolve(function (request) {
28
+ return requestHandler.handle(request.request, options || {});
29
+ }, handlerExecutionContext);
30
+ };
31
+ ListManagedJobTemplatesCommand.prototype.serialize = function (input, context) {
32
+ return serializeAws_restJson1ListManagedJobTemplatesCommand(input, context);
33
+ };
34
+ ListManagedJobTemplatesCommand.prototype.deserialize = function (output, context) {
35
+ return deserializeAws_restJson1ListManagedJobTemplatesCommand(output, context);
36
+ };
37
+ return ListManagedJobTemplatesCommand;
38
+ }($Command));
39
+ export { ListManagedJobTemplatesCommand };
@@ -1,8 +1,7 @@
1
1
  import { __extends } from "tslib";
2
2
  import { getSerdePlugin } from "@aws-sdk/middleware-serde";
3
3
  import { Command as $Command } from "@aws-sdk/smithy-client";
4
- import { ListThingTypesRequest } from "../models/models_1";
5
- import { ListThingTypesResponse } from "../models/models_2";
4
+ import { ListThingTypesRequest, ListThingTypesResponse } from "../models/models_2";
6
5
  import { deserializeAws_restJson1ListThingTypesCommand, serializeAws_restJson1ListThingTypesCommand, } from "../protocols/Aws_restJson1";
7
6
  var ListThingTypesCommand = (function (_super) {
8
7
  __extends(ListThingTypesCommand, _super);
@@ -1,7 +1,8 @@
1
1
  import { __extends } from "tslib";
2
2
  import { getSerdePlugin } from "@aws-sdk/middleware-serde";
3
3
  import { Command as $Command } from "@aws-sdk/smithy-client";
4
- import { ListThingsRequest, ListThingsResponse } from "../models/models_1";
4
+ import { ListThingsRequest } from "../models/models_1";
5
+ import { ListThingsResponse } from "../models/models_2";
5
6
  import { deserializeAws_restJson1ListThingsCommand, serializeAws_restJson1ListThingsCommand, } from "../protocols/Aws_restJson1";
6
7
  var ListThingsCommand = (function (_super) {
7
8
  __extends(ListThingsCommand, _super);
@@ -1,7 +1,7 @@
1
1
  import { __extends } from "tslib";
2
2
  import { getSerdePlugin } from "@aws-sdk/middleware-serde";
3
3
  import { Command as $Command } from "@aws-sdk/smithy-client";
4
- import { ListThingsInBillingGroupRequest, ListThingsInBillingGroupResponse } from "../models/models_1";
4
+ import { ListThingsInBillingGroupRequest, ListThingsInBillingGroupResponse } from "../models/models_2";
5
5
  import { deserializeAws_restJson1ListThingsInBillingGroupCommand, serializeAws_restJson1ListThingsInBillingGroupCommand, } from "../protocols/Aws_restJson1";
6
6
  var ListThingsInBillingGroupCommand = (function (_super) {
7
7
  __extends(ListThingsInBillingGroupCommand, _super);
@@ -1,7 +1,7 @@
1
1
  import { __extends } from "tslib";
2
2
  import { getSerdePlugin } from "@aws-sdk/middleware-serde";
3
3
  import { Command as $Command } from "@aws-sdk/smithy-client";
4
- import { ListThingsInThingGroupRequest, ListThingsInThingGroupResponse } from "../models/models_1";
4
+ import { ListThingsInThingGroupRequest, ListThingsInThingGroupResponse } from "../models/models_2";
5
5
  import { deserializeAws_restJson1ListThingsInThingGroupCommand, serializeAws_restJson1ListThingsInThingGroupCommand, } from "../protocols/Aws_restJson1";
6
6
  var ListThingsInThingGroupCommand = (function (_super) {
7
7
  __extends(ListThingsInThingGroupCommand, _super);
@@ -95,6 +95,7 @@ export * from "./DescribeIndexCommand";
95
95
  export * from "./DescribeJobCommand";
96
96
  export * from "./DescribeJobExecutionCommand";
97
97
  export * from "./DescribeJobTemplateCommand";
98
+ export * from "./DescribeManagedJobTemplateCommand";
98
99
  export * from "./DescribeMitigationActionCommand";
99
100
  export * from "./DescribeProvisioningTemplateCommand";
100
101
  export * from "./DescribeProvisioningTemplateVersionCommand";
@@ -151,6 +152,7 @@ export * from "./ListJobExecutionsForJobCommand";
151
152
  export * from "./ListJobExecutionsForThingCommand";
152
153
  export * from "./ListJobTemplatesCommand";
153
154
  export * from "./ListJobsCommand";
155
+ export * from "./ListManagedJobTemplatesCommand";
154
156
  export * from "./ListMitigationActionsCommand";
155
157
  export * from "./ListOTAUpdatesCommand";
156
158
  export * from "./ListOutgoingCertificatesCommand";
@@ -384,6 +384,22 @@ export var DescribeJobTemplateResponse;
384
384
  (function (DescribeJobTemplateResponse) {
385
385
  DescribeJobTemplateResponse.filterSensitiveLog = function (obj) { return (__assign({}, obj)); };
386
386
  })(DescribeJobTemplateResponse || (DescribeJobTemplateResponse = {}));
387
+ export var DescribeManagedJobTemplateRequest;
388
+ (function (DescribeManagedJobTemplateRequest) {
389
+ DescribeManagedJobTemplateRequest.filterSensitiveLog = function (obj) { return (__assign({}, obj)); };
390
+ })(DescribeManagedJobTemplateRequest || (DescribeManagedJobTemplateRequest = {}));
391
+ export var DocumentParameter;
392
+ (function (DocumentParameter) {
393
+ DocumentParameter.filterSensitiveLog = function (obj) { return (__assign({}, obj)); };
394
+ })(DocumentParameter || (DocumentParameter = {}));
395
+ export var DescribeManagedJobTemplateResponse;
396
+ (function (DescribeManagedJobTemplateResponse) {
397
+ DescribeManagedJobTemplateResponse.filterSensitiveLog = function (obj) { return (__assign({}, obj)); };
398
+ })(DescribeManagedJobTemplateResponse || (DescribeManagedJobTemplateResponse = {}));
399
+ export var InternalServerException;
400
+ (function (InternalServerException) {
401
+ InternalServerException.filterSensitiveLog = function (obj) { return (__assign({}, obj)); };
402
+ })(InternalServerException || (InternalServerException = {}));
387
403
  export var DescribeMitigationActionRequest;
388
404
  (function (DescribeMitigationActionRequest) {
389
405
  DescribeMitigationActionRequest.filterSensitiveLog = function (obj) { return (__assign({}, obj)); };
@@ -996,6 +1012,18 @@ export var ListJobTemplatesResponse;
996
1012
  (function (ListJobTemplatesResponse) {
997
1013
  ListJobTemplatesResponse.filterSensitiveLog = function (obj) { return (__assign({}, obj)); };
998
1014
  })(ListJobTemplatesResponse || (ListJobTemplatesResponse = {}));
1015
+ export var ListManagedJobTemplatesRequest;
1016
+ (function (ListManagedJobTemplatesRequest) {
1017
+ ListManagedJobTemplatesRequest.filterSensitiveLog = function (obj) { return (__assign({}, obj)); };
1018
+ })(ListManagedJobTemplatesRequest || (ListManagedJobTemplatesRequest = {}));
1019
+ export var ManagedJobTemplateSummary;
1020
+ (function (ManagedJobTemplateSummary) {
1021
+ ManagedJobTemplateSummary.filterSensitiveLog = function (obj) { return (__assign({}, obj)); };
1022
+ })(ManagedJobTemplateSummary || (ManagedJobTemplateSummary = {}));
1023
+ export var ListManagedJobTemplatesResponse;
1024
+ (function (ListManagedJobTemplatesResponse) {
1025
+ ListManagedJobTemplatesResponse.filterSensitiveLog = function (obj) { return (__assign({}, obj)); };
1026
+ })(ListManagedJobTemplatesResponse || (ListManagedJobTemplatesResponse = {}));
999
1027
  export var ListMitigationActionsRequest;
1000
1028
  (function (ListMitigationActionsRequest) {
1001
1029
  ListMitigationActionsRequest.filterSensitiveLog = function (obj) { return (__assign({}, obj)); };
@@ -1233,31 +1261,3 @@ export var ListThingsRequest;
1233
1261
  (function (ListThingsRequest) {
1234
1262
  ListThingsRequest.filterSensitiveLog = function (obj) { return (__assign({}, obj)); };
1235
1263
  })(ListThingsRequest || (ListThingsRequest = {}));
1236
- export var ThingAttribute;
1237
- (function (ThingAttribute) {
1238
- ThingAttribute.filterSensitiveLog = function (obj) { return (__assign({}, obj)); };
1239
- })(ThingAttribute || (ThingAttribute = {}));
1240
- export var ListThingsResponse;
1241
- (function (ListThingsResponse) {
1242
- ListThingsResponse.filterSensitiveLog = function (obj) { return (__assign({}, obj)); };
1243
- })(ListThingsResponse || (ListThingsResponse = {}));
1244
- export var ListThingsInBillingGroupRequest;
1245
- (function (ListThingsInBillingGroupRequest) {
1246
- ListThingsInBillingGroupRequest.filterSensitiveLog = function (obj) { return (__assign({}, obj)); };
1247
- })(ListThingsInBillingGroupRequest || (ListThingsInBillingGroupRequest = {}));
1248
- export var ListThingsInBillingGroupResponse;
1249
- (function (ListThingsInBillingGroupResponse) {
1250
- ListThingsInBillingGroupResponse.filterSensitiveLog = function (obj) { return (__assign({}, obj)); };
1251
- })(ListThingsInBillingGroupResponse || (ListThingsInBillingGroupResponse = {}));
1252
- export var ListThingsInThingGroupRequest;
1253
- (function (ListThingsInThingGroupRequest) {
1254
- ListThingsInThingGroupRequest.filterSensitiveLog = function (obj) { return (__assign({}, obj)); };
1255
- })(ListThingsInThingGroupRequest || (ListThingsInThingGroupRequest = {}));
1256
- export var ListThingsInThingGroupResponse;
1257
- (function (ListThingsInThingGroupResponse) {
1258
- ListThingsInThingGroupResponse.filterSensitiveLog = function (obj) { return (__assign({}, obj)); };
1259
- })(ListThingsInThingGroupResponse || (ListThingsInThingGroupResponse = {}));
1260
- export var ListThingTypesRequest;
1261
- (function (ListThingTypesRequest) {
1262
- ListThingTypesRequest.filterSensitiveLog = function (obj) { return (__assign({}, obj)); };
1263
- })(ListThingTypesRequest || (ListThingTypesRequest = {}));
@@ -1,4 +1,32 @@
1
1
  import { __assign } from "tslib";
2
+ export var ThingAttribute;
3
+ (function (ThingAttribute) {
4
+ ThingAttribute.filterSensitiveLog = function (obj) { return (__assign({}, obj)); };
5
+ })(ThingAttribute || (ThingAttribute = {}));
6
+ export var ListThingsResponse;
7
+ (function (ListThingsResponse) {
8
+ ListThingsResponse.filterSensitiveLog = function (obj) { return (__assign({}, obj)); };
9
+ })(ListThingsResponse || (ListThingsResponse = {}));
10
+ export var ListThingsInBillingGroupRequest;
11
+ (function (ListThingsInBillingGroupRequest) {
12
+ ListThingsInBillingGroupRequest.filterSensitiveLog = function (obj) { return (__assign({}, obj)); };
13
+ })(ListThingsInBillingGroupRequest || (ListThingsInBillingGroupRequest = {}));
14
+ export var ListThingsInBillingGroupResponse;
15
+ (function (ListThingsInBillingGroupResponse) {
16
+ ListThingsInBillingGroupResponse.filterSensitiveLog = function (obj) { return (__assign({}, obj)); };
17
+ })(ListThingsInBillingGroupResponse || (ListThingsInBillingGroupResponse = {}));
18
+ export var ListThingsInThingGroupRequest;
19
+ (function (ListThingsInThingGroupRequest) {
20
+ ListThingsInThingGroupRequest.filterSensitiveLog = function (obj) { return (__assign({}, obj)); };
21
+ })(ListThingsInThingGroupRequest || (ListThingsInThingGroupRequest = {}));
22
+ export var ListThingsInThingGroupResponse;
23
+ (function (ListThingsInThingGroupResponse) {
24
+ ListThingsInThingGroupResponse.filterSensitiveLog = function (obj) { return (__assign({}, obj)); };
25
+ })(ListThingsInThingGroupResponse || (ListThingsInThingGroupResponse = {}));
26
+ export var ListThingTypesRequest;
27
+ (function (ListThingTypesRequest) {
28
+ ListThingTypesRequest.filterSensitiveLog = function (obj) { return (__assign({}, obj)); };
29
+ })(ListThingTypesRequest || (ListThingTypesRequest = {}));
2
30
  export var ThingTypeDefinition;
3
31
  (function (ThingTypeDefinition) {
4
32
  ThingTypeDefinition.filterSensitiveLog = function (obj) { return (__assign({}, obj)); };
@@ -878,8 +878,11 @@ export var serializeAws_restJson1CreateJobCommand = function (input, context) {
878
878
  else {
879
879
  throw new Error("No value provided for input HTTP label: jobId.");
880
880
  }
881
- body = JSON.stringify(__assign(__assign(__assign(__assign(__assign(__assign(__assign(__assign(__assign(__assign(__assign(__assign({}, (input.abortConfig !== undefined &&
882
- input.abortConfig !== null && { abortConfig: serializeAws_restJson1AbortConfig(input.abortConfig, context) })), (input.description !== undefined && input.description !== null && { description: input.description })), (input.document !== undefined && input.document !== null && { document: input.document })), (input.documentSource !== undefined &&
881
+ body = JSON.stringify(__assign(__assign(__assign(__assign(__assign(__assign(__assign(__assign(__assign(__assign(__assign(__assign(__assign({}, (input.abortConfig !== undefined &&
882
+ input.abortConfig !== null && { abortConfig: serializeAws_restJson1AbortConfig(input.abortConfig, context) })), (input.description !== undefined && input.description !== null && { description: input.description })), (input.document !== undefined && input.document !== null && { document: input.document })), (input.documentParameters !== undefined &&
883
+ input.documentParameters !== null && {
884
+ documentParameters: serializeAws_restJson1ParameterMap(input.documentParameters, context),
885
+ })), (input.documentSource !== undefined &&
883
886
  input.documentSource !== null && { documentSource: input.documentSource })), (input.jobExecutionsRolloutConfig !== undefined &&
884
887
  input.jobExecutionsRolloutConfig !== null && {
885
888
  jobExecutionsRolloutConfig: serializeAws_restJson1JobExecutionsRolloutConfig(input.jobExecutionsRolloutConfig, context),
@@ -3240,6 +3243,39 @@ export var serializeAws_restJson1DescribeJobTemplateCommand = function (input, c
3240
3243
  }
3241
3244
  });
3242
3245
  }); };
3246
+ export var serializeAws_restJson1DescribeManagedJobTemplateCommand = function (input, context) { return __awaiter(void 0, void 0, void 0, function () {
3247
+ var _a, hostname, _b, protocol, port, basePath, headers, resolvedPath, labelValue, query, body;
3248
+ return __generator(this, function (_c) {
3249
+ switch (_c.label) {
3250
+ case 0: return [4, context.endpoint()];
3251
+ case 1:
3252
+ _a = _c.sent(), hostname = _a.hostname, _b = _a.protocol, protocol = _b === void 0 ? "https" : _b, port = _a.port, basePath = _a.path;
3253
+ headers = {};
3254
+ resolvedPath = "" + ((basePath === null || basePath === void 0 ? void 0 : basePath.endsWith("/")) ? basePath.slice(0, -1) : basePath || "") + "/managed-job-templates/{templateName}";
3255
+ if (input.templateName !== undefined) {
3256
+ labelValue = input.templateName;
3257
+ if (labelValue.length <= 0) {
3258
+ throw new Error("Empty value provided for input HTTP label: templateName.");
3259
+ }
3260
+ resolvedPath = resolvedPath.replace("{templateName}", __extendedEncodeURIComponent(labelValue));
3261
+ }
3262
+ else {
3263
+ throw new Error("No value provided for input HTTP label: templateName.");
3264
+ }
3265
+ query = __assign({}, (input.templateVersion !== undefined && { templateVersion: input.templateVersion }));
3266
+ return [2, new __HttpRequest({
3267
+ protocol: protocol,
3268
+ hostname: hostname,
3269
+ port: port,
3270
+ method: "GET",
3271
+ headers: headers,
3272
+ path: resolvedPath,
3273
+ query: query,
3274
+ body: body,
3275
+ })];
3276
+ }
3277
+ });
3278
+ }); };
3243
3279
  export var serializeAws_restJson1DescribeMitigationActionCommand = function (input, context) { return __awaiter(void 0, void 0, void 0, function () {
3244
3280
  var _a, hostname, _b, protocol, port, basePath, headers, resolvedPath, labelValue, body;
3245
3281
  return __generator(this, function (_c) {
@@ -4816,6 +4852,29 @@ export var serializeAws_restJson1ListJobTemplatesCommand = function (input, cont
4816
4852
  }
4817
4853
  });
4818
4854
  }); };
4855
+ export var serializeAws_restJson1ListManagedJobTemplatesCommand = function (input, context) { return __awaiter(void 0, void 0, void 0, function () {
4856
+ var _a, hostname, _b, protocol, port, basePath, headers, resolvedPath, query, body;
4857
+ return __generator(this, function (_c) {
4858
+ switch (_c.label) {
4859
+ case 0: return [4, context.endpoint()];
4860
+ case 1:
4861
+ _a = _c.sent(), hostname = _a.hostname, _b = _a.protocol, protocol = _b === void 0 ? "https" : _b, port = _a.port, basePath = _a.path;
4862
+ headers = {};
4863
+ resolvedPath = "" + ((basePath === null || basePath === void 0 ? void 0 : basePath.endsWith("/")) ? basePath.slice(0, -1) : basePath || "") + "/managed-job-templates";
4864
+ query = __assign(__assign(__assign({}, (input.templateName !== undefined && { templateName: input.templateName })), (input.maxResults !== undefined && { maxResults: input.maxResults.toString() })), (input.nextToken !== undefined && { nextToken: input.nextToken }));
4865
+ return [2, new __HttpRequest({
4866
+ protocol: protocol,
4867
+ hostname: hostname,
4868
+ port: port,
4869
+ method: "GET",
4870
+ headers: headers,
4871
+ path: resolvedPath,
4872
+ query: query,
4873
+ body: body,
4874
+ })];
4875
+ }
4876
+ });
4877
+ }); };
4819
4878
  export var serializeAws_restJson1ListMitigationActionsCommand = function (input, context) { return __awaiter(void 0, void 0, void 0, function () {
4820
4879
  var _a, hostname, _b, protocol, port, basePath, headers, resolvedPath, query, body;
4821
4880
  return __generator(this, function (_c) {
@@ -16917,6 +16976,116 @@ var deserializeAws_restJson1DescribeJobTemplateCommandError = function (output,
16917
16976
  }
16918
16977
  });
16919
16978
  }); };
16979
+ export var deserializeAws_restJson1DescribeManagedJobTemplateCommand = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
16980
+ var contents, data, _a, _b;
16981
+ return __generator(this, function (_c) {
16982
+ switch (_c.label) {
16983
+ case 0:
16984
+ if (output.statusCode !== 200 && output.statusCode >= 300) {
16985
+ return [2, deserializeAws_restJson1DescribeManagedJobTemplateCommandError(output, context)];
16986
+ }
16987
+ contents = {
16988
+ $metadata: deserializeMetadata(output),
16989
+ description: undefined,
16990
+ document: undefined,
16991
+ documentParameters: undefined,
16992
+ environments: undefined,
16993
+ templateArn: undefined,
16994
+ templateName: undefined,
16995
+ templateVersion: undefined,
16996
+ };
16997
+ _a = __expectNonNull;
16998
+ _b = __expectObject;
16999
+ return [4, parseBody(output.body, context)];
17000
+ case 1:
17001
+ data = _a.apply(void 0, [_b.apply(void 0, [_c.sent()]), "body"]);
17002
+ if (data.description !== undefined && data.description !== null) {
17003
+ contents.description = __expectString(data.description);
17004
+ }
17005
+ if (data.document !== undefined && data.document !== null) {
17006
+ contents.document = __expectString(data.document);
17007
+ }
17008
+ if (data.documentParameters !== undefined && data.documentParameters !== null) {
17009
+ contents.documentParameters = deserializeAws_restJson1DocumentParameters(data.documentParameters, context);
17010
+ }
17011
+ if (data.environments !== undefined && data.environments !== null) {
17012
+ contents.environments = deserializeAws_restJson1Environments(data.environments, context);
17013
+ }
17014
+ if (data.templateArn !== undefined && data.templateArn !== null) {
17015
+ contents.templateArn = __expectString(data.templateArn);
17016
+ }
17017
+ if (data.templateName !== undefined && data.templateName !== null) {
17018
+ contents.templateName = __expectString(data.templateName);
17019
+ }
17020
+ if (data.templateVersion !== undefined && data.templateVersion !== null) {
17021
+ contents.templateVersion = __expectString(data.templateVersion);
17022
+ }
17023
+ return [2, Promise.resolve(contents)];
17024
+ }
17025
+ });
17026
+ }); };
17027
+ var deserializeAws_restJson1DescribeManagedJobTemplateCommandError = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
17028
+ var parsedOutput, _a, response, errorCode, _b, _c, _d, _e, _f, parsedBody, message;
17029
+ var _g;
17030
+ return __generator(this, function (_h) {
17031
+ switch (_h.label) {
17032
+ case 0:
17033
+ _a = [__assign({}, output)];
17034
+ _g = {};
17035
+ return [4, parseBody(output.body, context)];
17036
+ case 1:
17037
+ parsedOutput = __assign.apply(void 0, _a.concat([(_g.body = _h.sent(), _g)]));
17038
+ errorCode = "UnknownError";
17039
+ errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
17040
+ _b = errorCode;
17041
+ switch (_b) {
17042
+ case "InternalServerException": return [3, 2];
17043
+ case "com.amazonaws.iot#InternalServerException": return [3, 2];
17044
+ case "InvalidRequestException": return [3, 4];
17045
+ case "com.amazonaws.iot#InvalidRequestException": return [3, 4];
17046
+ case "ResourceNotFoundException": return [3, 6];
17047
+ case "com.amazonaws.iot#ResourceNotFoundException": return [3, 6];
17048
+ case "ThrottlingException": return [3, 8];
17049
+ case "com.amazonaws.iot#ThrottlingException": return [3, 8];
17050
+ }
17051
+ return [3, 10];
17052
+ case 2:
17053
+ _c = [{}];
17054
+ return [4, deserializeAws_restJson1InternalServerExceptionResponse(parsedOutput, context)];
17055
+ case 3:
17056
+ response = __assign.apply(void 0, [__assign.apply(void 0, _c.concat([(_h.sent())])), { name: errorCode, $metadata: deserializeMetadata(output) }]);
17057
+ return [3, 11];
17058
+ case 4:
17059
+ _d = [{}];
17060
+ return [4, deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)];
17061
+ case 5:
17062
+ response = __assign.apply(void 0, [__assign.apply(void 0, _d.concat([(_h.sent())])), { name: errorCode, $metadata: deserializeMetadata(output) }]);
17063
+ return [3, 11];
17064
+ case 6:
17065
+ _e = [{}];
17066
+ return [4, deserializeAws_restJson1ResourceNotFoundExceptionResponse(parsedOutput, context)];
17067
+ case 7:
17068
+ response = __assign.apply(void 0, [__assign.apply(void 0, _e.concat([(_h.sent())])), { name: errorCode, $metadata: deserializeMetadata(output) }]);
17069
+ return [3, 11];
17070
+ case 8:
17071
+ _f = [{}];
17072
+ return [4, deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)];
17073
+ case 9:
17074
+ response = __assign.apply(void 0, [__assign.apply(void 0, _f.concat([(_h.sent())])), { name: errorCode, $metadata: deserializeMetadata(output) }]);
17075
+ return [3, 11];
17076
+ case 10:
17077
+ parsedBody = parsedOutput.body;
17078
+ errorCode = parsedBody.code || parsedBody.Code || errorCode;
17079
+ response = __assign(__assign({}, parsedBody), { name: "" + errorCode, message: parsedBody.message || parsedBody.Message || errorCode, $fault: "client", $metadata: deserializeMetadata(output) });
17080
+ _h.label = 11;
17081
+ case 11:
17082
+ message = response.message || response.Message || errorCode;
17083
+ response.message = message;
17084
+ delete response.Message;
17085
+ return [2, Promise.reject(Object.assign(new Error(message), response))];
17086
+ }
17087
+ });
17088
+ }); };
16920
17089
  export var deserializeAws_restJson1DescribeMitigationActionCommand = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
16921
17090
  var contents, data, _a, _b;
16922
17091
  return __generator(this, function (_c) {
@@ -22509,6 +22678,96 @@ var deserializeAws_restJson1ListJobTemplatesCommandError = function (output, con
22509
22678
  }
22510
22679
  });
22511
22680
  }); };
22681
+ export var deserializeAws_restJson1ListManagedJobTemplatesCommand = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
22682
+ var contents, data, _a, _b;
22683
+ return __generator(this, function (_c) {
22684
+ switch (_c.label) {
22685
+ case 0:
22686
+ if (output.statusCode !== 200 && output.statusCode >= 300) {
22687
+ return [2, deserializeAws_restJson1ListManagedJobTemplatesCommandError(output, context)];
22688
+ }
22689
+ contents = {
22690
+ $metadata: deserializeMetadata(output),
22691
+ managedJobTemplates: undefined,
22692
+ nextToken: undefined,
22693
+ };
22694
+ _a = __expectNonNull;
22695
+ _b = __expectObject;
22696
+ return [4, parseBody(output.body, context)];
22697
+ case 1:
22698
+ data = _a.apply(void 0, [_b.apply(void 0, [_c.sent()]), "body"]);
22699
+ if (data.managedJobTemplates !== undefined && data.managedJobTemplates !== null) {
22700
+ contents.managedJobTemplates = deserializeAws_restJson1ManagedJobTemplatesSummaryList(data.managedJobTemplates, context);
22701
+ }
22702
+ if (data.nextToken !== undefined && data.nextToken !== null) {
22703
+ contents.nextToken = __expectString(data.nextToken);
22704
+ }
22705
+ return [2, Promise.resolve(contents)];
22706
+ }
22707
+ });
22708
+ }); };
22709
+ var deserializeAws_restJson1ListManagedJobTemplatesCommandError = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
22710
+ var parsedOutput, _a, response, errorCode, _b, _c, _d, _e, _f, parsedBody, message;
22711
+ var _g;
22712
+ return __generator(this, function (_h) {
22713
+ switch (_h.label) {
22714
+ case 0:
22715
+ _a = [__assign({}, output)];
22716
+ _g = {};
22717
+ return [4, parseBody(output.body, context)];
22718
+ case 1:
22719
+ parsedOutput = __assign.apply(void 0, _a.concat([(_g.body = _h.sent(), _g)]));
22720
+ errorCode = "UnknownError";
22721
+ errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
22722
+ _b = errorCode;
22723
+ switch (_b) {
22724
+ case "InternalServerException": return [3, 2];
22725
+ case "com.amazonaws.iot#InternalServerException": return [3, 2];
22726
+ case "InvalidRequestException": return [3, 4];
22727
+ case "com.amazonaws.iot#InvalidRequestException": return [3, 4];
22728
+ case "ResourceNotFoundException": return [3, 6];
22729
+ case "com.amazonaws.iot#ResourceNotFoundException": return [3, 6];
22730
+ case "ThrottlingException": return [3, 8];
22731
+ case "com.amazonaws.iot#ThrottlingException": return [3, 8];
22732
+ }
22733
+ return [3, 10];
22734
+ case 2:
22735
+ _c = [{}];
22736
+ return [4, deserializeAws_restJson1InternalServerExceptionResponse(parsedOutput, context)];
22737
+ case 3:
22738
+ response = __assign.apply(void 0, [__assign.apply(void 0, _c.concat([(_h.sent())])), { name: errorCode, $metadata: deserializeMetadata(output) }]);
22739
+ return [3, 11];
22740
+ case 4:
22741
+ _d = [{}];
22742
+ return [4, deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)];
22743
+ case 5:
22744
+ response = __assign.apply(void 0, [__assign.apply(void 0, _d.concat([(_h.sent())])), { name: errorCode, $metadata: deserializeMetadata(output) }]);
22745
+ return [3, 11];
22746
+ case 6:
22747
+ _e = [{}];
22748
+ return [4, deserializeAws_restJson1ResourceNotFoundExceptionResponse(parsedOutput, context)];
22749
+ case 7:
22750
+ response = __assign.apply(void 0, [__assign.apply(void 0, _e.concat([(_h.sent())])), { name: errorCode, $metadata: deserializeMetadata(output) }]);
22751
+ return [3, 11];
22752
+ case 8:
22753
+ _f = [{}];
22754
+ return [4, deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)];
22755
+ case 9:
22756
+ response = __assign.apply(void 0, [__assign.apply(void 0, _f.concat([(_h.sent())])), { name: errorCode, $metadata: deserializeMetadata(output) }]);
22757
+ return [3, 11];
22758
+ case 10:
22759
+ parsedBody = parsedOutput.body;
22760
+ errorCode = parsedBody.code || parsedBody.Code || errorCode;
22761
+ response = __assign(__assign({}, parsedBody), { name: "" + errorCode, message: parsedBody.message || parsedBody.Message || errorCode, $fault: "client", $metadata: deserializeMetadata(output) });
22762
+ _h.label = 11;
22763
+ case 11:
22764
+ message = response.message || response.Message || errorCode;
22765
+ response.message = message;
22766
+ delete response.Message;
22767
+ return [2, Promise.reject(Object.assign(new Error(message), response))];
22768
+ }
22769
+ });
22770
+ }); };
22512
22771
  export var deserializeAws_restJson1ListMitigationActionsCommand = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
22513
22772
  var contents, data, _a, _b;
22514
22773
  return __generator(this, function (_c) {
@@ -30463,6 +30722,22 @@ var deserializeAws_restJson1InternalFailureExceptionResponse = function (parsedO
30463
30722
  return [2, contents];
30464
30723
  });
30465
30724
  }); };
30725
+ var deserializeAws_restJson1InternalServerExceptionResponse = function (parsedOutput, context) { return __awaiter(void 0, void 0, void 0, function () {
30726
+ var contents, data;
30727
+ return __generator(this, function (_a) {
30728
+ contents = {
30729
+ name: "InternalServerException",
30730
+ $fault: "server",
30731
+ $metadata: deserializeMetadata(parsedOutput),
30732
+ message: undefined,
30733
+ };
30734
+ data = parsedOutput.body;
30735
+ if (data.message !== undefined && data.message !== null) {
30736
+ contents.message = __expectString(data.message);
30737
+ }
30738
+ return [2, contents];
30739
+ });
30740
+ }); };
30466
30741
  var deserializeAws_restJson1InvalidAggregationExceptionResponse = function (parsedOutput, context) { return __awaiter(void 0, void 0, void 0, function () {
30467
30742
  var contents, data;
30468
30743
  return __generator(this, function (_a) {
@@ -31498,6 +31773,16 @@ var serializeAws_restJson1OTAUpdateFiles = function (input, context) {
31498
31773
  return serializeAws_restJson1OTAUpdateFile(entry, context);
31499
31774
  });
31500
31775
  };
31776
+ var serializeAws_restJson1ParameterMap = function (input, context) {
31777
+ return Object.entries(input).reduce(function (acc, _a) {
31778
+ var _b;
31779
+ var _c = __read(_a, 2), key = _c[0], value = _c[1];
31780
+ if (value === null) {
31781
+ return acc;
31782
+ }
31783
+ return __assign(__assign({}, acc), (_b = {}, _b[key] = value, _b));
31784
+ }, {});
31785
+ };
31501
31786
  var serializeAws_restJson1Parameters = function (input, context) {
31502
31787
  return Object.entries(input).reduce(function (acc, _a) {
31503
31788
  var _b;
@@ -32925,6 +33210,25 @@ var deserializeAws_restJson1DimensionStringValues = function (output, context) {
32925
33210
  return __expectString(entry);
32926
33211
  });
32927
33212
  };
33213
+ var deserializeAws_restJson1DocumentParameter = function (output, context) {
33214
+ return {
33215
+ description: __expectString(output.description),
33216
+ example: __expectString(output.example),
33217
+ key: __expectString(output.key),
33218
+ optional: __expectBoolean(output.optional),
33219
+ regex: __expectString(output.regex),
33220
+ };
33221
+ };
33222
+ var deserializeAws_restJson1DocumentParameters = function (output, context) {
33223
+ return (output || [])
33224
+ .filter(function (e) { return e != null; })
33225
+ .map(function (entry) {
33226
+ if (entry === null) {
33227
+ return null;
33228
+ }
33229
+ return deserializeAws_restJson1DocumentParameter(entry, context);
33230
+ });
33231
+ };
32928
33232
  var deserializeAws_restJson1DomainConfigurations = function (output, context) {
32929
33233
  return (output || [])
32930
33234
  .filter(function (e) { return e != null; })
@@ -32996,6 +33300,16 @@ var deserializeAws_restJson1EnableIoTLoggingParams = function (output, context)
32996
33300
  roleArnForLogging: __expectString(output.roleArnForLogging),
32997
33301
  };
32998
33302
  };
33303
+ var deserializeAws_restJson1Environments = function (output, context) {
33304
+ return (output || [])
33305
+ .filter(function (e) { return e != null; })
33306
+ .map(function (entry) {
33307
+ if (entry === null) {
33308
+ return null;
33309
+ }
33310
+ return __expectString(entry);
33311
+ });
33312
+ };
32999
33313
  var deserializeAws_restJson1ErrorInfo = function (output, context) {
33000
33314
  return {
33001
33315
  code: __expectString(output.code),
@@ -33193,6 +33507,9 @@ var deserializeAws_restJson1Job = function (output, context) {
33193
33507
  ? __expectNonNull(__parseEpochTimestamp(__expectNumber(output.createdAt)))
33194
33508
  : undefined,
33195
33509
  description: __expectString(output.description),
33510
+ documentParameters: output.documentParameters !== undefined && output.documentParameters !== null
33511
+ ? deserializeAws_restJson1ParameterMap(output.documentParameters, context)
33512
+ : undefined,
33196
33513
  forceCanceled: __expectBoolean(output.forceCanceled),
33197
33514
  jobArn: __expectString(output.jobArn),
33198
33515
  jobExecutionsRolloutConfig: output.jobExecutionsRolloutConfig !== undefined && output.jobExecutionsRolloutConfig !== null
@@ -33441,6 +33758,27 @@ var deserializeAws_restJson1MachineLearningDetectionConfig = function (output, c
33441
33758
  confidenceLevel: __expectString(output.confidenceLevel),
33442
33759
  };
33443
33760
  };
33761
+ var deserializeAws_restJson1ManagedJobTemplatesSummaryList = function (output, context) {
33762
+ return (output || [])
33763
+ .filter(function (e) { return e != null; })
33764
+ .map(function (entry) {
33765
+ if (entry === null) {
33766
+ return null;
33767
+ }
33768
+ return deserializeAws_restJson1ManagedJobTemplateSummary(entry, context);
33769
+ });
33770
+ };
33771
+ var deserializeAws_restJson1ManagedJobTemplateSummary = function (output, context) {
33772
+ return {
33773
+ description: __expectString(output.description),
33774
+ environments: output.environments !== undefined && output.environments !== null
33775
+ ? deserializeAws_restJson1Environments(output.environments, context)
33776
+ : undefined,
33777
+ templateArn: __expectString(output.templateArn),
33778
+ templateName: __expectString(output.templateName),
33779
+ templateVersion: __expectString(output.templateVersion),
33780
+ };
33781
+ };
33444
33782
  var deserializeAws_restJson1MetricDimension = function (output, context) {
33445
33783
  return {
33446
33784
  dimensionName: __expectString(output.dimensionName),
@@ -33701,6 +34039,16 @@ var deserializeAws_restJson1OutgoingCertificates = function (output, context) {
33701
34039
  return deserializeAws_restJson1OutgoingCertificate(entry, context);
33702
34040
  });
33703
34041
  };
34042
+ var deserializeAws_restJson1ParameterMap = function (output, context) {
34043
+ return Object.entries(output).reduce(function (acc, _a) {
34044
+ var _b;
34045
+ var _c = __read(_a, 2), key = _c[0], value = _c[1];
34046
+ if (value === null) {
34047
+ return acc;
34048
+ }
34049
+ return __assign(__assign({}, acc), (_b = {}, _b[key] = __expectString(value), _b));
34050
+ }, {});
34051
+ };
33704
34052
  var deserializeAws_restJson1Percentiles = function (output, context) {
33705
34053
  return (output || [])
33706
34054
  .filter(function (e) { return e != null; })