@aws-sdk/client-synthetics 3.477.0 → 3.481.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 (117) hide show
  1. package/dist-cjs/commands/AssociateResourceCommand.js +18 -41
  2. package/dist-cjs/commands/CreateCanaryCommand.js +18 -41
  3. package/dist-cjs/commands/CreateGroupCommand.js +18 -41
  4. package/dist-cjs/commands/DeleteCanaryCommand.js +18 -41
  5. package/dist-cjs/commands/DeleteGroupCommand.js +18 -41
  6. package/dist-cjs/commands/DescribeCanariesCommand.js +18 -41
  7. package/dist-cjs/commands/DescribeCanariesLastRunCommand.js +18 -41
  8. package/dist-cjs/commands/DescribeRuntimeVersionsCommand.js +18 -41
  9. package/dist-cjs/commands/DisassociateResourceCommand.js +18 -41
  10. package/dist-cjs/commands/GetCanaryCommand.js +18 -41
  11. package/dist-cjs/commands/GetCanaryRunsCommand.js +18 -41
  12. package/dist-cjs/commands/GetGroupCommand.js +18 -41
  13. package/dist-cjs/commands/ListAssociatedGroupsCommand.js +18 -41
  14. package/dist-cjs/commands/ListGroupResourcesCommand.js +18 -41
  15. package/dist-cjs/commands/ListGroupsCommand.js +18 -41
  16. package/dist-cjs/commands/ListTagsForResourceCommand.js +18 -41
  17. package/dist-cjs/commands/StartCanaryCommand.js +18 -41
  18. package/dist-cjs/commands/StopCanaryCommand.js +18 -41
  19. package/dist-cjs/commands/TagResourceCommand.js +18 -41
  20. package/dist-cjs/commands/UntagResourceCommand.js +18 -41
  21. package/dist-cjs/commands/UpdateCanaryCommand.js +18 -41
  22. package/dist-cjs/endpoint/EndpointParameters.js +7 -1
  23. package/dist-cjs/pagination/DescribeCanariesLastRunPaginator.js +2 -24
  24. package/dist-cjs/pagination/DescribeCanariesPaginator.js +2 -24
  25. package/dist-cjs/pagination/DescribeRuntimeVersionsPaginator.js +2 -24
  26. package/dist-cjs/pagination/GetCanaryRunsPaginator.js +2 -24
  27. package/dist-cjs/pagination/ListAssociatedGroupsPaginator.js +2 -24
  28. package/dist-cjs/pagination/ListGroupResourcesPaginator.js +2 -24
  29. package/dist-cjs/pagination/ListGroupsPaginator.js +2 -24
  30. package/dist-es/commands/AssociateResourceCommand.js +18 -41
  31. package/dist-es/commands/CreateCanaryCommand.js +18 -41
  32. package/dist-es/commands/CreateGroupCommand.js +18 -41
  33. package/dist-es/commands/DeleteCanaryCommand.js +18 -41
  34. package/dist-es/commands/DeleteGroupCommand.js +18 -41
  35. package/dist-es/commands/DescribeCanariesCommand.js +18 -41
  36. package/dist-es/commands/DescribeCanariesLastRunCommand.js +18 -41
  37. package/dist-es/commands/DescribeRuntimeVersionsCommand.js +18 -41
  38. package/dist-es/commands/DisassociateResourceCommand.js +18 -41
  39. package/dist-es/commands/GetCanaryCommand.js +18 -41
  40. package/dist-es/commands/GetCanaryRunsCommand.js +18 -41
  41. package/dist-es/commands/GetGroupCommand.js +18 -41
  42. package/dist-es/commands/ListAssociatedGroupsCommand.js +18 -41
  43. package/dist-es/commands/ListGroupResourcesCommand.js +18 -41
  44. package/dist-es/commands/ListGroupsCommand.js +18 -41
  45. package/dist-es/commands/ListTagsForResourceCommand.js +18 -41
  46. package/dist-es/commands/StartCanaryCommand.js +18 -41
  47. package/dist-es/commands/StopCanaryCommand.js +18 -41
  48. package/dist-es/commands/TagResourceCommand.js +18 -41
  49. package/dist-es/commands/UntagResourceCommand.js +18 -41
  50. package/dist-es/commands/UpdateCanaryCommand.js +18 -41
  51. package/dist-es/endpoint/EndpointParameters.js +6 -0
  52. package/dist-es/pagination/DescribeCanariesLastRunPaginator.js +2 -23
  53. package/dist-es/pagination/DescribeCanariesPaginator.js +2 -23
  54. package/dist-es/pagination/DescribeRuntimeVersionsPaginator.js +2 -23
  55. package/dist-es/pagination/GetCanaryRunsPaginator.js +2 -23
  56. package/dist-es/pagination/ListAssociatedGroupsPaginator.js +2 -23
  57. package/dist-es/pagination/ListGroupResourcesPaginator.js +2 -23
  58. package/dist-es/pagination/ListGroupsPaginator.js +2 -23
  59. package/dist-types/commands/AssociateResourceCommand.d.ts +6 -21
  60. package/dist-types/commands/CreateCanaryCommand.d.ts +6 -21
  61. package/dist-types/commands/CreateGroupCommand.d.ts +6 -21
  62. package/dist-types/commands/DeleteCanaryCommand.d.ts +6 -21
  63. package/dist-types/commands/DeleteGroupCommand.d.ts +6 -21
  64. package/dist-types/commands/DescribeCanariesCommand.d.ts +6 -21
  65. package/dist-types/commands/DescribeCanariesLastRunCommand.d.ts +6 -21
  66. package/dist-types/commands/DescribeRuntimeVersionsCommand.d.ts +6 -21
  67. package/dist-types/commands/DisassociateResourceCommand.d.ts +6 -21
  68. package/dist-types/commands/GetCanaryCommand.d.ts +6 -21
  69. package/dist-types/commands/GetCanaryRunsCommand.d.ts +6 -21
  70. package/dist-types/commands/GetGroupCommand.d.ts +6 -21
  71. package/dist-types/commands/ListAssociatedGroupsCommand.d.ts +6 -21
  72. package/dist-types/commands/ListGroupResourcesCommand.d.ts +6 -21
  73. package/dist-types/commands/ListGroupsCommand.d.ts +6 -21
  74. package/dist-types/commands/ListTagsForResourceCommand.d.ts +6 -21
  75. package/dist-types/commands/StartCanaryCommand.d.ts +6 -21
  76. package/dist-types/commands/StopCanaryCommand.d.ts +6 -21
  77. package/dist-types/commands/TagResourceCommand.d.ts +6 -21
  78. package/dist-types/commands/UntagResourceCommand.d.ts +6 -21
  79. package/dist-types/commands/UpdateCanaryCommand.d.ts +6 -21
  80. package/dist-types/endpoint/EndpointParameters.d.ts +18 -0
  81. package/dist-types/pagination/DescribeCanariesLastRunPaginator.d.ts +1 -1
  82. package/dist-types/pagination/DescribeCanariesPaginator.d.ts +1 -1
  83. package/dist-types/pagination/DescribeRuntimeVersionsPaginator.d.ts +1 -1
  84. package/dist-types/pagination/GetCanaryRunsPaginator.d.ts +1 -1
  85. package/dist-types/pagination/ListAssociatedGroupsPaginator.d.ts +1 -1
  86. package/dist-types/pagination/ListGroupResourcesPaginator.d.ts +1 -1
  87. package/dist-types/pagination/ListGroupsPaginator.d.ts +1 -1
  88. package/dist-types/ts3.4/commands/AssociateResourceCommand.d.ts +14 -23
  89. package/dist-types/ts3.4/commands/CreateCanaryCommand.d.ts +14 -23
  90. package/dist-types/ts3.4/commands/CreateGroupCommand.d.ts +14 -23
  91. package/dist-types/ts3.4/commands/DeleteCanaryCommand.d.ts +14 -23
  92. package/dist-types/ts3.4/commands/DeleteGroupCommand.d.ts +14 -23
  93. package/dist-types/ts3.4/commands/DescribeCanariesCommand.d.ts +14 -23
  94. package/dist-types/ts3.4/commands/DescribeCanariesLastRunCommand.d.ts +12 -24
  95. package/dist-types/ts3.4/commands/DescribeRuntimeVersionsCommand.d.ts +12 -24
  96. package/dist-types/ts3.4/commands/DisassociateResourceCommand.d.ts +12 -24
  97. package/dist-types/ts3.4/commands/GetCanaryCommand.d.ts +14 -23
  98. package/dist-types/ts3.4/commands/GetCanaryRunsCommand.d.ts +14 -23
  99. package/dist-types/ts3.4/commands/GetGroupCommand.d.ts +14 -23
  100. package/dist-types/ts3.4/commands/ListAssociatedGroupsCommand.d.ts +12 -24
  101. package/dist-types/ts3.4/commands/ListGroupResourcesCommand.d.ts +14 -23
  102. package/dist-types/ts3.4/commands/ListGroupsCommand.d.ts +14 -23
  103. package/dist-types/ts3.4/commands/ListTagsForResourceCommand.d.ts +14 -23
  104. package/dist-types/ts3.4/commands/StartCanaryCommand.d.ts +14 -23
  105. package/dist-types/ts3.4/commands/StopCanaryCommand.d.ts +14 -23
  106. package/dist-types/ts3.4/commands/TagResourceCommand.d.ts +14 -23
  107. package/dist-types/ts3.4/commands/UntagResourceCommand.d.ts +14 -23
  108. package/dist-types/ts3.4/commands/UpdateCanaryCommand.d.ts +14 -23
  109. package/dist-types/ts3.4/endpoint/EndpointParameters.d.ts +18 -0
  110. package/dist-types/ts3.4/pagination/DescribeCanariesLastRunPaginator.d.ts +3 -3
  111. package/dist-types/ts3.4/pagination/DescribeCanariesPaginator.d.ts +3 -3
  112. package/dist-types/ts3.4/pagination/DescribeRuntimeVersionsPaginator.d.ts +3 -3
  113. package/dist-types/ts3.4/pagination/GetCanaryRunsPaginator.d.ts +3 -3
  114. package/dist-types/ts3.4/pagination/ListAssociatedGroupsPaginator.d.ts +3 -3
  115. package/dist-types/ts3.4/pagination/ListGroupResourcesPaginator.d.ts +3 -3
  116. package/dist-types/ts3.4/pagination/ListGroupsPaginator.d.ts +3 -3
  117. package/package.json +11 -11
