@aws-sdk/client-agent-registry-control 3.1105.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/LICENSE +201 -0
- package/README.md +286 -0
- package/dist-cjs/index.js +1536 -0
- package/dist-es/AgentRegistryControl.js +49 -0
- package/dist-es/AgentRegistryControlClient.js +47 -0
- package/dist-es/auth/httpAuthExtensionConfiguration.js +38 -0
- package/dist-es/auth/httpAuthSchemeProvider.js +40 -0
- package/dist-es/commandBuilder.js +6 -0
- package/dist-es/commands/CreateRegistryCommand.js +4 -0
- package/dist-es/commands/CreateRegistryRecordCommand.js +4 -0
- package/dist-es/commands/DeleteRegistryCommand.js +4 -0
- package/dist-es/commands/DeleteRegistryRecordCommand.js +4 -0
- package/dist-es/commands/GetRegistryCommand.js +4 -0
- package/dist-es/commands/GetRegistryRecordCommand.js +4 -0
- package/dist-es/commands/ListRegistriesCommand.js +4 -0
- package/dist-es/commands/ListRegistryRecordsCommand.js +4 -0
- package/dist-es/commands/ListTagsForResourceCommand.js +4 -0
- package/dist-es/commands/SubmitRegistryRecordForApprovalCommand.js +4 -0
- package/dist-es/commands/TagResourceCommand.js +4 -0
- package/dist-es/commands/UntagResourceCommand.js +4 -0
- package/dist-es/commands/UpdateRegistryCommand.js +4 -0
- package/dist-es/commands/UpdateRegistryRecordCommand.js +4 -0
- package/dist-es/commands/UpdateRegistryRecordStatusCommand.js +4 -0
- package/dist-es/commands/index.js +15 -0
- package/dist-es/endpoint/EndpointParameters.js +9 -0
- package/dist-es/endpoint/bdd.js +22 -0
- package/dist-es/endpoint/endpointResolver.js +14 -0
- package/dist-es/extensionConfiguration.js +1 -0
- package/dist-es/index.js +11 -0
- package/dist-es/models/AgentRegistryControlServiceException.js +8 -0
- package/dist-es/models/enums.js +69 -0
- package/dist-es/models/errors.js +89 -0
- package/dist-es/models/models_0.js +1 -0
- package/dist-es/pagination/Interfaces.js +1 -0
- package/dist-es/pagination/ListRegistriesPaginator.js +4 -0
- package/dist-es/pagination/ListRegistryRecordsPaginator.js +4 -0
- package/dist-es/pagination/index.js +3 -0
- package/dist-es/runtimeConfig.browser.js +29 -0
- package/dist-es/runtimeConfig.js +43 -0
- package/dist-es/runtimeConfig.native.js +9 -0
- package/dist-es/runtimeConfig.shared.js +40 -0
- package/dist-es/runtimeExtensions.js +9 -0
- package/dist-es/schemas/schemas_0.js +783 -0
- package/dist-es/waiters/index.js +2 -0
- package/dist-es/waiters/waitForRegistryReady.js +58 -0
- package/dist-es/waiters/waitForRegistryRecordApproved.js +58 -0
- package/dist-types/AgentRegistryControl.d.ts +143 -0
- package/dist-types/AgentRegistryControlClient.d.ts +201 -0
- package/dist-types/auth/httpAuthExtensionConfiguration.d.ts +29 -0
- package/dist-types/auth/httpAuthSchemeProvider.d.ts +75 -0
- package/dist-types/commandBuilder.d.ts +18 -0
- package/dist-types/commands/CreateRegistryCommand.d.ts +172 -0
- package/dist-types/commands/CreateRegistryRecordCommand.d.ts +212 -0
- package/dist-types/commands/DeleteRegistryCommand.d.ts +89 -0
- package/dist-types/commands/DeleteRegistryRecordCommand.d.ts +88 -0
- package/dist-types/commands/GetRegistryCommand.d.ts +173 -0
- package/dist-types/commands/GetRegistryRecordCommand.d.ts +211 -0
- package/dist-types/commands/ListRegistriesCommand.d.ts +179 -0
- package/dist-types/commands/ListRegistryRecordsCommand.d.ts +114 -0
- package/dist-types/commands/ListTagsForResourceCommand.d.ts +88 -0
- package/dist-types/commands/SubmitRegistryRecordForApprovalCommand.d.ts +94 -0
- package/dist-types/commands/TagResourceCommand.d.ts +90 -0
- package/dist-types/commands/UntagResourceCommand.d.ts +87 -0
- package/dist-types/commands/UpdateRegistryCommand.d.ts +266 -0
- package/dist-types/commands/UpdateRegistryRecordCommand.d.ts +375 -0
- package/dist-types/commands/UpdateRegistryRecordStatusCommand.d.ts +97 -0
- package/dist-types/commands/index.d.ts +15 -0
- package/dist-types/endpoint/EndpointParameters.d.ts +38 -0
- package/dist-types/endpoint/bdd.d.ts +2 -0
- package/dist-types/endpoint/endpointResolver.d.ts +8 -0
- package/dist-types/extensionConfiguration.d.ts +9 -0
- package/dist-types/index.d.ts +19 -0
- package/dist-types/models/AgentRegistryControlServiceException.d.ts +14 -0
- package/dist-types/models/enums.d.ts +173 -0
- package/dist-types/models/errors.d.ts +98 -0
- package/dist-types/models/models_0.d.ts +1886 -0
- package/dist-types/pagination/Interfaces.d.ts +8 -0
- package/dist-types/pagination/ListRegistriesPaginator.d.ts +7 -0
- package/dist-types/pagination/ListRegistryRecordsPaginator.d.ts +7 -0
- package/dist-types/pagination/index.d.ts +3 -0
- package/dist-types/runtimeConfig.browser.d.ts +57 -0
- package/dist-types/runtimeConfig.d.ts +57 -0
- package/dist-types/runtimeConfig.native.d.ts +56 -0
- package/dist-types/runtimeConfig.shared.d.ts +28 -0
- package/dist-types/runtimeExtensions.d.ts +17 -0
- package/dist-types/schemas/schemas_0.d.ts +118 -0
- package/dist-types/ts3.4/AgentRegistryControl.d.ts +295 -0
- package/dist-types/ts3.4/AgentRegistryControlClient.d.ts +187 -0
- package/dist-types/ts3.4/auth/httpAuthExtensionConfiguration.d.ts +27 -0
- package/dist-types/ts3.4/auth/httpAuthSchemeProvider.d.ts +43 -0
- package/dist-types/ts3.4/commandBuilder.d.ts +40 -0
- package/dist-types/ts3.4/commands/CreateRegistryCommand.d.ts +38 -0
- package/dist-types/ts3.4/commands/CreateRegistryRecordCommand.d.ts +39 -0
- package/dist-types/ts3.4/commands/DeleteRegistryCommand.d.ts +38 -0
- package/dist-types/ts3.4/commands/DeleteRegistryRecordCommand.d.ts +39 -0
- package/dist-types/ts3.4/commands/GetRegistryCommand.d.ts +38 -0
- package/dist-types/ts3.4/commands/GetRegistryRecordCommand.d.ts +39 -0
- package/dist-types/ts3.4/commands/ListRegistriesCommand.d.ts +38 -0
- package/dist-types/ts3.4/commands/ListRegistryRecordsCommand.d.ts +39 -0
- package/dist-types/ts3.4/commands/ListTagsForResourceCommand.d.ts +39 -0
- package/dist-types/ts3.4/commands/SubmitRegistryRecordForApprovalCommand.d.ts +42 -0
- package/dist-types/ts3.4/commands/TagResourceCommand.d.ts +38 -0
- package/dist-types/ts3.4/commands/UntagResourceCommand.d.ts +38 -0
- package/dist-types/ts3.4/commands/UpdateRegistryCommand.d.ts +38 -0
- package/dist-types/ts3.4/commands/UpdateRegistryRecordCommand.d.ts +39 -0
- package/dist-types/ts3.4/commands/UpdateRegistryRecordStatusCommand.d.ts +42 -0
- package/dist-types/ts3.4/commands/index.d.ts +15 -0
- package/dist-types/ts3.4/endpoint/EndpointParameters.d.ts +39 -0
- package/dist-types/ts3.4/endpoint/bdd.d.ts +2 -0
- package/dist-types/ts3.4/endpoint/endpointResolver.d.ts +8 -0
- package/dist-types/ts3.4/extensionConfiguration.d.ts +10 -0
- package/dist-types/ts3.4/index.d.ts +14 -0
- package/dist-types/ts3.4/models/AgentRegistryControlServiceException.d.ts +9 -0
- package/dist-types/ts3.4/models/enums.d.ts +90 -0
- package/dist-types/ts3.4/models/errors.d.ts +41 -0
- package/dist-types/ts3.4/models/models_0.d.ts +528 -0
- package/dist-types/ts3.4/pagination/Interfaces.d.ts +5 -0
- package/dist-types/ts3.4/pagination/ListRegistriesPaginator.d.ts +11 -0
- package/dist-types/ts3.4/pagination/ListRegistryRecordsPaginator.d.ts +11 -0
- package/dist-types/ts3.4/pagination/index.d.ts +3 -0
- package/dist-types/ts3.4/runtimeConfig.browser.d.ts +95 -0
- package/dist-types/ts3.4/runtimeConfig.d.ts +95 -0
- package/dist-types/ts3.4/runtimeConfig.native.d.ts +99 -0
- package/dist-types/ts3.4/runtimeConfig.shared.d.ts +31 -0
- package/dist-types/ts3.4/runtimeExtensions.d.ts +11 -0
- package/dist-types/ts3.4/schemas/schemas_0.d.ts +118 -0
- package/dist-types/ts3.4/waiters/index.d.ts +2 -0
- package/dist-types/ts3.4/waiters/waitForRegistryReady.d.ts +12 -0
- package/dist-types/ts3.4/waiters/waitForRegistryRecordApproved.d.ts +15 -0
- package/dist-types/waiters/index.d.ts +2 -0
- package/dist-types/waiters/waitForRegistryReady.d.ts +15 -0
- package/dist-types/waiters/waitForRegistryRecordApproved.d.ts +15 -0
- package/package.json +69 -0
|
@@ -0,0 +1,49 @@
|
|
|
1
|
+
import { createAggregatedClient } from "@smithy/core/client";
|
|
2
|
+
import { AgentRegistryControlClient } from "./AgentRegistryControlClient";
|
|
3
|
+
import { CreateRegistryCommand, } from "./commands/CreateRegistryCommand";
|
|
4
|
+
import { CreateRegistryRecordCommand, } from "./commands/CreateRegistryRecordCommand";
|
|
5
|
+
import { DeleteRegistryCommand, } from "./commands/DeleteRegistryCommand";
|
|
6
|
+
import { DeleteRegistryRecordCommand, } from "./commands/DeleteRegistryRecordCommand";
|
|
7
|
+
import { GetRegistryCommand, } from "./commands/GetRegistryCommand";
|
|
8
|
+
import { GetRegistryRecordCommand, } from "./commands/GetRegistryRecordCommand";
|
|
9
|
+
import { ListRegistriesCommand, } from "./commands/ListRegistriesCommand";
|
|
10
|
+
import { ListRegistryRecordsCommand, } from "./commands/ListRegistryRecordsCommand";
|
|
11
|
+
import { ListTagsForResourceCommand, } from "./commands/ListTagsForResourceCommand";
|
|
12
|
+
import { SubmitRegistryRecordForApprovalCommand, } from "./commands/SubmitRegistryRecordForApprovalCommand";
|
|
13
|
+
import { TagResourceCommand, } from "./commands/TagResourceCommand";
|
|
14
|
+
import { UntagResourceCommand, } from "./commands/UntagResourceCommand";
|
|
15
|
+
import { UpdateRegistryCommand, } from "./commands/UpdateRegistryCommand";
|
|
16
|
+
import { UpdateRegistryRecordCommand, } from "./commands/UpdateRegistryRecordCommand";
|
|
17
|
+
import { UpdateRegistryRecordStatusCommand, } from "./commands/UpdateRegistryRecordStatusCommand";
|
|
18
|
+
import { paginateListRegistries } from "./pagination/ListRegistriesPaginator";
|
|
19
|
+
import { paginateListRegistryRecords } from "./pagination/ListRegistryRecordsPaginator";
|
|
20
|
+
import { waitUntilRegistryReady } from "./waiters/waitForRegistryReady";
|
|
21
|
+
import { waitUntilRegistryRecordApproved } from "./waiters/waitForRegistryRecordApproved";
|
|
22
|
+
const commands = {
|
|
23
|
+
CreateRegistryCommand,
|
|
24
|
+
CreateRegistryRecordCommand,
|
|
25
|
+
DeleteRegistryCommand,
|
|
26
|
+
DeleteRegistryRecordCommand,
|
|
27
|
+
GetRegistryCommand,
|
|
28
|
+
GetRegistryRecordCommand,
|
|
29
|
+
ListRegistriesCommand,
|
|
30
|
+
ListRegistryRecordsCommand,
|
|
31
|
+
ListTagsForResourceCommand,
|
|
32
|
+
SubmitRegistryRecordForApprovalCommand,
|
|
33
|
+
TagResourceCommand,
|
|
34
|
+
UntagResourceCommand,
|
|
35
|
+
UpdateRegistryCommand,
|
|
36
|
+
UpdateRegistryRecordCommand,
|
|
37
|
+
UpdateRegistryRecordStatusCommand,
|
|
38
|
+
};
|
|
39
|
+
const paginators = {
|
|
40
|
+
paginateListRegistries,
|
|
41
|
+
paginateListRegistryRecords,
|
|
42
|
+
};
|
|
43
|
+
const waiters = {
|
|
44
|
+
waitUntilRegistryReady,
|
|
45
|
+
waitUntilRegistryRecordApproved,
|
|
46
|
+
};
|
|
47
|
+
export class AgentRegistryControl extends AgentRegistryControlClient {
|
|
48
|
+
}
|
|
49
|
+
createAggregatedClient(commands, AgentRegistryControl, { 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 { defaultAgentRegistryControlHttpAuthSchemeParametersProvider, 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 AgentRegistryControlClient 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: defaultAgentRegistryControlHttpAuthSchemeParametersProvider,
|
|
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 defaultAgentRegistryControlHttpAuthSchemeParametersProvider = 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: "agent-registry",
|
|
16
|
+
region: authParameters.region,
|
|
17
|
+
},
|
|
18
|
+
propertiesExtractor: (config, context) => ({
|
|
19
|
+
signingProperties: {
|
|
20
|
+
config,
|
|
21
|
+
context,
|
|
22
|
+
},
|
|
23
|
+
}),
|
|
24
|
+
};
|
|
25
|
+
}
|
|
26
|
+
export const defaultAgentRegistryControlHttpAuthSchemeProvider = (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,6 @@
|
|
|
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, "AgentRegistryControl", "AgentRegistryControlClient", getEndpointPlugin);
|
|
5
|
+
export const _ep0 = {};
|
|
6
|
+
export const _mw0 = (Command, cs, config, o) => [];
|
|
@@ -0,0 +1,4 @@
|
|
|
1
|
+
import { _ep0, _mw0, command } from "../commandBuilder";
|
|
2
|
+
import { SubmitRegistryRecordForApproval$ } from "../schemas/schemas_0";
|
|
3
|
+
export class SubmitRegistryRecordForApprovalCommand extends command(_ep0, _mw0, "SubmitRegistryRecordForApproval", SubmitRegistryRecordForApproval$) {
|
|
4
|
+
}
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
export * from "./CreateRegistryCommand";
|
|
2
|
+
export * from "./CreateRegistryRecordCommand";
|
|
3
|
+
export * from "./DeleteRegistryCommand";
|
|
4
|
+
export * from "./DeleteRegistryRecordCommand";
|
|
5
|
+
export * from "./GetRegistryCommand";
|
|
6
|
+
export * from "./GetRegistryRecordCommand";
|
|
7
|
+
export * from "./ListRegistriesCommand";
|
|
8
|
+
export * from "./ListRegistryRecordsCommand";
|
|
9
|
+
export * from "./ListTagsForResourceCommand";
|
|
10
|
+
export * from "./SubmitRegistryRecordForApprovalCommand";
|
|
11
|
+
export * from "./TagResourceCommand";
|
|
12
|
+
export * from "./UntagResourceCommand";
|
|
13
|
+
export * from "./UpdateRegistryCommand";
|
|
14
|
+
export * from "./UpdateRegistryRecordCommand";
|
|
15
|
+
export * from "./UpdateRegistryRecordStatusCommand";
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
export const resolveClientEndpointParameters = (options) => {
|
|
2
|
+
return Object.assign(options, {
|
|
3
|
+
defaultSigningName: "agent-registry",
|
|
4
|
+
});
|
|
5
|
+
};
|
|
6
|
+
export const commonParams = {
|
|
7
|
+
Endpoint: { type: "builtInParams", name: "endpoint" },
|
|
8
|
+
Region: { type: "builtInParams", name: "region" },
|
|
9
|
+
};
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
import { BinaryDecisionDiagram } from "@smithy/core/endpoints";
|
|
2
|
+
const a = "isSet", b = { "ref": "Endpoint" };
|
|
3
|
+
const _data = {
|
|
4
|
+
conditions: [
|
|
5
|
+
[a, [b]],
|
|
6
|
+
[a, [{ ref: "Region" }]]
|
|
7
|
+
],
|
|
8
|
+
results: [
|
|
9
|
+
[-1],
|
|
10
|
+
[b, {}],
|
|
11
|
+
["https://agent-registry-control.{Region}.api.aws", {}],
|
|
12
|
+
[-1, "Unable to resolve an Agent Registry Control endpoint: Region was not set and no explicit Endpoint override was provided."]
|
|
13
|
+
]
|
|
14
|
+
};
|
|
15
|
+
const root = 2;
|
|
16
|
+
const r = 100_000_000;
|
|
17
|
+
const nodes = new Int32Array([
|
|
18
|
+
-1, 1, -1,
|
|
19
|
+
0, r + 1, 3,
|
|
20
|
+
1, r + 2, r + 3,
|
|
21
|
+
]);
|
|
22
|
+
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"],
|
|
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 {};
|
package/dist-es/index.js
ADDED
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
export * from "./AgentRegistryControlClient";
|
|
2
|
+
export * from "./AgentRegistryControl";
|
|
3
|
+
export * from "./commands";
|
|
4
|
+
export { Command as $Command } from "@smithy/core/client";
|
|
5
|
+
export * from "./schemas/schemas_0";
|
|
6
|
+
export * from "./pagination";
|
|
7
|
+
export * from "./waiters";
|
|
8
|
+
export * from "./models/enums";
|
|
9
|
+
export * from "./models/errors";
|
|
10
|
+
export * from "./models/models_0";
|
|
11
|
+
export { AgentRegistryControlServiceException } from "./models/AgentRegistryControlServiceException";
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import { ServiceException as __ServiceException, } from "@smithy/core/client";
|
|
2
|
+
export { __ServiceException };
|
|
3
|
+
export class AgentRegistryControlServiceException extends __ServiceException {
|
|
4
|
+
constructor(options) {
|
|
5
|
+
super(options);
|
|
6
|
+
Object.setPrototypeOf(this, AgentRegistryControlServiceException.prototype);
|
|
7
|
+
}
|
|
8
|
+
}
|
|
@@ -0,0 +1,69 @@
|
|
|
1
|
+
export const RegistryRecordOAuthGrantType = {
|
|
2
|
+
CLIENT_CREDENTIALS: "CLIENT_CREDENTIALS",
|
|
3
|
+
};
|
|
4
|
+
export const RegistryRecordCredentialProviderType = {
|
|
5
|
+
IAM: "IAM",
|
|
6
|
+
OAUTH: "OAUTH",
|
|
7
|
+
};
|
|
8
|
+
export const ValidationExceptionReason = {
|
|
9
|
+
CANNOT_PARSE: "CannotParse",
|
|
10
|
+
FIELD_VALIDATION_FAILED: "FieldValidationFailed",
|
|
11
|
+
IDEMPOTENT_PARAMETER_MISMATCH_EXCEPTION: "IdempotentParameterMismatchException",
|
|
12
|
+
RESOURCE_CONFLICT: "ResourceConflict",
|
|
13
|
+
ROOT_EVENT_IN_OTHER_SESSION: "EventInOtherSession",
|
|
14
|
+
};
|
|
15
|
+
export const RecordType = {
|
|
16
|
+
AGENT: "AGENT",
|
|
17
|
+
CUSTOM: "CUSTOM",
|
|
18
|
+
MCP: "MCP",
|
|
19
|
+
SKILL: "SKILL",
|
|
20
|
+
};
|
|
21
|
+
export const RegistryRecordStatus = {
|
|
22
|
+
APPROVED: "APPROVED",
|
|
23
|
+
CREATE_FAILED: "CREATE_FAILED",
|
|
24
|
+
CREATING: "CREATING",
|
|
25
|
+
DEPRECATED: "DEPRECATED",
|
|
26
|
+
DRAFT: "DRAFT",
|
|
27
|
+
PENDING_APPROVAL: "PENDING_APPROVAL",
|
|
28
|
+
REJECTED: "REJECTED",
|
|
29
|
+
UPDATE_FAILED: "UPDATE_FAILED",
|
|
30
|
+
UPDATING: "UPDATING",
|
|
31
|
+
};
|
|
32
|
+
export const RegistryRecordFilterName = {
|
|
33
|
+
NAME: "name",
|
|
34
|
+
RECORD_TYPE: "recordType",
|
|
35
|
+
STATUS: "status",
|
|
36
|
+
};
|
|
37
|
+
export const AutoApprovalRule = {
|
|
38
|
+
APPROVE_ALL: "APPROVE_ALL",
|
|
39
|
+
};
|
|
40
|
+
export const ClaimMatchOperatorType = {
|
|
41
|
+
CONTAINS: "CONTAINS",
|
|
42
|
+
CONTAINS_ANY: "CONTAINS_ANY",
|
|
43
|
+
EQUALS: "EQUALS",
|
|
44
|
+
};
|
|
45
|
+
export const InboundTokenClaimValueType = {
|
|
46
|
+
STRING: "STRING",
|
|
47
|
+
STRING_ARRAY: "STRING_ARRAY",
|
|
48
|
+
};
|
|
49
|
+
export const EndpointIpAddressType = {
|
|
50
|
+
IPV4: "IPV4",
|
|
51
|
+
IPV6: "IPV6",
|
|
52
|
+
};
|
|
53
|
+
export const RegistryAuthorizerType = {
|
|
54
|
+
AWS_IAM: "AWS_IAM",
|
|
55
|
+
CUSTOM_JWT: "CUSTOM_JWT",
|
|
56
|
+
};
|
|
57
|
+
export const RegistryStatus = {
|
|
58
|
+
CREATE_FAILED: "CREATE_FAILED",
|
|
59
|
+
CREATING: "CREATING",
|
|
60
|
+
DELETE_FAILED: "DELETE_FAILED",
|
|
61
|
+
DELETING: "DELETING",
|
|
62
|
+
READY: "READY",
|
|
63
|
+
UPDATE_FAILED: "UPDATE_FAILED",
|
|
64
|
+
UPDATING: "UPDATING",
|
|
65
|
+
};
|
|
66
|
+
export const RegistryFilterName = {
|
|
67
|
+
DISCOVERY_CONFIGURATION_AUTHORIZER_TYPE: "discoveryConfiguration.authorizerType",
|
|
68
|
+
STATUS: "status",
|
|
69
|
+
};
|
|
@@ -0,0 +1,89 @@
|
|
|
1
|
+
import { AgentRegistryControlServiceException as __BaseException } from "./AgentRegistryControlServiceException";
|
|
2
|
+
export class AccessDeniedException extends __BaseException {
|
|
3
|
+
name = "AccessDeniedException";
|
|
4
|
+
$fault = "client";
|
|
5
|
+
constructor(opts) {
|
|
6
|
+
super({
|
|
7
|
+
name: "AccessDeniedException",
|
|
8
|
+
$fault: "client",
|
|
9
|
+
...opts,
|
|
10
|
+
});
|
|
11
|
+
Object.setPrototypeOf(this, AccessDeniedException.prototype);
|
|
12
|
+
}
|
|
13
|
+
}
|
|
14
|
+
export class InternalServerException extends __BaseException {
|
|
15
|
+
name = "InternalServerException";
|
|
16
|
+
$fault = "server";
|
|
17
|
+
constructor(opts) {
|
|
18
|
+
super({
|
|
19
|
+
name: "InternalServerException",
|
|
20
|
+
$fault: "server",
|
|
21
|
+
...opts,
|
|
22
|
+
});
|
|
23
|
+
Object.setPrototypeOf(this, InternalServerException.prototype);
|
|
24
|
+
}
|
|
25
|
+
}
|
|
26
|
+
export class ResourceNotFoundException extends __BaseException {
|
|
27
|
+
name = "ResourceNotFoundException";
|
|
28
|
+
$fault = "client";
|
|
29
|
+
constructor(opts) {
|
|
30
|
+
super({
|
|
31
|
+
name: "ResourceNotFoundException",
|
|
32
|
+
$fault: "client",
|
|
33
|
+
...opts,
|
|
34
|
+
});
|
|
35
|
+
Object.setPrototypeOf(this, ResourceNotFoundException.prototype);
|
|
36
|
+
}
|
|
37
|
+
}
|
|
38
|
+
export class ThrottlingException extends __BaseException {
|
|
39
|
+
name = "ThrottlingException";
|
|
40
|
+
$fault = "client";
|
|
41
|
+
constructor(opts) {
|
|
42
|
+
super({
|
|
43
|
+
name: "ThrottlingException",
|
|
44
|
+
$fault: "client",
|
|
45
|
+
...opts,
|
|
46
|
+
});
|
|
47
|
+
Object.setPrototypeOf(this, ThrottlingException.prototype);
|
|
48
|
+
}
|
|
49
|
+
}
|
|
50
|
+
export class ValidationException extends __BaseException {
|
|
51
|
+
name = "ValidationException";
|
|
52
|
+
$fault = "client";
|
|
53
|
+
reason;
|
|
54
|
+
fieldList;
|
|
55
|
+
constructor(opts) {
|
|
56
|
+
super({
|
|
57
|
+
name: "ValidationException",
|
|
58
|
+
$fault: "client",
|
|
59
|
+
...opts,
|
|
60
|
+
});
|
|
61
|
+
Object.setPrototypeOf(this, ValidationException.prototype);
|
|
62
|
+
this.reason = opts.reason;
|
|
63
|
+
this.fieldList = opts.fieldList;
|
|
64
|
+
}
|
|
65
|
+
}
|
|
66
|
+
export class ConflictException extends __BaseException {
|
|
67
|
+
name = "ConflictException";
|
|
68
|
+
$fault = "client";
|
|
69
|
+
constructor(opts) {
|
|
70
|
+
super({
|
|
71
|
+
name: "ConflictException",
|
|
72
|
+
$fault: "client",
|
|
73
|
+
...opts,
|
|
74
|
+
});
|
|
75
|
+
Object.setPrototypeOf(this, ConflictException.prototype);
|
|
76
|
+
}
|
|
77
|
+
}
|
|
78
|
+
export class ServiceQuotaExceededException extends __BaseException {
|
|
79
|
+
name = "ServiceQuotaExceededException";
|
|
80
|
+
$fault = "client";
|
|
81
|
+
constructor(opts) {
|
|
82
|
+
super({
|
|
83
|
+
name: "ServiceQuotaExceededException",
|
|
84
|
+
$fault: "client",
|
|
85
|
+
...opts,
|
|
86
|
+
});
|
|
87
|
+
Object.setPrototypeOf(this, ServiceQuotaExceededException.prototype);
|
|
88
|
+
}
|
|
89
|
+
}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
|
@@ -0,0 +1,4 @@
|
|
|
1
|
+
import { createPaginator } from "@smithy/core";
|
|
2
|
+
import { AgentRegistryControlClient } from "../AgentRegistryControlClient";
|
|
3
|
+
import { ListRegistriesCommand, } from "../commands/ListRegistriesCommand";
|
|
4
|
+
export const paginateListRegistries = createPaginator(AgentRegistryControlClient, ListRegistriesCommand, "nextToken", "nextToken", "maxResults");
|
|
@@ -0,0 +1,4 @@
|
|
|
1
|
+
import { createPaginator } from "@smithy/core";
|
|
2
|
+
import { AgentRegistryControlClient } from "../AgentRegistryControlClient";
|
|
3
|
+
import { ListRegistryRecordsCommand, } from "../commands/ListRegistryRecordsCommand";
|
|
4
|
+
export const paginateListRegistryRecords = createPaginator(AgentRegistryControlClient, ListRegistryRecordsCommand, "nextToken", "nextToken", "maxResults");
|
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
import packageInfo from "../package.json";
|
|
2
|
+
import { createDefaultUserAgentProvider } from "@aws-sdk/core/client";
|
|
3
|
+
import { invalidProvider, loadConfigsForDefaultMode } from "@smithy/core/client";
|
|
4
|
+
import { DEFAULT_USE_DUALSTACK_ENDPOINT, DEFAULT_USE_FIPS_ENDPOINT, resolveDefaultsModeConfig, } from "@smithy/core/config";
|
|
5
|
+
import { DEFAULT_MAX_ATTEMPTS, DEFAULT_RETRY_MODE } from "@smithy/core/retry";
|
|
6
|
+
import { calculateBodyLength } from "@smithy/core/serde";
|
|
7
|
+
import { FetchHttpHandler as RequestHandler, streamCollector } from "@smithy/fetch-http-handler";
|
|
8
|
+
import { getRuntimeConfig as getSharedRuntimeConfig } from "./runtimeConfig.shared";
|
|
9
|
+
export const getRuntimeConfig = (config) => {
|
|
10
|
+
const defaultsMode = resolveDefaultsModeConfig(config);
|
|
11
|
+
const defaultConfigProvider = () => defaultsMode().then(loadConfigsForDefaultMode);
|
|
12
|
+
const clientSharedValues = getSharedRuntimeConfig(config);
|
|
13
|
+
return {
|
|
14
|
+
...clientSharedValues,
|
|
15
|
+
...config,
|
|
16
|
+
runtime: "browser",
|
|
17
|
+
defaultsMode,
|
|
18
|
+
bodyLengthChecker: config?.bodyLengthChecker ?? calculateBodyLength,
|
|
19
|
+
credentialDefaultProvider: config?.credentialDefaultProvider ?? ((_) => () => Promise.reject(new Error("Credential is missing"))),
|
|
20
|
+
defaultUserAgentProvider: config?.defaultUserAgentProvider ?? createDefaultUserAgentProvider({ serviceId: clientSharedValues.serviceId, clientVersion: packageInfo.version }),
|
|
21
|
+
maxAttempts: config?.maxAttempts ?? DEFAULT_MAX_ATTEMPTS,
|
|
22
|
+
region: config?.region ?? invalidProvider("Region is missing"),
|
|
23
|
+
requestHandler: RequestHandler.create(config?.requestHandler ?? defaultConfigProvider),
|
|
24
|
+
retryMode: config?.retryMode ?? (async () => (await defaultConfigProvider()).retryMode || DEFAULT_RETRY_MODE),
|
|
25
|
+
streamCollector: config?.streamCollector ?? streamCollector,
|
|
26
|
+
useDualstackEndpoint: config?.useDualstackEndpoint ?? (() => Promise.resolve(DEFAULT_USE_DUALSTACK_ENDPOINT)),
|
|
27
|
+
useFipsEndpoint: config?.useFipsEndpoint ?? (() => Promise.resolve(DEFAULT_USE_FIPS_ENDPOINT)),
|
|
28
|
+
};
|
|
29
|
+
};
|
|
@@ -0,0 +1,43 @@
|
|
|
1
|
+
import packageInfo from "../package.json";
|
|
2
|
+
import { createDefaultUserAgentProvider, emitWarningIfUnsupportedVersion as awsCheckVersion, NODE_APP_ID_CONFIG_OPTIONS, } from "@aws-sdk/core/client";
|
|
3
|
+
import { NODE_AUTH_SCHEME_PREFERENCE_OPTIONS } from "@aws-sdk/core/httpAuthSchemes";
|
|
4
|
+
import { defaultProvider as credentialDefaultProvider } from "@aws-sdk/credential-provider-node";
|
|
5
|
+
import { emitWarningIfUnsupportedVersion, loadConfigsForDefaultMode } from "@smithy/core/client";
|
|
6
|
+
import { loadConfig as loadNodeConfig, NODE_REGION_CONFIG_FILE_OPTIONS, NODE_REGION_CONFIG_OPTIONS, NODE_USE_DUALSTACK_ENDPOINT_CONFIG_OPTIONS, NODE_USE_FIPS_ENDPOINT_CONFIG_OPTIONS, resolveDefaultsModeConfig, } from "@smithy/core/config";
|
|
7
|
+
import { DEFAULT_RETRY_MODE, NODE_MAX_ATTEMPT_CONFIG_OPTIONS, NODE_RETRY_MODE_CONFIG_OPTIONS, } from "@smithy/core/retry";
|
|
8
|
+
import { calculateBodyLength } from "@smithy/core/serde";
|
|
9
|
+
import { NodeHttpHandler as RequestHandler, streamCollector } from "@smithy/node-http-handler";
|
|
10
|
+
import { getRuntimeConfig as getSharedRuntimeConfig } from "./runtimeConfig.shared";
|
|
11
|
+
export const getRuntimeConfig = (config) => {
|
|
12
|
+
emitWarningIfUnsupportedVersion(process.version);
|
|
13
|
+
const defaultsMode = resolveDefaultsModeConfig(config);
|
|
14
|
+
const defaultConfigProvider = () => defaultsMode().then(loadConfigsForDefaultMode);
|
|
15
|
+
const clientSharedValues = getSharedRuntimeConfig(config);
|
|
16
|
+
awsCheckVersion(process.version);
|
|
17
|
+
const loaderConfig = {
|
|
18
|
+
profile: config?.profile,
|
|
19
|
+
logger: clientSharedValues.logger,
|
|
20
|
+
};
|
|
21
|
+
return {
|
|
22
|
+
...clientSharedValues,
|
|
23
|
+
...config,
|
|
24
|
+
runtime: "node",
|
|
25
|
+
defaultsMode,
|
|
26
|
+
authSchemePreference: config?.authSchemePreference ?? loadNodeConfig(NODE_AUTH_SCHEME_PREFERENCE_OPTIONS, loaderConfig),
|
|
27
|
+
bodyLengthChecker: config?.bodyLengthChecker ?? calculateBodyLength,
|
|
28
|
+
credentialDefaultProvider: config?.credentialDefaultProvider ?? credentialDefaultProvider,
|
|
29
|
+
defaultUserAgentProvider: config?.defaultUserAgentProvider ?? createDefaultUserAgentProvider({ serviceId: clientSharedValues.serviceId, clientVersion: packageInfo.version }),
|
|
30
|
+
maxAttempts: config?.maxAttempts ?? loadNodeConfig(NODE_MAX_ATTEMPT_CONFIG_OPTIONS, config),
|
|
31
|
+
region: config?.region ?? loadNodeConfig(NODE_REGION_CONFIG_OPTIONS, { ...NODE_REGION_CONFIG_FILE_OPTIONS, ...loaderConfig }),
|
|
32
|
+
requestHandler: RequestHandler.create(config?.requestHandler ?? defaultConfigProvider),
|
|
33
|
+
retryMode: config?.retryMode ??
|
|
34
|
+
loadNodeConfig({
|
|
35
|
+
...NODE_RETRY_MODE_CONFIG_OPTIONS,
|
|
36
|
+
default: async () => (await defaultConfigProvider()).retryMode || DEFAULT_RETRY_MODE,
|
|
37
|
+
}, config),
|
|
38
|
+
streamCollector: config?.streamCollector ?? streamCollector,
|
|
39
|
+
useDualstackEndpoint: config?.useDualstackEndpoint ?? loadNodeConfig(NODE_USE_DUALSTACK_ENDPOINT_CONFIG_OPTIONS, loaderConfig),
|
|
40
|
+
useFipsEndpoint: config?.useFipsEndpoint ?? loadNodeConfig(NODE_USE_FIPS_ENDPOINT_CONFIG_OPTIONS, loaderConfig),
|
|
41
|
+
userAgentAppId: config?.userAgentAppId ?? loadNodeConfig(NODE_APP_ID_CONFIG_OPTIONS, loaderConfig),
|
|
42
|
+
};
|
|
43
|
+
};
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import { getRuntimeConfig as getBrowserRuntimeConfig } from "./runtimeConfig.browser";
|
|
2
|
+
export const getRuntimeConfig = (config) => {
|
|
3
|
+
const browserDefaults = getBrowserRuntimeConfig(config);
|
|
4
|
+
return {
|
|
5
|
+
...browserDefaults,
|
|
6
|
+
...config,
|
|
7
|
+
runtime: "react-native",
|
|
8
|
+
};
|
|
9
|
+
};
|