@aws-sdk/client-cloudwatch-logs 3.445.0 → 3.449.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 (97) hide show
  1. package/README.md +120 -0
  2. package/dist-cjs/CloudWatchLogs.js +30 -0
  3. package/dist-cjs/commands/CreateDeliveryCommand.js +51 -0
  4. package/dist-cjs/commands/DeleteDeliveryCommand.js +51 -0
  5. package/dist-cjs/commands/DeleteDeliveryDestinationCommand.js +51 -0
  6. package/dist-cjs/commands/DeleteDeliveryDestinationPolicyCommand.js +51 -0
  7. package/dist-cjs/commands/DeleteDeliverySourceCommand.js +51 -0
  8. package/dist-cjs/commands/DescribeDeliveriesCommand.js +51 -0
  9. package/dist-cjs/commands/DescribeDeliveryDestinationsCommand.js +51 -0
  10. package/dist-cjs/commands/DescribeDeliverySourcesCommand.js +51 -0
  11. package/dist-cjs/commands/GetDeliveryCommand.js +51 -0
  12. package/dist-cjs/commands/GetDeliveryDestinationCommand.js +51 -0
  13. package/dist-cjs/commands/GetDeliveryDestinationPolicyCommand.js +51 -0
  14. package/dist-cjs/commands/GetDeliverySourceCommand.js +51 -0
  15. package/dist-cjs/commands/PutDeliveryDestinationCommand.js +51 -0
  16. package/dist-cjs/commands/PutDeliveryDestinationPolicyCommand.js +51 -0
  17. package/dist-cjs/commands/PutDeliverySourceCommand.js +51 -0
  18. package/dist-cjs/commands/index.js +15 -0
  19. package/dist-cjs/models/models_0.js +78 -1
  20. package/dist-cjs/pagination/DescribeDeliveriesPaginator.js +29 -0
  21. package/dist-cjs/pagination/DescribeDeliveryDestinationsPaginator.js +29 -0
  22. package/dist-cjs/pagination/DescribeDeliverySourcesPaginator.js +29 -0
  23. package/dist-cjs/pagination/index.js +3 -0
  24. package/dist-cjs/protocols/Aws_json1_1.js +887 -74
  25. package/dist-es/CloudWatchLogs.js +30 -0
  26. package/dist-es/commands/CreateDeliveryCommand.js +47 -0
  27. package/dist-es/commands/DeleteDeliveryCommand.js +47 -0
  28. package/dist-es/commands/DeleteDeliveryDestinationCommand.js +47 -0
  29. package/dist-es/commands/DeleteDeliveryDestinationPolicyCommand.js +47 -0
  30. package/dist-es/commands/DeleteDeliverySourceCommand.js +47 -0
  31. package/dist-es/commands/DescribeDeliveriesCommand.js +47 -0
  32. package/dist-es/commands/DescribeDeliveryDestinationsCommand.js +47 -0
  33. package/dist-es/commands/DescribeDeliverySourcesCommand.js +47 -0
  34. package/dist-es/commands/GetDeliveryCommand.js +47 -0
  35. package/dist-es/commands/GetDeliveryDestinationCommand.js +47 -0
  36. package/dist-es/commands/GetDeliveryDestinationPolicyCommand.js +47 -0
  37. package/dist-es/commands/GetDeliverySourceCommand.js +47 -0
  38. package/dist-es/commands/PutDeliveryDestinationCommand.js +47 -0
  39. package/dist-es/commands/PutDeliveryDestinationPolicyCommand.js +47 -0
  40. package/dist-es/commands/PutDeliverySourceCommand.js +47 -0
  41. package/dist-es/commands/index.js +15 -0
  42. package/dist-es/models/models_0.js +72 -0
  43. package/dist-es/pagination/DescribeDeliveriesPaginator.js +25 -0
  44. package/dist-es/pagination/DescribeDeliveryDestinationsPaginator.js +25 -0
  45. package/dist-es/pagination/DescribeDeliverySourcesPaginator.js +25 -0
  46. package/dist-es/pagination/index.js +3 -0
  47. package/dist-es/protocols/Aws_json1_1.js +854 -71
  48. package/dist-types/CloudWatchLogs.d.ts +105 -0
  49. package/dist-types/CloudWatchLogsClient.d.ts +17 -2
  50. package/dist-types/commands/CreateDeliveryCommand.d.ts +142 -0
  51. package/dist-types/commands/DeleteDeliveryCommand.d.ts +91 -0
  52. package/dist-types/commands/DeleteDeliveryDestinationCommand.d.ts +92 -0
  53. package/dist-types/commands/DeleteDeliveryDestinationPolicyCommand.d.ts +84 -0
  54. package/dist-types/commands/DeleteDeliverySourceCommand.d.ts +92 -0
  55. package/dist-types/commands/DescribeDeliveriesCommand.d.ts +98 -0
  56. package/dist-types/commands/DescribeDeliveryDestinationsCommand.d.ts +100 -0
  57. package/dist-types/commands/DescribeDeliverySourcesCommand.d.ts +100 -0
  58. package/dist-types/commands/GetDeliveryCommand.d.ts +101 -0
  59. package/dist-types/commands/GetDeliveryDestinationCommand.d.ts +99 -0
  60. package/dist-types/commands/GetDeliveryDestinationPolicyCommand.d.ts +86 -0
  61. package/dist-types/commands/GetDeliverySourceCommand.d.ts +99 -0
  62. package/dist-types/commands/GetQueryResultsCommand.d.ts +2 -1
  63. package/dist-types/commands/PutDeliveryDestinationCommand.d.ts +145 -0
  64. package/dist-types/commands/PutDeliveryDestinationPolicyCommand.d.ts +118 -0
  65. package/dist-types/commands/PutDeliverySourceCommand.d.ts +142 -0
  66. package/dist-types/commands/index.d.ts +15 -0
  67. package/dist-types/models/models_0.d.ts +635 -0
  68. package/dist-types/pagination/DescribeDeliveriesPaginator.d.ts +7 -0
  69. package/dist-types/pagination/DescribeDeliveryDestinationsPaginator.d.ts +7 -0
  70. package/dist-types/pagination/DescribeDeliverySourcesPaginator.d.ts +7 -0
  71. package/dist-types/pagination/index.d.ts +3 -0
  72. package/dist-types/protocols/Aws_json1_1.d.ts +135 -0
  73. package/dist-types/ts3.4/CloudWatchLogs.d.ts +255 -0
  74. package/dist-types/ts3.4/CloudWatchLogsClient.d.ts +90 -0
  75. package/dist-types/ts3.4/commands/CreateDeliveryCommand.d.ts +38 -0
  76. package/dist-types/ts3.4/commands/DeleteDeliveryCommand.d.ts +33 -0
  77. package/dist-types/ts3.4/commands/DeleteDeliveryDestinationCommand.d.ts +38 -0
  78. package/dist-types/ts3.4/commands/DeleteDeliveryDestinationPolicyCommand.d.ts +38 -0
  79. package/dist-types/ts3.4/commands/DeleteDeliverySourceCommand.d.ts +37 -0
  80. package/dist-types/ts3.4/commands/DescribeDeliveriesCommand.d.ts +39 -0
  81. package/dist-types/ts3.4/commands/DescribeDeliveryDestinationsCommand.d.ts +42 -0
  82. package/dist-types/ts3.4/commands/DescribeDeliverySourcesCommand.d.ts +42 -0
  83. package/dist-types/ts3.4/commands/GetDeliveryCommand.d.ts +35 -0
  84. package/dist-types/ts3.4/commands/GetDeliveryDestinationCommand.d.ts +42 -0
  85. package/dist-types/ts3.4/commands/GetDeliveryDestinationPolicyCommand.d.ts +42 -0
  86. package/dist-types/ts3.4/commands/GetDeliverySourceCommand.d.ts +39 -0
  87. package/dist-types/ts3.4/commands/PutDeliveryDestinationCommand.d.ts +42 -0
  88. package/dist-types/ts3.4/commands/PutDeliveryDestinationPolicyCommand.d.ts +42 -0
  89. package/dist-types/ts3.4/commands/PutDeliverySourceCommand.d.ts +39 -0
  90. package/dist-types/ts3.4/commands/index.d.ts +15 -0
  91. package/dist-types/ts3.4/models/models_0.d.ts +173 -0
  92. package/dist-types/ts3.4/pagination/DescribeDeliveriesPaginator.d.ts +11 -0
  93. package/dist-types/ts3.4/pagination/DescribeDeliveryDestinationsPaginator.d.ts +11 -0
  94. package/dist-types/ts3.4/pagination/DescribeDeliverySourcesPaginator.d.ts +11 -0
  95. package/dist-types/ts3.4/pagination/index.d.ts +3 -0
  96. package/dist-types/ts3.4/protocols/Aws_json1_1.d.ts +180 -0
  97. package/package.json +12 -12
