@aws-sdk/client-opensearchmemory 0.0.0-stage → 3.1170.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 (157) hide show
  1. package/LICENSE +201 -0
  2. package/README.md +320 -2
  3. package/dist-cjs/index.js +1550 -0
  4. package/dist-es/OpenSearchMemory.js +65 -0
  5. package/dist-es/OpenSearchMemoryClient.js +47 -0
  6. package/dist-es/auth/httpAuthExtensionConfiguration.js +38 -0
  7. package/dist-es/auth/httpAuthSchemeProvider.js +40 -0
  8. package/dist-es/commandBuilder.js +9 -0
  9. package/dist-es/commands/BatchGetEventCommand.js +4 -0
  10. package/dist-es/commands/CreateEventCommand.js +4 -0
  11. package/dist-es/commands/CreateMemoryCommand.js +4 -0
  12. package/dist-es/commands/CreateSpaceCommand.js +4 -0
  13. package/dist-es/commands/DeleteEventCommand.js +4 -0
  14. package/dist-es/commands/DeleteMemoryCommand.js +4 -0
  15. package/dist-es/commands/DeleteSpaceCommand.js +4 -0
  16. package/dist-es/commands/GetEventCommand.js +4 -0
  17. package/dist-es/commands/GetMemoryCommand.js +4 -0
  18. package/dist-es/commands/GetSpaceCommand.js +4 -0
  19. package/dist-es/commands/ListEventsCommand.js +4 -0
  20. package/dist-es/commands/ListMemoriesCommand.js +4 -0
  21. package/dist-es/commands/ListSpacesCommand.js +4 -0
  22. package/dist-es/commands/ListTagsForResourceCommand.js +4 -0
  23. package/dist-es/commands/SearchEventsCommand.js +4 -0
  24. package/dist-es/commands/SearchMemoriesCommand.js +4 -0
  25. package/dist-es/commands/TagResourceCommand.js +4 -0
  26. package/dist-es/commands/UntagResourceCommand.js +4 -0
  27. package/dist-es/commands/UpdateMemoryCommand.js +4 -0
  28. package/dist-es/commands/UpdateSpaceCommand.js +4 -0
  29. package/dist-es/commands/index.js +20 -0
  30. package/dist-es/endpoint/EndpointParameters.js +11 -0
  31. package/dist-es/endpoint/bdd.js +33 -0
  32. package/dist-es/endpoint/endpointResolver.js +14 -0
  33. package/dist-es/extensionConfiguration.js +1 -0
  34. package/dist-es/index.js +11 -0
  35. package/dist-es/models/OpenSearchMemoryServiceException.js +9 -0
  36. package/dist-es/models/enums.js +61 -0
  37. package/dist-es/models/errors.js +114 -0
  38. package/dist-es/models/models_0.js +1 -0
  39. package/dist-es/pagination/Interfaces.js +1 -0
  40. package/dist-es/pagination/ListEventsPaginator.js +4 -0
  41. package/dist-es/pagination/ListMemoriesPaginator.js +4 -0
  42. package/dist-es/pagination/ListSpacesPaginator.js +4 -0
  43. package/dist-es/pagination/SearchEventsPaginator.js +4 -0
  44. package/dist-es/pagination/SearchMemoriesPaginator.js +4 -0
  45. package/dist-es/pagination/index.js +6 -0
  46. package/dist-es/runtimeConfig.browser.js +29 -0
  47. package/dist-es/runtimeConfig.js +44 -0
  48. package/dist-es/runtimeConfig.native.js +9 -0
  49. package/dist-es/runtimeConfig.shared.js +40 -0
  50. package/dist-es/runtimeExtensions.js +9 -0
  51. package/dist-es/schemas/schemas_0.js +720 -0
  52. package/dist-es/waiters/index.js +2 -0
  53. package/dist-es/waiters/waitForSpaceActive.js +79 -0
  54. package/dist-es/waiters/waitForSpaceDeleted.js +52 -0
  55. package/dist-types/OpenSearchMemory.d.ts +206 -0
  56. package/dist-types/OpenSearchMemoryClient.d.ts +207 -0
  57. package/dist-types/auth/httpAuthExtensionConfiguration.d.ts +29 -0
  58. package/dist-types/auth/httpAuthSchemeProvider.d.ts +75 -0
  59. package/dist-types/commandBuilder.d.ts +22 -0
  60. package/dist-types/commands/BatchGetEventCommand.d.ts +140 -0
  61. package/dist-types/commands/CreateEventCommand.d.ts +134 -0
  62. package/dist-types/commands/CreateMemoryCommand.d.ts +103 -0
  63. package/dist-types/commands/CreateSpaceCommand.d.ts +122 -0
  64. package/dist-types/commands/DeleteEventCommand.d.ts +89 -0
  65. package/dist-types/commands/DeleteMemoryCommand.d.ts +89 -0
  66. package/dist-types/commands/DeleteSpaceCommand.d.ts +90 -0
  67. package/dist-types/commands/GetEventCommand.d.ts +129 -0
  68. package/dist-types/commands/GetMemoryCommand.d.ts +103 -0
  69. package/dist-types/commands/GetSpaceCommand.d.ts +113 -0
  70. package/dist-types/commands/ListEventsCommand.d.ts +105 -0
  71. package/dist-types/commands/ListMemoriesCommand.d.ts +120 -0
  72. package/dist-types/commands/ListSpacesCommand.d.ts +93 -0
  73. package/dist-types/commands/ListTagsForResourceCommand.d.ts +91 -0
  74. package/dist-types/commands/SearchEventsCommand.d.ts +110 -0
  75. package/dist-types/commands/SearchMemoriesCommand.d.ts +120 -0
  76. package/dist-types/commands/TagResourceCommand.d.ts +90 -0
  77. package/dist-types/commands/UntagResourceCommand.d.ts +87 -0
  78. package/dist-types/commands/UpdateMemoryCommand.d.ts +111 -0
  79. package/dist-types/commands/UpdateSpaceCommand.d.ts +112 -0
  80. package/dist-types/commands/index.d.ts +20 -0
  81. package/dist-types/endpoint/EndpointParameters.d.ts +45 -0
  82. package/dist-types/endpoint/bdd.d.ts +2 -0
  83. package/dist-types/endpoint/endpointResolver.d.ts +8 -0
  84. package/dist-types/extensionConfiguration.d.ts +9 -0
  85. package/dist-types/index.d.ts +19 -0
  86. package/dist-types/models/OpenSearchMemoryServiceException.d.ts +15 -0
  87. package/dist-types/models/enums.d.ts +258 -0
  88. package/dist-types/models/errors.d.ts +144 -0
  89. package/dist-types/models/models_0.d.ts +1629 -0
  90. package/dist-types/pagination/Interfaces.d.ts +8 -0
  91. package/dist-types/pagination/ListEventsPaginator.d.ts +7 -0
  92. package/dist-types/pagination/ListMemoriesPaginator.d.ts +7 -0
  93. package/dist-types/pagination/ListSpacesPaginator.d.ts +7 -0
  94. package/dist-types/pagination/SearchEventsPaginator.d.ts +7 -0
  95. package/dist-types/pagination/SearchMemoriesPaginator.d.ts +7 -0
  96. package/dist-types/pagination/index.d.ts +6 -0
  97. package/dist-types/runtimeConfig.browser.d.ts +57 -0
  98. package/dist-types/runtimeConfig.d.ts +58 -0
  99. package/dist-types/runtimeConfig.native.d.ts +56 -0
  100. package/dist-types/runtimeConfig.shared.d.ts +28 -0
  101. package/dist-types/runtimeExtensions.d.ts +17 -0
  102. package/dist-types/schemas/schemas_0.d.ts +105 -0
  103. package/dist-types/ts3.4/OpenSearchMemory.d.ts +371 -0
  104. package/dist-types/ts3.4/OpenSearchMemoryClient.d.ts +190 -0
  105. package/dist-types/ts3.4/auth/httpAuthExtensionConfiguration.d.ts +25 -0
  106. package/dist-types/ts3.4/auth/httpAuthSchemeProvider.d.ts +43 -0
  107. package/dist-types/ts3.4/commandBuilder.d.ts +41 -0
  108. package/dist-types/ts3.4/commands/BatchGetEventCommand.d.ts +38 -0
  109. package/dist-types/ts3.4/commands/CreateEventCommand.d.ts +38 -0
  110. package/dist-types/ts3.4/commands/CreateMemoryCommand.d.ts +38 -0
  111. package/dist-types/ts3.4/commands/CreateSpaceCommand.d.ts +38 -0
  112. package/dist-types/ts3.4/commands/DeleteEventCommand.d.ts +38 -0
  113. package/dist-types/ts3.4/commands/DeleteMemoryCommand.d.ts +38 -0
  114. package/dist-types/ts3.4/commands/DeleteSpaceCommand.d.ts +38 -0
  115. package/dist-types/ts3.4/commands/GetEventCommand.d.ts +38 -0
  116. package/dist-types/ts3.4/commands/GetMemoryCommand.d.ts +38 -0
  117. package/dist-types/ts3.4/commands/GetSpaceCommand.d.ts +38 -0
  118. package/dist-types/ts3.4/commands/ListEventsCommand.d.ts +38 -0
  119. package/dist-types/ts3.4/commands/ListMemoriesCommand.d.ts +38 -0
  120. package/dist-types/ts3.4/commands/ListSpacesCommand.d.ts +38 -0
  121. package/dist-types/ts3.4/commands/ListTagsForResourceCommand.d.ts +39 -0
  122. package/dist-types/ts3.4/commands/SearchEventsCommand.d.ts +38 -0
  123. package/dist-types/ts3.4/commands/SearchMemoriesCommand.d.ts +38 -0
  124. package/dist-types/ts3.4/commands/TagResourceCommand.d.ts +38 -0
  125. package/dist-types/ts3.4/commands/UntagResourceCommand.d.ts +38 -0
  126. package/dist-types/ts3.4/commands/UpdateMemoryCommand.d.ts +38 -0
  127. package/dist-types/ts3.4/commands/UpdateSpaceCommand.d.ts +38 -0
  128. package/dist-types/ts3.4/commands/index.d.ts +20 -0
  129. package/dist-types/ts3.4/endpoint/EndpointParameters.d.ts +46 -0
  130. package/dist-types/ts3.4/endpoint/bdd.d.ts +2 -0
  131. package/dist-types/ts3.4/endpoint/endpointResolver.d.ts +8 -0
  132. package/dist-types/ts3.4/extensionConfiguration.d.ts +10 -0
  133. package/dist-types/ts3.4/index.d.ts +14 -0
  134. package/dist-types/ts3.4/models/OpenSearchMemoryServiceException.d.ts +10 -0
  135. package/dist-types/ts3.4/models/enums.d.ts +73 -0
  136. package/dist-types/ts3.4/models/errors.d.ts +59 -0
  137. package/dist-types/ts3.4/models/models_0.d.ts +459 -0
  138. package/dist-types/ts3.4/pagination/Interfaces.d.ts +5 -0
  139. package/dist-types/ts3.4/pagination/ListEventsPaginator.d.ts +8 -0
  140. package/dist-types/ts3.4/pagination/ListMemoriesPaginator.d.ts +11 -0
  141. package/dist-types/ts3.4/pagination/ListSpacesPaginator.d.ts +8 -0
  142. package/dist-types/ts3.4/pagination/SearchEventsPaginator.d.ts +11 -0
  143. package/dist-types/ts3.4/pagination/SearchMemoriesPaginator.d.ts +11 -0
  144. package/dist-types/ts3.4/pagination/index.d.ts +6 -0
  145. package/dist-types/ts3.4/runtimeConfig.browser.d.ts +93 -0
  146. package/dist-types/ts3.4/runtimeConfig.d.ts +96 -0
  147. package/dist-types/ts3.4/runtimeConfig.native.d.ts +97 -0
  148. package/dist-types/ts3.4/runtimeConfig.shared.d.ts +31 -0
  149. package/dist-types/ts3.4/runtimeExtensions.d.ts +11 -0
  150. package/dist-types/ts3.4/schemas/schemas_0.d.ts +105 -0
  151. package/dist-types/ts3.4/waiters/index.d.ts +2 -0
  152. package/dist-types/ts3.4/waiters/waitForSpaceActive.d.ts +12 -0
  153. package/dist-types/ts3.4/waiters/waitForSpaceDeleted.d.ts +13 -0
  154. package/dist-types/waiters/index.d.ts +2 -0
  155. package/dist-types/waiters/waitForSpaceActive.d.ts +15 -0
  156. package/dist-types/waiters/waitForSpaceDeleted.d.ts +16 -0
  157. package/package.json +67 -4