@@ -5,47 +5,24 @@ const middleware_endpoint_1 = require("@smithy/middleware-endpoint");
5
5
  const middleware_serde_1 = require("@smithy/middleware-serde");
6
6
  const smithy_client_1 = require("@smithy/smithy-client");
7
7
  Object.defineProperty(exports, "$Command", { enumerable: true, get: function () { return smithy_client_1.Command; } });
8
- const types_1 = require("@smithy/types");
8
+ const EndpointParameters_1 = require("../endpoint/EndpointParameters");
9
9
  const Aws_restJson1_1 = require("../protocols/Aws_restJson1");
10
- class TagResourceCommand extends smithy_client_1.Command {
11
- static getEndpointParameterInstructions() {
12
- return {
13
- UseFIPS: { type: "builtInParams", name: "useFipsEndpoint" },
14
- Endpoint: { type: "builtInParams", name: "endpoint" },
15
- Region: { type: "builtInParams", name: "region" },
16
- UseDualStack: { type: "builtInParams", name: "useDualstackEndpoint" },
17
- };
18
- }
19
- constructor(input) {
20
- super();
21
- this.input = input;
22
- }
23
- resolveMiddleware(clientStack, configuration, options) {
24
- this.middlewareStack.use((0, middleware_serde_1.getSerdePlugin)(configuration, this.serialize, this.deserialize));
25
- this.middlewareStack.use((0, middleware_endpoint_1.getEndpointPlugin)(configuration, TagResourceCommand.getEndpointParameterInstructions()));
26
- const stack = clientStack.concat(this.middlewareStack);
27
- const { logger } = configuration;
28
- const clientName = "SyntheticsClient";
29
- const commandName = "TagResourceCommand";
30
- const handlerExecutionContext = {
31
- logger,
32
- clientName,
33
- commandName,
34
- inputFilterSensitiveLog: (_) => _,
35
- outputFilterSensitiveLog: (_) => _,
36
- [types_1.SMITHY_CONTEXT_KEY]: {
37
- service: "Synthetics",
38
- operation: "TagResource",
39
- },
40
- };
41
- const { requestHandler } = configuration;
42
- return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext);
43
- }
44
- serialize(input, context) {
45
- return (0, Aws_restJson1_1.se_TagResourceCommand)(input, context);
46
- }
47
- deserialize(output, context) {
48
- return (0, Aws_restJson1_1.de_TagResourceCommand)(output, context);
49
- }
10
+ class TagResourceCommand extends smithy_client_1.Command
11
+ .classBuilder()
12
+ .ep({
13
+ ...EndpointParameters_1.commonParams,
14
+ })
15
+ .m(function (Command, cs, config, o) {
16
+ return [
17
+ (0, middleware_serde_1.getSerdePlugin)(config, this.serialize, this.deserialize),
18
+ (0, middleware_endpoint_1.getEndpointPlugin)(config, Command.getEndpointParameterInstructions()),
19
+ ];
20
+ })
21
+ .s("Synthetics", "TagResource", {})
22
+ .n("SyntheticsClient", "TagResourceCommand")
23
+ .f(void 0, void 0)
24
+ .ser(Aws_restJson1_1.se_TagResourceCommand)
25
+ .de(Aws_restJson1_1.de_TagResourceCommand)
26
+ .build() {
50
27
  }