@@ -0,0 +1,47 @@
1
+ import { getEndpointPlugin } from "@smithy/middleware-endpoint";
2
+ import { getSerdePlugin } from "@smithy/middleware-serde";
3
+ import { Command as $Command } from "@smithy/smithy-client";
4
+ import { SMITHY_CONTEXT_KEY, } from "@smithy/types";
5
+ import { de_GetDeliverySourceCommand, se_GetDeliverySourceCommand } from "../protocols/Aws_json1_1";
6
+ export { $Command };
7
+ export class GetDeliverySourceCommand 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, GetDeliverySourceCommand.getEndpointParameterInstructions()));
23
+ const stack = clientStack.concat(this.middlewareStack);
24
+ const { logger } = configuration;
25
+ const clientName = "CloudWatchLogsClient";
26
+ const commandName = "GetDeliverySourceCommand";
27
+ const handlerExecutionContext = {
28
+ logger,
29
+ clientName,
30
+ commandName,
31
+ inputFilterSensitiveLog: (_) => _,
32
+ outputFilterSensitiveLog: (_) => _,
33
+ [SMITHY_CONTEXT_KEY]: {
34
+ service: "Logs_20140328",
35
+ operation: "GetDeliverySource",
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_GetDeliverySourceCommand(input, context);
43
+ }
44
+ deserialize(output, context) {
45
+ return de_GetDeliverySourceCommand(output, context);
46
+ }
47
+ }
@@ -0,0 +1,47 @@
1
+ import { getEndpointPlugin } from "@smithy/middleware-endpoint";
2
+ import { getSerdePlugin } from "@smithy/middleware-serde";
3
+ import { Command as $Command } from "@smithy/smithy-client";
4
+ import { SMITHY_CONTEXT_KEY, } from "@smithy/types";
5
+ import { de_PutDeliveryDestinationCommand, se_PutDeliveryDestinationCommand } from "../protocols/Aws_json1_1";
6
+ export { $Command };
7
+ export class PutDeliveryDestinationCommand 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, PutDeliveryDestinationCommand.getEndpointParameterInstructions()));
23
+ const stack = clientStack.concat(this.middlewareStack);
24
+ const { logger } = configuration;
25
+ const clientName = "CloudWatchLogsClient";
26
+ const commandName = "PutDeliveryDestinationCommand";
27
+ const handlerExecutionContext = {
28
+ logger,
29
+ clientName,
30
+ commandName,
31
+ inputFilterSensitiveLog: (_) => _,
32
+ outputFilterSensitiveLog: (_) => _,
33
+ [SMITHY_CONTEXT_KEY]: {
34
+ service: "Logs_20140328",
35
+ operation: "PutDeliveryDestination",
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_PutDeliveryDestinationCommand(input, context);
43
+ }
44
+ deserialize(output, context) {
45
+ return de_PutDeliveryDestinationCommand(output, context);
46
+ }
47
+ }
@@ -0,0 +1,47 @@
1
+ import { getEndpointPlugin } from "@smithy/middleware-endpoint";
2
+ import { getSerdePlugin } from "@smithy/middleware-serde";
3
+ import { Command as $Command } from "@smithy/smithy-client";
4
+ import { SMITHY_CONTEXT_KEY, } from "@smithy/types";
5
+ import { de_PutDeliveryDestinationPolicyCommand, se_PutDeliveryDestinationPolicyCommand, } from "../protocols/Aws_json1_1";
6
+ export { $Command };
7
+ export class PutDeliveryDestinationPolicyCommand 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, PutDeliveryDestinationPolicyCommand.getEndpointParameterInstructions()));
23
+ const stack = clientStack.concat(this.middlewareStack);
24
+ const { logger } = configuration;
25
+ const clientName = "CloudWatchLogsClient";
26
+ const commandName = "PutDeliveryDestinationPolicyCommand";
27
+ const handlerExecutionContext = {
28
+ logger,
29
+ clientName,
30
+ commandName,
31
+ inputFilterSensitiveLog: (_) => _,
32
+ outputFilterSensitiveLog: (_) => _,
33
+ [SMITHY_CONTEXT_KEY]: {
34
+ service: "Logs_20140328",
35
+ operation: "PutDeliveryDestinationPolicy",
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_PutDeliveryDestinationPolicyCommand(input, context);
43
+ }
44
+ deserialize(output, context) {
45
+ return de_PutDeliveryDestinationPolicyCommand(output, context);
46
+ }
47
+ }
@@ -0,0 +1,47 @@
1
+ import { getEndpointPlugin } from "@smithy/middleware-endpoint";
2
+ import { getSerdePlugin } from "@smithy/middleware-serde";
3
+ import { Command as $Command } from "@smithy/smithy-client";
4
+ import { SMITHY_CONTEXT_KEY, } from "@smithy/types";
5
+ import { de_PutDeliverySourceCommand, se_PutDeliverySourceCommand } from "../protocols/Aws_json1_1";
6
+ export { $Command };
7
+ export class PutDeliverySourceCommand 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, PutDeliverySourceCommand.getEndpointParameterInstructions()));
23
+ const stack = clientStack.concat(this.middlewareStack);
24
+ const { logger } = configuration;
25
+ const clientName = "CloudWatchLogsClient";
26
+ const commandName = "PutDeliverySourceCommand";
27
+ const handlerExecutionContext = {
28
+ logger,
29
+ clientName,
30
+ commandName,
31
+ inputFilterSensitiveLog: (_) => _,
32
+ outputFilterSensitiveLog: (_) => _,
33
+ [SMITHY_CONTEXT_KEY]: {
34
+ service: "Logs_20140328",
35
+ operation: "PutDeliverySource",
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_PutDeliverySourceCommand(input, context);
43
+ }
44
+ deserialize(output, context) {
45
+ return de_PutDeliverySourceCommand(output, context);
46
+ }
47
+ }
@@ -1,10 +1,15 @@
1
1
  export * from "./AssociateKmsKeyCommand";
