@wildix/wim-tools-client 1.0.2 → 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 -174
- 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 -166
- 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 -7
- 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 -7
- package/dist-types/commands/ListToolsCommand.d.ts +11 -7
- package/dist-types/commands/UpdateToolCommand.d.ts +11 -7
- 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 +32 -136
- 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 +13 -38
- 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/package.json
CHANGED
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@wildix/wim-tools-client",
|
|
3
3
|
"description": "@wildix/wim-tools-client client",
|
|
4
|
-
"version": "1.
|
|
4
|
+
"version": "3.1.3",
|
|
5
5
|
"scripts": {
|
|
6
6
|
"build": "concurrently 'yarn:build:cjs' 'yarn:build:es' 'yarn:build:types'",
|
|
7
7
|
"build:cjs": "tsc -p tsconfig.cjs.json",
|
|
8
8
|
"build:es": "tsc -p tsconfig.es.json",
|
|
9
9
|
"build:types": "tsc -p tsconfig.types.json",
|
|
10
10
|
"build:types:downlevel": "downlevel-dts dist-types dist-types/ts3.4",
|
|
11
|
-
"clean": "
|
|
11
|
+
"clean": "premove dist-cjs dist-es dist-types tsconfig.cjs.tsbuildinfo tsconfig.es.tsbuildinfo tsconfig.types.tsbuildinfo",
|
|
12
12
|
"prepack": "yarn run clean && yarn run build",
|
|
13
13
|
"postpublish": "node ../../scripts/postpublish.js"
|
|
14
14
|
},
|
|
@@ -20,50 +20,25 @@
|
|
|
20
20
|
"tslib": "^2.6.2",
|
|
21
21
|
"@aws-crypto/sha256-browser": "5.2.0",
|
|
22
22
|
"@aws-crypto/sha256-js": "5.2.0",
|
|
23
|
-
"@aws-sdk/core": "3.
|
|
24
|
-
"@
|
|
25
|
-
"@
|
|
26
|
-
"@
|
|
27
|
-
"@
|
|
28
|
-
"@aws-sdk/types": "latest",
|
|
29
|
-
"@aws-sdk/util-user-agent-browser": "3.775.0",
|
|
30
|
-
"@aws-sdk/util-user-agent-node": "3.775.0",
|
|
31
|
-
"@smithy/config-resolver": "^4.1.0",
|
|
32
|
-
"@smithy/core": "^3.2.0",
|
|
33
|
-
"@smithy/fetch-http-handler": "^5.0.2",
|
|
34
|
-
"@smithy/hash-node": "^4.0.2",
|
|
35
|
-
"@smithy/invalid-dependency": "^4.0.2",
|
|
36
|
-
"@smithy/middleware-content-length": "^4.0.2",
|
|
37
|
-
"@smithy/middleware-retry": "^4.1.0",
|
|
38
|
-
"@smithy/middleware-serde": "^4.0.3",
|
|
39
|
-
"@smithy/middleware-stack": "^4.0.2",
|
|
40
|
-
"@smithy/node-config-provider": "^4.0.2",
|
|
41
|
-
"@smithy/node-http-handler": "^4.0.4",
|
|
42
|
-
"@smithy/protocol-http": "^5.1.0",
|
|
43
|
-
"@smithy/smithy-client": "^4.2.0",
|
|
44
|
-
"@smithy/types": "^4.2.0",
|
|
45
|
-
"@smithy/url-parser": "^4.0.2",
|
|
46
|
-
"@smithy/util-base64": "^4.0.0",
|
|
47
|
-
"@smithy/util-body-length-browser": "^4.0.0",
|
|
48
|
-
"@smithy/util-body-length-node": "^4.0.0",
|
|
49
|
-
"@smithy/util-defaults-mode-browser": "^4.0.8",
|
|
50
|
-
"@smithy/util-defaults-mode-node": "^4.0.8",
|
|
51
|
-
"@smithy/util-retry": "^4.0.2",
|
|
52
|
-
"@smithy/util-utf8": "^4.0.0"
|
|
23
|
+
"@aws-sdk/core": "^3.974.15",
|
|
24
|
+
"@smithy/core": "^3.24.5",
|
|
25
|
+
"@smithy/fetch-http-handler": "^5.4.5",
|
|
26
|
+
"@smithy/node-http-handler": "^4.7.5",
|
|
27
|
+
"@smithy/types": "^4.14.2"
|
|
53
28
|
},
|
|
54
29
|
"devDependencies": {
|
|
55
|
-
"@tsconfig/
|
|
30
|
+
"@tsconfig/node20": "20.1.8",
|
|
56
31
|
"concurrently": "7.0.0",
|
|
57
32
|
"downlevel-dts": "0.10.1",
|
|
58
|
-
"
|
|
59
|
-
"typescript": "~5.
|
|
60
|
-
"@types/node": "^
|
|
33
|
+
"premove": "4.0.0",
|
|
34
|
+
"typescript": "~5.8.3",
|
|
35
|
+
"@types/node": "^20.14.8"
|
|
61
36
|
},
|
|
62
37
|
"engines": {
|
|
63
|
-
"node": ">=
|
|
38
|
+
"node": ">=20.0.0"
|
|
64
39
|
},
|
|
65
40
|
"typesVersions": {
|
|
66
|
-
"<4.
|
|
41
|
+
"<4.5": {
|
|
67
42
|
"dist-types/*": [
|
|
68
43
|
"dist-types/ts3.4/*"
|
|
69
44
|
]
|
package/dist-cjs/models/index.js
DELETED
|
@@ -1,518 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.de_UpdateToolCommand = exports.de_ListToolsCommand = exports.de_GetToolCommand = exports.de_ExecuteToolCommand = exports.de_DiscoverToolsCommand = exports.de_DescribeToolsCommand = exports.de_DeleteToolCommand = exports.de_CreateToolCommand = exports.se_UpdateToolCommand = exports.se_ListToolsCommand = exports.se_GetToolCommand = exports.se_ExecuteToolCommand = exports.se_DiscoverToolsCommand = exports.se_DescribeToolsCommand = exports.se_DeleteToolCommand = exports.se_CreateToolCommand = void 0;
|
|
4
|
-
const ToolsServiceException_1 = require("../models/ToolsServiceException");
|
|
5
|
-
const models_0_1 = require("../models/models_0");
|
|
6
|
-
const core_1 = require("@aws-sdk/core");
|
|
7
|
-
const core_2 = require("@smithy/core");
|
|
8
|
-
const smithy_client_1 = require("@smithy/smithy-client");
|
|
9
|
-
const se_CreateToolCommand = async (input, context) => {
|
|
10
|
-
const b = (0, core_2.requestBuilder)(input, context);
|
|
11
|
-
const headers = {
|
|
12
|
-
'content-type': 'application/json',
|
|
13
|
-
};
|
|
14
|
-
b.bp("/v1/tools");
|
|
15
|
-
const query = (0, smithy_client_1.map)({
|
|
16
|
-
[_c]: [, input[_cI]],
|
|
17
|
-
});
|
|
18
|
-
let body;
|
|
19
|
-
body = JSON.stringify((0, smithy_client_1.take)(input, {
|
|
20
|
-
'category': [],
|
|
21
|
-
'description': [],
|
|
22
|
-
'handler': _ => (0, smithy_client_1._json)(_),
|
|
23
|
-
'input': _ => se_ToolInput(_, context),
|
|
24
|
-
'name': [],
|
|
25
|
-
}));
|
|
26
|
-
b.m("POST")
|
|
27
|
-
.h(headers)
|
|
28
|
-
.q(query)
|
|
29
|
-
.b(body);
|
|
30
|
-
return b.build();
|
|
31
|
-
};
|
|
32
|
-
exports.se_CreateToolCommand = se_CreateToolCommand;
|
|
33
|
-
const se_DeleteToolCommand = async (input, context) => {
|
|
34
|
-
const b = (0, core_2.requestBuilder)(input, context);
|
|
35
|
-
const headers = {};
|
|
36
|
-
b.bp("/v1/tools/{toolId}");
|
|
37
|
-
b.p('toolId', () => input.toolId, '{toolId}', false);
|
|
38
|
-
const query = (0, smithy_client_1.map)({
|
|
39
|
-
[_c]: [, input[_cI]],
|
|
40
|
-
});
|
|
41
|
-
let body;
|
|
42
|
-
b.m("DELETE")
|
|
43
|
-
.h(headers)
|
|
44
|
-
.q(query)
|
|
45
|
-
.b(body);
|
|
46
|
-
return b.build();
|
|
47
|
-
};
|
|
48
|
-
exports.se_DeleteToolCommand = se_DeleteToolCommand;
|
|
49
|
-
const se_DescribeToolsCommand = async (input, context) => {
|
|
50
|
-
const b = (0, core_2.requestBuilder)(input, context);
|
|
51
|
-
const headers = {
|
|
52
|
-
'content-type': 'application/json',
|
|
53
|
-
};
|
|
54
|
-
b.bp("/v1/tools/describe");
|
|
55
|
-
const query = (0, smithy_client_1.map)({
|
|
56
|
-
[_c]: [, input[_cI]],
|
|
57
|
-
});
|
|
58
|
-
let body;
|
|
59
|
-
body = JSON.stringify((0, smithy_client_1.take)(input, {
|
|
60
|
-
'ids': _ => (0, smithy_client_1._json)(_),
|
|
61
|
-
}));
|
|
62
|
-
b.m("POST")
|
|
63
|
-
.h(headers)
|
|
64
|
-
.q(query)
|
|
65
|
-
.b(body);
|
|
66
|
-
return b.build();
|
|
67
|
-
};
|
|
68
|
-
exports.se_DescribeToolsCommand = se_DescribeToolsCommand;
|
|
69
|
-
const se_DiscoverToolsCommand = async (input, context) => {
|
|
70
|
-
const b = (0, core_2.requestBuilder)(input, context);
|
|
71
|
-
const headers = {
|
|
72
|
-
'content-type': 'application/json',
|
|
73
|
-
};
|
|
74
|
-
b.bp("/v1/tools/discover");
|
|
75
|
-
const query = (0, smithy_client_1.map)({
|
|
76
|
-
[_c]: [, input[_cI]],
|
|
77
|
-
});
|
|
78
|
-
let body;
|
|
79
|
-
body = JSON.stringify((0, smithy_client_1.take)(input, {
|
|
80
|
-
'authorization': _ => (0, smithy_client_1._json)(_),
|
|
81
|
-
'serverUrl': [],
|
|
82
|
-
}));
|
|
83
|
-
b.m("POST")
|
|
84
|
-
.h(headers)
|
|
85
|
-
.q(query)
|
|
86
|
-
.b(body);
|
|
87
|
-
return b.build();
|
|
88
|
-
};
|
|
89
|
-
exports.se_DiscoverToolsCommand = se_DiscoverToolsCommand;
|
|
90
|
-
const se_ExecuteToolCommand = async (input, context) => {
|
|
91
|
-
const b = (0, core_2.requestBuilder)(input, context);
|
|
92
|
-
const headers = {
|
|
93
|
-
'content-type': 'application/json',
|
|
94
|
-
};
|
|
95
|
-
b.bp("/v1/tools/execute");
|
|
96
|
-
const query = (0, smithy_client_1.map)({
|
|
97
|
-
[_c]: [, input[_cI]],
|
|
98
|
-
});
|
|
99
|
-
let body;
|
|
100
|
-
body = JSON.stringify((0, smithy_client_1.take)(input, {
|
|
101
|
-
'id': [],
|
|
102
|
-
'input': _ => se_Document(_, context),
|
|
103
|
-
'service': [],
|
|
104
|
-
'user': [],
|
|
105
|
-
}));
|
|
106
|
-
b.m("POST")
|
|
107
|
-
.h(headers)
|
|
108
|
-
.q(query)
|
|
109
|
-
.b(body);
|
|
110
|
-
return b.build();
|
|
111
|
-
};
|
|
112
|
-
exports.se_ExecuteToolCommand = se_ExecuteToolCommand;
|
|
113
|
-
const se_GetToolCommand = async (input, context) => {
|
|
114
|
-
const b = (0, core_2.requestBuilder)(input, context);
|
|
115
|
-
const headers = {};
|
|
116
|
-
b.bp("/v1/tools/{toolId}");
|
|
117
|
-
b.p('toolId', () => input.toolId, '{toolId}', false);
|
|
118
|
-
const query = (0, smithy_client_1.map)({
|
|
119
|
-
[_c]: [, input[_cI]],
|
|
120
|
-
});
|
|
121
|
-
let body;
|
|
122
|
-
b.m("GET")
|
|
123
|
-
.h(headers)
|
|
124
|
-
.q(query)
|
|
125
|
-
.b(body);
|
|
126
|
-
return b.build();
|
|
127
|
-
};
|
|
128
|
-
exports.se_GetToolCommand = se_GetToolCommand;
|
|
129
|
-
const se_ListToolsCommand = async (input, context) => {
|
|
130
|
-
const b = (0, core_2.requestBuilder)(input, context);
|
|
131
|
-
const headers = {};
|
|
132
|
-
b.bp("/v1/tools");
|
|
133
|
-
const query = (0, smithy_client_1.map)({
|
|
134
|
-
[_c]: [, input[_cI]],
|
|
135
|
-
});
|
|
136
|
-
let body;
|
|
137
|
-
b.m("GET")
|
|
138
|
-
.h(headers)
|
|
139
|
-
.q(query)
|
|
140
|
-
.b(body);
|
|
141
|
-
return b.build();
|
|
142
|
-
};
|
|
143
|
-
exports.se_ListToolsCommand = se_ListToolsCommand;
|
|
144
|
-
const se_UpdateToolCommand = async (input, context) => {
|
|
145
|
-
const b = (0, core_2.requestBuilder)(input, context);
|
|
146
|
-
const headers = {
|
|
147
|
-
'content-type': 'application/json',
|
|
148
|
-
};
|
|
149
|
-
b.bp("/v1/tools/{toolId}");
|
|
150
|
-
b.p('toolId', () => input.toolId, '{toolId}', false);
|
|
151
|
-
const query = (0, smithy_client_1.map)({
|
|
152
|
-
[_c]: [, input[_cI]],
|
|
153
|
-
});
|
|
154
|
-
let body;
|
|
155
|
-
body = JSON.stringify((0, smithy_client_1.take)(input, {
|
|
156
|
-
'category': [],
|
|
157
|
-
'description': [],
|
|
158
|
-
'handler': _ => (0, smithy_client_1._json)(_),
|
|
159
|
-
'input': _ => se_ToolInput(_, context),
|
|
160
|
-
'name': [],
|
|
161
|
-
}));
|
|
162
|
-
b.m("PUT")
|
|
163
|
-
.h(headers)
|
|
164
|
-
.q(query)
|
|
165
|
-
.b(body);
|
|
166
|
-
return b.build();
|
|
167
|
-
};
|
|
168
|
-
exports.se_UpdateToolCommand = se_UpdateToolCommand;
|
|
169
|
-
const de_CreateToolCommand = async (output, context) => {
|
|
170
|
-
if (output.statusCode !== 201 && output.statusCode >= 300) {
|
|
171
|
-
return de_CommandError(output, context);
|
|
172
|
-
}
|
|
173
|
-
const contents = (0, smithy_client_1.map)({
|
|
174
|
-
$metadata: deserializeMetadata(output),
|
|
175
|
-
});
|
|
176
|
-
const data = (0, smithy_client_1.expectNonNull)(((0, smithy_client_1.expectObject)(await (0, core_1.parseJsonBody)(output.body, context))), "body");
|
|
177
|
-
const doc = (0, smithy_client_1.take)(data, {
|
|
178
|
-
'tool': _ => de_Tool(_, context),
|
|
179
|
-
});
|
|
180
|
-
Object.assign(contents, doc);
|
|
181
|
-
return contents;
|
|
182
|
-
};
|
|
183
|
-
exports.de_CreateToolCommand = de_CreateToolCommand;
|
|
184
|
-
const de_DeleteToolCommand = async (output, context) => {
|
|
185
|
-
if (output.statusCode !== 204 && output.statusCode >= 300) {
|
|
186
|
-
return de_CommandError(output, context);
|
|
187
|
-
}
|
|
188
|
-
const contents = (0, smithy_client_1.map)({
|
|
189
|
-
$metadata: deserializeMetadata(output),
|
|
190
|
-
});
|
|
191
|
-
await (0, smithy_client_1.collectBody)(output.body, context);
|
|
192
|
-
return contents;
|
|
193
|
-
};
|
|
194
|
-
exports.de_DeleteToolCommand = de_DeleteToolCommand;
|
|
195
|
-
const de_DescribeToolsCommand = async (output, context) => {
|
|
196
|
-
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
197
|
-
return de_CommandError(output, context);
|
|
198
|
-
}
|
|
199
|
-
const contents = (0, smithy_client_1.map)({
|
|
200
|
-
$metadata: deserializeMetadata(output),
|
|
201
|
-
});
|
|
202
|
-
const data = (0, smithy_client_1.expectNonNull)(((0, smithy_client_1.expectObject)(await (0, core_1.parseJsonBody)(output.body, context))), "body");
|
|
203
|
-
const doc = (0, smithy_client_1.take)(data, {
|
|
204
|
-
'descriptions': _ => de_ToolDescriptionList(_, context),
|
|
205
|
-
});
|
|
206
|
-
Object.assign(contents, doc);
|
|
207
|
-
return contents;
|
|
208
|
-
};
|
|
209
|
-
exports.de_DescribeToolsCommand = de_DescribeToolsCommand;
|
|
210
|
-
const de_DiscoverToolsCommand = async (output, context) => {
|
|
211
|
-
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
212
|
-
return de_CommandError(output, context);
|
|
213
|
-
}
|
|
214
|
-
const contents = (0, smithy_client_1.map)({
|
|
215
|
-
$metadata: deserializeMetadata(output),
|
|
216
|
-
});
|
|
217
|
-
const data = (0, smithy_client_1.expectNonNull)(((0, smithy_client_1.expectObject)(await (0, core_1.parseJsonBody)(output.body, context))), "body");
|
|
218
|
-
const doc = (0, smithy_client_1.take)(data, {
|
|
219
|
-
'tools': _ => de_DiscoveredToolList(_, context),
|
|
220
|
-
});
|
|
221
|
-
Object.assign(contents, doc);
|
|
222
|
-
return contents;
|
|
223
|
-
};
|
|
224
|
-
exports.de_DiscoverToolsCommand = de_DiscoverToolsCommand;
|
|
225
|
-
const de_ExecuteToolCommand = async (output, context) => {
|
|
226
|
-
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
227
|
-
return de_CommandError(output, context);
|
|
228
|
-
}
|
|
229
|
-
const contents = (0, smithy_client_1.map)({
|
|
230
|
-
$metadata: deserializeMetadata(output),
|
|
231
|
-
});
|
|
232
|
-
const data = (0, smithy_client_1.expectNonNull)(((0, smithy_client_1.expectObject)(await (0, core_1.parseJsonBody)(output.body, context))), "body");
|
|
233
|
-
const doc = (0, smithy_client_1.take)(data, {
|
|
234
|
-
'result': _ => de_ToolExecutionResult(_, context),
|
|
235
|
-
});
|
|
236
|
-
Object.assign(contents, doc);
|
|
237
|
-
return contents;
|
|
238
|
-
};
|
|
239
|
-
exports.de_ExecuteToolCommand = de_ExecuteToolCommand;
|
|
240
|
-
const de_GetToolCommand = async (output, context) => {
|
|
241
|
-
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
242
|
-
return de_CommandError(output, context);
|
|
243
|
-
}
|
|
244
|
-
const contents = (0, smithy_client_1.map)({
|
|
245
|
-
$metadata: deserializeMetadata(output),
|
|
246
|
-
});
|
|
247
|
-
const data = (0, smithy_client_1.expectNonNull)(((0, smithy_client_1.expectObject)(await (0, core_1.parseJsonBody)(output.body, context))), "body");
|
|
248
|
-
const doc = (0, smithy_client_1.take)(data, {
|
|
249
|
-
'tool': _ => de_Tool(_, context),
|
|
250
|
-
});
|
|
251
|
-
Object.assign(contents, doc);
|
|
252
|
-
return contents;
|
|
253
|
-
};
|
|
254
|
-
exports.de_GetToolCommand = de_GetToolCommand;
|
|
255
|
-
const de_ListToolsCommand = async (output, context) => {
|
|
256
|
-
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
257
|
-
return de_CommandError(output, context);
|
|
258
|
-
}
|
|
259
|
-
const contents = (0, smithy_client_1.map)({
|
|
260
|
-
$metadata: deserializeMetadata(output),
|
|
261
|
-
});
|
|
262
|
-
const data = (0, smithy_client_1.expectNonNull)(((0, smithy_client_1.expectObject)(await (0, core_1.parseJsonBody)(output.body, context))), "body");
|
|
263
|
-
const doc = (0, smithy_client_1.take)(data, {
|
|
264
|
-
'tools': _ => de_ToolsList(_, context),
|
|
265
|
-
});
|
|
266
|
-
Object.assign(contents, doc);
|
|
267
|
-
return contents;
|
|
268
|
-
};
|
|
269
|
-
exports.de_ListToolsCommand = de_ListToolsCommand;
|
|
270
|
-
const de_UpdateToolCommand = async (output, context) => {
|
|
271
|
-
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
272
|
-
return de_CommandError(output, context);
|
|
273
|
-
}
|
|
274
|
-
const contents = (0, smithy_client_1.map)({
|
|
275
|
-
$metadata: deserializeMetadata(output),
|
|
276
|
-
});
|
|
277
|
-
const data = (0, smithy_client_1.expectNonNull)(((0, smithy_client_1.expectObject)(await (0, core_1.parseJsonBody)(output.body, context))), "body");
|
|
278
|
-
const doc = (0, smithy_client_1.take)(data, {
|
|
279
|
-
'tool': _ => de_Tool(_, context),
|
|
280
|
-
});
|
|
281
|
-
Object.assign(contents, doc);
|
|
282
|
-
return contents;
|
|
283
|
-
};
|
|
284
|
-
exports.de_UpdateToolCommand = de_UpdateToolCommand;
|
|
285
|
-
const de_CommandError = async (output, context) => {
|
|
286
|
-
const parsedOutput = {
|
|
287
|
-
...output,
|
|
288
|
-
body: await (0, core_1.parseJsonErrorBody)(output.body, context)
|
|
289
|
-
};
|
|
290
|
-
const errorCode = (0, core_1.loadRestJsonErrorCode)(output, parsedOutput.body);
|
|
291
|
-
switch (errorCode) {
|
|
292
|
-
case "AlreadyExistException":
|
|
293
|
-
case "smithy.framework#AlreadyExistException":
|
|
294
|
-
throw await de_AlreadyExistExceptionRes(parsedOutput, context);
|
|
295
|
-
case "ForbiddenException":
|
|
296
|
-
case "smithy.framework#ForbiddenException":
|
|
297
|
-
throw await de_ForbiddenExceptionRes(parsedOutput, context);
|
|
298
|
-
case "NotFoundException":
|
|
299
|
-
case "smithy.framework#NotFoundException":
|
|
300
|
-
throw await de_NotFoundExceptionRes(parsedOutput, context);
|
|
301
|
-
case "ToolExecutionException":
|
|
302
|
-
case "wildix.wim.tools#ToolExecutionException":
|
|
303
|
-
throw await de_ToolExecutionExceptionRes(parsedOutput, context);
|
|
304
|
-
case "ToolExecutionServerException":
|
|
305
|
-
case "wildix.wim.tools#ToolExecutionServerException":
|
|
306
|
-
throw await de_ToolExecutionServerExceptionRes(parsedOutput, context);
|
|
307
|
-
case "UnauthorizedException":
|
|
308
|
-
case "smithy.framework#UnauthorizedException":
|
|
309
|
-
throw await de_UnauthorizedExceptionRes(parsedOutput, context);
|
|
310
|
-
case "ValidationException":
|
|
311
|
-
case "smithy.framework#ValidationException":
|
|
312
|
-
throw await de_ValidationExceptionRes(parsedOutput, context);
|
|
313
|
-
default:
|
|
314
|
-
const parsedBody = parsedOutput.body;
|
|
315
|
-
return throwDefaultError({
|
|
316
|
-
output,
|
|
317
|
-
parsedBody,
|
|
318
|
-
errorCode
|
|
319
|
-
});
|
|
320
|
-
}
|
|
321
|
-
};
|
|
322
|
-
const throwDefaultError = (0, smithy_client_1.withBaseException)(ToolsServiceException_1.ToolsServiceException);
|
|
323
|
-
const de_AlreadyExistExceptionRes = async (parsedOutput, context) => {
|
|
324
|
-
const contents = (0, smithy_client_1.map)({});
|
|
325
|
-
const data = parsedOutput.body;
|
|
326
|
-
const doc = (0, smithy_client_1.take)(data, {
|
|
327
|
-
'message': smithy_client_1.expectString,
|
|
328
|
-
});
|
|
329
|
-
Object.assign(contents, doc);
|
|
330
|
-
const exception = new models_0_1.AlreadyExistException({
|
|
331
|
-
$metadata: deserializeMetadata(parsedOutput),
|
|
332
|
-
...contents
|
|
333
|
-
});
|
|
334
|
-
return (0, smithy_client_1.decorateServiceException)(exception, parsedOutput.body);
|
|
335
|
-
};
|
|
336
|
-
const de_ForbiddenExceptionRes = async (parsedOutput, context) => {
|
|
337
|
-
const contents = (0, smithy_client_1.map)({});
|
|
338
|
-
const data = parsedOutput.body;
|
|
339
|
-
const doc = (0, smithy_client_1.take)(data, {
|
|
340
|
-
'message': smithy_client_1.expectString,
|
|
341
|
-
});
|
|
342
|
-
Object.assign(contents, doc);
|
|
343
|
-
const exception = new models_0_1.ForbiddenException({
|
|
344
|
-
$metadata: deserializeMetadata(parsedOutput),
|
|
345
|
-
...contents
|
|
346
|
-
});
|
|
347
|
-
return (0, smithy_client_1.decorateServiceException)(exception, parsedOutput.body);
|
|
348
|
-
};
|
|
349
|
-
const de_NotFoundExceptionRes = async (parsedOutput, context) => {
|
|
350
|
-
const contents = (0, smithy_client_1.map)({});
|
|
351
|
-
const data = parsedOutput.body;
|
|
352
|
-
const doc = (0, smithy_client_1.take)(data, {
|
|
353
|
-
'message': smithy_client_1.expectString,
|
|
354
|
-
});
|
|
355
|
-
Object.assign(contents, doc);
|
|
356
|
-
const exception = new models_0_1.NotFoundException({
|
|
357
|
-
$metadata: deserializeMetadata(parsedOutput),
|
|
358
|
-
...contents
|
|
359
|
-
});
|
|
360
|
-
return (0, smithy_client_1.decorateServiceException)(exception, parsedOutput.body);
|
|
361
|
-
};
|
|
362
|
-
const de_UnauthorizedExceptionRes = async (parsedOutput, context) => {
|
|
363
|
-
const contents = (0, smithy_client_1.map)({});
|
|
364
|
-
const data = parsedOutput.body;
|
|
365
|
-
const doc = (0, smithy_client_1.take)(data, {
|
|
366
|
-
'message': smithy_client_1.expectString,
|
|
367
|
-
});
|
|
368
|
-
Object.assign(contents, doc);
|
|
369
|
-
const exception = new models_0_1.UnauthorizedException({
|
|
370
|
-
$metadata: deserializeMetadata(parsedOutput),
|
|
371
|
-
...contents
|
|
372
|
-
});
|
|
373
|
-
return (0, smithy_client_1.decorateServiceException)(exception, parsedOutput.body);
|
|
374
|
-
};
|
|
375
|
-
const de_ValidationExceptionRes = async (parsedOutput, context) => {
|
|
376
|
-
const contents = (0, smithy_client_1.map)({});
|
|
377
|
-
const data = parsedOutput.body;
|
|
378
|
-
const doc = (0, smithy_client_1.take)(data, {
|
|
379
|
-
'message': smithy_client_1.expectString,
|
|
380
|
-
});
|
|
381
|
-
Object.assign(contents, doc);
|
|
382
|
-
const exception = new models_0_1.ValidationException({
|
|
383
|
-
$metadata: deserializeMetadata(parsedOutput),
|
|
384
|
-
...contents
|
|
385
|
-
});
|
|
386
|
-
return (0, smithy_client_1.decorateServiceException)(exception, parsedOutput.body);
|
|
387
|
-
};
|
|
388
|
-
const de_ToolExecutionExceptionRes = async (parsedOutput, context) => {
|
|
389
|
-
const contents = (0, smithy_client_1.map)({});
|
|
390
|
-
const data = parsedOutput.body;
|
|
391
|
-
const doc = (0, smithy_client_1.take)(data, {
|
|
392
|
-
'details': _ => de_Document(_, context),
|
|
393
|
-
'message': smithy_client_1.expectString,
|
|
394
|
-
});
|
|
395
|
-
Object.assign(contents, doc);
|
|
396
|
-
const exception = new models_0_1.ToolExecutionException({
|
|
397
|
-
$metadata: deserializeMetadata(parsedOutput),
|
|
398
|
-
...contents
|
|
399
|
-
});
|
|
400
|
-
return (0, smithy_client_1.decorateServiceException)(exception, parsedOutput.body);
|
|
401
|
-
};
|
|
402
|
-
const de_ToolExecutionServerExceptionRes = async (parsedOutput, context) => {
|
|
403
|
-
const contents = (0, smithy_client_1.map)({});
|
|
404
|
-
const data = parsedOutput.body;
|
|
405
|
-
const doc = (0, smithy_client_1.take)(data, {
|
|
406
|
-
'details': _ => de_Document(_, context),
|
|
407
|
-
'message': smithy_client_1.expectString,
|
|
408
|
-
});
|
|
409
|
-
Object.assign(contents, doc);
|
|
410
|
-
const exception = new models_0_1.ToolExecutionServerException({
|
|
411
|
-
$metadata: deserializeMetadata(parsedOutput),
|
|
412
|
-
...contents
|
|
413
|
-
});
|
|
414
|
-
return (0, smithy_client_1.decorateServiceException)(exception, parsedOutput.body);
|
|
415
|
-
};
|
|
416
|
-
const se_Document = (input, context) => {
|
|
417
|
-
return input;
|
|
418
|
-
};
|
|
419
|
-
const se_ToolInput = (input, context) => {
|
|
420
|
-
return (0, smithy_client_1.take)(input, {
|
|
421
|
-
'variables': _ => se_ToolVariableList(_, context),
|
|
422
|
-
});
|
|
423
|
-
};
|
|
424
|
-
const se_ToolVariable = (input, context) => {
|
|
425
|
-
return (0, smithy_client_1.take)(input, {
|
|
426
|
-
'description': [],
|
|
427
|
-
'name': [],
|
|
428
|
-
'optional': [],
|
|
429
|
-
'schema': _ => se_Document(_, context),
|
|
430
|
-
'type': [],
|
|
431
|
-
});
|
|
432
|
-
};
|
|
433
|
-
const se_ToolVariableList = (input, context) => {
|
|
434
|
-
return input.filter((e) => e != null).map(entry => {
|
|
435
|
-
return se_ToolVariable(entry, context);
|
|
436
|
-
});
|
|
437
|
-
};
|
|
438
|
-
const de_Document = (output, context) => {
|
|
439
|
-
return output;
|
|
440
|
-
};
|
|
441
|
-
const de_DiscoveredTool = (output, context) => {
|
|
442
|
-
return (0, smithy_client_1.take)(output, {
|
|
443
|
-
'description': smithy_client_1.expectString,
|
|
444
|
-
'inputSchema': (_) => de_Document(_, context),
|
|
445
|
-
'name': smithy_client_1.expectString,
|
|
446
|
-
});
|
|
447
|
-
};
|
|
448
|
-
const de_DiscoveredToolList = (output, context) => {
|
|
449
|
-
const retVal = (output || []).filter((e) => e != null).map((entry) => {
|
|
450
|
-
return de_DiscoveredTool(entry, context);
|
|
451
|
-
});
|
|
452
|
-
return retVal;
|
|
453
|
-
};
|
|
454
|
-
const de_Tool = (output, context) => {
|
|
455
|
-
return (0, smithy_client_1.take)(output, {
|
|
456
|
-
'category': smithy_client_1.expectString,
|
|
457
|
-
'companyId': smithy_client_1.expectString,
|
|
458
|
-
'description': smithy_client_1.expectString,
|
|
459
|
-
'handler': (_) => (0, smithy_client_1._json)((0, core_1.awsExpectUnion)(_)),
|
|
460
|
-
'id': smithy_client_1.expectString,
|
|
461
|
-
'input': (_) => de_ToolInput(_, context),
|
|
462
|
-
'name': smithy_client_1.expectString,
|
|
463
|
-
});
|
|
464
|
-
};
|
|
465
|
-
const de_ToolDescription = (output, context) => {
|
|
466
|
-
return (0, smithy_client_1.take)(output, {
|
|
467
|
-
'description': smithy_client_1.expectString,
|
|
468
|
-
'id': smithy_client_1.expectString,
|
|
469
|
-
'name': smithy_client_1.expectString,
|
|
470
|
-
'variables': (_) => de_ToolVariableList(_, context),
|
|
471
|
-
});
|
|
472
|
-
};
|
|
473
|
-
const de_ToolDescriptionList = (output, context) => {
|
|
474
|
-
const retVal = (output || []).filter((e) => e != null).map((entry) => {
|
|
475
|
-
return de_ToolDescription(entry, context);
|
|
476
|
-
});
|
|
477
|
-
return retVal;
|
|
478
|
-
};
|
|
479
|
-
const de_ToolExecutionResult = (output, context) => {
|
|
480
|
-
return (0, smithy_client_1.take)(output, {
|
|
481
|
-
'output': (_) => de_Document(_, context),
|
|
482
|
-
});
|
|
483
|
-
};
|
|
484
|
-
const de_ToolInput = (output, context) => {
|
|
485
|
-
return (0, smithy_client_1.take)(output, {
|
|
486
|
-
'variables': (_) => de_ToolVariableList(_, context),
|
|
487
|
-
});
|
|
488
|
-
};
|
|
489
|
-
const de_ToolsList = (output, context) => {
|
|
490
|
-
const retVal = (output || []).filter((e) => e != null).map((entry) => {
|
|
491
|
-
return de_Tool(entry, context);
|
|
492
|
-
});
|
|
493
|
-
return retVal;
|
|
494
|
-
};
|
|
495
|
-
const de_ToolVariable = (output, context) => {
|
|
496
|
-
return (0, smithy_client_1.take)(output, {
|
|
497
|
-
'description': smithy_client_1.expectString,
|
|
498
|
-
'name': smithy_client_1.expectString,
|
|
499
|
-
'optional': smithy_client_1.expectBoolean,
|
|
500
|
-
'schema': (_) => de_Document(_, context),
|
|
501
|
-
'type': smithy_client_1.expectString,
|
|
502
|
-
});
|
|
503
|
-
};
|
|
504
|
-
const de_ToolVariableList = (output, context) => {
|
|
505
|
-
const retVal = (output || []).filter((e) => e != null).map((entry) => {
|
|
506
|
-
return de_ToolVariable(entry, context);
|
|
507
|
-
});
|
|
508
|
-
return retVal;
|
|
509
|
-
};
|
|
510
|
-
const deserializeMetadata = (output) => ({
|
|
511
|
-
httpStatusCode: output.statusCode,
|
|
512
|
-
requestId: output.headers["x-amzn-requestid"] ?? output.headers["x-amzn-request-id"] ?? output.headers["x-amz-request-id"],
|
|
513
|
-
extendedRequestId: output.headers["x-amz-id-2"],
|
|
514
|
-
cfId: output.headers["x-amz-cf-id"],
|
|
515
|
-
});
|
|
516
|
-
const collectBodyString = (streamBody, context) => (0, smithy_client_1.collectBody)(streamBody, context).then(body => context.utf8Encoder(body));
|
|
517
|
-
const _c = "company";
|
|
518
|
-
const _cI = "companyId";
|
package/dist-es/models/index.js
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export * from "./models_0";
|