51
28
  exports.TagResourceCommand = TagResourceCommand;
@@ -5,47 +5,24 @@ const middleware_endpoint_1 = require("@smithy/middleware-endpoint");
5
5
  const middleware_serde_1 = require("@smithy/middleware-serde");
6
6
  const smithy_client_1 = require("@smithy/smithy-client");
7
7
  Object.defineProperty(exports, "$Command", { enumerable: true, get: function () { return smithy_client_1.Command; } });
8
- const types_1 = require("@smithy/types");
8
+ const EndpointParameters_1 = require("../endpoint/EndpointParameters");
9
9
  const Aws_restJson1_1 = require("../protocols/Aws_restJson1");
10
- class UntagResourceCommand extends smithy_client_1.Command {
11
- static getEndpointParameterInstructions() {
12
- return {
13
- UseFIPS: { type: "builtInParams", name: "useFipsEndpoint" },
14
- Endpoint: { type: "builtInParams", name: "endpoint" },
15
- Region: { type: "builtInParams", name: "region" },
16
- UseDualStack: { type: "builtInParams", name: "useDualstackEndpoint" },
17
- };
18
- }
19
- constructor(input) {
20
- super();
21
- this.input = input;
22
- }
23
- resolveMiddleware(clientStack, configuration, options) {
24
- this.middlewareStack.use((0, middleware_serde_1.getSerdePlugin)(configuration, this.serialize, this.deserialize));
25
- this.middlewareStack.use((0, middleware_endpoint_1.getEndpointPlugin)(configuration, UntagResourceCommand.getEndpointParameterInstructions()));
26
- const stack = clientStack.concat(this.middlewareStack);
27
- const { logger } = configuration;
28
- const clientName = "SyntheticsClient";
29
- const commandName = "UntagResourceCommand";
30
- const handlerExecutionContext = {
31
- logger,
32
- clientName,
33
- commandName,
34
- inputFilterSensitiveLog: (_) => _,
35
- outputFilterSensitiveLog: (_) => _,
36
- [types_1.SMITHY_CONTEXT_KEY]: {
37
- service: "Synthetics",
38
- operation: "UntagResource",
39
- },
40
- };
41
- const { requestHandler } = configuration;
42
- return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext);
43
- }
44
- serialize(input, context) {
45
- return (0, Aws_restJson1_1.se_UntagResourceCommand)(input, context);
46
- }
47
- deserialize(output, context) {
48
- return (0, Aws_restJson1_1.de_UntagResourceCommand)(output, context);
49
- }
10
+ class UntagResourceCommand extends smithy_client_1.Command
11
+ .classBuilder()
12
+ .ep({
13
+ ...EndpointParameters_1.commonParams,
14
+ })
15
+ .m(function (Command, cs, config, o) {
16
+ return [
17
+ (0, middleware_serde_1.getSerdePlugin)(config, this.serialize, this.deserialize),
18
+ (0, middleware_endpoint_1.getEndpointPlugin)(config, Command.getEndpointParameterInstructions()),
19
+ ];
20
+ })
21
+ .s("Synthetics", "UntagResource", {})
22
+ .n("SyntheticsClient", "UntagResourceCommand")
23
+ .f(void 0, void 0)
24
+ .ser(Aws_restJson1_1.se_UntagResourceCommand)
25
+ .de(Aws_restJson1_1.de_UntagResourceCommand)
26
+ .build() {
50
27
  }