2
2
  export * from "./CancelExportTaskCommand";
3
+ export * from "./CreateDeliveryCommand";
3
4
  export * from "./CreateExportTaskCommand";
4
5
  export * from "./CreateLogGroupCommand";
5
6
  export * from "./CreateLogStreamCommand";
6
7
  export * from "./DeleteAccountPolicyCommand";
7
8
  export * from "./DeleteDataProtectionPolicyCommand";
9
+ export * from "./DeleteDeliveryCommand";
10
+ export * from "./DeleteDeliveryDestinationCommand";
11
+ export * from "./DeleteDeliveryDestinationPolicyCommand";
12
+ export * from "./DeleteDeliverySourceCommand";
8
13
  export * from "./DeleteDestinationCommand";
9
14
  export * from "./DeleteLogGroupCommand";
10
15
  export * from "./DeleteLogStreamCommand";
@@ -14,6 +19,9 @@ export * from "./DeleteResourcePolicyCommand";
14
19
  export * from "./DeleteRetentionPolicyCommand";
15
20
  export * from "./DeleteSubscriptionFilterCommand";
16
21
  export * from "./DescribeAccountPoliciesCommand";
22
+ export * from "./DescribeDeliveriesCommand";
23
+ export * from "./DescribeDeliveryDestinationsCommand";
24
+ export * from "./DescribeDeliverySourcesCommand";
17
25
  export * from "./DescribeDestinationsCommand";
