@aws-sdk/client-account 3.141.0 → 3.142.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/CHANGELOG.md +11 -0
- package/dist-cjs/protocols/Aws_restJson1.js +53 -69
- package/dist-es/protocols/Aws_restJson1.js +69 -70
- package/package.json +6 -6
package/CHANGELOG.md
CHANGED
|
@@ -3,6 +3,17 @@
|
|
|
3
3
|
All notable changes to this project will be documented in this file.
|
|
4
4
|
See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
|
|
5
5
|
|
|
6
|
+
# [3.142.0](https://github.com/aws/aws-sdk-js-v3/compare/v3.141.0...v3.142.0) (2022-08-02)
|
|
7
|
+
|
|
8
|
+
|
|
9
|
+
### Features
|
|
10
|
+
|
|
11
|
+
* **codegen:** general data mapping function ([#3830](https://github.com/aws/aws-sdk-js-v3/issues/3830)) ([9417eae](https://github.com/aws/aws-sdk-js-v3/commit/9417eae722806799fb4c15c07921574268c1165c))
|
|
12
|
+
|
|
13
|
+
|
|
14
|
+
|
|
15
|
+
|
|
16
|
+
|
|
6
17
|
# [3.141.0](https://github.com/aws/aws-sdk-js-v3/compare/v3.140.0...v3.141.0) (2022-08-01)
|
|
7
18
|
|
|
8
19
|
|
|
@@ -124,11 +124,11 @@ const deserializeAws_restJson1DeleteAlternateContactCommand = async (output, con
|
|
|
124
124
|
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
125
125
|
return deserializeAws_restJson1DeleteAlternateContactCommandError(output, context);
|
|
126
126
|
}
|
|
127
|
-
const contents = {
|
|
127
|
+
const contents = map({
|
|
128
128
|
$metadata: deserializeMetadata(output),
|
|
129
|
-
};
|
|
129
|
+
});
|
|
130
130
|
await collectBody(output.body, context);
|
|
131
|
-
return
|
|
131
|
+
return contents;
|
|
132
132
|
};
|
|
133
133
|
exports.deserializeAws_restJson1DeleteAlternateContactCommand = deserializeAws_restJson1DeleteAlternateContactCommand;
|
|
134
134
|
const deserializeAws_restJson1DeleteAlternateContactCommandError = async (output, context) => {
|
|
@@ -136,7 +136,6 @@ const deserializeAws_restJson1DeleteAlternateContactCommandError = async (output
|
|
|
136
136
|
...output,
|
|
137
137
|
body: await parseBody(output.body, context),
|
|
138
138
|
};
|
|
139
|
-
let response;
|
|
140
139
|
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
141
140
|
switch (errorCode) {
|
|
142
141
|
case "AccessDeniedException":
|
|
@@ -156,29 +155,26 @@ const deserializeAws_restJson1DeleteAlternateContactCommandError = async (output
|
|
|
156
155
|
throw await deserializeAws_restJson1ValidationExceptionResponse(parsedOutput, context);
|
|
157
156
|
default:
|
|
158
157
|
const parsedBody = parsedOutput.body;
|
|
159
|
-
|
|
160
|
-
|
|
161
|
-
|
|
162
|
-
|
|
163
|
-
|
|
164
|
-
$metadata,
|
|
158
|
+
(0, smithy_client_1.throwDefaultError)({
|
|
159
|
+
output,
|
|
160
|
+
parsedBody,
|
|
161
|
+
exceptionCtor: AccountServiceException_1.AccountServiceException,
|
|
162
|
+
errorCode,
|
|
165
163
|
});
|
|
166
|
-
throw (0, smithy_client_1.decorateServiceException)(response, parsedBody);
|
|
167
164
|
}
|
|
168
165
|
};
|
|
169
166
|
const deserializeAws_restJson1GetAlternateContactCommand = async (output, context) => {
|
|
170
167
|
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
171
168
|
return deserializeAws_restJson1GetAlternateContactCommandError(output, context);
|
|
172
169
|
}
|
|
173
|
-
const contents = {
|
|
170
|
+
const contents = map({
|
|
174
171
|
$metadata: deserializeMetadata(output),
|
|
175
|
-
|
|
176
|
-
};
|
|
172
|
+
});
|
|
177
173
|
const data = (0, smithy_client_1.expectNonNull)((0, smithy_client_1.expectObject)(await parseBody(output.body, context)), "body");
|
|
178
|
-
if (data.AlternateContact
|
|
174
|
+
if (data.AlternateContact != null) {
|
|
179
175
|
contents.AlternateContact = deserializeAws_restJson1AlternateContact(data.AlternateContact, context);
|
|
180
176
|
}
|
|
181
|
-
return
|
|
177
|
+
return contents;
|
|
182
178
|
};
|
|
183
179
|
exports.deserializeAws_restJson1GetAlternateContactCommand = deserializeAws_restJson1GetAlternateContactCommand;
|
|
184
180
|
const deserializeAws_restJson1GetAlternateContactCommandError = async (output, context) => {
|
|
@@ -186,7 +182,6 @@ const deserializeAws_restJson1GetAlternateContactCommandError = async (output, c
|
|
|
186
182
|
...output,
|
|
187
183
|
body: await parseBody(output.body, context),
|
|
188
184
|
};
|
|
189
|
-
let response;
|
|
190
185
|
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
191
186
|
switch (errorCode) {
|
|
192
187
|
case "AccessDeniedException":
|
|
@@ -206,29 +201,26 @@ const deserializeAws_restJson1GetAlternateContactCommandError = async (output, c
|
|
|
206
201
|
throw await deserializeAws_restJson1ValidationExceptionResponse(parsedOutput, context);
|
|
207
202
|
default:
|
|
208
203
|
const parsedBody = parsedOutput.body;
|
|
209
|
-
|
|
210
|
-
|
|
211
|
-
|
|
212
|
-
|
|
213
|
-
|
|
214
|
-
$metadata,
|
|
204
|
+
(0, smithy_client_1.throwDefaultError)({
|
|
205
|
+
output,
|
|
206
|
+
parsedBody,
|
|
207
|
+
exceptionCtor: AccountServiceException_1.AccountServiceException,
|
|
208
|
+
errorCode,
|
|
215
209
|
});
|
|
216
|
-
throw (0, smithy_client_1.decorateServiceException)(response, parsedBody);
|
|
217
210
|
}
|
|
218
211
|
};
|
|
219
212
|
const deserializeAws_restJson1GetContactInformationCommand = async (output, context) => {
|
|
220
213
|
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
221
214
|
return deserializeAws_restJson1GetContactInformationCommandError(output, context);
|
|
222
215
|
}
|
|
223
|
-
const contents = {
|
|
216
|
+
const contents = map({
|
|
224
217
|
$metadata: deserializeMetadata(output),
|
|
225
|
-
|
|
226
|
-
};
|
|
218
|
+
});
|
|
227
219
|
const data = (0, smithy_client_1.expectNonNull)((0, smithy_client_1.expectObject)(await parseBody(output.body, context)), "body");
|
|
228
|
-
if (data.ContactInformation
|
|
220
|
+
if (data.ContactInformation != null) {
|
|
229
221
|
contents.ContactInformation = deserializeAws_restJson1ContactInformation(data.ContactInformation, context);
|
|
230
222
|
}
|
|
231
|
-
return
|
|
223
|
+
return contents;
|
|
232
224
|
};
|
|
233
225
|
exports.deserializeAws_restJson1GetContactInformationCommand = deserializeAws_restJson1GetContactInformationCommand;
|
|
234
226
|
const deserializeAws_restJson1GetContactInformationCommandError = async (output, context) => {
|
|
@@ -236,7 +228,6 @@ const deserializeAws_restJson1GetContactInformationCommandError = async (output,
|
|
|
236
228
|
...output,
|
|
237
229
|
body: await parseBody(output.body, context),
|
|
238
230
|
};
|
|
239
|
-
let response;
|
|
240
231
|
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
241
232
|
switch (errorCode) {
|
|
242
233
|
case "AccessDeniedException":
|
|
@@ -256,25 +247,23 @@ const deserializeAws_restJson1GetContactInformationCommandError = async (output,
|
|
|
256
247
|
throw await deserializeAws_restJson1ValidationExceptionResponse(parsedOutput, context);
|
|
257
248
|
default:
|
|
258
249
|
const parsedBody = parsedOutput.body;
|
|
259
|
-
|
|
260
|
-
|
|
261
|
-
|
|
262
|
-
|
|
263
|
-
|
|
264
|
-
$metadata,
|
|
250
|
+
(0, smithy_client_1.throwDefaultError)({
|
|
251
|
+
output,
|
|
252
|
+
parsedBody,
|
|
253
|
+
exceptionCtor: AccountServiceException_1.AccountServiceException,
|
|
254
|
+
errorCode,
|
|
265
255
|
});
|
|
266
|
-
throw (0, smithy_client_1.decorateServiceException)(response, parsedBody);
|
|
267
256
|
}
|
|
268
257
|
};
|
|
269
258
|
const deserializeAws_restJson1PutAlternateContactCommand = async (output, context) => {
|
|
270
259
|
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
271
260
|
return deserializeAws_restJson1PutAlternateContactCommandError(output, context);
|
|
272
261
|
}
|
|
273
|
-
const contents = {
|
|
262
|
+
const contents = map({
|
|
274
263
|
$metadata: deserializeMetadata(output),
|
|
275
|
-
};
|
|
264
|
+
});
|
|
276
265
|
await collectBody(output.body, context);
|
|
277
|
-
return
|
|
266
|
+
return contents;
|
|
278
267
|
};
|
|
279
268
|
exports.deserializeAws_restJson1PutAlternateContactCommand = deserializeAws_restJson1PutAlternateContactCommand;
|
|
280
269
|
const deserializeAws_restJson1PutAlternateContactCommandError = async (output, context) => {
|
|
@@ -282,7 +271,6 @@ const deserializeAws_restJson1PutAlternateContactCommandError = async (output, c
|
|
|
282
271
|
...output,
|
|
283
272
|
body: await parseBody(output.body, context),
|
|
284
273
|
};
|
|
285
|
-
let response;
|
|
286
274
|
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
287
275
|
switch (errorCode) {
|
|
288
276
|
case "AccessDeniedException":
|
|
@@ -299,25 +287,23 @@ const deserializeAws_restJson1PutAlternateContactCommandError = async (output, c
|
|
|
299
287
|
throw await deserializeAws_restJson1ValidationExceptionResponse(parsedOutput, context);
|
|
300
288
|
default:
|
|
301
289
|
const parsedBody = parsedOutput.body;
|
|
302
|
-
|
|
303
|
-
|
|
304
|
-
|
|
305
|
-
|
|
306
|
-
|
|
307
|
-
$metadata,
|
|
290
|
+
(0, smithy_client_1.throwDefaultError)({
|
|
291
|
+
output,
|
|
292
|
+
parsedBody,
|
|
293
|
+
exceptionCtor: AccountServiceException_1.AccountServiceException,
|
|
294
|
+
errorCode,
|
|
308
295
|
});
|
|
309
|
-
throw (0, smithy_client_1.decorateServiceException)(response, parsedBody);
|
|
310
296
|
}
|
|
311
297
|
};
|
|
312
298
|
const deserializeAws_restJson1PutContactInformationCommand = async (output, context) => {
|
|
313
299
|
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
314
300
|
return deserializeAws_restJson1PutContactInformationCommandError(output, context);
|
|
315
301
|
}
|
|
316
|
-
const contents = {
|
|
302
|
+
const contents = map({
|
|
317
303
|
$metadata: deserializeMetadata(output),
|
|
318
|
-
};
|
|
304
|
+
});
|
|
319
305
|
await collectBody(output.body, context);
|
|
320
|
-
return
|
|
306
|
+
return contents;
|
|
321
307
|
};
|
|
322
308
|
exports.deserializeAws_restJson1PutContactInformationCommand = deserializeAws_restJson1PutContactInformationCommand;
|
|
323
309
|
const deserializeAws_restJson1PutContactInformationCommandError = async (output, context) => {
|
|
@@ -325,7 +311,6 @@ const deserializeAws_restJson1PutContactInformationCommandError = async (output,
|
|
|
325
311
|
...output,
|
|
326
312
|
body: await parseBody(output.body, context),
|
|
327
313
|
};
|
|
328
|
-
let response;
|
|
329
314
|
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
330
315
|
switch (errorCode) {
|
|
331
316
|
case "AccessDeniedException":
|
|
@@ -342,20 +327,19 @@ const deserializeAws_restJson1PutContactInformationCommandError = async (output,
|
|
|
342
327
|
throw await deserializeAws_restJson1ValidationExceptionResponse(parsedOutput, context);
|
|
343
328
|
default:
|
|
344
329
|
const parsedBody = parsedOutput.body;
|
|
345
|
-
|
|
346
|
-
|
|
347
|
-
|
|
348
|
-
|
|
349
|
-
|
|
350
|
-
$metadata,
|
|
330
|
+
(0, smithy_client_1.throwDefaultError)({
|
|
331
|
+
output,
|
|
332
|
+
parsedBody,
|
|
333
|
+
exceptionCtor: AccountServiceException_1.AccountServiceException,
|
|
334
|
+
errorCode,
|
|
351
335
|
});
|
|
352
|
-
throw (0, smithy_client_1.decorateServiceException)(response, parsedBody);
|
|
353
336
|
}
|
|
354
337
|
};
|
|
338
|
+
const map = smithy_client_1.map;
|
|
355
339
|
const deserializeAws_restJson1AccessDeniedExceptionResponse = async (parsedOutput, context) => {
|
|
356
|
-
const contents = {};
|
|
340
|
+
const contents = map({});
|
|
357
341
|
const data = parsedOutput.body;
|
|
358
|
-
if (data.message
|
|
342
|
+
if (data.message != null) {
|
|
359
343
|
contents.message = (0, smithy_client_1.expectString)(data.message);
|
|
360
344
|
}
|
|
361
345
|
const exception = new models_0_1.AccessDeniedException({
|
|
@@ -365,9 +349,9 @@ const deserializeAws_restJson1AccessDeniedExceptionResponse = async (parsedOutpu
|
|
|
365
349
|
return (0, smithy_client_1.decorateServiceException)(exception, parsedOutput.body);
|
|
366
350
|
};
|
|
367
351
|
const deserializeAws_restJson1InternalServerExceptionResponse = async (parsedOutput, context) => {
|
|
368
|
-
const contents = {};
|
|
352
|
+
const contents = map({});
|
|
369
353
|
const data = parsedOutput.body;
|
|
370
|
-
if (data.message
|
|
354
|
+
if (data.message != null) {
|
|
371
355
|
contents.message = (0, smithy_client_1.expectString)(data.message);
|
|
372
356
|
}
|
|
373
357
|
const exception = new models_0_1.InternalServerException({
|
|
@@ -377,9 +361,9 @@ const deserializeAws_restJson1InternalServerExceptionResponse = async (parsedOut
|
|
|
377
361
|
return (0, smithy_client_1.decorateServiceException)(exception, parsedOutput.body);
|
|
378
362
|
};
|
|
379
363
|
const deserializeAws_restJson1ResourceNotFoundExceptionResponse = async (parsedOutput, context) => {
|
|
380
|
-
const contents = {};
|
|
364
|
+
const contents = map({});
|
|
381
365
|
const data = parsedOutput.body;
|
|
382
|
-
if (data.message
|
|
366
|
+
if (data.message != null) {
|
|
383
367
|
contents.message = (0, smithy_client_1.expectString)(data.message);
|
|
384
368
|
}
|
|
385
369
|
const exception = new models_0_1.ResourceNotFoundException({
|
|
@@ -389,9 +373,9 @@ const deserializeAws_restJson1ResourceNotFoundExceptionResponse = async (parsedO
|
|
|
389
373
|
return (0, smithy_client_1.decorateServiceException)(exception, parsedOutput.body);
|
|
390
374
|
};
|
|
391
375
|
const deserializeAws_restJson1TooManyRequestsExceptionResponse = async (parsedOutput, context) => {
|
|
392
|
-
const contents = {};
|
|
376
|
+
const contents = map({});
|
|
393
377
|
const data = parsedOutput.body;
|
|
394
|
-
if (data.message
|
|
378
|
+
if (data.message != null) {
|
|
395
379
|
contents.message = (0, smithy_client_1.expectString)(data.message);
|
|
396
380
|
}
|
|
397
381
|
const exception = new models_0_1.TooManyRequestsException({
|
|
@@ -401,9 +385,9 @@ const deserializeAws_restJson1TooManyRequestsExceptionResponse = async (parsedOu
|
|
|
401
385
|
return (0, smithy_client_1.decorateServiceException)(exception, parsedOutput.body);
|
|
402
386
|
};
|
|
403
387
|
const deserializeAws_restJson1ValidationExceptionResponse = async (parsedOutput, context) => {
|
|
404
|
-
const contents = {};
|
|
388
|
+
const contents = map({});
|
|
405
389
|
const data = parsedOutput.body;
|
|
406
|
-
if (data.message
|
|
390
|
+
if (data.message != null) {
|
|
407
391
|
contents.message = (0, smithy_client_1.expectString)(data.message);
|
|
408
392
|
}
|
|
409
393
|
const exception = new models_0_1.ValidationException({
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { __assign, __awaiter, __generator } from "tslib";
|
|
2
2
|
import { HttpRequest as __HttpRequest } from "@aws-sdk/protocol-http";
|
|
3
|
-
import { decorateServiceException as __decorateServiceException, expectNonNull as __expectNonNull, expectObject as __expectObject, expectString as __expectString, } from "@aws-sdk/smithy-client";
|
|
3
|
+
import { decorateServiceException as __decorateServiceException, expectNonNull as __expectNonNull, expectObject as __expectObject, expectString as __expectString, map as __map, throwDefaultError, } from "@aws-sdk/smithy-client";
|
|
4
4
|
import { AccountServiceException as __BaseException } from "../models/AccountServiceException";
|
|
5
5
|
import { AccessDeniedException, InternalServerException, ResourceNotFoundException, TooManyRequestsException, ValidationException, } from "../models/models_0";
|
|
6
6
|
export var serializeAws_restJson1DeleteAlternateContactCommand = function (input, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
@@ -133,18 +133,18 @@ export var deserializeAws_restJson1DeleteAlternateContactCommand = function (out
|
|
|
133
133
|
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
134
134
|
return [2, deserializeAws_restJson1DeleteAlternateContactCommandError(output, context)];
|
|
135
135
|
}
|
|
136
|
-
contents = {
|
|
136
|
+
contents = map({
|
|
137
137
|
$metadata: deserializeMetadata(output),
|
|
138
|
-
};
|
|
138
|
+
});
|
|
139
139
|
return [4, collectBody(output.body, context)];
|
|
140
140
|
case 1:
|
|
141
141
|
_a.sent();
|
|
142
|
-
return [2,
|
|
142
|
+
return [2, contents];
|
|
143
143
|
}
|
|
144
144
|
});
|
|
145
145
|
}); };
|
|
146
146
|
var deserializeAws_restJson1DeleteAlternateContactCommandError = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
147
|
-
var parsedOutput, _a,
|
|
147
|
+
var parsedOutput, _a, errorCode, _b, parsedBody;
|
|
148
148
|
var _c;
|
|
149
149
|
return __generator(this, function (_d) {
|
|
150
150
|
switch (_d.label) {
|
|
@@ -181,14 +181,14 @@ var deserializeAws_restJson1DeleteAlternateContactCommandError = function (outpu
|
|
|
181
181
|
case 11: throw _d.sent();
|
|
182
182
|
case 12:
|
|
183
183
|
parsedBody = parsedOutput.body;
|
|
184
|
-
|
|
185
|
-
|
|
186
|
-
|
|
187
|
-
|
|
188
|
-
|
|
189
|
-
$metadata: $metadata,
|
|
184
|
+
throwDefaultError({
|
|
185
|
+
output: output,
|
|
186
|
+
parsedBody: parsedBody,
|
|
187
|
+
exceptionCtor: __BaseException,
|
|
188
|
+
errorCode: errorCode,
|
|
190
189
|
});
|
|
191
|
-
|
|
190
|
+
_d.label = 13;
|
|
191
|
+
case 13: return [2];
|
|
192
192
|
}
|
|
193
193
|
});
|
|
194
194
|
}); };
|
|
@@ -200,24 +200,23 @@ export var deserializeAws_restJson1GetAlternateContactCommand = function (output
|
|
|
200
200
|
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
201
201
|
return [2, deserializeAws_restJson1GetAlternateContactCommandError(output, context)];
|
|
202
202
|
}
|
|
203
|
-
contents = {
|
|
203
|
+
contents = map({
|
|
204
204
|
$metadata: deserializeMetadata(output),
|
|
205
|
-
|
|
206
|
-
};
|
|
205
|
+
});
|
|
207
206
|
_a = __expectNonNull;
|
|
208
207
|
_b = __expectObject;
|
|
209
208
|
return [4, parseBody(output.body, context)];
|
|
210
209
|
case 1:
|
|
211
210
|
data = _a.apply(void 0, [_b.apply(void 0, [_c.sent()]), "body"]);
|
|
212
|
-
if (data.AlternateContact
|
|
211
|
+
if (data.AlternateContact != null) {
|
|
213
212
|
contents.AlternateContact = deserializeAws_restJson1AlternateContact(data.AlternateContact, context);
|
|
214
213
|
}
|
|
215
|
-
return [2,
|
|
214
|
+
return [2, contents];
|
|
216
215
|
}
|
|
217
216
|
});
|
|
218
217
|
}); };
|
|
219
218
|
var deserializeAws_restJson1GetAlternateContactCommandError = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
220
|
-
var parsedOutput, _a,
|
|
219
|
+
var parsedOutput, _a, errorCode, _b, parsedBody;
|
|
221
220
|
var _c;
|
|
222
221
|
return __generator(this, function (_d) {
|
|
223
222
|
switch (_d.label) {
|
|
@@ -254,14 +253,14 @@ var deserializeAws_restJson1GetAlternateContactCommandError = function (output,
|
|
|
254
253
|
case 11: throw _d.sent();
|
|
255
254
|
case 12:
|
|
256
255
|
parsedBody = parsedOutput.body;
|
|
257
|
-
|
|
258
|
-
|
|
259
|
-
|
|
260
|
-
|
|
261
|
-
|
|
262
|
-
$metadata: $metadata,
|
|
256
|
+
throwDefaultError({
|
|
257
|
+
output: output,
|
|
258
|
+
parsedBody: parsedBody,
|
|
259
|
+
exceptionCtor: __BaseException,
|
|
260
|
+
errorCode: errorCode,
|
|
263
261
|
});
|
|
264
|
-
|
|
262
|
+
_d.label = 13;
|
|
263
|
+
case 13: return [2];
|
|
265
264
|
}
|
|
266
265
|
});
|
|
267
266
|
}); };
|
|
@@ -273,24 +272,23 @@ export var deserializeAws_restJson1GetContactInformationCommand = function (outp
|
|
|
273
272
|
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
274
273
|
return [2, deserializeAws_restJson1GetContactInformationCommandError(output, context)];
|
|
275
274
|
}
|
|
276
|
-
contents = {
|
|
275
|
+
contents = map({
|
|
277
276
|
$metadata: deserializeMetadata(output),
|
|
278
|
-
|
|
279
|
-
};
|
|
277
|
+
});
|
|
280
278
|
_a = __expectNonNull;
|
|
281
279
|
_b = __expectObject;
|
|
282
280
|
return [4, parseBody(output.body, context)];
|
|
283
281
|
case 1:
|
|
284
282
|
data = _a.apply(void 0, [_b.apply(void 0, [_c.sent()]), "body"]);
|
|
285
|
-
if (data.ContactInformation
|
|
283
|
+
if (data.ContactInformation != null) {
|
|
286
284
|
contents.ContactInformation = deserializeAws_restJson1ContactInformation(data.ContactInformation, context);
|
|
287
285
|
}
|
|
288
|
-
return [2,
|
|
286
|
+
return [2, contents];
|
|
289
287
|
}
|
|
290
288
|
});
|
|
291
289
|
}); };
|
|
292
290
|
var deserializeAws_restJson1GetContactInformationCommandError = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
293
|
-
var parsedOutput, _a,
|
|
291
|
+
var parsedOutput, _a, errorCode, _b, parsedBody;
|
|
294
292
|
var _c;
|
|
295
293
|
return __generator(this, function (_d) {
|
|
296
294
|
switch (_d.label) {
|
|
@@ -327,14 +325,14 @@ var deserializeAws_restJson1GetContactInformationCommandError = function (output
|
|
|
327
325
|
case 11: throw _d.sent();
|
|
328
326
|
case 12:
|
|
329
327
|
parsedBody = parsedOutput.body;
|
|
330
|
-
|
|
331
|
-
|
|
332
|
-
|
|
333
|
-
|
|
334
|
-
|
|
335
|
-
$metadata: $metadata,
|
|
328
|
+
throwDefaultError({
|
|
329
|
+
output: output,
|
|
330
|
+
parsedBody: parsedBody,
|
|
331
|
+
exceptionCtor: __BaseException,
|
|
332
|
+
errorCode: errorCode,
|
|
336
333
|
});
|
|
337
|
-
|
|
334
|
+
_d.label = 13;
|
|
335
|
+
case 13: return [2];
|
|
338
336
|
}
|
|
339
337
|
});
|
|
340
338
|
}); };
|
|
@@ -346,18 +344,18 @@ export var deserializeAws_restJson1PutAlternateContactCommand = function (output
|
|
|
346
344
|
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
347
345
|
return [2, deserializeAws_restJson1PutAlternateContactCommandError(output, context)];
|
|
348
346
|
}
|
|
349
|
-
contents = {
|
|
347
|
+
contents = map({
|
|
350
348
|
$metadata: deserializeMetadata(output),
|
|
351
|
-
};
|
|
349
|
+
});
|
|
352
350
|
return [4, collectBody(output.body, context)];
|
|
353
351
|
case 1:
|
|
354
352
|
_a.sent();
|
|
355
|
-
return [2,
|
|
353
|
+
return [2, contents];
|
|
356
354
|
}
|
|
357
355
|
});
|
|
358
356
|
}); };
|
|
359
357
|
var deserializeAws_restJson1PutAlternateContactCommandError = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
360
|
-
var parsedOutput, _a,
|
|
358
|
+
var parsedOutput, _a, errorCode, _b, parsedBody;
|
|
361
359
|
var _c;
|
|
362
360
|
return __generator(this, function (_d) {
|
|
363
361
|
switch (_d.label) {
|
|
@@ -390,14 +388,14 @@ var deserializeAws_restJson1PutAlternateContactCommandError = function (output,
|
|
|
390
388
|
case 9: throw _d.sent();
|
|
391
389
|
case 10:
|
|
392
390
|
parsedBody = parsedOutput.body;
|
|
393
|
-
|
|
394
|
-
|
|
395
|
-
|
|
396
|
-
|
|
397
|
-
|
|
398
|
-
$metadata: $metadata,
|
|
391
|
+
throwDefaultError({
|
|
392
|
+
output: output,
|
|
393
|
+
parsedBody: parsedBody,
|
|
394
|
+
exceptionCtor: __BaseException,
|
|
395
|
+
errorCode: errorCode,
|
|
399
396
|
});
|
|
400
|
-
|
|
397
|
+
_d.label = 11;
|
|
398
|
+
case 11: return [2];
|
|
401
399
|
}
|
|
402
400
|
});
|
|
403
401
|
}); };
|
|
@@ -409,18 +407,18 @@ export var deserializeAws_restJson1PutContactInformationCommand = function (outp
|
|
|
409
407
|
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
410
408
|
return [2, deserializeAws_restJson1PutContactInformationCommandError(output, context)];
|
|
411
409
|
}
|
|
412
|
-
contents = {
|
|
410
|
+
contents = map({
|
|
413
411
|
$metadata: deserializeMetadata(output),
|
|
414
|
-
};
|
|
412
|
+
});
|
|
415
413
|
return [4, collectBody(output.body, context)];
|
|
416
414
|
case 1:
|
|
417
415
|
_a.sent();
|
|
418
|
-
return [2,
|
|
416
|
+
return [2, contents];
|
|
419
417
|
}
|
|
420
418
|
});
|
|
421
419
|
}); };
|
|
422
420
|
var deserializeAws_restJson1PutContactInformationCommandError = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
423
|
-
var parsedOutput, _a,
|
|
421
|
+
var parsedOutput, _a, errorCode, _b, parsedBody;
|
|
424
422
|
var _c;
|
|
425
423
|
return __generator(this, function (_d) {
|
|
426
424
|
switch (_d.label) {
|
|
@@ -453,23 +451,24 @@ var deserializeAws_restJson1PutContactInformationCommandError = function (output
|
|
|
453
451
|
case 9: throw _d.sent();
|
|
454
452
|
case 10:
|
|
455
453
|
parsedBody = parsedOutput.body;
|
|
456
|
-
|
|
457
|
-
|
|
458
|
-
|
|
459
|
-
|
|
460
|
-
|
|
461
|
-
$metadata: $metadata,
|
|
454
|
+
throwDefaultError({
|
|
455
|
+
output: output,
|
|
456
|
+
parsedBody: parsedBody,
|
|
457
|
+
exceptionCtor: __BaseException,
|
|
458
|
+
errorCode: errorCode,
|
|
462
459
|
});
|
|
463
|
-
|
|
460
|
+
_d.label = 11;
|
|
461
|
+
case 11: return [2];
|
|
464
462
|
}
|
|
465
463
|
});
|
|
466
464
|
}); };
|
|
465
|
+
var map = __map;
|
|
467
466
|
var deserializeAws_restJson1AccessDeniedExceptionResponse = function (parsedOutput, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
468
467
|
var contents, data, exception;
|
|
469
468
|
return __generator(this, function (_a) {
|
|
470
|
-
contents = {};
|
|
469
|
+
contents = map({});
|
|
471
470
|
data = parsedOutput.body;
|
|
472
|
-
if (data.message
|
|
471
|
+
if (data.message != null) {
|
|
473
472
|
contents.message = __expectString(data.message);
|
|
474
473
|
}
|
|
475
474
|
exception = new AccessDeniedException(__assign({ $metadata: deserializeMetadata(parsedOutput) }, contents));
|
|
@@ -479,9 +478,9 @@ var deserializeAws_restJson1AccessDeniedExceptionResponse = function (parsedOutp
|
|
|
479
478
|
var deserializeAws_restJson1InternalServerExceptionResponse = function (parsedOutput, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
480
479
|
var contents, data, exception;
|
|
481
480
|
return __generator(this, function (_a) {
|
|
482
|
-
contents = {};
|
|
481
|
+
contents = map({});
|
|
483
482
|
data = parsedOutput.body;
|
|
484
|
-
if (data.message
|
|
483
|
+
if (data.message != null) {
|
|
485
484
|
contents.message = __expectString(data.message);
|
|
486
485
|
}
|
|
487
486
|
exception = new InternalServerException(__assign({ $metadata: deserializeMetadata(parsedOutput) }, contents));
|
|
@@ -491,9 +490,9 @@ var deserializeAws_restJson1InternalServerExceptionResponse = function (parsedOu
|
|
|
491
490
|
var deserializeAws_restJson1ResourceNotFoundExceptionResponse = function (parsedOutput, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
492
491
|
var contents, data, exception;
|
|
493
492
|
return __generator(this, function (_a) {
|
|
494
|
-
contents = {};
|
|
493
|
+
contents = map({});
|
|
495
494
|
data = parsedOutput.body;
|
|
496
|
-
if (data.message
|
|
495
|
+
if (data.message != null) {
|
|
497
496
|
contents.message = __expectString(data.message);
|
|
498
497
|
}
|
|
499
498
|
exception = new ResourceNotFoundException(__assign({ $metadata: deserializeMetadata(parsedOutput) }, contents));
|
|
@@ -503,9 +502,9 @@ var deserializeAws_restJson1ResourceNotFoundExceptionResponse = function (parsed
|
|
|
503
502
|
var deserializeAws_restJson1TooManyRequestsExceptionResponse = function (parsedOutput, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
504
503
|
var contents, data, exception;
|
|
505
504
|
return __generator(this, function (_a) {
|
|
506
|
-
contents = {};
|
|
505
|
+
contents = map({});
|
|
507
506
|
data = parsedOutput.body;
|
|
508
|
-
if (data.message
|
|
507
|
+
if (data.message != null) {
|
|
509
508
|
contents.message = __expectString(data.message);
|
|
510
509
|
}
|
|
511
510
|
exception = new TooManyRequestsException(__assign({ $metadata: deserializeMetadata(parsedOutput) }, contents));
|
|
@@ -515,9 +514,9 @@ var deserializeAws_restJson1TooManyRequestsExceptionResponse = function (parsedO
|
|
|
515
514
|
var deserializeAws_restJson1ValidationExceptionResponse = function (parsedOutput, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
516
515
|
var contents, data, exception;
|
|
517
516
|
return __generator(this, function (_a) {
|
|
518
|
-
contents = {};
|
|
517
|
+
contents = map({});
|
|
519
518
|
data = parsedOutput.body;
|
|
520
|
-
if (data.message
|
|
519
|
+
if (data.message != null) {
|
|
521
520
|
contents.message = __expectString(data.message);
|
|
522
521
|
}
|
|
523
522
|
exception = new ValidationException(__assign({ $metadata: deserializeMetadata(parsedOutput) }, contents));
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@aws-sdk/client-account",
|
|
3
3
|
"description": "AWS SDK for JavaScript Account Client for Node.js, Browser and React Native",
|
|
4
|
-
"version": "3.
|
|
4
|
+
"version": "3.142.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",
|
|
@@ -18,9 +18,9 @@
|
|
|
18
18
|
"dependencies": {
|
|
19
19
|
"@aws-crypto/sha256-browser": "2.0.0",
|
|
20
20
|
"@aws-crypto/sha256-js": "2.0.0",
|
|
21
|
-
"@aws-sdk/client-sts": "3.
|
|
21
|
+
"@aws-sdk/client-sts": "3.142.0",
|
|
22
22
|
"@aws-sdk/config-resolver": "3.130.0",
|
|
23
|
-
"@aws-sdk/credential-provider-node": "3.
|
|
23
|
+
"@aws-sdk/credential-provider-node": "3.142.0",
|
|
24
24
|
"@aws-sdk/fetch-http-handler": "3.131.0",
|
|
25
25
|
"@aws-sdk/hash-node": "3.127.0",
|
|
26
26
|
"@aws-sdk/invalid-dependency": "3.127.0",
|
|
@@ -36,15 +36,15 @@
|
|
|
36
36
|
"@aws-sdk/node-config-provider": "3.127.0",
|
|
37
37
|
"@aws-sdk/node-http-handler": "3.127.0",
|
|
38
38
|
"@aws-sdk/protocol-http": "3.127.0",
|
|
39
|
-
"@aws-sdk/smithy-client": "3.
|
|
39
|
+
"@aws-sdk/smithy-client": "3.142.0",
|
|
40
40
|
"@aws-sdk/types": "3.127.0",
|
|
41
41
|
"@aws-sdk/url-parser": "3.127.0",
|
|
42
42
|
"@aws-sdk/util-base64-browser": "3.109.0",
|
|
43
43
|
"@aws-sdk/util-base64-node": "3.55.0",
|
|
44
44
|
"@aws-sdk/util-body-length-browser": "3.55.0",
|
|
45
45
|
"@aws-sdk/util-body-length-node": "3.55.0",
|
|
46
|
-
"@aws-sdk/util-defaults-mode-browser": "3.
|
|
47
|
-
"@aws-sdk/util-defaults-mode-node": "3.
|
|
46
|
+
"@aws-sdk/util-defaults-mode-browser": "3.142.0",
|
|
47
|
+
"@aws-sdk/util-defaults-mode-node": "3.142.0",
|
|
48
48
|
"@aws-sdk/util-user-agent-browser": "3.127.0",
|
|
49
49
|
"@aws-sdk/util-user-agent-node": "3.127.0",
|
|
50
50
|
"@aws-sdk/util-utf8-browser": "3.109.0",
|