@@ -0,0 +1,65 @@
1
+ import { createAggregatedClient } from "@smithy/core/client";
2
+ import { BatchGetEventCommand, } from "./commands/BatchGetEventCommand";
3
+ import { CreateEventCommand, } from "./commands/CreateEventCommand";
4
+ import { CreateMemoryCommand, } from "./commands/CreateMemoryCommand";
5
+ import { CreateSpaceCommand, } from "./commands/CreateSpaceCommand";
6
+ import { DeleteEventCommand, } from "./commands/DeleteEventCommand";
7
+ import { DeleteMemoryCommand, } from "./commands/DeleteMemoryCommand";
8
+ import { DeleteSpaceCommand, } from "./commands/DeleteSpaceCommand";
9
+ import { GetEventCommand } from "./commands/GetEventCommand";
10
+ import { GetMemoryCommand } from "./commands/GetMemoryCommand";
11
+ import { GetSpaceCommand } from "./commands/GetSpaceCommand";
12
+ import { ListEventsCommand, } from "./commands/ListEventsCommand";
13
+ import { ListMemoriesCommand, } from "./commands/ListMemoriesCommand";
14
+ import { ListSpacesCommand, } from "./commands/ListSpacesCommand";
15
+ import { ListTagsForResourceCommand, } from "./commands/ListTagsForResourceCommand";
16
+ import { SearchEventsCommand, } from "./commands/SearchEventsCommand";
17
+ import { SearchMemoriesCommand, } from "./commands/SearchMemoriesCommand";
18
+ import { TagResourceCommand, } from "./commands/TagResourceCommand";
19
+ import { UntagResourceCommand, } from "./commands/UntagResourceCommand";
20
+ import { UpdateMemoryCommand, } from "./commands/UpdateMemoryCommand";
21
+ import { UpdateSpaceCommand, } from "./commands/UpdateSpaceCommand";
22
+ import { OpenSearchMemoryClient } from "./OpenSearchMemoryClient";
23
+ import { paginateListEvents } from "./pagination/ListEventsPaginator";
24
+ import { paginateListMemories } from "./pagination/ListMemoriesPaginator";
25
+ import { paginateListSpaces } from "./pagination/ListSpacesPaginator";
26
+ import { paginateSearchEvents } from "./pagination/SearchEventsPaginator";
27
+ import { paginateSearchMemories } from "./pagination/SearchMemoriesPaginator";
28
+ import { waitUntilSpaceActive } from "./waiters/waitForSpaceActive";
29
+ import { waitUntilSpaceDeleted } from "./waiters/waitForSpaceDeleted";
30
+ const commands = {
31
+ BatchGetEventCommand,
32
+ CreateEventCommand,
33
+ CreateMemoryCommand,
34
+ CreateSpaceCommand,
35
+ DeleteEventCommand,
36
+ DeleteMemoryCommand,
37
+ DeleteSpaceCommand,
38
+ GetEventCommand,
39
+ GetMemoryCommand,
40
+ GetSpaceCommand,
41
+ ListEventsCommand,
42
+ ListMemoriesCommand,
43
+ ListSpacesCommand,
44
+ ListTagsForResourceCommand,
45
+ SearchEventsCommand,
46
+ SearchMemoriesCommand,
47
+ TagResourceCommand,
48
+ UntagResourceCommand,
49
+ UpdateMemoryCommand,
50
+ UpdateSpaceCommand,
51
+ };
52
+ const paginators = {
53
+ paginateListEvents,
54
+ paginateListMemories,
55
+ paginateListSpaces,
56
+ paginateSearchEvents,
57
+ paginateSearchMemories,
58
+ };
59
+ const waiters = {
60
+ waitUntilSpaceActive,
61
+ waitUntilSpaceDeleted,
62
+ };
63
+ export class OpenSearchMemory extends OpenSearchMemoryClient {
64
+ }
65
+ createAggregatedClient(commands, OpenSearchMemory, { paginators, waiters });
@@ -0,0 +1,47 @@
1
+ import { getHostHeaderPlugin, getLoggerPlugin, getRecursionDetectionPlugin, getUserAgentPlugin, resolveHostHeaderConfig, resolveUserAgentConfig, } from "@aws-sdk/core/client";
2
+ import { DefaultIdentityProviderConfig, getHttpAuthSchemeEndpointRuleSetPlugin, getHttpSigningPlugin, } from "@smithy/core";
3
+ import { Client as __Client, } from "@smithy/core/client";
4
+ import { resolveRegionConfig } from "@smithy/core/config";
5
+ import { resolveEndpointConfig } from "@smithy/core/endpoints";
6
+ import { getContentLengthPlugin } from "@smithy/core/protocols";
7
+ import { getRetryPlugin, resolveRetryConfig, } from "@smithy/core/retry";
8
+ import { getSchemaSerdePlugin } from "@smithy/core/schema";
9
+ import { defaultOpenSearchMemoryHttpAuthSchemeParametersProvider, resolveHttpAuthSchemeConfig, } from "./auth/httpAuthSchemeProvider";
10
+ import { resolveClientEndpointParameters, } from "./endpoint/EndpointParameters";
11
+ import { getRuntimeConfig as __getRuntimeConfig } from "./runtimeConfig";
12
+ import { resolveRuntimeExtensions } from "./runtimeExtensions";
13
+ export { __Client };
14
+ export class OpenSearchMemoryClient extends __Client {
15
+ config;
16
+ constructor(...[configuration]) {
17
+ const _config_0 = __getRuntimeConfig(configuration || {});
18
+ super(_config_0);
19
+ this.initConfig = _config_0;
20
+ const _config_1 = resolveClientEndpointParameters(_config_0);
21
+ const _config_2 = resolveUserAgentConfig(_config_1);
22
+ const _config_3 = resolveRetryConfig(_config_2);
23
+ const _config_4 = resolveRegionConfig(_config_3);
24
+ const _config_5 = resolveHostHeaderConfig(_config_4);
25
+ const _config_6 = resolveEndpointConfig(_config_5);
26
+ const _config_7 = resolveHttpAuthSchemeConfig(_config_6);
27
+ const _config_8 = resolveRuntimeExtensions(_config_7, configuration?.extensions || []);
28
+ this.config = _config_8;
29
+ this.middlewareStack.use(getSchemaSerdePlugin(this.config));
30
+ this.middlewareStack.use(getUserAgentPlugin(this.config));
31
+ this.middlewareStack.use(getRetryPlugin(this.config));
32
+ this.middlewareStack.use(getContentLengthPlugin(this.config));
33
+ this.middlewareStack.use(getHostHeaderPlugin(this.config));
34
+ this.middlewareStack.use(getLoggerPlugin(this.config));
35
+ this.middlewareStack.use(getRecursionDetectionPlugin(this.config));
36
+ this.middlewareStack.use(getHttpAuthSchemeEndpointRuleSetPlugin(this.config, {
37
+ httpAuthSchemeParametersProvider: defaultOpenSearchMemoryHttpAuthSchemeParametersProvider,
38
+ identityProviderConfigProvider: async (config) => new DefaultIdentityProviderConfig({
39
+ "aws.auth#sigv4": config.credentials,
40
+ }),
41
+ }));
42
+ this.middlewareStack.use(getHttpSigningPlugin(this.config));
43
+ }
44
+ destroy() {
45
+ super.destroy();
46
+ }
47
+ }
@@ -0,0 +1,38 @@
1
+ export const getHttpAuthExtensionConfiguration = (runtimeConfig) => {
2
+ const _httpAuthSchemes = runtimeConfig.httpAuthSchemes;
3
+ let _httpAuthSchemeProvider = runtimeConfig.httpAuthSchemeProvider;
4
+ let _credentials = runtimeConfig.credentials;
5
+ return {
6
+ setHttpAuthScheme(httpAuthScheme) {
7
+ const index = _httpAuthSchemes.findIndex((scheme) => scheme.schemeId === httpAuthScheme.schemeId);
8
+ if (index === -1) {
9
+ _httpAuthSchemes.push(httpAuthScheme);
10
+ }
11
+ else {
12
+ _httpAuthSchemes.splice(index, 1, httpAuthScheme);
13
+ }
14
+ },
15
+ httpAuthSchemes() {
16
+ return _httpAuthSchemes;
17
+ },
18
+ setHttpAuthSchemeProvider(httpAuthSchemeProvider) {
19
+ _httpAuthSchemeProvider = httpAuthSchemeProvider;
20
+ },
21
+ httpAuthSchemeProvider() {
22
+ return _httpAuthSchemeProvider;
23
+ },
24
+ setCredentials(credentials) {
25
+ _credentials = credentials;
26
+ },
27
+ credentials() {
28
+ return _credentials;
29
+ },
30
+ };
31
+ };
32
+ export const resolveHttpAuthRuntimeConfig = (config) => {
33
+ return {
34
+ httpAuthSchemes: config.httpAuthSchemes(),
35
+ httpAuthSchemeProvider: config.httpAuthSchemeProvider(),
36
+ credentials: config.credentials(),
37
+ };
38
+ };
@@ -0,0 +1,40 @@
1
+ import { resolveAwsSdkSigV4Config, } from "@aws-sdk/core/httpAuthSchemes";
2
+ import { getSmithyContext, normalizeProvider } from "@smithy/core/client";
3
+ export const defaultOpenSearchMemoryHttpAuthSchemeParametersProvider = async (config, context, input) => {
4
+ return {
5
+ operation: getSmithyContext(context).operation,
6
+ region: await normalizeProvider(config.region)() || (() => {
7
+ throw new Error("expected `region` to be configured for `aws.auth#sigv4`");
8
+ })(),
9
+ };
10
+ };
11
+ function createAwsAuthSigv4HttpAuthOption(authParameters) {
12
+ return {
13
+ schemeId: "aws.auth#sigv4",
14
+ signingProperties: {
15
+ name: "osm",
16
+ region: authParameters.region,
17
+ },
18
+ propertiesExtractor: (config, context) => ({
19
+ signingProperties: {
20
+ config,
21
+ context,
22
+ },
23
+ }),
24
+ };
25
+ }
26
+ export const defaultOpenSearchMemoryHttpAuthSchemeProvider = (authParameters) => {
27
+ const options = [];
28
+ switch (authParameters.operation) {
29
+ default: {
30
+ options.push(createAwsAuthSigv4HttpAuthOption(authParameters));
31
+ }
32
+ }
33
+ return options;
34
+ };
35
+ export const resolveHttpAuthSchemeConfig = (config) => {
36
+ const config_0 = resolveAwsSdkSigV4Config(config);
37
+ return Object.assign(config_0, {
38
+ authSchemePreference: normalizeProvider(config.authSchemePreference ?? []),
39
+ });
40
+ };
@@ -0,0 +1,9 @@
1
+ import { makeBuilder } from "@smithy/core/client";
2
+ import { getEndpointPlugin } from "@smithy/core/endpoints";
3
+ import { commonParams } from "./endpoint/EndpointParameters";
4
+ export const command = makeBuilder(commonParams, "OpenSearchMemory", "OpenSearchMemoryClient", getEndpointPlugin);
5
+ export const _ep0 = {
6
+ SpaceId: { type: "contextParams", name: "spaceId" },
7
+ };
8
+ export const _ep1 = {};
9
+ export const _mw0 = (Command, cs, config, o) => [];
@@ -0,0 +1,4 @@
1
+ import { _ep0, _mw0, command } from "../commandBuilder";
2
+ import { BatchGetEvent$ } from "../schemas/schemas_0";
3
+ export class BatchGetEventCommand extends command(_ep0, _mw0, "BatchGetEvent", BatchGetEvent$) {
4
+ }
@@ -0,0 +1,4 @@
1
+ import { _ep0, _mw0, command } from "../commandBuilder";
2
+ import { CreateEvent$ } from "../schemas/schemas_0";
3
+ export class CreateEventCommand extends command(_ep0, _mw0, "CreateEvent", CreateEvent$) {
4
+ }
@@ -0,0 +1,4 @@
1
+ import { _ep0, _mw0, command } from "../commandBuilder";
2
+ import { CreateMemory$ } from "../schemas/schemas_0";
3
+ export class CreateMemoryCommand extends command(_ep0, _mw0, "CreateMemory", CreateMemory$) {
4
+ }
@@ -0,0 +1,4 @@
1
+ import { _ep1, _mw0, command } from "../commandBuilder";
2
+ import { CreateSpace$ } from "../schemas/schemas_0";
3
+ export class CreateSpaceCommand extends command(_ep1, _mw0, "CreateSpace", CreateSpace$) {
4
+ }
@@ -0,0 +1,4 @@
1
+ import { _ep0, _mw0, command } from "../commandBuilder";
2
+ import { DeleteEvent$ } from "../schemas/schemas_0";
3
+ export class DeleteEventCommand extends command(_ep0, _mw0, "DeleteEvent", DeleteEvent$) {
4
+ }
@@ -0,0 +1,4 @@
1
+ import { _ep0, _mw0, command } from "../commandBuilder";
2
+ import { DeleteMemory$ } from "../schemas/schemas_0";
3
+ export class DeleteMemoryCommand extends command(_ep0, _mw0, "DeleteMemory", DeleteMemory$) {
4
+ }
@@ -0,0 +1,4 @@
1
+ import { _ep1, _mw0, command } from "../commandBuilder";
2
+ import { DeleteSpace$ } from "../schemas/schemas_0";
3
+ export class DeleteSpaceCommand extends command(_ep1, _mw0, "DeleteSpace", DeleteSpace$) {
4
+ }
@@ -0,0 +1,4 @@
1
+ import { _ep0, _mw0, command } from "../commandBuilder";
2
+ import { GetEvent$ } from "../schemas/schemas_0";
3
+ export class GetEventCommand extends command(_ep0, _mw0, "GetEvent", GetEvent$) {
4
+ }
@@ -0,0 +1,4 @@
1
+ import { _ep0, _mw0, command } from "../commandBuilder";
2
+ import { GetMemory$ } from "../schemas/schemas_0";
3
+ export class GetMemoryCommand extends command(_ep0, _mw0, "GetMemory", GetMemory$) {
4
+ }
@@ -0,0 +1,4 @@
1
+ import { _ep1, _mw0, command } from "../commandBuilder";
2
+ import { GetSpace$ } from "../schemas/schemas_0";
3
+ export class GetSpaceCommand extends command(_ep1, _mw0, "GetSpace", GetSpace$) {
4
+ }
@@ -0,0 +1,4 @@
1
+ import { _ep0, _mw0, command } from "../commandBuilder";
2
+ import { ListEvents$ } from "../schemas/schemas_0";
3
+ export class ListEventsCommand extends command(_ep0, _mw0, "ListEvents", ListEvents$) {
4
+ }
@@ -0,0 +1,4 @@
1
+ import { _ep0, _mw0, command } from "../commandBuilder";
2
+ import { ListMemories$ } from "../schemas/schemas_0";
3
+ export class ListMemoriesCommand extends command(_ep0, _mw0, "ListMemories", ListMemories$) {
4
+ }
@@ -0,0 +1,4 @@
1
+ import { _ep1, _mw0, command } from "../commandBuilder";
2
+ import { ListSpaces$ } from "../schemas/schemas_0";
3
+ export class ListSpacesCommand extends command(_ep1, _mw0, "ListSpaces", ListSpaces$) {
4
+ }
@@ -0,0 +1,4 @@
1
+ import { _ep1, _mw0, command } from "../commandBuilder";
2
+ import { ListTagsForResource$ } from "../schemas/schemas_0";
3
+ export class ListTagsForResourceCommand extends command(_ep1, _mw0, "ListTagsForResource", ListTagsForResource$) {
4
+ }
@@ -0,0 +1,4 @@
1
+ import { _ep0, _mw0, command } from "../commandBuilder";
2
+ import { SearchEvents$ } from "../schemas/schemas_0";
3
+ export class SearchEventsCommand extends command(_ep0, _mw0, "SearchEvents", SearchEvents$) {
4
+ }
@@ -0,0 +1,4 @@
1
+ import { _ep0, _mw0, command } from "../commandBuilder";
2
+ import { SearchMemories$ } from "../schemas/schemas_0";
3
+ export class SearchMemoriesCommand extends command(_ep0, _mw0, "SearchMemories", SearchMemories$) {
4
+ }
@@ -0,0 +1,4 @@
1
+ import { _ep1, _mw0, command } from "../commandBuilder";
2
+ import { TagResource$ } from "../schemas/schemas_0";
3
+ export class TagResourceCommand extends command(_ep1, _mw0, "TagResource", TagResource$) {
4
+ }
@@ -0,0 +1,4 @@
1
+ import { _ep1, _mw0, command } from "../commandBuilder";
2
+ import { UntagResource$ } from "../schemas/schemas_0";
3
+ export class UntagResourceCommand extends command(_ep1, _mw0, "UntagResource", UntagResource$) {
4
+ }
@@ -0,0 +1,4 @@
1
+ import { _ep0, _mw0, command } from "../commandBuilder";
2
+ import { UpdateMemory$ } from "../schemas/schemas_0";
3
+ export class UpdateMemoryCommand extends command(_ep0, _mw0, "UpdateMemory", UpdateMemory$) {
4
+ }
@@ -0,0 +1,4 @@
1
+ import { _ep1, _mw0, command } from "../commandBuilder";
2
+ import { UpdateSpace$ } from "../schemas/schemas_0";
3
+ export class UpdateSpaceCommand extends command(_ep1, _mw0, "UpdateSpace", UpdateSpace$) {
4
+ }
@@ -0,0 +1,20 @@
1
+ export * from "./BatchGetEventCommand";
2
+ export * from "./CreateEventCommand";
3
+ export * from "./CreateMemoryCommand";
4
+ export * from "./CreateSpaceCommand";
5
+ export * from "./DeleteEventCommand";
6
+ export * from "./DeleteMemoryCommand";
7
+ export * from "./DeleteSpaceCommand";
8
+ export * from "./GetEventCommand";
9
+ export * from "./GetMemoryCommand";
10
+ export * from "./GetSpaceCommand";
11
+ export * from "./ListEventsCommand";
12
+ export * from "./ListMemoriesCommand";
13
+ export * from "./ListSpacesCommand";
14
+ export * from "./ListTagsForResourceCommand";
15
+ export * from "./SearchEventsCommand";
16
+ export * from "./SearchMemoriesCommand";
17
+ export * from "./TagResourceCommand";
18
+ export * from "./UntagResourceCommand";
19
+ export * from "./UpdateMemoryCommand";
20
+ export * from "./UpdateSpaceCommand";
@@ -0,0 +1,11 @@
1
+ export const resolveClientEndpointParameters = (options) => {
2
+ return Object.assign(options, {
3
+ useFipsEndpoint: options.useFipsEndpoint ?? false,
4
+ defaultSigningName: "osm",
5
+ });
6
+ };
7
+ export const commonParams = {
8
+ UseFIPS: { type: "builtInParams", name: "useFipsEndpoint" },
9
+ Endpoint: { type: "builtInParams", name: "endpoint" },
10
+ Region: { type: "builtInParams", name: "region" },
11
+ };
@@ -0,0 +1,33 @@
1
+ import { BinaryDecisionDiagram } from "@smithy/core/endpoints";
2
+ const a = -1, b = "isSet", c = "isValidHostLabel", d = { "ref": "SpaceId" };
3
+ const _data = {
4
+ conditions: [
5
+ [b, [{ ref: "Endpoint" }]],
6
+ ["booleanEquals", [{ ref: "UseFIPS" }, true]],
7
+ [c, [{ ref: "Region" }, true]],
8
+ [b, [d]],
9
+ [c, [d, false]]
10
+ ],
11
+ results: [
12
+ [a],
13
+ [a, "Invalid Configuration: FIPS and custom endpoint are not supported"],
14
+ ["{Endpoint}", {}],
15
+ [a, "Invalid Configuration: FIPS is not supported with OpenSearch Memory."],
16
+ [a, "Invalid Configuration: Region must be a valid host label"],
17
+ ["https://{SpaceId}.osm.{Region}.on.aws", {}],
18
+ [a, "Invalid SpaceId: must be a valid host label"],
19
+ ["https://osm.{Region}.api.aws", {}]
20
+ ]
21
+ };
22
+ const root = 2;
23
+ const r = 100_000_000;
24
+ const nodes = new Int32Array([
25
+ -1, 1, -1,
26
+ 0, 7, 3,
27
+ 1, r + 3, 4,
28
+ 2, 5, r + 4,
29
+ 3, 6, r + 7,
30
+ 4, r + 5, r + 6,
31
+ 1, r + 1, r + 2,
32
+ ]);
33
+ export const bdd = BinaryDecisionDiagram.from(nodes, root, _data.conditions, _data.results);
@@ -0,0 +1,14 @@
1
+ import { awsEndpointFunctions } from "@aws-sdk/core/client";
2
+ import { customEndpointFunctions, decideEndpoint, EndpointCache } from "@smithy/core/endpoints";
3
+ import { bdd } from "./bdd";
4
+ const cache = new EndpointCache({
5
+ size: 50,
6
+ params: ["Endpoint", "Region", "SpaceId", "UseFIPS"],
7
+ });
8
+ export const defaultEndpointResolver = (endpointParams, context = {}) => {
9
+ return cache.get(endpointParams, () => decideEndpoint(bdd, {
10
+ endpointParams: endpointParams,
11
+ logger: context.logger,
12
+ }));
13
+ };
14
+ customEndpointFunctions.aws = awsEndpointFunctions;
@@ -0,0 +1 @@
1
+ export {};
@@ -0,0 +1,11 @@
1
+ export * from "./OpenSearchMemoryClient";
2
+ export * from "./OpenSearchMemory";
3
+ export * from "./commands";
4
+ export { Command as $Command } from "@smithy/core/client";
5
+ export * from "./pagination";
6
+ export * from "./waiters";
7
+ export * from "./schemas/schemas_0";
8
+ export * from "./models/enums";
9
+ export * from "./models/errors";
10
+ export * from "./models/models_0";
11
+ export { OpenSearchMemoryServiceException } from "./models/OpenSearchMemoryServiceException";
@@ -0,0 +1,9 @@
1
+ import { ServiceException as __ServiceException, } from "@smithy/core/client";
2
+ export { __ServiceException };
3
+ export class OpenSearchMemoryServiceException extends __ServiceException {
4
+ static shapeId = "smithy.ts.sdk.synthetic.com.amazonaws.opensearchmemory#OpenSearchMemoryServiceException";
5
+ constructor(options) {
6
+ super(options);
7
+ Object.setPrototypeOf(this, OpenSearchMemoryServiceException.prototype);
8
+ }
9
+ }
@@ -0,0 +1,61 @@
1
+ export const BatchGetEventErrorCode = {
2
+ ACCESS_DENIED: "ACCESS_DENIED",
3
+ INTERNAL_SERVER: "INTERNAL_SERVER",
4
+ RESOURCE_NOT_FOUND: "RESOURCE_NOT_FOUND",
5
+ THROTTLING: "THROTTLING",
6
+ };
7
+ export const BlobContentType = {
8
+ JPEG: "image/jpeg",
9
+ PDF: "application/pdf",
10
+ PNG: "image/png",
11
+ };
12
+ export const MessageRole = {
13
+ ASSISTANT: "ASSISTANT",
14
+ SYSTEM: "SYSTEM",
15
+ USER: "USER",
16
+ };
17
+ export const ValidationExceptionReason = {
18
+ DISALLOWED_QUERY_TYPE: "disallowedQueryType",
19
+ FIELD_INDEX_MISMATCH: "fieldIndexMismatch",
20
+ FIELD_VALIDATION_FAILED: "fieldValidationFailed",
21
+ INVALID_NEXT_TOKEN: "invalidNextToken",
22
+ MALFORMED_QUERY_BODY: "malformedQueryBody",
23
+ NON_FILTERABLE_FIELD: "nonFilterableField",
24
+ OTHER: "other",
25
+ QUERY_BODY_TOO_LARGE: "queryBodyTooLarge",
26
+ QUERY_NESTING_TOO_DEEP: "queryNestingTooDeep",
27
+ UNBOUNDED_PATTERN: "unboundedPattern",
28
+ UNKNOWN_FIELD: "unknownField",
29
+ UNSUPPORTED_FIELD: "unsupportedField",
30
+ UNSUPPORTED_PARAMETER: "unsupportedParameter",
31
+ };
32
+ export const MemoryStrategyType = {
33
+ CUSTOM: "CUSTOM",
34
+ SEMANTIC: "SEMANTIC",
35
+ SUMMARY: "SUMMARY",
36
+ };
37
+ export const SpaceStatus = {
38
+ ACTIVE: "ACTIVE",
39
+ CREATING: "CREATING",
40
+ DELETED: "DELETED",
41
+ DELETING: "DELETING",
42
+ FAILED: "FAILED",
43
+ UPDATING: "UPDATING",
44
+ };
45
+ export const MemoryType = {
46
+ CUSTOM: "CUSTOM",
47
+ SEMANTIC: "SEMANTIC",
48
+ SUMMARY: "SUMMARY",
49
+ };
50
+ export const SortOrder = {
51
+ ASC: "ASC",
52
+ DESC: "DESC",
53
+ };
54
+ export const MemorySortField = {
55
+ CREATED_AT: "CREATED_AT",
56
+ UPDATED_AT: "UPDATED_AT",
57
+ };
58
+ export const MetadataMode = {
59
+ MERGE: "MERGE",
60
+ REPLACE: "REPLACE",
61
+ };
@@ -0,0 +1,114 @@
1
+ import { OpenSearchMemoryServiceException as __BaseException } from "./OpenSearchMemoryServiceException";
2
+ export class AccessDeniedException extends __BaseException {
3
+ static shapeId = "com.amazonaws.opensearchmemory#AccessDeniedException";
4
+ name = "AccessDeniedException";
5
+ $fault = "client";
6
+ constructor(opts) {
7
+ super({
8
+ name: "AccessDeniedException",
9
+ $fault: "client",
10
+ ...opts,
11
+ });
12
+ Object.setPrototypeOf(this, AccessDeniedException.prototype);
13
+ }
14
+ }
15
+ export class InternalServerException extends __BaseException {
16
+ static shapeId = "com.amazonaws.opensearchmemory#InternalServerException";
17
+ name = "InternalServerException";
18
+ $fault = "server";
19
+ $retryable = {};
20
+ constructor(opts) {
21
+ super({
22
+ name: "InternalServerException",
23
+ $fault: "server",
24
+ ...opts,
25
+ });
26
+ Object.setPrototypeOf(this, InternalServerException.prototype);
27
+ }
28
+ }
29
+ export class ResourceNotFoundException extends __BaseException {
30
+ static shapeId = "com.amazonaws.opensearchmemory#ResourceNotFoundException";
31
+ name = "ResourceNotFoundException";
32
+ $fault = "client";
33
+ resourceId;
34
+ resourceType;
35
+ constructor(opts) {
36
+ super({
37
+ name: "ResourceNotFoundException",
38
+ $fault: "client",
39
+ ...opts,
40
+ });
41
+ Object.setPrototypeOf(this, ResourceNotFoundException.prototype);
42
+ this.resourceId = opts.resourceId;
43
+ this.resourceType = opts.resourceType;
44
+ }
45
+ }
46
+ export class ThrottlingException extends __BaseException {
47
+ static shapeId = "com.amazonaws.opensearchmemory#ThrottlingException";
48
+ name = "ThrottlingException";
49
+ $fault = "client";
50
+ $retryable = {
51
+ throttling: true,
52
+ };
53
+ retryAfterSeconds;
54
+ constructor(opts) {
55
+ super({
56
+ name: "ThrottlingException",
57
+ $fault: "client",
58
+ ...opts,
59
+ });
60
+ Object.setPrototypeOf(this, ThrottlingException.prototype);
61
+ this.retryAfterSeconds = opts.retryAfterSeconds;
62
+ }
63
+ }
64
+ export class ValidationException extends __BaseException {
65
+ static shapeId = "com.amazonaws.opensearchmemory#ValidationException";
66
+ name = "ValidationException";
67
+ $fault = "client";
68
+ reason;
69
+ fieldList;
70
+ constructor(opts) {
71
+ super({
72
+ name: "ValidationException",
73
+ $fault: "client",
74
+ ...opts,
75
+ });
76
+ Object.setPrototypeOf(this, ValidationException.prototype);
77
+ this.reason = opts.reason;
78
+ this.fieldList = opts.fieldList;
79
+ }
80
+ }
81
+ export class ConflictException extends __BaseException {
82
+ static shapeId = "com.amazonaws.opensearchmemory#ConflictException";
83
+ name = "ConflictException";
84
+ $fault = "client";
85
+ resourceId;
86
+ resourceType;
87
+ constructor(opts) {
88
+ super({
89
+ name: "ConflictException",
90
+ $fault: "client",
91
+ ...opts,
92
+ });
93
+ Object.setPrototypeOf(this, ConflictException.prototype);
94
+ this.resourceId = opts.resourceId;
95
+ this.resourceType = opts.resourceType;
96
+ }
97
+ }
98
+ export class ServiceQuotaExceededException extends __BaseException {
99
+ static shapeId = "com.amazonaws.opensearchmemory#ServiceQuotaExceededException";
100
+ name = "ServiceQuotaExceededException";
101
+ $fault = "client";
102
+ quotaCode;
103
+ serviceCode;
104
+ constructor(opts) {
105
+ super({
106
+ name: "ServiceQuotaExceededException",
107
+ $fault: "client",
108
+ ...opts,
109
+ });
110
+ Object.setPrototypeOf(this, ServiceQuotaExceededException.prototype);
111
+ this.quotaCode = opts.quotaCode;
112
+ this.serviceCode = opts.serviceCode;
113
+ }
114
+ }
@@ -0,0 +1 @@
1
+ export {};
@@ -0,0 +1 @@
1
+ export {};
@@ -0,0 +1,4 @@
1
+ import { createPaginator } from "@smithy/core";
2
+ import { ListEventsCommand } from "../commands/ListEventsCommand";
3
+ import { OpenSearchMemoryClient } from "../OpenSearchMemoryClient";
4
+ export const paginateListEvents = createPaginator(OpenSearchMemoryClient, ListEventsCommand, "nextToken", "nextToken", "maxResults");
@@ -0,0 +1,4 @@
1
+ import { createPaginator } from "@smithy/core";
2
+ import { ListMemoriesCommand, } from "../commands/ListMemoriesCommand";
3
+ import { OpenSearchMemoryClient } from "../OpenSearchMemoryClient";
4
+ export const paginateListMemories = createPaginator(OpenSearchMemoryClient, ListMemoriesCommand, "nextToken", "nextToken", "maxResults");
@@ -0,0 +1,4 @@
1
+ import { createPaginator } from "@smithy/core";
2
+ import { ListSpacesCommand } from "../commands/ListSpacesCommand";
3
+ import { OpenSearchMemoryClient } from "../OpenSearchMemoryClient";
4
+ export const paginateListSpaces = createPaginator(OpenSearchMemoryClient, ListSpacesCommand, "nextToken", "nextToken", "maxResults");
@@ -0,0 +1,4 @@
1
+ import { createPaginator } from "@smithy/core";
2
+ import { SearchEventsCommand, } from "../commands/SearchEventsCommand";
3
+ import { OpenSearchMemoryClient } from "../OpenSearchMemoryClient";
4
+ export const paginateSearchEvents = createPaginator(OpenSearchMemoryClient, SearchEventsCommand, "nextToken", "nextToken", "maxResults");