18
26
  export * from "./DescribeExportTasksCommand";
19
27
  export * from "./DescribeLogGroupsCommand";
@@ -26,6 +34,10 @@ export * from "./DescribeSubscriptionFiltersCommand";
26
34
  export * from "./DisassociateKmsKeyCommand";
27
35
  export * from "./FilterLogEventsCommand";
28
36
  export * from "./GetDataProtectionPolicyCommand";
37
+ export * from "./GetDeliveryCommand";
38
+ export * from "./GetDeliveryDestinationCommand";
39
+ export * from "./GetDeliveryDestinationPolicyCommand";
40
+ export * from "./GetDeliverySourceCommand";
29
41
  export * from "./GetLogEventsCommand";
30
42
  export * from "./GetLogGroupFieldsCommand";
31
43
  export * from "./GetLogRecordCommand";
@@ -34,6 +46,9 @@ export * from "./ListTagsForResourceCommand";
34
46
  export * from "./ListTagsLogGroupCommand";
35
47
  export * from "./PutAccountPolicyCommand";
36
48
  export * from "./PutDataProtectionPolicyCommand";
49
+ export * from "./PutDeliveryDestinationCommand";
50
+ export * from "./PutDeliveryDestinationPolicyCommand";
51
+ export * from "./PutDeliverySourceCommand";
37
52
  export * from "./PutDestinationCommand";
