@aws-sdk/client-cloudwatch 3.42.0 → 3.47.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.
- package/CHANGELOG.md +51 -0
- package/dist-cjs/endpoints.js +1 -24
- package/dist-cjs/models/models_0.js +37 -99
- package/dist-cjs/protocols/Aws_query.js +146 -0
- package/dist-cjs/runtimeConfig.browser.js +7 -2
- package/dist-cjs/runtimeConfig.js +9 -3
- package/dist-es/endpoints.js +1 -24
- package/dist-es/models/models_0.js +25 -64
- package/dist-es/protocols/Aws_query.js +322 -158
- package/dist-es/runtimeConfig.browser.js +12 -3
- package/dist-es/runtimeConfig.js +13 -6
- package/dist-types/CloudWatch.d.ts +19 -5
- package/dist-types/CloudWatchClient.d.ts +5 -1
- package/dist-types/commands/DescribeAlarmHistoryCommand.d.ts +3 -0
- package/dist-types/commands/DescribeAlarmsCommand.d.ts +3 -0
- package/dist-types/commands/DescribeAnomalyDetectorsCommand.d.ts +7 -3
- package/dist-types/commands/PutCompositeAlarmCommand.d.ts +4 -0
- package/dist-types/commands/PutMetricAlarmCommand.d.ts +1 -1
- package/dist-types/commands/PutMetricStreamCommand.d.ts +1 -1
- package/dist-types/models/models_0.d.ts +423 -258
- package/dist-types/runtimeConfig.browser.d.ts +3 -2
- package/dist-types/runtimeConfig.d.ts +4 -3
- package/dist-types/runtimeConfig.native.d.ts +1 -0
- package/dist-types/ts3.4/CloudWatchClient.d.ts +3 -1
- package/dist-types/ts3.4/models/models_0.d.ts +103 -113
- package/dist-types/ts3.4/runtimeConfig.browser.d.ts +3 -2
- package/dist-types/ts3.4/runtimeConfig.d.ts +4 -3
- package/dist-types/ts3.4/runtimeConfig.native.d.ts +1 -0
- package/package.json +39 -46
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import { __assign } from "tslib";
|
|
1
|
+
import { __assign, __awaiter, __generator } from "tslib";
|
|
2
2
|
import packageInfo from "../package.json";
|
|
3
3
|
import { Sha256 } from "@aws-crypto/sha256-browser";
|
|
4
4
|
import { DEFAULT_USE_DUALSTACK_ENDPOINT, DEFAULT_USE_FIPS_ENDPOINT } from "@aws-sdk/config-resolver";
|
|
5
|
-
import { FetchHttpHandler, streamCollector } from "@aws-sdk/fetch-http-handler";
|
|
5
|
+
import { FetchHttpHandler as RequestHandler, streamCollector } from "@aws-sdk/fetch-http-handler";
|
|
6
6
|
import { invalidProvider } from "@aws-sdk/invalid-dependency";
|
|
7
7
|
import { DEFAULT_MAX_ATTEMPTS, DEFAULT_RETRY_MODE } from "@aws-sdk/middleware-retry";
|
|
8
8
|
import { fromBase64, toBase64 } from "@aws-sdk/util-base64-browser";
|
|
@@ -10,8 +10,17 @@ import { calculateBodyLength } from "@aws-sdk/util-body-length-browser";
|
|
|
10
10
|
import { defaultUserAgent } from "@aws-sdk/util-user-agent-browser";
|
|
11
11
|
import { fromUtf8, toUtf8 } from "@aws-sdk/util-utf8-browser";
|
|
12
12
|
import { getRuntimeConfig as getSharedRuntimeConfig } from "./runtimeConfig.shared";
|
|
13
|
+
import { loadConfigsForDefaultMode } from "@aws-sdk/smithy-client";
|
|
14
|
+
import { resolveDefaultsModeConfig } from "@aws-sdk/util-defaults-mode-browser";
|
|
13
15
|
export var getRuntimeConfig = function (config) {
|
|
14
16
|
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o, _p, _q;
|
|
17
|
+
var defaultsMode = resolveDefaultsModeConfig(config);
|
|
18
|
+
var defaultConfigProvider = function () { return defaultsMode().then(loadConfigsForDefaultMode); };
|
|
15
19
|
var clientSharedValues = getSharedRuntimeConfig(config);
|
|
16
|
-
return __assign(__assign(__assign({}, clientSharedValues), config), { runtime: "browser", base64Decoder: (_a = config === null || config === void 0 ? void 0 : config.base64Decoder) !== null && _a !== void 0 ? _a : fromBase64, base64Encoder: (_b = config === null || config === void 0 ? void 0 : config.base64Encoder) !== null && _b !== void 0 ? _b : toBase64, bodyLengthChecker: (_c = config === null || config === void 0 ? void 0 : config.bodyLengthChecker) !== null && _c !== void 0 ? _c : calculateBodyLength, credentialDefaultProvider: (_d = config === null || config === void 0 ? void 0 : config.credentialDefaultProvider) !== null && _d !== void 0 ? _d : (function (_) { return function () { return Promise.reject(new Error("Credential is missing")); }; }), defaultUserAgentProvider: (_e = config === null || config === void 0 ? void 0 : config.defaultUserAgentProvider) !== null && _e !== void 0 ? _e : defaultUserAgent({ serviceId: clientSharedValues.serviceId, clientVersion: packageInfo.version }), maxAttempts: (_f = config === null || config === void 0 ? void 0 : config.maxAttempts) !== null && _f !== void 0 ? _f : DEFAULT_MAX_ATTEMPTS, region: (_g = config === null || config === void 0 ? void 0 : config.region) !== null && _g !== void 0 ? _g : invalidProvider("Region is missing"), requestHandler: (_h = config === null || config === void 0 ? void 0 : config.requestHandler) !== null && _h !== void 0 ? _h : new
|
|
20
|
+
return __assign(__assign(__assign({}, clientSharedValues), config), { runtime: "browser", defaultsMode: defaultsMode, base64Decoder: (_a = config === null || config === void 0 ? void 0 : config.base64Decoder) !== null && _a !== void 0 ? _a : fromBase64, base64Encoder: (_b = config === null || config === void 0 ? void 0 : config.base64Encoder) !== null && _b !== void 0 ? _b : toBase64, bodyLengthChecker: (_c = config === null || config === void 0 ? void 0 : config.bodyLengthChecker) !== null && _c !== void 0 ? _c : calculateBodyLength, credentialDefaultProvider: (_d = config === null || config === void 0 ? void 0 : config.credentialDefaultProvider) !== null && _d !== void 0 ? _d : (function (_) { return function () { return Promise.reject(new Error("Credential is missing")); }; }), defaultUserAgentProvider: (_e = config === null || config === void 0 ? void 0 : config.defaultUserAgentProvider) !== null && _e !== void 0 ? _e : defaultUserAgent({ serviceId: clientSharedValues.serviceId, clientVersion: packageInfo.version }), maxAttempts: (_f = config === null || config === void 0 ? void 0 : config.maxAttempts) !== null && _f !== void 0 ? _f : DEFAULT_MAX_ATTEMPTS, region: (_g = config === null || config === void 0 ? void 0 : config.region) !== null && _g !== void 0 ? _g : invalidProvider("Region is missing"), requestHandler: (_h = config === null || config === void 0 ? void 0 : config.requestHandler) !== null && _h !== void 0 ? _h : new RequestHandler(defaultConfigProvider), retryMode: (_j = config === null || config === void 0 ? void 0 : config.retryMode) !== null && _j !== void 0 ? _j : (function () { return __awaiter(void 0, void 0, void 0, function () { return __generator(this, function (_a) {
|
|
21
|
+
switch (_a.label) {
|
|
22
|
+
case 0: return [4, defaultConfigProvider()];
|
|
23
|
+
case 1: return [2, (_a.sent()).retryMode || DEFAULT_RETRY_MODE];
|
|
24
|
+
}
|
|
25
|
+
}); }); }), sha256: (_k = config === null || config === void 0 ? void 0 : config.sha256) !== null && _k !== void 0 ? _k : Sha256, streamCollector: (_l = config === null || config === void 0 ? void 0 : config.streamCollector) !== null && _l !== void 0 ? _l : streamCollector, useDualstackEndpoint: (_m = config === null || config === void 0 ? void 0 : config.useDualstackEndpoint) !== null && _m !== void 0 ? _m : (function () { return Promise.resolve(DEFAULT_USE_DUALSTACK_ENDPOINT); }), useFipsEndpoint: (_o = config === null || config === void 0 ? void 0 : config.useFipsEndpoint) !== null && _o !== void 0 ? _o : (function () { return Promise.resolve(DEFAULT_USE_FIPS_ENDPOINT); }), utf8Decoder: (_p = config === null || config === void 0 ? void 0 : config.utf8Decoder) !== null && _p !== void 0 ? _p : fromUtf8, utf8Encoder: (_q = config === null || config === void 0 ? void 0 : config.utf8Encoder) !== null && _q !== void 0 ? _q : toUtf8 });
|
|
17
26
|
};
|
package/dist-es/runtimeConfig.js
CHANGED
|
@@ -1,21 +1,28 @@
|
|
|
1
|
-
import { __assign } from "tslib";
|
|
1
|
+
import { __assign, __awaiter, __generator } from "tslib";
|
|
2
2
|
import packageInfo from "../package.json";
|
|
3
3
|
import { decorateDefaultCredentialProvider } from "@aws-sdk/client-sts";
|
|
4
4
|
import { NODE_REGION_CONFIG_FILE_OPTIONS, NODE_REGION_CONFIG_OPTIONS, NODE_USE_DUALSTACK_ENDPOINT_CONFIG_OPTIONS, NODE_USE_FIPS_ENDPOINT_CONFIG_OPTIONS, } from "@aws-sdk/config-resolver";
|
|
5
5
|
import { defaultProvider as credentialDefaultProvider } from "@aws-sdk/credential-provider-node";
|
|
6
6
|
import { Hash } from "@aws-sdk/hash-node";
|
|
7
|
-
import { NODE_MAX_ATTEMPT_CONFIG_OPTIONS, NODE_RETRY_MODE_CONFIG_OPTIONS } from "@aws-sdk/middleware-retry";
|
|
7
|
+
import { DEFAULT_RETRY_MODE, NODE_MAX_ATTEMPT_CONFIG_OPTIONS, NODE_RETRY_MODE_CONFIG_OPTIONS, } from "@aws-sdk/middleware-retry";
|
|
8
8
|
import { loadConfig as loadNodeConfig } from "@aws-sdk/node-config-provider";
|
|
9
|
-
import { NodeHttpHandler, streamCollector } from "@aws-sdk/node-http-handler";
|
|
9
|
+
import { NodeHttpHandler as RequestHandler, streamCollector } from "@aws-sdk/node-http-handler";
|
|
10
10
|
import { fromBase64, toBase64 } from "@aws-sdk/util-base64-node";
|
|
11
11
|
import { calculateBodyLength } from "@aws-sdk/util-body-length-node";
|
|
12
12
|
import { defaultUserAgent } from "@aws-sdk/util-user-agent-node";
|
|
13
13
|
import { fromUtf8, toUtf8 } from "@aws-sdk/util-utf8-node";
|
|
14
14
|
import { getRuntimeConfig as getSharedRuntimeConfig } from "./runtimeConfig.shared";
|
|
15
|
-
import {
|
|
15
|
+
import { loadConfigsForDefaultMode } from "@aws-sdk/smithy-client";
|
|
16
|
+
import { resolveDefaultsModeConfig } from "@aws-sdk/util-defaults-mode-node";
|
|
16
17
|
export var getRuntimeConfig = function (config) {
|
|
17
18
|
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o, _p, _q;
|
|
18
|
-
|
|
19
|
+
var defaultsMode = resolveDefaultsModeConfig(config);
|
|
20
|
+
var defaultConfigProvider = function () { return defaultsMode().then(loadConfigsForDefaultMode); };
|
|
19
21
|
var clientSharedValues = getSharedRuntimeConfig(config);
|
|
20
|
-
return __assign(__assign(__assign({}, clientSharedValues), config), { runtime: "node", base64Decoder: (_a = config === null || config === void 0 ? void 0 : config.base64Decoder) !== null && _a !== void 0 ? _a : fromBase64, base64Encoder: (_b = config === null || config === void 0 ? void 0 : config.base64Encoder) !== null && _b !== void 0 ? _b : toBase64, bodyLengthChecker: (_c = config === null || config === void 0 ? void 0 : config.bodyLengthChecker) !== null && _c !== void 0 ? _c : calculateBodyLength, credentialDefaultProvider: (_d = config === null || config === void 0 ? void 0 : config.credentialDefaultProvider) !== null && _d !== void 0 ? _d : decorateDefaultCredentialProvider(credentialDefaultProvider), defaultUserAgentProvider: (_e = config === null || config === void 0 ? void 0 : config.defaultUserAgentProvider) !== null && _e !== void 0 ? _e : defaultUserAgent({ serviceId: clientSharedValues.serviceId, clientVersion: packageInfo.version }), maxAttempts: (_f = config === null || config === void 0 ? void 0 : config.maxAttempts) !== null && _f !== void 0 ? _f : loadNodeConfig(NODE_MAX_ATTEMPT_CONFIG_OPTIONS), region: (_g = config === null || config === void 0 ? void 0 : config.region) !== null && _g !== void 0 ? _g : loadNodeConfig(NODE_REGION_CONFIG_OPTIONS, NODE_REGION_CONFIG_FILE_OPTIONS), requestHandler: (_h = config === null || config === void 0 ? void 0 : config.requestHandler) !== null && _h !== void 0 ? _h : new
|
|
22
|
+
return __assign(__assign(__assign({}, clientSharedValues), config), { runtime: "node", defaultsMode: defaultsMode, base64Decoder: (_a = config === null || config === void 0 ? void 0 : config.base64Decoder) !== null && _a !== void 0 ? _a : fromBase64, base64Encoder: (_b = config === null || config === void 0 ? void 0 : config.base64Encoder) !== null && _b !== void 0 ? _b : toBase64, bodyLengthChecker: (_c = config === null || config === void 0 ? void 0 : config.bodyLengthChecker) !== null && _c !== void 0 ? _c : calculateBodyLength, credentialDefaultProvider: (_d = config === null || config === void 0 ? void 0 : config.credentialDefaultProvider) !== null && _d !== void 0 ? _d : decorateDefaultCredentialProvider(credentialDefaultProvider), defaultUserAgentProvider: (_e = config === null || config === void 0 ? void 0 : config.defaultUserAgentProvider) !== null && _e !== void 0 ? _e : defaultUserAgent({ serviceId: clientSharedValues.serviceId, clientVersion: packageInfo.version }), maxAttempts: (_f = config === null || config === void 0 ? void 0 : config.maxAttempts) !== null && _f !== void 0 ? _f : loadNodeConfig(NODE_MAX_ATTEMPT_CONFIG_OPTIONS), region: (_g = config === null || config === void 0 ? void 0 : config.region) !== null && _g !== void 0 ? _g : loadNodeConfig(NODE_REGION_CONFIG_OPTIONS, NODE_REGION_CONFIG_FILE_OPTIONS), requestHandler: (_h = config === null || config === void 0 ? void 0 : config.requestHandler) !== null && _h !== void 0 ? _h : new RequestHandler(defaultConfigProvider), retryMode: (_j = config === null || config === void 0 ? void 0 : config.retryMode) !== null && _j !== void 0 ? _j : loadNodeConfig(__assign(__assign({}, NODE_RETRY_MODE_CONFIG_OPTIONS), { default: function () { return __awaiter(void 0, void 0, void 0, function () { return __generator(this, function (_a) {
|
|
23
|
+
switch (_a.label) {
|
|
24
|
+
case 0: return [4, defaultConfigProvider()];
|
|
25
|
+
case 1: return [2, (_a.sent()).retryMode || DEFAULT_RETRY_MODE];
|
|
26
|
+
}
|
|
27
|
+
}); }); } })), sha256: (_k = config === null || config === void 0 ? void 0 : config.sha256) !== null && _k !== void 0 ? _k : Hash.bind(null, "sha256"), streamCollector: (_l = config === null || config === void 0 ? void 0 : config.streamCollector) !== null && _l !== void 0 ? _l : streamCollector, useDualstackEndpoint: (_m = config === null || config === void 0 ? void 0 : config.useDualstackEndpoint) !== null && _m !== void 0 ? _m : loadNodeConfig(NODE_USE_DUALSTACK_ENDPOINT_CONFIG_OPTIONS), useFipsEndpoint: (_o = config === null || config === void 0 ? void 0 : config.useFipsEndpoint) !== null && _o !== void 0 ? _o : loadNodeConfig(NODE_USE_FIPS_ENDPOINT_CONFIG_OPTIONS), utf8Decoder: (_p = config === null || config === void 0 ? void 0 : config.utf8Decoder) !== null && _p !== void 0 ? _p : fromUtf8, utf8Encoder: (_q = config === null || config === void 0 ? void 0 : config.utf8Encoder) !== null && _q !== void 0 ? _q : toUtf8 });
|
|
21
28
|
};
|
|
@@ -108,6 +108,9 @@ export declare class CloudWatch extends CloudWatchClient {
|
|
|
108
108
|
* <p>Retrieves the history for the specified alarm. You can filter the results by date range or item type.
|
|
109
109
|
* If an alarm name is not specified, the histories for either all metric alarms or all composite alarms are returned.</p>
|
|
110
110
|
* <p>CloudWatch retains the history of an alarm even if you delete the alarm.</p>
|
|
111
|
+
* <p>To use this operation and return information about a composite alarm, you must be signed on with
|
|
112
|
+
* the <code>cloudwatch:DescribeAlarmHistory</code> permission that is scoped to <code>*</code>. You can't return information
|
|
113
|
+
* about composite alarms if your <code>cloudwatch:DescribeAlarmHistory</code> permission has a narrower scope.</p>
|
|
111
114
|
*/
|
|
112
115
|
describeAlarmHistory(args: DescribeAlarmHistoryCommandInput, options?: __HttpHandlerOptions): Promise<DescribeAlarmHistoryCommandOutput>;
|
|
113
116
|
describeAlarmHistory(args: DescribeAlarmHistoryCommandInput, cb: (err: any, data?: DescribeAlarmHistoryCommandOutput) => void): void;
|
|
@@ -115,6 +118,9 @@ export declare class CloudWatch extends CloudWatchClient {
|
|
|
115
118
|
/**
|
|
116
119
|
* <p>Retrieves the specified alarms. You can filter the results by specifying a prefix for the alarm
|
|
117
120
|
* name, the alarm state, or a prefix for any action.</p>
|
|
121
|
+
* <p>To use this operation and return information about composite alarms, you must be signed on with
|
|
122
|
+
* the <code>cloudwatch:DescribeAlarms</code> permission that is scoped to <code>*</code>. You can't return information
|
|
123
|
+
* about composite alarms if your <code>cloudwatch:DescribeAlarms</code> permission has a narrower scope.</p>
|
|
118
124
|
*/
|
|
119
125
|
describeAlarms(args: DescribeAlarmsCommandInput, options?: __HttpHandlerOptions): Promise<DescribeAlarmsCommandOutput>;
|
|
120
126
|
describeAlarms(args: DescribeAlarmsCommandInput, cb: (err: any, data?: DescribeAlarmsCommandOutput) => void): void;
|
|
@@ -130,9 +136,13 @@ export declare class CloudWatch extends CloudWatchClient {
|
|
|
130
136
|
describeAlarmsForMetric(args: DescribeAlarmsForMetricCommandInput, cb: (err: any, data?: DescribeAlarmsForMetricCommandOutput) => void): void;
|
|
131
137
|
describeAlarmsForMetric(args: DescribeAlarmsForMetricCommandInput, options: __HttpHandlerOptions, cb: (err: any, data?: DescribeAlarmsForMetricCommandOutput) => void): void;
|
|
132
138
|
/**
|
|
133
|
-
* <p>Lists the anomaly detection models that you have created in your account.
|
|
134
|
-
*
|
|
135
|
-
*
|
|
139
|
+
* <p>Lists the anomaly detection models that you have created in your account.
|
|
140
|
+
* For single metric anomaly detectors,
|
|
141
|
+
* you can list all of the models in your account or filter the results
|
|
142
|
+
* to only the models that are related to a certain namespace, metric name, or metric dimension.
|
|
143
|
+
* For metric math anomaly detectors,
|
|
144
|
+
* you can list them by adding <code>METRIC_MATH</code> to the <code>AnomalyDetectorTypes</code> array.
|
|
145
|
+
* This will return all metric math anomaly detectors in your account.</p>
|
|
136
146
|
*/
|
|
137
147
|
describeAnomalyDetectors(args: DescribeAnomalyDetectorsCommandInput, options?: __HttpHandlerOptions): Promise<DescribeAnomalyDetectorsCommandOutput>;
|
|
138
148
|
describeAnomalyDetectors(args: DescribeAnomalyDetectorsCommandInput, cb: (err: any, data?: DescribeAnomalyDetectorsCommandOutput) => void): void;
|
|
@@ -439,6 +449,10 @@ export declare class CloudWatch extends CloudWatchClient {
|
|
|
439
449
|
* <p>When you update an existing alarm, its state is left unchanged, but the update
|
|
440
450
|
* completely overwrites the previous configuration of the alarm.</p>
|
|
441
451
|
*
|
|
452
|
+
* <p>To use this operation, you must be signed on with
|
|
453
|
+
* the <code>cloudwatch:PutCompositeAlarm</code> permission that is scoped to <code>*</code>. You can't create a
|
|
454
|
+
* composite alarms if your <code>cloudwatch:PutCompositeAlarm</code> permission has a narrower scope.</p>
|
|
455
|
+
*
|
|
442
456
|
* <p>If you are an IAM user, you must have <code>iam:CreateServiceLinkedRole</code> to create
|
|
443
457
|
* a composite alarm that has Systems Manager OpsItem actions.</p>
|
|
444
458
|
*/
|
|
@@ -506,7 +520,7 @@ export declare class CloudWatch extends CloudWatchClient {
|
|
|
506
520
|
*
|
|
507
521
|
*
|
|
508
522
|
* <p>The first time you create an alarm in the
|
|
509
|
-
* Management Console, the CLI, or by using the PutMetricAlarm API, CloudWatch
|
|
523
|
+
* Amazon Web Services Management Console, the CLI, or by using the PutMetricAlarm API, CloudWatch
|
|
510
524
|
* creates the necessary service-linked role for you. The service-linked roles
|
|
511
525
|
* are called <code>AWSServiceRoleForCloudWatchEvents</code> and
|
|
512
526
|
* <code>AWSServiceRoleForCloudWatchAlarms_ActionSSM</code>.
|
|
@@ -597,7 +611,7 @@ export declare class CloudWatch extends CloudWatchClient {
|
|
|
597
611
|
* <p>Creates or updates a metric stream. Metric streams can automatically stream CloudWatch metrics
|
|
598
612
|
* to Amazon Web Services destinations including
|
|
599
613
|
* Amazon S3 and to many third-party solutions.</p>
|
|
600
|
-
* <p>For more information, see <a href="https://docs.aws.amazon.com/AmazonCloudWatch/latest/monitoring/Metric-Streams.html">
|
|
614
|
+
* <p>For more information, see <a href="https://docs.aws.amazon.com/AmazonCloudWatch/latest/monitoring/CloudWatch-Metric-Streams.html">
|
|
601
615
|
* Using Metric Streams</a>.</p>
|
|
602
616
|
* <p>To create a metric stream,
|
|
603
617
|
* you must be logged on to an account that has the <code>iam:PassRole</code> permission
|
|
@@ -4,7 +4,7 @@ import { RetryInputConfig, RetryResolvedConfig } from "@aws-sdk/middleware-retry
|
|
|
4
4
|
import { AwsAuthInputConfig, AwsAuthResolvedConfig } from "@aws-sdk/middleware-signing";
|
|
5
5
|
import { UserAgentInputConfig, UserAgentResolvedConfig } from "@aws-sdk/middleware-user-agent";
|
|
6
6
|
import { HttpHandler as __HttpHandler } from "@aws-sdk/protocol-http";
|
|
7
|
-
import { Client as __Client, SmithyConfiguration as __SmithyConfiguration, SmithyResolvedConfiguration as __SmithyResolvedConfiguration } from "@aws-sdk/smithy-client";
|
|
7
|
+
import { Client as __Client, DefaultsMode, SmithyConfiguration as __SmithyConfiguration, SmithyResolvedConfiguration as __SmithyResolvedConfiguration } from "@aws-sdk/smithy-client";
|
|
8
8
|
import { Credentials as __Credentials, Decoder as __Decoder, Encoder as __Encoder, HashConstructor as __HashConstructor, HttpHandlerOptions as __HttpHandlerOptions, Logger as __Logger, Provider as __Provider, Provider, RegionInfoProvider, StreamCollector as __StreamCollector, UrlParser as __UrlParser, UserAgent as __UserAgent } from "@aws-sdk/types";
|
|
9
9
|
import { DeleteAlarmsCommandInput, DeleteAlarmsCommandOutput } from "./commands/DeleteAlarmsCommand";
|
|
10
10
|
import { DeleteAnomalyDetectorCommandInput, DeleteAnomalyDetectorCommandOutput } from "./commands/DeleteAnomalyDetectorCommand";
|
|
@@ -144,6 +144,10 @@ export interface ClientDefaults extends Partial<__SmithyResolvedConfiguration<__
|
|
|
144
144
|
* @internal
|
|
145
145
|
*/
|
|
146
146
|
defaultUserAgentProvider?: Provider<__UserAgent>;
|
|
147
|
+
/**
|
|
148
|
+
* The {@link DefaultsMode} that will be used to determine how certain default configuration options are resolved in the SDK.
|
|
149
|
+
*/
|
|
150
|
+
defaultsMode?: DefaultsMode | Provider<DefaultsMode>;
|
|
147
151
|
}
|
|
148
152
|
declare type CloudWatchClientConfigType = Partial<__SmithyConfiguration<__HttpHandlerOptions>> & ClientDefaults & RegionInputConfig & EndpointsInputConfig & RetryInputConfig & HostHeaderInputConfig & AwsAuthInputConfig & UserAgentInputConfig;
|
|
149
153
|
/**
|
|
@@ -10,6 +10,9 @@ export interface DescribeAlarmHistoryCommandOutput extends DescribeAlarmHistoryO
|
|
|
10
10
|
* <p>Retrieves the history for the specified alarm. You can filter the results by date range or item type.
|
|
11
11
|
* If an alarm name is not specified, the histories for either all metric alarms or all composite alarms are returned.</p>
|
|
12
12
|
* <p>CloudWatch retains the history of an alarm even if you delete the alarm.</p>
|
|
13
|
+
* <p>To use this operation and return information about a composite alarm, you must be signed on with
|
|
14
|
+
* the <code>cloudwatch:DescribeAlarmHistory</code> permission that is scoped to <code>*</code>. You can't return information
|
|
15
|
+
* about composite alarms if your <code>cloudwatch:DescribeAlarmHistory</code> permission has a narrower scope.</p>
|
|
13
16
|
* @example
|
|
14
17
|
* Use a bare-bones client and the command you need to make an API call.
|
|
15
18
|
* ```javascript
|
|
@@ -9,6 +9,9 @@ export interface DescribeAlarmsCommandOutput extends DescribeAlarmsOutput, __Met
|
|
|
9
9
|
/**
|
|
10
10
|
* <p>Retrieves the specified alarms. You can filter the results by specifying a prefix for the alarm
|
|
11
11
|
* name, the alarm state, or a prefix for any action.</p>
|
|
12
|
+
* <p>To use this operation and return information about composite alarms, you must be signed on with
|
|
13
|
+
* the <code>cloudwatch:DescribeAlarms</code> permission that is scoped to <code>*</code>. You can't return information
|
|
14
|
+
* about composite alarms if your <code>cloudwatch:DescribeAlarms</code> permission has a narrower scope.</p>
|
|
12
15
|
* @example
|
|
13
16
|
* Use a bare-bones client and the command you need to make an API call.
|
|
14
17
|
* ```javascript
|
|
@@ -7,9 +7,13 @@ export interface DescribeAnomalyDetectorsCommandInput extends DescribeAnomalyDet
|
|
|
7
7
|
export interface DescribeAnomalyDetectorsCommandOutput extends DescribeAnomalyDetectorsOutput, __MetadataBearer {
|
|
8
8
|
}
|
|
9
9
|
/**
|
|
10
|
-
* <p>Lists the anomaly detection models that you have created in your account.
|
|
11
|
-
*
|
|
12
|
-
*
|
|
10
|
+
* <p>Lists the anomaly detection models that you have created in your account.
|
|
11
|
+
* For single metric anomaly detectors,
|
|
12
|
+
* you can list all of the models in your account or filter the results
|
|
13
|
+
* to only the models that are related to a certain namespace, metric name, or metric dimension.
|
|
14
|
+
* For metric math anomaly detectors,
|
|
15
|
+
* you can list them by adding <code>METRIC_MATH</code> to the <code>AnomalyDetectorTypes</code> array.
|
|
16
|
+
* This will return all metric math anomaly detectors in your account.</p>
|
|
13
17
|
* @example
|
|
14
18
|
* Use a bare-bones client and the command you need to make an API call.
|
|
15
19
|
* ```javascript
|
|
@@ -41,6 +41,10 @@ export interface PutCompositeAlarmCommandOutput extends __MetadataBearer {
|
|
|
41
41
|
* <p>When you update an existing alarm, its state is left unchanged, but the update
|
|
42
42
|
* completely overwrites the previous configuration of the alarm.</p>
|
|
43
43
|
*
|
|
44
|
+
* <p>To use this operation, you must be signed on with
|
|
45
|
+
* the <code>cloudwatch:PutCompositeAlarm</code> permission that is scoped to <code>*</code>. You can't create a
|
|
46
|
+
* composite alarms if your <code>cloudwatch:PutCompositeAlarm</code> permission has a narrower scope.</p>
|
|
47
|
+
*
|
|
44
48
|
* <p>If you are an IAM user, you must have <code>iam:CreateServiceLinkedRole</code> to create
|
|
45
49
|
* a composite alarm that has Systems Manager OpsItem actions.</p>
|
|
46
50
|
* @example
|
|
@@ -38,7 +38,7 @@ export interface PutMetricAlarmCommandOutput extends __MetadataBearer {
|
|
|
38
38
|
*
|
|
39
39
|
*
|
|
40
40
|
* <p>The first time you create an alarm in the
|
|
41
|
-
* Management Console, the CLI, or by using the PutMetricAlarm API, CloudWatch
|
|
41
|
+
* Amazon Web Services Management Console, the CLI, or by using the PutMetricAlarm API, CloudWatch
|
|
42
42
|
* creates the necessary service-linked role for you. The service-linked roles
|
|
43
43
|
* are called <code>AWSServiceRoleForCloudWatchEvents</code> and
|
|
44
44
|
* <code>AWSServiceRoleForCloudWatchAlarms_ActionSSM</code>.
|
|
@@ -10,7 +10,7 @@ export interface PutMetricStreamCommandOutput extends PutMetricStreamOutput, __M
|
|
|
10
10
|
* <p>Creates or updates a metric stream. Metric streams can automatically stream CloudWatch metrics
|
|
11
11
|
* to Amazon Web Services destinations including
|
|
12
12
|
* Amazon S3 and to many third-party solutions.</p>
|
|
13
|
-
* <p>For more information, see <a href="https://docs.aws.amazon.com/AmazonCloudWatch/latest/monitoring/Metric-Streams.html">
|
|
13
|
+
* <p>For more information, see <a href="https://docs.aws.amazon.com/AmazonCloudWatch/latest/monitoring/CloudWatch-Metric-Streams.html">
|
|
14
14
|
* Using Metric Streams</a>.</p>
|
|
15
15
|
* <p>To create a metric stream,
|
|
16
16
|
* you must be logged on to an account that has the <code>iam:PassRole</code> permission
|