@aws-sdk/client-apigatewaymanagementapi 3.312.0 → 3.315.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.
|
@@ -65,7 +65,7 @@ const de_DeleteConnectionCommand = async (output, context) => {
|
|
|
65
65
|
if (output.statusCode !== 204 && output.statusCode >= 300) {
|
|
66
66
|
return de_DeleteConnectionCommandError(output, context);
|
|
67
67
|
}
|
|
68
|
-
const contents = map({
|
|
68
|
+
const contents = (0, smithy_client_1.map)({
|
|
69
69
|
$metadata: deserializeMetadata(output),
|
|
70
70
|
});
|
|
71
71
|
await collectBody(output.body, context);
|
|
@@ -90,10 +90,9 @@ const de_DeleteConnectionCommandError = async (output, context) => {
|
|
|
90
90
|
throw await de_LimitExceededExceptionRes(parsedOutput, context);
|
|
91
91
|
default:
|
|
92
92
|
const parsedBody = parsedOutput.body;
|
|
93
|
-
|
|
93
|
+
return throwDefaultError({
|
|
94
94
|
output,
|
|
95
95
|
parsedBody,
|
|
96
|
-
exceptionCtor: ApiGatewayManagementApiServiceException_1.ApiGatewayManagementApiServiceException,
|
|
97
96
|
errorCode,
|
|
98
97
|
});
|
|
99
98
|
}
|
|
@@ -102,19 +101,16 @@ const de_GetConnectionCommand = async (output, context) => {
|
|
|
102
101
|
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
103
102
|
return de_GetConnectionCommandError(output, context);
|
|
104
103
|
}
|
|
105
|
-
const contents = map({
|
|
104
|
+
const contents = (0, smithy_client_1.map)({
|
|
106
105
|
$metadata: deserializeMetadata(output),
|
|
107
106
|
});
|
|
108
107
|
const data = (0, smithy_client_1.expectNonNull)((0, smithy_client_1.expectObject)(await parseBody(output.body, context)), "body");
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
if (data.lastActiveAt != null) {
|
|
116
|
-
contents.LastActiveAt = (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseRfc3339DateTimeWithOffset)(data.lastActiveAt));
|
|
117
|
-
}
|
|
108
|
+
const doc = (0, smithy_client_1.take)(data, {
|
|
109
|
+
ConnectedAt: [, (_) => (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseRfc3339DateTimeWithOffset)(_)), `connectedAt`],
|
|
110
|
+
Identity: [, (_) => de_Identity(_, context), `identity`],
|
|
111
|
+
LastActiveAt: [, (_) => (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseRfc3339DateTimeWithOffset)(_)), `lastActiveAt`],
|
|
112
|
+
});
|
|
113
|
+
Object.assign(contents, doc);
|
|
118
114
|
return contents;
|
|
119
115
|
};
|
|
120
116
|
exports.de_GetConnectionCommand = de_GetConnectionCommand;
|
|
@@ -136,10 +132,9 @@ const de_GetConnectionCommandError = async (output, context) => {
|
|
|
136
132
|
throw await de_LimitExceededExceptionRes(parsedOutput, context);
|
|
137
133
|
default:
|
|
138
134
|
const parsedBody = parsedOutput.body;
|
|
139
|
-
|
|
135
|
+
return throwDefaultError({
|
|
140
136
|
output,
|
|
141
137
|
parsedBody,
|
|
142
|
-
exceptionCtor: ApiGatewayManagementApiServiceException_1.ApiGatewayManagementApiServiceException,
|
|
143
138
|
errorCode,
|
|
144
139
|
});
|
|
145
140
|
}
|
|
@@ -148,7 +143,7 @@ const de_PostToConnectionCommand = async (output, context) => {
|
|
|
148
143
|
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
149
144
|
return de_PostToConnectionCommandError(output, context);
|
|
150
145
|
}
|
|
151
|
-
const contents = map({
|
|
146
|
+
const contents = (0, smithy_client_1.map)({
|
|
152
147
|
$metadata: deserializeMetadata(output),
|
|
153
148
|
});
|
|
154
149
|
await collectBody(output.body, context);
|
|
@@ -176,18 +171,19 @@ const de_PostToConnectionCommandError = async (output, context) => {
|
|
|
176
171
|
throw await de_PayloadTooLargeExceptionRes(parsedOutput, context);
|
|
177
172
|
default:
|
|
178
173
|
const parsedBody = parsedOutput.body;
|
|
179
|
-
|
|
174
|
+
return throwDefaultError({
|
|
180
175
|
output,
|
|
181
176
|
parsedBody,
|
|
182
|
-
exceptionCtor: ApiGatewayManagementApiServiceException_1.ApiGatewayManagementApiServiceException,
|
|
183
177
|
errorCode,
|
|
184
178
|
});
|
|
185
179
|
}
|
|
186
180
|
};
|
|
187
|
-
const
|
|
181
|
+
const throwDefaultError = (0, smithy_client_1.withBaseException)(ApiGatewayManagementApiServiceException_1.ApiGatewayManagementApiServiceException);
|
|
188
182
|
const de_ForbiddenExceptionRes = async (parsedOutput, context) => {
|
|
189
|
-
const contents = map({});
|
|
183
|
+
const contents = (0, smithy_client_1.map)({});
|
|
190
184
|
const data = parsedOutput.body;
|
|
185
|
+
const doc = (0, smithy_client_1.take)(data, {});
|
|
186
|
+
Object.assign(contents, doc);
|
|
191
187
|
const exception = new models_0_1.ForbiddenException({
|
|
192
188
|
$metadata: deserializeMetadata(parsedOutput),
|
|
193
189
|
...contents,
|
|
@@ -195,8 +191,10 @@ const de_ForbiddenExceptionRes = async (parsedOutput, context) => {
|
|
|
195
191
|
return (0, smithy_client_1.decorateServiceException)(exception, parsedOutput.body);
|
|
196
192
|
};
|
|
197
193
|
const de_GoneExceptionRes = async (parsedOutput, context) => {
|
|
198
|
-
const contents = map({});
|
|
194
|
+
const contents = (0, smithy_client_1.map)({});
|
|
199
195
|
const data = parsedOutput.body;
|
|
196
|
+
const doc = (0, smithy_client_1.take)(data, {});
|
|
197
|
+
Object.assign(contents, doc);
|
|
200
198
|
const exception = new models_0_1.GoneException({
|
|
201
199
|
$metadata: deserializeMetadata(parsedOutput),
|
|
202
200
|
...contents,
|
|
@@ -204,8 +202,10 @@ const de_GoneExceptionRes = async (parsedOutput, context) => {
|
|
|
204
202
|
return (0, smithy_client_1.decorateServiceException)(exception, parsedOutput.body);
|
|
205
203
|
};
|
|
206
204
|
const de_LimitExceededExceptionRes = async (parsedOutput, context) => {
|
|
207
|
-
const contents = map({});
|
|
205
|
+
const contents = (0, smithy_client_1.map)({});
|
|
208
206
|
const data = parsedOutput.body;
|
|
207
|
+
const doc = (0, smithy_client_1.take)(data, {});
|
|
208
|
+
Object.assign(contents, doc);
|
|
209
209
|
const exception = new models_0_1.LimitExceededException({
|
|
210
210
|
$metadata: deserializeMetadata(parsedOutput),
|
|
211
211
|
...contents,
|
|
@@ -213,11 +213,12 @@ const de_LimitExceededExceptionRes = async (parsedOutput, context) => {
|
|
|
213
213
|
return (0, smithy_client_1.decorateServiceException)(exception, parsedOutput.body);
|
|
214
214
|
};
|
|
215
215
|
const de_PayloadTooLargeExceptionRes = async (parsedOutput, context) => {
|
|
216
|
-
const contents = map({});
|
|
216
|
+
const contents = (0, smithy_client_1.map)({});
|
|
217
217
|
const data = parsedOutput.body;
|
|
218
|
-
|
|
219
|
-
|
|
220
|
-
}
|
|
218
|
+
const doc = (0, smithy_client_1.take)(data, {
|
|
219
|
+
Message: [, smithy_client_1.expectString, `message`],
|
|
220
|
+
});
|
|
221
|
+
Object.assign(contents, doc);
|
|
221
222
|
const exception = new models_0_1.PayloadTooLargeException({
|
|
222
223
|
$metadata: deserializeMetadata(parsedOutput),
|
|
223
224
|
...contents,
|
|
@@ -225,10 +226,10 @@ const de_PayloadTooLargeExceptionRes = async (parsedOutput, context) => {
|
|
|
225
226
|
return (0, smithy_client_1.decorateServiceException)(exception, parsedOutput.body);
|
|
226
227
|
};
|
|
227
228
|
const de_Identity = (output, context) => {
|
|
228
|
-
return {
|
|
229
|
-
SourceIp:
|
|
230
|
-
UserAgent:
|
|
231
|
-
};
|
|
229
|
+
return (0, smithy_client_1.take)(output, {
|
|
230
|
+
SourceIp: [, smithy_client_1.expectString, `sourceIp`],
|
|
231
|
+
UserAgent: [, smithy_client_1.expectString, `userAgent`],
|
|
232
|
+
});
|
|
232
233
|
};
|
|
233
234
|
const deserializeMetadata = (output) => ({
|
|
234
235
|
httpStatusCode: output.statusCode,
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { HttpRequest as __HttpRequest } from "@aws-sdk/protocol-http";
|
|
2
|
-
import { decorateServiceException as __decorateServiceException, expectNonNull as __expectNonNull, expectObject as __expectObject, expectString as __expectString, map
|
|
2
|
+
import { decorateServiceException as __decorateServiceException, expectNonNull as __expectNonNull, expectObject as __expectObject, expectString as __expectString, map, parseRfc3339DateTimeWithOffset as __parseRfc3339DateTimeWithOffset, resolvedPath as __resolvedPath, take, withBaseException, } from "@aws-sdk/smithy-client";
|
|
3
3
|
import { ApiGatewayManagementApiServiceException as __BaseException } from "../models/ApiGatewayManagementApiServiceException";
|
|
4
4
|
import { ForbiddenException, GoneException, LimitExceededException, PayloadTooLargeException, } from "../models/models_0";
|
|
5
5
|
export const se_DeleteConnectionCommand = async (input, context) => {
|
|
@@ -83,10 +83,9 @@ const de_DeleteConnectionCommandError = async (output, context) => {
|
|
|
83
83
|
throw await de_LimitExceededExceptionRes(parsedOutput, context);
|
|
84
84
|
default:
|
|
85
85
|
const parsedBody = parsedOutput.body;
|
|
86
|
-
throwDefaultError({
|
|
86
|
+
return throwDefaultError({
|
|
87
87
|
output,
|
|
88
88
|
parsedBody,
|
|
89
|
-
exceptionCtor: __BaseException,
|
|
90
89
|
errorCode,
|
|
91
90
|
});
|
|
92
91
|
}
|
|
@@ -99,15 +98,12 @@ export const de_GetConnectionCommand = async (output, context) => {
|
|
|
99
98
|
$metadata: deserializeMetadata(output),
|
|
100
99
|
});
|
|
101
100
|
const data = __expectNonNull(__expectObject(await parseBody(output.body, context)), "body");
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
if (data.lastActiveAt != null) {
|
|
109
|
-
contents.LastActiveAt = __expectNonNull(__parseRfc3339DateTimeWithOffset(data.lastActiveAt));
|
|
110
|
-
}
|
|
101
|
+
const doc = take(data, {
|
|
102
|
+
ConnectedAt: [, (_) => __expectNonNull(__parseRfc3339DateTimeWithOffset(_)), `connectedAt`],
|
|
103
|
+
Identity: [, (_) => de_Identity(_, context), `identity`],
|
|
104
|
+
LastActiveAt: [, (_) => __expectNonNull(__parseRfc3339DateTimeWithOffset(_)), `lastActiveAt`],
|
|
105
|
+
});
|
|
106
|
+
Object.assign(contents, doc);
|
|
111
107
|
return contents;
|
|
112
108
|
};
|
|
113
109
|
const de_GetConnectionCommandError = async (output, context) => {
|
|
@@ -128,10 +124,9 @@ const de_GetConnectionCommandError = async (output, context) => {
|
|
|
128
124
|
throw await de_LimitExceededExceptionRes(parsedOutput, context);
|
|
129
125
|
default:
|
|
130
126
|
const parsedBody = parsedOutput.body;
|
|
131
|
-
throwDefaultError({
|
|
127
|
+
return throwDefaultError({
|
|
132
128
|
output,
|
|
133
129
|
parsedBody,
|
|
134
|
-
exceptionCtor: __BaseException,
|
|
135
130
|
errorCode,
|
|
136
131
|
});
|
|
137
132
|
}
|
|
@@ -167,18 +162,19 @@ const de_PostToConnectionCommandError = async (output, context) => {
|
|
|
167
162
|
throw await de_PayloadTooLargeExceptionRes(parsedOutput, context);
|
|
168
163
|
default:
|
|
169
164
|
const parsedBody = parsedOutput.body;
|
|
170
|
-
throwDefaultError({
|
|
165
|
+
return throwDefaultError({
|
|
171
166
|
output,
|
|
172
167
|
parsedBody,
|
|
173
|
-
exceptionCtor: __BaseException,
|
|
174
168
|
errorCode,
|
|
175
169
|
});
|
|
176
170
|
}
|
|
177
171
|
};
|
|
178
|
-
const
|
|
172
|
+
const throwDefaultError = withBaseException(__BaseException);
|
|
179
173
|
const de_ForbiddenExceptionRes = async (parsedOutput, context) => {
|
|
180
174
|
const contents = map({});
|
|
181
175
|
const data = parsedOutput.body;
|
|
176
|
+
const doc = take(data, {});
|
|
177
|
+
Object.assign(contents, doc);
|
|
182
178
|
const exception = new ForbiddenException({
|
|
183
179
|
$metadata: deserializeMetadata(parsedOutput),
|
|
184
180
|
...contents,
|
|
@@ -188,6 +184,8 @@ const de_ForbiddenExceptionRes = async (parsedOutput, context) => {
|
|
|
188
184
|
const de_GoneExceptionRes = async (parsedOutput, context) => {
|
|
189
185
|
const contents = map({});
|
|
190
186
|
const data = parsedOutput.body;
|
|
187
|
+
const doc = take(data, {});
|
|
188
|
+
Object.assign(contents, doc);
|
|
191
189
|
const exception = new GoneException({
|
|
192
190
|
$metadata: deserializeMetadata(parsedOutput),
|
|
193
191
|
...contents,
|
|
@@ -197,6 +195,8 @@ const de_GoneExceptionRes = async (parsedOutput, context) => {
|
|
|
197
195
|
const de_LimitExceededExceptionRes = async (parsedOutput, context) => {
|
|
198
196
|
const contents = map({});
|
|
199
197
|
const data = parsedOutput.body;
|
|
198
|
+
const doc = take(data, {});
|
|
199
|
+
Object.assign(contents, doc);
|
|
200
200
|
const exception = new LimitExceededException({
|
|
201
201
|
$metadata: deserializeMetadata(parsedOutput),
|
|
202
202
|
...contents,
|
|
@@ -206,9 +206,10 @@ const de_LimitExceededExceptionRes = async (parsedOutput, context) => {
|
|
|
206
206
|
const de_PayloadTooLargeExceptionRes = async (parsedOutput, context) => {
|
|
207
207
|
const contents = map({});
|
|
208
208
|
const data = parsedOutput.body;
|
|
209
|
-
|
|
210
|
-
|
|
211
|
-
}
|
|
209
|
+
const doc = take(data, {
|
|
210
|
+
Message: [, __expectString, `message`],
|
|
211
|
+
});
|
|
212
|
+
Object.assign(contents, doc);
|
|
212
213
|
const exception = new PayloadTooLargeException({
|
|
213
214
|
$metadata: deserializeMetadata(parsedOutput),
|
|
214
215
|
...contents,
|
|
@@ -216,10 +217,10 @@ const de_PayloadTooLargeExceptionRes = async (parsedOutput, context) => {
|
|
|
216
217
|
return __decorateServiceException(exception, parsedOutput.body);
|
|
217
218
|
};
|
|
218
219
|
const de_Identity = (output, context) => {
|
|
219
|
-
return {
|
|
220
|
-
SourceIp: __expectString
|
|
221
|
-
UserAgent: __expectString
|
|
222
|
-
};
|
|
220
|
+
return take(output, {
|
|
221
|
+
SourceIp: [, __expectString, `sourceIp`],
|
|
222
|
+
UserAgent: [, __expectString, `userAgent`],
|
|
223
|
+
});
|
|
223
224
|
};
|
|
224
225
|
const deserializeMetadata = (output) => ({
|
|
225
226
|
httpStatusCode: output.statusCode,
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@aws-sdk/client-apigatewaymanagementapi",
|
|
3
3
|
"description": "AWS SDK for JavaScript Apigatewaymanagementapi Client for Node.js, Browser and React Native",
|
|
4
|
-
"version": "3.
|
|
4
|
+
"version": "3.315.0",
|
|
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",
|
|
@@ -21,9 +21,9 @@
|
|
|
21
21
|
"dependencies": {
|
|
22
22
|
"@aws-crypto/sha256-browser": "3.0.0",
|
|
23
23
|
"@aws-crypto/sha256-js": "3.0.0",
|
|
24
|
-
"@aws-sdk/client-sts": "3.
|
|
24
|
+
"@aws-sdk/client-sts": "3.315.0",
|
|
25
25
|
"@aws-sdk/config-resolver": "3.310.0",
|
|
26
|
-
"@aws-sdk/credential-provider-node": "3.
|
|
26
|
+
"@aws-sdk/credential-provider-node": "3.315.0",
|
|
27
27
|
"@aws-sdk/fetch-http-handler": "3.310.0",
|
|
28
28
|
"@aws-sdk/hash-node": "3.310.0",
|
|
29
29
|
"@aws-sdk/invalid-dependency": "3.310.0",
|
|
@@ -40,14 +40,14 @@
|
|
|
40
40
|
"@aws-sdk/node-config-provider": "3.310.0",
|
|
41
41
|
"@aws-sdk/node-http-handler": "3.310.0",
|
|
42
42
|
"@aws-sdk/protocol-http": "3.310.0",
|
|
43
|
-
"@aws-sdk/smithy-client": "3.
|
|
43
|
+
"@aws-sdk/smithy-client": "3.315.0",
|
|
44
44
|
"@aws-sdk/types": "3.310.0",
|
|
45
45
|
"@aws-sdk/url-parser": "3.310.0",
|
|
46
46
|
"@aws-sdk/util-base64": "3.310.0",
|
|
47
47
|
"@aws-sdk/util-body-length-browser": "3.310.0",
|
|
48
48
|
"@aws-sdk/util-body-length-node": "3.310.0",
|
|
49
|
-
"@aws-sdk/util-defaults-mode-browser": "3.
|
|
50
|
-
"@aws-sdk/util-defaults-mode-node": "3.
|
|
49
|
+
"@aws-sdk/util-defaults-mode-browser": "3.315.0",
|
|
50
|
+
"@aws-sdk/util-defaults-mode-node": "3.315.0",
|
|
51
51
|
"@aws-sdk/util-endpoints": "3.310.0",
|
|
52
52
|
"@aws-sdk/util-retry": "3.310.0",
|
|
53
53
|
"@aws-sdk/util-user-agent-browser": "3.310.0",
|