@aws-sdk/client-oam 3.218.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 (143) hide show
  1. package/LICENSE +201 -0
  2. package/README.md +216 -0
  3. package/dist-cjs/OAM.js +232 -0
  4. package/dist-cjs/OAMClient.js +40 -0
  5. package/dist-cjs/commands/CreateLinkCommand.js +46 -0
  6. package/dist-cjs/commands/CreateSinkCommand.js +46 -0
  7. package/dist-cjs/commands/DeleteLinkCommand.js +46 -0
  8. package/dist-cjs/commands/DeleteSinkCommand.js +46 -0
  9. package/dist-cjs/commands/GetLinkCommand.js +46 -0
  10. package/dist-cjs/commands/GetSinkCommand.js +46 -0
  11. package/dist-cjs/commands/GetSinkPolicyCommand.js +46 -0
  12. package/dist-cjs/commands/ListAttachedLinksCommand.js +46 -0
  13. package/dist-cjs/commands/ListLinksCommand.js +46 -0
  14. package/dist-cjs/commands/ListSinksCommand.js +46 -0
  15. package/dist-cjs/commands/ListTagsForResourceCommand.js +46 -0
  16. package/dist-cjs/commands/PutSinkPolicyCommand.js +46 -0
  17. package/dist-cjs/commands/TagResourceCommand.js +46 -0
  18. package/dist-cjs/commands/UntagResourceCommand.js +46 -0
  19. package/dist-cjs/commands/UpdateLinkCommand.js +46 -0
  20. package/dist-cjs/commands/index.js +18 -0
  21. package/dist-cjs/endpoint/EndpointParameters.js +12 -0
  22. package/dist-cjs/endpoint/endpointResolver.js +12 -0
  23. package/dist-cjs/endpoint/ruleset.js +312 -0
  24. package/dist-cjs/index.js +11 -0
  25. package/dist-cjs/models/OAMServiceException.js +11 -0
  26. package/dist-cjs/models/index.js +4 -0
  27. package/dist-cjs/models/models_0.js +258 -0
  28. package/dist-cjs/pagination/Interfaces.js +2 -0
  29. package/dist-cjs/pagination/ListAttachedLinksPaginator.js +36 -0
  30. package/dist-cjs/pagination/ListLinksPaginator.js +36 -0
  31. package/dist-cjs/pagination/ListSinksPaginator.js +36 -0
  32. package/dist-cjs/pagination/index.js +7 -0
  33. package/dist-cjs/protocols/Aws_restJson1.js +1313 -0
  34. package/dist-cjs/runtimeConfig.browser.js +42 -0
  35. package/dist-cjs/runtimeConfig.js +50 -0
  36. package/dist-cjs/runtimeConfig.native.js +15 -0
  37. package/dist-cjs/runtimeConfig.shared.js +18 -0
  38. package/dist-es/OAM.js +228 -0
  39. package/dist-es/OAMClient.js +36 -0
  40. package/dist-es/commands/CreateLinkCommand.js +42 -0
  41. package/dist-es/commands/CreateSinkCommand.js +42 -0
  42. package/dist-es/commands/DeleteLinkCommand.js +42 -0
  43. package/dist-es/commands/DeleteSinkCommand.js +42 -0
  44. package/dist-es/commands/GetLinkCommand.js +42 -0
  45. package/dist-es/commands/GetSinkCommand.js +42 -0
  46. package/dist-es/commands/GetSinkPolicyCommand.js +42 -0
  47. package/dist-es/commands/ListAttachedLinksCommand.js +42 -0
  48. package/dist-es/commands/ListLinksCommand.js +42 -0
  49. package/dist-es/commands/ListSinksCommand.js +42 -0
  50. package/dist-es/commands/ListTagsForResourceCommand.js +42 -0
  51. package/dist-es/commands/PutSinkPolicyCommand.js +42 -0
  52. package/dist-es/commands/TagResourceCommand.js +42 -0
  53. package/dist-es/commands/UntagResourceCommand.js +42 -0
  54. package/dist-es/commands/UpdateLinkCommand.js +42 -0
  55. package/dist-es/commands/index.js +15 -0
  56. package/dist-es/endpoint/EndpointParameters.js +8 -0
  57. package/dist-es/endpoint/endpointResolver.js +8 -0
  58. package/dist-es/endpoint/ruleset.js +309 -0
  59. package/dist-es/index.js +6 -0
  60. package/dist-es/models/OAMServiceException.js +7 -0
  61. package/dist-es/models/index.js +1 -0
  62. package/dist-es/models/models_0.js +214 -0
  63. package/dist-es/pagination/Interfaces.js +1 -0
  64. package/dist-es/pagination/ListAttachedLinksPaginator.js +32 -0
  65. package/dist-es/pagination/ListLinksPaginator.js +32 -0
  66. package/dist-es/pagination/ListSinksPaginator.js +32 -0
  67. package/dist-es/pagination/index.js +4 -0
  68. package/dist-es/protocols/Aws_restJson1.js +1280 -0
  69. package/dist-es/runtimeConfig.browser.js +37 -0
  70. package/dist-es/runtimeConfig.js +45 -0
  71. package/dist-es/runtimeConfig.native.js +11 -0
  72. package/dist-es/runtimeConfig.shared.js +14 -0
  73. package/dist-types/OAM.d.ts +194 -0
  74. package/dist-types/OAMClient.d.ts +167 -0
  75. package/dist-types/commands/CreateLinkCommand.d.ts +46 -0
  76. package/dist-types/commands/CreateSinkCommand.d.ts +43 -0
  77. package/dist-types/commands/DeleteLinkCommand.d.ts +38 -0
  78. package/dist-types/commands/DeleteSinkCommand.d.ts +37 -0
  79. package/dist-types/commands/GetLinkCommand.d.ts +38 -0
  80. package/dist-types/commands/GetSinkCommand.d.ts +38 -0
  81. package/dist-types/commands/GetSinkPolicyCommand.d.ts +38 -0
  82. package/dist-types/commands/ListAttachedLinksCommand.d.ts +39 -0
  83. package/dist-types/commands/ListLinksCommand.d.ts +39 -0
  84. package/dist-types/commands/ListSinksCommand.d.ts +37 -0
  85. package/dist-types/commands/ListTagsForResourceCommand.d.ts +37 -0
  86. package/dist-types/commands/PutSinkPolicyCommand.d.ts +60 -0
  87. package/dist-types/commands/TagResourceCommand.d.ts +53 -0
  88. package/dist-types/commands/UntagResourceCommand.d.ts +43 -0
  89. package/dist-types/commands/UpdateLinkCommand.d.ts +40 -0
  90. package/dist-types/commands/index.d.ts +15 -0
  91. package/dist-types/endpoint/EndpointParameters.d.ts +19 -0
  92. package/dist-types/endpoint/endpointResolver.d.ts +5 -0
  93. package/dist-types/endpoint/ruleset.d.ts +2 -0
  94. package/dist-types/index.d.ts +6 -0
  95. package/dist-types/models/OAMServiceException.d.ts +10 -0
  96. package/dist-types/models/index.d.ts +1 -0
  97. package/dist-types/models/models_0.d.ts +724 -0
  98. package/dist-types/pagination/Interfaces.d.ts +6 -0
  99. package/dist-types/pagination/ListAttachedLinksPaginator.d.ts +4 -0
  100. package/dist-types/pagination/ListLinksPaginator.d.ts +4 -0
  101. package/dist-types/pagination/ListSinksPaginator.d.ts +4 -0
  102. package/dist-types/pagination/index.d.ts +4 -0
  103. package/dist-types/protocols/Aws_restJson1.d.ts +47 -0
  104. package/dist-types/runtimeConfig.browser.d.ts +42 -0
  105. package/dist-types/runtimeConfig.d.ts +42 -0
  106. package/dist-types/runtimeConfig.native.d.ts +41 -0
  107. package/dist-types/runtimeConfig.shared.d.ts +16 -0
  108. package/dist-types/ts3.4/OAM.d.ts +259 -0
  109. package/dist-types/ts3.4/OAMClient.d.ts +200 -0
  110. package/dist-types/ts3.4/commands/CreateLinkCommand.d.ts +34 -0
  111. package/dist-types/ts3.4/commands/CreateSinkCommand.d.ts +34 -0
  112. package/dist-types/ts3.4/commands/DeleteLinkCommand.d.ts +34 -0
  113. package/dist-types/ts3.4/commands/DeleteSinkCommand.d.ts +34 -0
  114. package/dist-types/ts3.4/commands/GetLinkCommand.d.ts +32 -0
  115. package/dist-types/ts3.4/commands/GetSinkCommand.d.ts +32 -0
  116. package/dist-types/ts3.4/commands/GetSinkPolicyCommand.d.ts +34 -0
  117. package/dist-types/ts3.4/commands/ListAttachedLinksCommand.d.ts +37 -0
  118. package/dist-types/ts3.4/commands/ListLinksCommand.d.ts +34 -0
  119. package/dist-types/ts3.4/commands/ListSinksCommand.d.ts +34 -0
  120. package/dist-types/ts3.4/commands/ListTagsForResourceCommand.d.ts +38 -0
  121. package/dist-types/ts3.4/commands/PutSinkPolicyCommand.d.ts +34 -0
  122. package/dist-types/ts3.4/commands/TagResourceCommand.d.ts +34 -0
  123. package/dist-types/ts3.4/commands/UntagResourceCommand.d.ts +34 -0
  124. package/dist-types/ts3.4/commands/UpdateLinkCommand.d.ts +34 -0
  125. package/dist-types/ts3.4/commands/index.d.ts +15 -0
  126. package/dist-types/ts3.4/endpoint/EndpointParameters.d.ts +34 -0
  127. package/dist-types/ts3.4/endpoint/endpointResolver.d.ts +8 -0
  128. package/dist-types/ts3.4/endpoint/ruleset.d.ts +2 -0
  129. package/dist-types/ts3.4/index.d.ts +6 -0
  130. package/dist-types/ts3.4/models/OAMServiceException.d.ts +7 -0
  131. package/dist-types/ts3.4/models/index.d.ts +1 -0
  132. package/dist-types/ts3.4/models/models_0.d.ts +313 -0
  133. package/dist-types/ts3.4/pagination/Interfaces.d.ts +6 -0
  134. package/dist-types/ts3.4/pagination/ListAttachedLinksPaginator.d.ts +11 -0
  135. package/dist-types/ts3.4/pagination/ListLinksPaginator.d.ts +11 -0
  136. package/dist-types/ts3.4/pagination/ListSinksPaginator.d.ts +11 -0
  137. package/dist-types/ts3.4/pagination/index.d.ts +4 -0
  138. package/dist-types/ts3.4/protocols/Aws_restJson1.d.ts +185 -0
  139. package/dist-types/ts3.4/runtimeConfig.browser.d.ts +88 -0
  140. package/dist-types/ts3.4/runtimeConfig.d.ts +88 -0
  141. package/dist-types/ts3.4/runtimeConfig.native.d.ts +77 -0
  142. package/dist-types/ts3.4/runtimeConfig.shared.d.ts +16 -0
  143. package/package.json +101 -0