51
28
  exports.UntagResourceCommand = UntagResourceCommand;
@@ -5,47 +5,24 @@ const middleware_endpoint_1 = require("@smithy/middleware-endpoint");
5
5
  const middleware_serde_1 = require("@smithy/middleware-serde");
6
6
  const smithy_client_1 = require("@smithy/smithy-client");
7
7
  Object.defineProperty(exports, "$Command", { enumerable: true, get: function () { return smithy_client_1.Command; } });
8
- const types_1 = require("@smithy/types");
8
+ const EndpointParameters_1 = require("../endpoint/EndpointParameters");
9
9
  const Aws_restJson1_1 = require("../protocols/Aws_restJson1");
10
- class UpdateCanaryCommand extends smithy_client_1.Command {
11
- static getEndpointParameterInstructions() {
12
- return {
13
- UseFIPS: { type: "builtInParams", name: "useFipsEndpoint" },
14
- Endpoint: { type: "builtInParams", name: "endpoint" },
15
- Region: { type: "builtInParams", name: "region" },
16
- UseDualStack: { type: "builtInParams", name: "useDualstackEndpoint" },
17
- };
18
- }
19
- constructor(input) {
20
- super();
21
- this.input = input;
22
- }
23
- resolveMiddleware(clientStack, configuration, options) {
24
- this.middlewareStack.use((0, middleware_serde_1.getSerdePlugin)(configuration, this.serialize, this.deserialize));
25
- this.middlewareStack.use((0, middleware_endpoint_1.getEndpointPlugin)(configuration, UpdateCanaryCommand.getEndpointParameterInstructions()));
26
- const stack = clientStack.concat(this.middlewareStack);
27
- const { logger } = configuration;
28
- const clientName = "SyntheticsClient";
29
- const commandName = "UpdateCanaryCommand";
30
- const handlerExecutionContext = {
31
- logger,
32
- clientName,
33
- commandName,
34
- inputFilterSensitiveLog: (_) => _,
35
- outputFilterSensitiveLog: (_) => _,
36
- [types_1.SMITHY_CONTEXT_KEY]: {
37
- service: "Synthetics",
38
- operation: "UpdateCanary",
39
- },
40
- };
41
- const { requestHandler } = configuration;
42
- return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext);
43
- }
44
- serialize(input, context) {
45
- return (0, Aws_restJson1_1.se_UpdateCanaryCommand)(input, context);
46
- }
47
- deserialize(output, context) {
48
- return (0, Aws_restJson1_1.de_UpdateCanaryCommand)(output, context);
49
- }
10
+ class UpdateCanaryCommand extends smithy_client_1.Command
11
+ .classBuilder()
12
+ .ep({
13
+ ...EndpointParameters_1.commonParams,
14
+ })
15
+ .m(function (Command, cs, config, o) {
16
+ return [
17
+ (0, middleware_serde_1.getSerdePlugin)(config, this.serialize, this.deserialize),
18
+ (0, middleware_endpoint_1.getEndpointPlugin)(config, Command.getEndpointParameterInstructions()),
19
+ ];
20
+ })
21
+ .s("Synthetics", "UpdateCanary", {})
22
+ .n("SyntheticsClient", "UpdateCanaryCommand")
23
+ .f(void 0, void 0)
24
+ .ser(Aws_restJson1_1.se_UpdateCanaryCommand)
25
+ .de(Aws_restJson1_1.de_UpdateCanaryCommand)
26
+ .build() {
50
27
  }
