@aws-sdk/client-iotsecuretunneling 3.306.0 → 3.309.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/dist-cjs/commands/CloseTunnelCommand.js +2 -2
- package/dist-cjs/commands/DescribeTunnelCommand.js +2 -2
- package/dist-cjs/commands/ListTagsForResourceCommand.js +2 -2
- package/dist-cjs/commands/ListTunnelsCommand.js +2 -2
- package/dist-cjs/commands/OpenTunnelCommand.js +2 -2
- package/dist-cjs/commands/RotateTunnelAccessTokenCommand.js +2 -2
- package/dist-cjs/commands/TagResourceCommand.js +2 -2
- package/dist-cjs/commands/UntagResourceCommand.js +2 -2
- package/dist-cjs/protocols/Aws_json1_1.js +128 -136
- package/dist-es/commands/CloseTunnelCommand.js +3 -3
- package/dist-es/commands/DescribeTunnelCommand.js +3 -3
- package/dist-es/commands/ListTagsForResourceCommand.js +3 -3
- package/dist-es/commands/ListTunnelsCommand.js +3 -3
- package/dist-es/commands/OpenTunnelCommand.js +3 -3
- package/dist-es/commands/RotateTunnelAccessTokenCommand.js +3 -3
- package/dist-es/commands/TagResourceCommand.js +3 -3
- package/dist-es/commands/UntagResourceCommand.js +3 -3
- package/dist-es/protocols/Aws_json1_1.js +111 -119
- package/dist-types/protocols/Aws_json1_1.d.ts +64 -16
- package/dist-types/ts3.4/protocols/Aws_json1_1.d.ts +16 -16
- package/package.json +6 -6
|
@@ -1,105 +1,105 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.
|
|
3
|
+
exports.de_UntagResourceCommand = exports.de_TagResourceCommand = exports.de_RotateTunnelAccessTokenCommand = exports.de_OpenTunnelCommand = exports.de_ListTunnelsCommand = exports.de_ListTagsForResourceCommand = exports.de_DescribeTunnelCommand = exports.de_CloseTunnelCommand = exports.se_UntagResourceCommand = exports.se_TagResourceCommand = exports.se_RotateTunnelAccessTokenCommand = exports.se_OpenTunnelCommand = exports.se_ListTunnelsCommand = exports.se_ListTagsForResourceCommand = exports.se_DescribeTunnelCommand = exports.se_CloseTunnelCommand = void 0;
|
|
4
4
|
const protocol_http_1 = require("@aws-sdk/protocol-http");
|
|
5
5
|
const smithy_client_1 = require("@aws-sdk/smithy-client");
|
|
6
6
|
const IoTSecureTunnelingServiceException_1 = require("../models/IoTSecureTunnelingServiceException");
|
|
7
7
|
const models_0_1 = require("../models/models_0");
|
|
8
|
-
const
|
|
8
|
+
const se_CloseTunnelCommand = async (input, context) => {
|
|
9
9
|
const headers = {
|
|
10
10
|
"content-type": "application/x-amz-json-1.1",
|
|
11
11
|
"x-amz-target": "IoTSecuredTunneling.CloseTunnel",
|
|
12
12
|
};
|
|
13
13
|
let body;
|
|
14
|
-
body = JSON.stringify(
|
|
14
|
+
body = JSON.stringify(se_CloseTunnelRequest(input, context));
|
|
15
15
|
return buildHttpRpcRequest(context, headers, "/", undefined, body);
|
|
16
16
|
};
|
|
17
|
-
exports.
|
|
18
|
-
const
|
|
17
|
+
exports.se_CloseTunnelCommand = se_CloseTunnelCommand;
|
|
18
|
+
const se_DescribeTunnelCommand = async (input, context) => {
|
|
19
19
|
const headers = {
|
|
20
20
|
"content-type": "application/x-amz-json-1.1",
|
|
21
21
|
"x-amz-target": "IoTSecuredTunneling.DescribeTunnel",
|
|
22
22
|
};
|
|
23
23
|
let body;
|
|
24
|
-
body = JSON.stringify(
|
|
24
|
+
body = JSON.stringify(se_DescribeTunnelRequest(input, context));
|
|
25
25
|
return buildHttpRpcRequest(context, headers, "/", undefined, body);
|
|
26
26
|
};
|
|
27
|
-
exports.
|
|
28
|
-
const
|
|
27
|
+
exports.se_DescribeTunnelCommand = se_DescribeTunnelCommand;
|
|
28
|
+
const se_ListTagsForResourceCommand = async (input, context) => {
|
|
29
29
|
const headers = {
|
|
30
30
|
"content-type": "application/x-amz-json-1.1",
|
|
31
31
|
"x-amz-target": "IoTSecuredTunneling.ListTagsForResource",
|
|
32
32
|
};
|
|
33
33
|
let body;
|
|
34
|
-
body = JSON.stringify(
|
|
34
|
+
body = JSON.stringify(se_ListTagsForResourceRequest(input, context));
|
|
35
35
|
return buildHttpRpcRequest(context, headers, "/", undefined, body);
|
|
36
36
|
};
|
|
37
|
-
exports.
|
|
38
|
-
const
|
|
37
|
+
exports.se_ListTagsForResourceCommand = se_ListTagsForResourceCommand;
|
|
38
|
+
const se_ListTunnelsCommand = async (input, context) => {
|
|
39
39
|
const headers = {
|
|
40
40
|
"content-type": "application/x-amz-json-1.1",
|
|
41
41
|
"x-amz-target": "IoTSecuredTunneling.ListTunnels",
|
|
42
42
|
};
|
|
43
43
|
let body;
|
|
44
|
-
body = JSON.stringify(
|
|
44
|
+
body = JSON.stringify(se_ListTunnelsRequest(input, context));
|
|
45
45
|
return buildHttpRpcRequest(context, headers, "/", undefined, body);
|
|
46
46
|
};
|
|
47
|
-
exports.
|
|
48
|
-
const
|
|
47
|
+
exports.se_ListTunnelsCommand = se_ListTunnelsCommand;
|
|
48
|
+
const se_OpenTunnelCommand = async (input, context) => {
|
|
49
49
|
const headers = {
|
|
50
50
|
"content-type": "application/x-amz-json-1.1",
|
|
51
51
|
"x-amz-target": "IoTSecuredTunneling.OpenTunnel",
|
|
52
52
|
};
|
|
53
53
|
let body;
|
|
54
|
-
body = JSON.stringify(
|
|
54
|
+
body = JSON.stringify(se_OpenTunnelRequest(input, context));
|
|
55
55
|
return buildHttpRpcRequest(context, headers, "/", undefined, body);
|
|
56
56
|
};
|
|
57
|
-
exports.
|
|
58
|
-
const
|
|
57
|
+
exports.se_OpenTunnelCommand = se_OpenTunnelCommand;
|
|
58
|
+
const se_RotateTunnelAccessTokenCommand = async (input, context) => {
|
|
59
59
|
const headers = {
|
|
60
60
|
"content-type": "application/x-amz-json-1.1",
|
|
61
61
|
"x-amz-target": "IoTSecuredTunneling.RotateTunnelAccessToken",
|
|
62
62
|
};
|
|
63
63
|
let body;
|
|
64
|
-
body = JSON.stringify(
|
|
64
|
+
body = JSON.stringify(se_RotateTunnelAccessTokenRequest(input, context));
|
|
65
65
|
return buildHttpRpcRequest(context, headers, "/", undefined, body);
|
|
66
66
|
};
|
|
67
|
-
exports.
|
|
68
|
-
const
|
|
67
|
+
exports.se_RotateTunnelAccessTokenCommand = se_RotateTunnelAccessTokenCommand;
|
|
68
|
+
const se_TagResourceCommand = async (input, context) => {
|
|
69
69
|
const headers = {
|
|
70
70
|
"content-type": "application/x-amz-json-1.1",
|
|
71
71
|
"x-amz-target": "IoTSecuredTunneling.TagResource",
|
|
72
72
|
};
|
|
73
73
|
let body;
|
|
74
|
-
body = JSON.stringify(
|
|
74
|
+
body = JSON.stringify(se_TagResourceRequest(input, context));
|
|
75
75
|
return buildHttpRpcRequest(context, headers, "/", undefined, body);
|
|
76
76
|
};
|
|
77
|
-
exports.
|
|
78
|
-
const
|
|
77
|
+
exports.se_TagResourceCommand = se_TagResourceCommand;
|
|
78
|
+
const se_UntagResourceCommand = async (input, context) => {
|
|
79
79
|
const headers = {
|
|
80
80
|
"content-type": "application/x-amz-json-1.1",
|
|
81
81
|
"x-amz-target": "IoTSecuredTunneling.UntagResource",
|
|
82
82
|
};
|
|
83
83
|
let body;
|
|
84
|
-
body = JSON.stringify(
|
|
84
|
+
body = JSON.stringify(se_UntagResourceRequest(input, context));
|
|
85
85
|
return buildHttpRpcRequest(context, headers, "/", undefined, body);
|
|
86
86
|
};
|
|
87
|
-
exports.
|
|
88
|
-
const
|
|
87
|
+
exports.se_UntagResourceCommand = se_UntagResourceCommand;
|
|
88
|
+
const de_CloseTunnelCommand = async (output, context) => {
|
|
89
89
|
if (output.statusCode >= 300) {
|
|
90
|
-
return
|
|
90
|
+
return de_CloseTunnelCommandError(output, context);
|
|
91
91
|
}
|
|
92
92
|
const data = await parseBody(output.body, context);
|
|
93
93
|
let contents = {};
|
|
94
|
-
contents =
|
|
94
|
+
contents = de_CloseTunnelResponse(data, context);
|
|
95
95
|
const response = {
|
|
96
96
|
$metadata: deserializeMetadata(output),
|
|
97
97
|
...contents,
|
|
98
98
|
};
|
|
99
99
|
return Promise.resolve(response);
|
|
100
100
|
};
|
|
101
|
-
exports.
|
|
102
|
-
const
|
|
101
|
+
exports.de_CloseTunnelCommand = de_CloseTunnelCommand;
|
|
102
|
+
const de_CloseTunnelCommandError = async (output, context) => {
|
|
103
103
|
const parsedOutput = {
|
|
104
104
|
...output,
|
|
105
105
|
body: await parseErrorBody(output.body, context),
|
|
@@ -108,7 +108,7 @@ const deserializeAws_json1_1CloseTunnelCommandError = async (output, context) =>
|
|
|
108
108
|
switch (errorCode) {
|
|
109
109
|
case "ResourceNotFoundException":
|
|
110
110
|
case "com.amazonaws.iotsecuretunneling#ResourceNotFoundException":
|
|
111
|
-
throw await
|
|
111
|
+
throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
|
|
112
112
|
default:
|
|
113
113
|
const parsedBody = parsedOutput.body;
|
|
114
114
|
(0, smithy_client_1.throwDefaultError)({
|
|
@@ -119,21 +119,21 @@ const deserializeAws_json1_1CloseTunnelCommandError = async (output, context) =>
|
|
|
119
119
|
});
|
|
120
120
|
}
|
|
121
121
|
};
|
|
122
|
-
const
|
|
122
|
+
const de_DescribeTunnelCommand = async (output, context) => {
|
|
123
123
|
if (output.statusCode >= 300) {
|
|
124
|
-
return
|
|
124
|
+
return de_DescribeTunnelCommandError(output, context);
|
|
125
125
|
}
|
|
126
126
|
const data = await parseBody(output.body, context);
|
|
127
127
|
let contents = {};
|
|
128
|
-
contents =
|
|
128
|
+
contents = de_DescribeTunnelResponse(data, context);
|
|
129
129
|
const response = {
|
|
130
130
|
$metadata: deserializeMetadata(output),
|
|
131
131
|
...contents,
|
|
132
132
|
};
|
|
133
133
|
return Promise.resolve(response);
|
|
134
134
|
};
|
|
135
|
-
exports.
|
|
136
|
-
const
|
|
135
|
+
exports.de_DescribeTunnelCommand = de_DescribeTunnelCommand;
|
|
136
|
+
const de_DescribeTunnelCommandError = async (output, context) => {
|
|
137
137
|
const parsedOutput = {
|
|
138
138
|
...output,
|
|
139
139
|
body: await parseErrorBody(output.body, context),
|
|
@@ -142,7 +142,7 @@ const deserializeAws_json1_1DescribeTunnelCommandError = async (output, context)
|
|
|
142
142
|
switch (errorCode) {
|
|
143
143
|
case "ResourceNotFoundException":
|
|
144
144
|
case "com.amazonaws.iotsecuretunneling#ResourceNotFoundException":
|
|
145
|
-
throw await
|
|
145
|
+
throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
|
|
146
146
|
default:
|
|
147
147
|
const parsedBody = parsedOutput.body;
|
|
148
148
|
(0, smithy_client_1.throwDefaultError)({
|
|
@@ -153,21 +153,21 @@ const deserializeAws_json1_1DescribeTunnelCommandError = async (output, context)
|
|
|
153
153
|
});
|
|
154
154
|
}
|
|
155
155
|
};
|
|
156
|
-
const
|
|
156
|
+
const de_ListTagsForResourceCommand = async (output, context) => {
|
|
157
157
|
if (output.statusCode >= 300) {
|
|
158
|
-
return
|
|
158
|
+
return de_ListTagsForResourceCommandError(output, context);
|
|
159
159
|
}
|
|
160
160
|
const data = await parseBody(output.body, context);
|
|
161
161
|
let contents = {};
|
|
162
|
-
contents =
|
|
162
|
+
contents = de_ListTagsForResourceResponse(data, context);
|
|
163
163
|
const response = {
|
|
164
164
|
$metadata: deserializeMetadata(output),
|
|
165
165
|
...contents,
|
|
166
166
|
};
|
|
167
167
|
return Promise.resolve(response);
|
|
168
168
|
};
|
|
169
|
-
exports.
|
|
170
|
-
const
|
|
169
|
+
exports.de_ListTagsForResourceCommand = de_ListTagsForResourceCommand;
|
|
170
|
+
const de_ListTagsForResourceCommandError = async (output, context) => {
|
|
171
171
|
const parsedOutput = {
|
|
172
172
|
...output,
|
|
173
173
|
body: await parseErrorBody(output.body, context),
|
|
@@ -176,7 +176,7 @@ const deserializeAws_json1_1ListTagsForResourceCommandError = async (output, con
|
|
|
176
176
|
switch (errorCode) {
|
|
177
177
|
case "ResourceNotFoundException":
|
|
178
178
|
case "com.amazonaws.iotsecuretunneling#ResourceNotFoundException":
|
|
179
|
-
throw await
|
|
179
|
+
throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
|
|
180
180
|
default:
|
|
181
181
|
const parsedBody = parsedOutput.body;
|
|
182
182
|
(0, smithy_client_1.throwDefaultError)({
|
|
@@ -187,21 +187,21 @@ const deserializeAws_json1_1ListTagsForResourceCommandError = async (output, con
|
|
|
187
187
|
});
|
|
188
188
|
}
|
|
189
189
|
};
|
|
190
|
-
const
|
|
190
|
+
const de_ListTunnelsCommand = async (output, context) => {
|
|
191
191
|
if (output.statusCode >= 300) {
|
|
192
|
-
return
|
|
192
|
+
return de_ListTunnelsCommandError(output, context);
|
|
193
193
|
}
|
|
194
194
|
const data = await parseBody(output.body, context);
|
|
195
195
|
let contents = {};
|
|
196
|
-
contents =
|
|
196
|
+
contents = de_ListTunnelsResponse(data, context);
|
|
197
197
|
const response = {
|
|
198
198
|
$metadata: deserializeMetadata(output),
|
|
199
199
|
...contents,
|
|
200
200
|
};
|
|
201
201
|
return Promise.resolve(response);
|
|
202
202
|
};
|
|
203
|
-
exports.
|
|
204
|
-
const
|
|
203
|
+
exports.de_ListTunnelsCommand = de_ListTunnelsCommand;
|
|
204
|
+
const de_ListTunnelsCommandError = async (output, context) => {
|
|
205
205
|
const parsedOutput = {
|
|
206
206
|
...output,
|
|
207
207
|
body: await parseErrorBody(output.body, context),
|
|
@@ -215,21 +215,21 @@ const deserializeAws_json1_1ListTunnelsCommandError = async (output, context) =>
|
|
|
215
215
|
errorCode,
|
|
216
216
|
});
|
|
217
217
|
};
|
|
218
|
-
const
|
|
218
|
+
const de_OpenTunnelCommand = async (output, context) => {
|
|
219
219
|
if (output.statusCode >= 300) {
|
|
220
|
-
return
|
|
220
|
+
return de_OpenTunnelCommandError(output, context);
|
|
221
221
|
}
|
|
222
222
|
const data = await parseBody(output.body, context);
|
|
223
223
|
let contents = {};
|
|
224
|
-
contents =
|
|
224
|
+
contents = de_OpenTunnelResponse(data, context);
|
|
225
225
|
const response = {
|
|
226
226
|
$metadata: deserializeMetadata(output),
|
|
227
227
|
...contents,
|
|
228
228
|
};
|
|
229
229
|
return Promise.resolve(response);
|
|
230
230
|
};
|
|
231
|
-
exports.
|
|
232
|
-
const
|
|
231
|
+
exports.de_OpenTunnelCommand = de_OpenTunnelCommand;
|
|
232
|
+
const de_OpenTunnelCommandError = async (output, context) => {
|
|
233
233
|
const parsedOutput = {
|
|
234
234
|
...output,
|
|
235
235
|
body: await parseErrorBody(output.body, context),
|
|
@@ -238,7 +238,7 @@ const deserializeAws_json1_1OpenTunnelCommandError = async (output, context) =>
|
|
|
238
238
|
switch (errorCode) {
|
|
239
239
|
case "LimitExceededException":
|
|
240
240
|
case "com.amazonaws.iotsecuretunneling#LimitExceededException":
|
|
241
|
-
throw await
|
|
241
|
+
throw await de_LimitExceededExceptionRes(parsedOutput, context);
|
|
242
242
|
default:
|
|
243
243
|
const parsedBody = parsedOutput.body;
|
|
244
244
|
(0, smithy_client_1.throwDefaultError)({
|
|
@@ -249,21 +249,21 @@ const deserializeAws_json1_1OpenTunnelCommandError = async (output, context) =>
|
|
|
249
249
|
});
|
|
250
250
|
}
|
|
251
251
|
};
|
|
252
|
-
const
|
|
252
|
+
const de_RotateTunnelAccessTokenCommand = async (output, context) => {
|
|
253
253
|
if (output.statusCode >= 300) {
|
|
254
|
-
return
|
|
254
|
+
return de_RotateTunnelAccessTokenCommandError(output, context);
|
|
255
255
|
}
|
|
256
256
|
const data = await parseBody(output.body, context);
|
|
257
257
|
let contents = {};
|
|
258
|
-
contents =
|
|
258
|
+
contents = de_RotateTunnelAccessTokenResponse(data, context);
|
|
259
259
|
const response = {
|
|
260
260
|
$metadata: deserializeMetadata(output),
|
|
261
261
|
...contents,
|
|
262
262
|
};
|
|
263
263
|
return Promise.resolve(response);
|
|
264
264
|
};
|
|
265
|
-
exports.
|
|
266
|
-
const
|
|
265
|
+
exports.de_RotateTunnelAccessTokenCommand = de_RotateTunnelAccessTokenCommand;
|
|
266
|
+
const de_RotateTunnelAccessTokenCommandError = async (output, context) => {
|
|
267
267
|
const parsedOutput = {
|
|
268
268
|
...output,
|
|
269
269
|
body: await parseErrorBody(output.body, context),
|
|
@@ -272,7 +272,7 @@ const deserializeAws_json1_1RotateTunnelAccessTokenCommandError = async (output,
|
|
|
272
272
|
switch (errorCode) {
|
|
273
273
|
case "ResourceNotFoundException":
|
|
274
274
|
case "com.amazonaws.iotsecuretunneling#ResourceNotFoundException":
|
|
275
|
-
throw await
|
|
275
|
+
throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
|
|
276
276
|
default:
|
|
277
277
|
const parsedBody = parsedOutput.body;
|
|
278
278
|
(0, smithy_client_1.throwDefaultError)({
|
|
@@ -283,21 +283,21 @@ const deserializeAws_json1_1RotateTunnelAccessTokenCommandError = async (output,
|
|
|
283
283
|
});
|
|
284
284
|
}
|
|
285
285
|
};
|
|
286
|
-
const
|
|
286
|
+
const de_TagResourceCommand = async (output, context) => {
|
|
287
287
|
if (output.statusCode >= 300) {
|
|
288
|
-
return
|
|
288
|
+
return de_TagResourceCommandError(output, context);
|
|
289
289
|
}
|
|
290
290
|
const data = await parseBody(output.body, context);
|
|
291
291
|
let contents = {};
|
|
292
|
-
contents =
|
|
292
|
+
contents = de_TagResourceResponse(data, context);
|
|
293
293
|
const response = {
|
|
294
294
|
$metadata: deserializeMetadata(output),
|
|
295
295
|
...contents,
|
|
296
296
|
};
|
|
297
297
|
return Promise.resolve(response);
|
|
298
298
|
};
|
|
299
|
-
exports.
|
|
300
|
-
const
|
|
299
|
+
exports.de_TagResourceCommand = de_TagResourceCommand;
|
|
300
|
+
const de_TagResourceCommandError = async (output, context) => {
|
|
301
301
|
const parsedOutput = {
|
|
302
302
|
...output,
|
|
303
303
|
body: await parseErrorBody(output.body, context),
|
|
@@ -306,7 +306,7 @@ const deserializeAws_json1_1TagResourceCommandError = async (output, context) =>
|
|
|
306
306
|
switch (errorCode) {
|
|
307
307
|
case "ResourceNotFoundException":
|
|
308
308
|
case "com.amazonaws.iotsecuretunneling#ResourceNotFoundException":
|
|
309
|
-
throw await
|
|
309
|
+
throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
|
|
310
310
|
default:
|
|
311
311
|
const parsedBody = parsedOutput.body;
|
|
312
312
|
(0, smithy_client_1.throwDefaultError)({
|
|
@@ -317,21 +317,21 @@ const deserializeAws_json1_1TagResourceCommandError = async (output, context) =>
|
|
|
317
317
|
});
|
|
318
318
|
}
|
|
319
319
|
};
|
|
320
|
-
const
|
|
320
|
+
const de_UntagResourceCommand = async (output, context) => {
|
|
321
321
|
if (output.statusCode >= 300) {
|
|
322
|
-
return
|
|
322
|
+
return de_UntagResourceCommandError(output, context);
|
|
323
323
|
}
|
|
324
324
|
const data = await parseBody(output.body, context);
|
|
325
325
|
let contents = {};
|
|
326
|
-
contents =
|
|
326
|
+
contents = de_UntagResourceResponse(data, context);
|
|
327
327
|
const response = {
|
|
328
328
|
$metadata: deserializeMetadata(output),
|
|
329
329
|
...contents,
|
|
330
330
|
};
|
|
331
331
|
return Promise.resolve(response);
|
|
332
332
|
};
|
|
333
|
-
exports.
|
|
334
|
-
const
|
|
333
|
+
exports.de_UntagResourceCommand = de_UntagResourceCommand;
|
|
334
|
+
const de_UntagResourceCommandError = async (output, context) => {
|
|
335
335
|
const parsedOutput = {
|
|
336
336
|
...output,
|
|
337
337
|
body: await parseErrorBody(output.body, context),
|
|
@@ -340,7 +340,7 @@ const deserializeAws_json1_1UntagResourceCommandError = async (output, context)
|
|
|
340
340
|
switch (errorCode) {
|
|
341
341
|
case "ResourceNotFoundException":
|
|
342
342
|
case "com.amazonaws.iotsecuretunneling#ResourceNotFoundException":
|
|
343
|
-
throw await
|
|
343
|
+
throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
|
|
344
344
|
default:
|
|
345
345
|
const parsedBody = parsedOutput.body;
|
|
346
346
|
(0, smithy_client_1.throwDefaultError)({
|
|
@@ -351,122 +351,120 @@ const deserializeAws_json1_1UntagResourceCommandError = async (output, context)
|
|
|
351
351
|
});
|
|
352
352
|
}
|
|
353
353
|
};
|
|
354
|
-
const
|
|
354
|
+
const de_LimitExceededExceptionRes = async (parsedOutput, context) => {
|
|
355
355
|
const body = parsedOutput.body;
|
|
356
|
-
const deserialized =
|
|
356
|
+
const deserialized = de_LimitExceededException(body, context);
|
|
357
357
|
const exception = new models_0_1.LimitExceededException({
|
|
358
358
|
$metadata: deserializeMetadata(parsedOutput),
|
|
359
359
|
...deserialized,
|
|
360
360
|
});
|
|
361
361
|
return (0, smithy_client_1.decorateServiceException)(exception, body);
|
|
362
362
|
};
|
|
363
|
-
const
|
|
363
|
+
const de_ResourceNotFoundExceptionRes = async (parsedOutput, context) => {
|
|
364
364
|
const body = parsedOutput.body;
|
|
365
|
-
const deserialized =
|
|
365
|
+
const deserialized = de_ResourceNotFoundException(body, context);
|
|
366
366
|
const exception = new models_0_1.ResourceNotFoundException({
|
|
367
367
|
$metadata: deserializeMetadata(parsedOutput),
|
|
368
368
|
...deserialized,
|
|
369
369
|
});
|
|
370
370
|
return (0, smithy_client_1.decorateServiceException)(exception, body);
|
|
371
371
|
};
|
|
372
|
-
const
|
|
372
|
+
const se_CloseTunnelRequest = (input, context) => {
|
|
373
373
|
return {
|
|
374
374
|
...(input.delete != null && { delete: input.delete }),
|
|
375
375
|
...(input.tunnelId != null && { tunnelId: input.tunnelId }),
|
|
376
376
|
};
|
|
377
377
|
};
|
|
378
|
-
const
|
|
378
|
+
const se_DescribeTunnelRequest = (input, context) => {
|
|
379
379
|
return {
|
|
380
380
|
...(input.tunnelId != null && { tunnelId: input.tunnelId }),
|
|
381
381
|
};
|
|
382
382
|
};
|
|
383
|
-
const
|
|
383
|
+
const se_DestinationConfig = (input, context) => {
|
|
384
384
|
return {
|
|
385
|
-
...(input.services != null && { services:
|
|
385
|
+
...(input.services != null && { services: se_ServiceList(input.services, context) }),
|
|
386
386
|
...(input.thingName != null && { thingName: input.thingName }),
|
|
387
387
|
};
|
|
388
388
|
};
|
|
389
|
-
const
|
|
389
|
+
const se_ListTagsForResourceRequest = (input, context) => {
|
|
390
390
|
return {
|
|
391
391
|
...(input.resourceArn != null && { resourceArn: input.resourceArn }),
|
|
392
392
|
};
|
|
393
393
|
};
|
|
394
|
-
const
|
|
394
|
+
const se_ListTunnelsRequest = (input, context) => {
|
|
395
395
|
return {
|
|
396
396
|
...(input.maxResults != null && { maxResults: input.maxResults }),
|
|
397
397
|
...(input.nextToken != null && { nextToken: input.nextToken }),
|
|
398
398
|
...(input.thingName != null && { thingName: input.thingName }),
|
|
399
399
|
};
|
|
400
400
|
};
|
|
401
|
-
const
|
|
401
|
+
const se_OpenTunnelRequest = (input, context) => {
|
|
402
402
|
return {
|
|
403
403
|
...(input.description != null && { description: input.description }),
|
|
404
404
|
...(input.destinationConfig != null && {
|
|
405
|
-
destinationConfig:
|
|
406
|
-
}),
|
|
407
|
-
...(input.tags != null && { tags: serializeAws_json1_1TagList(input.tags, context) }),
|
|
408
|
-
...(input.timeoutConfig != null && {
|
|
409
|
-
timeoutConfig: serializeAws_json1_1TimeoutConfig(input.timeoutConfig, context),
|
|
405
|
+
destinationConfig: se_DestinationConfig(input.destinationConfig, context),
|
|
410
406
|
}),
|
|
407
|
+
...(input.tags != null && { tags: se_TagList(input.tags, context) }),
|
|
408
|
+
...(input.timeoutConfig != null && { timeoutConfig: se_TimeoutConfig(input.timeoutConfig, context) }),
|
|
411
409
|
};
|
|
412
410
|
};
|
|
413
|
-
const
|
|
411
|
+
const se_RotateTunnelAccessTokenRequest = (input, context) => {
|
|
414
412
|
return {
|
|
415
413
|
...(input.clientMode != null && { clientMode: input.clientMode }),
|
|
416
414
|
...(input.destinationConfig != null && {
|
|
417
|
-
destinationConfig:
|
|
415
|
+
destinationConfig: se_DestinationConfig(input.destinationConfig, context),
|
|
418
416
|
}),
|
|
419
417
|
...(input.tunnelId != null && { tunnelId: input.tunnelId }),
|
|
420
418
|
};
|
|
421
419
|
};
|
|
422
|
-
const
|
|
420
|
+
const se_ServiceList = (input, context) => {
|
|
423
421
|
return input
|
|
424
422
|
.filter((e) => e != null)
|
|
425
423
|
.map((entry) => {
|
|
426
424
|
return entry;
|
|
427
425
|
});
|
|
428
426
|
};
|
|
429
|
-
const
|
|
427
|
+
const se_Tag = (input, context) => {
|
|
430
428
|
return {
|
|
431
429
|
...(input.key != null && { key: input.key }),
|
|
432
430
|
...(input.value != null && { value: input.value }),
|
|
433
431
|
};
|
|
434
432
|
};
|
|
435
|
-
const
|
|
433
|
+
const se_TagKeyList = (input, context) => {
|
|
436
434
|
return input
|
|
437
435
|
.filter((e) => e != null)
|
|
438
436
|
.map((entry) => {
|
|
439
437
|
return entry;
|
|
440
438
|
});
|
|
441
439
|
};
|
|
442
|
-
const
|
|
440
|
+
const se_TagList = (input, context) => {
|
|
443
441
|
return input
|
|
444
442
|
.filter((e) => e != null)
|
|
445
443
|
.map((entry) => {
|
|
446
|
-
return
|
|
444
|
+
return se_Tag(entry, context);
|
|
447
445
|
});
|
|
448
446
|
};
|
|
449
|
-
const
|
|
447
|
+
const se_TagResourceRequest = (input, context) => {
|
|
450
448
|
return {
|
|
451
449
|
...(input.resourceArn != null && { resourceArn: input.resourceArn }),
|
|
452
|
-
...(input.tags != null && { tags:
|
|
450
|
+
...(input.tags != null && { tags: se_TagList(input.tags, context) }),
|
|
453
451
|
};
|
|
454
452
|
};
|
|
455
|
-
const
|
|
453
|
+
const se_TimeoutConfig = (input, context) => {
|
|
456
454
|
return {
|
|
457
455
|
...(input.maxLifetimeTimeoutMinutes != null && { maxLifetimeTimeoutMinutes: input.maxLifetimeTimeoutMinutes }),
|
|
458
456
|
};
|
|
459
457
|
};
|
|
460
|
-
const
|
|
458
|
+
const se_UntagResourceRequest = (input, context) => {
|
|
461
459
|
return {
|
|
462
460
|
...(input.resourceArn != null && { resourceArn: input.resourceArn }),
|
|
463
|
-
...(input.tagKeys != null && { tagKeys:
|
|
461
|
+
...(input.tagKeys != null && { tagKeys: se_TagKeyList(input.tagKeys, context) }),
|
|
464
462
|
};
|
|
465
463
|
};
|
|
466
|
-
const
|
|
464
|
+
const de_CloseTunnelResponse = (output, context) => {
|
|
467
465
|
return {};
|
|
468
466
|
};
|
|
469
|
-
const
|
|
467
|
+
const de_ConnectionState = (output, context) => {
|
|
470
468
|
return {
|
|
471
469
|
lastUpdatedAt: output.lastUpdatedAt != null
|
|
472
470
|
? (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseEpochTimestamp)((0, smithy_client_1.expectNumber)(output.lastUpdatedAt)))
|
|
@@ -474,36 +472,34 @@ const deserializeAws_json1_1ConnectionState = (output, context) => {
|
|
|
474
472
|
status: (0, smithy_client_1.expectString)(output.status),
|
|
475
473
|
};
|
|
476
474
|
};
|
|
477
|
-
const
|
|
475
|
+
const de_DescribeTunnelResponse = (output, context) => {
|
|
478
476
|
return {
|
|
479
|
-
tunnel: output.tunnel != null ?
|
|
477
|
+
tunnel: output.tunnel != null ? de_Tunnel(output.tunnel, context) : undefined,
|
|
480
478
|
};
|
|
481
479
|
};
|
|
482
|
-
const
|
|
480
|
+
const de_DestinationConfig = (output, context) => {
|
|
483
481
|
return {
|
|
484
|
-
services: output.services != null ?
|
|
482
|
+
services: output.services != null ? de_ServiceList(output.services, context) : undefined,
|
|
485
483
|
thingName: (0, smithy_client_1.expectString)(output.thingName),
|
|
486
484
|
};
|
|
487
485
|
};
|
|
488
|
-
const
|
|
486
|
+
const de_LimitExceededException = (output, context) => {
|
|
489
487
|
return {
|
|
490
488
|
message: (0, smithy_client_1.expectString)(output.message),
|
|
491
489
|
};
|
|
492
490
|
};
|
|
493
|
-
const
|
|
491
|
+
const de_ListTagsForResourceResponse = (output, context) => {
|
|
494
492
|
return {
|
|
495
|
-
tags: output.tags != null ?
|
|
493
|
+
tags: output.tags != null ? de_TagList(output.tags, context) : undefined,
|
|
496
494
|
};
|
|
497
495
|
};
|
|
498
|
-
const
|
|
496
|
+
const de_ListTunnelsResponse = (output, context) => {
|
|
499
497
|
return {
|
|
500
498
|
nextToken: (0, smithy_client_1.expectString)(output.nextToken),
|
|
501
|
-
tunnelSummaries: output.tunnelSummaries != null
|
|
502
|
-
? deserializeAws_json1_1TunnelSummaryList(output.tunnelSummaries, context)
|
|
503
|
-
: undefined,
|
|
499
|
+
tunnelSummaries: output.tunnelSummaries != null ? de_TunnelSummaryList(output.tunnelSummaries, context) : undefined,
|
|
504
500
|
};
|
|
505
501
|
};
|
|
506
|
-
const
|
|
502
|
+
const de_OpenTunnelResponse = (output, context) => {
|
|
507
503
|
return {
|
|
508
504
|
destinationAccessToken: (0, smithy_client_1.expectString)(output.destinationAccessToken),
|
|
509
505
|
sourceAccessToken: (0, smithy_client_1.expectString)(output.sourceAccessToken),
|
|
@@ -511,19 +507,19 @@ const deserializeAws_json1_1OpenTunnelResponse = (output, context) => {
|
|
|
511
507
|
tunnelId: (0, smithy_client_1.expectString)(output.tunnelId),
|
|
512
508
|
};
|
|
513
509
|
};
|
|
514
|
-
const
|
|
510
|
+
const de_ResourceNotFoundException = (output, context) => {
|
|
515
511
|
return {
|
|
516
512
|
message: (0, smithy_client_1.expectString)(output.message),
|
|
517
513
|
};
|
|
518
514
|
};
|
|
519
|
-
const
|
|
515
|
+
const de_RotateTunnelAccessTokenResponse = (output, context) => {
|
|
520
516
|
return {
|
|
521
517
|
destinationAccessToken: (0, smithy_client_1.expectString)(output.destinationAccessToken),
|
|
522
518
|
sourceAccessToken: (0, smithy_client_1.expectString)(output.sourceAccessToken),
|
|
523
519
|
tunnelArn: (0, smithy_client_1.expectString)(output.tunnelArn),
|
|
524
520
|
};
|
|
525
521
|
};
|
|
526
|
-
const
|
|
522
|
+
const de_ServiceList = (output, context) => {
|
|
527
523
|
const retVal = (output || [])
|
|
528
524
|
.filter((e) => e != null)
|
|
529
525
|
.map((entry) => {
|
|
@@ -534,55 +530,51 @@ const deserializeAws_json1_1ServiceList = (output, context) => {
|
|
|
534
530
|
});
|
|
535
531
|
return retVal;
|
|
536
532
|
};
|
|
537
|
-
const
|
|
533
|
+
const de_Tag = (output, context) => {
|
|
538
534
|
return {
|
|
539
535
|
key: (0, smithy_client_1.expectString)(output.key),
|
|
540
536
|
value: (0, smithy_client_1.expectString)(output.value),
|
|
541
537
|
};
|
|
542
538
|
};
|
|
543
|
-
const
|
|
539
|
+
const de_TagList = (output, context) => {
|
|
544
540
|
const retVal = (output || [])
|
|
545
541
|
.filter((e) => e != null)
|
|
546
542
|
.map((entry) => {
|
|
547
543
|
if (entry === null) {
|
|
548
544
|
return null;
|
|
549
545
|
}
|
|
550
|
-
return
|
|
546
|
+
return de_Tag(entry, context);
|
|
551
547
|
});
|
|
552
548
|
return retVal;
|
|
553
549
|
};
|
|
554
|
-
const
|
|
550
|
+
const de_TagResourceResponse = (output, context) => {
|
|
555
551
|
return {};
|
|
556
552
|
};
|
|
557
|
-
const
|
|
553
|
+
const de_TimeoutConfig = (output, context) => {
|
|
558
554
|
return {
|
|
559
555
|
maxLifetimeTimeoutMinutes: (0, smithy_client_1.expectInt32)(output.maxLifetimeTimeoutMinutes),
|
|
560
556
|
};
|
|
561
557
|
};
|
|
562
|
-
const
|
|
558
|
+
const de_Tunnel = (output, context) => {
|
|
563
559
|
return {
|
|
564
560
|
createdAt: output.createdAt != null ? (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseEpochTimestamp)((0, smithy_client_1.expectNumber)(output.createdAt))) : undefined,
|
|
565
561
|
description: (0, smithy_client_1.expectString)(output.description),
|
|
566
|
-
destinationConfig: output.destinationConfig != null
|
|
567
|
-
? deserializeAws_json1_1DestinationConfig(output.destinationConfig, context)
|
|
568
|
-
: undefined,
|
|
562
|
+
destinationConfig: output.destinationConfig != null ? de_DestinationConfig(output.destinationConfig, context) : undefined,
|
|
569
563
|
destinationConnectionState: output.destinationConnectionState != null
|
|
570
|
-
?
|
|
564
|
+
? de_ConnectionState(output.destinationConnectionState, context)
|
|
571
565
|
: undefined,
|
|
572
566
|
lastUpdatedAt: output.lastUpdatedAt != null
|
|
573
567
|
? (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseEpochTimestamp)((0, smithy_client_1.expectNumber)(output.lastUpdatedAt)))
|
|
574
568
|
: undefined,
|
|
575
|
-
sourceConnectionState: output.sourceConnectionState != null
|
|
576
|
-
? deserializeAws_json1_1ConnectionState(output.sourceConnectionState, context)
|
|
577
|
-
: undefined,
|
|
569
|
+
sourceConnectionState: output.sourceConnectionState != null ? de_ConnectionState(output.sourceConnectionState, context) : undefined,
|
|
578
570
|
status: (0, smithy_client_1.expectString)(output.status),
|
|
579
|
-
tags: output.tags != null ?
|
|
580
|
-
timeoutConfig: output.timeoutConfig != null ?
|
|
571
|
+
tags: output.tags != null ? de_TagList(output.tags, context) : undefined,
|
|
572
|
+
timeoutConfig: output.timeoutConfig != null ? de_TimeoutConfig(output.timeoutConfig, context) : undefined,
|
|
581
573
|
tunnelArn: (0, smithy_client_1.expectString)(output.tunnelArn),
|
|
582
574
|
tunnelId: (0, smithy_client_1.expectString)(output.tunnelId),
|
|
583
575
|
};
|
|
584
576
|
};
|
|
585
|
-
const
|
|
577
|
+
const de_TunnelSummary = (output, context) => {
|
|
586
578
|
return {
|
|
587
579
|
createdAt: output.createdAt != null ? (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseEpochTimestamp)((0, smithy_client_1.expectNumber)(output.createdAt))) : undefined,
|
|
588
580
|
description: (0, smithy_client_1.expectString)(output.description),
|
|
@@ -594,18 +586,18 @@ const deserializeAws_json1_1TunnelSummary = (output, context) => {
|
|
|
594
586
|
tunnelId: (0, smithy_client_1.expectString)(output.tunnelId),
|
|
595
587
|
};
|
|
596
588
|
};
|
|
597
|
-
const
|
|
589
|
+
const de_TunnelSummaryList = (output, context) => {
|
|
598
590
|
const retVal = (output || [])
|
|
599
591
|
.filter((e) => e != null)
|
|
600
592
|
.map((entry) => {
|
|
601
593
|
if (entry === null) {
|
|
602
594
|
return null;
|
|
603
595
|
}
|
|
604
|
-
return
|
|
596
|
+
return de_TunnelSummary(entry, context);
|
|
605
597
|
});
|
|
606
598
|
return retVal;
|
|
607
599
|
};
|
|
608
|
-
const
|
|
600
|
+
const de_UntagResourceResponse = (output, context) => {
|
|
609
601
|
return {};
|
|
610
602
|
};
|
|
611
603
|
const deserializeMetadata = (output) => ({
|