@@ -0,0 +1,37 @@
1
+ import packageInfo from "../package.json";
2
+ import { Sha256 } from "@aws-crypto/sha256-browser";
3
+ import { DEFAULT_USE_DUALSTACK_ENDPOINT, DEFAULT_USE_FIPS_ENDPOINT } from "@aws-sdk/config-resolver";
4
+ import { FetchHttpHandler as RequestHandler, streamCollector } from "@aws-sdk/fetch-http-handler";
5
+ import { invalidProvider } from "@aws-sdk/invalid-dependency";
6
+ import { DEFAULT_MAX_ATTEMPTS, DEFAULT_RETRY_MODE } from "@aws-sdk/middleware-retry";
7
+ import { calculateBodyLength } from "@aws-sdk/util-body-length-browser";
8
+ import { defaultUserAgent } from "@aws-sdk/util-user-agent-browser";
9
+ import { fromUtf8, toUtf8 } from "@aws-sdk/util-utf8-browser";
10
+ import { getRuntimeConfig as getSharedRuntimeConfig } from "./runtimeConfig.shared";
11
+ import { loadConfigsForDefaultMode } from "@aws-sdk/smithy-client";
12
+ import { resolveDefaultsModeConfig } from "@aws-sdk/util-defaults-mode-browser";
13
+ export const getRuntimeConfig = (config) => {
14
+ const defaultsMode = resolveDefaultsModeConfig(config);
15
+ const defaultConfigProvider = () => defaultsMode().then(loadConfigsForDefaultMode);
16
+ const clientSharedValues = getSharedRuntimeConfig(config);
17
+ return {
18
+ ...clientSharedValues,
19
+ ...config,
20
+ runtime: "browser",
21
+ defaultsMode,
22
+ bodyLengthChecker: config?.bodyLengthChecker ?? calculateBodyLength,
23
+ credentialDefaultProvider: config?.credentialDefaultProvider ?? ((_) => () => Promise.reject(new Error("Credential is missing"))),
24
+ defaultUserAgentProvider: config?.defaultUserAgentProvider ??
25
+ defaultUserAgent({ serviceId: clientSharedValues.serviceId, clientVersion: packageInfo.version }),
26
+ maxAttempts: config?.maxAttempts ?? DEFAULT_MAX_ATTEMPTS,
27
+ region: config?.region ?? invalidProvider("Region is missing"),
28
+ requestHandler: config?.requestHandler ?? new RequestHandler(defaultConfigProvider),
29
+ retryMode: config?.retryMode ?? (async () => (await defaultConfigProvider()).retryMode || DEFAULT_RETRY_MODE),
30
+ sha256: config?.sha256 ?? Sha256,
31
+ streamCollector: config?.streamCollector ?? streamCollector,
32
+ useDualstackEndpoint: config?.useDualstackEndpoint ?? (() => Promise.resolve(DEFAULT_USE_DUALSTACK_ENDPOINT)),
33
+ useFipsEndpoint: config?.useFipsEndpoint ?? (() => Promise.resolve(DEFAULT_USE_FIPS_ENDPOINT)),
34
+ utf8Decoder: config?.utf8Decoder ?? fromUtf8,
35
+ utf8Encoder: config?.utf8Encoder ?? toUtf8,
36
+ };
37
+ };
@@ -0,0 +1,45 @@
1
+ import packageInfo from "../package.json";
2
+ import { decorateDefaultCredentialProvider } from "@aws-sdk/client-sts";
3
+ 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";
4
+ import { defaultProvider as credentialDefaultProvider } from "@aws-sdk/credential-provider-node";
5
+ import { Hash } from "@aws-sdk/hash-node";
6
+ import { DEFAULT_RETRY_MODE, NODE_MAX_ATTEMPT_CONFIG_OPTIONS, NODE_RETRY_MODE_CONFIG_OPTIONS, } from "@aws-sdk/middleware-retry";
7
+ import { loadConfig as loadNodeConfig } from "@aws-sdk/node-config-provider";
8
+ import { NodeHttpHandler as RequestHandler, streamCollector } from "@aws-sdk/node-http-handler";
9
+ import { calculateBodyLength } from "@aws-sdk/util-body-length-node";
10
+ import { defaultUserAgent } from "@aws-sdk/util-user-agent-node";
11
+ import { fromUtf8, toUtf8 } from "@aws-sdk/util-utf8-node";
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-node";
15
+ import { emitWarningIfUnsupportedVersion } from "@aws-sdk/smithy-client";
16
+ export const getRuntimeConfig = (config) => {
17
+ emitWarningIfUnsupportedVersion(process.version);
18
+ const defaultsMode = resolveDefaultsModeConfig(config);
19
+ const defaultConfigProvider = () => defaultsMode().then(loadConfigsForDefaultMode);
20
+ const clientSharedValues = getSharedRuntimeConfig(config);
21
+ return {
22
+ ...clientSharedValues,
23
+ ...config,
24
+ runtime: "node",
25
+ defaultsMode,
26
+ bodyLengthChecker: config?.bodyLengthChecker ?? calculateBodyLength,
27
+ credentialDefaultProvider: config?.credentialDefaultProvider ?? decorateDefaultCredentialProvider(credentialDefaultProvider),
28
+ defaultUserAgentProvider: config?.defaultUserAgentProvider ??
29
+ defaultUserAgent({ serviceId: clientSharedValues.serviceId, clientVersion: packageInfo.version }),
30
+ maxAttempts: config?.maxAttempts ?? loadNodeConfig(NODE_MAX_ATTEMPT_CONFIG_OPTIONS),
31
+ region: config?.region ?? loadNodeConfig(NODE_REGION_CONFIG_OPTIONS, NODE_REGION_CONFIG_FILE_OPTIONS),
32
+ requestHandler: config?.requestHandler ?? new RequestHandler(defaultConfigProvider),
33
+ retryMode: config?.retryMode ??
34
+ loadNodeConfig({
35
+ ...NODE_RETRY_MODE_CONFIG_OPTIONS,
36
+ default: async () => (await defaultConfigProvider()).retryMode || DEFAULT_RETRY_MODE,
37
+ }),
38
+ sha256: config?.sha256 ?? Hash.bind(null, "sha256"),
39
+ streamCollector: config?.streamCollector ?? streamCollector,
40
+ useDualstackEndpoint: config?.useDualstackEndpoint ?? loadNodeConfig(NODE_USE_DUALSTACK_ENDPOINT_CONFIG_OPTIONS),
41
+ useFipsEndpoint: config?.useFipsEndpoint ?? loadNodeConfig(NODE_USE_FIPS_ENDPOINT_CONFIG_OPTIONS),
42
+ utf8Decoder: config?.utf8Decoder ?? fromUtf8,
43
+ utf8Encoder: config?.utf8Encoder ?? toUtf8,
44
+ };
45
+ };
@@ -0,0 +1,11 @@
1
+ import { Sha256 } from "@aws-crypto/sha256-js";
2
+ import { getRuntimeConfig as getBrowserRuntimeConfig } from "./runtimeConfig.browser";
3
+ export const getRuntimeConfig = (config) => {
4
+ const browserDefaults = getBrowserRuntimeConfig(config);
5
+ return {
6
+ ...browserDefaults,
7
+ ...config,
8
+ runtime: "react-native",
9
+ sha256: config?.sha256 ?? Sha256,
10
+ };
11
+ };
@@ -0,0 +1,14 @@
1
+ import { NoOpLogger } from "@aws-sdk/smithy-client";
2
+ import { parseUrl } from "@aws-sdk/url-parser";
3
+ import { fromBase64, toBase64 } from "@aws-sdk/util-base64";
4
+ import { defaultEndpointResolver } from "./endpoint/endpointResolver";
5
+ export const getRuntimeConfig = (config) => ({
6
+ apiVersion: "2022-06-10",
7
+ base64Decoder: config?.base64Decoder ?? fromBase64,
8
+ base64Encoder: config?.base64Encoder ?? toBase64,
9
+ disableHostPrefix: config?.disableHostPrefix ?? false,
10
+ endpointProvider: config?.endpointProvider ?? defaultEndpointResolver,
11
+ logger: config?.logger ?? new NoOpLogger(),
12
+ serviceId: config?.serviceId ?? "OAM",
13
+ urlParser: config?.urlParser ?? parseUrl,
14
+ });
@@ -0,0 +1,194 @@
1
+ import { HttpHandlerOptions as __HttpHandlerOptions } from "@aws-sdk/types";
2
+ import { CreateLinkCommandInput, CreateLinkCommandOutput } from "./commands/CreateLinkCommand";
3
+ import { CreateSinkCommandInput, CreateSinkCommandOutput } from "./commands/CreateSinkCommand";
4
+ import { DeleteLinkCommandInput, DeleteLinkCommandOutput } from "./commands/DeleteLinkCommand";
5
+ import { DeleteSinkCommandInput, DeleteSinkCommandOutput } from "./commands/DeleteSinkCommand";
6
+ import { GetLinkCommandInput, GetLinkCommandOutput } from "./commands/GetLinkCommand";
7
+ import { GetSinkCommandInput, GetSinkCommandOutput } from "./commands/GetSinkCommand";
8
+ import { GetSinkPolicyCommandInput, GetSinkPolicyCommandOutput } from "./commands/GetSinkPolicyCommand";
9
+ import { ListAttachedLinksCommandInput, ListAttachedLinksCommandOutput } from "./commands/ListAttachedLinksCommand";
10
+ import { ListLinksCommandInput, ListLinksCommandOutput } from "./commands/ListLinksCommand";
11
+ import { ListSinksCommandInput, ListSinksCommandOutput } from "./commands/ListSinksCommand";
12
+ import { ListTagsForResourceCommandInput, ListTagsForResourceCommandOutput } from "./commands/ListTagsForResourceCommand";
13
+ import { PutSinkPolicyCommandInput, PutSinkPolicyCommandOutput } from "./commands/PutSinkPolicyCommand";
14
+ import { TagResourceCommandInput, TagResourceCommandOutput } from "./commands/TagResourceCommand";
15
+ import { UntagResourceCommandInput, UntagResourceCommandOutput } from "./commands/UntagResourceCommand";
16
+ import { UpdateLinkCommandInput, UpdateLinkCommandOutput } from "./commands/UpdateLinkCommand";
17
+ import { OAMClient } from "./OAMClient";
18
+ /**
19
+ * <p>Use Amazon CloudWatch Observability Access Manager to create and manage links between source accounts and
20
+ * monitoring accounts by using <i>CloudWatch cross-account observability</i>. With
21
+ * CloudWatch cross-account observability, you can monitor and troubleshoot applications that span
22
+ * multiple accounts within a Region. Seamlessly search, visualize, and analyze your metrics,
23
+ * logs, and traces in any of the linked accounts without account boundaries.</p>
24
+ *
25
+ * <p>Set up one or more Amazon Web Services accounts as <i>monitoring
26
+ * accounts</i> and link them with multiple <i>source accounts</i>. A
27
+ * monitoring account is a central Amazon Web Services account that can view and interact with
28
+ * observability data generated from source accounts. A source account is an individual Amazon Web Services account that generates observability data for the resources that reside in it.
29
+ * Source accounts share their observability data with the monitoring account. The shared
30
+ * observability data can include metrics in Amazon CloudWatch, logs in Amazon CloudWatch Logs, and traces in X-Ray.</p>
31
+ */
32
+ export declare class OAM extends OAMClient {
33
+ /**
34
+ * <p>Creates a link between a source account and a sink that you have created in a monitoring account.</p>
35
+ * <p>Before you create a link, you must create a sink in the monitoring account and create a
36
+ * sink policy in that account. The sink policy must permit the source account to link to it. You
37
+ * can grant permission to source accounts by granting permission to an entire organization or to
38
+ * individual accounts.</p>
39
+ * <p>For more information, see
40
+ * <a href="https://docs.aws.amazon.com/OAM/latest/APIReference/API_CreateSink.html">CreateSink</a> and
41
+ * <a href="https://docs.aws.amazon.com/OAM/latest/APIReference/API_PutSinkPolicy.html">PutSinkPolicy</a>.</p>
42
+ * <p>Each monitoring account can be linked to as many as 100,000 source accounts.</p>
43
+ * <p>Each source account can be linked to as many as five monitoring accounts.</p>
44
+ */
45
+ createLink(args: CreateLinkCommandInput, options?: __HttpHandlerOptions): Promise<CreateLinkCommandOutput>;
46
+ createLink(args: CreateLinkCommandInput, cb: (err: any, data?: CreateLinkCommandOutput) => void): void;
47
+ createLink(args: CreateLinkCommandInput, options: __HttpHandlerOptions, cb: (err: any, data?: CreateLinkCommandOutput) => void): void;
48
+ /**
49
+ * <p>Use this to create a <i>sink</i> in the current account, so that it can be
50
+ * used as a monitoring account in CloudWatch cross-account observability. A sink is a resource that
51
+ * represents an attachment point in a monitoring account. Source accounts can link to the sink
52
+ * to send observability data.</p>
53
+ * <p>After you create a sink, you must create a sink policy that allows source accounts to attach to it.
54
+ * For more information, see <a href="https://docs.aws.amazon.com/OAM/latest/APIReference/API_PutSinkPolicy.html">PutSinkPolicy</a>.</p>
55
+ * <p>Each account can contain one sink. If you delete a sink, you can then create a new one in that account.</p>
56
+ */
57
+ createSink(args: CreateSinkCommandInput, options?: __HttpHandlerOptions): Promise<CreateSinkCommandOutput>;
58
+ createSink(args: CreateSinkCommandInput, cb: (err: any, data?: CreateSinkCommandOutput) => void): void;
59
+ createSink(args: CreateSinkCommandInput, options: __HttpHandlerOptions, cb: (err: any, data?: CreateSinkCommandOutput) => void): void;
60
+ /**
61
+ * <p>Deletes a link between a monitoring account sink and a source account. You must run this operation
62
+ * in the source account.</p>
63
+ */
64
+ deleteLink(args: DeleteLinkCommandInput, options?: __HttpHandlerOptions): Promise<DeleteLinkCommandOutput>;
65
+ deleteLink(args: DeleteLinkCommandInput, cb: (err: any, data?: DeleteLinkCommandOutput) => void): void;
66
+ deleteLink(args: DeleteLinkCommandInput, options: __HttpHandlerOptions, cb: (err: any, data?: DeleteLinkCommandOutput) => void): void;
67
+ /**
68
+ * <p>Deletes a sink. You must delete all links to a sink before you can delete that sink.</p>
69
+ */
70
+ deleteSink(args: DeleteSinkCommandInput, options?: __HttpHandlerOptions): Promise<DeleteSinkCommandOutput>;
71
+ deleteSink(args: DeleteSinkCommandInput, cb: (err: any, data?: DeleteSinkCommandOutput) => void): void;
72
+ deleteSink(args: DeleteSinkCommandInput, options: __HttpHandlerOptions, cb: (err: any, data?: DeleteSinkCommandOutput) => void): void;
73
+ /**
74
+ * <p>Returns complete information about one link.</p>
75
+ * <p>To use this operation, provide the link ARN. To retrieve a list of link ARNs, use <a href="https://docs.aws.amazon.com/OAM/latest/APIReference/API_ListLinks.html">ListLinks</a>.</p>
76
+ */
77
+ getLink(args: GetLinkCommandInput, options?: __HttpHandlerOptions): Promise<GetLinkCommandOutput>;
78
+ getLink(args: GetLinkCommandInput, cb: (err: any, data?: GetLinkCommandOutput) => void): void;
79
+ getLink(args: GetLinkCommandInput, options: __HttpHandlerOptions, cb: (err: any, data?: GetLinkCommandOutput) => void): void;
80
+ /**
81
+ * <p>Returns complete information about one monitoring account sink.</p>
82
+ * <p>To use this operation, provide the sink ARN. To retrieve a list of sink ARNs, use <a href="https://docs.aws.amazon.com/OAM/latest/APIReference/API_ListSinks.html">ListSinks</a>.</p>
83
+ */
84
+ getSink(args: GetSinkCommandInput, options?: __HttpHandlerOptions): Promise<GetSinkCommandOutput>;
85
+ getSink(args: GetSinkCommandInput, cb: (err: any, data?: GetSinkCommandOutput) => void): void;
86
+ getSink(args: GetSinkCommandInput, options: __HttpHandlerOptions, cb: (err: any, data?: GetSinkCommandOutput) => void): void;
87
+ /**
88
+ * <p>Returns the current sink policy attached to this sink. The sink policy specifies what
89
+ * accounts can attach to this sink as source accounts, and what types of data they can share.</p>
90
+ */
91
+ getSinkPolicy(args: GetSinkPolicyCommandInput, options?: __HttpHandlerOptions): Promise<GetSinkPolicyCommandOutput>;
92
+ getSinkPolicy(args: GetSinkPolicyCommandInput, cb: (err: any, data?: GetSinkPolicyCommandOutput) => void): void;
93
+ getSinkPolicy(args: GetSinkPolicyCommandInput, options: __HttpHandlerOptions, cb: (err: any, data?: GetSinkPolicyCommandOutput) => void): void;
94
+ /**
95
+ * <p>Returns a list of source account links that are linked to this monitoring account sink.</p>
96
+ * <p>To use this operation, provide the sink ARN. To retrieve a list of sink ARNs, use <a href="https://docs.aws.amazon.com/OAM/latest/APIReference/API_ListSinks.html">ListSinks</a>.</p>
97
+ * <p>To find a list of links for one source account, use <a href="https://docs.aws.amazon.com/OAM/latest/APIReference/API_ListLinks.html">ListLinks</a>.</p>
98
+ */
99
+ listAttachedLinks(args: ListAttachedLinksCommandInput, options?: __HttpHandlerOptions): Promise<ListAttachedLinksCommandOutput>;
100
+ listAttachedLinks(args: ListAttachedLinksCommandInput, cb: (err: any, data?: ListAttachedLinksCommandOutput) => void): void;
101
+ listAttachedLinks(args: ListAttachedLinksCommandInput, options: __HttpHandlerOptions, cb: (err: any, data?: ListAttachedLinksCommandOutput) => void): void;
102
+ /**
103
+ * <p>Use this operation in a source account to return a list of links to monitoring account sinks that
104
+ * this source account has.</p>
105
+ * <p>To find a list of links for one monitoring account sink, use <a href="https://docs.aws.amazon.com/OAM/latest/APIReference/API_ListAttachedLinks.html">ListAttachedLinks</a> from within the monitoring account.</p>
106
+ */
107
+ listLinks(args: ListLinksCommandInput, options?: __HttpHandlerOptions): Promise<ListLinksCommandOutput>;
108
+ listLinks(args: ListLinksCommandInput, cb: (err: any, data?: ListLinksCommandOutput) => void): void;
109
+ listLinks(args: ListLinksCommandInput, options: __HttpHandlerOptions, cb: (err: any, data?: ListLinksCommandOutput) => void): void;
110
+ /**
111
+ * <p>Use this operation in a monitoring account to return the list of sinks created in that account.</p>
112
+ */
113
+ listSinks(args: ListSinksCommandInput, options?: __HttpHandlerOptions): Promise<ListSinksCommandOutput>;
114
+ listSinks(args: ListSinksCommandInput, cb: (err: any, data?: ListSinksCommandOutput) => void): void;
115
+ listSinks(args: ListSinksCommandInput, options: __HttpHandlerOptions, cb: (err: any, data?: ListSinksCommandOutput) => void): void;
116
+ /**
117
+ * <p>Displays the tags associated with a resource. Both sinks and links support tagging.</p>
118
+ */
119
+ listTagsForResource(args: ListTagsForResourceCommandInput, options?: __HttpHandlerOptions): Promise<ListTagsForResourceCommandOutput>;
120
+ listTagsForResource(args: ListTagsForResourceCommandInput, cb: (err: any, data?: ListTagsForResourceCommandOutput) => void): void;
121
+ listTagsForResource(args: ListTagsForResourceCommandInput, options: __HttpHandlerOptions, cb: (err: any, data?: ListTagsForResourceCommandOutput) => void): void;
122
+ /**
123
+ * <p>Creates or updates the resource policy that grants permissions to source
124
+ * accounts to link to the monitoring account sink. When you create a sink policy, you can grant
125
+ * permissions to all accounts in an organization or to individual accounts.</p>
126
+ * <p>You can also use a sink policy to limit the types of data that is shared. The three types that
127
+ * you can allow or deny are:</p>
128
+ * <ul>
129
+ * <li>
130
+ * <p>
131
+ * <b>Metrics</b> - Specify with
132
+ * <code>AWS::CloudWatch::Metric</code>
133
+ * </p>
134
+ * </li>
135
+ * <li>
136
+ * <p>
137
+ * <b>Log groups</b> - Specify with <code>AWS::Logs::LogGroup</code>
138
+ * </p>
139
+ * </li>
140
+ * <li>
141
+ * <p>
142
+ * <b>Traces</b> - Specify with <code>AWS::XRay::Trace</code>
143
+ * </p>
144
+ * </li>
145
+ * </ul>
146
+ * <p>See the examples in this section to see how to specify permitted source accounts and data types.</p>
147
+ */
148
+ putSinkPolicy(args: PutSinkPolicyCommandInput, options?: __HttpHandlerOptions): Promise<PutSinkPolicyCommandOutput>;
149
+ putSinkPolicy(args: PutSinkPolicyCommandInput, cb: (err: any, data?: PutSinkPolicyCommandOutput) => void): void;
150
+ putSinkPolicy(args: PutSinkPolicyCommandInput, options: __HttpHandlerOptions, cb: (err: any, data?: PutSinkPolicyCommandOutput) => void): void;
151
+ /**
152
+ * <p>Assigns one or more tags (key-value pairs) to the specified resource.
153
+ * Both sinks and links can be tagged. </p>
154
+ * <p>Tags can help you organize and categorize your resources. You can also use them to scope user
155
+ * permissions by granting a user
156
+ * permission to access or change only resources with certain tag values.</p>
157
+ * <p>Tags don't have any semantic meaning to Amazon Web Services and are interpreted strictly as strings of characters.</p>
158
+ * <p>You can use the <code>TagResource</code> action with a resource that already has tags. If you specify a new tag key for the alarm,
159
+ * this tag is appended to the list of tags associated
160
+ * with the alarm. If you specify a tag key that is already associated with the alarm, the new tag value that you specify replaces
161
+ * the previous value for that tag.</p>
162
+ * <p>You can associate as many as 50 tags with a resource.</p>
163
+ * <important>
164
+ * <p>Unlike tagging permissions in other Amazon Web Services services, to tag or untag links and
165
+ * sinks you must have the <code>oam:ResourceTag</code> permission. The
166
+ * <code>iam:ResourceTag</code> permission does not allow you to tag and untag links and
167
+ * sinks.</p>
168
+ * </important>
169
+ */
170
+ tagResource(args: TagResourceCommandInput, options?: __HttpHandlerOptions): Promise<TagResourceCommandOutput>;
171
+ tagResource(args: TagResourceCommandInput, cb: (err: any, data?: TagResourceCommandOutput) => void): void;
172
+ tagResource(args: TagResourceCommandInput, options: __HttpHandlerOptions, cb: (err: any, data?: TagResourceCommandOutput) => void): void;
173
+ /**
174
+ * <p>Removes one or more tags from the specified resource.</p>
175
+ * <important>
176
+ * <p>Unlike tagging permissions in other Amazon Web Services services, to tag or untag links and
177
+ * sinks you must have the <code>oam:ResourceTag</code> permission. The
178
+ * <code>iam:TagResource</code> permission does not allow you to tag and untag links and
179
+ * sinks.</p>
180
+ * </important>
181
+ */
182
+ untagResource(args: UntagResourceCommandInput, options?: __HttpHandlerOptions): Promise<UntagResourceCommandOutput>;
183
+ untagResource(args: UntagResourceCommandInput, cb: (err: any, data?: UntagResourceCommandOutput) => void): void;
184
+ untagResource(args: UntagResourceCommandInput, options: __HttpHandlerOptions, cb: (err: any, data?: UntagResourceCommandOutput) => void): void;
185
+ /**
186
+ * <p>Use this operation to change what types of data are shared from a source account to its linked
187
+ * monitoring account sink. You can't change the sink or change the monitoring account with this operation.</p>
188
+ * <p>To update the list of tags associated with the sink, use
189
+ * <a href="https://docs.aws.amazon.com/OAM/latest/APIReference/API_TagResource.html">TagResource</a>.</p>
190
+ */
191
+ updateLink(args: UpdateLinkCommandInput, options?: __HttpHandlerOptions): Promise<UpdateLinkCommandOutput>;
192
+ updateLink(args: UpdateLinkCommandInput, cb: (err: any, data?: UpdateLinkCommandOutput) => void): void;
193
+ updateLink(args: UpdateLinkCommandInput, options: __HttpHandlerOptions, cb: (err: any, data?: UpdateLinkCommandOutput) => void): void;
194
+ }
@@ -0,0 +1,167 @@
1
+ import { RegionInputConfig, RegionResolvedConfig } from "@aws-sdk/config-resolver";
2
+ import { EndpointInputConfig, EndpointResolvedConfig } from "@aws-sdk/middleware-endpoint";
3
+ import { HostHeaderInputConfig, HostHeaderResolvedConfig } from "@aws-sdk/middleware-host-header";
4
+ import { RetryInputConfig, RetryResolvedConfig } from "@aws-sdk/middleware-retry";
5
+ import { AwsAuthInputConfig, AwsAuthResolvedConfig } from "@aws-sdk/middleware-signing";
6
+ import { UserAgentInputConfig, UserAgentResolvedConfig } from "@aws-sdk/middleware-user-agent";
7
+ import { HttpHandler as __HttpHandler } from "@aws-sdk/protocol-http";
8
+ import { Client as __Client, DefaultsMode, SmithyConfiguration as __SmithyConfiguration, SmithyResolvedConfiguration as __SmithyResolvedConfiguration } from "@aws-sdk/smithy-client";
9
+ import { BodyLengthCalculator as __BodyLengthCalculator, Credentials as __Credentials, Decoder as __Decoder, Encoder as __Encoder, HashConstructor as __HashConstructor, HttpHandlerOptions as __HttpHandlerOptions, Logger as __Logger, Provider as __Provider, Provider, StreamCollector as __StreamCollector, UrlParser as __UrlParser, UserAgent as __UserAgent } from "@aws-sdk/types";
10
+ import { CreateLinkCommandInput, CreateLinkCommandOutput } from "./commands/CreateLinkCommand";
11
+ import { CreateSinkCommandInput, CreateSinkCommandOutput } from "./commands/CreateSinkCommand";
12
+ import { DeleteLinkCommandInput, DeleteLinkCommandOutput } from "./commands/DeleteLinkCommand";
13
+ import { DeleteSinkCommandInput, DeleteSinkCommandOutput } from "./commands/DeleteSinkCommand";
14
+ import { GetLinkCommandInput, GetLinkCommandOutput } from "./commands/GetLinkCommand";
15
+ import { GetSinkCommandInput, GetSinkCommandOutput } from "./commands/GetSinkCommand";
16
+ import { GetSinkPolicyCommandInput, GetSinkPolicyCommandOutput } from "./commands/GetSinkPolicyCommand";
17
+ import { ListAttachedLinksCommandInput, ListAttachedLinksCommandOutput } from "./commands/ListAttachedLinksCommand";
18
+ import { ListLinksCommandInput, ListLinksCommandOutput } from "./commands/ListLinksCommand";
19
+ import { ListSinksCommandInput, ListSinksCommandOutput } from "./commands/ListSinksCommand";
20
+ import { ListTagsForResourceCommandInput, ListTagsForResourceCommandOutput } from "./commands/ListTagsForResourceCommand";
21
+ import { PutSinkPolicyCommandInput, PutSinkPolicyCommandOutput } from "./commands/PutSinkPolicyCommand";
22
+ import { TagResourceCommandInput, TagResourceCommandOutput } from "./commands/TagResourceCommand";
23
+ import { UntagResourceCommandInput, UntagResourceCommandOutput } from "./commands/UntagResourceCommand";
24
+ import { UpdateLinkCommandInput, UpdateLinkCommandOutput } from "./commands/UpdateLinkCommand";
25
+ import { ClientInputEndpointParameters, ClientResolvedEndpointParameters, EndpointParameters } from "./endpoint/EndpointParameters";
26
+ export declare type ServiceInputTypes = CreateLinkCommandInput | CreateSinkCommandInput | DeleteLinkCommandInput | DeleteSinkCommandInput | GetLinkCommandInput | GetSinkCommandInput | GetSinkPolicyCommandInput | ListAttachedLinksCommandInput | ListLinksCommandInput | ListSinksCommandInput | ListTagsForResourceCommandInput | PutSinkPolicyCommandInput | TagResourceCommandInput | UntagResourceCommandInput | UpdateLinkCommandInput;
27
+ export declare type ServiceOutputTypes = CreateLinkCommandOutput | CreateSinkCommandOutput | DeleteLinkCommandOutput | DeleteSinkCommandOutput | GetLinkCommandOutput | GetSinkCommandOutput | GetSinkPolicyCommandOutput | ListAttachedLinksCommandOutput | ListLinksCommandOutput | ListSinksCommandOutput | ListTagsForResourceCommandOutput | PutSinkPolicyCommandOutput | TagResourceCommandOutput | UntagResourceCommandOutput | UpdateLinkCommandOutput;
28
+ export interface ClientDefaults extends Partial<__SmithyResolvedConfiguration<__HttpHandlerOptions>> {
29
+ /**
30
+ * The HTTP handler to use. Fetch in browser and Https in Nodejs.
31
+ */
32
+ requestHandler?: __HttpHandler;
33
+ /**
34
+ * A constructor for a class implementing the {@link __Hash} interface
35
+ * that computes the SHA-256 HMAC or checksum of a string or binary buffer.
36
+ * @internal
37
+ */
38
+ sha256?: __HashConstructor;
39
+ /**
40
+ * The function that will be used to convert strings into HTTP endpoints.
41
+ * @internal
42
+ */
43
+ urlParser?: __UrlParser;
44
+ /**
45
+ * A function that can calculate the length of a request body.
46
+ * @internal
47
+ */
48
+ bodyLengthChecker?: __BodyLengthCalculator;
49
+ /**
50
+ * A function that converts a stream into an array of bytes.
51
+ * @internal
52
+ */
53
+ streamCollector?: __StreamCollector;
54
+ /**
55
+ * The function that will be used to convert a base64-encoded string to a byte array.
56
+ * @internal
57
+ */
58
+ base64Decoder?: __Decoder;
59
+ /**
60
+ * The function that will be used to convert binary data to a base64-encoded string.
61
+ * @internal
62
+ */
63
+ base64Encoder?: __Encoder;
64
+ /**
65
+ * The function that will be used to convert a UTF8-encoded string to a byte array.
66
+ * @internal
67
+ */
68
+ utf8Decoder?: __Decoder;
69
+ /**
70
+ * The function that will be used to convert binary data to a UTF-8 encoded string.
71
+ * @internal
72
+ */
73
+ utf8Encoder?: __Encoder;
74
+ /**
75
+ * The runtime environment.
76
+ * @internal
77
+ */
78
+ runtime?: string;
79
+ /**
80
+ * Disable dyanamically changing the endpoint of the client based on the hostPrefix
81
+ * trait of an operation.
82
+ */
83
+ disableHostPrefix?: boolean;
84
+ /**
85
+ * Value for how many times a request will be made at most in case of retry.
86
+ */
87
+ maxAttempts?: number | __Provider<number>;
88
+ /**
89
+ * Specifies which retry algorithm to use.
90
+ */
91
+ retryMode?: string | __Provider<string>;
92
+ /**
93
+ * Optional logger for logging debug/info/warn/error.
94
+ */
95
+ logger?: __Logger;
96
+ /**
97
+ * Enables IPv6/IPv4 dualstack endpoint.
98
+ */
99
+ useDualstackEndpoint?: boolean | __Provider<boolean>;
100
+ /**
101
+ * Enables FIPS compatible endpoints.
102
+ */
103
+ useFipsEndpoint?: boolean | __Provider<boolean>;
104
+ /**
105
+ * Unique service identifier.
106
+ * @internal
107
+ */
108
+ serviceId?: string;
109
+ /**
110
+ * The AWS region to which this client will send requests
111
+ */
112
+ region?: string | __Provider<string>;
113
+ /**
114
+ * Default credentials provider; Not available in browser runtime.
115
+ * @internal
116
+ */
117
+ credentialDefaultProvider?: (input: any) => __Provider<__Credentials>;
118
+ /**
119
+ * The provider populating default tracking information to be sent with `user-agent`, `x-amz-user-agent` header
120
+ * @internal
121
+ */
122
+ defaultUserAgentProvider?: Provider<__UserAgent>;
123
+ /**
124
+ * The {@link DefaultsMode} that will be used to determine how certain default configuration options are resolved in the SDK.
125
+ */
126
+ defaultsMode?: DefaultsMode | Provider<DefaultsMode>;
127
+ }
128
+ declare type OAMClientConfigType = Partial<__SmithyConfiguration<__HttpHandlerOptions>> & ClientDefaults & RegionInputConfig & EndpointInputConfig<EndpointParameters> & RetryInputConfig & HostHeaderInputConfig & AwsAuthInputConfig & UserAgentInputConfig & ClientInputEndpointParameters;
129
+ /**
130
+ * The configuration interface of OAMClient class constructor that set the region, credentials and other options.
131
+ */
132
+ export interface OAMClientConfig extends OAMClientConfigType {
133
+ }
134
+ declare type OAMClientResolvedConfigType = __SmithyResolvedConfiguration<__HttpHandlerOptions> & Required<ClientDefaults> & RegionResolvedConfig & EndpointResolvedConfig<EndpointParameters> & RetryResolvedConfig & HostHeaderResolvedConfig & AwsAuthResolvedConfig & UserAgentResolvedConfig & ClientResolvedEndpointParameters;
135
+ /**
136
+ * The resolved configuration interface of OAMClient class. This is resolved and normalized from the {@link OAMClientConfig | constructor configuration interface}.
137
+ */
138
+ export interface OAMClientResolvedConfig extends OAMClientResolvedConfigType {
139
+ }
140
+ /**
141
+ * <p>Use Amazon CloudWatch Observability Access Manager to create and manage links between source accounts and
142
+ * monitoring accounts by using <i>CloudWatch cross-account observability</i>. With
143
+ * CloudWatch cross-account observability, you can monitor and troubleshoot applications that span
144
+ * multiple accounts within a Region. Seamlessly search, visualize, and analyze your metrics,
145
+ * logs, and traces in any of the linked accounts without account boundaries.</p>
146
+ *
147
+ * <p>Set up one or more Amazon Web Services accounts as <i>monitoring
148
+ * accounts</i> and link them with multiple <i>source accounts</i>. A
149
+ * monitoring account is a central Amazon Web Services account that can view and interact with
150
+ * observability data generated from source accounts. A source account is an individual Amazon Web Services account that generates observability data for the resources that reside in it.
151
+ * Source accounts share their observability data with the monitoring account. The shared
152
+ * observability data can include metrics in Amazon CloudWatch, logs in Amazon CloudWatch Logs, and traces in X-Ray.</p>
153
+ */
154
+ export declare class OAMClient extends __Client<__HttpHandlerOptions, ServiceInputTypes, ServiceOutputTypes, OAMClientResolvedConfig> {
155
+ /**
156
+ * The resolved configuration of OAMClient class. This is resolved and normalized from the {@link OAMClientConfig | constructor configuration interface}.
157
+ */
158
+ readonly config: OAMClientResolvedConfig;
159
+ constructor(configuration: OAMClientConfig);
160
+ /**
161
+ * Destroy underlying resources, like sockets. It's usually not necessary to do this.
162
+ * However in Node.js, it's best to explicitly shut down the client's agent when it is no longer needed.
163
+ * Otherwise, sockets might stay open for quite a long time before the server terminates them.
164
+ */
165
+ destroy(): void;
166
+ }
167
+ export {};
@@ -0,0 +1,46 @@
1
+ import { EndpointParameterInstructions } from "@aws-sdk/middleware-endpoint";
2
+ import { Command as $Command } from "@aws-sdk/smithy-client";
3
+ import { Handler, HttpHandlerOptions as __HttpHandlerOptions, MetadataBearer as __MetadataBearer, MiddlewareStack } from "@aws-sdk/types";
4
+ import { CreateLinkInput, CreateLinkOutput } from "../models/models_0";
5
+ import { OAMClientResolvedConfig, ServiceInputTypes, ServiceOutputTypes } from "../OAMClient";
6
+ export interface CreateLinkCommandInput extends CreateLinkInput {
7
+ }
8
+ export interface CreateLinkCommandOutput extends CreateLinkOutput, __MetadataBearer {
9
+ }
10
+ /**
11
+ * <p>Creates a link between a source account and a sink that you have created in a monitoring account.</p>
12
+ * <p>Before you create a link, you must create a sink in the monitoring account and create a
13
+ * sink policy in that account. The sink policy must permit the source account to link to it. You
14
+ * can grant permission to source accounts by granting permission to an entire organization or to
15
+ * individual accounts.</p>
16
+ * <p>For more information, see
17
+ * <a href="https://docs.aws.amazon.com/OAM/latest/APIReference/API_CreateSink.html">CreateSink</a> and
18
+ * <a href="https://docs.aws.amazon.com/OAM/latest/APIReference/API_PutSinkPolicy.html">PutSinkPolicy</a>.</p>
19
+ * <p>Each monitoring account can be linked to as many as 100,000 source accounts.</p>
20
+ * <p>Each source account can be linked to as many as five monitoring accounts.</p>
21
+ * @example
22
+ * Use a bare-bones client and the command you need to make an API call.
23
+ * ```javascript
24
+ * import { OAMClient, CreateLinkCommand } from "@aws-sdk/client-oam"; // ES Modules import
25
+ * // const { OAMClient, CreateLinkCommand } = require("@aws-sdk/client-oam"); // CommonJS import
26
+ * const client = new OAMClient(config);
27
+ * const command = new CreateLinkCommand(input);
28
+ * const response = await client.send(command);
29
+ * ```
30
+ *
31
+ * @see {@link CreateLinkCommandInput} for command's `input` shape.
32
+ * @see {@link CreateLinkCommandOutput} for command's `response` shape.
33
+ * @see {@link OAMClientResolvedConfig | config} for OAMClient's `config` shape.
34
+ *
35
+ */
36
+ export declare class CreateLinkCommand extends $Command<CreateLinkCommandInput, CreateLinkCommandOutput, OAMClientResolvedConfig> {
37
+ readonly input: CreateLinkCommandInput;
38
+ static getEndpointParameterInstructions(): EndpointParameterInstructions;
39
+ constructor(input: CreateLinkCommandInput);
40
+ /**
41
+ * @internal
42
+ */
43
+ resolveMiddleware(clientStack: MiddlewareStack<ServiceInputTypes, ServiceOutputTypes>, configuration: OAMClientResolvedConfig, options?: __HttpHandlerOptions): Handler<CreateLinkCommandInput, CreateLinkCommandOutput>;
44
+ private serialize;
45
+ private deserialize;
46
+ }
@@ -0,0 +1,43 @@
1
+ import { EndpointParameterInstructions } from "@aws-sdk/middleware-endpoint";
2
+ import { Command as $Command } from "@aws-sdk/smithy-client";
3
+ import { Handler, HttpHandlerOptions as __HttpHandlerOptions, MetadataBearer as __MetadataBearer, MiddlewareStack } from "@aws-sdk/types";
4
+ import { CreateSinkInput, CreateSinkOutput } from "../models/models_0";
5
+ import { OAMClientResolvedConfig, ServiceInputTypes, ServiceOutputTypes } from "../OAMClient";
6
+ export interface CreateSinkCommandInput extends CreateSinkInput {
7
+ }
8
+ export interface CreateSinkCommandOutput extends CreateSinkOutput, __MetadataBearer {
9
+ }
10
+ /**
11
+ * <p>Use this to create a <i>sink</i> in the current account, so that it can be
12
+ * used as a monitoring account in CloudWatch cross-account observability. A sink is a resource that
13
+ * represents an attachment point in a monitoring account. Source accounts can link to the sink
14
+ * to send observability data.</p>
15
+ * <p>After you create a sink, you must create a sink policy that allows source accounts to attach to it.
16
+ * For more information, see <a href="https://docs.aws.amazon.com/OAM/latest/APIReference/API_PutSinkPolicy.html">PutSinkPolicy</a>.</p>
17
+ * <p>Each account can contain one sink. If you delete a sink, you can then create a new one in that account.</p>
18
+ * @example
19
+ * Use a bare-bones client and the command you need to make an API call.
20
+ * ```javascript
21
+ * import { OAMClient, CreateSinkCommand } from "@aws-sdk/client-oam"; // ES Modules import
22
+ * // const { OAMClient, CreateSinkCommand } = require("@aws-sdk/client-oam"); // CommonJS import
23
+ * const client = new OAMClient(config);
24
+ * const command = new CreateSinkCommand(input);
25
+ * const response = await client.send(command);
26
+ * ```
27
+ *
28
+ * @see {@link CreateSinkCommandInput} for command's `input` shape.
29
+ * @see {@link CreateSinkCommandOutput} for command's `response` shape.
30
+ * @see {@link OAMClientResolvedConfig | config} for OAMClient's `config` shape.
31
+ *
32
+ */
33
+ export declare class CreateSinkCommand extends $Command<CreateSinkCommandInput, CreateSinkCommandOutput, OAMClientResolvedConfig> {
34
+ readonly input: CreateSinkCommandInput;
35
+ static getEndpointParameterInstructions(): EndpointParameterInstructions;
36
+ constructor(input: CreateSinkCommandInput);
37
+ /**
38
+ * @internal
39
+ */
40
+ resolveMiddleware(clientStack: MiddlewareStack<ServiceInputTypes, ServiceOutputTypes>, configuration: OAMClientResolvedConfig, options?: __HttpHandlerOptions): Handler<CreateSinkCommandInput, CreateSinkCommandOutput>;
41
+ private serialize;
42
+ private deserialize;
43
+ }
@@ -0,0 +1,38 @@
1
+ import { EndpointParameterInstructions } from "@aws-sdk/middleware-endpoint";
2
+ import { Command as $Command } from "@aws-sdk/smithy-client";
3
+ import { Handler, HttpHandlerOptions as __HttpHandlerOptions, MetadataBearer as __MetadataBearer, MiddlewareStack } from "@aws-sdk/types";
4
+ import { DeleteLinkInput, DeleteLinkOutput } from "../models/models_0";
5
+ import { OAMClientResolvedConfig, ServiceInputTypes, ServiceOutputTypes } from "../OAMClient";
6
+ export interface DeleteLinkCommandInput extends DeleteLinkInput {
7
+ }
8
+ export interface DeleteLinkCommandOutput extends DeleteLinkOutput, __MetadataBearer {
9
+ }
10
+ /**
11
+ * <p>Deletes a link between a monitoring account sink and a source account. You must run this operation
12
+ * in the source account.</p>
13
+ * @example
14
+ * Use a bare-bones client and the command you need to make an API call.
15
+ * ```javascript
16
+ * import { OAMClient, DeleteLinkCommand } from "@aws-sdk/client-oam"; // ES Modules import
17
+ * // const { OAMClient, DeleteLinkCommand } = require("@aws-sdk/client-oam"); // CommonJS import
18
+ * const client = new OAMClient(config);
19
+ * const command = new DeleteLinkCommand(input);
20
+ * const response = await client.send(command);
21
+ * ```
22
+ *
23
+ * @see {@link DeleteLinkCommandInput} for command's `input` shape.
24
+ * @see {@link DeleteLinkCommandOutput} for command's `response` shape.
25
+ * @see {@link OAMClientResolvedConfig | config} for OAMClient's `config` shape.
26
+ *
27
+ */
28
+ export declare class DeleteLinkCommand extends $Command<DeleteLinkCommandInput, DeleteLinkCommandOutput, OAMClientResolvedConfig> {
29
+ readonly input: DeleteLinkCommandInput;
30
+ static getEndpointParameterInstructions(): EndpointParameterInstructions;
31
+ constructor(input: DeleteLinkCommandInput);
32
+ /**
33
+ * @internal
34
+ */
35
+ resolveMiddleware(clientStack: MiddlewareStack<ServiceInputTypes, ServiceOutputTypes>, configuration: OAMClientResolvedConfig, options?: __HttpHandlerOptions): Handler<DeleteLinkCommandInput, DeleteLinkCommandOutput>;
36
+ private serialize;
37
+ private deserialize;
38
+ }