51
28
  exports.UpdateCanaryCommand = UpdateCanaryCommand;
@@ -1,6 +1,6 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.resolveClientEndpointParameters = void 0;
3
+ exports.commonParams = exports.resolveClientEndpointParameters = void 0;
4
4
  const resolveClientEndpointParameters = (options) => {
5
5
  return {
6
6
  ...options,
@@ -10,3 +10,9 @@ const resolveClientEndpointParameters = (options) => {
10
10
  };
11
11
  };
12
12
  exports.resolveClientEndpointParameters = resolveClientEndpointParameters;
13
+ exports.commonParams = {
14
+ UseFIPS: { type: "builtInParams", name: "useFipsEndpoint" },
15
+ Endpoint: { type: "builtInParams", name: "endpoint" },
16
+ Region: { type: "builtInParams", name: "region" },
17
+ UseDualStack: { type: "builtInParams", name: "useDualstackEndpoint" },
18
+ };
@@ -1,29 +1,7 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.paginateDescribeCanariesLastRun = void 0;
4
+ const core_1 = require("@smithy/core");
4
5
  const DescribeCanariesLastRunCommand_1 = require("../commands/DescribeCanariesLastRunCommand");
5
6
  const SyntheticsClient_1 = require("../SyntheticsClient");
6
- const makePagedClientRequest = async (client, input, ...args) => {
7
- return await client.send(new DescribeCanariesLastRunCommand_1.DescribeCanariesLastRunCommand(input), ...args);
8
- };
9
- async function* paginateDescribeCanariesLastRun(config, input, ...additionalArguments) {
10
- let token = config.startingToken || undefined;
11
- let hasNext = true;
12
- let page;
13
- while (hasNext) {
14
- input.NextToken = token;
15
- input["MaxResults"] = config.pageSize;
16
- if (config.client instanceof SyntheticsClient_1.SyntheticsClient) {
17
- page = await makePagedClientRequest(config.client, input, ...additionalArguments);
18
- }
19
- else {
20
- throw new Error("Invalid client, expected Synthetics | SyntheticsClient");
21
- }
22
- yield page;
23
- const prevToken = token;
24
- token = page.NextToken;
25
- hasNext = !!(token && (!config.stopOnSameToken || token !== prevToken));
26
- }
27
- return undefined;
28
- }
29
- exports.paginateDescribeCanariesLastRun = paginateDescribeCanariesLastRun;
7
+ exports.paginateDescribeCanariesLastRun = (0, core_1.createPaginator)(SyntheticsClient_1.SyntheticsClient, DescribeCanariesLastRunCommand_1.DescribeCanariesLastRunCommand, "NextToken", "NextToken", "MaxResults");
@@ -1,29 +1,7 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.paginateDescribeCanaries = void 0;
4
+ const core_1 = require("@smithy/core");
4
5
  const DescribeCanariesCommand_1 = require("../commands/DescribeCanariesCommand");
5
6
  const SyntheticsClient_1 = require("../SyntheticsClient");
6
- const makePagedClientRequest = async (client, input, ...args) => {
7
- return await client.send(new DescribeCanariesCommand_1.DescribeCanariesCommand(input), ...args);
8
- };
9
- async function* paginateDescribeCanaries(config, input, ...additionalArguments) {
10
- let token = config.startingToken || undefined;
11
- let hasNext = true;
12
- let page;
13
- while (hasNext) {
14
- input.NextToken = token;
15
- input["MaxResults"] = config.pageSize;
16
- if (config.client instanceof SyntheticsClient_1.SyntheticsClient) {
17
- page = await makePagedClientRequest(config.client, input, ...additionalArguments);
18
- }
19
- else {
20
- throw new Error("Invalid client, expected Synthetics | SyntheticsClient");
21
- }
22
- yield page;
23
- const prevToken = token;
24
- token = page.NextToken;
25
- hasNext = !!(token && (!config.stopOnSameToken || token !== prevToken));
26
- }
27
- return undefined;
28
- }
29
- exports.paginateDescribeCanaries = paginateDescribeCanaries;
7
+ exports.paginateDescribeCanaries = (0, core_1.createPaginator)(SyntheticsClient_1.SyntheticsClient, DescribeCanariesCommand_1.DescribeCanariesCommand, "NextToken", "NextToken", "MaxResults");
@@ -1,29 +1,7 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.paginateDescribeRuntimeVersions = void 0;
4
+ const core_1 = require("@smithy/core");
4
5
  const DescribeRuntimeVersionsCommand_1 = require("../commands/DescribeRuntimeVersionsCommand");
5
6
  const SyntheticsClient_1 = require("../SyntheticsClient");
6
- const makePagedClientRequest = async (client, input, ...args) => {
7
- return await client.send(new DescribeRuntimeVersionsCommand_1.DescribeRuntimeVersionsCommand(input), ...args);
8
- };
9
- async function* paginateDescribeRuntimeVersions(config, input, ...additionalArguments) {
10
- let token = config.startingToken || undefined;
11
- let hasNext = true;
12
- let page;
13
- while (hasNext) {
14
- input.NextToken = token;
15
- input["MaxResults"] = config.pageSize;
16
- if (config.client instanceof SyntheticsClient_1.SyntheticsClient) {
17
- page = await makePagedClientRequest(config.client, input, ...additionalArguments);
18
- }
19
- else {
20
- throw new Error("Invalid client, expected Synthetics | SyntheticsClient");
21
- }
22
- yield page;
23
- const prevToken = token;
24
- token = page.NextToken;
25
- hasNext = !!(token && (!config.stopOnSameToken || token !== prevToken));
26
- }
27
- return undefined;
28
- }
29
- exports.paginateDescribeRuntimeVersions = paginateDescribeRuntimeVersions;
7
+ exports.paginateDescribeRuntimeVersions = (0, core_1.createPaginator)(SyntheticsClient_1.SyntheticsClient, DescribeRuntimeVersionsCommand_1.DescribeRuntimeVersionsCommand, "NextToken", "NextToken", "MaxResults");
@@ -1,29 +1,7 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.paginateGetCanaryRuns = void 0;
4
+ const core_1 = require("@smithy/core");
4
5
  const GetCanaryRunsCommand_1 = require("../commands/GetCanaryRunsCommand");
5
6
  const SyntheticsClient_1 = require("../SyntheticsClient");
6
- const makePagedClientRequest = async (client, input, ...args) => {
7
- return await client.send(new GetCanaryRunsCommand_1.GetCanaryRunsCommand(input), ...args);
8
- };
9
- async function* paginateGetCanaryRuns(config, input, ...additionalArguments) {
10
- let token = config.startingToken || undefined;
11
- let hasNext = true;
12
- let page;
13
- while (hasNext) {
14
- input.NextToken = token;
15
- input["MaxResults"] = config.pageSize;
16
- if (config.client instanceof SyntheticsClient_1.SyntheticsClient) {
17
- page = await makePagedClientRequest(config.client, input, ...additionalArguments);
18
- }
19
- else {
20
- throw new Error("Invalid client, expected Synthetics | SyntheticsClient");
21
- }
22
- yield page;
23
- const prevToken = token;
24
- token = page.NextToken;
25
- hasNext = !!(token && (!config.stopOnSameToken || token !== prevToken));
26
- }
27
- return undefined;
28
- }
29
- exports.paginateGetCanaryRuns = paginateGetCanaryRuns;
7
+ exports.paginateGetCanaryRuns = (0, core_1.createPaginator)(SyntheticsClient_1.SyntheticsClient, GetCanaryRunsCommand_1.GetCanaryRunsCommand, "NextToken", "NextToken", "MaxResults");
@@ -1,29 +1,7 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.paginateListAssociatedGroups = void 0;
4
+ const core_1 = require("@smithy/core");
4
5
  const ListAssociatedGroupsCommand_1 = require("../commands/ListAssociatedGroupsCommand");
5
6
  const SyntheticsClient_1 = require("../SyntheticsClient");
6
- const makePagedClientRequest = async (client, input, ...args) => {
7
- return await client.send(new ListAssociatedGroupsCommand_1.ListAssociatedGroupsCommand(input), ...args);
8
- };
9
- async function* paginateListAssociatedGroups(config, input, ...additionalArguments) {
10
- let token = config.startingToken || undefined;
11
- let hasNext = true;
12
- let page;
13
- while (hasNext) {
14
- input.NextToken = token;
15
- input["MaxResults"] = config.pageSize;
16
- if (config.client instanceof SyntheticsClient_1.SyntheticsClient) {
17
- page = await makePagedClientRequest(config.client, input, ...additionalArguments);
18
- }
19
- else {
20
- throw new Error("Invalid client, expected Synthetics | SyntheticsClient");
21
- }
22
- yield page;
23
- const prevToken = token;
24
- token = page.NextToken;
25
- hasNext = !!(token && (!config.stopOnSameToken || token !== prevToken));
26
- }
27
- return undefined;
28
- }
29
- exports.paginateListAssociatedGroups = paginateListAssociatedGroups;
7
+ exports.paginateListAssociatedGroups = (0, core_1.createPaginator)(SyntheticsClient_1.SyntheticsClient, ListAssociatedGroupsCommand_1.ListAssociatedGroupsCommand, "NextToken", "NextToken", "MaxResults");
@@ -1,29 +1,7 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.paginateListGroupResources = void 0;
4
+ const core_1 = require("@smithy/core");
4
5
  const ListGroupResourcesCommand_1 = require("../commands/ListGroupResourcesCommand");
5
6
  const SyntheticsClient_1 = require("../SyntheticsClient");
6
- const makePagedClientRequest = async (client, input, ...args) => {
7
- return await client.send(new ListGroupResourcesCommand_1.ListGroupResourcesCommand(input), ...args);
8
- };
9
- async function* paginateListGroupResources(config, input, ...additionalArguments) {
10
- let token = config.startingToken || undefined;
11
- let hasNext = true;
12
- let page;
13
- while (hasNext) {
14
- input.NextToken = token;
15
- input["MaxResults"] = config.pageSize;
16
- if (config.client instanceof SyntheticsClient_1.SyntheticsClient) {
17
- page = await makePagedClientRequest(config.client, input, ...additionalArguments);
18
- }
19
- else {
20
- throw new Error("Invalid client, expected Synthetics | SyntheticsClient");
21
- }
22
- yield page;
23
- const prevToken = token;
24
- token = page.NextToken;
25
- hasNext = !!(token && (!config.stopOnSameToken || token !== prevToken));
26
- }
27
- return undefined;
28
- }
29
- exports.paginateListGroupResources = paginateListGroupResources;
7
+ exports.paginateListGroupResources = (0, core_1.createPaginator)(SyntheticsClient_1.SyntheticsClient, ListGroupResourcesCommand_1.ListGroupResourcesCommand, "NextToken", "NextToken", "MaxResults");
@@ -1,29 +1,7 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.paginateListGroups = void 0;
4
+ const core_1 = require("@smithy/core");
4
5
  const ListGroupsCommand_1 = require("../commands/ListGroupsCommand");
5
6
  const SyntheticsClient_1 = require("../SyntheticsClient");
6
- const makePagedClientRequest = async (client, input, ...args) => {
7
- return await client.send(new ListGroupsCommand_1.ListGroupsCommand(input), ...args);
8
- };
9
- async function* paginateListGroups(config, input, ...additionalArguments) {
10
- let token = config.startingToken || undefined;
11
- let hasNext = true;
12
- let page;
13
- while (hasNext) {
14
- input.NextToken = token;
15
- input["MaxResults"] = config.pageSize;
16
- if (config.client instanceof SyntheticsClient_1.SyntheticsClient) {
17
- page = await makePagedClientRequest(config.client, input, ...additionalArguments);
18
- }
19
- else {
20
- throw new Error("Invalid client, expected Synthetics | SyntheticsClient");
21
- }
22
- yield page;
23
- const prevToken = token;
24
- token = page.NextToken;
25
- hasNext = !!(token && (!config.stopOnSameToken || token !== prevToken));
26
- }
27
- return undefined;
28
- }
29
- exports.paginateListGroups = paginateListGroups;
7
+ exports.paginateListGroups = (0, core_1.createPaginator)(SyntheticsClient_1.SyntheticsClient, ListGroupsCommand_1.ListGroupsCommand, "NextToken", "NextToken", "MaxResults");
@@ -1,47 +1,24 @@
1
1
  import { getEndpointPlugin } from "@smithy/middleware-endpoint";
2
2
  import { getSerdePlugin } from "@smithy/middleware-serde";
3
3
  import { Command as $Command } from "@smithy/smithy-client";
4
- import { SMITHY_CONTEXT_KEY, } from "@smithy/types";
4
+ import { commonParams } from "../endpoint/EndpointParameters";
5
5
  import { de_AssociateResourceCommand, se_AssociateResourceCommand } from "../protocols/Aws_restJson1";
6
6
  export { $Command };
7
- export class AssociateResourceCommand extends $Command {
8
- static getEndpointParameterInstructions() {
9
- return {
10
- UseFIPS: { type: "builtInParams", name: "useFipsEndpoint" },
11
- Endpoint: { type: "builtInParams", name: "endpoint" },
12
- Region: { type: "builtInParams", name: "region" },
13
- UseDualStack: { type: "builtInParams", name: "useDualstackEndpoint" },
14
- };
15
- }
16
- constructor(input) {
17
- super();
18
- this.input = input;
19
- }
20
- resolveMiddleware(clientStack, configuration, options) {
21
- this.middlewareStack.use(getSerdePlugin(configuration, this.serialize, this.deserialize));
22
- this.middlewareStack.use(getEndpointPlugin(configuration, AssociateResourceCommand.getEndpointParameterInstructions()));
23
- const stack = clientStack.concat(this.middlewareStack);
24
- const { logger } = configuration;
25
- const clientName = "SyntheticsClient";
26
- const commandName = "AssociateResourceCommand";
27
- const handlerExecutionContext = {
28
- logger,
29
- clientName,
30
- commandName,
31
- inputFilterSensitiveLog: (_) => _,
32
- outputFilterSensitiveLog: (_) => _,
33
- [SMITHY_CONTEXT_KEY]: {
34
- service: "Synthetics",
35
- operation: "AssociateResource",
36
- },
37
- };
38
- const { requestHandler } = configuration;
39
- return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext);
40
- }
41
- serialize(input, context) {
42
- return se_AssociateResourceCommand(input, context);
43
- }
44
- deserialize(output, context) {
45
- return de_AssociateResourceCommand(output, context);
46
- }
7
+ export class AssociateResourceCommand extends $Command
8
+ .classBuilder()
9
+ .ep({
10
+ ...commonParams,
11
+ })
12
+ .m(function (Command, cs, config, o) {
13
+ return [
14
+ getSerdePlugin(config, this.serialize, this.deserialize),
15
+ getEndpointPlugin(config, Command.getEndpointParameterInstructions()),
16
+ ];
17
+ })
18
+ .s("Synthetics", "AssociateResource", {})
19
+ .n("SyntheticsClient", "AssociateResourceCommand")
20
+ .f(void 0, void 0)
21
+ .ser(se_AssociateResourceCommand)
22
+ .de(de_AssociateResourceCommand)
23
+ .build() {
47
24
  }
@@ -1,47 +1,24 @@
1
1
  import { getEndpointPlugin } from "@smithy/middleware-endpoint";
2
2
  import { getSerdePlugin } from "@smithy/middleware-serde";
3
3
  import { Command as $Command } from "@smithy/smithy-client";
4
- import { SMITHY_CONTEXT_KEY, } from "@smithy/types";
4
+ import { commonParams } from "../endpoint/EndpointParameters";
5
5
  import { de_CreateCanaryCommand, se_CreateCanaryCommand } from "../protocols/Aws_restJson1";
6
6
  export { $Command };
7
- export class CreateCanaryCommand extends $Command {
8
- static getEndpointParameterInstructions() {
9
- return {
10
- UseFIPS: { type: "builtInParams", name: "useFipsEndpoint" },
11
- Endpoint: { type: "builtInParams", name: "endpoint" },
12
- Region: { type: "builtInParams", name: "region" },
13
- UseDualStack: { type: "builtInParams", name: "useDualstackEndpoint" },
14
- };
15
- }
16
- constructor(input) {
17
- super();
18
- this.input = input;
19
- }
20
- resolveMiddleware(clientStack, configuration, options) {
21
- this.middlewareStack.use(getSerdePlugin(configuration, this.serialize, this.deserialize));
22
- this.middlewareStack.use(getEndpointPlugin(configuration, CreateCanaryCommand.getEndpointParameterInstructions()));
23
- const stack = clientStack.concat(this.middlewareStack);
24
- const { logger } = configuration;
25
- const clientName = "SyntheticsClient";
26
- const commandName = "CreateCanaryCommand";
27
- const handlerExecutionContext = {
28
- logger,
29
- clientName,
30
- commandName,
31
- inputFilterSensitiveLog: (_) => _,
32
- outputFilterSensitiveLog: (_) => _,
33
- [SMITHY_CONTEXT_KEY]: {
34
- service: "Synthetics",
35
- operation: "CreateCanary",
36
- },
37
- };
38
- const { requestHandler } = configuration;
39
- return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext);
40
- }
41
- serialize(input, context) {
42
- return se_CreateCanaryCommand(input, context);
43
- }
44
- deserialize(output, context) {
45
- return de_CreateCanaryCommand(output, context);
46
- }
7
+ export class CreateCanaryCommand extends $Command
8
+ .classBuilder()
9
+ .ep({
10
+ ...commonParams,
11
+ })
12
+ .m(function (Command, cs, config, o) {
13
+ return [
14
+ getSerdePlugin(config, this.serialize, this.deserialize),
15
+ getEndpointPlugin(config, Command.getEndpointParameterInstructions()),
16
+ ];
17
+ })
18
+ .s("Synthetics", "CreateCanary", {})
19
+ .n("SyntheticsClient", "CreateCanaryCommand")
20
+ .f(void 0, void 0)
21
+ .ser(se_CreateCanaryCommand)
22
+ .de(de_CreateCanaryCommand)
23
+ .build() {
47
24
  }