@wildix/wim-tools-client 1.0.6 → 3.1.3
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/dist-cjs/Tools.js +3 -3
- package/dist-cjs/ToolsClient.js +34 -25
- package/dist-cjs/auth/httpAuthExtensionConfiguration.js +43 -0
- package/dist-cjs/auth/httpAuthSchemeProvider.js +46 -0
- package/dist-cjs/commands/CreateToolCommand.js +10 -11
- package/dist-cjs/commands/DeleteToolCommand.js +10 -11
- package/dist-cjs/commands/DescribeToolsCommand.js +10 -11
- package/dist-cjs/commands/DiscoverToolsCommand.js +10 -11
- package/dist-cjs/commands/ExecuteToolCommand.js +10 -11
- package/dist-cjs/commands/GetToolCommand.js +10 -11
- package/dist-cjs/commands/ListToolsCommand.js +10 -11
- package/dist-cjs/commands/UpdateToolCommand.js +10 -11
- package/dist-cjs/endpoint/EndpointParameters.js +16 -0
- package/dist-cjs/endpoint/bdd.js +28 -0
- package/dist-cjs/endpoint/endpointResolver.js +16 -0
- package/dist-cjs/index.js +4 -1
- package/dist-cjs/models/ToolsServiceException.js +3 -3
- package/dist-cjs/models/enums.js +18 -0
- package/dist-cjs/models/errors.js +99 -0
- package/dist-cjs/models/models_0.js +0 -183
- package/dist-cjs/runtimeConfig.browser.js +11 -11
- package/dist-cjs/runtimeConfig.js +22 -18
- package/dist-cjs/runtimeConfig.shared.js +30 -10
- package/dist-cjs/runtimeExtensions.js +6 -5
- package/dist-cjs/schemas/schemas_0.js +458 -0
- package/dist-es/Tools.js +4 -4
- package/dist-es/ToolsClient.js +30 -21
- package/dist-es/auth/httpAuthExtensionConfiguration.js +38 -0
- package/dist-es/auth/httpAuthSchemeProvider.js +40 -0
- package/dist-es/commands/CreateToolCommand.js +9 -10
- package/dist-es/commands/DeleteToolCommand.js +9 -10
- package/dist-es/commands/DescribeToolsCommand.js +9 -10
- package/dist-es/commands/DiscoverToolsCommand.js +9 -10
- package/dist-es/commands/ExecuteToolCommand.js +9 -10
- package/dist-es/commands/GetToolCommand.js +9 -10
- package/dist-es/commands/ListToolsCommand.js +9 -10
- package/dist-es/commands/UpdateToolCommand.js +9 -10
- package/dist-es/endpoint/EndpointParameters.js +12 -0
- package/dist-es/endpoint/bdd.js +25 -0
- package/dist-es/endpoint/endpointResolver.js +12 -0
- package/dist-es/index.js +4 -1
- package/dist-es/models/ToolsServiceException.js +1 -1
- package/dist-es/models/enums.js +15 -0
- package/dist-es/models/errors.js +89 -0
- package/dist-es/models/models_0.js +1 -175
- package/dist-es/runtimeConfig.browser.js +7 -7
- package/dist-es/runtimeConfig.js +17 -13
- package/dist-es/runtimeConfig.shared.js +24 -4
- package/dist-es/runtimeExtensions.js +6 -5
- package/dist-es/schemas/schemas_0.js +454 -0
- package/dist-types/Tools.d.ts +9 -9
- package/dist-types/ToolsClient.d.ts +38 -21
- package/dist-types/auth/httpAuthExtensionConfiguration.d.ts +29 -0
- package/dist-types/auth/httpAuthSchemeProvider.d.ts +81 -0
- package/dist-types/commands/CreateToolCommand.d.ts +11 -13
- package/dist-types/commands/DeleteToolCommand.d.ts +11 -7
- package/dist-types/commands/DescribeToolsCommand.d.ts +11 -7
- package/dist-types/commands/DiscoverToolsCommand.d.ts +11 -7
- package/dist-types/commands/ExecuteToolCommand.d.ts +11 -7
- package/dist-types/commands/GetToolCommand.d.ts +11 -10
- package/dist-types/commands/ListToolsCommand.d.ts +11 -10
- package/dist-types/commands/UpdateToolCommand.d.ts +11 -13
- package/dist-types/endpoint/EndpointParameters.d.ts +41 -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 +4 -3
- package/dist-types/index.d.ts +5 -1
- package/dist-types/models/ToolsServiceException.d.ts +1 -1
- package/dist-types/models/enums.d.ts +31 -0
- package/dist-types/models/errors.d.ts +90 -0
- package/dist-types/models/models_0.d.ts +33 -182
- package/dist-types/runtimeConfig.browser.d.ts +35 -17
- package/dist-types/runtimeConfig.d.ts +34 -16
- package/dist-types/runtimeConfig.native.d.ts +36 -18
- package/dist-types/runtimeConfig.shared.d.ts +20 -3
- package/dist-types/runtimeExtensions.d.ts +1 -1
- package/dist-types/schemas/schemas_0.d.ts +66 -0
- package/package.json +14 -39
- package/dist-cjs/models/index.js +0 -4
- package/dist-cjs/protocols/Aws_restJson1.js +0 -518
- package/dist-es/models/index.js +0 -1
- package/dist-es/protocols/Aws_restJson1.js +0 -499
- package/dist-types/models/index.d.ts +0 -1
- package/dist-types/protocols/Aws_restJson1.d.ts +0 -74
package/dist-cjs/Tools.js
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.Tools = void 0;
|
|
4
|
-
const
|
|
4
|
+
const client_1 = require("@smithy/core/client");
|
|
5
5
|
const CreateToolCommand_1 = require("./commands/CreateToolCommand");
|
|
6
6
|
const DeleteToolCommand_1 = require("./commands/DeleteToolCommand");
|
|
7
7
|
const DescribeToolsCommand_1 = require("./commands/DescribeToolsCommand");
|
|
@@ -10,7 +10,7 @@ const ExecuteToolCommand_1 = require("./commands/ExecuteToolCommand");
|
|
|
10
10
|
const GetToolCommand_1 = require("./commands/GetToolCommand");
|
|
11
11
|
const ListToolsCommand_1 = require("./commands/ListToolsCommand");
|
|
12
12
|
const UpdateToolCommand_1 = require("./commands/UpdateToolCommand");
|
|
13
|
-
const
|
|
13
|
+
const ToolsClient_1 = require("./ToolsClient");
|
|
14
14
|
const commands = {
|
|
15
15
|
CreateToolCommand: CreateToolCommand_1.CreateToolCommand,
|
|
16
16
|
DeleteToolCommand: DeleteToolCommand_1.DeleteToolCommand,
|
|
@@ -24,4 +24,4 @@ const commands = {
|
|
|
24
24
|
class Tools extends ToolsClient_1.ToolsClient {
|
|
25
25
|
}
|
|
26
26
|
exports.Tools = Tools;
|
|
27
|
-
(0,
|
|
27
|
+
(0, client_1.createAggregatedClient)(commands, Tools);
|
package/dist-cjs/ToolsClient.js
CHANGED
|
@@ -1,37 +1,46 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.ToolsClient = exports.__Client = void 0;
|
|
4
|
+
const client_1 = require("@aws-sdk/core/client");
|
|
5
|
+
const core_1 = require("@smithy/core");
|
|
6
|
+
const client_2 = require("@smithy/core/client");
|
|
7
|
+
Object.defineProperty(exports, "__Client", { enumerable: true, get: function () { return client_2.Client; } });
|
|
8
|
+
const endpoints_1 = require("@smithy/core/endpoints");
|
|
9
|
+
const protocols_1 = require("@smithy/core/protocols");
|
|
10
|
+
const retry_1 = require("@smithy/core/retry");
|
|
11
|
+
const schema_1 = require("@smithy/core/schema");
|
|
12
|
+
const httpAuthSchemeProvider_1 = require("./auth/httpAuthSchemeProvider");
|
|
13
|
+
const EndpointParameters_1 = require("./endpoint/EndpointParameters");
|
|
4
14
|
const runtimeConfig_1 = require("./runtimeConfig");
|
|
5
15
|
const runtimeExtensions_1 = require("./runtimeExtensions");
|
|
6
|
-
|
|
7
|
-
const middleware_content_length_1 = require("@smithy/middleware-content-length");
|
|
8
|
-
const middleware_retry_1 = require("@smithy/middleware-retry");
|
|
9
|
-
const smithy_client_1 = require("@smithy/smithy-client");
|
|
10
|
-
Object.defineProperty(exports, "__Client", { enumerable: true, get: function () { return smithy_client_1.Client; } });
|
|
11
|
-
const smithy_utils_1 = require("@wildix/smithy-utils");
|
|
12
|
-
class ToolsClient extends smithy_client_1.Client {
|
|
16
|
+
class ToolsClient extends client_2.Client {
|
|
13
17
|
config;
|
|
14
18
|
constructor(...[configuration]) {
|
|
15
|
-
|
|
19
|
+
const _config_0 = (0, runtimeConfig_1.getRuntimeConfig)(configuration || {});
|
|
16
20
|
super(_config_0);
|
|
17
21
|
this.initConfig = _config_0;
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
const
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
this.
|
|
31
|
-
this.middlewareStack.
|
|
32
|
-
this.middlewareStack.use((0,
|
|
33
|
-
this.middlewareStack.use((0,
|
|
34
|
-
|
|
22
|
+
const _config_1 = (0, EndpointParameters_1.resolveClientEndpointParameters)(_config_0);
|
|
23
|
+
const _config_2 = (0, client_1.resolveUserAgentConfig)(_config_1);
|
|
24
|
+
const _config_3 = (0, retry_1.resolveRetryConfig)(_config_2);
|
|
25
|
+
const _config_4 = (0, client_1.resolveHostHeaderConfig)(_config_3);
|
|
26
|
+
const _config_5 = (0, endpoints_1.resolveEndpointConfig)(_config_4);
|
|
27
|
+
const _config_6 = (0, httpAuthSchemeProvider_1.resolveHttpAuthSchemeConfig)(_config_5);
|
|
28
|
+
const _config_7 = (0, runtimeExtensions_1.resolveRuntimeExtensions)(_config_6, configuration?.extensions || []);
|
|
29
|
+
this.config = _config_7;
|
|
30
|
+
this.middlewareStack.use((0, schema_1.getSchemaSerdePlugin)(this.config));
|
|
31
|
+
this.middlewareStack.use((0, client_1.getUserAgentPlugin)(this.config));
|
|
32
|
+
this.middlewareStack.use((0, retry_1.getRetryPlugin)(this.config));
|
|
33
|
+
this.middlewareStack.use((0, protocols_1.getContentLengthPlugin)(this.config));
|
|
34
|
+
this.middlewareStack.use((0, client_1.getHostHeaderPlugin)(this.config));
|
|
35
|
+
this.middlewareStack.use((0, client_1.getLoggerPlugin)(this.config));
|
|
36
|
+
this.middlewareStack.use((0, client_1.getRecursionDetectionPlugin)(this.config));
|
|
37
|
+
this.middlewareStack.use((0, core_1.getHttpAuthSchemeEndpointRuleSetPlugin)(this.config, {
|
|
38
|
+
httpAuthSchemeParametersProvider: httpAuthSchemeProvider_1.defaultToolsHttpAuthSchemeParametersProvider,
|
|
39
|
+
identityProviderConfigProvider: async (config) => new core_1.DefaultIdentityProviderConfig({
|
|
40
|
+
"smithy.api#httpBearerAuth": config.token,
|
|
41
|
+
}),
|
|
42
|
+
}));
|
|
43
|
+
this.middlewareStack.use((0, core_1.getHttpSigningPlugin)(this.config));
|
|
35
44
|
}
|
|
36
45
|
destroy() {
|
|
37
46
|
super.destroy();
|
|
@@ -0,0 +1,43 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.resolveHttpAuthRuntimeConfig = exports.getHttpAuthExtensionConfiguration = void 0;
|
|
4
|
+
const getHttpAuthExtensionConfiguration = (runtimeConfig) => {
|
|
5
|
+
const _httpAuthSchemes = runtimeConfig.httpAuthSchemes;
|
|
6
|
+
let _httpAuthSchemeProvider = runtimeConfig.httpAuthSchemeProvider;
|
|
7
|
+
let _token = runtimeConfig.token;
|
|
8
|
+
return {
|
|
9
|
+
setHttpAuthScheme(httpAuthScheme) {
|
|
10
|
+
const index = _httpAuthSchemes.findIndex((scheme) => scheme.schemeId === httpAuthScheme.schemeId);
|
|
11
|
+
if (index === -1) {
|
|
12
|
+
_httpAuthSchemes.push(httpAuthScheme);
|
|
13
|
+
}
|
|
14
|
+
else {
|
|
15
|
+
_httpAuthSchemes.splice(index, 1, httpAuthScheme);
|
|
16
|
+
}
|
|
17
|
+
},
|
|
18
|
+
httpAuthSchemes() {
|
|
19
|
+
return _httpAuthSchemes;
|
|
20
|
+
},
|
|
21
|
+
setHttpAuthSchemeProvider(httpAuthSchemeProvider) {
|
|
22
|
+
_httpAuthSchemeProvider = httpAuthSchemeProvider;
|
|
23
|
+
},
|
|
24
|
+
httpAuthSchemeProvider() {
|
|
25
|
+
return _httpAuthSchemeProvider;
|
|
26
|
+
},
|
|
27
|
+
setToken(token) {
|
|
28
|
+
_token = token;
|
|
29
|
+
},
|
|
30
|
+
token() {
|
|
31
|
+
return _token;
|
|
32
|
+
},
|
|
33
|
+
};
|
|
34
|
+
};
|
|
35
|
+
exports.getHttpAuthExtensionConfiguration = getHttpAuthExtensionConfiguration;
|
|
36
|
+
const resolveHttpAuthRuntimeConfig = (config) => {
|
|
37
|
+
return {
|
|
38
|
+
httpAuthSchemes: config.httpAuthSchemes(),
|
|
39
|
+
httpAuthSchemeProvider: config.httpAuthSchemeProvider(),
|
|
40
|
+
token: config.token(),
|
|
41
|
+
};
|
|
42
|
+
};
|
|
43
|
+
exports.resolveHttpAuthRuntimeConfig = resolveHttpAuthRuntimeConfig;
|
|
@@ -0,0 +1,46 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.resolveHttpAuthSchemeConfig = exports.defaultToolsHttpAuthSchemeProvider = exports.defaultToolsHttpAuthSchemeParametersProvider = void 0;
|
|
4
|
+
const core_1 = require("@smithy/core");
|
|
5
|
+
const client_1 = require("@smithy/core/client");
|
|
6
|
+
const defaultToolsHttpAuthSchemeParametersProvider = async (config, context, input) => {
|
|
7
|
+
return {
|
|
8
|
+
operation: (0, client_1.getSmithyContext)(context).operation,
|
|
9
|
+
};
|
|
10
|
+
};
|
|
11
|
+
exports.defaultToolsHttpAuthSchemeParametersProvider = defaultToolsHttpAuthSchemeParametersProvider;
|
|
12
|
+
function createSmithyApiHttpBearerAuthHttpAuthOption(authParameters) {
|
|
13
|
+
return {
|
|
14
|
+
schemeId: "smithy.api#httpBearerAuth",
|
|
15
|
+
};
|
|
16
|
+
}
|
|
17
|
+
function createWildixAuthPbxHttpAuthOption(authParameters) {
|
|
18
|
+
return {
|
|
19
|
+
schemeId: "wildix.auth#pbx",
|
|
20
|
+
};
|
|
21
|
+
}
|
|
22
|
+
function createWildixAuthS2sHttpAuthOption(authParameters) {
|
|
23
|
+
return {
|
|
24
|
+
schemeId: "wildix.auth#s2s",
|
|
25
|
+
};
|
|
26
|
+
}
|
|
27
|
+
const defaultToolsHttpAuthSchemeProvider = (authParameters) => {
|
|
28
|
+
const options = [];
|
|
29
|
+
switch (authParameters.operation) {
|
|
30
|
+
default: {
|
|
31
|
+
options.push(createSmithyApiHttpBearerAuthHttpAuthOption(authParameters));
|
|
32
|
+
options.push(createWildixAuthS2sHttpAuthOption(authParameters));
|
|
33
|
+
options.push(createWildixAuthPbxHttpAuthOption(authParameters));
|
|
34
|
+
}
|
|
35
|
+
}
|
|
36
|
+
return options;
|
|
37
|
+
};
|
|
38
|
+
exports.defaultToolsHttpAuthSchemeProvider = defaultToolsHttpAuthSchemeProvider;
|
|
39
|
+
const resolveHttpAuthSchemeConfig = (config) => {
|
|
40
|
+
const token = (0, core_1.memoizeIdentityProvider)(config.token, core_1.isIdentityExpired, core_1.doesIdentityRequireRefresh);
|
|
41
|
+
return Object.assign(config, {
|
|
42
|
+
authSchemePreference: (0, client_1.normalizeProvider)(config.authSchemePreference ?? []),
|
|
43
|
+
token,
|
|
44
|
+
});
|
|
45
|
+
};
|
|
46
|
+
exports.resolveHttpAuthSchemeConfig = resolveHttpAuthSchemeConfig;
|
|
@@ -1,21 +1,20 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.CreateToolCommand = exports.$Command = void 0;
|
|
4
|
-
const
|
|
5
|
-
|
|
6
|
-
const
|
|
7
|
-
|
|
8
|
-
|
|
4
|
+
const client_1 = require("@smithy/core/client");
|
|
5
|
+
Object.defineProperty(exports, "$Command", { enumerable: true, get: function () { return client_1.Command; } });
|
|
6
|
+
const endpoints_1 = require("@smithy/core/endpoints");
|
|
7
|
+
const EndpointParameters_1 = require("../endpoint/EndpointParameters");
|
|
8
|
+
const schemas_0_1 = require("../schemas/schemas_0");
|
|
9
|
+
class CreateToolCommand extends client_1.Command
|
|
10
|
+
.classBuilder()
|
|
11
|
+
.ep(EndpointParameters_1.commonParams)
|
|
9
12
|
.m(function (Command, cs, config, o) {
|
|
10
|
-
return [
|
|
11
|
-
(0, middleware_serde_1.getSerdePlugin)(config, this.serialize, this.deserialize),
|
|
12
|
-
];
|
|
13
|
+
return [(0, endpoints_1.getEndpointPlugin)(config, Command.getEndpointParameterInstructions())];
|
|
13
14
|
})
|
|
14
15
|
.s("Tools", "CreateTool", {})
|
|
15
16
|
.n("ToolsClient", "CreateToolCommand")
|
|
16
|
-
.
|
|
17
|
-
.ser(Aws_restJson1_1.se_CreateToolCommand)
|
|
18
|
-
.de(Aws_restJson1_1.de_CreateToolCommand)
|
|
17
|
+
.sc(schemas_0_1.CreateTool$)
|
|
19
18
|
.build() {
|
|
20
19
|
}
|
|
21
20
|
exports.CreateToolCommand = CreateToolCommand;
|
|
@@ -1,21 +1,20 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.DeleteToolCommand = exports.$Command = void 0;
|
|
4
|
-
const
|
|
5
|
-
|
|
6
|
-
const
|
|
7
|
-
|
|
8
|
-
|
|
4
|
+
const client_1 = require("@smithy/core/client");
|
|
5
|
+
Object.defineProperty(exports, "$Command", { enumerable: true, get: function () { return client_1.Command; } });
|
|
6
|
+
const endpoints_1 = require("@smithy/core/endpoints");
|
|
7
|
+
const EndpointParameters_1 = require("../endpoint/EndpointParameters");
|
|
8
|
+
const schemas_0_1 = require("../schemas/schemas_0");
|
|
9
|
+
class DeleteToolCommand extends client_1.Command
|
|
10
|
+
.classBuilder()
|
|
11
|
+
.ep(EndpointParameters_1.commonParams)
|
|
9
12
|
.m(function (Command, cs, config, o) {
|
|
10
|
-
return [
|
|
11
|
-
(0, middleware_serde_1.getSerdePlugin)(config, this.serialize, this.deserialize),
|
|
12
|
-
];
|
|
13
|
+
return [(0, endpoints_1.getEndpointPlugin)(config, Command.getEndpointParameterInstructions())];
|
|
13
14
|
})
|
|
14
15
|
.s("Tools", "DeleteTool", {})
|
|
15
16
|
.n("ToolsClient", "DeleteToolCommand")
|
|
16
|
-
.
|
|
17
|
-
.ser(Aws_restJson1_1.se_DeleteToolCommand)
|
|
18
|
-
.de(Aws_restJson1_1.de_DeleteToolCommand)
|
|
17
|
+
.sc(schemas_0_1.DeleteTool$)
|
|
19
18
|
.build() {
|
|
20
19
|
}
|
|
21
20
|
exports.DeleteToolCommand = DeleteToolCommand;
|
|
@@ -1,21 +1,20 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.DescribeToolsCommand = exports.$Command = void 0;
|
|
4
|
-
const
|
|
5
|
-
|
|
6
|
-
const
|
|
7
|
-
|
|
8
|
-
|
|
4
|
+
const client_1 = require("@smithy/core/client");
|
|
5
|
+
Object.defineProperty(exports, "$Command", { enumerable: true, get: function () { return client_1.Command; } });
|
|
6
|
+
const endpoints_1 = require("@smithy/core/endpoints");
|
|
7
|
+
const EndpointParameters_1 = require("../endpoint/EndpointParameters");
|
|
8
|
+
const schemas_0_1 = require("../schemas/schemas_0");
|
|
9
|
+
class DescribeToolsCommand extends client_1.Command
|
|
10
|
+
.classBuilder()
|
|
11
|
+
.ep(EndpointParameters_1.commonParams)
|
|
9
12
|
.m(function (Command, cs, config, o) {
|
|
10
|
-
return [
|
|
11
|
-
(0, middleware_serde_1.getSerdePlugin)(config, this.serialize, this.deserialize),
|
|
12
|
-
];
|
|
13
|
+
return [(0, endpoints_1.getEndpointPlugin)(config, Command.getEndpointParameterInstructions())];
|
|
13
14
|
})
|
|
14
15
|
.s("Tools", "DescribeTools", {})
|
|
15
16
|
.n("ToolsClient", "DescribeToolsCommand")
|
|
16
|
-
.
|
|
17
|
-
.ser(Aws_restJson1_1.se_DescribeToolsCommand)
|
|
18
|
-
.de(Aws_restJson1_1.de_DescribeToolsCommand)
|
|
17
|
+
.sc(schemas_0_1.DescribeTools$)
|
|
19
18
|
.build() {
|
|
20
19
|
}
|
|
21
20
|
exports.DescribeToolsCommand = DescribeToolsCommand;
|
|
@@ -1,21 +1,20 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.DiscoverToolsCommand = exports.$Command = void 0;
|
|
4
|
-
const
|
|
5
|
-
|
|
6
|
-
const
|
|
7
|
-
|
|
8
|
-
|
|
4
|
+
const client_1 = require("@smithy/core/client");
|
|
5
|
+
Object.defineProperty(exports, "$Command", { enumerable: true, get: function () { return client_1.Command; } });
|
|
6
|
+
const endpoints_1 = require("@smithy/core/endpoints");
|
|
7
|
+
const EndpointParameters_1 = require("../endpoint/EndpointParameters");
|
|
8
|
+
const schemas_0_1 = require("../schemas/schemas_0");
|
|
9
|
+
class DiscoverToolsCommand extends client_1.Command
|
|
10
|
+
.classBuilder()
|
|
11
|
+
.ep(EndpointParameters_1.commonParams)
|
|
9
12
|
.m(function (Command, cs, config, o) {
|
|
10
|
-
return [
|
|
11
|
-
(0, middleware_serde_1.getSerdePlugin)(config, this.serialize, this.deserialize),
|
|
12
|
-
];
|
|
13
|
+
return [(0, endpoints_1.getEndpointPlugin)(config, Command.getEndpointParameterInstructions())];
|
|
13
14
|
})
|
|
14
15
|
.s("Tools", "DiscoverTools", {})
|
|
15
16
|
.n("ToolsClient", "DiscoverToolsCommand")
|
|
16
|
-
.
|
|
17
|
-
.ser(Aws_restJson1_1.se_DiscoverToolsCommand)
|
|
18
|
-
.de(Aws_restJson1_1.de_DiscoverToolsCommand)
|
|
17
|
+
.sc(schemas_0_1.DiscoverTools$)
|
|
19
18
|
.build() {
|
|
20
19
|
}
|
|
21
20
|
exports.DiscoverToolsCommand = DiscoverToolsCommand;
|
|
@@ -1,21 +1,20 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.ExecuteToolCommand = exports.$Command = void 0;
|
|
4
|
-
const
|
|
5
|
-
|
|
6
|
-
const
|
|
7
|
-
|
|
8
|
-
|
|
4
|
+
const client_1 = require("@smithy/core/client");
|
|
5
|
+
Object.defineProperty(exports, "$Command", { enumerable: true, get: function () { return client_1.Command; } });
|
|
6
|
+
const endpoints_1 = require("@smithy/core/endpoints");
|
|
7
|
+
const EndpointParameters_1 = require("../endpoint/EndpointParameters");
|
|
8
|
+
const schemas_0_1 = require("../schemas/schemas_0");
|
|
9
|
+
class ExecuteToolCommand extends client_1.Command
|
|
10
|
+
.classBuilder()
|
|
11
|
+
.ep(EndpointParameters_1.commonParams)
|
|
9
12
|
.m(function (Command, cs, config, o) {
|
|
10
|
-
return [
|
|
11
|
-
(0, middleware_serde_1.getSerdePlugin)(config, this.serialize, this.deserialize),
|
|
12
|
-
];
|
|
13
|
+
return [(0, endpoints_1.getEndpointPlugin)(config, Command.getEndpointParameterInstructions())];
|
|
13
14
|
})
|
|
14
15
|
.s("Tools", "ExecuteTool", {})
|
|
15
16
|
.n("ToolsClient", "ExecuteToolCommand")
|
|
16
|
-
.
|
|
17
|
-
.ser(Aws_restJson1_1.se_ExecuteToolCommand)
|
|
18
|
-
.de(Aws_restJson1_1.de_ExecuteToolCommand)
|
|
17
|
+
.sc(schemas_0_1.ExecuteTool$)
|
|
19
18
|
.build() {
|
|
20
19
|
}
|
|
21
20
|
exports.ExecuteToolCommand = ExecuteToolCommand;
|
|
@@ -1,21 +1,20 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.GetToolCommand = exports.$Command = void 0;
|
|
4
|
-
const
|
|
5
|
-
|
|
6
|
-
const
|
|
7
|
-
|
|
8
|
-
|
|
4
|
+
const client_1 = require("@smithy/core/client");
|
|
5
|
+
Object.defineProperty(exports, "$Command", { enumerable: true, get: function () { return client_1.Command; } });
|
|
6
|
+
const endpoints_1 = require("@smithy/core/endpoints");
|
|
7
|
+
const EndpointParameters_1 = require("../endpoint/EndpointParameters");
|
|
8
|
+
const schemas_0_1 = require("../schemas/schemas_0");
|
|
9
|
+
class GetToolCommand extends client_1.Command
|
|
10
|
+
.classBuilder()
|
|
11
|
+
.ep(EndpointParameters_1.commonParams)
|
|
9
12
|
.m(function (Command, cs, config, o) {
|
|
10
|
-
return [
|
|
11
|
-
(0, middleware_serde_1.getSerdePlugin)(config, this.serialize, this.deserialize),
|
|
12
|
-
];
|
|
13
|
+
return [(0, endpoints_1.getEndpointPlugin)(config, Command.getEndpointParameterInstructions())];
|
|
13
14
|
})
|
|
14
15
|
.s("Tools", "GetTool", {})
|
|
15
16
|
.n("ToolsClient", "GetToolCommand")
|
|
16
|
-
.
|
|
17
|
-
.ser(Aws_restJson1_1.se_GetToolCommand)
|
|
18
|
-
.de(Aws_restJson1_1.de_GetToolCommand)
|
|
17
|
+
.sc(schemas_0_1.GetTool$)
|
|
19
18
|
.build() {
|
|
20
19
|
}
|
|
21
20
|
exports.GetToolCommand = GetToolCommand;
|
|
@@ -1,21 +1,20 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.ListToolsCommand = exports.$Command = void 0;
|
|
4
|
-
const
|
|
5
|
-
|
|
6
|
-
const
|
|
7
|
-
|
|
8
|
-
|
|
4
|
+
const client_1 = require("@smithy/core/client");
|
|
5
|
+
Object.defineProperty(exports, "$Command", { enumerable: true, get: function () { return client_1.Command; } });
|
|
6
|
+
const endpoints_1 = require("@smithy/core/endpoints");
|
|
7
|
+
const EndpointParameters_1 = require("../endpoint/EndpointParameters");
|
|
8
|
+
const schemas_0_1 = require("../schemas/schemas_0");
|
|
9
|
+
class ListToolsCommand extends client_1.Command
|
|
10
|
+
.classBuilder()
|
|
11
|
+
.ep(EndpointParameters_1.commonParams)
|
|
9
12
|
.m(function (Command, cs, config, o) {
|
|
10
|
-
return [
|
|
11
|
-
(0, middleware_serde_1.getSerdePlugin)(config, this.serialize, this.deserialize),
|
|
12
|
-
];
|
|
13
|
+
return [(0, endpoints_1.getEndpointPlugin)(config, Command.getEndpointParameterInstructions())];
|
|
13
14
|
})
|
|
14
15
|
.s("Tools", "ListTools", {})
|
|
15
16
|
.n("ToolsClient", "ListToolsCommand")
|
|
16
|
-
.
|
|
17
|
-
.ser(Aws_restJson1_1.se_ListToolsCommand)
|
|
18
|
-
.de(Aws_restJson1_1.de_ListToolsCommand)
|
|
17
|
+
.sc(schemas_0_1.ListTools$)
|
|
19
18
|
.build() {
|
|
20
19
|
}
|
|
21
20
|
exports.ListToolsCommand = ListToolsCommand;
|
|
@@ -1,21 +1,20 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.UpdateToolCommand = exports.$Command = void 0;
|
|
4
|
-
const
|
|
5
|
-
|
|
6
|
-
const
|
|
7
|
-
|
|
8
|
-
|
|
4
|
+
const client_1 = require("@smithy/core/client");
|
|
5
|
+
Object.defineProperty(exports, "$Command", { enumerable: true, get: function () { return client_1.Command; } });
|
|
6
|
+
const endpoints_1 = require("@smithy/core/endpoints");
|
|
7
|
+
const EndpointParameters_1 = require("../endpoint/EndpointParameters");
|
|
8
|
+
const schemas_0_1 = require("../schemas/schemas_0");
|
|
9
|
+
class UpdateToolCommand extends client_1.Command
|
|
10
|
+
.classBuilder()
|
|
11
|
+
.ep(EndpointParameters_1.commonParams)
|
|
9
12
|
.m(function (Command, cs, config, o) {
|
|
10
|
-
return [
|
|
11
|
-
(0, middleware_serde_1.getSerdePlugin)(config, this.serialize, this.deserialize),
|
|
12
|
-
];
|
|
13
|
+
return [(0, endpoints_1.getEndpointPlugin)(config, Command.getEndpointParameterInstructions())];
|
|
13
14
|
})
|
|
14
15
|
.s("Tools", "UpdateTool", {})
|
|
15
16
|
.n("ToolsClient", "UpdateToolCommand")
|
|
16
|
-
.
|
|
17
|
-
.ser(Aws_restJson1_1.se_UpdateToolCommand)
|
|
18
|
-
.de(Aws_restJson1_1.de_UpdateToolCommand)
|
|
17
|
+
.sc(schemas_0_1.UpdateTool$)
|
|
19
18
|
.build() {
|
|
20
19
|
}
|
|
21
20
|
exports.UpdateToolCommand = UpdateToolCommand;
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.commonParams = exports.resolveClientEndpointParameters = void 0;
|
|
4
|
+
const clientContextParamDefaults = {};
|
|
5
|
+
const resolveClientEndpointParameters = (options) => {
|
|
6
|
+
return Object.assign(options, {
|
|
7
|
+
env: options.env ?? "prod",
|
|
8
|
+
defaultSigningName: "",
|
|
9
|
+
clientContextParams: Object.assign(clientContextParamDefaults, options.clientContextParams),
|
|
10
|
+
});
|
|
11
|
+
};
|
|
12
|
+
exports.resolveClientEndpointParameters = resolveClientEndpointParameters;
|
|
13
|
+
exports.commonParams = {
|
|
14
|
+
env: { type: "clientContextParams", name: "env" },
|
|
15
|
+
endpoint: { type: "builtInParams", name: "endpoint" },
|
|
16
|
+
};
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.bdd = void 0;
|
|
4
|
+
const endpoints_1 = require("@smithy/core/endpoints");
|
|
5
|
+
const a = "stringEquals", b = { "ref": "endpoint" }, c = { "ref": "env" };
|
|
6
|
+
const _data = {
|
|
7
|
+
conditions: [
|
|
8
|
+
["isSet", [b]],
|
|
9
|
+
[a, [c, "stable"]],
|
|
10
|
+
[a, [c, "stage"]]
|
|
11
|
+
],
|
|
12
|
+
results: [
|
|
13
|
+
[-1],
|
|
14
|
+
[b, {}],
|
|
15
|
+
["https://tools.wim-stable.wildix.com", {}],
|
|
16
|
+
["https://tools.wim-stage.wildix.com", {}],
|
|
17
|
+
["https://tools.wim.wildix.com", {}]
|
|
18
|
+
]
|
|
19
|
+
};
|
|
20
|
+
const root = 2;
|
|
21
|
+
const r = 100_000_000;
|
|
22
|
+
const nodes = new Int32Array([
|
|
23
|
+
-1, 1, -1,
|
|
24
|
+
0, r + 1, 3,
|
|
25
|
+
1, r + 2, 4,
|
|
26
|
+
2, r + 3, r + 4,
|
|
27
|
+
]);
|
|
28
|
+
exports.bdd = endpoints_1.BinaryDecisionDiagram.from(nodes, root, _data.conditions, _data.results);
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.defaultEndpointResolver = void 0;
|
|
4
|
+
const endpoints_1 = require("@smithy/core/endpoints");
|
|
5
|
+
const bdd_1 = require("./bdd");
|
|
6
|
+
const cache = new endpoints_1.EndpointCache({
|
|
7
|
+
size: 50,
|
|
8
|
+
params: ["endpoint", "env"],
|
|
9
|
+
});
|
|
10
|
+
const defaultEndpointResolver = (endpointParams, context = {}) => {
|
|
11
|
+
return cache.get(endpointParams, () => (0, endpoints_1.decideEndpoint)(bdd_1.bdd, {
|
|
12
|
+
endpointParams: endpointParams,
|
|
13
|
+
logger: context.logger,
|
|
14
|
+
}));
|
|
15
|
+
};
|
|
16
|
+
exports.defaultEndpointResolver = defaultEndpointResolver;
|
package/dist-cjs/index.js
CHANGED
|
@@ -5,6 +5,9 @@ const tslib_1 = require("tslib");
|
|
|
5
5
|
tslib_1.__exportStar(require("./ToolsClient"), exports);
|
|
6
6
|
tslib_1.__exportStar(require("./Tools"), exports);
|
|
7
7
|
tslib_1.__exportStar(require("./commands"), exports);
|
|
8
|
-
tslib_1.__exportStar(require("./
|
|
8
|
+
tslib_1.__exportStar(require("./schemas/schemas_0"), exports);
|
|
9
|
+
tslib_1.__exportStar(require("./models/enums"), exports);
|
|
10
|
+
tslib_1.__exportStar(require("./models/errors"), exports);
|
|
11
|
+
tslib_1.__exportStar(require("./models/models_0"), exports);
|
|
9
12
|
var ToolsServiceException_1 = require("./models/ToolsServiceException");
|
|
10
13
|
Object.defineProperty(exports, "ToolsServiceException", { enumerable: true, get: function () { return ToolsServiceException_1.ToolsServiceException; } });
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.ToolsServiceException = exports.__ServiceException = void 0;
|
|
4
|
-
const
|
|
5
|
-
Object.defineProperty(exports, "__ServiceException", { enumerable: true, get: function () { return
|
|
6
|
-
class ToolsServiceException extends
|
|
4
|
+
const client_1 = require("@smithy/core/client");
|
|
5
|
+
Object.defineProperty(exports, "__ServiceException", { enumerable: true, get: function () { return client_1.ServiceException; } });
|
|
6
|
+
class ToolsServiceException extends client_1.ServiceException {
|
|
7
7
|
constructor(options) {
|
|
8
8
|
super(options);
|
|
9
9
|
Object.setPrototypeOf(this, ToolsServiceException.prototype);
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.ToolVariableType = exports.ToolWebhookMethod = void 0;
|
|
4
|
+
exports.ToolWebhookMethod = {
|
|
5
|
+
DELETE: "DELETE",
|
|
6
|
+
GET: "GET",
|
|
7
|
+
PATCH: "PATCH",
|
|
8
|
+
POST: "POST",
|
|
9
|
+
PUT: "PUT",
|
|
10
|
+
};
|
|
11
|
+
exports.ToolVariableType = {
|
|
12
|
+
BOOLEAN: "boolean",
|
|
13
|
+
NUMBER: "number",
|
|
14
|
+
NUMBER_ARRAY: "number_array",
|
|
15
|
+
SCHEMA: "schema",
|
|
16
|
+
STRING: "string",
|
|
17
|
+
STRING_ARRAY: "string_array",
|
|
18
|
+
};
|