38
53
  export * from "./PutDestinationPolicyCommand";
39
54
  export * from "./PutLogEventsCommand";
@@ -1,4 +1,16 @@
1
1
  import { CloudWatchLogsServiceException as __BaseException } from "./CloudWatchLogsServiceException";
2
+ export class AccessDeniedException extends __BaseException {
3
+ constructor(opts) {
4
+ super({
5
+ name: "AccessDeniedException",
6
+ $fault: "client",
7
+ ...opts,
8
+ });
9
+ this.name = "AccessDeniedException";
10
+ this.$fault = "client";
11
+ Object.setPrototypeOf(this, AccessDeniedException.prototype);
12
+ }
13
+ }
2
14
  export const PolicyType = {
3
15
  DATA_PROTECTION_POLICY: "DATA_PROTECTION_POLICY",
4
16
  };
@@ -65,6 +77,59 @@ export class InvalidOperationException extends __BaseException {
65
77
  Object.setPrototypeOf(this, InvalidOperationException.prototype);
66
78
  }
67
79
  }
80
+ export class ConflictException extends __BaseException {
81
+ constructor(opts) {
82
+ super({
83
+ name: "ConflictException",
84
+ $fault: "client",
85
+ ...opts,
86
+ });
87
+ this.name = "ConflictException";
88
+ this.$fault = "client";
89
+ Object.setPrototypeOf(this, ConflictException.prototype);
90
+ }
91
+ }
92
+ export const DeliveryDestinationType = {
93
+ CWL: "CWL",
94
+ FH: "FH",
95
+ S3: "S3",
96
+ };
97
+ export class ServiceQuotaExceededException extends __BaseException {
98
+ constructor(opts) {
99
+ super({
100
+ name: "ServiceQuotaExceededException",
101
+ $fault: "client",
102
+ ...opts,
103
+ });
104
+ this.name = "ServiceQuotaExceededException";
105
+ this.$fault = "client";
106
+ Object.setPrototypeOf(this, ServiceQuotaExceededException.prototype);
107
+ }
108
+ }
109
+ export class ThrottlingException extends __BaseException {
110
+ constructor(opts) {
111
+ super({
112
+ name: "ThrottlingException",
113
+ $fault: "client",
114
+ ...opts,
115
+ });
116
+ this.name = "ThrottlingException";
117
+ this.$fault = "client";
118
+ Object.setPrototypeOf(this, ThrottlingException.prototype);
119
+ }
120
+ }
121
+ export class ValidationException extends __BaseException {
122
+ constructor(opts) {
123
+ super({
124
+ name: "ValidationException",
125
+ $fault: "client",
126
+ ...opts,
127
+ });
128
+ this.name = "ValidationException";
129
+ this.$fault = "client";
130
+ Object.setPrototypeOf(this, ValidationException.prototype);
131
+ }
132
+ }
68
133
  export class LimitExceededException extends __BaseException {
69
134
  constructor(opts) {
70
135
  super({
@@ -108,6 +173,13 @@ export const DataProtectionStatus = {
108
173
  DELETED: "DELETED",
109
174
  DISABLED: "DISABLED",
110
175
  };
176
+ export const OutputFormat = {
177
+ JSON: "json",
178
+ PARQUET: "parquet",
179
+ PLAIN: "plain",
180
+ RAW: "raw",
181
+ W3C: "w3c",
182
+ };
111
183
  export const ExportTaskStatusCode = {
112
184
  CANCELLED: "CANCELLED",
113
185
  COMPLETED: "COMPLETED",
@@ -0,0 +1,25 @@
1
+ import { CloudWatchLogsClient } from "../CloudWatchLogsClient";
2
+ import { DescribeDeliveriesCommand, } from "../commands/DescribeDeliveriesCommand";
3
+ const makePagedClientRequest = async (client, input, ...args) => {
4
+ return await client.send(new DescribeDeliveriesCommand(input), ...args);
5
+ };
6
+ export async function* paginateDescribeDeliveries(config, input, ...additionalArguments) {
7
+ let token = config.startingToken || undefined;
8
+ let hasNext = true;
9
+ let page;
10
+ while (hasNext) {
11
+ input.nextToken = token;
12
+ input["limit"] = config.pageSize;
13
+ if (config.client instanceof CloudWatchLogsClient) {
14
+ page = await makePagedClientRequest(config.client, input, ...additionalArguments);
15
+ }
16
+ else {
17
+ throw new Error("Invalid client, expected CloudWatchLogs | CloudWatchLogsClient");
18
+ }
19
+ yield page;
20
+ const prevToken = token;
21
+ token = page.nextToken;
22
+ hasNext = !!(token && (!config.stopOnSameToken || token !== prevToken));
23
+ }
24
+ return undefined;
25
+ }
@@ -0,0 +1,25 @@
1
+ import { CloudWatchLogsClient } from "../CloudWatchLogsClient";
2
+ import { DescribeDeliveryDestinationsCommand, } from "../commands/DescribeDeliveryDestinationsCommand";
3
+ const makePagedClientRequest = async (client, input, ...args) => {
4
+ return await client.send(new DescribeDeliveryDestinationsCommand(input), ...args);
5
+ };
6
+ export async function* paginateDescribeDeliveryDestinations(config, input, ...additionalArguments) {
7
+ let token = config.startingToken || undefined;
8
+ let hasNext = true;
9
+ let page;
10
+ while (hasNext) {
11
+ input.nextToken = token;
12
+ input["limit"] = config.pageSize;
13
+ if (config.client instanceof CloudWatchLogsClient) {
14
+ page = await makePagedClientRequest(config.client, input, ...additionalArguments);
15
+ }
16
+ else {
17
+ throw new Error("Invalid client, expected CloudWatchLogs | CloudWatchLogsClient");
18
+ }
19
+ yield page;
20
+ const prevToken = token;
21
+ token = page.nextToken;
22
+ hasNext = !!(token && (!config.stopOnSameToken || token !== prevToken));
23
+ }
24
+ return undefined;
25
+ }
@@ -0,0 +1,25 @@
1
+ import { CloudWatchLogsClient } from "../CloudWatchLogsClient";
2
+ import { DescribeDeliverySourcesCommand, } from "../commands/DescribeDeliverySourcesCommand";
3
+ const makePagedClientRequest = async (client, input, ...args) => {
4
+ return await client.send(new DescribeDeliverySourcesCommand(input), ...args);
5
+ };
6
+ export async function* paginateDescribeDeliverySources(config, input, ...additionalArguments) {
7
+ let token = config.startingToken || undefined;
8
+ let hasNext = true;
9
+ let page;
10
+ while (hasNext) {
11
+ input.nextToken = token;
12
+ input["limit"] = config.pageSize;
13
+ if (config.client instanceof CloudWatchLogsClient) {
14
+ page = await makePagedClientRequest(config.client, input, ...additionalArguments);
15
+ }
16
+ else {
17
+ throw new Error("Invalid client, expected CloudWatchLogs | CloudWatchLogsClient");
18
+ }
19
+ yield page;
20
+ const prevToken = token;
21
+ token = page.nextToken;
22
+ hasNext = !!(token && (!config.stopOnSameToken || token !== prevToken));
23
+ }
24
+ return undefined;
25
+ }
@@ -1,3 +1,6 @@
1
+ export * from "./DescribeDeliveriesPaginator";
2
+ export * from "./DescribeDeliveryDestinationsPaginator";
3
+ export * from "./DescribeDeliverySourcesPaginator";
1
4
  export * from "./DescribeDestinationsPaginator";
2
5
  export * from "./DescribeLogGroupsPaginator";
3
6
  export * from "./DescribeLogStreamsPaginator";